diff --git a/.ci/packer_cache.sh b/.ci/packer_cache.sh index a8ae2d9f3b5b4..52c32de6f9a24 100755 --- a/.ci/packer_cache.sh +++ b/.ci/packer_cache.sh @@ -22,4 +22,5 @@ tar -cf "$HOME/.kibana/bootstrap_cache/master.tar" \ x-pack/plugins/*/node_modules \ x-pack/plugins/reporting/.chromium \ x-pack/plugins/reporting/.phantom \ + test/plugin_functional/plugins/*/node_modules \ .es; diff --git a/.eslintignore b/.eslintignore index 7fe4c94b477ae..21a643ae8eb35 100644 --- a/.eslintignore +++ b/.eslintignore @@ -5,6 +5,7 @@ bower_components /.es /plugins /optimize +/dlls /src/fixtures/vislib/mock_data /src/ui/public/angular-bootstrap /src/ui/public/flot-charts diff --git a/.gitignore b/.gitignore index 15fa517ae7474..157d51cea5f28 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,7 @@ node_modules !/src/dev/notice/__fixtures__/node_modules trash /optimize +/dlls target /build .jruby diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 9bb072317d053..db8024ac1dc86 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -230,8 +230,6 @@ The `config/kibana.yml` file stores user configuration directives. Since this fi #### Potential Optimization Pitfalls -In development mode, Kibana runs a customized version of [Webpack](http://webpack.github.io/) with some optimizations enabled to make building the browser bundles as fast as possible. These optimizations make the build process about 2x as fast for initial builds, and about 7x faster for rebuilds, but are labeled "unsafe" by Webpack because they can sometimes cause changes to go unnoticed by the compiler. If you experience any of the scenarios below either restart the dev server, or add `optimize.unsafeCache: false` to your `config/kibana.dev.yml` file to disable these optimizations completely. - - Webpack is trying to include a file in the bundle that I deleted and is now complaining about it is missing - A module id that used to resolve to a single file now resolves to a directory, but webpack isn't adapting - (if you discover other scenarios, please send a PR!) diff --git a/NOTICE.txt b/NOTICE.txt index 87c9dfb44799a..be6305d509b74 100644 --- a/NOTICE.txt +++ b/NOTICE.txt @@ -1,6 +1,9 @@ Kibana source code with Kibana X-Pack source code Copyright 2012-2018 Elasticsearch B.V. +--- +This product has relied on ASTExplorer that is licensed under MIT. + --- This product includes code that was extracted from angular-ui-bootstrap@0.13.1 which is available under an "MIT" license diff --git a/package.json b/package.json index 3fa5366a3e180..89ec90dfd0f4e 100644 --- a/package.json +++ b/package.json @@ -27,6 +27,7 @@ "extraPatterns": [ "build", "optimize", + "dlls", ".eslintcache" ] } @@ -71,39 +72,41 @@ "url": "https://github.com/elastic/kibana.git" }, "resolutions": { - "**/@types/node": "8.10.21", + "**/@types/node": "8.10.38", "@types/react": "16.3.14" }, "workspaces": { "packages": [ "packages/*", "x-pack", - "x-pack/plugins/*" + "x-pack/plugins/*", + "test/plugin_functional/plugins/*" ], "nohoist": [ "**/@types/*", "**/@types/*/**", "**/grunt-*", "**/grunt-*/**", - "x-pack/typescript" + "x-pack/typescript", + "kbn_tp_*/**" ] }, "dependencies": { + "@elastic/datemath": "5.0.1", "@elastic/eui": "5.3.0", "@elastic/filesaver": "1.1.2", "@elastic/good": "8.1.1-kibana1", "@elastic/numeral": "2.3.2", "@elastic/ui-ace": "0.2.3", + "@kbn/babel-code-parser": "1.0.0", "@kbn/babel-preset": "1.0.0", "@kbn/config-schema": "1.0.0", - "@elastic/datemath": "5.0.1", "@kbn/es-query": "1.0.0", "@kbn/i18n": "1.0.0", "@kbn/interpreter": "1.0.0", "@kbn/pm": "1.0.0", "@kbn/test-subj-selector": "0.2.1", "@kbn/ui-framework": "1.0.0", - "JSONStream": "1.1.1", "abortcontroller-polyfill": "^1.1.9", "angular": "1.6.9", "angular-aria": "1.6.6", @@ -113,19 +116,19 @@ "angular-sanitize": "1.5.7", "angular-sortable-view": "0.0.15", "autoprefixer": "^9.1.0", - "babel-core": "6.21.0", - "babel-loader": "7.1.2", - "babel-polyfill": "6.20.0", - "babel-register": "6.18.0", + "babel-core": "6.26.3", + "babel-loader": "7.1.5", + "babel-polyfill": "6.26.0", + "babel-register": "6.26.0", "bluebird": "2.9.34", "boom": "^7.2.0", "brace": "0.11.1", - "cache-loader": "1.0.3", + "cache-loader": "1.2.2", "chalk": "^2.4.1", "color": "1.0.3", "commander": "2.8.1", "compare-versions": "3.1.0", - "css-loader": "0.28.7", + "css-loader": "1.0.0", "custom-event-polyfill": "^0.3.0", "d3": "3.5.6", "d3-cloud": "1.2.1", @@ -136,8 +139,7 @@ "encode-uri-query": "1.0.0", "execa": "^0.10.0", "expiry-js": "0.1.7", - "extract-text-webpack-plugin": "3.0.1", - "file-loader": "1.1.4", + "file-loader": "2.0.0", "font-awesome": "4.4.0", "getos": "^3.1.0", "glob": "^7.1.2", @@ -162,10 +164,11 @@ "leaflet-vega": "^0.8.6", "leaflet.heat": "0.2.0", "less": "2.7.1", - "less-loader": "4.0.5", + "less-loader": "4.1.0", "lodash": "npm:@elastic/lodash@3.10.1-kibana1", "lru-cache": "4.1.1", "markdown-it": "^8.4.1", + "mini-css-extract-plugin": "0.4.4", "minimatch": "^3.0.4", "mkdirp": "0.5.1", "moment": "^2.20.1", @@ -177,7 +180,7 @@ "opn": "^5.4.0", "oppsy": "^2.0.0", "pegjs": "0.9.0", - "postcss-loader": "2.0.6", + "postcss-loader": "3.0.0", "prop-types": "15.5.8", "proxy-from-env": "1.0.0", "pug": "^2.0.3", @@ -210,7 +213,7 @@ "semver": "^5.5.0", "socket.io": "^2.1.1", "stream-stream": "^1.2.6", - "style-loader": "0.19.0", + "style-loader": "0.23.1", "tar": "2.2.0", "tinygradient": "0.3.0", "tinymath": "1.1.0", @@ -222,17 +225,17 @@ "type-detect": "^4.0.8", "uglifyjs-webpack-plugin": "^1.2.7", "ui-select": "0.19.6", - "url-loader": "0.5.9", + "url-loader": "1.1.2", "uuid": "3.0.1", - "val-loader": "^1.1.0", + "val-loader": "^1.1.1", "validate-npm-package-name": "2.2.2", "vega-lib": "^3.3.1", "vega-lite": "^2.4.0", "vega-schema-url-parser": "1.0.0", "vega-tooltip": "^0.9.14", "vision": "^5.3.3", - "webpack": "3.6.0", - "webpack-merge": "4.1.0", + "webpack": "4.23.1", + "webpack-merge": "4.1.4", "whatwg-fetch": "^2.0.3", "wreck": "^14.0.2", "x-pack": "7.0.0", @@ -249,7 +252,7 @@ "@kbn/plugin-generator": "1.0.0", "@kbn/test": "1.0.0", "@octokit/rest": "^15.10.0", - "@types/angular": "^1.6.50", + "@types/angular": "1.6.50", "@types/angular-mocks": "^1.7.0", "@types/babel-core": "^6.25.5", "@types/bluebird": "^3.1.1", @@ -282,7 +285,7 @@ "@types/minimatch": "^2.0.29", "@types/moment-timezone": "^0.5.8", "@types/mustache": "^0.8.31", - "@types/node": "^8.10.20", + "@types/node": "^8.10.38", "@types/opn": "^5.1.0", "@types/podium": "^1.0.0", "@types/prop-types": "^15.5.3", @@ -346,7 +349,7 @@ "has-ansi": "^3.0.0", "image-diff": "1.6.0", "intl-messageformat-parser": "^1.4.0", - "istanbul-instrumenter-loader": "3.0.0", + "istanbul-instrumenter-loader": "3.0.1", "jest": "^23.5.0", "jest-cli": "^23.5.0", "jest-raw-loader": "^1.0.1", @@ -370,10 +373,11 @@ "murmurhash3js": "3.0.1", "mutation-observer": "^1.0.3", "nock": "8.0.0", - "node-sass": "^4.9.0", + "node-sass": "^4.9.4", "normalize-path": "^3.0.0", "pixelmatch": "4.0.2", - "postcss": "^7.0.2", + "pkg-up": "^2.0.0", + "postcss": "^7.0.5", "prettier": "^1.14.3", "proxyquire": "1.7.11", "regenerate": "^1.4.0", @@ -384,7 +388,7 @@ "supertest-as-promised": "^4.0.2", "tree-kill": "^1.1.0", "ts-jest": "^23.1.4", - "ts-loader": "^3.5.0", + "ts-loader": "^5.2.2", "ts-node": "^7.0.1", "tslint": "^5.11.0", "tslint-config-prettier": "^1.15.0", diff --git a/packages/elastic-datemath/package.json b/packages/elastic-datemath/package.json index 27d9b0b291dcf..90263708d0859 100644 --- a/packages/elastic-datemath/package.json +++ b/packages/elastic-datemath/package.json @@ -13,7 +13,7 @@ "devDependencies": { "babel-cli": "^6.26.0", "babel-plugin-add-module-exports": "^0.2.1", - "babel-preset-env": "^1.6.1" + "babel-preset-env": "^1.7.0" }, "dependencies": { "moment": "^2.13.0", diff --git a/packages/kbn-babel-code-parser/.babelrc b/packages/kbn-babel-code-parser/.babelrc new file mode 100644 index 0000000000000..7da72d1779128 --- /dev/null +++ b/packages/kbn-babel-code-parser/.babelrc @@ -0,0 +1,3 @@ +{ + "presets": ["@kbn/babel-preset/node_preset"] +} diff --git a/packages/kbn-babel-code-parser/README.md b/packages/kbn-babel-code-parser/README.md new file mode 100755 index 0000000000000..f99d01541ee22 --- /dev/null +++ b/packages/kbn-babel-code-parser/README.md @@ -0,0 +1,19 @@ +# @kbn/babel-code-parser + +Simple abstraction over the `@babel/parser` and the `@babel/traverse` in order +to build a code parser on top. + +We have two main functions `parseSingleFile` (sync and sync version) and the +`parseEntries` (only async version). The first one just parse one entry file +and the second one parses recursively all the files from a list of +start entry points. + +Then we have `visitors` and `strategies`. The first ones are basically the +`visitors` to use into the ast from the `@babel/traverse`. They are the only +way to collect info when using the `parseSingleFile`. The `strategies` are +meant to be used with the `parseEntries` and configures the info we want +to collect from our parsed code. After each loop, one per entry file, the +`parseEntries` method will call the given `strategy` expecting that +`strategy` would call the desired visitors, assemble the important +information to collect and adds them to the final results. + diff --git a/packages/kbn-babel-code-parser/package.json b/packages/kbn-babel-code-parser/package.json new file mode 100755 index 0000000000000..5ef9c94194797 --- /dev/null +++ b/packages/kbn-babel-code-parser/package.json @@ -0,0 +1,26 @@ +{ + "name": "@kbn/babel-code-parser", + "description": "babel code parser for Kibana", + "private": true, + "version": "1.0.0", + "main": "./target/index.js", + "license": "Apache-2.0", + "repository": { + "type": "git", + "url": "https://github.com/elastic/kibana/tree/master/packages/kbn-babel-code-parser" + }, + "scripts": { + "build": "babel src --out-dir target --quiet", + "kbn:bootstrap": "yarn build", + "kbn:watch": "yarn build --watch" + }, + "devDependencies": { + "babel-cli": "^6.26.0" + }, + "dependencies": { + "@kbn/babel-preset": "1.0.0", + "@babel/parser": "^7.1.3", + "@babel/traverse": "^7.1.4", + "lodash": "^4.17.11" + } +} diff --git a/packages/kbn-babel-code-parser/src/can_require.js b/packages/kbn-babel-code-parser/src/can_require.js new file mode 100644 index 0000000000000..e590c249e9806 --- /dev/null +++ b/packages/kbn-babel-code-parser/src/can_require.js @@ -0,0 +1,36 @@ +/* + * 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 canRequire(cwd, entry) { + try { + // We will try to test if we can resolve + // this entry through the require.resolve + // setting as the start looking path the + // given cwd. Require.resolve will keep + // looking recursively as normal starting + // from that location. + return require.resolve(entry, { + paths: [ + cwd + ] + }); + } catch (e) { + return false; + } +} diff --git a/packages/kbn-babel-code-parser/src/code_parser.js b/packages/kbn-babel-code-parser/src/code_parser.js new file mode 100644 index 0000000000000..8d76b1032561a --- /dev/null +++ b/packages/kbn-babel-code-parser/src/code_parser.js @@ -0,0 +1,103 @@ +/* + * 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 { canRequire } from './can_require'; +import { readFile, readFileSync } from 'fs'; +import { extname } from 'path'; +import { promisify } from 'util'; +import * as parser from '@babel/parser'; +import traverse from '@babel/traverse'; +import * as babelParserOptions from '@kbn/babel-preset/common_babel_parser_options'; + +const read = promisify(readFile); + +function _cannotParseFile(filePath) { + return extname(filePath) !== '.js'; +} + +function _parseAndTraverseFileContent(fileContent, visitorsGenerator) { + const results = []; + + // Parse and get the code AST + // All the babel parser plugins + // were enabled + const ast = parser.parse(fileContent, babelParserOptions); + + // Loop through the code AST with + // the defined visitors + traverse(ast, visitorsGenerator(results)); + + return results; +} + +export async function parseSingleFile(filePath, visitorsGenerator) { + // Don't parse any other files than .js ones + if (_cannotParseFile(filePath)) { + return []; + } + + // Read the file + const content = await read(filePath, { encoding: 'utf8' }); + + // return the results found on parse and traverse + // the file content with the given visitors + return _parseAndTraverseFileContent(content, visitorsGenerator); +} + +export function parseSingleFileSync(filePath, visitorsGenerator) { + // Don't parse any other files than .js ones + if (_cannotParseFile(filePath)) { + return []; + } + + // Read the file + const content = readFileSync(filePath, { encoding: 'utf8' }); + + // return the results found on parse and traverse + // the file content with the given visitors + return _parseAndTraverseFileContent(content, visitorsGenerator); +} + +export async function parseEntries(cwd, entries, strategy, results, wasParsed = {}) { + // Assure that we always have a cwd + const sanitizedCwd = cwd || process.cwd(); + + // Test each entry against canRequire function + const entriesQueue = entries.map(entry => canRequire(sanitizedCwd, entry)); + + while(entriesQueue.length) { + // Get the first element in the queue as + // select it as our current entry to parse + const mainEntry = entriesQueue.shift(); + + // Avoid parse the current entry if it is not valid + // or it was already parsed + if (typeof mainEntry !== 'string' || wasParsed[mainEntry]) { + continue; + } + + // Find new entries and adds them to the end of the queue + entriesQueue.push(...(await strategy(sanitizedCwd, parseSingleFile, mainEntry, wasParsed, results))); + + // Mark the current main entry as already parsed + wasParsed[mainEntry] = true; + } + + return results; +} diff --git a/packages/kbn-babel-code-parser/src/index.js b/packages/kbn-babel-code-parser/src/index.js new file mode 100644 index 0000000000000..70e4eb18068b0 --- /dev/null +++ b/packages/kbn-babel-code-parser/src/index.js @@ -0,0 +1,22 @@ +/* + * 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 { dependenciesParseStrategy } from './strategies'; +export { dependenciesVisitorsGenerator } from './visitors'; +export { parseSingleFile, parseSingleFileSync, parseEntries } from './code_parser'; diff --git a/packages/kbn-babel-code-parser/src/strategies.js b/packages/kbn-babel-code-parser/src/strategies.js new file mode 100644 index 0000000000000..317ded014210b --- /dev/null +++ b/packages/kbn-babel-code-parser/src/strategies.js @@ -0,0 +1,94 @@ +/* + * 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 { canRequire } from './can_require'; +import { dependenciesVisitorsGenerator } from './visitors'; +import { dirname, isAbsolute, resolve } from 'path'; + +export function _calculateTopLevelDependency(inputDep, outputDep = '') { + // The path separator will be always the forward slash + // as at this point we only have the found entries into + // the provided source code entries where we just use it + const pathSeparator = '/'; + const depSplitPaths = inputDep.split(pathSeparator); + const firstPart = depSplitPaths.shift(); + const outputDepFirstArgAppend = outputDep ? pathSeparator : ''; + + outputDep += `${outputDepFirstArgAppend}${firstPart}`; + + // In case our dependency isn't started by @ + // we are already done and we can return the + // dependency value we already have + if (firstPart.charAt(0) !== '@') { + return outputDep; + } + + // Otherwise we need to keep constructing the dependency + // value because dependencies starting with @ points to + // folders of dependencies. For example, in case we found + // dependencies values with '@the-deps/a' and '@the-deps/a/b' + // we don't want to map it to '@the-deps' but also to @'the-deps/a' + // because inside '@the-deps' we can also have '@the-dep/b' + return _calculateTopLevelDependency(depSplitPaths.join(pathSeparator), outputDep); +} + +export async function dependenciesParseStrategy(cwd, parseSingleFile, mainEntry, wasParsed, results) { + // Retrieve native nodeJS modules + const natives = process.binding('natives'); + + // Get dependencies from a single file and filter + // out node native modules from the result + const dependencies = (await parseSingleFile(mainEntry, dependenciesVisitorsGenerator)) + .filter(dep => !natives[dep]); + + // Return the list of all the new entries found into + // the current mainEntry that we could use to look for + // new dependencies + return dependencies.reduce((filteredEntries, entry) => { + const absEntryPath = resolve(cwd, dirname(mainEntry), entry); + const requiredPath = canRequire(cwd, absEntryPath); + const requiredRelativePath = canRequire(cwd, entry); + const isRelativeFile = !isAbsolute(entry); + const isNodeModuleDep = isRelativeFile && !requiredPath && requiredRelativePath; + const isNewEntry = isRelativeFile && requiredPath; + + // If it is a node_module add it to the results and also + // add the resolved path for the node_module main file + // as an entry point to look for dependencies it was + // not already parsed + if (isNodeModuleDep) { + // Save the result as the top level dependency + results[_calculateTopLevelDependency(entry)] = true; + + if (!wasParsed[requiredRelativePath]) { + filteredEntries.push(requiredRelativePath); + } + } + + // If a new, not yet parsed, relative entry were found + // add it to the list of entries to be parsed + if (isNewEntry && !wasParsed[requiredPath]) { + if (!wasParsed[requiredPath]) { + filteredEntries.push(requiredPath); + } + } + + return filteredEntries; + }, []); +} diff --git a/packages/kbn-babel-code-parser/src/strategies.test.js b/packages/kbn-babel-code-parser/src/strategies.test.js new file mode 100644 index 0000000000000..5a84edf560af1 --- /dev/null +++ b/packages/kbn-babel-code-parser/src/strategies.test.js @@ -0,0 +1,96 @@ +/* + * 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 { readFile } from 'fs'; +import { canRequire } from './can_require'; +import { parseSingleFile } from './code_parser'; +import { _calculateTopLevelDependency, dependenciesParseStrategy } from './strategies'; + +jest.mock('./can_require', () => ({ + canRequire: jest.fn() +})); + +jest.mock('fs', () => ({ + readFile: jest.fn() +})); + +const mockCwd = '/tmp/project/dir/'; + +describe('Code Parser Strategies', () => { + it('should calculate the top level dependencies correctly', () => { + const plainDep = 'dep1/file'; + const foldedDep = '@kbn/es/file'; + const otherFoldedDep = '@kbn/es'; + + expect(_calculateTopLevelDependency(plainDep)).toEqual('dep1'); + expect(_calculateTopLevelDependency(foldedDep)).toEqual('@kbn/es'); + expect(_calculateTopLevelDependency(otherFoldedDep)).toEqual('@kbn/es'); + }); + + it('should exclude native modules', async () => { + readFile.mockImplementationOnce((path, options, cb) => { + cb(null, `require('fs')`); + }); + + const results = []; + await dependenciesParseStrategy(mockCwd, parseSingleFile, 'dep1/file.js', {}, results); + + expect(results.length).toBe(0); + }); + + it('should return a dep from_modules', async () => { + readFile.mockImplementationOnce((path, options, cb) => { + cb(null, `require('dep_from_node_modules')`); + }); + + canRequire.mockImplementation((mockCwd, entry) => { + if (entry === `${mockCwd}dep1/dep_from_node_modules`) { + return false; + } + + if (entry === 'dep_from_node_modules') { + return `${mockCwd}node_modules/dep_from_node_modules/index.js`; + } + }); + + const results = await dependenciesParseStrategy(mockCwd, parseSingleFile, 'dep1/file.js', {}, {}); + expect(results[0]).toBe(`${mockCwd}node_modules/dep_from_node_modules/index.js`); + }); + + it('should return a relative dep file', async () => { + readFile.mockImplementationOnce((path, options, cb) => { + cb(null, `require('./relative_dep')`); + }); + + canRequire.mockImplementation((mockCwd, entry) => { + if (entry === `${mockCwd}dep1/relative_dep`) { + return `${entry}/index.js`; + } + + return false; + }); + + const results = await dependenciesParseStrategy(mockCwd, parseSingleFile, 'dep1/file.js', {}, {}); + expect(results[0]).toBe(`${mockCwd}dep1/relative_dep/index.js`); + }); + + afterAll(() => { + jest.clearAllMocks(); + }); +}); diff --git a/packages/kbn-babel-code-parser/src/visitors.js b/packages/kbn-babel-code-parser/src/visitors.js new file mode 100644 index 0000000000000..ad93570a46d7e --- /dev/null +++ b/packages/kbn-babel-code-parser/src/visitors.js @@ -0,0 +1,142 @@ +/* + * 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 { matches } from 'lodash'; + +/** + * @notice + * + * This product has relied on ASTExplorer that is licensed under MIT. + */ +export function dependenciesVisitorsGenerator(dependenciesAcc) { + return (() => { + // This was built with help on an ast explorer and some ESTree docs + // like the babel parser ast spec and the main docs for the Esprima + // which is a complete and useful docs for the ESTree spec. + // + // https://astexplorer.net + // https://github.com/babel/babel/blob/master/packages/babel-parser/ast/spec.md + // https://esprima.readthedocs.io/en/latest/syntax-tree-format.html + // https://github.com/estree/estree + return { + // Visitors to traverse and found dependencies + // raw values on require + require.resolve + CallExpression: ({ node }) => { + // AST check for require expressions + const isRequire = (node) => { + return matches({ + callee: { + type: 'Identifier', + name: 'require' + } + })(node); + }; + + // AST check for require.resolve expressions + const isRequireResolve = (node) => { + return matches({ + callee: { + type: 'MemberExpression', + object: { + type: 'Identifier', + name: 'require' + }, + property: { + type: 'Identifier', + name: 'resolve' + } + } + })(node); + }; + + // Get string values inside the expressions + // whether they are require or require.resolve + if (isRequire(node) || isRequireResolve(node)) { + const nodeArguments = node.arguments; + const reqArg = Array.isArray(nodeArguments) ? nodeArguments.shift() : null; + + if (!reqArg) { + return; + } + + if (reqArg.type === 'StringLiteral') { + dependenciesAcc.push(reqArg.value); + } + } + }, + // Visitors to traverse and found dependencies + // raw values on import + ImportDeclaration: ({ node }) => { + // AST check for supported import expressions + const isImport = (node) => { + return matches({ + type: 'ImportDeclaration', + source: { + type: 'StringLiteral' + } + })(node); + }; + + // Get string values from import expressions + if (isImport(node)) { + const importSource = node.source; + dependenciesAcc.push(importSource.value); + } + }, + // Visitors to traverse and found dependencies + // raw values on export from + ExportNamedDeclaration: ({ node }) => { + // AST check for supported export from expressions + const isExportFrom = (node) => { + return matches({ + type: 'ExportNamedDeclaration', + source: { + type: 'StringLiteral' + } + })(node); + }; + + // Get string values from export from expressions + if (isExportFrom(node)) { + const exportFromSource = node.source; + dependenciesAcc.push(exportFromSource.value); + } + }, + // Visitors to traverse and found dependencies + // raw values on export * from + ExportAllDeclaration: ({ node }) => { + // AST check for supported export * from expressions + const isExportAllFrom = (node) => { + return matches({ + type: 'ExportAllDeclaration', + source: { + type: 'StringLiteral' + } + })(node); + }; + + // Get string values from export * from expressions + if (isExportAllFrom(node)) { + const exportAllFromSource = node.source; + dependenciesAcc.push(exportAllFromSource.value); + } + } + }; + })(); +} diff --git a/packages/kbn-babel-code-parser/src/visitors.test.js b/packages/kbn-babel-code-parser/src/visitors.test.js new file mode 100644 index 0000000000000..a8f865bda26e8 --- /dev/null +++ b/packages/kbn-babel-code-parser/src/visitors.test.js @@ -0,0 +1,68 @@ +/* + * 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 * as parser from '@babel/parser'; +import traverse from '@babel/traverse'; +import { dependenciesVisitorsGenerator } from './visitors'; + +const visitorsApplier = (code) => { + const result = []; + traverse( + parser.parse(code, { + sourceType: 'unambiguous', + plugins: ['exportDefaultFrom'] + }), + dependenciesVisitorsGenerator(result) + ); + return result; +}; + +describe('Code Parser Visitors', () => { + it('should get values from require', () => { + const rawCode = `/*foo*/require('dep1'); const bar = 1;`; + const foundDeps = visitorsApplier(rawCode); + expect(foundDeps[0] === 'dep1'); + }); + + it('should get values from require.resolve', () => { + const rawCode = `/*foo*/require.resolve('dep2'); const bar = 1;`; + const foundDeps = visitorsApplier(rawCode); + expect(foundDeps[0] === 'dep2'); + }); + + it('should get values from import', () => { + const rawCode = `/*foo*/import dep1 from 'dep1'; import dep2 from 'dep2';const bar = 1;`; + const foundDeps = visitorsApplier(rawCode); + expect(foundDeps[0] === 'dep1'); + expect(foundDeps[1] === 'dep2'); + }); + + it('should get values from export from', () => { + const rawCode = `/*foo*/export dep1 from 'dep1'; import dep2 from 'dep2';const bar = 1;`; + const foundDeps = visitorsApplier(rawCode); + expect(foundDeps[0] === 'dep1'); + }); + + it('should get values from export * from', () => { + const rawCode = `/*foo*/export * from 'dep1'; export dep2 from 'dep2';const bar = 1;`; + const foundDeps = visitorsApplier(rawCode); + expect(foundDeps[0] === 'dep1'); + expect(foundDeps[1] === 'dep2'); + }); +}); diff --git a/packages/kbn-babel-preset/common_babel_parser_options.js b/packages/kbn-babel-preset/common_babel_parser_options.js new file mode 100644 index 0000000000000..3020b919bc3a6 --- /dev/null +++ b/packages/kbn-babel-preset/common_babel_parser_options.js @@ -0,0 +1,33 @@ +/* + * 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. + */ + +// The @babel/parser options documentation can be found here: +// https://babeljs.io/docs/en/babel-parser#options +module.exports = { + sourceType: 'unambiguous', + plugins: [ + 'asyncGenerators', + 'classProperties', + 'dynamicImport', + 'exportDefaultFrom', + 'exportNamespaceFrom', + 'objectRestSpread', + 'throwExpressions' + ], +}; diff --git a/packages/kbn-babel-preset/package.json b/packages/kbn-babel-preset/package.json index 1d0a578fa1778..1309d88197e5c 100644 --- a/packages/kbn-babel-preset/package.json +++ b/packages/kbn-babel-preset/package.json @@ -9,7 +9,7 @@ "babel-plugin-transform-class-properties": "^6.24.1", "babel-plugin-transform-define": "^1.3.0", "babel-plugin-transform-object-rest-spread": "^6.26.0", - "babel-preset-env": "1.4.0", + "babel-preset-env": "^1.7.0", "babel-preset-react": "^6.24.1" } } diff --git a/packages/kbn-eslint-import-resolver-kibana/package.json b/packages/kbn-eslint-import-resolver-kibana/package.json index 9a6f506c022a6..a16cc1e128b74 100755 --- a/packages/kbn-eslint-import-resolver-kibana/package.json +++ b/packages/kbn-eslint-import-resolver-kibana/package.json @@ -14,8 +14,8 @@ "eslint-import-resolver-node": "^0.3.2", "eslint-import-resolver-webpack": "^0.10.1", "glob-all": "^3.1.0", - "lru-cache": "^4.1.2", + "lru-cache": "^4.1.3", "resolve": "^1.7.1", - "webpack": "3.6.0" + "webpack": "^4.23.1" } } diff --git a/packages/kbn-interpreter/package.json b/packages/kbn-interpreter/package.json index 3c7c1e47a74d7..1648e66cdb300 100644 --- a/packages/kbn-interpreter/package.json +++ b/packages/kbn-interpreter/package.json @@ -19,18 +19,19 @@ "@kbn/babel-preset": "1.0.0", "@kbn/dev-utils": "1.0.0", "babel-cli": "^6.26.0", - "babel-core": "^6.26.0", - "babel-loader": "7.1.2", + "babel-core": "6.26.3", + "babel-loader": "7.1.5", "babel-plugin-transform-runtime": "^6.23.0", "babel-polyfill": "6.20.0", - "css-loader": "0.28.7", + "css-loader": "1.0.0", "del": "^3.0.0", "getopts": "^2.2.3", "pegjs": "0.9.0", "sass-loader": "^7.1.0", - "style-loader": "0.19.0", + "style-loader": "0.23.1", "supports-color": "^5.5.0", - "url-loader": "0.5.9", - "webpack": "3.6.0" + "url-loader": "1.1.2", + "webpack": "4.23.1", + "webpack-cli": "^3.1.2" } } diff --git a/packages/kbn-interpreter/tasks/build/webpack.config.js b/packages/kbn-interpreter/tasks/build/webpack.config.js index 9dc9398563efd..71e0cfd733da0 100644 --- a/packages/kbn-interpreter/tasks/build/webpack.config.js +++ b/packages/kbn-interpreter/tasks/build/webpack.config.js @@ -28,6 +28,7 @@ module.exports = function ({ sourceMaps }, { watch }) { return { devtool: sourceMaps ? 'inline-cheap-module-source-map' : undefined, + mode: 'none', entry: { 'types/all': resolve(PLUGIN_SOURCE_DIR, 'types/register.js'), 'functions/common/all': resolve(PLUGIN_SOURCE_DIR, 'functions/common/register.js'), @@ -42,6 +43,16 @@ module.exports = function ({ sourceMaps }, { watch }) { path: PLUGIN_BUILD_DIR, filename: '[name].js', // Need long paths here. libraryTarget: 'umd', + // Note: this is needed due to a not yet resolved bug on + // webpack 4 with umd modules generation. + // For now we have 2 quick workarounds: one is what is implemented + // below another is to change the libraryTarget to commonjs + // + // The issues can be followed on: + // https://github.com/webpack/webpack/issues/6642 + // https://github.com/webpack/webpack/issues/6525 + // https://github.com/webpack/webpack/issues/6677 + globalObject: `(typeof self !== 'undefined' ? self : this)`, }, resolve: { @@ -84,7 +95,7 @@ module.exports = function ({ sourceMaps }, { watch }) { stats: 'errors-only', plugins: [ - function loaderFailHandler() { + function LoaderFailHandlerPlugin() { if (!watch) { return; } @@ -93,7 +104,7 @@ module.exports = function ({ sourceMaps }, { watch }) { // bails on error, including loader errors // see https://github.com/webpack/webpack/issues/708, which does not fix loader errors - this.plugin('done', function (stats) { + this.hooks.done.tapPromise('LoaderFailHandlerPlugin', async stats => { if (stats.hasErrors() || stats.hasWarnings()) { lastBuildFailed = true; return; diff --git a/packages/kbn-plugin-helpers/package.json b/packages/kbn-plugin-helpers/package.json index a460c5b922f2b..d73368338292a 100644 --- a/packages/kbn-plugin-helpers/package.json +++ b/packages/kbn-plugin-helpers/package.json @@ -18,7 +18,7 @@ "gulp-zip": "^4.1.0", "inquirer": "^1.2.2", "minimatch": "^3.0.4", - "node-sass": "^4.9.0", + "node-sass": "^4.9.4", "through2": "^2.0.3", "through2-map": "^3.0.0", "vinyl-fs": "^3.0.0" diff --git a/packages/kbn-pm/dist/index.js b/packages/kbn-pm/dist/index.js index 42c540e99f142..8d62848f49d06 100644 --- a/packages/kbn-pm/dist/index.js +++ b/packages/kbn-pm/dist/index.js @@ -37,14 +37,34 @@ module.exports = /******/ // define getter function for harmony exports /******/ __webpack_require__.d = function(exports, name, getter) { /******/ if(!__webpack_require__.o(exports, name)) { -/******/ Object.defineProperty(exports, name, { -/******/ configurable: false, -/******/ enumerable: true, -/******/ get: getter -/******/ }); +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); /******/ } /******/ }; /******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __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; +/******/ }; +/******/ /******/ // getDefaultExport function for compatibility with non-harmony modules /******/ __webpack_require__.n = function(module) { /******/ var getter = module && module.__esModule ? @@ -60,8 +80,9 @@ module.exports = /******/ // __webpack_public_path__ /******/ __webpack_require__.p = ""; /******/ +/******/ /******/ // Load entry module and return exports -/******/ return __webpack_require__(__webpack_require__.s = 136); +/******/ return __webpack_require__(__webpack_require__.s = 119); /******/ }) /************************************************************************/ /******/ ([ @@ -69,7 +90,7 @@ module.exports = /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = __extends; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return __extends; }); /* unused harmony export __assign */ /* unused harmony export __rest */ /* unused harmony export __decorate */ @@ -274,13 +295,13 @@ function __importDefault(mod) { "use strict"; /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Subscriber; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_isFunction__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Observer__ = __webpack_require__(102); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__internal_symbol_rxSubscriber__ = __webpack_require__(62); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__config__ = __webpack_require__(42); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__util_hostReportError__ = __webpack_require__(61); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _util_isFunction__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(29); +/* harmony import */ var _Observer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(55); +/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5); +/* harmony import */ var _internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(38); +/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(18); +/* harmony import */ var _util_hostReportError__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(37); /** PURE_IMPORTS_START tslib,_util_isFunction,_Observer,_Subscription,_internal_symbol_rxSubscriber,_config,_util_hostReportError PURE_IMPORTS_END */ @@ -290,7 +311,7 @@ function __importDefault(mod) { var Subscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](Subscriber, _super); + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](Subscriber, _super); function Subscriber(destinationOrNext, error, complete) { var _this = _super.call(this) || this; _this.syncErrorValue = null; @@ -299,16 +320,16 @@ var Subscriber = /*@__PURE__*/ (function (_super) { _this.isStopped = false; switch (arguments.length) { case 0: - _this.destination = __WEBPACK_IMPORTED_MODULE_2__Observer__["a" /* empty */]; + _this.destination = _Observer__WEBPACK_IMPORTED_MODULE_2__[/* empty */ "a"]; break; case 1: if (!destinationOrNext) { - _this.destination = __WEBPACK_IMPORTED_MODULE_2__Observer__["a" /* empty */]; + _this.destination = _Observer__WEBPACK_IMPORTED_MODULE_2__[/* empty */ "a"]; break; } if (typeof destinationOrNext === 'object') { if (isTrustedSubscriber(destinationOrNext)) { - var trustedSubscriber = destinationOrNext[__WEBPACK_IMPORTED_MODULE_4__internal_symbol_rxSubscriber__["a" /* rxSubscriber */]](); + var trustedSubscriber = destinationOrNext[_internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_4__[/* rxSubscriber */ "a"]](); _this.syncErrorThrowable = trustedSubscriber.syncErrorThrowable; _this.destination = trustedSubscriber; trustedSubscriber.add(_this); @@ -326,7 +347,7 @@ var Subscriber = /*@__PURE__*/ (function (_super) { } return _this; } - Subscriber.prototype[__WEBPACK_IMPORTED_MODULE_4__internal_symbol_rxSubscriber__["a" /* rxSubscriber */]] = function () { return this; }; + Subscriber.prototype[_internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_4__[/* rxSubscriber */ "a"]] = function () { return this; }; Subscriber.create = function (next, error, complete) { var subscriber = new Subscriber(next, error, complete); subscriber.syncErrorThrowable = false; @@ -379,25 +400,25 @@ var Subscriber = /*@__PURE__*/ (function (_super) { return this; }; return Subscriber; -}(__WEBPACK_IMPORTED_MODULE_3__Subscription__["a" /* Subscription */])); +}(_Subscription__WEBPACK_IMPORTED_MODULE_3__[/* Subscription */ "a"])); var SafeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SafeSubscriber, _super); + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](SafeSubscriber, _super); function SafeSubscriber(_parentSubscriber, observerOrNext, error, complete) { var _this = _super.call(this) || this; _this._parentSubscriber = _parentSubscriber; var next; var context = _this; - if (Object(__WEBPACK_IMPORTED_MODULE_1__util_isFunction__["a" /* isFunction */])(observerOrNext)) { + if (Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_1__[/* isFunction */ "a"])(observerOrNext)) { next = observerOrNext; } else if (observerOrNext) { next = observerOrNext.next; error = observerOrNext.error; complete = observerOrNext.complete; - if (observerOrNext !== __WEBPACK_IMPORTED_MODULE_2__Observer__["a" /* empty */]) { + if (observerOrNext !== _Observer__WEBPACK_IMPORTED_MODULE_2__[/* empty */ "a"]) { context = Object.create(observerOrNext); - if (Object(__WEBPACK_IMPORTED_MODULE_1__util_isFunction__["a" /* isFunction */])(context.unsubscribe)) { + if (Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_1__[/* isFunction */ "a"])(context.unsubscribe)) { _this.add(context.unsubscribe.bind(context)); } context.unsubscribe = _this.unsubscribe.bind(_this); @@ -412,7 +433,7 @@ var SafeSubscriber = /*@__PURE__*/ (function (_super) { SafeSubscriber.prototype.next = function (value) { if (!this.isStopped && this._next) { var _parentSubscriber = this._parentSubscriber; - if (!__WEBPACK_IMPORTED_MODULE_5__config__["a" /* config */].useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) { + if (!_config__WEBPACK_IMPORTED_MODULE_5__[/* config */ "a"].useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) { this.__tryOrUnsub(this._next, value); } else if (this.__tryOrSetError(_parentSubscriber, this._next, value)) { @@ -423,7 +444,7 @@ var SafeSubscriber = /*@__PURE__*/ (function (_super) { SafeSubscriber.prototype.error = function (err) { if (!this.isStopped) { var _parentSubscriber = this._parentSubscriber; - var useDeprecatedSynchronousErrorHandling = __WEBPACK_IMPORTED_MODULE_5__config__["a" /* config */].useDeprecatedSynchronousErrorHandling; + var useDeprecatedSynchronousErrorHandling = _config__WEBPACK_IMPORTED_MODULE_5__[/* config */ "a"].useDeprecatedSynchronousErrorHandling; if (this._error) { if (!useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) { this.__tryOrUnsub(this._error, err); @@ -439,7 +460,7 @@ var SafeSubscriber = /*@__PURE__*/ (function (_super) { if (useDeprecatedSynchronousErrorHandling) { throw err; } - Object(__WEBPACK_IMPORTED_MODULE_6__util_hostReportError__["a" /* hostReportError */])(err); + Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_6__[/* hostReportError */ "a"])(err); } else { if (useDeprecatedSynchronousErrorHandling) { @@ -447,7 +468,7 @@ var SafeSubscriber = /*@__PURE__*/ (function (_super) { _parentSubscriber.syncErrorThrown = true; } else { - Object(__WEBPACK_IMPORTED_MODULE_6__util_hostReportError__["a" /* hostReportError */])(err); + Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_6__[/* hostReportError */ "a"])(err); } this.unsubscribe(); } @@ -459,7 +480,7 @@ var SafeSubscriber = /*@__PURE__*/ (function (_super) { var _parentSubscriber = this._parentSubscriber; if (this._complete) { var wrappedComplete = function () { return _this._complete.call(_this._context); }; - if (!__WEBPACK_IMPORTED_MODULE_5__config__["a" /* config */].useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) { + if (!_config__WEBPACK_IMPORTED_MODULE_5__[/* config */ "a"].useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) { this.__tryOrUnsub(wrappedComplete); this.unsubscribe(); } @@ -479,29 +500,29 @@ var SafeSubscriber = /*@__PURE__*/ (function (_super) { } catch (err) { this.unsubscribe(); - if (__WEBPACK_IMPORTED_MODULE_5__config__["a" /* config */].useDeprecatedSynchronousErrorHandling) { + if (_config__WEBPACK_IMPORTED_MODULE_5__[/* config */ "a"].useDeprecatedSynchronousErrorHandling) { throw err; } else { - Object(__WEBPACK_IMPORTED_MODULE_6__util_hostReportError__["a" /* hostReportError */])(err); + Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_6__[/* hostReportError */ "a"])(err); } } }; SafeSubscriber.prototype.__tryOrSetError = function (parent, fn, value) { - if (!__WEBPACK_IMPORTED_MODULE_5__config__["a" /* config */].useDeprecatedSynchronousErrorHandling) { + if (!_config__WEBPACK_IMPORTED_MODULE_5__[/* config */ "a"].useDeprecatedSynchronousErrorHandling) { throw new Error('bad call'); } try { fn.call(this._context, value); } catch (err) { - if (__WEBPACK_IMPORTED_MODULE_5__config__["a" /* config */].useDeprecatedSynchronousErrorHandling) { + if (_config__WEBPACK_IMPORTED_MODULE_5__[/* config */ "a"].useDeprecatedSynchronousErrorHandling) { parent.syncErrorValue = err; parent.syncErrorThrown = true; return true; } else { - Object(__WEBPACK_IMPORTED_MODULE_6__util_hostReportError__["a" /* hostReportError */])(err); + Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_6__[/* hostReportError */ "a"])(err); return true; } } @@ -516,33 +537,64 @@ var SafeSubscriber = /*@__PURE__*/ (function (_super) { return SafeSubscriber; }(Subscriber)); function isTrustedSubscriber(obj) { - return obj instanceof Subscriber || ('syncErrorThrowable' in obj && obj[__WEBPACK_IMPORTED_MODULE_4__internal_symbol_rxSubscriber__["a" /* rxSubscriber */]]); + return obj instanceof Subscriber || ('syncErrorThrowable' in obj && obj[_internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_4__[/* rxSubscriber */ "a"]]); } //# sourceMappingURL=Subscriber.js.map /***/ }), /* 2 */ -/***/ (function(module, exports) { - -module.exports = require("path"); - -/***/ }), -/* 3 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Observable; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_toSubscriber__ = __webpack_require__(262); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__internal_symbol_observable__ = __webpack_require__(24); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_pipe__ = __webpack_require__(63); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__config__ = __webpack_require__(42); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subscriber.js +var Subscriber = __webpack_require__(1); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/symbol/rxSubscriber.js +var rxSubscriber = __webpack_require__(38); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Observer.js +var Observer = __webpack_require__(55); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/toSubscriber.js +/** PURE_IMPORTS_START _Subscriber,_symbol_rxSubscriber,_Observer PURE_IMPORTS_END */ + + + +function toSubscriber(nextOrObserver, error, complete) { + if (nextOrObserver) { + if (nextOrObserver instanceof Subscriber["a" /* Subscriber */]) { + return nextOrObserver; + } + if (nextOrObserver[rxSubscriber["a" /* rxSubscriber */]]) { + return nextOrObserver[rxSubscriber["a" /* rxSubscriber */]](); + } + } + if (!nextOrObserver && !error && !complete) { + return new Subscriber["a" /* Subscriber */](Observer["a" /* empty */]); + } + return new Subscriber["a" /* Subscriber */](nextOrObserver, error, complete); +} +//# sourceMappingURL=toSubscriber.js.map + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/symbol/observable.js +var observable = __webpack_require__(24); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/pipe.js +var pipe = __webpack_require__(39); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/config.js +var config = __webpack_require__(18); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Observable.js +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Observable_Observable; }); /** PURE_IMPORTS_START _util_toSubscriber,_internal_symbol_observable,_util_pipe,_config PURE_IMPORTS_END */ -var Observable = /*@__PURE__*/ (function () { +var Observable_Observable = /*@__PURE__*/ (function () { function Observable(subscribe) { this._isScalar = false; if (subscribe) { @@ -557,16 +609,16 @@ var Observable = /*@__PURE__*/ (function () { }; Observable.prototype.subscribe = function (observerOrNext, error, complete) { var operator = this.operator; - var sink = Object(__WEBPACK_IMPORTED_MODULE_0__util_toSubscriber__["a" /* toSubscriber */])(observerOrNext, error, complete); + var sink = toSubscriber(observerOrNext, error, complete); if (operator) { operator.call(sink, this.source); } else { - sink.add(this.source || (__WEBPACK_IMPORTED_MODULE_3__config__["a" /* config */].useDeprecatedSynchronousErrorHandling && !sink.syncErrorThrowable) ? + sink.add(this.source || (config["a" /* config */].useDeprecatedSynchronousErrorHandling && !sink.syncErrorThrowable) ? this._subscribe(sink) : this._trySubscribe(sink)); } - if (__WEBPACK_IMPORTED_MODULE_3__config__["a" /* config */].useDeprecatedSynchronousErrorHandling) { + if (config["a" /* config */].useDeprecatedSynchronousErrorHandling) { if (sink.syncErrorThrowable) { sink.syncErrorThrowable = false; if (sink.syncErrorThrown) { @@ -581,7 +633,7 @@ var Observable = /*@__PURE__*/ (function () { return this._subscribe(sink); } catch (err) { - if (__WEBPACK_IMPORTED_MODULE_3__config__["a" /* config */].useDeprecatedSynchronousErrorHandling) { + if (config["a" /* config */].useDeprecatedSynchronousErrorHandling) { sink.syncErrorThrown = true; sink.syncErrorValue = err; } @@ -610,7 +662,7 @@ var Observable = /*@__PURE__*/ (function () { var source = this.source; return source && source.subscribe(subscriber); }; - Observable.prototype[__WEBPACK_IMPORTED_MODULE_1__internal_symbol_observable__["a" /* observable */]] = function () { + Observable.prototype[observable["a" /* observable */]] = function () { return this; }; Observable.prototype.pipe = function () { @@ -621,7 +673,7 @@ var Observable = /*@__PURE__*/ (function () { if (operations.length === 0) { return this; } - return Object(__WEBPACK_IMPORTED_MODULE_2__util_pipe__["b" /* pipeFromArray */])(operations)(this); + return Object(pipe["b" /* pipeFromArray */])(operations)(this); }; Observable.prototype.toPromise = function (promiseCtor) { var _this = this; @@ -639,7 +691,7 @@ var Observable = /*@__PURE__*/ (function () { function getPromiseCtor(promiseCtor) { if (!promiseCtor) { - promiseCtor = __WEBPACK_IMPORTED_MODULE_3__config__["a" /* config */].Promise || Promise; + promiseCtor = config["a" /* config */].Promise || Promise; } if (!promiseCtor) { throw new Error('no Promise impl found'); @@ -649,19 +701,76 @@ function getPromiseCtor(promiseCtor) { //# sourceMappingURL=Observable.js.map +/***/ }), +/* 3 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/node_modules/tslib/tslib.es6.js +var tslib_es6 = __webpack_require__(0); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subscriber.js +var Subscriber = __webpack_require__(1); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/InnerSubscriber.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ + + +var InnerSubscriber_InnerSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](InnerSubscriber, _super); + function InnerSubscriber(parent, outerValue, outerIndex) { + var _this = _super.call(this) || this; + _this.parent = parent; + _this.outerValue = outerValue; + _this.outerIndex = outerIndex; + _this.index = 0; + return _this; + } + InnerSubscriber.prototype._next = function (value) { + this.parent.notifyNext(this.outerValue, value, this.outerIndex, this.index++, this); + }; + InnerSubscriber.prototype._error = function (error) { + this.parent.notifyError(error, this); + this.unsubscribe(); + }; + InnerSubscriber.prototype._complete = function () { + this.parent.notifyComplete(this); + this.unsubscribe(); + }; + return InnerSubscriber; +}(Subscriber["a" /* Subscriber */])); + +//# sourceMappingURL=InnerSubscriber.js.map + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/subscribeTo.js +var subscribeTo = __webpack_require__(76); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/subscribeToResult.js +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToResult; }); +/** PURE_IMPORTS_START _InnerSubscriber,_subscribeTo PURE_IMPORTS_END */ + + +function subscribeToResult(outerSubscriber, result, outerValue, outerIndex) { + var destination = new InnerSubscriber_InnerSubscriber(outerSubscriber, outerValue, outerIndex); + return Object(subscribeTo["a" /* subscribeTo */])(result)(destination); +} +//# sourceMappingURL=subscribeToResult.js.map + + /***/ }), /* 4 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return OuterSubscriber; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1); /** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ var OuterSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](OuterSubscriber, _super); + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](OuterSubscriber, _super); function OuterSubscriber() { return _super !== null && _super.apply(this, arguments) || this; } @@ -675,7 +784,7 @@ var OuterSubscriber = /*@__PURE__*/ (function (_super) { this.destination.complete(); }; return OuterSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); +}(_Subscriber__WEBPACK_IMPORTED_MODULE_1__[/* Subscriber */ "a"])); //# sourceMappingURL=OuterSubscriber.js.map @@ -684,38 +793,14 @@ var OuterSubscriber = /*@__PURE__*/ (function (_super) { /* 5 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = subscribeToResult; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__InnerSubscriber__ = __webpack_require__(276); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__subscribeTo__ = __webpack_require__(115); -/** PURE_IMPORTS_START _InnerSubscriber,_subscribeTo PURE_IMPORTS_END */ - - -function subscribeToResult(outerSubscriber, result, outerValue, outerIndex) { - var destination = new __WEBPACK_IMPORTED_MODULE_0__InnerSubscriber__["a" /* InnerSubscriber */](outerSubscriber, outerValue, outerIndex); - return Object(__WEBPACK_IMPORTED_MODULE_1__subscribeTo__["a" /* subscribeTo */])(result)(destination); -} -//# sourceMappingURL=subscribeToResult.js.map - - -/***/ }), -/* 6 */ -/***/ (function(module, exports) { - -module.exports = require("fs"); - -/***/ }), -/* 7 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - "use strict"; /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Subscription; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_isObject__ = __webpack_require__(103); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isFunction__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_UnsubscriptionError__ = __webpack_require__(104); +/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11); +/* harmony import */ var _util_isObject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(73); +/* harmony import */ var _util_isFunction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(29); +/* harmony import */ var _util_tryCatch__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(14); +/* harmony import */ var _util_errorObject__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6); +/* harmony import */ var _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(40); /** PURE_IMPORTS_START _util_isArray,_util_isObject,_util_isFunction,_util_tryCatch,_util_errorObject,_util_UnsubscriptionError PURE_IMPORTS_END */ @@ -750,26 +835,26 @@ var Subscription = /*@__PURE__*/ (function () { _parent.remove(this); _parent = ++index < len && _parents[index] || null; } - if (Object(__WEBPACK_IMPORTED_MODULE_2__util_isFunction__["a" /* isFunction */])(_unsubscribe)) { - var trial = Object(__WEBPACK_IMPORTED_MODULE_3__util_tryCatch__["a" /* tryCatch */])(_unsubscribe).call(this); - if (trial === __WEBPACK_IMPORTED_MODULE_4__util_errorObject__["a" /* errorObject */]) { + if (Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_2__[/* isFunction */ "a"])(_unsubscribe)) { + var trial = Object(_util_tryCatch__WEBPACK_IMPORTED_MODULE_3__[/* tryCatch */ "a"])(_unsubscribe).call(this); + if (trial === _util_errorObject__WEBPACK_IMPORTED_MODULE_4__[/* errorObject */ "a"]) { hasErrors = true; - errors = errors || (__WEBPACK_IMPORTED_MODULE_4__util_errorObject__["a" /* errorObject */].e instanceof __WEBPACK_IMPORTED_MODULE_5__util_UnsubscriptionError__["a" /* UnsubscriptionError */] ? - flattenUnsubscriptionErrors(__WEBPACK_IMPORTED_MODULE_4__util_errorObject__["a" /* errorObject */].e.errors) : [__WEBPACK_IMPORTED_MODULE_4__util_errorObject__["a" /* errorObject */].e]); + errors = errors || (_util_errorObject__WEBPACK_IMPORTED_MODULE_4__[/* errorObject */ "a"].e instanceof _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_5__[/* UnsubscriptionError */ "a"] ? + flattenUnsubscriptionErrors(_util_errorObject__WEBPACK_IMPORTED_MODULE_4__[/* errorObject */ "a"].e.errors) : [_util_errorObject__WEBPACK_IMPORTED_MODULE_4__[/* errorObject */ "a"].e]); } } - if (Object(__WEBPACK_IMPORTED_MODULE_0__util_isArray__["a" /* isArray */])(_subscriptions)) { + if (Object(_util_isArray__WEBPACK_IMPORTED_MODULE_0__[/* isArray */ "a"])(_subscriptions)) { index = -1; len = _subscriptions.length; while (++index < len) { var sub = _subscriptions[index]; - if (Object(__WEBPACK_IMPORTED_MODULE_1__util_isObject__["a" /* isObject */])(sub)) { - var trial = Object(__WEBPACK_IMPORTED_MODULE_3__util_tryCatch__["a" /* tryCatch */])(sub.unsubscribe).call(sub); - if (trial === __WEBPACK_IMPORTED_MODULE_4__util_errorObject__["a" /* errorObject */]) { + if (Object(_util_isObject__WEBPACK_IMPORTED_MODULE_1__[/* isObject */ "a"])(sub)) { + var trial = Object(_util_tryCatch__WEBPACK_IMPORTED_MODULE_3__[/* tryCatch */ "a"])(sub.unsubscribe).call(sub); + if (trial === _util_errorObject__WEBPACK_IMPORTED_MODULE_4__[/* errorObject */ "a"]) { hasErrors = true; errors = errors || []; - var err = __WEBPACK_IMPORTED_MODULE_4__util_errorObject__["a" /* errorObject */].e; - if (err instanceof __WEBPACK_IMPORTED_MODULE_5__util_UnsubscriptionError__["a" /* UnsubscriptionError */]) { + var err = _util_errorObject__WEBPACK_IMPORTED_MODULE_4__[/* errorObject */ "a"].e; + if (err instanceof _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_5__[/* UnsubscriptionError */ "a"]) { errors = errors.concat(flattenUnsubscriptionErrors(err.errors)); } else { @@ -780,7 +865,7 @@ var Subscription = /*@__PURE__*/ (function () { } } if (hasErrors) { - throw new __WEBPACK_IMPORTED_MODULE_5__util_UnsubscriptionError__["a" /* UnsubscriptionError */](errors); + throw new _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_5__[/* UnsubscriptionError */ "a"](errors); } }; Subscription.prototype.add = function (teardown) { @@ -845,32 +930,43 @@ var Subscription = /*@__PURE__*/ (function () { }()); function flattenUnsubscriptionErrors(errors) { - return errors.reduce(function (errs, err) { return errs.concat((err instanceof __WEBPACK_IMPORTED_MODULE_5__util_UnsubscriptionError__["a" /* UnsubscriptionError */]) ? err.errors : err); }, []); + return errors.reduce(function (errs, err) { return errs.concat((err instanceof _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_5__[/* UnsubscriptionError */ "a"]) ? err.errors : err); }, []); } //# sourceMappingURL=Subscription.js.map /***/ }), -/* 8 */ +/* 6 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return errorObject; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +var errorObject = { e: {} }; +//# sourceMappingURL=errorObject.js.map + + +/***/ }), +/* 7 */ /***/ (function(module, exports) { -module.exports = require("util"); +module.exports = require("path"); /***/ }), -/* 9 */ +/* 8 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return SubjectSubscriber; }); /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Subject; }); /* unused harmony export AnonymousSubject */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_ObjectUnsubscribedError__ = __webpack_require__(44); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__SubjectSubscription__ = __webpack_require__(106); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__internal_symbol_rxSubscriber__ = __webpack_require__(62); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2); +/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1); +/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5); +/* harmony import */ var _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(25); +/* harmony import */ var _SubjectSubscription__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(74); +/* harmony import */ var _internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(38); /** PURE_IMPORTS_START tslib,_Observable,_Subscriber,_Subscription,_util_ObjectUnsubscribedError,_SubjectSubscription,_internal_symbol_rxSubscriber PURE_IMPORTS_END */ @@ -880,17 +976,17 @@ module.exports = require("util"); var SubjectSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SubjectSubscriber, _super); + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](SubjectSubscriber, _super); function SubjectSubscriber(destination) { var _this = _super.call(this, destination) || this; _this.destination = destination; return _this; } return SubjectSubscriber; -}(__WEBPACK_IMPORTED_MODULE_2__Subscriber__["a" /* Subscriber */])); +}(_Subscriber__WEBPACK_IMPORTED_MODULE_2__[/* Subscriber */ "a"])); var Subject = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](Subject, _super); + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](Subject, _super); function Subject() { var _this = _super.call(this) || this; _this.observers = []; @@ -900,7 +996,7 @@ var Subject = /*@__PURE__*/ (function (_super) { _this.thrownError = null; return _this; } - Subject.prototype[__WEBPACK_IMPORTED_MODULE_6__internal_symbol_rxSubscriber__["a" /* rxSubscriber */]] = function () { + Subject.prototype[_internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_6__[/* rxSubscriber */ "a"]] = function () { return new SubjectSubscriber(this); }; Subject.prototype.lift = function (operator) { @@ -910,7 +1006,7 @@ var Subject = /*@__PURE__*/ (function (_super) { }; Subject.prototype.next = function (value) { if (this.closed) { - throw new __WEBPACK_IMPORTED_MODULE_4__util_ObjectUnsubscribedError__["a" /* ObjectUnsubscribedError */](); + throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_4__[/* ObjectUnsubscribedError */ "a"](); } if (!this.isStopped) { var observers = this.observers; @@ -923,7 +1019,7 @@ var Subject = /*@__PURE__*/ (function (_super) { }; Subject.prototype.error = function (err) { if (this.closed) { - throw new __WEBPACK_IMPORTED_MODULE_4__util_ObjectUnsubscribedError__["a" /* ObjectUnsubscribedError */](); + throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_4__[/* ObjectUnsubscribedError */ "a"](); } this.hasError = true; this.thrownError = err; @@ -938,7 +1034,7 @@ var Subject = /*@__PURE__*/ (function (_super) { }; Subject.prototype.complete = function () { if (this.closed) { - throw new __WEBPACK_IMPORTED_MODULE_4__util_ObjectUnsubscribedError__["a" /* ObjectUnsubscribedError */](); + throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_4__[/* ObjectUnsubscribedError */ "a"](); } this.isStopped = true; var observers = this.observers; @@ -956,7 +1052,7 @@ var Subject = /*@__PURE__*/ (function (_super) { }; Subject.prototype._trySubscribe = function (subscriber) { if (this.closed) { - throw new __WEBPACK_IMPORTED_MODULE_4__util_ObjectUnsubscribedError__["a" /* ObjectUnsubscribedError */](); + throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_4__[/* ObjectUnsubscribedError */ "a"](); } else { return _super.prototype._trySubscribe.call(this, subscriber); @@ -964,23 +1060,23 @@ var Subject = /*@__PURE__*/ (function (_super) { }; Subject.prototype._subscribe = function (subscriber) { if (this.closed) { - throw new __WEBPACK_IMPORTED_MODULE_4__util_ObjectUnsubscribedError__["a" /* ObjectUnsubscribedError */](); + throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_4__[/* ObjectUnsubscribedError */ "a"](); } else if (this.hasError) { subscriber.error(this.thrownError); - return __WEBPACK_IMPORTED_MODULE_3__Subscription__["a" /* Subscription */].EMPTY; + return _Subscription__WEBPACK_IMPORTED_MODULE_3__[/* Subscription */ "a"].EMPTY; } else if (this.isStopped) { subscriber.complete(); - return __WEBPACK_IMPORTED_MODULE_3__Subscription__["a" /* Subscription */].EMPTY; + return _Subscription__WEBPACK_IMPORTED_MODULE_3__[/* Subscription */ "a"].EMPTY; } else { this.observers.push(subscriber); - return new __WEBPACK_IMPORTED_MODULE_5__SubjectSubscription__["a" /* SubjectSubscription */](this, subscriber); + return new _SubjectSubscription__WEBPACK_IMPORTED_MODULE_5__[/* SubjectSubscription */ "a"](this, subscriber); } }; Subject.prototype.asObservable = function () { - var observable = new __WEBPACK_IMPORTED_MODULE_1__Observable__["a" /* Observable */](); + var observable = new _Observable__WEBPACK_IMPORTED_MODULE_1__[/* Observable */ "a"](); observable.source = this; return observable; }; @@ -988,10 +1084,10 @@ var Subject = /*@__PURE__*/ (function (_super) { return new AnonymousSubject(destination, source); }; return Subject; -}(__WEBPACK_IMPORTED_MODULE_1__Observable__["a" /* Observable */])); +}(_Observable__WEBPACK_IMPORTED_MODULE_1__[/* Observable */ "a"])); var AnonymousSubject = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AnonymousSubject, _super); + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](AnonymousSubject, _super); function AnonymousSubject(destination, source) { var _this = _super.call(this) || this; _this.destination = destination; @@ -1022,7 +1118,7 @@ var AnonymousSubject = /*@__PURE__*/ (function (_super) { return this.source.subscribe(subscriber); } else { - return __WEBPACK_IMPORTED_MODULE_3__Subscription__["a" /* Subscription */].EMPTY; + return _Subscription__WEBPACK_IMPORTED_MODULE_3__[/* Subscription */ "a"].EMPTY; } }; return AnonymousSubject; @@ -1032,69 +1128,58 @@ var AnonymousSubject = /*@__PURE__*/ (function (_super) { /***/ }), -/* 10 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isArray; }); -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -var isArray = Array.isArray || (function (x) { return x && typeof x.length === 'number'; }); -//# sourceMappingURL=isArray.js.map - - -/***/ }), -/* 11 */ +/* 9 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return EMPTY; }); -/* harmony export (immutable) */ __webpack_exports__["b"] = empty; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return empty; }); /* unused harmony export emptyScheduled */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2); /** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ -var EMPTY = /*@__PURE__*/ new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { return subscriber.complete(); }); +var EMPTY = /*@__PURE__*/ new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](function (subscriber) { return subscriber.complete(); }); function empty(scheduler) { return scheduler ? emptyScheduled(scheduler) : EMPTY; } function emptyScheduled(scheduler) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { return scheduler.schedule(function () { return subscriber.complete(); }); }); + return new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](function (subscriber) { return scheduler.schedule(function () { return subscriber.complete(); }); }); } //# sourceMappingURL=empty.js.map /***/ }), -/* 12 */ +/* 10 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return async; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__AsyncAction__ = __webpack_require__(30); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncScheduler__ = __webpack_require__(31); +/* harmony import */ var _AsyncAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(34); +/* harmony import */ var _AsyncScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(32); /** PURE_IMPORTS_START _AsyncAction,_AsyncScheduler PURE_IMPORTS_END */ -var async = /*@__PURE__*/ new __WEBPACK_IMPORTED_MODULE_1__AsyncScheduler__["a" /* AsyncScheduler */](__WEBPACK_IMPORTED_MODULE_0__AsyncAction__["a" /* AsyncAction */]); +var async = /*@__PURE__*/ new _AsyncScheduler__WEBPACK_IMPORTED_MODULE_1__[/* AsyncScheduler */ "a"](_AsyncAction__WEBPACK_IMPORTED_MODULE_0__[/* AsyncAction */ "a"]); //# sourceMappingURL=async.js.map /***/ }), -/* 13 */ +/* 11 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return errorObject; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isArray; }); /** PURE_IMPORTS_START PURE_IMPORTS_END */ -var errorObject = { e: {} }; -//# sourceMappingURL=errorObject.js.map +var isArray = Array.isArray || (function (x) { return x && typeof x.length === 'number'; }); +//# sourceMappingURL=isArray.js.map /***/ }), -/* 14 */ +/* 12 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isScheduler; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isScheduler; }); /** PURE_IMPORTS_START PURE_IMPORTS_END */ function isScheduler(value) { return value && typeof value.schedule === 'function'; @@ -1103,14 +1188,14 @@ function isScheduler(value) { /***/ }), -/* 15 */ +/* 13 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = map; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return map; }); /* unused harmony export MapOperator */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1); /** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ @@ -1134,7 +1219,7 @@ var MapOperator = /*@__PURE__*/ (function () { }()); var MapSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](MapSubscriber, _super); + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](MapSubscriber, _super); function MapSubscriber(destination, project, thisArg) { var _this = _super.call(this, destination) || this; _this.project = project; @@ -1154,17 +1239,17 @@ var MapSubscriber = /*@__PURE__*/ (function (_super) { this.destination.next(result); }; return MapSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); +}(_Subscriber__WEBPACK_IMPORTED_MODULE_1__[/* Subscriber */ "a"])); //# sourceMappingURL=map.js.map /***/ }), -/* 16 */ +/* 14 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = tryCatch; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__errorObject__ = __webpack_require__(13); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return tryCatch; }); +/* harmony import */ var _errorObject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6); /** PURE_IMPORTS_START _errorObject PURE_IMPORTS_END */ var tryCatchTarget; @@ -1173,8 +1258,8 @@ function tryCatcher() { return tryCatchTarget.apply(this, arguments); } catch (e) { - __WEBPACK_IMPORTED_MODULE_0__errorObject__["a" /* errorObject */].e = e; - return __WEBPACK_IMPORTED_MODULE_0__errorObject__["a" /* errorObject */]; + _errorObject__WEBPACK_IMPORTED_MODULE_0__[/* errorObject */ "a"].e = e; + return _errorObject__WEBPACK_IMPORTED_MODULE_0__[/* errorObject */ "a"]; } } function tryCatch(fn) { @@ -1185,256 +1270,171 @@ function tryCatch(fn) { /***/ }), -/* 17 */ -/***/ (function(module, exports, __webpack_require__) { +/* 15 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -const escapeStringRegexp = __webpack_require__(51); -const ansiStyles = __webpack_require__(138); -const stdoutColor = __webpack_require__(141).stdout; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Observable.js + 1 modules +var Observable = __webpack_require__(2); -const template = __webpack_require__(142); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isPromise.js +var isPromise = __webpack_require__(79); -const isSimpleWindowsTerm = process.platform === 'win32' && !(process.env.TERM || '').toLowerCase().startsWith('xterm'); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isArrayLike.js +var isArrayLike = __webpack_require__(78); -// `supportsColor.level` → `ansiStyles.color[name]` mapping -const levelMapping = ['ansi', 'ansi', 'ansi256', 'ansi16m']; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/symbol/observable.js +var symbol_observable = __webpack_require__(24); -// `color-convert` models to exclude from the Chalk API due to conflicts and such -const skipModels = new Set(['gray']); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isInteropObservable.js +/** PURE_IMPORTS_START _symbol_observable PURE_IMPORTS_END */ -const styles = Object.create(null); +function isInteropObservable(input) { + return input && typeof input[symbol_observable["a" /* observable */]] === 'function'; +} +//# sourceMappingURL=isInteropObservable.js.map -function applyOptions(obj, options) { - options = options || {}; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/symbol/iterator.js +var symbol_iterator = __webpack_require__(23); - // Detect level if not set manually - const scLevel = stdoutColor ? stdoutColor.level : 0; - obj.level = options.level === undefined ? scLevel : options.level; - obj.enabled = 'enabled' in options ? options.enabled : obj.level > 0; +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isIterable.js +/** PURE_IMPORTS_START _symbol_iterator PURE_IMPORTS_END */ + +function isIterable(input) { + return input && typeof input[symbol_iterator["a" /* iterator */]] === 'function'; } +//# sourceMappingURL=isIterable.js.map -function Chalk(options) { - // We check for this.template here since calling `chalk.constructor()` - // by itself will have a `this` of a previously constructed chalk object - if (!this || !(this instanceof Chalk) || this.template) { - const chalk = {}; - applyOptions(chalk, options); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/fromArray.js +var fromArray = __webpack_require__(17); - chalk.template = function () { - const args = [].slice.call(arguments); - return chalkTag.apply(null, [chalk.template].concat(args)); - }; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subscription.js +var Subscription = __webpack_require__(5); - Object.setPrototypeOf(chalk, Chalk.prototype); - Object.setPrototypeOf(chalk.template, chalk); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/subscribeToPromise.js +var subscribeToPromise = __webpack_require__(80); - chalk.template.constructor = Chalk; +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/fromPromise.js +/** PURE_IMPORTS_START _Observable,_Subscription,_util_subscribeToPromise PURE_IMPORTS_END */ - return chalk.template; - } - applyOptions(this, options); -} -// Use bright blue on Windows as the normal blue color is illegible -if (isSimpleWindowsTerm) { - ansiStyles.blue.open = '\u001B[94m'; +function fromPromise(input, scheduler) { + if (!scheduler) { + return new Observable["a" /* Observable */](Object(subscribeToPromise["a" /* subscribeToPromise */])(input)); + } + else { + return new Observable["a" /* Observable */](function (subscriber) { + var sub = new Subscription["a" /* Subscription */](); + sub.add(scheduler.schedule(function () { + return input.then(function (value) { + sub.add(scheduler.schedule(function () { + subscriber.next(value); + sub.add(scheduler.schedule(function () { return subscriber.complete(); })); + })); + }, function (err) { + sub.add(scheduler.schedule(function () { return subscriber.error(err); })); + }); + })); + return sub; + }); + } } +//# sourceMappingURL=fromPromise.js.map -for (const key of Object.keys(ansiStyles)) { - ansiStyles[key].closeRe = new RegExp(escapeStringRegexp(ansiStyles[key].close), 'g'); - - styles[key] = { - get() { - const codes = ansiStyles[key]; - return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, key); - } - }; -} +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/subscribeToIterable.js +var subscribeToIterable = __webpack_require__(81); -styles.visible = { - get() { - return build.call(this, this._styles || [], true, 'visible'); - } -}; +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/fromIterable.js +/** PURE_IMPORTS_START _Observable,_Subscription,_symbol_iterator,_util_subscribeToIterable PURE_IMPORTS_END */ -ansiStyles.color.closeRe = new RegExp(escapeStringRegexp(ansiStyles.color.close), 'g'); -for (const model of Object.keys(ansiStyles.color.ansi)) { - if (skipModels.has(model)) { - continue; - } - styles[model] = { - get() { - const level = this.level; - return function () { - const open = ansiStyles.color[levelMapping[level]][model].apply(null, arguments); - const codes = { - open, - close: ansiStyles.color.close, - closeRe: ansiStyles.color.closeRe - }; - return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, model); - }; - } - }; -} -ansiStyles.bgColor.closeRe = new RegExp(escapeStringRegexp(ansiStyles.bgColor.close), 'g'); -for (const model of Object.keys(ansiStyles.bgColor.ansi)) { - if (skipModels.has(model)) { - continue; - } - const bgModel = 'bg' + model[0].toUpperCase() + model.slice(1); - styles[bgModel] = { - get() { - const level = this.level; - return function () { - const open = ansiStyles.bgColor[levelMapping[level]][model].apply(null, arguments); - const codes = { - open, - close: ansiStyles.bgColor.close, - closeRe: ansiStyles.bgColor.closeRe - }; - return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, model); - }; - } - }; -} - -const proto = Object.defineProperties(() => {}, styles); - -function build(_styles, _empty, key) { - const builder = function () { - return applyStyle.apply(builder, arguments); - }; - - builder._styles = _styles; - builder._empty = _empty; - - const self = this; - - Object.defineProperty(builder, 'level', { - enumerable: true, - get() { - return self.level; - }, - set(level) { - self.level = level; - } - }); - - Object.defineProperty(builder, 'enabled', { - enumerable: true, - get() { - return self.enabled; - }, - set(enabled) { - self.enabled = enabled; - } - }); - - // See below for fix regarding invisible grey/dim combination on Windows - builder.hasGrey = this.hasGrey || key === 'gray' || key === 'grey'; - - // `__proto__` is used because we must return a function, but there is - // no way to create a function with a different prototype - builder.__proto__ = proto; // eslint-disable-line no-proto - - return builder; +function fromIterable(input, scheduler) { + if (!input) { + throw new Error('Iterable cannot be null'); + } + if (!scheduler) { + return new Observable["a" /* Observable */](Object(subscribeToIterable["a" /* subscribeToIterable */])(input)); + } + else { + return new Observable["a" /* Observable */](function (subscriber) { + var sub = new Subscription["a" /* Subscription */](); + var iterator; + sub.add(function () { + if (iterator && typeof iterator.return === 'function') { + iterator.return(); + } + }); + sub.add(scheduler.schedule(function () { + iterator = input[symbol_iterator["a" /* iterator */]](); + sub.add(scheduler.schedule(function () { + if (subscriber.closed) { + return; + } + var value; + var done; + try { + var result = iterator.next(); + value = result.value; + done = result.done; + } + catch (err) { + subscriber.error(err); + return; + } + if (done) { + subscriber.complete(); + } + else { + subscriber.next(value); + this.schedule(); + } + })); + })); + return sub; + }); + } } +//# sourceMappingURL=fromIterable.js.map -function applyStyle() { - // Support varags, but simply cast to string in case there's only one arg - const args = arguments; - const argsLen = args.length; - let str = String(arguments[0]); - - if (argsLen === 0) { - return ''; - } - - if (argsLen > 1) { - // Don't slice `arguments`, it prevents V8 optimizations - for (let a = 1; a < argsLen; a++) { - str += ' ' + args[a]; - } - } - - if (!this.enabled || this.level <= 0 || !str) { - return this._empty ? '' : str; - } - - // Turns out that on Windows dimmed gray text becomes invisible in cmd.exe, - // see https://github.com/chalk/chalk/issues/58 - // If we're on Windows and we're dealing with a gray color, temporarily make 'dim' a noop. - const originalDim = ansiStyles.dim.open; - if (isSimpleWindowsTerm && this.hasGrey) { - ansiStyles.dim.open = ''; - } - - for (const code of this._styles.slice().reverse()) { - // Replace any instances already present with a re-opening code - // otherwise only the part of the string until said closing code - // will be colored, and the rest will simply be 'plain'. - str = code.open + str.replace(code.closeRe, code.open) + code.close; - - // Close the styling before a linebreak and reopen - // after next line to fix a bleed issue on macOS - // https://github.com/chalk/chalk/pull/92 - str = str.replace(/\r?\n/g, `${code.close}$&${code.open}`); - } - - // Reset the original `dim` if we changed it to work around the Windows dimmed gray issue - ansiStyles.dim.open = originalDim; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/subscribeToObservable.js +var subscribeToObservable = __webpack_require__(77); - return str; -} +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/fromObservable.js +/** PURE_IMPORTS_START _Observable,_Subscription,_symbol_observable,_util_subscribeToObservable PURE_IMPORTS_END */ -function chalkTag(chalk, strings) { - if (!Array.isArray(strings)) { - // If chalk() was called by itself or with a string, - // return the string itself as a string. - return [].slice.call(arguments, 1).join(' '); - } - const args = [].slice.call(arguments, 2); - const parts = [strings.raw[0]]; - for (let i = 1; i < strings.length; i++) { - parts.push(String(args[i - 1]).replace(/[{}\\]/g, '\\$&')); - parts.push(String(strings.raw[i])); - } - return template(chalk, parts.join('')); +function fromObservable(input, scheduler) { + if (!scheduler) { + return new Observable["a" /* Observable */](Object(subscribeToObservable["a" /* subscribeToObservable */])(input)); + } + else { + return new Observable["a" /* Observable */](function (subscriber) { + var sub = new Subscription["a" /* Subscription */](); + sub.add(scheduler.schedule(function () { + var observable = input[symbol_observable["a" /* observable */]](); + sub.add(observable.subscribe({ + next: function (value) { sub.add(scheduler.schedule(function () { return subscriber.next(value); })); }, + error: function (err) { sub.add(scheduler.schedule(function () { return subscriber.error(err); })); }, + complete: function () { sub.add(scheduler.schedule(function () { return subscriber.complete(); })); }, + })); + })); + return sub; + }); + } } +//# sourceMappingURL=fromObservable.js.map -Object.defineProperties(Chalk.prototype, styles); - -module.exports = Chalk(); // eslint-disable-line new-cap -module.exports.supportsColor = stdoutColor; -module.exports.default = module.exports; // For TypeScript - - -/***/ }), -/* 18 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/subscribeTo.js +var subscribeTo = __webpack_require__(76); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = from; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_isPromise__ = __webpack_require__(120); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isArrayLike__ = __webpack_require__(119); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_isInteropObservable__ = __webpack_require__(277); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_isIterable__ = __webpack_require__(278); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__fromArray__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__fromPromise__ = __webpack_require__(279); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__fromIterable__ = __webpack_require__(280); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__fromObservable__ = __webpack_require__(281); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__util_subscribeTo__ = __webpack_require__(115); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/from.js +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return from; }); /** PURE_IMPORTS_START _Observable,_util_isPromise,_util_isArrayLike,_util_isInteropObservable,_util_isIterable,_fromArray,_fromPromise,_fromIterable,_fromObservable,_util_subscribeTo PURE_IMPORTS_END */ @@ -1448,23 +1448,23 @@ module.exports.default = module.exports; // For TypeScript function from(input, scheduler) { if (!scheduler) { - if (input instanceof __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */]) { + if (input instanceof Observable["a" /* Observable */]) { return input; } - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](Object(__WEBPACK_IMPORTED_MODULE_9__util_subscribeTo__["a" /* subscribeTo */])(input)); + return new Observable["a" /* Observable */](Object(subscribeTo["a" /* subscribeTo */])(input)); } if (input != null) { - if (Object(__WEBPACK_IMPORTED_MODULE_3__util_isInteropObservable__["a" /* isInteropObservable */])(input)) { - return Object(__WEBPACK_IMPORTED_MODULE_8__fromObservable__["a" /* fromObservable */])(input, scheduler); + if (isInteropObservable(input)) { + return fromObservable(input, scheduler); } - else if (Object(__WEBPACK_IMPORTED_MODULE_1__util_isPromise__["a" /* isPromise */])(input)) { - return Object(__WEBPACK_IMPORTED_MODULE_6__fromPromise__["a" /* fromPromise */])(input, scheduler); + else if (Object(isPromise["a" /* isPromise */])(input)) { + return fromPromise(input, scheduler); } - else if (Object(__WEBPACK_IMPORTED_MODULE_2__util_isArrayLike__["a" /* isArrayLike */])(input)) { - return Object(__WEBPACK_IMPORTED_MODULE_5__fromArray__["a" /* fromArray */])(input, scheduler); + else if (Object(isArrayLike["a" /* isArrayLike */])(input)) { + return Object(fromArray["a" /* fromArray */])(input, scheduler); } - else if (Object(__WEBPACK_IMPORTED_MODULE_4__util_isIterable__["a" /* isIterable */])(input) || typeof input === 'string') { - return Object(__WEBPACK_IMPORTED_MODULE_7__fromIterable__["a" /* fromIterable */])(input, scheduler); + else if (isIterable(input) || typeof input === 'string') { + return fromIterable(input, scheduler); } } throw new TypeError((input !== null && typeof input || input) + ' is not observable'); @@ -1473,65 +1473,31 @@ function from(input, scheduler) { /***/ }), -/* 19 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - +/* 16 */ +/***/ (function(module, exports) { -Object.defineProperty(exports, "__esModule", { - value: true -}); -/* - * 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. - */ -const log = exports.log = { - /** - * Log something to the console. Ideally we would use a real logger in - * kbn-pm, but that's a pretty big change for now. - * @param ...args - */ - write(...args) { - // tslint:disable no-console - console.log(...args); - } -}; +module.exports = require("fs"); /***/ }), -/* 20 */ +/* 17 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = fromArray; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToArray__ = __webpack_require__(112); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return fromArray; }); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2); +/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5); +/* harmony import */ var _util_subscribeToArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(75); /** PURE_IMPORTS_START _Observable,_Subscription,_util_subscribeToArray PURE_IMPORTS_END */ function fromArray(input, scheduler) { if (!scheduler) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToArray__["a" /* subscribeToArray */])(input)); + return new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](Object(_util_subscribeToArray__WEBPACK_IMPORTED_MODULE_2__[/* subscribeToArray */ "a"])(input)); } else { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var sub = new __WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */](); + return new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](function (subscriber) { + var sub = new _Subscription__WEBPACK_IMPORTED_MODULE_1__[/* Subscription */ "a"](); var i = 0; sub.add(scheduler.schedule(function () { if (i === input.length) { @@ -1551,2252 +1517,2305 @@ function fromArray(input, scheduler) { /***/ }), -/* 21 */ +/* 18 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return config; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +var _enable_super_gross_mode_that_will_cause_bad_things = false; +var config = { + Promise: undefined, + set useDeprecatedSynchronousErrorHandling(value) { + if (value) { + var error = /*@__PURE__*/ new Error(); + /*@__PURE__*/ console.warn('DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n' + error.stack); + } + else if (_enable_super_gross_mode_that_will_cause_bad_things) { + /*@__PURE__*/ console.log('RxJS: Back to a better error behavior. Thank you. <3'); + } + _enable_super_gross_mode_that_will_cause_bad_things = value; + }, + get useDeprecatedSynchronousErrorHandling() { + return _enable_super_gross_mode_that_will_cause_bad_things; + }, +}; +//# sourceMappingURL=config.js.map + + +/***/ }), +/* 19 */ /***/ (function(module, exports) { -module.exports = require("stream"); +module.exports = require("util"); /***/ }), -/* 22 */ -/***/ (function(module, exports, __webpack_require__) { +/* 20 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return noop; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function noop() { } +//# sourceMappingURL=noop.js.map -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.getProjects = undefined; +/***/ }), +/* 21 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -let getProjects = exports.getProjects = (() => { - var _ref = _asyncToGenerator(function* (rootPath, projectsPathsPatterns, { include = [], exclude = [] } = {}) { - const projects = new Map(); - const workspaceProjectsPaths = yield (0, _workspaces.workspacePackagePaths)(rootPath); - for (const pattern of projectsPathsPatterns) { - const pathsToProcess = yield packagesFromGlobPattern({ pattern, rootPath }); - for (const filePath of pathsToProcess) { - const projectConfigPath = normalize(filePath); - const projectDir = _path2.default.dirname(projectConfigPath); - const project = yield _project.Project.fromPath(projectDir); - if (workspaceProjectsPaths.indexOf(filePath) >= 0) { - project.isWorkspaceProject = true; - } - const excludeProject = exclude.includes(project.name) || include.length > 0 && !include.includes(project.name); - if (excludeProject) { - continue; - } - if (projects.has(project.name)) { - throw new _errors.CliError(`There are multiple projects with the same name [${project.name}]`, { - name: project.name, - paths: [project.path, projects.get(project.name).path] - }); - } - projects.set(project.name, project); - } - } - return projects; - }); +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return identity; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function identity(x) { + return x; +} +//# sourceMappingURL=identity.js.map - return function getProjects(_x, _x2) { - return _ref.apply(this, arguments); + +/***/ }), +/* 22 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Notification; }); +/* harmony import */ var _observable_empty__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9); +/* harmony import */ var _observable_of__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(47); +/* harmony import */ var _observable_throwError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(48); +/** PURE_IMPORTS_START _observable_empty,_observable_of,_observable_throwError PURE_IMPORTS_END */ + + + +var Notification = /*@__PURE__*/ (function () { + function Notification(kind, value, error) { + this.kind = kind; + this.value = value; + this.error = error; + this.hasValue = kind === 'N'; + } + Notification.prototype.observe = function (observer) { + switch (this.kind) { + case 'N': + return observer.next && observer.next(this.value); + case 'E': + return observer.error && observer.error(this.error); + case 'C': + return observer.complete && observer.complete(); + } }; -})(); + Notification.prototype.do = function (next, error, complete) { + var kind = this.kind; + switch (kind) { + case 'N': + return next && next(this.value); + case 'E': + return error && error(this.error); + case 'C': + return complete && complete(); + } + }; + Notification.prototype.accept = function (nextOrObserver, error, complete) { + if (nextOrObserver && typeof nextOrObserver.next === 'function') { + return this.observe(nextOrObserver); + } + else { + return this.do(nextOrObserver, error, complete); + } + }; + Notification.prototype.toObservable = function () { + var kind = this.kind; + switch (kind) { + case 'N': + return Object(_observable_of__WEBPACK_IMPORTED_MODULE_1__[/* of */ "a"])(this.value); + case 'E': + return Object(_observable_throwError__WEBPACK_IMPORTED_MODULE_2__[/* throwError */ "a"])(this.error); + case 'C': + return Object(_observable_empty__WEBPACK_IMPORTED_MODULE_0__[/* empty */ "b"])(); + } + throw new Error('unexpected notification kind value'); + }; + Notification.createNext = function (value) { + if (typeof value !== 'undefined') { + return new Notification('N', value); + } + return Notification.undefinedValueNotification; + }; + Notification.createError = function (err) { + return new Notification('E', undefined, err); + }; + Notification.createComplete = function () { + return Notification.completeNotification; + }; + Notification.completeNotification = new Notification('C'); + Notification.undefinedValueNotification = new Notification('N', undefined); + return Notification; +}()); -exports.buildProjectGraph = buildProjectGraph; -exports.topologicallyBatchProjects = topologicallyBatchProjects; -exports.includeTransitiveProjects = includeTransitiveProjects; +//# sourceMappingURL=Notification.js.map -var _glob = __webpack_require__(23); -var _glob2 = _interopRequireDefault(_glob); +/***/ }), +/* 23 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* unused harmony export getSymbolIterator */ +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return iterator; }); +/* unused harmony export $$iterator */ +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function getSymbolIterator() { + if (typeof Symbol !== 'function' || !Symbol.iterator) { + return '@@iterator'; + } + return Symbol.iterator; +} +var iterator = /*@__PURE__*/ getSymbolIterator(); +var $$iterator = iterator; +//# sourceMappingURL=iterator.js.map -var _path = __webpack_require__(2); -var _path2 = _interopRequireDefault(_path); +/***/ }), +/* 24 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -var _util = __webpack_require__(8); +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return observable; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +var observable = typeof Symbol === 'function' && Symbol.observable || '@@observable'; +//# sourceMappingURL=observable.js.map -var _errors = __webpack_require__(57); -var _project = __webpack_require__(86); +/***/ }), +/* 25 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -var _workspaces = __webpack_require__(97); +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ObjectUnsubscribedError; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +var ObjectUnsubscribedError = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](ObjectUnsubscribedError, _super); + function ObjectUnsubscribedError() { + var _this = _super.call(this, 'object unsubscribed') || this; + _this.name = 'ObjectUnsubscribedError'; + Object.setPrototypeOf(_this, ObjectUnsubscribedError.prototype); + return _this; + } + return ObjectUnsubscribedError; +}(Error)); -function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* - * 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. - */ +//# sourceMappingURL=ObjectUnsubscribedError.js.map -const glob = (0, _util.promisify)(_glob2.default); +/***/ }), +/* 26 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -function packagesFromGlobPattern({ pattern, rootPath }) { - const globOptions = { - cwd: rootPath, - // Should throw in case of unusual errors when reading the file system - strict: true, - // Always returns absolute paths for matched files - absolute: true, - // Do not match ** against multiple filenames - // (This is only specified because we currently don't have a need for it.) - noglobstar: true - }; - return glob(_path2.default.join(pattern, 'package.json'), globOptions); -} -// https://github.com/isaacs/node-glob/blob/master/common.js#L104 -// glob always returns "\\" as "/" in windows, so everyone -// gets normalized because we can't have nice things. -function normalize(dir) { - return _path2.default.normalize(dir); +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return concat; }); +/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(12); +/* harmony import */ var _of__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(47); +/* harmony import */ var _from__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(15); +/* harmony import */ var _operators_concatAll__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(68); +/** PURE_IMPORTS_START _util_isScheduler,_of,_from,_operators_concatAll PURE_IMPORTS_END */ + + + + +function concat() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i] = arguments[_i]; + } + if (observables.length === 1 || (observables.length === 2 && Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_0__[/* isScheduler */ "a"])(observables[1]))) { + return Object(_from__WEBPACK_IMPORTED_MODULE_2__[/* from */ "a"])(observables[0]); + } + return Object(_operators_concatAll__WEBPACK_IMPORTED_MODULE_3__[/* concatAll */ "a"])()(_of__WEBPACK_IMPORTED_MODULE_1__[/* of */ "a"].apply(void 0, observables)); } -function buildProjectGraph(projects) { - const projectGraph = new Map(); - for (const project of projects.values()) { - const projectDeps = []; - const dependencies = project.allDependencies; - for (const depName of Object.keys(dependencies)) { - if (projects.has(depName)) { - const dep = projects.get(depName); - const dependentProjectIsInWorkspace = project.isWorkspaceProject || project.json.name === 'kibana'; - project.ensureValidProjectDependency(dep, dependentProjectIsInWorkspace); - projectDeps.push(dep); - } - } - projectGraph.set(project.name, projectDeps); +//# sourceMappingURL=concat.js.map + + +/***/ }), +/* 27 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return mergeMap; }); +/* unused harmony export MergeMapOperator */ +/* unused harmony export MergeMapSubscriber */ +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3); +/* harmony import */ var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4); +/* harmony import */ var _map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(13); +/* harmony import */ var _observable_from__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(15); +/** PURE_IMPORTS_START tslib,_util_subscribeToResult,_OuterSubscriber,_map,_observable_from PURE_IMPORTS_END */ + + + + + +function mergeMap(project, resultSelector, concurrent) { + if (concurrent === void 0) { + concurrent = Number.POSITIVE_INFINITY; } - return projectGraph; + if (typeof resultSelector === 'function') { + return function (source) { return source.pipe(mergeMap(function (a, i) { return Object(_observable_from__WEBPACK_IMPORTED_MODULE_4__[/* from */ "a"])(project(a, i)).pipe(Object(_map__WEBPACK_IMPORTED_MODULE_3__[/* map */ "a"])(function (b, ii) { return resultSelector(a, b, i, ii); })); }, concurrent)); }; + } + else if (typeof resultSelector === 'number') { + concurrent = resultSelector; + } + return function (source) { return source.lift(new MergeMapOperator(project, concurrent)); }; } -function topologicallyBatchProjects(projectsToBatch, projectGraph, { batchByWorkspace = false } = {}) { - // We're going to be chopping stuff out of this list, so copy it. - const projectsLeftToBatch = new Set(projectsToBatch.keys()); - const batches = []; - if (batchByWorkspace) { - const workspaceRootProject = Array.from(projectsToBatch.values()).find(p => p.isWorkspaceRoot); - if (!workspaceRootProject) { - throw new _errors.CliError(`There was no yarn workspace root found.`); +var MergeMapOperator = /*@__PURE__*/ (function () { + function MergeMapOperator(project, concurrent) { + if (concurrent === void 0) { + concurrent = Number.POSITIVE_INFINITY; } - // Push in the workspace root first. - batches.push([workspaceRootProject]); - projectsLeftToBatch.delete(workspaceRootProject.name); - // In the next batch, push in all workspace projects. - const workspaceBatch = []; - for (const projectName of projectsLeftToBatch) { - const project = projectsToBatch.get(projectName); - if (project.isWorkspaceProject) { - workspaceBatch.push(project); - projectsLeftToBatch.delete(projectName); - } + this.project = project; + this.concurrent = concurrent; + } + MergeMapOperator.prototype.call = function (observer, source) { + return source.subscribe(new MergeMapSubscriber(observer, this.project, this.concurrent)); + }; + return MergeMapOperator; +}()); + +var MergeMapSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](MergeMapSubscriber, _super); + function MergeMapSubscriber(destination, project, concurrent) { + if (concurrent === void 0) { + concurrent = Number.POSITIVE_INFINITY; } - batches.push(workspaceBatch); + var _this = _super.call(this, destination) || this; + _this.project = project; + _this.concurrent = concurrent; + _this.hasCompleted = false; + _this.buffer = []; + _this.active = 0; + _this.index = 0; + return _this; } - while (projectsLeftToBatch.size > 0) { - // Get all projects that have no remaining dependencies within the repo - // that haven't yet been picked. - const batch = []; - for (const projectName of projectsLeftToBatch) { - const projectDeps = projectGraph.get(projectName); - const needsDependenciesBatched = projectDeps.some(dep => projectsLeftToBatch.has(dep.name)); - if (!needsDependenciesBatched) { - batch.push(projectsToBatch.get(projectName)); - } + MergeMapSubscriber.prototype._next = function (value) { + if (this.active < this.concurrent) { + this._tryNext(value); } - // If we weren't able to find a project with no remaining dependencies, - // then we've encountered a cycle in the dependency graph. - const hasCycles = batch.length === 0; - if (hasCycles) { - const cycleProjectNames = [...projectsLeftToBatch]; - const message = 'Encountered a cycle in the dependency graph. Projects in cycle are:\n' + cycleProjectNames.join(', '); - throw new _errors.CliError(message); + else { + this.buffer.push(value); } - batches.push(batch); - batch.forEach(project => projectsLeftToBatch.delete(project.name)); - } - return batches; -} -function includeTransitiveProjects(subsetOfProjects, allProjects, { onlyProductionDependencies = false } = {}) { - const dependentProjects = new Map(); - // the current list of packages we are expanding using breadth-first-search - const toProcess = [...subsetOfProjects]; - while (toProcess.length > 0) { - const project = toProcess.shift(); - const dependencies = onlyProductionDependencies ? project.productionDependencies : project.allDependencies; - Object.keys(dependencies).forEach(dep => { - if (allProjects.has(dep)) { - toProcess.push(allProjects.get(dep)); - } - }); - dependentProjects.set(project.name, project); - } - return dependentProjects; -} + }; + MergeMapSubscriber.prototype._tryNext = function (value) { + var result; + var index = this.index++; + try { + result = this.project(value, index); + } + catch (err) { + this.destination.error(err); + return; + } + this.active++; + this._innerSub(result, value, index); + }; + MergeMapSubscriber.prototype._innerSub = function (ish, value, index) { + this.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__[/* subscribeToResult */ "a"])(this, ish, value, index)); + }; + MergeMapSubscriber.prototype._complete = function () { + this.hasCompleted = true; + if (this.active === 0 && this.buffer.length === 0) { + this.destination.complete(); + } + }; + MergeMapSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.destination.next(innerValue); + }; + MergeMapSubscriber.prototype.notifyComplete = function (innerSub) { + var buffer = this.buffer; + this.remove(innerSub); + this.active--; + if (buffer.length > 0) { + this._next(buffer.shift()); + } + else if (this.active === 0 && this.hasCompleted) { + this.destination.complete(); + } + }; + return MergeMapSubscriber; +}(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__[/* OuterSubscriber */ "a"])); -/***/ }), -/* 23 */ -/***/ (function(module, exports, __webpack_require__) { +//# sourceMappingURL=mergeMap.js.map -// Approach: -// -// 1. Get the minimatch set -// 2. For each pattern in the set, PROCESS(pattern, false) -// 3. Store matches per-set, then uniq them -// -// PROCESS(pattern, inGlobStar) -// Get the first [n] items from pattern that are all strings -// Join these together. This is PREFIX. -// If there is no more remaining, then stat(PREFIX) and -// add to matches if it succeeds. END. -// -// If inGlobStar and PREFIX is symlink and points to dir -// set ENTRIES = [] -// else readdir(PREFIX) as ENTRIES -// If fail, END -// -// with ENTRIES -// If pattern[n] is GLOBSTAR -// // handle the case where the globstar match is empty -// // by pruning it out, and testing the resulting pattern -// PROCESS(pattern[0..n] + pattern[n+1 .. $], false) -// // handle other cases. -// for ENTRY in ENTRIES (not dotfiles) -// // attach globstar + tail onto the entry -// // Mark that this entry is a globstar match -// PROCESS(pattern[0..n] + ENTRY + pattern[n .. $], true) -// -// else // not globstar -// for ENTRY in ENTRIES (not dotfiles, unless pattern[n] is dot) -// Test ENTRY against pattern[n] -// If fails, continue -// If passes, PROCESS(pattern[0..n] + item + pattern[n+1 .. $]) -// -// Caveat: -// Cache all stats and readdirs results to minimize syscall. Since all -// we ever care about is existence and directory-ness, we can just keep -// `true` for files, and [children,...] for directories, or `false` for -// things that don't exist. -module.exports = glob +/***/ }), +/* 28 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -var fs = __webpack_require__(6) -var rp = __webpack_require__(81) -var minimatch = __webpack_require__(55) -var Minimatch = minimatch.Minimatch -var inherits = __webpack_require__(82) -var EE = __webpack_require__(40).EventEmitter -var path = __webpack_require__(2) -var assert = __webpack_require__(28) -var isAbsolute = __webpack_require__(56) -var globSync = __webpack_require__(158) -var common = __webpack_require__(83) -var alphasort = common.alphasort -var alphasorti = common.alphasorti -var setopts = common.setopts -var ownProp = common.ownProp -var inflight = __webpack_require__(159) -var util = __webpack_require__(8) -var childrenIgnored = common.childrenIgnored -var isIgnored = common.isIgnored +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ArgumentOutOfRangeError; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ -var once = __webpack_require__(85) +var ArgumentOutOfRangeError = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](ArgumentOutOfRangeError, _super); + function ArgumentOutOfRangeError() { + var _this = _super.call(this, 'argument out of range') || this; + _this.name = 'ArgumentOutOfRangeError'; + Object.setPrototypeOf(_this, ArgumentOutOfRangeError.prototype); + return _this; + } + return ArgumentOutOfRangeError; +}(Error)); -function glob (pattern, options, cb) { - if (typeof options === 'function') cb = options, options = {} - if (!options) options = {} +//# sourceMappingURL=ArgumentOutOfRangeError.js.map - if (options.sync) { - if (cb) - throw new TypeError('callback provided to sync glob') - return globSync(pattern, options) - } - return new Glob(pattern, options, cb) +/***/ }), +/* 29 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isFunction; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function isFunction(x) { + return typeof x === 'function'; } +//# sourceMappingURL=isFunction.js.map -glob.sync = globSync -var GlobSync = glob.GlobSync = globSync.GlobSync -// old api surface -glob.glob = glob +/***/ }), +/* 30 */ +/***/ (function(module, exports, __webpack_require__) { -function extend (origin, add) { - if (add === null || typeof add !== 'object') { - return origin - } +"use strict"; - var keys = Object.keys(add) - var i = keys.length - while (i--) { - origin[keys[i]] = add[keys[i]] - } - return origin -} +const escapeStringRegexp = __webpack_require__(82); +const ansiStyles = __webpack_require__(121); +const stdoutColor = __webpack_require__(124).stdout; -glob.hasMagic = function (pattern, options_) { - var options = extend({}, options_) - options.noprocess = true +const template = __webpack_require__(125); - var g = new Glob(pattern, options) - var set = g.minimatch.set +const isSimpleWindowsTerm = process.platform === 'win32' && !(process.env.TERM || '').toLowerCase().startsWith('xterm'); - if (!pattern) - return false +// `supportsColor.level` → `ansiStyles.color[name]` mapping +const levelMapping = ['ansi', 'ansi', 'ansi256', 'ansi16m']; - if (set.length > 1) - return true +// `color-convert` models to exclude from the Chalk API due to conflicts and such +const skipModels = new Set(['gray']); - for (var j = 0; j < set[0].length; j++) { - if (typeof set[0][j] !== 'string') - return true - } +const styles = Object.create(null); - return false +function applyOptions(obj, options) { + options = options || {}; + + // Detect level if not set manually + const scLevel = stdoutColor ? stdoutColor.level : 0; + obj.level = options.level === undefined ? scLevel : options.level; + obj.enabled = 'enabled' in options ? options.enabled : obj.level > 0; } -glob.Glob = Glob -inherits(Glob, EE) -function Glob (pattern, options, cb) { - if (typeof options === 'function') { - cb = options - options = null - } - - if (options && options.sync) { - if (cb) - throw new TypeError('callback provided to sync glob') - return new GlobSync(pattern, options) - } +function Chalk(options) { + // We check for this.template here since calling `chalk.constructor()` + // by itself will have a `this` of a previously constructed chalk object + if (!this || !(this instanceof Chalk) || this.template) { + const chalk = {}; + applyOptions(chalk, options); - if (!(this instanceof Glob)) - return new Glob(pattern, options, cb) + chalk.template = function () { + const args = [].slice.call(arguments); + return chalkTag.apply(null, [chalk.template].concat(args)); + }; - setopts(this, pattern, options) - this._didRealPath = false + Object.setPrototypeOf(chalk, Chalk.prototype); + Object.setPrototypeOf(chalk.template, chalk); - // process each pattern in the minimatch set - var n = this.minimatch.set.length + chalk.template.constructor = Chalk; - // The matches are stored as {: true,...} so that - // duplicates are automagically pruned. - // Later, we do an Object.keys() on these. - // Keep them as a list so we can fill in when nonull is set. - this.matches = new Array(n) + return chalk.template; + } - if (typeof cb === 'function') { - cb = once(cb) - this.on('error', cb) - this.on('end', function (matches) { - cb(null, matches) - }) - } + applyOptions(this, options); +} - var self = this - this._processing = 0 +// Use bright blue on Windows as the normal blue color is illegible +if (isSimpleWindowsTerm) { + ansiStyles.blue.open = '\u001B[94m'; +} - this._emitQueue = [] - this._processQueue = [] - this.paused = false +for (const key of Object.keys(ansiStyles)) { + ansiStyles[key].closeRe = new RegExp(escapeStringRegexp(ansiStyles[key].close), 'g'); - if (this.noprocess) - return this + styles[key] = { + get() { + const codes = ansiStyles[key]; + return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, key); + } + }; +} - if (n === 0) - return done() +styles.visible = { + get() { + return build.call(this, this._styles || [], true, 'visible'); + } +}; - var sync = true - for (var i = 0; i < n; i ++) { - this._process(this.minimatch.set[i], i, false, done) - } - sync = false +ansiStyles.color.closeRe = new RegExp(escapeStringRegexp(ansiStyles.color.close), 'g'); +for (const model of Object.keys(ansiStyles.color.ansi)) { + if (skipModels.has(model)) { + continue; + } - function done () { - --self._processing - if (self._processing <= 0) { - if (sync) { - process.nextTick(function () { - self._finish() - }) - } else { - self._finish() - } - } - } + styles[model] = { + get() { + const level = this.level; + return function () { + const open = ansiStyles.color[levelMapping[level]][model].apply(null, arguments); + const codes = { + open, + close: ansiStyles.color.close, + closeRe: ansiStyles.color.closeRe + }; + return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, model); + }; + } + }; } -Glob.prototype._finish = function () { - assert(this instanceof Glob) - if (this.aborted) - return - - if (this.realpath && !this._didRealpath) - return this._realpath() +ansiStyles.bgColor.closeRe = new RegExp(escapeStringRegexp(ansiStyles.bgColor.close), 'g'); +for (const model of Object.keys(ansiStyles.bgColor.ansi)) { + if (skipModels.has(model)) { + continue; + } - common.finish(this) - this.emit('end', this.found) + const bgModel = 'bg' + model[0].toUpperCase() + model.slice(1); + styles[bgModel] = { + get() { + const level = this.level; + return function () { + const open = ansiStyles.bgColor[levelMapping[level]][model].apply(null, arguments); + const codes = { + open, + close: ansiStyles.bgColor.close, + closeRe: ansiStyles.bgColor.closeRe + }; + return build.call(this, this._styles ? this._styles.concat(codes) : [codes], this._empty, model); + }; + } + }; } -Glob.prototype._realpath = function () { - if (this._didRealpath) - return - - this._didRealpath = true +const proto = Object.defineProperties(() => {}, styles); - var n = this.matches.length - if (n === 0) - return this._finish() +function build(_styles, _empty, key) { + const builder = function () { + return applyStyle.apply(builder, arguments); + }; - var self = this - for (var i = 0; i < this.matches.length; i++) - this._realpathSet(i, next) + builder._styles = _styles; + builder._empty = _empty; - function next () { - if (--n === 0) - self._finish() - } -} + const self = this; -Glob.prototype._realpathSet = function (index, cb) { - var matchset = this.matches[index] - if (!matchset) - return cb() + Object.defineProperty(builder, 'level', { + enumerable: true, + get() { + return self.level; + }, + set(level) { + self.level = level; + } + }); - var found = Object.keys(matchset) - var self = this - var n = found.length + Object.defineProperty(builder, 'enabled', { + enumerable: true, + get() { + return self.enabled; + }, + set(enabled) { + self.enabled = enabled; + } + }); - if (n === 0) - return cb() + // See below for fix regarding invisible grey/dim combination on Windows + builder.hasGrey = this.hasGrey || key === 'gray' || key === 'grey'; - var set = this.matches[index] = Object.create(null) - found.forEach(function (p, i) { - // If there's a problem with the stat, then it means that - // one or more of the links in the realpath couldn't be - // resolved. just return the abs value in that case. - p = self._makeAbs(p) - rp.realpath(p, self.realpathCache, function (er, real) { - if (!er) - set[real] = true - else if (er.syscall === 'stat') - set[p] = true - else - self.emit('error', er) // srsly wtf right here + // `__proto__` is used because we must return a function, but there is + // no way to create a function with a different prototype + builder.__proto__ = proto; // eslint-disable-line no-proto - if (--n === 0) { - self.matches[index] = set - cb() - } - }) - }) + return builder; } -Glob.prototype._mark = function (p) { - return common.mark(this, p) -} +function applyStyle() { + // Support varags, but simply cast to string in case there's only one arg + const args = arguments; + const argsLen = args.length; + let str = String(arguments[0]); -Glob.prototype._makeAbs = function (f) { - return common.makeAbs(this, f) -} + if (argsLen === 0) { + return ''; + } -Glob.prototype.abort = function () { - this.aborted = true - this.emit('abort') -} + if (argsLen > 1) { + // Don't slice `arguments`, it prevents V8 optimizations + for (let a = 1; a < argsLen; a++) { + str += ' ' + args[a]; + } + } -Glob.prototype.pause = function () { - if (!this.paused) { - this.paused = true - this.emit('pause') - } -} + if (!this.enabled || this.level <= 0 || !str) { + return this._empty ? '' : str; + } -Glob.prototype.resume = function () { - if (this.paused) { - this.emit('resume') - this.paused = false - if (this._emitQueue.length) { - var eq = this._emitQueue.slice(0) - this._emitQueue.length = 0 - for (var i = 0; i < eq.length; i ++) { - var e = eq[i] - this._emitMatch(e[0], e[1]) - } - } - if (this._processQueue.length) { - var pq = this._processQueue.slice(0) - this._processQueue.length = 0 - for (var i = 0; i < pq.length; i ++) { - var p = pq[i] - this._processing-- - this._process(p[0], p[1], p[2], p[3]) - } - } - } -} + // Turns out that on Windows dimmed gray text becomes invisible in cmd.exe, + // see https://github.com/chalk/chalk/issues/58 + // If we're on Windows and we're dealing with a gray color, temporarily make 'dim' a noop. + const originalDim = ansiStyles.dim.open; + if (isSimpleWindowsTerm && this.hasGrey) { + ansiStyles.dim.open = ''; + } -Glob.prototype._process = function (pattern, index, inGlobStar, cb) { - assert(this instanceof Glob) - assert(typeof cb === 'function') + for (const code of this._styles.slice().reverse()) { + // Replace any instances already present with a re-opening code + // otherwise only the part of the string until said closing code + // will be colored, and the rest will simply be 'plain'. + str = code.open + str.replace(code.closeRe, code.open) + code.close; - if (this.aborted) - return + // Close the styling before a linebreak and reopen + // after next line to fix a bleed issue on macOS + // https://github.com/chalk/chalk/pull/92 + str = str.replace(/\r?\n/g, `${code.close}$&${code.open}`); + } - this._processing++ - if (this.paused) { - this._processQueue.push([pattern, index, inGlobStar, cb]) - return - } + // Reset the original `dim` if we changed it to work around the Windows dimmed gray issue + ansiStyles.dim.open = originalDim; - //console.error('PROCESS %d', this._processing, pattern) + return str; +} - // Get the first [n] parts of pattern that are all strings. - var n = 0 - while (typeof pattern[n] === 'string') { - n ++ - } - // now n is the index of the first one that is *not* a string. +function chalkTag(chalk, strings) { + if (!Array.isArray(strings)) { + // If chalk() was called by itself or with a string, + // return the string itself as a string. + return [].slice.call(arguments, 1).join(' '); + } - // see if there's anything else - var prefix - switch (n) { - // if not, then this is rather simple - case pattern.length: - this._processSimple(pattern.join('/'), index, cb) - return + const args = [].slice.call(arguments, 2); + const parts = [strings.raw[0]]; - case 0: - // pattern *starts* with some non-trivial item. - // going to readdir(cwd), but not include the prefix in matches. - prefix = null - break + for (let i = 1; i < strings.length; i++) { + parts.push(String(args[i - 1]).replace(/[{}\\]/g, '\\$&')); + parts.push(String(strings.raw[i])); + } - default: - // pattern has some string bits in the front. - // whatever it starts with, whether that's 'absolute' like /foo/bar, - // or 'relative' like '../baz' - prefix = pattern.slice(0, n).join('/') - break - } + return template(chalk, parts.join('')); +} - var remain = pattern.slice(n) +Object.defineProperties(Chalk.prototype, styles); - // get the list of entries. - var read - if (prefix === null) - read = '.' - else if (isAbsolute(prefix) || isAbsolute(pattern.join('/'))) { - if (!prefix || !isAbsolute(prefix)) - prefix = '/' + prefix - read = prefix - } else - read = prefix +module.exports = Chalk(); // eslint-disable-line new-cap +module.exports.supportsColor = stdoutColor; +module.exports.default = module.exports; // For TypeScript - var abs = this._makeAbs(read) - //if ignored, skip _processing - if (childrenIgnored(this, read)) - return cb() +/***/ }), +/* 31 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - var isGlobStar = remain[0] === minimatch.GLOBSTAR - if (isGlobStar) - this._processGlobStar(prefix, read, abs, remain, index, inGlobStar, cb) - else - this._processReaddir(prefix, read, abs, remain, index, inGlobStar, cb) -} +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return EmptyError; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ -Glob.prototype._processReaddir = function (prefix, read, abs, remain, index, inGlobStar, cb) { - var self = this - this._readdir(abs, inGlobStar, function (er, entries) { - return self._processReaddir2(prefix, read, abs, remain, index, inGlobStar, entries, cb) - }) -} +var EmptyError = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](EmptyError, _super); + function EmptyError() { + var _this = _super.call(this, 'no elements in sequence') || this; + _this.name = 'EmptyError'; + Object.setPrototypeOf(_this, EmptyError.prototype); + return _this; + } + return EmptyError; +}(Error)); -Glob.prototype._processReaddir2 = function (prefix, read, abs, remain, index, inGlobStar, entries, cb) { +//# sourceMappingURL=EmptyError.js.map - // if the abs isn't a dir, then nothing can match! - if (!entries) - return cb() - // It will only match dot entries if it starts with a dot, or if - // dot is set. Stuff like @(.foo|.bar) isn't allowed. - var pn = remain[0] - var negate = !!this.minimatch.negate - var rawGlob = pn._glob - var dotOk = this.dot || rawGlob.charAt(0) === '.' +/***/ }), +/* 32 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - var matchedEntries = [] - for (var i = 0; i < entries.length; i++) { - var e = entries[i] - if (e.charAt(0) !== '.' || dotOk) { - var m - if (negate && !prefix) { - m = !e.match(pn) - } else { - m = e.match(pn) - } - if (m) - matchedEntries.push(e) +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AsyncScheduler; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Scheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(58); +/** PURE_IMPORTS_START tslib,_Scheduler PURE_IMPORTS_END */ + + +var AsyncScheduler = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](AsyncScheduler, _super); + function AsyncScheduler(SchedulerAction, now) { + if (now === void 0) { + now = _Scheduler__WEBPACK_IMPORTED_MODULE_1__[/* Scheduler */ "a"].now; + } + var _this = _super.call(this, SchedulerAction, function () { + if (AsyncScheduler.delegate && AsyncScheduler.delegate !== _this) { + return AsyncScheduler.delegate.now(); + } + else { + return now(); + } + }) || this; + _this.actions = []; + _this.active = false; + _this.scheduled = undefined; + return _this; } - } + AsyncScheduler.prototype.schedule = function (work, delay, state) { + if (delay === void 0) { + delay = 0; + } + if (AsyncScheduler.delegate && AsyncScheduler.delegate !== this) { + return AsyncScheduler.delegate.schedule(work, delay, state); + } + else { + return _super.prototype.schedule.call(this, work, delay, state); + } + }; + AsyncScheduler.prototype.flush = function (action) { + var actions = this.actions; + if (this.active) { + actions.push(action); + return; + } + var error; + this.active = true; + do { + if (error = action.execute(action.state, action.delay)) { + break; + } + } while (action = actions.shift()); + this.active = false; + if (error) { + while (action = actions.shift()) { + action.unsubscribe(); + } + throw error; + } + }; + return AsyncScheduler; +}(_Scheduler__WEBPACK_IMPORTED_MODULE_1__[/* Scheduler */ "a"])); - //console.error('prd2', prefix, entries, remain[0]._glob, matchedEntries) +//# sourceMappingURL=AsyncScheduler.js.map - var len = matchedEntries.length - // If there are no matched entries, then nothing matches. - if (len === 0) - return cb() - // if this is the last remaining pattern bit, then no need for - // an additional stat *unless* the user has specified mark or - // stat explicitly. We know they exist, since readdir returned - // them. +/***/ }), +/* 33 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - if (remain.length === 1 && !this.mark && !this.stat) { - if (!this.matches[index]) - this.matches[index] = Object.create(null) +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AsyncSubject; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8); +/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5); +/** PURE_IMPORTS_START tslib,_Subject,_Subscription PURE_IMPORTS_END */ - for (var i = 0; i < len; i ++) { - var e = matchedEntries[i] - if (prefix) { - if (prefix !== '/') - e = prefix + '/' + e - else - e = prefix + e - } - if (e.charAt(0) === '/' && !this.nomount) { - e = path.join(this.root, e) - } - this._emitMatch(index, e) - } - // This was the last one, and no stats were needed - return cb() - } - // now test all matched entries as stand-ins for that part - // of the pattern. - remain.shift() - for (var i = 0; i < len; i ++) { - var e = matchedEntries[i] - var newPattern - if (prefix) { - if (prefix !== '/') - e = prefix + '/' + e - else - e = prefix + e +var AsyncSubject = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](AsyncSubject, _super); + function AsyncSubject() { + var _this = _super !== null && _super.apply(this, arguments) || this; + _this.value = null; + _this.hasNext = false; + _this.hasCompleted = false; + return _this; } - this._process([e].concat(remain), index, inGlobStar, cb) - } - cb() -} + AsyncSubject.prototype._subscribe = function (subscriber) { + if (this.hasError) { + subscriber.error(this.thrownError); + return _Subscription__WEBPACK_IMPORTED_MODULE_2__[/* Subscription */ "a"].EMPTY; + } + else if (this.hasCompleted && this.hasNext) { + subscriber.next(this.value); + subscriber.complete(); + return _Subscription__WEBPACK_IMPORTED_MODULE_2__[/* Subscription */ "a"].EMPTY; + } + return _super.prototype._subscribe.call(this, subscriber); + }; + AsyncSubject.prototype.next = function (value) { + if (!this.hasCompleted) { + this.value = value; + this.hasNext = true; + } + }; + AsyncSubject.prototype.error = function (error) { + if (!this.hasCompleted) { + _super.prototype.error.call(this, error); + } + }; + AsyncSubject.prototype.complete = function () { + this.hasCompleted = true; + if (this.hasNext) { + _super.prototype.next.call(this, this.value); + } + _super.prototype.complete.call(this); + }; + return AsyncSubject; +}(_Subject__WEBPACK_IMPORTED_MODULE_1__[/* Subject */ "a"])); -Glob.prototype._emitMatch = function (index, e) { - if (this.aborted) - return +//# sourceMappingURL=AsyncSubject.js.map - if (isIgnored(this, e)) - return - if (this.paused) { - this._emitQueue.push([index, e]) - return - } +/***/ }), +/* 34 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - var abs = isAbsolute(e) ? e : this._makeAbs(e) +"use strict"; - if (this.mark) - e = this._mark(e) +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/node_modules/tslib/tslib.es6.js +var tslib_es6 = __webpack_require__(0); - if (this.absolute) - e = abs +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subscription.js +var Subscription = __webpack_require__(5); - if (this.matches[index][e]) - return +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/Action.js +/** PURE_IMPORTS_START tslib,_Subscription PURE_IMPORTS_END */ - if (this.nodir) { - var c = this.cache[abs] - if (c === 'DIR' || Array.isArray(c)) - return - } - this.matches[index][e] = true +var Action_Action = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](Action, _super); + function Action(scheduler, work) { + return _super.call(this) || this; + } + Action.prototype.schedule = function (state, delay) { + if (delay === void 0) { + delay = 0; + } + return this; + }; + return Action; +}(Subscription["a" /* Subscription */])); - var st = this.statCache[abs] - if (st) - this.emit('stat', e, st) +//# sourceMappingURL=Action.js.map - this.emit('match', e) -} +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsyncAction.js +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AsyncAction_AsyncAction; }); +/** PURE_IMPORTS_START tslib,_Action PURE_IMPORTS_END */ -Glob.prototype._readdirInGlobStar = function (abs, cb) { - if (this.aborted) - return - // follow all symlinked directories forever - // just proceed as if this is a non-globstar situation - if (this.follow) - return this._readdir(abs, false, cb) +var AsyncAction_AsyncAction = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](AsyncAction, _super); + function AsyncAction(scheduler, work) { + var _this = _super.call(this, scheduler, work) || this; + _this.scheduler = scheduler; + _this.work = work; + _this.pending = false; + return _this; + } + AsyncAction.prototype.schedule = function (state, delay) { + if (delay === void 0) { + delay = 0; + } + if (this.closed) { + return this; + } + this.state = state; + var id = this.id; + var scheduler = this.scheduler; + if (id != null) { + this.id = this.recycleAsyncId(scheduler, id, delay); + } + this.pending = true; + this.delay = delay; + this.id = this.id || this.requestAsyncId(scheduler, this.id, delay); + return this; + }; + AsyncAction.prototype.requestAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; + } + return setInterval(scheduler.flush.bind(scheduler, this), delay); + }; + AsyncAction.prototype.recycleAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; + } + if (delay !== null && this.delay === delay && this.pending === false) { + return id; + } + return clearInterval(id) && undefined || undefined; + }; + AsyncAction.prototype.execute = function (state, delay) { + if (this.closed) { + return new Error('executing a cancelled action'); + } + this.pending = false; + var error = this._execute(state, delay); + if (error) { + return error; + } + else if (this.pending === false && this.id != null) { + this.id = this.recycleAsyncId(this.scheduler, this.id, null); + } + }; + AsyncAction.prototype._execute = function (state, delay) { + var errored = false; + var errorValue = undefined; + try { + this.work(state); + } + catch (e) { + errored = true; + errorValue = !!e && e || new Error(e); + } + if (errored) { + this.unsubscribe(); + return errorValue; + } + }; + AsyncAction.prototype._unsubscribe = function () { + var id = this.id; + var scheduler = this.scheduler; + var actions = scheduler.actions; + var index = actions.indexOf(this); + this.work = null; + this.state = null; + this.pending = false; + this.scheduler = null; + if (index !== -1) { + actions.splice(index, 1); + } + if (id != null) { + this.id = this.recycleAsyncId(scheduler, id, null); + } + this.delay = null; + }; + return AsyncAction; +}(Action_Action)); - var lstatkey = 'lstat\0' + abs - var self = this - var lstatcb = inflight(lstatkey, lstatcb_) +//# sourceMappingURL=AsyncAction.js.map - if (lstatcb) - fs.lstat(abs, lstatcb) - function lstatcb_ (er, lstat) { - if (er && er.code === 'ENOENT') - return cb() +/***/ }), +/* 35 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - var isSym = lstat && lstat.isSymbolicLink() - self.symlinks[abs] = isSym +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isNumeric; }); +/* harmony import */ var _isArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11); +/** PURE_IMPORTS_START _isArray PURE_IMPORTS_END */ - // If it's not a symlink or a dir, then it's definitely a regular file. - // don't bother doing a readdir in that case. - if (!isSym && lstat && !lstat.isDirectory()) { - self.cache[abs] = 'FILE' - cb() - } else - self._readdir(abs, false, cb) - } +function isNumeric(val) { + return !Object(_isArray__WEBPACK_IMPORTED_MODULE_0__[/* isArray */ "a"])(val) && (val - parseFloat(val) + 1) >= 0; } +//# sourceMappingURL=isNumeric.js.map -Glob.prototype._readdir = function (abs, inGlobStar, cb) { - if (this.aborted) - return - cb = inflight('readdir\0'+abs+'\0'+inGlobStar, cb) - if (!cb) - return +/***/ }), +/* 36 */ +/***/ (function(module, exports, __webpack_require__) { - //console.error('RD %j %j', +inGlobStar, abs) - if (inGlobStar && !ownProp(this.symlinks, abs)) - return this._readdirInGlobStar(abs, cb) +"use strict"; - if (ownProp(this.cache, abs)) { - var c = this.cache[abs] - if (!c || c === 'FILE') - return cb() - if (Array.isArray(c)) - return cb(null, c) +Object.defineProperty(exports, "__esModule", { + value: true +}); +/* + * 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. + */ +const log = exports.log = { + /** + * Log something to the console. Ideally we would use a real logger in + * kbn-pm, but that's a pretty big change for now. + * @param ...args + */ + write(...args) { + // tslint:disable no-console + console.log(...args); } +}; - var self = this - fs.readdir(abs, readdirCb(this, abs, cb)) -} +/***/ }), +/* 37 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -function readdirCb (self, abs, cb) { - return function (er, entries) { - if (er) - self._readdirError(abs, er, cb) - else - self._readdirEntries(abs, entries, cb) - } +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return hostReportError; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function hostReportError(err) { + setTimeout(function () { throw err; }); } +//# sourceMappingURL=hostReportError.js.map -Glob.prototype._readdirEntries = function (abs, entries, cb) { - if (this.aborted) - return - - // if we haven't asked to stat everything, then just - // assume that everything in there exists, so we can avoid - // having to stat it a second time. - if (!this.mark && !this.stat) { - for (var i = 0; i < entries.length; i ++) { - var e = entries[i] - if (abs === '/') - e = abs + e - else - e = abs + '/' + e - this.cache[e] = true - } - } - this.cache[abs] = entries - return cb(null, entries) -} +/***/ }), +/* 38 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -Glob.prototype._readdirError = function (f, er, cb) { - if (this.aborted) - return +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return rxSubscriber; }); +/* unused harmony export $$rxSubscriber */ +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +var rxSubscriber = (typeof Symbol === 'function' && typeof Symbol.for === 'function') + ? /*@__PURE__*/ Symbol.for('rxSubscriber') + : '@@rxSubscriber'; +var $$rxSubscriber = rxSubscriber; +//# sourceMappingURL=rxSubscriber.js.map - // handle errors, and cache the information - switch (er.code) { - case 'ENOTSUP': // https://github.com/isaacs/node-glob/issues/205 - case 'ENOTDIR': // totally normal. means it *does* exist. - var abs = this._makeAbs(f) - this.cache[abs] = 'FILE' - if (abs === this.cwdAbs) { - var error = new Error(er.code + ' invalid cwd ' + this.cwd) - error.path = this.cwd - error.code = er.code - this.emit('error', error) - this.abort() - } - break - case 'ENOENT': // not terribly unusual - case 'ELOOP': - case 'ENAMETOOLONG': - case 'UNKNOWN': - this.cache[this._makeAbs(f)] = false - break +/***/ }), +/* 39 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - default: // some unusual error. Treat as failure. - this.cache[this._makeAbs(f)] = false - if (this.strict) { - this.emit('error', er) - // If the error is handled, then we abort - // if not, we threw out of here - this.abort() - } - if (!this.silent) - console.error('glob error', er) - break - } +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return pipe; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return pipeFromArray; }); +/* harmony import */ var _noop__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(20); +/** PURE_IMPORTS_START _noop PURE_IMPORTS_END */ - return cb() +function pipe() { + var fns = []; + for (var _i = 0; _i < arguments.length; _i++) { + fns[_i] = arguments[_i]; + } + return pipeFromArray(fns); } - -Glob.prototype._processGlobStar = function (prefix, read, abs, remain, index, inGlobStar, cb) { - var self = this - this._readdir(abs, inGlobStar, function (er, entries) { - self._processGlobStar2(prefix, read, abs, remain, index, inGlobStar, entries, cb) - }) +function pipeFromArray(fns) { + if (!fns) { + return _noop__WEBPACK_IMPORTED_MODULE_0__[/* noop */ "a"]; + } + if (fns.length === 1) { + return fns[0]; + } + return function piped(input) { + return fns.reduce(function (prev, fn) { return fn(prev); }, input); + }; } +//# sourceMappingURL=pipe.js.map -Glob.prototype._processGlobStar2 = function (prefix, read, abs, remain, index, inGlobStar, entries, cb) { - //console.error('pgs2', prefix, remain[0], entries) +/***/ }), +/* 40 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - // no entries means not a dir, so it can never have matches - // foo.txt/** doesn't match foo.txt - if (!entries) - return cb() +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return UnsubscriptionError; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ - // test without the globstar, and with every child both below - // and replacing the globstar. - var remainWithoutGlobStar = remain.slice(1) - var gspref = prefix ? [ prefix ] : [] - var noGlobStar = gspref.concat(remainWithoutGlobStar) +var UnsubscriptionError = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](UnsubscriptionError, _super); + function UnsubscriptionError(errors) { + var _this = _super.call(this, errors ? + errors.length + " errors occurred during unsubscription:\n " + errors.map(function (err, i) { return i + 1 + ") " + err.toString(); }).join('\n ') : '') || this; + _this.errors = errors; + _this.name = 'UnsubscriptionError'; + Object.setPrototypeOf(_this, UnsubscriptionError.prototype); + return _this; + } + return UnsubscriptionError; +}(Error)); - // the noGlobStar pattern exits the inGlobStar state - this._process(noGlobStar, index, false, cb) +//# sourceMappingURL=UnsubscriptionError.js.map - var isSym = this.symlinks[abs] - var len = entries.length - // If it's a symlink, and we're in a globstar, then stop - if (isSym && inGlobStar) - return cb() +/***/ }), +/* 41 */ +/***/ (function(module, exports) { - for (var i = 0; i < len; i++) { - var e = entries[i] - if (e.charAt(0) === '.' && !this.dot) - continue +module.exports = require("stream"); - // these two cases enter the inGlobStar state - var instead = gspref.concat(entries[i], remainWithoutGlobStar) - this._process(instead, index, true, cb) +/***/ }), +/* 42 */ +/***/ (function(module, exports, __webpack_require__) { - var below = gspref.concat(entries[i], remain) - this._process(below, index, true, cb) - } +"use strict"; - cb() -} -Glob.prototype._processSimple = function (prefix, index, cb) { - // XXX review this. Shouldn't it be doing the mounting etc - // before doing stat? kinda weird? - var self = this - this._stat(prefix, function (er, exists) { - self._processSimple2(prefix, index, er, exists, cb) - }) -} -Glob.prototype._processSimple2 = function (prefix, index, er, exists, cb) { +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.getProjects = undefined; - //console.error('ps2', prefix, exists) +let getProjects = exports.getProjects = (() => { + var _ref = _asyncToGenerator(function* (rootPath, projectsPathsPatterns, { include = [], exclude = [] } = {}) { + const projects = new Map(); + const workspaceProjectsPaths = yield (0, _workspaces.workspacePackagePaths)(rootPath); + for (const pattern of projectsPathsPatterns) { + const pathsToProcess = yield packagesFromGlobPattern({ pattern, rootPath }); + for (const filePath of pathsToProcess) { + const projectConfigPath = normalize(filePath); + const projectDir = _path2.default.dirname(projectConfigPath); + const project = yield _project.Project.fromPath(projectDir); + if (workspaceProjectsPaths.indexOf(filePath) >= 0) { + project.isWorkspaceProject = true; + } + const excludeProject = exclude.includes(project.name) || include.length > 0 && !include.includes(project.name); + if (excludeProject) { + continue; + } + if (projects.has(project.name)) { + throw new _errors.CliError(`There are multiple projects with the same name [${project.name}]`, { + name: project.name, + paths: [project.path, projects.get(project.name).path] + }); + } + projects.set(project.name, project); + } + } + return projects; + }); - if (!this.matches[index]) - this.matches[index] = Object.create(null) + return function getProjects(_x, _x2) { + return _ref.apply(this, arguments); + }; +})(); - // If it doesn't exist, then just mark the lack of results - if (!exists) - return cb() +exports.buildProjectGraph = buildProjectGraph; +exports.topologicallyBatchProjects = topologicallyBatchProjects; +exports.includeTransitiveProjects = includeTransitiveProjects; - if (prefix && isAbsolute(prefix) && !this.nomount) { - var trail = /[\/\\]$/.test(prefix) - if (prefix.charAt(0) === '/') { - prefix = path.join(this.root, prefix) - } else { - prefix = path.resolve(this.root, prefix) - if (trail) - prefix += '/' - } - } +var _glob = __webpack_require__(43); - if (process.platform === 'win32') - prefix = prefix.replace(/\\/g, '/') +var _glob2 = _interopRequireDefault(_glob); - // Mark this as a match - this._emitMatch(index, prefix) - cb() -} +var _path = __webpack_require__(7); -// Returns either 'DIR', 'FILE', or false -Glob.prototype._stat = function (f, cb) { - var abs = this._makeAbs(f) - var needDir = f.slice(-1) === '/' +var _path2 = _interopRequireDefault(_path); - if (f.length > this.maxLength) - return cb() +var _util = __webpack_require__(19); - if (!this.stat && ownProp(this.cache, abs)) { - var c = this.cache[abs] +var _errors = __webpack_require__(88); - if (Array.isArray(c)) - c = 'DIR' +var _project = __webpack_require__(101); - // It exists, but maybe not how we need it - if (!needDir || c === 'DIR') - return cb(null, c) +var _workspaces = __webpack_require__(112); - if (needDir && c === 'FILE') - return cb() +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - // otherwise we have to stat, because maybe c=true - // if we know it exists, but not what it is. - } +function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* + * 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. + */ - var exists - var stat = this.statCache[abs] - if (stat !== undefined) { - if (stat === false) - return cb(null, stat) - else { - var type = stat.isDirectory() ? 'DIR' : 'FILE' - if (needDir && type === 'FILE') - return cb() - else - return cb(null, type, stat) - } - } - var self = this - var statcb = inflight('stat\0' + abs, lstatcb_) - if (statcb) - fs.lstat(abs, statcb) +const glob = (0, _util.promisify)(_glob2.default); - function lstatcb_ (er, lstat) { - if (lstat && lstat.isSymbolicLink()) { - // If it's a symlink, then treat it as the target, unless - // the target does not exist, then treat it as a file. - return fs.stat(abs, function (er, stat) { - if (er) - self._stat2(f, abs, null, lstat, cb) - else - self._stat2(f, abs, er, stat, cb) - }) - } else { - self._stat2(f, abs, er, lstat, cb) +function packagesFromGlobPattern({ pattern, rootPath }) { + const globOptions = { + cwd: rootPath, + // Should throw in case of unusual errors when reading the file system + strict: true, + // Always returns absolute paths for matched files + absolute: true, + // Do not match ** against multiple filenames + // (This is only specified because we currently don't have a need for it.) + noglobstar: true + }; + return glob(_path2.default.join(pattern, 'package.json'), globOptions); +} +// https://github.com/isaacs/node-glob/blob/master/common.js#L104 +// glob always returns "\\" as "/" in windows, so everyone +// gets normalized because we can't have nice things. +function normalize(dir) { + return _path2.default.normalize(dir); +} +function buildProjectGraph(projects) { + const projectGraph = new Map(); + for (const project of projects.values()) { + const projectDeps = []; + const dependencies = project.allDependencies; + for (const depName of Object.keys(dependencies)) { + if (projects.has(depName)) { + const dep = projects.get(depName); + const dependentProjectIsInWorkspace = project.isWorkspaceProject || project.json.name === 'kibana'; + project.ensureValidProjectDependency(dep, dependentProjectIsInWorkspace); + projectDeps.push(dep); + } + } + projectGraph.set(project.name, projectDeps); } - } + return projectGraph; +} +function topologicallyBatchProjects(projectsToBatch, projectGraph, { batchByWorkspace = false } = {}) { + // We're going to be chopping stuff out of this list, so copy it. + const projectsLeftToBatch = new Set(projectsToBatch.keys()); + const batches = []; + if (batchByWorkspace) { + const workspaceRootProject = Array.from(projectsToBatch.values()).find(p => p.isWorkspaceRoot); + if (!workspaceRootProject) { + throw new _errors.CliError(`There was no yarn workspace root found.`); + } + // Push in the workspace root first. + batches.push([workspaceRootProject]); + projectsLeftToBatch.delete(workspaceRootProject.name); + // In the next batch, push in all workspace projects. + const workspaceBatch = []; + for (const projectName of projectsLeftToBatch) { + const project = projectsToBatch.get(projectName); + if (project.isWorkspaceProject) { + workspaceBatch.push(project); + projectsLeftToBatch.delete(projectName); + } + } + batches.push(workspaceBatch); + } + while (projectsLeftToBatch.size > 0) { + // Get all projects that have no remaining dependencies within the repo + // that haven't yet been picked. + const batch = []; + for (const projectName of projectsLeftToBatch) { + const projectDeps = projectGraph.get(projectName); + const needsDependenciesBatched = projectDeps.some(dep => projectsLeftToBatch.has(dep.name)); + if (!needsDependenciesBatched) { + batch.push(projectsToBatch.get(projectName)); + } + } + // If we weren't able to find a project with no remaining dependencies, + // then we've encountered a cycle in the dependency graph. + const hasCycles = batch.length === 0; + if (hasCycles) { + const cycleProjectNames = [...projectsLeftToBatch]; + const message = 'Encountered a cycle in the dependency graph. Projects in cycle are:\n' + cycleProjectNames.join(', '); + throw new _errors.CliError(message); + } + batches.push(batch); + batch.forEach(project => projectsLeftToBatch.delete(project.name)); + } + return batches; +} +function includeTransitiveProjects(subsetOfProjects, allProjects, { onlyProductionDependencies = false } = {}) { + const dependentProjects = new Map(); + // the current list of packages we are expanding using breadth-first-search + const toProcess = [...subsetOfProjects]; + while (toProcess.length > 0) { + const project = toProcess.shift(); + const dependencies = onlyProductionDependencies ? project.productionDependencies : project.allDependencies; + Object.keys(dependencies).forEach(dep => { + if (allProjects.has(dep)) { + toProcess.push(allProjects.get(dep)); + } + }); + dependentProjects.set(project.name, project); + } + return dependentProjects; } -Glob.prototype._stat2 = function (f, abs, er, stat, cb) { - if (er && (er.code === 'ENOENT' || er.code === 'ENOTDIR')) { - this.statCache[abs] = false - return cb() - } +/***/ }), +/* 43 */ +/***/ (function(module, exports, __webpack_require__) { - var needDir = f.slice(-1) === '/' - this.statCache[abs] = stat +// Approach: +// +// 1. Get the minimatch set +// 2. For each pattern in the set, PROCESS(pattern, false) +// 3. Store matches per-set, then uniq them +// +// PROCESS(pattern, inGlobStar) +// Get the first [n] items from pattern that are all strings +// Join these together. This is PREFIX. +// If there is no more remaining, then stat(PREFIX) and +// add to matches if it succeeds. END. +// +// If inGlobStar and PREFIX is symlink and points to dir +// set ENTRIES = [] +// else readdir(PREFIX) as ENTRIES +// If fail, END +// +// with ENTRIES +// If pattern[n] is GLOBSTAR +// // handle the case where the globstar match is empty +// // by pruning it out, and testing the resulting pattern +// PROCESS(pattern[0..n] + pattern[n+1 .. $], false) +// // handle other cases. +// for ENTRY in ENTRIES (not dotfiles) +// // attach globstar + tail onto the entry +// // Mark that this entry is a globstar match +// PROCESS(pattern[0..n] + ENTRY + pattern[n .. $], true) +// +// else // not globstar +// for ENTRY in ENTRIES (not dotfiles, unless pattern[n] is dot) +// Test ENTRY against pattern[n] +// If fails, continue +// If passes, PROCESS(pattern[0..n] + item + pattern[n+1 .. $]) +// +// Caveat: +// Cache all stats and readdirs results to minimize syscall. Since all +// we ever care about is existence and directory-ness, we can just keep +// `true` for files, and [children,...] for directories, or `false` for +// things that don't exist. - if (abs.slice(-1) === '/' && stat && !stat.isDirectory()) - return cb(null, false, stat) +module.exports = glob - var c = true - if (stat) - c = stat.isDirectory() ? 'DIR' : 'FILE' - this.cache[abs] = this.cache[abs] || c +var fs = __webpack_require__(16) +var rp = __webpack_require__(96) +var minimatch = __webpack_require__(86) +var Minimatch = minimatch.Minimatch +var inherits = __webpack_require__(97) +var EE = __webpack_require__(61).EventEmitter +var path = __webpack_require__(7) +var assert = __webpack_require__(57) +var isAbsolute = __webpack_require__(87) +var globSync = __webpack_require__(141) +var common = __webpack_require__(98) +var alphasort = common.alphasort +var alphasorti = common.alphasorti +var setopts = common.setopts +var ownProp = common.ownProp +var inflight = __webpack_require__(142) +var util = __webpack_require__(19) +var childrenIgnored = common.childrenIgnored +var isIgnored = common.isIgnored - if (needDir && c === 'FILE') - return cb() +var once = __webpack_require__(100) - return cb(null, c, stat) -} +function glob (pattern, options, cb) { + if (typeof options === 'function') cb = options, options = {} + if (!options) options = {} + if (options.sync) { + if (cb) + throw new TypeError('callback provided to sync glob') + return globSync(pattern, options) + } -/***/ }), -/* 24 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + return new Glob(pattern, options, cb) +} -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return observable; }); -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -var observable = typeof Symbol === 'function' && Symbol.observable || '@@observable'; -//# sourceMappingURL=observable.js.map +glob.sync = globSync +var GlobSync = glob.GlobSync = globSync.GlobSync +// old api surface +glob.glob = glob -/***/ }), -/* 25 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +function extend (origin, add) { + if (add === null || typeof add !== 'object') { + return origin + } -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = identity; -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function identity(x) { - return x; + var keys = Object.keys(add) + var i = keys.length + while (i--) { + origin[keys[i]] = add[keys[i]] + } + return origin } -//# sourceMappingURL=identity.js.map +glob.hasMagic = function (pattern, options_) { + var options = extend({}, options_) + options.noprocess = true -/***/ }), -/* 26 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + var g = new Glob(pattern, options) + var set = g.minimatch.set -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = multicast; -/* unused harmony export MulticastOperator */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_ConnectableObservable__ = __webpack_require__(105); -/** PURE_IMPORTS_START _observable_ConnectableObservable PURE_IMPORTS_END */ + if (!pattern) + return false -function multicast(subjectOrSubjectFactory, selector) { - return function multicastOperatorFunction(source) { - var subjectFactory; - if (typeof subjectOrSubjectFactory === 'function') { - subjectFactory = subjectOrSubjectFactory; - } - else { - subjectFactory = function subjectFactory() { - return subjectOrSubjectFactory; - }; - } - if (typeof selector === 'function') { - return source.lift(new MulticastOperator(subjectFactory, selector)); - } - var connectable = Object.create(source, __WEBPACK_IMPORTED_MODULE_0__observable_ConnectableObservable__["b" /* connectableObservableDescriptor */]); - connectable.source = source; - connectable.subjectFactory = subjectFactory; - return connectable; - }; -} -var MulticastOperator = /*@__PURE__*/ (function () { - function MulticastOperator(subjectFactory, selector) { - this.subjectFactory = subjectFactory; - this.selector = selector; - } - MulticastOperator.prototype.call = function (subscriber, source) { - var selector = this.selector; - var subject = this.subjectFactory(); - var subscription = selector(subject).subscribe(subscriber); - subscription.add(source.subscribe(subject)); - return subscription; - }; - return MulticastOperator; -}()); + if (set.length > 1) + return true -//# sourceMappingURL=multicast.js.map + for (var j = 0; j < set[0].length; j++) { + if (typeof set[0][j] !== 'string') + return true + } + return false +} -/***/ }), -/* 27 */ -/***/ (function(module, exports, __webpack_require__) { +glob.Glob = Glob +inherits(Glob, EE) +function Glob (pattern, options, cb) { + if (typeof options === 'function') { + cb = options + options = null + } -var fs = __webpack_require__(6) -var polyfills = __webpack_require__(149) -var legacy = __webpack_require__(151) -var queue = [] + if (options && options.sync) { + if (cb) + throw new TypeError('callback provided to sync glob') + return new GlobSync(pattern, options) + } -var util = __webpack_require__(8) + if (!(this instanceof Glob)) + return new Glob(pattern, options, cb) -function noop () {} + setopts(this, pattern, options) + this._didRealPath = false -var debug = noop -if (util.debuglog) - debug = util.debuglog('gfs4') -else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || '')) - debug = function() { - var m = util.format.apply(util, arguments) - m = 'GFS4: ' + m.split(/\n/).join('\nGFS4: ') - console.error(m) - } + // process each pattern in the minimatch set + var n = this.minimatch.set.length -if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || '')) { - process.on('exit', function() { - debug(queue) - __webpack_require__(28).equal(queue.length, 0) - }) -} + // The matches are stored as {: true,...} so that + // duplicates are automagically pruned. + // Later, we do an Object.keys() on these. + // Keep them as a list so we can fill in when nonull is set. + this.matches = new Array(n) -module.exports = patch(__webpack_require__(79)) -if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH) { - module.exports = patch(fs) -} + if (typeof cb === 'function') { + cb = once(cb) + this.on('error', cb) + this.on('end', function (matches) { + cb(null, matches) + }) + } -// Always patch fs.close/closeSync, because we want to -// retry() whenever a close happens *anywhere* in the program. -// This is essential when multiple graceful-fs instances are -// in play at the same time. -module.exports.close = -fs.close = (function (fs$close) { return function (fd, cb) { - return fs$close.call(fs, fd, function (err) { - if (!err) - retry() + var self = this + this._processing = 0 - if (typeof cb === 'function') - cb.apply(this, arguments) - }) -}})(fs.close) + this._emitQueue = [] + this._processQueue = [] + this.paused = false -module.exports.closeSync = -fs.closeSync = (function (fs$closeSync) { return function (fd) { - // Note that graceful-fs also retries when fs.closeSync() fails. - // Looks like a bug to me, although it's probably a harmless one. - var rval = fs$closeSync.apply(fs, arguments) - retry() - return rval -}})(fs.closeSync) + if (this.noprocess) + return this -function patch (fs) { - // Everything that references the open() function needs to be in here - polyfills(fs) - fs.gracefulify = patch - fs.FileReadStream = ReadStream; // Legacy name. - fs.FileWriteStream = WriteStream; // Legacy name. - fs.createReadStream = createReadStream - fs.createWriteStream = createWriteStream - var fs$readFile = fs.readFile - fs.readFile = readFile - function readFile (path, options, cb) { - if (typeof options === 'function') - cb = options, options = null + if (n === 0) + return done() - return go$readFile(path, options, cb) + var sync = true + for (var i = 0; i < n; i ++) { + this._process(this.minimatch.set[i], i, false, done) + } + sync = false - function go$readFile (path, options, cb) { - return fs$readFile(path, options, function (err) { - if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) - enqueue([go$readFile, [path, options, cb]]) - else { - if (typeof cb === 'function') - cb.apply(this, arguments) - retry() - } - }) + function done () { + --self._processing + if (self._processing <= 0) { + if (sync) { + process.nextTick(function () { + self._finish() + }) + } else { + self._finish() + } } } +} - var fs$writeFile = fs.writeFile - fs.writeFile = writeFile - function writeFile (path, data, options, cb) { - if (typeof options === 'function') - cb = options, options = null +Glob.prototype._finish = function () { + assert(this instanceof Glob) + if (this.aborted) + return - return go$writeFile(path, data, options, cb) + if (this.realpath && !this._didRealpath) + return this._realpath() - function go$writeFile (path, data, options, cb) { - return fs$writeFile(path, data, options, function (err) { - if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) - enqueue([go$writeFile, [path, data, options, cb]]) - else { - if (typeof cb === 'function') - cb.apply(this, arguments) - retry() - } - }) - } - } + common.finish(this) + this.emit('end', this.found) +} - var fs$appendFile = fs.appendFile - if (fs$appendFile) - fs.appendFile = appendFile - function appendFile (path, data, options, cb) { - if (typeof options === 'function') - cb = options, options = null +Glob.prototype._realpath = function () { + if (this._didRealpath) + return - return go$appendFile(path, data, options, cb) + this._didRealpath = true - function go$appendFile (path, data, options, cb) { - return fs$appendFile(path, data, options, function (err) { - if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) - enqueue([go$appendFile, [path, data, options, cb]]) - else { - if (typeof cb === 'function') - cb.apply(this, arguments) - retry() - } - }) - } - } + var n = this.matches.length + if (n === 0) + return this._finish() - var fs$readdir = fs.readdir - fs.readdir = readdir - function readdir (path, options, cb) { - var args = [path] - if (typeof options !== 'function') { - args.push(options) - } else { - cb = options - } - args.push(go$readdir$cb) + var self = this + for (var i = 0; i < this.matches.length; i++) + this._realpathSet(i, next) - return go$readdir(args) + function next () { + if (--n === 0) + self._finish() + } +} - function go$readdir$cb (err, files) { - if (files && files.sort) - files.sort() +Glob.prototype._realpathSet = function (index, cb) { + var matchset = this.matches[index] + if (!matchset) + return cb() - if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) - enqueue([go$readdir, [args]]) - else { - if (typeof cb === 'function') - cb.apply(this, arguments) - retry() - } - } - } - - function go$readdir (args) { - return fs$readdir.apply(fs, args) - } - - if (process.version.substr(0, 4) === 'v0.8') { - var legStreams = legacy(fs) - ReadStream = legStreams.ReadStream - WriteStream = legStreams.WriteStream - } + var found = Object.keys(matchset) + var self = this + var n = found.length - var fs$ReadStream = fs.ReadStream - ReadStream.prototype = Object.create(fs$ReadStream.prototype) - ReadStream.prototype.open = ReadStream$open + if (n === 0) + return cb() - var fs$WriteStream = fs.WriteStream - WriteStream.prototype = Object.create(fs$WriteStream.prototype) - WriteStream.prototype.open = WriteStream$open + var set = this.matches[index] = Object.create(null) + found.forEach(function (p, i) { + // If there's a problem with the stat, then it means that + // one or more of the links in the realpath couldn't be + // resolved. just return the abs value in that case. + p = self._makeAbs(p) + rp.realpath(p, self.realpathCache, function (er, real) { + if (!er) + set[real] = true + else if (er.syscall === 'stat') + set[p] = true + else + self.emit('error', er) // srsly wtf right here - fs.ReadStream = ReadStream - fs.WriteStream = WriteStream + if (--n === 0) { + self.matches[index] = set + cb() + } + }) + }) +} - function ReadStream (path, options) { - if (this instanceof ReadStream) - return fs$ReadStream.apply(this, arguments), this - else - return ReadStream.apply(Object.create(ReadStream.prototype), arguments) - } +Glob.prototype._mark = function (p) { + return common.mark(this, p) +} - function ReadStream$open () { - var that = this - open(that.path, that.flags, that.mode, function (err, fd) { - if (err) { - if (that.autoClose) - that.destroy() +Glob.prototype._makeAbs = function (f) { + return common.makeAbs(this, f) +} - that.emit('error', err) - } else { - that.fd = fd - that.emit('open', fd) - that.read() - } - }) - } +Glob.prototype.abort = function () { + this.aborted = true + this.emit('abort') +} - function WriteStream (path, options) { - if (this instanceof WriteStream) - return fs$WriteStream.apply(this, arguments), this - else - return WriteStream.apply(Object.create(WriteStream.prototype), arguments) +Glob.prototype.pause = function () { + if (!this.paused) { + this.paused = true + this.emit('pause') } +} - function WriteStream$open () { - var that = this - open(that.path, that.flags, that.mode, function (err, fd) { - if (err) { - that.destroy() - that.emit('error', err) - } else { - that.fd = fd - that.emit('open', fd) +Glob.prototype.resume = function () { + if (this.paused) { + this.emit('resume') + this.paused = false + if (this._emitQueue.length) { + var eq = this._emitQueue.slice(0) + this._emitQueue.length = 0 + for (var i = 0; i < eq.length; i ++) { + var e = eq[i] + this._emitMatch(e[0], e[1]) } - }) + } + if (this._processQueue.length) { + var pq = this._processQueue.slice(0) + this._processQueue.length = 0 + for (var i = 0; i < pq.length; i ++) { + var p = pq[i] + this._processing-- + this._process(p[0], p[1], p[2], p[3]) + } + } } +} - function createReadStream (path, options) { - return new ReadStream(path, options) - } +Glob.prototype._process = function (pattern, index, inGlobStar, cb) { + assert(this instanceof Glob) + assert(typeof cb === 'function') - function createWriteStream (path, options) { - return new WriteStream(path, options) - } + if (this.aborted) + return - var fs$open = fs.open - fs.open = open - function open (path, flags, mode, cb) { - if (typeof mode === 'function') - cb = mode, mode = null + this._processing++ + if (this.paused) { + this._processQueue.push([pattern, index, inGlobStar, cb]) + return + } - return go$open(path, flags, mode, cb) + //console.error('PROCESS %d', this._processing, pattern) - function go$open (path, flags, mode, cb) { - return fs$open(path, flags, mode, function (err, fd) { - if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) - enqueue([go$open, [path, flags, mode, cb]]) - else { - if (typeof cb === 'function') - cb.apply(this, arguments) - retry() - } - }) - } + // Get the first [n] parts of pattern that are all strings. + var n = 0 + while (typeof pattern[n] === 'string') { + n ++ } + // now n is the index of the first one that is *not* a string. - return fs -} + // see if there's anything else + var prefix + switch (n) { + // if not, then this is rather simple + case pattern.length: + this._processSimple(pattern.join('/'), index, cb) + return -function enqueue (elem) { - debug('ENQUEUE', elem[0].name, elem[1]) - queue.push(elem) -} + case 0: + // pattern *starts* with some non-trivial item. + // going to readdir(cwd), but not include the prefix in matches. + prefix = null + break -function retry () { - var elem = queue.shift() - if (elem) { - debug('RETRY', elem[0].name, elem[1]) - elem[0].apply(null, elem[1]) + default: + // pattern has some string bits in the front. + // whatever it starts with, whether that's 'absolute' like /foo/bar, + // or 'relative' like '../baz' + prefix = pattern.slice(0, n).join('/') + break } -} + var remain = pattern.slice(n) -/***/ }), -/* 28 */ -/***/ (function(module, exports) { + // get the list of entries. + var read + if (prefix === null) + read = '.' + else if (isAbsolute(prefix) || isAbsolute(pattern.join('/'))) { + if (!prefix || !isAbsolute(prefix)) + prefix = '/' + prefix + read = prefix + } else + read = prefix -module.exports = require("assert"); + var abs = this._makeAbs(read) -/***/ }), -/* 29 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + //if ignored, skip _processing + if (childrenIgnored(this, read)) + return cb() -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isFunction; -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function isFunction(x) { - return typeof x === 'function'; + var isGlobStar = remain[0] === minimatch.GLOBSTAR + if (isGlobStar) + this._processGlobStar(prefix, read, abs, remain, index, inGlobStar, cb) + else + this._processReaddir(prefix, read, abs, remain, index, inGlobStar, cb) } -//# sourceMappingURL=isFunction.js.map +Glob.prototype._processReaddir = function (prefix, read, abs, remain, index, inGlobStar, cb) { + var self = this + this._readdir(abs, inGlobStar, function (er, entries) { + return self._processReaddir2(prefix, read, abs, remain, index, inGlobStar, entries, cb) + }) +} -/***/ }), -/* 30 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +Glob.prototype._processReaddir2 = function (prefix, read, abs, remain, index, inGlobStar, entries, cb) { -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AsyncAction; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Action__ = __webpack_require__(264); -/** PURE_IMPORTS_START tslib,_Action PURE_IMPORTS_END */ + // if the abs isn't a dir, then nothing can match! + if (!entries) + return cb() + // It will only match dot entries if it starts with a dot, or if + // dot is set. Stuff like @(.foo|.bar) isn't allowed. + var pn = remain[0] + var negate = !!this.minimatch.negate + var rawGlob = pn._glob + var dotOk = this.dot || rawGlob.charAt(0) === '.' -var AsyncAction = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AsyncAction, _super); - function AsyncAction(scheduler, work) { - var _this = _super.call(this, scheduler, work) || this; - _this.scheduler = scheduler; - _this.work = work; - _this.pending = false; - return _this; - } - AsyncAction.prototype.schedule = function (state, delay) { - if (delay === void 0) { - delay = 0; - } - if (this.closed) { - return this; - } - this.state = state; - var id = this.id; - var scheduler = this.scheduler; - if (id != null) { - this.id = this.recycleAsyncId(scheduler, id, delay); - } - this.pending = true; - this.delay = delay; - this.id = this.id || this.requestAsyncId(scheduler, this.id, delay); - return this; - }; - AsyncAction.prototype.requestAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - return setInterval(scheduler.flush.bind(scheduler, this), delay); - }; - AsyncAction.prototype.recycleAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - if (delay !== null && this.delay === delay && this.pending === false) { - return id; - } - return clearInterval(id) && undefined || undefined; - }; - AsyncAction.prototype.execute = function (state, delay) { - if (this.closed) { - return new Error('executing a cancelled action'); - } - this.pending = false; - var error = this._execute(state, delay); - if (error) { - return error; - } - else if (this.pending === false && this.id != null) { - this.id = this.recycleAsyncId(this.scheduler, this.id, null); - } - }; - AsyncAction.prototype._execute = function (state, delay) { - var errored = false; - var errorValue = undefined; - try { - this.work(state); - } - catch (e) { - errored = true; - errorValue = !!e && e || new Error(e); - } - if (errored) { - this.unsubscribe(); - return errorValue; - } - }; - AsyncAction.prototype._unsubscribe = function () { - var id = this.id; - var scheduler = this.scheduler; - var actions = scheduler.actions; - var index = actions.indexOf(this); - this.work = null; - this.state = null; - this.pending = false; - this.scheduler = null; - if (index !== -1) { - actions.splice(index, 1); - } - if (id != null) { - this.id = this.recycleAsyncId(scheduler, id, null); - } - this.delay = null; - }; - return AsyncAction; -}(__WEBPACK_IMPORTED_MODULE_1__Action__["a" /* Action */])); + var matchedEntries = [] + for (var i = 0; i < entries.length; i++) { + var e = entries[i] + if (e.charAt(0) !== '.' || dotOk) { + var m + if (negate && !prefix) { + m = !e.match(pn) + } else { + m = e.match(pn) + } + if (m) + matchedEntries.push(e) + } + } -//# sourceMappingURL=AsyncAction.js.map + //console.error('prd2', prefix, entries, remain[0]._glob, matchedEntries) + var len = matchedEntries.length + // If there are no matched entries, then nothing matches. + if (len === 0) + return cb() -/***/ }), -/* 31 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + // if this is the last remaining pattern bit, then no need for + // an additional stat *unless* the user has specified mark or + // stat explicitly. We know they exist, since readdir returned + // them. -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AsyncScheduler; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Scheduler__ = __webpack_require__(110); -/** PURE_IMPORTS_START tslib,_Scheduler PURE_IMPORTS_END */ + if (remain.length === 1 && !this.mark && !this.stat) { + if (!this.matches[index]) + this.matches[index] = Object.create(null) + for (var i = 0; i < len; i ++) { + var e = matchedEntries[i] + if (prefix) { + if (prefix !== '/') + e = prefix + '/' + e + else + e = prefix + e + } -var AsyncScheduler = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AsyncScheduler, _super); - function AsyncScheduler(SchedulerAction, now) { - if (now === void 0) { - now = __WEBPACK_IMPORTED_MODULE_1__Scheduler__["a" /* Scheduler */].now; - } - var _this = _super.call(this, SchedulerAction, function () { - if (AsyncScheduler.delegate && AsyncScheduler.delegate !== _this) { - return AsyncScheduler.delegate.now(); - } - else { - return now(); - } - }) || this; - _this.actions = []; - _this.active = false; - _this.scheduled = undefined; - return _this; + if (e.charAt(0) === '/' && !this.nomount) { + e = path.join(this.root, e) + } + this._emitMatch(index, e) } - AsyncScheduler.prototype.schedule = function (work, delay, state) { - if (delay === void 0) { - delay = 0; - } - if (AsyncScheduler.delegate && AsyncScheduler.delegate !== this) { - return AsyncScheduler.delegate.schedule(work, delay, state); - } - else { - return _super.prototype.schedule.call(this, work, delay, state); - } - }; - AsyncScheduler.prototype.flush = function (action) { - var actions = this.actions; - if (this.active) { - actions.push(action); - return; - } - var error; - this.active = true; - do { - if (error = action.execute(action.state, action.delay)) { - break; - } - } while (action = actions.shift()); - this.active = false; - if (error) { - while (action = actions.shift()) { - action.unsubscribe(); - } - throw error; - } - }; - return AsyncScheduler; -}(__WEBPACK_IMPORTED_MODULE_1__Scheduler__["a" /* Scheduler */])); + // This was the last one, and no stats were needed + return cb() + } -//# sourceMappingURL=AsyncScheduler.js.map + // now test all matched entries as stand-ins for that part + // of the pattern. + remain.shift() + for (var i = 0; i < len; i ++) { + var e = matchedEntries[i] + var newPattern + if (prefix) { + if (prefix !== '/') + e = prefix + '/' + e + else + e = prefix + e + } + this._process([e].concat(remain), index, inGlobStar, cb) + } + cb() +} +Glob.prototype._emitMatch = function (index, e) { + if (this.aborted) + return -/***/ }), -/* 32 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + if (isIgnored(this, e)) + return -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ArgumentOutOfRangeError; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ + if (this.paused) { + this._emitQueue.push([index, e]) + return + } -var ArgumentOutOfRangeError = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ArgumentOutOfRangeError, _super); - function ArgumentOutOfRangeError() { - var _this = _super.call(this, 'argument out of range') || this; - _this.name = 'ArgumentOutOfRangeError'; - Object.setPrototypeOf(_this, ArgumentOutOfRangeError.prototype); - return _this; - } - return ArgumentOutOfRangeError; -}(Error)); + var abs = isAbsolute(e) ? e : this._makeAbs(e) -//# sourceMappingURL=ArgumentOutOfRangeError.js.map + if (this.mark) + e = this._mark(e) + if (this.absolute) + e = abs -/***/ }), -/* 33 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + if (this.matches[index][e]) + return -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return EmptyError; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ + if (this.nodir) { + var c = this.cache[abs] + if (c === 'DIR' || Array.isArray(c)) + return + } -var EmptyError = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](EmptyError, _super); - function EmptyError() { - var _this = _super.call(this, 'no elements in sequence') || this; - _this.name = 'EmptyError'; - Object.setPrototypeOf(_this, EmptyError.prototype); - return _this; - } - return EmptyError; -}(Error)); + this.matches[index][e] = true -//# sourceMappingURL=EmptyError.js.map + var st = this.statCache[abs] + if (st) + this.emit('stat', e, st) + this.emit('match', e) +} -/***/ }), -/* 34 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* unused harmony export getSymbolIterator */ -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return iterator; }); -/* unused harmony export $$iterator */ -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function getSymbolIterator() { - if (typeof Symbol !== 'function' || !Symbol.iterator) { - return '@@iterator'; - } - return Symbol.iterator; -} -var iterator = /*@__PURE__*/ getSymbolIterator(); -var $$iterator = iterator; -//# sourceMappingURL=iterator.js.map +Glob.prototype._readdirInGlobStar = function (abs, cb) { + if (this.aborted) + return + // follow all symlinked directories forever + // just proceed as if this is a non-globstar situation + if (this.follow) + return this._readdir(abs, false, cb) -/***/ }), -/* 35 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + var lstatkey = 'lstat\0' + abs + var self = this + var lstatcb = inflight(lstatkey, lstatcb_) -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = mergeMap; -/* unused harmony export MergeMapOperator */ -/* unused harmony export MergeMapSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_subscribeToResult__ = __webpack_require__(5); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__map__ = __webpack_require__(15); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__observable_from__ = __webpack_require__(18); -/** PURE_IMPORTS_START tslib,_util_subscribeToResult,_OuterSubscriber,_map,_observable_from PURE_IMPORTS_END */ + if (lstatcb) + fs.lstat(abs, lstatcb) + function lstatcb_ (er, lstat) { + if (er && er.code === 'ENOENT') + return cb() + var isSym = lstat && lstat.isSymbolicLink() + self.symlinks[abs] = isSym + // If it's not a symlink or a dir, then it's definitely a regular file. + // don't bother doing a readdir in that case. + if (!isSym && lstat && !lstat.isDirectory()) { + self.cache[abs] = 'FILE' + cb() + } else + self._readdir(abs, false, cb) + } +} +Glob.prototype._readdir = function (abs, inGlobStar, cb) { + if (this.aborted) + return -function mergeMap(project, resultSelector, concurrent) { - if (concurrent === void 0) { - concurrent = Number.POSITIVE_INFINITY; - } - if (typeof resultSelector === 'function') { - return function (source) { return source.pipe(mergeMap(function (a, i) { return Object(__WEBPACK_IMPORTED_MODULE_4__observable_from__["a" /* from */])(project(a, i)).pipe(Object(__WEBPACK_IMPORTED_MODULE_3__map__["a" /* map */])(function (b, ii) { return resultSelector(a, b, i, ii); })); }, concurrent)); }; - } - else if (typeof resultSelector === 'number') { - concurrent = resultSelector; - } - return function (source) { return source.lift(new MergeMapOperator(project, concurrent)); }; -} -var MergeMapOperator = /*@__PURE__*/ (function () { - function MergeMapOperator(project, concurrent) { - if (concurrent === void 0) { - concurrent = Number.POSITIVE_INFINITY; - } - this.project = project; - this.concurrent = concurrent; - } - MergeMapOperator.prototype.call = function (observer, source) { - return source.subscribe(new MergeMapSubscriber(observer, this.project, this.concurrent)); - }; - return MergeMapOperator; -}()); + cb = inflight('readdir\0'+abs+'\0'+inGlobStar, cb) + if (!cb) + return -var MergeMapSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](MergeMapSubscriber, _super); - function MergeMapSubscriber(destination, project, concurrent) { - if (concurrent === void 0) { - concurrent = Number.POSITIVE_INFINITY; - } - var _this = _super.call(this, destination) || this; - _this.project = project; - _this.concurrent = concurrent; - _this.hasCompleted = false; - _this.buffer = []; - _this.active = 0; - _this.index = 0; - return _this; - } - MergeMapSubscriber.prototype._next = function (value) { - if (this.active < this.concurrent) { - this._tryNext(value); - } - else { - this.buffer.push(value); - } - }; - MergeMapSubscriber.prototype._tryNext = function (value) { - var result; - var index = this.index++; - try { - result = this.project(value, index); - } - catch (err) { - this.destination.error(err); - return; - } - this.active++; - this._innerSub(result, value, index); - }; - MergeMapSubscriber.prototype._innerSub = function (ish, value, index) { - this.add(Object(__WEBPACK_IMPORTED_MODULE_1__util_subscribeToResult__["a" /* subscribeToResult */])(this, ish, value, index)); - }; - MergeMapSubscriber.prototype._complete = function () { - this.hasCompleted = true; - if (this.active === 0 && this.buffer.length === 0) { - this.destination.complete(); - } - }; - MergeMapSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.destination.next(innerValue); - }; - MergeMapSubscriber.prototype.notifyComplete = function (innerSub) { - var buffer = this.buffer; - this.remove(innerSub); - this.active--; - if (buffer.length > 0) { - this._next(buffer.shift()); - } - else if (this.active === 0 && this.hasCompleted) { - this.destination.complete(); - } - }; - return MergeMapSubscriber; -}(__WEBPACK_IMPORTED_MODULE_2__OuterSubscriber__["a" /* OuterSubscriber */])); + //console.error('RD %j %j', +inGlobStar, abs) + if (inGlobStar && !ownProp(this.symlinks, abs)) + return this._readdirInGlobStar(abs, cb) -//# sourceMappingURL=mergeMap.js.map + if (ownProp(this.cache, abs)) { + var c = this.cache[abs] + if (!c || c === 'FILE') + return cb() + if (Array.isArray(c)) + return cb(null, c) + } -/***/ }), -/* 36 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + var self = this + fs.readdir(abs, readdirCb(this, abs, cb)) +} -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = defaultIfEmpty; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ +function readdirCb (self, abs, cb) { + return function (er, entries) { + if (er) + self._readdirError(abs, er, cb) + else + self._readdirEntries(abs, entries, cb) + } +} +Glob.prototype._readdirEntries = function (abs, entries, cb) { + if (this.aborted) + return -function defaultIfEmpty(defaultValue) { - if (defaultValue === void 0) { - defaultValue = null; + // if we haven't asked to stat everything, then just + // assume that everything in there exists, so we can avoid + // having to stat it a second time. + if (!this.mark && !this.stat) { + for (var i = 0; i < entries.length; i ++) { + var e = entries[i] + if (abs === '/') + e = abs + e + else + e = abs + '/' + e + this.cache[e] = true } - return function (source) { return source.lift(new DefaultIfEmptyOperator(defaultValue)); }; + } + + this.cache[abs] = entries + return cb(null, entries) } -var DefaultIfEmptyOperator = /*@__PURE__*/ (function () { - function DefaultIfEmptyOperator(defaultValue) { - this.defaultValue = defaultValue; - } - DefaultIfEmptyOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new DefaultIfEmptySubscriber(subscriber, this.defaultValue)); - }; - return DefaultIfEmptyOperator; -}()); -var DefaultIfEmptySubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](DefaultIfEmptySubscriber, _super); - function DefaultIfEmptySubscriber(destination, defaultValue) { - var _this = _super.call(this, destination) || this; - _this.defaultValue = defaultValue; - _this.isEmpty = true; - return _this; - } - DefaultIfEmptySubscriber.prototype._next = function (value) { - this.isEmpty = false; - this.destination.next(value); - }; - DefaultIfEmptySubscriber.prototype._complete = function () { - if (this.isEmpty) { - this.destination.next(this.defaultValue); - } - this.destination.complete(); - }; - return DefaultIfEmptySubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=defaultIfEmpty.js.map +Glob.prototype._readdirError = function (f, er, cb) { + if (this.aborted) + return -/***/ }), -/* 37 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + // handle errors, and cache the information + switch (er.code) { + case 'ENOTSUP': // https://github.com/isaacs/node-glob/issues/205 + case 'ENOTDIR': // totally normal. means it *does* exist. + var abs = this._makeAbs(f) + this.cache[abs] = 'FILE' + if (abs === this.cwdAbs) { + var error = new Error(er.code + ' invalid cwd ' + this.cwd) + error.path = this.cwd + error.code = er.code + this.emit('error', error) + this.abort() + } + break -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = filter; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ + case 'ENOENT': // not terribly unusual + case 'ELOOP': + case 'ENAMETOOLONG': + case 'UNKNOWN': + this.cache[this._makeAbs(f)] = false + break + default: // some unusual error. Treat as failure. + this.cache[this._makeAbs(f)] = false + if (this.strict) { + this.emit('error', er) + // If the error is handled, then we abort + // if not, we threw out of here + this.abort() + } + if (!this.silent) + console.error('glob error', er) + break + } -function filter(predicate, thisArg) { - return function filterOperatorFunction(source) { - return source.lift(new FilterOperator(predicate, thisArg)); - }; + return cb() } -var FilterOperator = /*@__PURE__*/ (function () { - function FilterOperator(predicate, thisArg) { - this.predicate = predicate; - this.thisArg = thisArg; - } - FilterOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new FilterSubscriber(subscriber, this.predicate, this.thisArg)); - }; - return FilterOperator; -}()); -var FilterSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](FilterSubscriber, _super); - function FilterSubscriber(destination, predicate, thisArg) { - var _this = _super.call(this, destination) || this; - _this.predicate = predicate; - _this.thisArg = thisArg; - _this.count = 0; - return _this; - } - FilterSubscriber.prototype._next = function (value) { - var result; - try { - result = this.predicate.call(this.thisArg, value, this.count++); - } - catch (err) { - this.destination.error(err); - return; - } - if (result) { - this.destination.next(value); - } - }; - return FilterSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=filter.js.map +Glob.prototype._processGlobStar = function (prefix, read, abs, remain, index, inGlobStar, cb) { + var self = this + this._readdir(abs, inGlobStar, function (er, entries) { + self._processGlobStar2(prefix, read, abs, remain, index, inGlobStar, entries, cb) + }) +} -/***/ }), -/* 38 */ -/***/ (function(module, exports) { -module.exports = function(module) { - if(!module.webpackPolyfill) { - module.deprecate = function() {}; - module.paths = []; - // module.parent = undefined by default - if(!module.children) module.children = []; - Object.defineProperty(module, "loaded", { - enumerable: true, - get: function() { - return module.l; - } - }); - Object.defineProperty(module, "id", { - enumerable: true, - get: function() { - return module.i; - } - }); - module.webpackPolyfill = 1; - } - return module; -}; +Glob.prototype._processGlobStar2 = function (prefix, read, abs, remain, index, inGlobStar, entries, cb) { + //console.error('pgs2', prefix, remain[0], entries) + // no entries means not a dir, so it can never have matches + // foo.txt/** doesn't match foo.txt + if (!entries) + return cb() -/***/ }), -/* 39 */ -/***/ (function(module, exports, __webpack_require__) { + // test without the globstar, and with every child both below + // and replacing the globstar. + var remainWithoutGlobStar = remain.slice(1) + var gspref = prefix ? [ prefix ] : [] + var noGlobStar = gspref.concat(remainWithoutGlobStar) -"use strict"; + // the noGlobStar pattern exits the inGlobStar state + this._process(noGlobStar, index, false, cb) + var isSym = this.symlinks[abs] + var len = entries.length -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.createSymlink = exports.isFile = exports.isDirectory = exports.mkdirp = exports.readFile = exports.chmod = exports.copyDirectory = exports.unlink = undefined; + // If it's a symlink, and we're in a globstar, then stop + if (isSym && inGlobStar) + return cb() -let statTest = (() => { - var _ref = _asyncToGenerator(function* (path, block) { - try { - return block((yield stat(path))); - } catch (e) { - if (e.code === 'ENOENT') { - return false; - } - throw e; - } - }); + for (var i = 0; i < len; i++) { + var e = entries[i] + if (e.charAt(0) === '.' && !this.dot) + continue - return function statTest(_x, _x2) { - return _ref.apply(this, arguments); - }; -})(); -/** - * Test if a path points to a directory. - * @param path - */ + // these two cases enter the inGlobStar state + var instead = gspref.concat(entries[i], remainWithoutGlobStar) + this._process(instead, index, true, cb) + var below = gspref.concat(entries[i], remain) + this._process(below, index, true, cb) + } -let isDirectory = exports.isDirectory = (() => { - var _ref2 = _asyncToGenerator(function* (path) { - return yield statTest(path, function (stats) { - return stats.isDirectory(); - }); - }); + cb() +} - return function isDirectory(_x3) { - return _ref2.apply(this, arguments); - }; -})(); -/** - * Test if a path points to a regular file. - * @param path - */ +Glob.prototype._processSimple = function (prefix, index, cb) { + // XXX review this. Shouldn't it be doing the mounting etc + // before doing stat? kinda weird? + var self = this + this._stat(prefix, function (er, exists) { + self._processSimple2(prefix, index, er, exists, cb) + }) +} +Glob.prototype._processSimple2 = function (prefix, index, er, exists, cb) { + //console.error('ps2', prefix, exists) -let isFile = exports.isFile = (() => { - var _ref3 = _asyncToGenerator(function* (path) { - return yield statTest(path, function (stats) { - return stats.isFile(); - }); - }); + if (!this.matches[index]) + this.matches[index] = Object.create(null) - return function isFile(_x4) { - return _ref3.apply(this, arguments); - }; -})(); -/** - * Create a symlink at dest that points to src. Adapted from - * https://github.com/lerna/lerna/blob/2f1b87d9e2295f587e4ac74269f714271d8ed428/src/FileSystemUtilities.js#L103. - * - * @param src - * @param dest - * @param type 'dir', 'file', 'junction', or 'exec'. 'exec' on - * windows will use the `cmd-shim` module since symlinks can't be used - * for executable files on windows. - */ + // If it doesn't exist, then just mark the lack of results + if (!exists) + return cb() + if (prefix && isAbsolute(prefix) && !this.nomount) { + var trail = /[\/\\]$/.test(prefix) + if (prefix.charAt(0) === '/') { + prefix = path.join(this.root, prefix) + } else { + prefix = path.resolve(this.root, prefix) + if (trail) + prefix += '/' + } + } -let createSymlink = exports.createSymlink = (() => { - var _ref4 = _asyncToGenerator(function* (src, dest, type) { - if (process.platform === 'win32') { - if (type === 'exec') { - yield cmdShim(src, dest); - } else { - yield forceCreate(src, dest, type); - } - } else { - const posixType = type === 'exec' ? 'file' : type; - const relativeSource = (0, _path.relative)((0, _path.dirname)(dest), src); - yield forceCreate(relativeSource, dest, posixType); - } - }); + if (process.platform === 'win32') + prefix = prefix.replace(/\\/g, '/') - return function createSymlink(_x5, _x6, _x7) { - return _ref4.apply(this, arguments); - }; -})(); + // Mark this as a match + this._emitMatch(index, prefix) + cb() +} -let forceCreate = (() => { - var _ref5 = _asyncToGenerator(function* (src, dest, type) { - try { - // If something exists at `dest` we need to remove it first. - yield unlink(dest); - } catch (error) { - if (error.code !== 'ENOENT') { - throw error; - } - } - yield symlink(src, dest, type); - }); +// Returns either 'DIR', 'FILE', or false +Glob.prototype._stat = function (f, cb) { + var abs = this._makeAbs(f) + var needDir = f.slice(-1) === '/' - return function forceCreate(_x8, _x9, _x10) { - return _ref5.apply(this, arguments); - }; -})(); + if (f.length > this.maxLength) + return cb() -var _cmdShim = __webpack_require__(148); + if (!this.stat && ownProp(this.cache, abs)) { + var c = this.cache[abs] -var _cmdShim2 = _interopRequireDefault(_cmdShim); + if (Array.isArray(c)) + c = 'DIR' -var _fs = __webpack_require__(6); + // It exists, but maybe not how we need it + if (!needDir || c === 'DIR') + return cb(null, c) -var _fs2 = _interopRequireDefault(_fs); + if (needDir && c === 'FILE') + return cb() -var _mkdirp = __webpack_require__(80); + // otherwise we have to stat, because maybe c=true + // if we know it exists, but not what it is. + } -var _mkdirp2 = _interopRequireDefault(_mkdirp); + var exists + var stat = this.statCache[abs] + if (stat !== undefined) { + if (stat === false) + return cb(null, stat) + else { + var type = stat.isDirectory() ? 'DIR' : 'FILE' + if (needDir && type === 'FILE') + return cb() + else + return cb(null, type, stat) + } + } -var _ncp = __webpack_require__(152); + var self = this + var statcb = inflight('stat\0' + abs, lstatcb_) + if (statcb) + fs.lstat(abs, statcb) -var _path = __webpack_require__(2); + function lstatcb_ (er, lstat) { + if (lstat && lstat.isSymbolicLink()) { + // If it's a symlink, then treat it as the target, unless + // the target does not exist, then treat it as a file. + return fs.stat(abs, function (er, stat) { + if (er) + self._stat2(f, abs, null, lstat, cb) + else + self._stat2(f, abs, er, stat, cb) + }) + } else { + self._stat2(f, abs, er, lstat, cb) + } + } +} -var _util = __webpack_require__(8); +Glob.prototype._stat2 = function (f, abs, er, stat, cb) { + if (er && (er.code === 'ENOENT' || er.code === 'ENOTDIR')) { + this.statCache[abs] = false + return cb() + } -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + var needDir = f.slice(-1) === '/' + this.statCache[abs] = stat -function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* - * 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. - */ + if (abs.slice(-1) === '/' && stat && !stat.isDirectory()) + return cb(null, false, stat) + var c = true + if (stat) + c = stat.isDirectory() ? 'DIR' : 'FILE' + this.cache[abs] = this.cache[abs] || c -const stat = (0, _util.promisify)(_fs2.default.stat); -const readFile = (0, _util.promisify)(_fs2.default.readFile); -const symlink = (0, _util.promisify)(_fs2.default.symlink); -const chmod = (0, _util.promisify)(_fs2.default.chmod); -const cmdShim = (0, _util.promisify)(_cmdShim2.default); -const mkdirp = (0, _util.promisify)(_mkdirp2.default); -const unlink = exports.unlink = (0, _util.promisify)(_fs2.default.unlink); -const copyDirectory = exports.copyDirectory = (0, _util.promisify)(_ncp.ncp); -exports.chmod = chmod; -exports.readFile = readFile; -exports.mkdirp = mkdirp; + if (needDir && c === 'FILE') + return cb() -/***/ }), -/* 40 */ -/***/ (function(module, exports) { + return cb(null, c, stat) +} -module.exports = require("events"); /***/ }), -/* 41 */ +/* 44 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.isLinkDependency = undefined; -exports.readPackageJson = readPackageJson; -exports.writePackageJson = writePackageJson; - -var _readPkg = __webpack_require__(160); +const processFn = (fn, opts) => function () { + const P = opts.promiseModule; + const args = new Array(arguments.length); -var _readPkg2 = _interopRequireDefault(_readPkg); + for (let i = 0; i < arguments.length; i++) { + args[i] = arguments[i]; + } -var _writePkg = __webpack_require__(185); + return new P((resolve, reject) => { + if (opts.errorFirst) { + args.push(function (err, result) { + if (opts.multiArgs) { + const results = new Array(arguments.length - 1); -var _writePkg2 = _interopRequireDefault(_writePkg); + for (let i = 1; i < arguments.length; i++) { + results[i - 1] = arguments[i]; + } -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + if (err) { + results.unshift(err); + reject(results); + } else { + resolve(results); + } + } else if (err) { + reject(err); + } else { + resolve(result); + } + }); + } else { + args.push(function (result) { + if (opts.multiArgs) { + const results = new Array(arguments.length - 1); -/* - * 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. - */ -function readPackageJson(dir) { - return (0, _readPkg2.default)(dir, { normalize: false }); -} -function writePackageJson(path, json) { - return (0, _writePkg2.default)(path, json); -} -const isLinkDependency = exports.isLinkDependency = depVersion => depVersion.startsWith('link:'); + for (let i = 0; i < arguments.length; i++) { + results[i] = arguments[i]; + } -/***/ }), -/* 42 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + resolve(results); + } else { + resolve(result); + } + }); + } -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return config; }); -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -var _enable_super_gross_mode_that_will_cause_bad_things = false; -var config = { - Promise: undefined, - set useDeprecatedSynchronousErrorHandling(value) { - if (value) { - var error = /*@__PURE__*/ new Error(); - /*@__PURE__*/ console.warn('DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n' + error.stack); - } - else if (_enable_super_gross_mode_that_will_cause_bad_things) { - /*@__PURE__*/ console.log('RxJS: Back to a better error behavior. Thank you. <3'); - } - _enable_super_gross_mode_that_will_cause_bad_things = value; - }, - get useDeprecatedSynchronousErrorHandling() { - return _enable_super_gross_mode_that_will_cause_bad_things; - }, + fn.apply(this, args); + }); }; -//# sourceMappingURL=config.js.map +module.exports = (obj, opts) => { + opts = Object.assign({ + exclude: [/.+(Sync|Stream)$/], + errorFirst: true, + promiseModule: Promise + }, opts); -/***/ }), -/* 43 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + const filter = key => { + const match = pattern => typeof pattern === 'string' ? key === pattern : pattern.test(key); + return opts.include ? opts.include.some(match) : !opts.exclude.some(match); + }; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = noop; -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function noop() { } -//# sourceMappingURL=noop.js.map + let ret; + if (typeof obj === 'function') { + ret = function () { + if (opts.excludeMain) { + return obj.apply(this, arguments); + } + + return processFn(obj, opts).apply(this, arguments); + }; + } else { + ret = Object.create(Object.getPrototypeOf(obj)); + } + + for (const key in obj) { // eslint-disable-line guard-for-in + const x = obj[key]; + ret[key] = typeof x === 'function' && filter(key) ? processFn(x, opts) : x; + } + + return ret; +}; /***/ }), -/* 44 */ +/* 45 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ObjectUnsubscribedError; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return refCount; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1); +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -var ObjectUnsubscribedError = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ObjectUnsubscribedError, _super); - function ObjectUnsubscribedError() { - var _this = _super.call(this, 'object unsubscribed') || this; - _this.name = 'ObjectUnsubscribedError'; - Object.setPrototypeOf(_this, ObjectUnsubscribedError.prototype); + +function refCount() { + return function refCountOperatorFunction(source) { + return source.lift(new RefCountOperator(source)); + }; +} +var RefCountOperator = /*@__PURE__*/ (function () { + function RefCountOperator(connectable) { + this.connectable = connectable; + } + RefCountOperator.prototype.call = function (subscriber, source) { + var connectable = this.connectable; + connectable._refCount++; + var refCounter = new RefCountSubscriber(subscriber, connectable); + var subscription = source.subscribe(refCounter); + if (!refCounter.closed) { + refCounter.connection = connectable.connect(); + } + return subscription; + }; + return RefCountOperator; +}()); +var RefCountSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](RefCountSubscriber, _super); + function RefCountSubscriber(destination, connectable) { + var _this = _super.call(this, destination) || this; + _this.connectable = connectable; return _this; } - return ObjectUnsubscribedError; -}(Error)); - -//# sourceMappingURL=ObjectUnsubscribedError.js.map + RefCountSubscriber.prototype._unsubscribe = function () { + var connectable = this.connectable; + if (!connectable) { + this.connection = null; + return; + } + this.connectable = null; + var refCount = connectable._refCount; + if (refCount <= 0) { + this.connection = null; + return; + } + connectable._refCount = refCount - 1; + if (refCount > 1) { + this.connection = null; + return; + } + var connection = this.connection; + var sharedConnection = connectable._connection; + this.connection = null; + if (sharedConnection && (!connection || sharedConnection === connection)) { + sharedConnection.unsubscribe(); + } + }; + return RefCountSubscriber; +}(_Subscriber__WEBPACK_IMPORTED_MODULE_1__[/* Subscriber */ "a"])); +//# sourceMappingURL=refCount.js.map /***/ }), -/* 45 */ +/* 46 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Notification; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_empty__ = __webpack_require__(11); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__observable_of__ = __webpack_require__(66); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__observable_throwError__ = __webpack_require__(68); -/** PURE_IMPORTS_START _observable_empty,_observable_of,_observable_throwError PURE_IMPORTS_END */ +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ReplaySubject; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8); +/* harmony import */ var _scheduler_queue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(72); +/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5); +/* harmony import */ var _operators_observeOn__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(66); +/* harmony import */ var _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(25); +/* harmony import */ var _SubjectSubscription__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(74); +/** PURE_IMPORTS_START tslib,_Subject,_scheduler_queue,_Subscription,_operators_observeOn,_util_ObjectUnsubscribedError,_SubjectSubscription PURE_IMPORTS_END */ -var Notification = /*@__PURE__*/ (function () { - function Notification(kind, value, error) { - this.kind = kind; - this.value = value; - this.error = error; - this.hasValue = kind === 'N'; + + + + +var ReplaySubject = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](ReplaySubject, _super); + function ReplaySubject(bufferSize, windowTime, scheduler) { + if (bufferSize === void 0) { + bufferSize = Number.POSITIVE_INFINITY; + } + if (windowTime === void 0) { + windowTime = Number.POSITIVE_INFINITY; + } + var _this = _super.call(this) || this; + _this.scheduler = scheduler; + _this._events = []; + _this._infiniteTimeWindow = false; + _this._bufferSize = bufferSize < 1 ? 1 : bufferSize; + _this._windowTime = windowTime < 1 ? 1 : windowTime; + if (windowTime === Number.POSITIVE_INFINITY) { + _this._infiniteTimeWindow = true; + _this.next = _this.nextInfiniteTimeWindow; + } + else { + _this.next = _this.nextTimeWindow; + } + return _this; } - Notification.prototype.observe = function (observer) { - switch (this.kind) { - case 'N': - return observer.next && observer.next(this.value); - case 'E': - return observer.error && observer.error(this.error); - case 'C': - return observer.complete && observer.complete(); + ReplaySubject.prototype.nextInfiniteTimeWindow = function (value) { + var _events = this._events; + _events.push(value); + if (_events.length > this._bufferSize) { + _events.shift(); } + _super.prototype.next.call(this, value); }; - Notification.prototype.do = function (next, error, complete) { - var kind = this.kind; - switch (kind) { - case 'N': - return next && next(this.value); - case 'E': - return error && error(this.error); - case 'C': - return complete && complete(); - } + ReplaySubject.prototype.nextTimeWindow = function (value) { + this._events.push(new ReplayEvent(this._getNow(), value)); + this._trimBufferThenGetEvents(); + _super.prototype.next.call(this, value); }; - Notification.prototype.accept = function (nextOrObserver, error, complete) { - if (nextOrObserver && typeof nextOrObserver.next === 'function') { - return this.observe(nextOrObserver); + ReplaySubject.prototype._subscribe = function (subscriber) { + var _infiniteTimeWindow = this._infiniteTimeWindow; + var _events = _infiniteTimeWindow ? this._events : this._trimBufferThenGetEvents(); + var scheduler = this.scheduler; + var len = _events.length; + var subscription; + if (this.closed) { + throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_5__[/* ObjectUnsubscribedError */ "a"](); + } + else if (this.isStopped || this.hasError) { + subscription = _Subscription__WEBPACK_IMPORTED_MODULE_3__[/* Subscription */ "a"].EMPTY; } else { - return this.do(nextOrObserver, error, complete); + this.observers.push(subscriber); + subscription = new _SubjectSubscription__WEBPACK_IMPORTED_MODULE_6__[/* SubjectSubscription */ "a"](this, subscriber); } - }; - Notification.prototype.toObservable = function () { - var kind = this.kind; - switch (kind) { - case 'N': - return Object(__WEBPACK_IMPORTED_MODULE_1__observable_of__["a" /* of */])(this.value); - case 'E': - return Object(__WEBPACK_IMPORTED_MODULE_2__observable_throwError__["a" /* throwError */])(this.error); - case 'C': - return Object(__WEBPACK_IMPORTED_MODULE_0__observable_empty__["b" /* empty */])(); + if (scheduler) { + subscriber.add(subscriber = new _operators_observeOn__WEBPACK_IMPORTED_MODULE_4__[/* ObserveOnSubscriber */ "a"](subscriber, scheduler)); } - throw new Error('unexpected notification kind value'); - }; - Notification.createNext = function (value) { - if (typeof value !== 'undefined') { - return new Notification('N', value); + if (_infiniteTimeWindow) { + for (var i = 0; i < len && !subscriber.closed; i++) { + subscriber.next(_events[i]); + } + } + else { + for (var i = 0; i < len && !subscriber.closed; i++) { + subscriber.next(_events[i].value); + } } - return Notification.undefinedValueNotification; - }; - Notification.createError = function (err) { - return new Notification('E', undefined, err); - }; - Notification.createComplete = function () { - return Notification.completeNotification; - }; - Notification.completeNotification = new Notification('C'); - Notification.undefinedValueNotification = new Notification('N', undefined); - return Notification; -}()); - -//# sourceMappingURL=Notification.js.map - - -/***/ }), -/* 46 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AsyncSubject; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Subscription__ = __webpack_require__(7); -/** PURE_IMPORTS_START tslib,_Subject,_Subscription PURE_IMPORTS_END */ - - - -var AsyncSubject = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AsyncSubject, _super); - function AsyncSubject() { - var _this = _super !== null && _super.apply(this, arguments) || this; - _this.value = null; - _this.hasNext = false; - _this.hasCompleted = false; - return _this; - } - AsyncSubject.prototype._subscribe = function (subscriber) { if (this.hasError) { subscriber.error(this.thrownError); - return __WEBPACK_IMPORTED_MODULE_2__Subscription__["a" /* Subscription */].EMPTY; } - else if (this.hasCompleted && this.hasNext) { - subscriber.next(this.value); + else if (this.isStopped) { subscriber.complete(); - return __WEBPACK_IMPORTED_MODULE_2__Subscription__["a" /* Subscription */].EMPTY; } - return _super.prototype._subscribe.call(this, subscriber); + return subscription; }; - AsyncSubject.prototype.next = function (value) { - if (!this.hasCompleted) { - this.value = value; - this.hasNext = true; - } + ReplaySubject.prototype._getNow = function () { + return (this.scheduler || _scheduler_queue__WEBPACK_IMPORTED_MODULE_2__[/* queue */ "a"]).now(); }; - AsyncSubject.prototype.error = function (error) { - if (!this.hasCompleted) { - _super.prototype.error.call(this, error); + ReplaySubject.prototype._trimBufferThenGetEvents = function () { + var now = this._getNow(); + var _bufferSize = this._bufferSize; + var _windowTime = this._windowTime; + var _events = this._events; + var eventsCount = _events.length; + var spliceCount = 0; + while (spliceCount < eventsCount) { + if ((now - _events[spliceCount].time) < _windowTime) { + break; + } + spliceCount++; } - }; - AsyncSubject.prototype.complete = function () { - this.hasCompleted = true; - if (this.hasNext) { - _super.prototype.next.call(this, this.value); + if (eventsCount > _bufferSize) { + spliceCount = Math.max(spliceCount, eventsCount - _bufferSize); } - _super.prototype.complete.call(this); + if (spliceCount > 0) { + _events.splice(0, spliceCount); + } + return _events; }; - return AsyncSubject; -}(__WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */])); + return ReplaySubject; +}(_Subject__WEBPACK_IMPORTED_MODULE_1__[/* Subject */ "a"])); -//# sourceMappingURL=AsyncSubject.js.map +var ReplayEvent = /*@__PURE__*/ (function () { + function ReplayEvent(time, value) { + this.time = time; + this.value = value; + } + return ReplayEvent; +}()); +//# sourceMappingURL=ReplaySubject.js.map /***/ }), @@ -3804,27 +3823,38 @@ var AsyncSubject = /*@__PURE__*/ (function (_super) { /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = concat; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_isScheduler__ = __webpack_require__(14); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__of__ = __webpack_require__(66); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__from__ = __webpack_require__(18); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__operators_concatAll__ = __webpack_require__(121); -/** PURE_IMPORTS_START _util_isScheduler,_of,_from,_operators_concatAll PURE_IMPORTS_END */ +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return of; }); +/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(12); +/* harmony import */ var _fromArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(17); +/* harmony import */ var _empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9); +/* harmony import */ var _scalar__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(53); +/** PURE_IMPORTS_START _util_isScheduler,_fromArray,_empty,_scalar PURE_IMPORTS_END */ -function concat() { - var observables = []; +function of() { + var args = []; for (var _i = 0; _i < arguments.length; _i++) { - observables[_i] = arguments[_i]; + args[_i] = arguments[_i]; + } + var scheduler = args[args.length - 1]; + if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_0__[/* isScheduler */ "a"])(scheduler)) { + args.pop(); + } + else { + scheduler = undefined; } - if (observables.length === 1 || (observables.length === 2 && Object(__WEBPACK_IMPORTED_MODULE_0__util_isScheduler__["a" /* isScheduler */])(observables[1]))) { - return Object(__WEBPACK_IMPORTED_MODULE_2__from__["a" /* from */])(observables[0]); + switch (args.length) { + case 0: + return Object(_empty__WEBPACK_IMPORTED_MODULE_2__[/* empty */ "b"])(scheduler); + case 1: + return scheduler ? Object(_fromArray__WEBPACK_IMPORTED_MODULE_1__[/* fromArray */ "a"])(args, scheduler) : Object(_scalar__WEBPACK_IMPORTED_MODULE_3__[/* scalar */ "a"])(args[0]); + default: + return Object(_fromArray__WEBPACK_IMPORTED_MODULE_1__[/* fromArray */ "a"])(args, scheduler); } - return Object(__WEBPACK_IMPORTED_MODULE_3__operators_concatAll__["a" /* concatAll */])()(__WEBPACK_IMPORTED_MODULE_1__of__["a" /* of */].apply(void 0, observables)); } -//# sourceMappingURL=concat.js.map +//# sourceMappingURL=of.js.map /***/ }), @@ -3832,14 +3862,23 @@ function concat() { /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isNumeric; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__isArray__ = __webpack_require__(10); -/** PURE_IMPORTS_START _isArray PURE_IMPORTS_END */ +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return throwError; }); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2); +/** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ -function isNumeric(val) { - return !Object(__WEBPACK_IMPORTED_MODULE_0__isArray__["a" /* isArray */])(val) && (val - parseFloat(val) + 1) >= 0; +function throwError(error, scheduler) { + if (!scheduler) { + return new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](function (subscriber) { return subscriber.error(error); }); + } + else { + return new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](function (subscriber) { return scheduler.schedule(dispatch, 0, { error: error, subscriber: subscriber }); }); + } } -//# sourceMappingURL=isNumeric.js.map +function dispatch(_a) { + var error = _a.error, subscriber = _a.subscriber; + subscriber.error(error); +} +//# sourceMappingURL=throwError.js.map /***/ }), @@ -3847,3946 +3886,3516 @@ function isNumeric(val) { /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return throwIfEmpty; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__tap__ = __webpack_require__(130); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_EmptyError__ = __webpack_require__(33); -/** PURE_IMPORTS_START _tap,_util_EmptyError PURE_IMPORTS_END */ - - -var throwIfEmpty = function (errorFactory) { - if (errorFactory === void 0) { - errorFactory = defaultErrorFactory; - } - return Object(__WEBPACK_IMPORTED_MODULE_0__tap__["a" /* tap */])({ - hasValue: false, - next: function () { this.hasValue = true; }, - complete: function () { - if (!this.hasValue) { - throw errorFactory(); - } - } - }); -}; -function defaultErrorFactory() { - return new __WEBPACK_IMPORTED_MODULE_1__util_EmptyError__["a" /* EmptyError */](); -} -//# sourceMappingURL=throwIfEmpty.js.map - +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return combineLatest; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return CombineLatestOperator; }); +/* unused harmony export CombineLatestSubscriber */ +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(12); +/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(11); +/* harmony import */ var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4); +/* harmony import */ var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3); +/* harmony import */ var _fromArray__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(17); +/** PURE_IMPORTS_START tslib,_util_isScheduler,_util_isArray,_OuterSubscriber,_util_subscribeToResult,_fromArray PURE_IMPORTS_END */ -/***/ }), -/* 50 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = reduce; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__scan__ = __webpack_require__(75); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__takeLast__ = __webpack_require__(74); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__defaultIfEmpty__ = __webpack_require__(36); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_pipe__ = __webpack_require__(63); -/** PURE_IMPORTS_START _scan,_takeLast,_defaultIfEmpty,_util_pipe PURE_IMPORTS_END */ -function reduce(accumulator, seed) { - if (arguments.length >= 2) { - return function reduceOperatorFunctionWithSeed(source) { - return Object(__WEBPACK_IMPORTED_MODULE_3__util_pipe__["a" /* pipe */])(Object(__WEBPACK_IMPORTED_MODULE_0__scan__["a" /* scan */])(accumulator, seed), Object(__WEBPACK_IMPORTED_MODULE_1__takeLast__["a" /* takeLast */])(1), Object(__WEBPACK_IMPORTED_MODULE_2__defaultIfEmpty__["a" /* defaultIfEmpty */])(seed))(source); - }; +var NONE = {}; +function combineLatest() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i] = arguments[_i]; } - return function reduceOperatorFunction(source) { - return Object(__WEBPACK_IMPORTED_MODULE_3__util_pipe__["a" /* pipe */])(Object(__WEBPACK_IMPORTED_MODULE_0__scan__["a" /* scan */])(function (acc, value, index) { - return accumulator(acc, value, index + 1); - }), Object(__WEBPACK_IMPORTED_MODULE_1__takeLast__["a" /* takeLast */])(1))(source); - }; -} -//# sourceMappingURL=reduce.js.map - - -/***/ }), -/* 51 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var matchOperatorsRe = /[|\\{}()[\]^$+*?.]/g; + var resultSelector = null; + var scheduler = null; + if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_1__[/* isScheduler */ "a"])(observables[observables.length - 1])) { + scheduler = observables.pop(); + } + if (typeof observables[observables.length - 1] === 'function') { + resultSelector = observables.pop(); + } + if (observables.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_2__[/* isArray */ "a"])(observables[0])) { + observables = observables[0]; + } + return Object(_fromArray__WEBPACK_IMPORTED_MODULE_5__[/* fromArray */ "a"])(observables, scheduler).lift(new CombineLatestOperator(resultSelector)); +} +var CombineLatestOperator = /*@__PURE__*/ (function () { + function CombineLatestOperator(resultSelector) { + this.resultSelector = resultSelector; + } + CombineLatestOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new CombineLatestSubscriber(subscriber, this.resultSelector)); + }; + return CombineLatestOperator; +}()); -module.exports = function (str) { - if (typeof str !== 'string') { - throw new TypeError('Expected a string'); - } +var CombineLatestSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](CombineLatestSubscriber, _super); + function CombineLatestSubscriber(destination, resultSelector) { + var _this = _super.call(this, destination) || this; + _this.resultSelector = resultSelector; + _this.active = 0; + _this.values = []; + _this.observables = []; + return _this; + } + CombineLatestSubscriber.prototype._next = function (observable) { + this.values.push(NONE); + this.observables.push(observable); + }; + CombineLatestSubscriber.prototype._complete = function () { + var observables = this.observables; + var len = observables.length; + if (len === 0) { + this.destination.complete(); + } + else { + this.active = len; + this.toRespond = len; + for (var i = 0; i < len; i++) { + var observable = observables[i]; + this.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_4__[/* subscribeToResult */ "a"])(this, observable, observable, i)); + } + } + }; + CombineLatestSubscriber.prototype.notifyComplete = function (unused) { + if ((this.active -= 1) === 0) { + this.destination.complete(); + } + }; + CombineLatestSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + var values = this.values; + var oldVal = values[outerIndex]; + var toRespond = !this.toRespond + ? 0 + : oldVal === NONE ? --this.toRespond : this.toRespond; + values[outerIndex] = innerValue; + if (toRespond === 0) { + if (this.resultSelector) { + this._tryResultSelector(values); + } + else { + this.destination.next(values.slice()); + } + } + }; + CombineLatestSubscriber.prototype._tryResultSelector = function (values) { + var result; + try { + result = this.resultSelector.apply(this, values); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(result); + }; + return CombineLatestSubscriber; +}(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_3__[/* OuterSubscriber */ "a"])); - return str.replace(matchOperatorsRe, '\\$&'); -}; +//# sourceMappingURL=combineLatest.js.map /***/ }), -/* 52 */ -/***/ (function(module, exports, __webpack_require__) { - -var conversions = __webpack_require__(77); -var route = __webpack_require__(140); - -var convert = {}; - -var models = Object.keys(conversions); - -function wrapRaw(fn) { - var wrappedFn = function (args) { - if (args === undefined || args === null) { - return args; - } - - if (arguments.length > 1) { - args = Array.prototype.slice.call(arguments); - } +/* 50 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - return fn(args); - }; +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return mergeAll; }); +/* harmony import */ var _mergeMap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27); +/* harmony import */ var _util_identity__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(21); +/** PURE_IMPORTS_START _mergeMap,_util_identity PURE_IMPORTS_END */ - // preserve .conversion property if there is one - if ('conversion' in fn) { - wrappedFn.conversion = fn.conversion; - } - return wrappedFn; +function mergeAll(concurrent) { + if (concurrent === void 0) { + concurrent = Number.POSITIVE_INFINITY; + } + return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__[/* mergeMap */ "a"])(_util_identity__WEBPACK_IMPORTED_MODULE_1__[/* identity */ "a"], concurrent); } +//# sourceMappingURL=mergeAll.js.map -function wrapRounded(fn) { - var wrappedFn = function (args) { - if (args === undefined || args === null) { - return args; - } - - if (arguments.length > 1) { - args = Array.prototype.slice.call(arguments); - } - var result = fn(args); +/***/ }), +/* 51 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - // we're assuming the result is an array here. - // see notice in conversions.js; don't use box types - // in conversion functions. - if (typeof result === 'object') { - for (var len = result.length, i = 0; i < len; i++) { - result[i] = Math.round(result[i]); - } - } +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return defer; }); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2); +/* harmony import */ var _from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(15); +/* harmony import */ var _empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9); +/** PURE_IMPORTS_START _Observable,_from,_empty PURE_IMPORTS_END */ - return result; - }; - // preserve .conversion property if there is one - if ('conversion' in fn) { - wrappedFn.conversion = fn.conversion; - } - return wrappedFn; +function defer(observableFactory) { + return new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](function (subscriber) { + var input; + try { + input = observableFactory(); + } + catch (err) { + subscriber.error(err); + return undefined; + } + var source = input ? Object(_from__WEBPACK_IMPORTED_MODULE_1__[/* from */ "a"])(input) : Object(_empty__WEBPACK_IMPORTED_MODULE_2__[/* empty */ "b"])(); + return source.subscribe(subscriber); + }); } - -models.forEach(function (fromModel) { - convert[fromModel] = {}; - - Object.defineProperty(convert[fromModel], 'channels', {value: conversions[fromModel].channels}); - Object.defineProperty(convert[fromModel], 'labels', {value: conversions[fromModel].labels}); - - var routes = route(fromModel); - var routeModels = Object.keys(routes); - - routeModels.forEach(function (toModel) { - var fn = routes[toModel]; - - convert[fromModel][toModel] = wrapRounded(fn); - convert[fromModel][toModel].raw = wrapRaw(fn); - }); -}); - -module.exports = convert; +//# sourceMappingURL=defer.js.map /***/ }), -/* 53 */ -/***/ (function(module, exports) { +/* 52 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -module.exports = require("os"); +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return zip; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ZipOperator; }); +/* unused harmony export ZipSubscriber */ +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _fromArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(17); +/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(11); +/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1); +/* harmony import */ var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(4); +/* harmony import */ var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(3); +/* harmony import */ var _internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(23); +/** PURE_IMPORTS_START tslib,_fromArray,_util_isArray,_Subscriber,_OuterSubscriber,_util_subscribeToResult,_.._internal_symbol_iterator PURE_IMPORTS_END */ -/***/ }), -/* 54 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); -/* - * 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. - */ -let parallelizeBatches = exports.parallelizeBatches = (() => { - var _ref = _asyncToGenerator(function* (batches, fn) { - for (const batch of batches) { - // We need to make sure the entire batch has completed before we can move on - // to the next batch - yield parallelize(batch, fn); - } - }); - return function parallelizeBatches(_x, _x2) { - return _ref.apply(this, arguments); + +function zip() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i] = arguments[_i]; + } + var resultSelector = observables[observables.length - 1]; + if (typeof resultSelector === 'function') { + observables.pop(); + } + return Object(_fromArray__WEBPACK_IMPORTED_MODULE_1__[/* fromArray */ "a"])(observables, undefined).lift(new ZipOperator(resultSelector)); +} +var ZipOperator = /*@__PURE__*/ (function () { + function ZipOperator(resultSelector) { + this.resultSelector = resultSelector; + } + ZipOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new ZipSubscriber(subscriber, this.resultSelector)); }; -})(); + return ZipOperator; +}()); -let parallelize = exports.parallelize = (() => { - var _ref2 = _asyncToGenerator(function* (items, fn, concurrency = 4) { - if (items.length === 0) { - return; +var ZipSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](ZipSubscriber, _super); + function ZipSubscriber(destination, resultSelector, values) { + if (values === void 0) { + values = Object.create(null); } - return new Promise(function (resolve, reject) { - let scheduleItem = (() => { - var _ref3 = _asyncToGenerator(function* (item) { - activePromises++; - try { - yield fn(item); - activePromises--; - if (values.length > 0) { - // We have more work to do, so we schedule the next promise - scheduleItem(values.shift()); - } else if (activePromises === 0) { - // We have no more values left, and all items have completed, so we've - // completed all the work. - resolve(); - } - } catch (error) { - reject(error); - } - }); - - return function scheduleItem(_x5) { - return _ref3.apply(this, arguments); - }; - })(); - - let activePromises = 0; - const values = items.slice(0); - - values.splice(0, concurrency).map(scheduleItem); - }); - }); - - return function parallelize(_x3, _x4) { - return _ref2.apply(this, arguments); - }; -})(); - -function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } - -/***/ }), -/* 55 */ -/***/ (function(module, exports, __webpack_require__) { - -module.exports = minimatch -minimatch.Minimatch = Minimatch - -var path = { sep: '/' } -try { - path = __webpack_require__(2) -} catch (er) {} - -var GLOBSTAR = minimatch.GLOBSTAR = Minimatch.GLOBSTAR = {} -var expand = __webpack_require__(154) - -var plTypes = { - '!': { open: '(?:(?!(?:', close: '))[^/]*?)'}, - '?': { open: '(?:', close: ')?' }, - '+': { open: '(?:', close: ')+' }, - '*': { open: '(?:', close: ')*' }, - '@': { open: '(?:', close: ')' } -} - -// any single thing other than / -// don't need to escape / when using new RegExp() -var qmark = '[^/]' - -// * => any number of characters -var star = qmark + '*?' - -// ** when dots are allowed. Anything goes, except .. and . -// not (^ or / followed by one or two dots followed by $ or /), -// followed by anything, any number of times. -var twoStarDot = '(?:(?!(?:\\\/|^)(?:\\.{1,2})($|\\\/)).)*?' - -// not a ^ or / followed by a dot, -// followed by anything, any number of times. -var twoStarNoDot = '(?:(?!(?:\\\/|^)\\.).)*?' - -// characters that need to be escaped in RegExp. -var reSpecials = charSet('().*{}+?[]^$\\!') - -// "abc" -> { a:true, b:true, c:true } -function charSet (s) { - return s.split('').reduce(function (set, c) { - set[c] = true - return set - }, {}) -} - -// normalizes slashes. -var slashSplit = /\/+/ - -minimatch.filter = filter -function filter (pattern, options) { - options = options || {} - return function (p, i, list) { - return minimatch(p, pattern, options) - } -} - -function ext (a, b) { - a = a || {} - b = b || {} - var t = {} - Object.keys(b).forEach(function (k) { - t[k] = b[k] - }) - Object.keys(a).forEach(function (k) { - t[k] = a[k] - }) - return t -} - -minimatch.defaults = function (def) { - if (!def || !Object.keys(def).length) return minimatch - - var orig = minimatch - - var m = function minimatch (p, pattern, options) { - return orig.minimatch(p, pattern, ext(def, options)) - } - - m.Minimatch = function Minimatch (pattern, options) { - return new orig.Minimatch(pattern, ext(def, options)) - } - - return m -} - -Minimatch.defaults = function (def) { - if (!def || !Object.keys(def).length) return Minimatch - return minimatch.defaults(def).Minimatch -} - -function minimatch (p, pattern, options) { - if (typeof pattern !== 'string') { - throw new TypeError('glob pattern string required') - } - - if (!options) options = {} - - // shortcut: comments match nothing. - if (!options.nocomment && pattern.charAt(0) === '#') { - return false - } - - // "" only matches "" - if (pattern.trim() === '') return p === '' - - return new Minimatch(pattern, options).match(p) -} - -function Minimatch (pattern, options) { - if (!(this instanceof Minimatch)) { - return new Minimatch(pattern, options) - } - - if (typeof pattern !== 'string') { - throw new TypeError('glob pattern string required') - } - - if (!options) options = {} - pattern = pattern.trim() - - // windows support: need to use /, not \ - if (path.sep !== '/') { - pattern = pattern.split(path.sep).join('/') - } - - this.options = options - this.set = [] - this.pattern = pattern - this.regexp = null - this.negate = false - this.comment = false - this.empty = false - - // make the set of regexps etc. - this.make() -} - -Minimatch.prototype.debug = function () {} - -Minimatch.prototype.make = make -function make () { - // don't do it more than once. - if (this._made) return - - var pattern = this.pattern - var options = this.options - - // empty patterns and comments match nothing. - if (!options.nocomment && pattern.charAt(0) === '#') { - this.comment = true - return - } - if (!pattern) { - this.empty = true - return - } - - // step 1: figure out negation, etc. - this.parseNegate() - - // step 2: expand braces - var set = this.globSet = this.braceExpand() - - if (options.debug) this.debug = console.error - - this.debug(this.pattern, set) - - // step 3: now we have a set, so turn each one into a series of path-portion - // matching patterns. - // These will be regexps, except in the case of "**", which is - // set to the GLOBSTAR object for globstar behavior, - // and will not contain any / characters - set = this.globParts = set.map(function (s) { - return s.split(slashSplit) - }) - - this.debug(this.pattern, set) - - // glob --> regexps - set = set.map(function (s, si, set) { - return s.map(this.parse, this) - }, this) - - this.debug(this.pattern, set) - - // filter out everything that didn't compile properly. - set = set.filter(function (s) { - return s.indexOf(false) === -1 - }) - - this.debug(this.pattern, set) - - this.set = set -} - -Minimatch.prototype.parseNegate = parseNegate -function parseNegate () { - var pattern = this.pattern - var negate = false - var options = this.options - var negateOffset = 0 - - if (options.nonegate) return - - for (var i = 0, l = pattern.length - ; i < l && pattern.charAt(i) === '!' - ; i++) { - negate = !negate - negateOffset++ - } - - if (negateOffset) this.pattern = pattern.substr(negateOffset) - this.negate = negate -} - -// Brace expansion: -// a{b,c}d -> abd acd -// a{b,}c -> abc ac -// a{0..3}d -> a0d a1d a2d a3d -// a{b,c{d,e}f}g -> abg acdfg acefg -// a{b,c}d{e,f}g -> abdeg acdeg abdeg abdfg -// -// Invalid sets are not expanded. -// a{2..}b -> a{2..}b -// a{b}c -> a{b}c -minimatch.braceExpand = function (pattern, options) { - return braceExpand(pattern, options) -} - -Minimatch.prototype.braceExpand = braceExpand - -function braceExpand (pattern, options) { - if (!options) { - if (this instanceof Minimatch) { - options = this.options - } else { - options = {} - } - } - - pattern = typeof pattern === 'undefined' - ? this.pattern : pattern - - if (typeof pattern === 'undefined') { - throw new TypeError('undefined pattern') - } - - if (options.nobrace || - !pattern.match(/\{.*\}/)) { - // shortcut. no need to expand. - return [pattern] - } - - return expand(pattern) -} - -// parse a component of the expanded set. -// At this point, no pattern may contain "/" in it -// so we're going to return a 2d array, where each entry is the full -// pattern, split on '/', and then turned into a regular expression. -// A regexp is made at the end which joins each array with an -// escaped /, and another full one which joins each regexp with |. -// -// Following the lead of Bash 4.1, note that "**" only has special meaning -// when it is the *only* thing in a path portion. Otherwise, any series -// of * is equivalent to a single *. Globstar behavior is enabled by -// default, and can be disabled by setting options.noglobstar. -Minimatch.prototype.parse = parse -var SUBPARSE = {} -function parse (pattern, isSub) { - if (pattern.length > 1024 * 64) { - throw new TypeError('pattern is too long') - } - - var options = this.options - - // shortcuts - if (!options.noglobstar && pattern === '**') return GLOBSTAR - if (pattern === '') return '' - - var re = '' - var hasMagic = !!options.nocase - var escaping = false - // ? => one single character - var patternListStack = [] - var negativeLists = [] - var stateChar - var inClass = false - var reClassStart = -1 - var classStart = -1 - // . and .. never match anything that doesn't start with ., - // even when options.dot is set. - var patternStart = pattern.charAt(0) === '.' ? '' // anything - // not (start or / followed by . or .. followed by / or end) - : options.dot ? '(?!(?:^|\\\/)\\.{1,2}(?:$|\\\/))' - : '(?!\\.)' - var self = this - - function clearStateChar () { - if (stateChar) { - // we had some state-tracking character - // that wasn't consumed by this pass. - switch (stateChar) { - case '*': - re += star - hasMagic = true - break - case '?': - re += qmark - hasMagic = true - break - default: - re += '\\' + stateChar - break - } - self.debug('clearStateChar %j %j', stateChar, re) - stateChar = false - } - } - - for (var i = 0, len = pattern.length, c - ; (i < len) && (c = pattern.charAt(i)) - ; i++) { - this.debug('%s\t%s %s %j', pattern, i, re, c) - - // skip over any that are escaped. - if (escaping && reSpecials[c]) { - re += '\\' + c - escaping = false - continue + var _this = _super.call(this, destination) || this; + _this.iterators = []; + _this.active = 0; + _this.resultSelector = (typeof resultSelector === 'function') ? resultSelector : null; + _this.values = values; + return _this; } - - switch (c) { - case '/': - // completely not allowed, even escaped. - // Should already be path-split by now. - return false - - case '\\': - clearStateChar() - escaping = true - continue - - // the various stateChar values - // for the "extglob" stuff. - case '?': - case '*': - case '+': - case '@': - case '!': - this.debug('%s\t%s %s %j <-- stateChar', pattern, i, re, c) - - // all of those are literals inside a class, except that - // the glob [!a] means [^a] in regexp - if (inClass) { - this.debug(' in class') - if (c === '!' && i === classStart + 1) c = '^' - re += c - continue + ZipSubscriber.prototype._next = function (value) { + var iterators = this.iterators; + if (Object(_util_isArray__WEBPACK_IMPORTED_MODULE_2__[/* isArray */ "a"])(value)) { + iterators.push(new StaticArrayIterator(value)); } - - // if we already have a stateChar, then it means - // that there was something like ** or +? in there. - // Handle the stateChar, then proceed with this one. - self.debug('call clearStateChar %j', stateChar) - clearStateChar() - stateChar = c - // if extglob is disabled, then +(asdf|foo) isn't a thing. - // just clear the statechar *now*, rather than even diving into - // the patternList stuff. - if (options.noext) clearStateChar() - continue - - case '(': - if (inClass) { - re += '(' - continue + else if (typeof value[_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_6__[/* iterator */ "a"]] === 'function') { + iterators.push(new StaticIterator(value[_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_6__[/* iterator */ "a"]]())); } - - if (!stateChar) { - re += '\\(' - continue + else { + iterators.push(new ZipBufferIterator(this.destination, this, value)); } - - patternListStack.push({ - type: stateChar, - start: i - 1, - reStart: re.length, - open: plTypes[stateChar].open, - close: plTypes[stateChar].close - }) - // negation is (?:(?!js)[^/]*) - re += stateChar === '!' ? '(?:(?!(?:' : '(?:' - this.debug('plType %j %j', stateChar, re) - stateChar = false - continue - - case ')': - if (inClass || !patternListStack.length) { - re += '\\)' - continue + }; + ZipSubscriber.prototype._complete = function () { + var iterators = this.iterators; + var len = iterators.length; + if (len === 0) { + this.destination.complete(); + return; } - - clearStateChar() - hasMagic = true - var pl = patternListStack.pop() - // negation is (?:(?!js)[^/]*) - // The others are (?:) - re += pl.close - if (pl.type === '!') { - negativeLists.push(pl) + this.active = len; + for (var i = 0; i < len; i++) { + var iterator = iterators[i]; + if (iterator.stillUnsubscribed) { + this.add(iterator.subscribe(iterator, i)); + } + else { + this.active--; + } } - pl.reEnd = re.length - continue - - case '|': - if (inClass || !patternListStack.length || escaping) { - re += '\\|' - escaping = false - continue + }; + ZipSubscriber.prototype.notifyInactive = function () { + this.active--; + if (this.active === 0) { + this.destination.complete(); } - - clearStateChar() - re += '|' - continue - - // these are mostly the same in regexp and glob - case '[': - // swallow any state-tracking char before the [ - clearStateChar() - - if (inClass) { - re += '\\' + c - continue + }; + ZipSubscriber.prototype.checkIterators = function () { + var iterators = this.iterators; + var len = iterators.length; + var destination = this.destination; + for (var i = 0; i < len; i++) { + var iterator = iterators[i]; + if (typeof iterator.hasValue === 'function' && !iterator.hasValue()) { + return; + } } - - inClass = true - classStart = i - reClassStart = re.length - re += c - continue - - case ']': - // a right bracket shall lose its special - // meaning and represent itself in - // a bracket expression if it occurs - // first in the list. -- POSIX.2 2.8.3.2 - if (i === classStart + 1 || !inClass) { - re += '\\' + c - escaping = false - continue + var shouldComplete = false; + var args = []; + for (var i = 0; i < len; i++) { + var iterator = iterators[i]; + var result = iterator.next(); + if (iterator.hasCompleted()) { + shouldComplete = true; + } + if (result.done) { + destination.complete(); + return; + } + args.push(result.value); } - - // handle the case where we left a class open. - // "[z-a]" is valid, equivalent to "\[z-a\]" - if (inClass) { - // split where the last [ was, make sure we don't have - // an invalid re. if so, re-walk the contents of the - // would-be class to re-translate any characters that - // were passed through as-is - // TODO: It would probably be faster to determine this - // without a try/catch and a new RegExp, but it's tricky - // to do safely. For now, this is safe and works. - var cs = pattern.substring(classStart + 1, i) - try { - RegExp('[' + cs + ']') - } catch (er) { - // not a valid class! - var sp = this.parse(cs, SUBPARSE) - re = re.substr(0, reClassStart) + '\\[' + sp[0] + '\\]' - hasMagic = hasMagic || sp[1] - inClass = false - continue - } + if (this.resultSelector) { + this._tryresultSelector(args); } - - // finish up the class. - hasMagic = true - inClass = false - re += c - continue - - default: - // swallow any state char that wasn't consumed - clearStateChar() - - if (escaping) { - // no need - escaping = false - } else if (reSpecials[c] - && !(c === '^' && inClass)) { - re += '\\' + else { + destination.next(args); } + if (shouldComplete) { + destination.complete(); + } + }; + ZipSubscriber.prototype._tryresultSelector = function (args) { + var result; + try { + result = this.resultSelector.apply(this, args); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(result); + }; + return ZipSubscriber; +}(_Subscriber__WEBPACK_IMPORTED_MODULE_3__[/* Subscriber */ "a"])); - re += c - - } // switch - } // for - - // handle the case where we left a class open. - // "[abc" is valid, equivalent to "\[abc" - if (inClass) { - // split where the last [ was, and escape it - // this is a huge pita. We now have to re-walk - // the contents of the would-be class to re-translate - // any characters that were passed through as-is - cs = pattern.substr(classStart + 1) - sp = this.parse(cs, SUBPARSE) - re = re.substr(0, reClassStart) + '\\[' + sp[0] - hasMagic = hasMagic || sp[1] - } - - // handle the case where we had a +( thing at the *end* - // of the pattern. - // each pattern list stack adds 3 chars, and we need to go through - // and escape any | chars that were passed through as-is for the regexp. - // Go through and escape them, taking care not to double-escape any - // | chars that were already escaped. - for (pl = patternListStack.pop(); pl; pl = patternListStack.pop()) { - var tail = re.slice(pl.reStart + pl.open.length) - this.debug('setting tail', re, pl) - // maybe some even number of \, then maybe 1 \, followed by a | - tail = tail.replace(/((?:\\{2}){0,64})(\\?)\|/g, function (_, $1, $2) { - if (!$2) { - // the | isn't already escaped, so escape it. - $2 = '\\' - } - - // need to escape all those slashes *again*, without escaping the - // one that we need for escaping the | character. As it works out, - // escaping an even number of slashes can be done by simply repeating - // it exactly after itself. That's why this trick works. - // - // I am sorry that you have to see this. - return $1 + $1 + $2 + '|' - }) - - this.debug('tail=%j\n %s', tail, tail, pl, re) - var t = pl.type === '*' ? star - : pl.type === '?' ? qmark - : '\\' + pl.type - - hasMagic = true - re = re.slice(0, pl.reStart) + t + '\\(' + tail - } - - // handle trailing things that only matter at the very end. - clearStateChar() - if (escaping) { - // trailing \\ - re += '\\\\' - } - - // only need to apply the nodot start if the re starts with - // something that could conceivably capture a dot - var addPatternStart = false - switch (re.charAt(0)) { - case '.': - case '[': - case '(': addPatternStart = true - } - - // Hack to work around lack of negative lookbehind in JS - // A pattern like: *.!(x).!(y|z) needs to ensure that a name - // like 'a.xyz.yz' doesn't match. So, the first negative - // lookahead, has to look ALL the way ahead, to the end of - // the pattern. - for (var n = negativeLists.length - 1; n > -1; n--) { - var nl = negativeLists[n] - - var nlBefore = re.slice(0, nl.reStart) - var nlFirst = re.slice(nl.reStart, nl.reEnd - 8) - var nlLast = re.slice(nl.reEnd - 8, nl.reEnd) - var nlAfter = re.slice(nl.reEnd) - - nlLast += nlAfter - - // Handle nested stuff like *(*.js|!(*.json)), where open parens - // mean that we should *not* include the ) in the bit that is considered - // "after" the negated section. - var openParensBefore = nlBefore.split('(').length - 1 - var cleanAfter = nlAfter - for (i = 0; i < openParensBefore; i++) { - cleanAfter = cleanAfter.replace(/\)[+*?]?/, '') - } - nlAfter = cleanAfter - - var dollar = '' - if (nlAfter === '' && isSub !== SUBPARSE) { - dollar = '$' - } - var newRe = nlBefore + nlFirst + nlAfter + dollar + nlLast - re = newRe - } - - // if the re is not "" at this point, then we need to make sure - // it doesn't match against an empty path part. - // Otherwise a/* will match a/, which it should not. - if (re !== '' && hasMagic) { - re = '(?=.)' + re - } - - if (addPatternStart) { - re = patternStart + re - } - - // parsing just a piece of a larger pattern. - if (isSub === SUBPARSE) { - return [re, hasMagic] - } - - // skip the regexp for non-magical patterns - // unescape anything in it, though, so that it'll be - // an exact match against a file etc. - if (!hasMagic) { - return globUnescape(pattern) - } - - var flags = options.nocase ? 'i' : '' - try { - var regExp = new RegExp('^' + re + '$', flags) - } catch (er) { - // If it was an invalid regular expression, then it can't match - // anything. This trick looks for a character after the end of - // the string, which is of course impossible, except in multi-line - // mode, but it's not a /m regex. - return new RegExp('$.') - } - - regExp._glob = pattern - regExp._src = re - - return regExp -} - -minimatch.makeRe = function (pattern, options) { - return new Minimatch(pattern, options || {}).makeRe() -} - -Minimatch.prototype.makeRe = makeRe -function makeRe () { - if (this.regexp || this.regexp === false) return this.regexp - - // at this point, this.set is a 2d array of partial - // pattern strings, or "**". - // - // It's better to use .match(). This function shouldn't - // be used, really, but it's pretty convenient sometimes, - // when you just want to work with a regex. - var set = this.set - - if (!set.length) { - this.regexp = false - return this.regexp - } - var options = this.options - - var twoStar = options.noglobstar ? star - : options.dot ? twoStarDot - : twoStarNoDot - var flags = options.nocase ? 'i' : '' - - var re = set.map(function (pattern) { - return pattern.map(function (p) { - return (p === GLOBSTAR) ? twoStar - : (typeof p === 'string') ? regExpEscape(p) - : p._src - }).join('\\\/') - }).join('|') - - // must match entire pattern - // ending in a * or ** will make it less strict. - re = '^(?:' + re + ')$' - - // can match anything, as long as it's not this. - if (this.negate) re = '^(?!' + re + ').*$' - - try { - this.regexp = new RegExp(re, flags) - } catch (ex) { - this.regexp = false - } - return this.regexp -} - -minimatch.match = function (list, pattern, options) { - options = options || {} - var mm = new Minimatch(pattern, options) - list = list.filter(function (f) { - return mm.match(f) - }) - if (mm.options.nonull && !list.length) { - list.push(pattern) - } - return list -} +var StaticIterator = /*@__PURE__*/ (function () { + function StaticIterator(iterator) { + this.iterator = iterator; + this.nextResult = iterator.next(); + } + StaticIterator.prototype.hasValue = function () { + return true; + }; + StaticIterator.prototype.next = function () { + var result = this.nextResult; + this.nextResult = this.iterator.next(); + return result; + }; + StaticIterator.prototype.hasCompleted = function () { + var nextResult = this.nextResult; + return nextResult && nextResult.done; + }; + return StaticIterator; +}()); +var StaticArrayIterator = /*@__PURE__*/ (function () { + function StaticArrayIterator(array) { + this.array = array; + this.index = 0; + this.length = 0; + this.length = array.length; + } + StaticArrayIterator.prototype[_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_6__[/* iterator */ "a"]] = function () { + return this; + }; + StaticArrayIterator.prototype.next = function (value) { + var i = this.index++; + var array = this.array; + return i < this.length ? { value: array[i], done: false } : { value: null, done: true }; + }; + StaticArrayIterator.prototype.hasValue = function () { + return this.array.length > this.index; + }; + StaticArrayIterator.prototype.hasCompleted = function () { + return this.array.length === this.index; + }; + return StaticArrayIterator; +}()); +var ZipBufferIterator = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](ZipBufferIterator, _super); + function ZipBufferIterator(destination, parent, observable) { + var _this = _super.call(this, destination) || this; + _this.parent = parent; + _this.observable = observable; + _this.stillUnsubscribed = true; + _this.buffer = []; + _this.isComplete = false; + return _this; + } + ZipBufferIterator.prototype[_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_6__[/* iterator */ "a"]] = function () { + return this; + }; + ZipBufferIterator.prototype.next = function () { + var buffer = this.buffer; + if (buffer.length === 0 && this.isComplete) { + return { value: null, done: true }; + } + else { + return { value: buffer.shift(), done: false }; + } + }; + ZipBufferIterator.prototype.hasValue = function () { + return this.buffer.length > 0; + }; + ZipBufferIterator.prototype.hasCompleted = function () { + return this.buffer.length === 0 && this.isComplete; + }; + ZipBufferIterator.prototype.notifyComplete = function () { + if (this.buffer.length > 0) { + this.isComplete = true; + this.parent.notifyInactive(); + } + else { + this.destination.complete(); + } + }; + ZipBufferIterator.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.buffer.push(innerValue); + this.parent.checkIterators(); + }; + ZipBufferIterator.prototype.subscribe = function (value, index) { + return Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_5__[/* subscribeToResult */ "a"])(this, this.observable, this, index); + }; + return ZipBufferIterator; +}(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_4__[/* OuterSubscriber */ "a"])); +//# sourceMappingURL=zip.js.map -Minimatch.prototype.match = match -function match (f, partial) { - this.debug('match', f, this.pattern) - // short-circuit in the case of busted things. - // comments, etc. - if (this.comment) return false - if (this.empty) return f === '' - if (f === '/' && partial) return true +/***/ }), +/* 53 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - var options = this.options +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return scalar; }); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2); +/** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ - // windows: need to use /, not \ - if (path.sep !== '/') { - f = f.split(path.sep).join('/') - } +function scalar(value) { + var result = new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](function (subscriber) { + subscriber.next(value); + subscriber.complete(); + }); + result._isScalar = true; + result.value = value; + return result; +} +//# sourceMappingURL=scalar.js.map - // treat the test path as a set of pathparts. - f = f.split(slashSplit) - this.debug(this.pattern, 'split', f) - // just ONE of the pattern sets in this.set needs to match - // in order for it to be valid. If negating, then just one - // match means that we have failed. - // Either way, return on the first hit. +/***/ }), +/* 54 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - var set = this.set - this.debug(this.pattern, 'set', set) +"use strict"; - // Find the basename of the path by looking for the last non-empty segment - var filename - var i - for (i = f.length - 1; i >= 0; i--) { - filename = f[i] - if (filename) break - } +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/node_modules/tslib/tslib.es6.js +var tslib_es6 = __webpack_require__(0); - for (i = 0; i < set.length; i++) { - var pattern = set[i] - var file = f - if (options.matchBase && pattern.length === 1) { - file = [filename] - } - var hit = this.matchOne(file, pattern, partial) - if (hit) { - if (options.flipNegate) return true - return !this.negate +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/Immediate.js +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +var nextHandle = 1; +var tasksByHandle = {}; +function runIfPresent(handle) { + var cb = tasksByHandle[handle]; + if (cb) { + cb(); } - } - - // didn't get any hits. this is success if it's a negative - // pattern, failure otherwise. - if (options.flipNegate) return false - return this.negate } +var Immediate = { + setImmediate: function (cb) { + var handle = nextHandle++; + tasksByHandle[handle] = cb; + Promise.resolve().then(function () { return runIfPresent(handle); }); + return handle; + }, + clearImmediate: function (handle) { + delete tasksByHandle[handle]; + }, +}; +//# sourceMappingURL=Immediate.js.map -// set partial to true to test if, for example, -// "/a/b" matches the start of "/*/b/*/d" -// Partial means, if you run out of file before you run -// out of pattern, then that's fine, as long as all -// the parts match. -Minimatch.prototype.matchOne = function (file, pattern, partial) { - var options = this.options - - this.debug('matchOne', - { 'this': this, file: file, pattern: pattern }) - - this.debug('matchOne', file.length, pattern.length) - - for (var fi = 0, - pi = 0, - fl = file.length, - pl = pattern.length - ; (fi < fl) && (pi < pl) - ; fi++, pi++) { - this.debug('matchOne loop') - var p = pattern[pi] - var f = file[fi] +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsyncAction.js + 1 modules +var AsyncAction = __webpack_require__(34); - this.debug(pattern, p, f) +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsapAction.js +/** PURE_IMPORTS_START tslib,_util_Immediate,_AsyncAction PURE_IMPORTS_END */ - // should be impossible. - // some invalid regexp stuff in the set. - if (p === false) return false - if (p === GLOBSTAR) { - this.debug('GLOBSTAR', [pattern, p, f]) - // "**" - // a/**/b/**/c would match the following: - // a/b/x/y/z/c - // a/x/y/z/b/c - // a/b/x/b/x/c - // a/b/c - // To do this, take the rest of the pattern after - // the **, and see if it would match the file remainder. - // If so, return success. - // If not, the ** "swallows" a segment, and try again. - // This is recursively awful. - // - // a/**/b/**/c matching a/b/x/y/z/c - // - a matches a - // - doublestar - // - matchOne(b/x/y/z/c, b/**/c) - // - b matches b - // - doublestar - // - matchOne(x/y/z/c, c) -> no - // - matchOne(y/z/c, c) -> no - // - matchOne(z/c, c) -> no - // - matchOne(c, c) yes, hit - var fr = fi - var pr = pi + 1 - if (pr === pl) { - this.debug('** at the end') - // a ** at the end will just swallow the rest. - // We have found a match. - // however, it will not swallow /.x, unless - // options.dot is set. - // . and .. are *never* matched by **, for explosively - // exponential reasons. - for (; fi < fl; fi++) { - if (file[fi] === '.' || file[fi] === '..' || - (!options.dot && file[fi].charAt(0) === '.')) return false +var AsapAction_AsapAction = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](AsapAction, _super); + function AsapAction(scheduler, work) { + var _this = _super.call(this, scheduler, work) || this; + _this.scheduler = scheduler; + _this.work = work; + return _this; + } + AsapAction.prototype.requestAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; + } + if (delay !== null && delay > 0) { + return _super.prototype.requestAsyncId.call(this, scheduler, id, delay); + } + scheduler.actions.push(this); + return scheduler.scheduled || (scheduler.scheduled = Immediate.setImmediate(scheduler.flush.bind(scheduler, null))); + }; + AsapAction.prototype.recycleAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; } - return true - } + if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { + return _super.prototype.recycleAsyncId.call(this, scheduler, id, delay); + } + if (scheduler.actions.length === 0) { + Immediate.clearImmediate(id); + scheduler.scheduled = undefined; + } + return undefined; + }; + return AsapAction; +}(AsyncAction["a" /* AsyncAction */])); - // ok, let's see if we can swallow whatever we can. - while (fr < fl) { - var swallowee = file[fr] +//# sourceMappingURL=AsapAction.js.map - this.debug('\nglobstar while', file, fr, pattern, pr, swallowee) +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsyncScheduler.js +var AsyncScheduler = __webpack_require__(32); - // XXX remove this slice. Just pass the start index. - if (this.matchOne(file.slice(fr), pattern.slice(pr), partial)) { - this.debug('globstar found match!', fr, fl, swallowee) - // found a match. - return true - } else { - // can't swallow "." or ".." ever. - // can only swallow ".foo" when explicitly asked. - if (swallowee === '.' || swallowee === '..' || - (!options.dot && swallowee.charAt(0) === '.')) { - this.debug('dot detected!', file, fr, pattern, pr) - break - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsapScheduler.js +/** PURE_IMPORTS_START tslib,_AsyncScheduler PURE_IMPORTS_END */ - // ** swallows a segment, and continue. - this.debug('globstar swallow a segment, and continue') - fr++ - } - } - // no match was found. - // However, in partial mode, we can't say this is necessarily over. - // If there's more *pattern* left, then - if (partial) { - // ran out of file - this.debug('\n>>> no match, partial?', file, fr, pattern, pr) - if (fr === fl) return true - } - return false +var AsapScheduler_AsapScheduler = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](AsapScheduler, _super); + function AsapScheduler() { + return _super !== null && _super.apply(this, arguments) || this; } + AsapScheduler.prototype.flush = function (action) { + this.active = true; + this.scheduled = undefined; + var actions = this.actions; + var error; + var index = -1; + var count = actions.length; + action = action || actions.shift(); + do { + if (error = action.execute(action.state, action.delay)) { + break; + } + } while (++index < count && (action = actions.shift())); + this.active = false; + if (error) { + while (++index < count && (action = actions.shift())) { + action.unsubscribe(); + } + throw error; + } + }; + return AsapScheduler; +}(AsyncScheduler["a" /* AsyncScheduler */])); - // something other than ** - // non-magic patterns just have to match exactly - // patterns with magic have been turned into regexps. - var hit - if (typeof p === 'string') { - if (options.nocase) { - hit = f.toLowerCase() === p.toLowerCase() - } else { - hit = f === p - } - this.debug('string match', p, f, hit) - } else { - hit = f.match(p) - this.debug('pattern match', p, f, hit) - } +//# sourceMappingURL=AsapScheduler.js.map - if (!hit) return false - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/asap.js +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return asap; }); +/** PURE_IMPORTS_START _AsapAction,_AsapScheduler PURE_IMPORTS_END */ - // Note: ending in / means that we'll get a final "" - // at the end of the pattern. This can only match a - // corresponding "" at the end of the file. - // If the file ends in /, then it can only match a - // a pattern that ends in /, unless the pattern just - // doesn't have any more for it. But, a/b/ should *not* - // match "a/b/*", even though "" matches against the - // [^/]*? pattern, except in partial mode, where it might - // simply not be reached yet. - // However, a/b/ should still satisfy a/* - // now either we fell off the end of the pattern, or we're done. - if (fi === fl && pi === pl) { - // ran out of pattern and filename at the same time. - // an exact hit! - return true - } else if (fi === fl) { - // ran out of file, but still had pattern left. - // this is ok if we're doing the match as part of - // a glob fs traversal. - return partial - } else if (pi === pl) { - // ran out of pattern, still have file left. - // this is only acceptable if we're on the very last - // empty segment of a file with a trailing slash. - // a/* should match a/b/ - var emptyFileEnd = (fi === fl - 1) && (file[fi] === '') - return emptyFileEnd - } +var asap = /*@__PURE__*/ new AsapScheduler_AsapScheduler(AsapAction_AsapAction); +//# sourceMappingURL=asap.js.map - // should be unreachable. - throw new Error('wtf?') -} -// replace stuff like \* with * -function globUnescape (s) { - return s.replace(/\\(.)/g, '$1') -} +/***/ }), +/* 55 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -function regExpEscape (s) { - return s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&') -} +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return empty; }); +/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(18); +/* harmony import */ var _util_hostReportError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(37); +/** PURE_IMPORTS_START _config,_util_hostReportError PURE_IMPORTS_END */ + + +var empty = { + closed: true, + next: function (value) { }, + error: function (err) { + if (_config__WEBPACK_IMPORTED_MODULE_0__[/* config */ "a"].useDeprecatedSynchronousErrorHandling) { + throw err; + } + else { + Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_1__[/* hostReportError */ "a"])(err); + } + }, + complete: function () { } +}; +//# sourceMappingURL=Observer.js.map /***/ }), /* 56 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +var fs = __webpack_require__(16) +var polyfills = __webpack_require__(132) +var legacy = __webpack_require__(134) +var queue = [] +var util = __webpack_require__(19) -function posix(path) { - return path.charAt(0) === '/'; -} +function noop () {} -function win32(path) { - // https://github.com/nodejs/node/blob/b3fcc245fb25539909ef1d5eaa01dbf92e168633/lib/path.js#L56 - var splitDeviceRe = /^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/; - var result = splitDeviceRe.exec(path); - var device = result[1] || ''; - var isUnc = Boolean(device && device.charAt(1) !== ':'); +var debug = noop +if (util.debuglog) + debug = util.debuglog('gfs4') +else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || '')) + debug = function() { + var m = util.format.apply(util, arguments) + m = 'GFS4: ' + m.split(/\n/).join('\nGFS4: ') + console.error(m) + } - // UNC paths are always absolute - return Boolean(result[2] || isUnc); +if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || '')) { + process.on('exit', function() { + debug(queue) + __webpack_require__(57).equal(queue.length, 0) + }) } -module.exports = process.platform === 'win32' ? win32 : posix; -module.exports.posix = posix; -module.exports.win32 = win32; +module.exports = patch(__webpack_require__(94)) +if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH) { + module.exports = patch(fs) +} + +// Always patch fs.close/closeSync, because we want to +// retry() whenever a close happens *anywhere* in the program. +// This is essential when multiple graceful-fs instances are +// in play at the same time. +module.exports.close = +fs.close = (function (fs$close) { return function (fd, cb) { + return fs$close.call(fs, fd, function (err) { + if (!err) + retry() + if (typeof cb === 'function') + cb.apply(this, arguments) + }) +}})(fs.close) -/***/ }), -/* 57 */ -/***/ (function(module, exports, __webpack_require__) { +module.exports.closeSync = +fs.closeSync = (function (fs$closeSync) { return function (fd) { + // Note that graceful-fs also retries when fs.closeSync() fails. + // Looks like a bug to me, although it's probably a harmless one. + var rval = fs$closeSync.apply(fs, arguments) + retry() + return rval +}})(fs.closeSync) -"use strict"; +function patch (fs) { + // Everything that references the open() function needs to be in here + polyfills(fs) + fs.gracefulify = patch + fs.FileReadStream = ReadStream; // Legacy name. + fs.FileWriteStream = WriteStream; // Legacy name. + fs.createReadStream = createReadStream + fs.createWriteStream = createWriteStream + var fs$readFile = fs.readFile + fs.readFile = readFile + function readFile (path, options, cb) { + if (typeof options === 'function') + cb = options, options = null + return go$readFile(path, options, cb) -Object.defineProperty(exports, "__esModule", { - value: true -}); -/* - * 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. - */ -class CliError extends Error { - constructor(message, meta = {}) { - super(message); - this.meta = meta; + function go$readFile (path, options, cb) { + return fs$readFile(path, options, function (err) { + if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) + enqueue([go$readFile, [path, options, cb]]) + else { + if (typeof cb === 'function') + cb.apply(this, arguments) + retry() + } + }) } -} -exports.CliError = CliError; - -/***/ }), -/* 58 */ -/***/ (function(module, exports, __webpack_require__) { + } -// Note: since nyc uses this module to output coverage, any lines -// that are in the direct sync flow of nyc's outputCoverage are -// ignored, since we can never get coverage for them. -var assert = __webpack_require__(28) -var signals = __webpack_require__(189) + var fs$writeFile = fs.writeFile + fs.writeFile = writeFile + function writeFile (path, data, options, cb) { + if (typeof options === 'function') + cb = options, options = null -var EE = __webpack_require__(40) -/* istanbul ignore if */ -if (typeof EE !== 'function') { - EE = EE.EventEmitter -} + return go$writeFile(path, data, options, cb) -var emitter -if (process.__signal_exit_emitter__) { - emitter = process.__signal_exit_emitter__ -} else { - emitter = process.__signal_exit_emitter__ = new EE() - emitter.count = 0 - emitter.emitted = {} -} + function go$writeFile (path, data, options, cb) { + return fs$writeFile(path, data, options, function (err) { + if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) + enqueue([go$writeFile, [path, data, options, cb]]) + else { + if (typeof cb === 'function') + cb.apply(this, arguments) + retry() + } + }) + } + } -// Because this emitter is a global, we have to check to see if a -// previous version of this library failed to enable infinite listeners. -// I know what you're about to say. But literally everything about -// signal-exit is a compromise with evil. Get used to it. -if (!emitter.infinite) { - emitter.setMaxListeners(Infinity) - emitter.infinite = true -} + var fs$appendFile = fs.appendFile + if (fs$appendFile) + fs.appendFile = appendFile + function appendFile (path, data, options, cb) { + if (typeof options === 'function') + cb = options, options = null -module.exports = function (cb, opts) { - assert.equal(typeof cb, 'function', 'a callback must be provided for exit handler') + return go$appendFile(path, data, options, cb) - if (loaded === false) { - load() + function go$appendFile (path, data, options, cb) { + return fs$appendFile(path, data, options, function (err) { + if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) + enqueue([go$appendFile, [path, data, options, cb]]) + else { + if (typeof cb === 'function') + cb.apply(this, arguments) + retry() + } + }) + } } - var ev = 'exit' - if (opts && opts.alwaysLast) { - ev = 'afterexit' - } + var fs$readdir = fs.readdir + fs.readdir = readdir + function readdir (path, options, cb) { + var args = [path] + if (typeof options !== 'function') { + args.push(options) + } else { + cb = options + } + args.push(go$readdir$cb) - var remove = function () { - emitter.removeListener(ev, cb) - if (emitter.listeners('exit').length === 0 && - emitter.listeners('afterexit').length === 0) { - unload() + return go$readdir(args) + + function go$readdir$cb (err, files) { + if (files && files.sort) + files.sort() + + if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) + enqueue([go$readdir, [args]]) + else { + if (typeof cb === 'function') + cb.apply(this, arguments) + retry() + } } } - emitter.on(ev, cb) - return remove -} + function go$readdir (args) { + return fs$readdir.apply(fs, args) + } -module.exports.unload = unload -function unload () { - if (!loaded) { - return + if (process.version.substr(0, 4) === 'v0.8') { + var legStreams = legacy(fs) + ReadStream = legStreams.ReadStream + WriteStream = legStreams.WriteStream } - loaded = false - signals.forEach(function (sig) { - try { - process.removeListener(sig, sigListeners[sig]) - } catch (er) {} - }) - process.emit = originalProcessEmit - process.reallyExit = originalProcessReallyExit - emitter.count -= 1 -} + var fs$ReadStream = fs.ReadStream + ReadStream.prototype = Object.create(fs$ReadStream.prototype) + ReadStream.prototype.open = ReadStream$open -function emit (event, code, signal) { - if (emitter.emitted[event]) { - return + var fs$WriteStream = fs.WriteStream + WriteStream.prototype = Object.create(fs$WriteStream.prototype) + WriteStream.prototype.open = WriteStream$open + + fs.ReadStream = ReadStream + fs.WriteStream = WriteStream + + function ReadStream (path, options) { + if (this instanceof ReadStream) + return fs$ReadStream.apply(this, arguments), this + else + return ReadStream.apply(Object.create(ReadStream.prototype), arguments) } - emitter.emitted[event] = true - emitter.emit(event, code, signal) -} -// { : , ... } -var sigListeners = {} -signals.forEach(function (sig) { - sigListeners[sig] = function listener () { - // If there are no other listeners, an exit is coming! - // Simplest way: remove us and then re-send the signal. - // We know that this will kill the process, so we can - // safely emit now. - var listeners = process.listeners(sig) - if (listeners.length === emitter.count) { - unload() - emit('exit', null, sig) - /* istanbul ignore next */ - emit('afterexit', null, sig) - /* istanbul ignore next */ - process.kill(process.pid, sig) - } + function ReadStream$open () { + var that = this + open(that.path, that.flags, that.mode, function (err, fd) { + if (err) { + if (that.autoClose) + that.destroy() + + that.emit('error', err) + } else { + that.fd = fd + that.emit('open', fd) + that.read() + } + }) } -}) -module.exports.signals = function () { - return signals -} + function WriteStream (path, options) { + if (this instanceof WriteStream) + return fs$WriteStream.apply(this, arguments), this + else + return WriteStream.apply(Object.create(WriteStream.prototype), arguments) + } -module.exports.load = load + function WriteStream$open () { + var that = this + open(that.path, that.flags, that.mode, function (err, fd) { + if (err) { + that.destroy() + that.emit('error', err) + } else { + that.fd = fd + that.emit('open', fd) + } + }) + } -var loaded = false + function createReadStream (path, options) { + return new ReadStream(path, options) + } -function load () { - if (loaded) { - return + function createWriteStream (path, options) { + return new WriteStream(path, options) } - loaded = true - // This is the number of onSignalExit's that are in play. - // It's important so that we can count the correct number of - // listeners on signals, and don't wait for the other one to - // handle it instead of us. - emitter.count += 1 + var fs$open = fs.open + fs.open = open + function open (path, flags, mode, cb) { + if (typeof mode === 'function') + cb = mode, mode = null - signals = signals.filter(function (sig) { - try { - process.on(sig, sigListeners[sig]) - return true - } catch (er) { - return false + return go$open(path, flags, mode, cb) + + function go$open (path, flags, mode, cb) { + return fs$open(path, flags, mode, function (err, fd) { + if (err && (err.code === 'EMFILE' || err.code === 'ENFILE')) + enqueue([go$open, [path, flags, mode, cb]]) + else { + if (typeof cb === 'function') + cb.apply(this, arguments) + retry() + } + }) } - }) + } - process.emit = processEmit - process.reallyExit = processReallyExit + return fs } -var originalProcessReallyExit = process.reallyExit -function processReallyExit (code) { - process.exitCode = code || 0 - emit('exit', process.exitCode, null) - /* istanbul ignore next */ - emit('afterexit', process.exitCode, null) - /* istanbul ignore next */ - originalProcessReallyExit.call(process, process.exitCode) +function enqueue (elem) { + debug('ENQUEUE', elem[0].name, elem[1]) + queue.push(elem) } -var originalProcessEmit = process.emit -function processEmit (ev, arg) { - if (ev === 'exit') { - if (arg !== undefined) { - process.exitCode = arg - } - var ret = originalProcessEmit.apply(this, arguments) - emit('exit', process.exitCode, null) - /* istanbul ignore next */ - emit('afterexit', process.exitCode, null) - return ret - } else { - return originalProcessEmit.apply(this, arguments) +function retry () { + var elem = queue.shift() + if (elem) { + debug('RETRY', elem[0].name, elem[1]) + elem[0].apply(null, elem[1]) } } /***/ }), -/* 59 */ +/* 57 */ /***/ (function(module, exports) { -module.exports = require("child_process"); +module.exports = require("assert"); /***/ }), -/* 60 */ -/***/ (function(module, exports, __webpack_require__) { +/* 58 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Scheduler; }); +var Scheduler = /*@__PURE__*/ (function () { + function Scheduler(SchedulerAction, now) { + if (now === void 0) { + now = Scheduler.now; + } + this.SchedulerAction = SchedulerAction; + this.now = now; + } + Scheduler.prototype.schedule = function (work, delay, state) { + if (delay === void 0) { + delay = 0; + } + return new this.SchedulerAction(this, work).schedule(state, delay); + }; + Scheduler.now = Date.now ? Date.now : function () { return +new Date(); }; + return Scheduler; +}()); +//# sourceMappingURL=Scheduler.js.map -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.getProjectPaths = getProjectPaths; - -var _path = __webpack_require__(2); - -/** - * Returns all the paths where plugins are located - */ -function getProjectPaths(rootPath, options) { - const skipKibanaExtra = Boolean(options['skip-kibana-extra']); - const ossOnly = Boolean(options.oss); - const projectPaths = [rootPath, (0, _path.resolve)(rootPath, 'packages/*')]; - if (!ossOnly) { - projectPaths.push((0, _path.resolve)(rootPath, 'x-pack')); - projectPaths.push((0, _path.resolve)(rootPath, 'x-pack/plugins/*')); - } - if (!skipKibanaExtra) { - projectPaths.push((0, _path.resolve)(rootPath, '../kibana-extra/*')); - projectPaths.push((0, _path.resolve)(rootPath, '../kibana-extra/*/packages/*')); - projectPaths.push((0, _path.resolve)(rootPath, '../kibana-extra/*/plugins/*')); - } - return projectPaths; -} /* - * 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. - */ /***/ }), -/* 61 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 59 */ +/***/ (function(module, exports) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = hostReportError; -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function hostReportError(err) { - setTimeout(function () { throw err; }); -} -//# sourceMappingURL=hostReportError.js.map +module.exports = function(module) { + if (!module.webpackPolyfill) { + module.deprecate = function() {}; + module.paths = []; + // module.parent = undefined by default + if (!module.children) module.children = []; + Object.defineProperty(module, "loaded", { + enumerable: true, + get: function() { + return module.l; + } + }); + Object.defineProperty(module, "id", { + enumerable: true, + get: function() { + return module.i; + } + }); + module.webpackPolyfill = 1; + } + return module; +}; /***/ }), -/* 62 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 60 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return rxSubscriber; }); -/* unused harmony export $$rxSubscriber */ -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -var rxSubscriber = (typeof Symbol === 'function' && typeof Symbol.for === 'function') - ? /*@__PURE__*/ Symbol.for('rxSubscriber') - : '@@rxSubscriber'; -var $$rxSubscriber = rxSubscriber; -//# sourceMappingURL=rxSubscriber.js.map -/***/ }), -/* 63 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.createSymlink = exports.isFile = exports.isDirectory = exports.mkdirp = exports.readFile = exports.chmod = exports.copyDirectory = exports.unlink = undefined; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = pipe; -/* harmony export (immutable) */ __webpack_exports__["b"] = pipeFromArray; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__noop__ = __webpack_require__(43); -/** PURE_IMPORTS_START _noop PURE_IMPORTS_END */ +let statTest = (() => { + var _ref = _asyncToGenerator(function* (path, block) { + try { + return block((yield stat(path))); + } catch (e) { + if (e.code === 'ENOENT') { + return false; + } + throw e; + } + }); -function pipe() { - var fns = []; - for (var _i = 0; _i < arguments.length; _i++) { - fns[_i] = arguments[_i]; - } - return pipeFromArray(fns); -} -function pipeFromArray(fns) { - if (!fns) { - return __WEBPACK_IMPORTED_MODULE_0__noop__["a" /* noop */]; - } - if (fns.length === 1) { - return fns[0]; - } - return function piped(input) { - return fns.reduce(function (prev, fn) { return fn(prev); }, input); + return function statTest(_x, _x2) { + return _ref.apply(this, arguments); }; -} -//# sourceMappingURL=pipe.js.map +})(); +/** + * Test if a path points to a directory. + * @param path + */ -/***/ }), -/* 64 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +let isDirectory = exports.isDirectory = (() => { + var _ref2 = _asyncToGenerator(function* (path) { + return yield statTest(path, function (stats) { + return stats.isDirectory(); + }); + }); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = refCount; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ + return function isDirectory(_x3) { + return _ref2.apply(this, arguments); + }; +})(); +/** + * Test if a path points to a regular file. + * @param path + */ -function refCount() { - return function refCountOperatorFunction(source) { - return source.lift(new RefCountOperator(source)); - }; -} -var RefCountOperator = /*@__PURE__*/ (function () { - function RefCountOperator(connectable) { - this.connectable = connectable; - } - RefCountOperator.prototype.call = function (subscriber, source) { - var connectable = this.connectable; - connectable._refCount++; - var refCounter = new RefCountSubscriber(subscriber, connectable); - var subscription = source.subscribe(refCounter); - if (!refCounter.closed) { - refCounter.connection = connectable.connect(); - } - return subscription; +let isFile = exports.isFile = (() => { + var _ref3 = _asyncToGenerator(function* (path) { + return yield statTest(path, function (stats) { + return stats.isFile(); + }); + }); + + return function isFile(_x4) { + return _ref3.apply(this, arguments); }; - return RefCountOperator; -}()); -var RefCountSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](RefCountSubscriber, _super); - function RefCountSubscriber(destination, connectable) { - var _this = _super.call(this, destination) || this; - _this.connectable = connectable; - return _this; - } - RefCountSubscriber.prototype._unsubscribe = function () { - var connectable = this.connectable; - if (!connectable) { - this.connection = null; - return; - } - this.connectable = null; - var refCount = connectable._refCount; - if (refCount <= 0) { - this.connection = null; - return; - } - connectable._refCount = refCount - 1; - if (refCount > 1) { - this.connection = null; - return; - } - var connection = this.connection; - var sharedConnection = connectable._connection; - this.connection = null; - if (sharedConnection && (!connection || sharedConnection === connection)) { - sharedConnection.unsubscribe(); +})(); +/** + * Create a symlink at dest that points to src. Adapted from + * https://github.com/lerna/lerna/blob/2f1b87d9e2295f587e4ac74269f714271d8ed428/src/FileSystemUtilities.js#L103. + * + * @param src + * @param dest + * @param type 'dir', 'file', 'junction', or 'exec'. 'exec' on + * windows will use the `cmd-shim` module since symlinks can't be used + * for executable files on windows. + */ + + +let createSymlink = exports.createSymlink = (() => { + var _ref4 = _asyncToGenerator(function* (src, dest, type) { + if (process.platform === 'win32') { + if (type === 'exec') { + yield cmdShim(src, dest); + } else { + yield forceCreate(src, dest, type); + } + } else { + const posixType = type === 'exec' ? 'file' : type; + const relativeSource = (0, _path.relative)((0, _path.dirname)(dest), src); + yield forceCreate(relativeSource, dest, posixType); } - }; - return RefCountSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=refCount.js.map - + }); -/***/ }), -/* 65 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + return function createSymlink(_x5, _x6, _x7) { + return _ref4.apply(this, arguments); + }; +})(); -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ReplaySubject; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__scheduler_queue__ = __webpack_require__(109); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__operators_observeOn__ = __webpack_require__(111); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_ObjectUnsubscribedError__ = __webpack_require__(44); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__SubjectSubscription__ = __webpack_require__(106); -/** PURE_IMPORTS_START tslib,_Subject,_scheduler_queue,_Subscription,_operators_observeOn,_util_ObjectUnsubscribedError,_SubjectSubscription PURE_IMPORTS_END */ +let forceCreate = (() => { + var _ref5 = _asyncToGenerator(function* (src, dest, type) { + try { + // If something exists at `dest` we need to remove it first. + yield unlink(dest); + } catch (error) { + if (error.code !== 'ENOENT') { + throw error; + } + } + yield symlink(src, dest, type); + }); + return function forceCreate(_x8, _x9, _x10) { + return _ref5.apply(this, arguments); + }; +})(); +var _cmdShim = __webpack_require__(131); +var _cmdShim2 = _interopRequireDefault(_cmdShim); +var _fs = __webpack_require__(16); +var _fs2 = _interopRequireDefault(_fs); +var _mkdirp = __webpack_require__(95); -var ReplaySubject = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ReplaySubject, _super); - function ReplaySubject(bufferSize, windowTime, scheduler) { - if (bufferSize === void 0) { - bufferSize = Number.POSITIVE_INFINITY; - } - if (windowTime === void 0) { - windowTime = Number.POSITIVE_INFINITY; - } - var _this = _super.call(this) || this; - _this.scheduler = scheduler; - _this._events = []; - _this._infiniteTimeWindow = false; - _this._bufferSize = bufferSize < 1 ? 1 : bufferSize; - _this._windowTime = windowTime < 1 ? 1 : windowTime; - if (windowTime === Number.POSITIVE_INFINITY) { - _this._infiniteTimeWindow = true; - _this.next = _this.nextInfiniteTimeWindow; - } - else { - _this.next = _this.nextTimeWindow; - } - return _this; - } - ReplaySubject.prototype.nextInfiniteTimeWindow = function (value) { - var _events = this._events; - _events.push(value); - if (_events.length > this._bufferSize) { - _events.shift(); - } - _super.prototype.next.call(this, value); - }; - ReplaySubject.prototype.nextTimeWindow = function (value) { - this._events.push(new ReplayEvent(this._getNow(), value)); - this._trimBufferThenGetEvents(); - _super.prototype.next.call(this, value); - }; - ReplaySubject.prototype._subscribe = function (subscriber) { - var _infiniteTimeWindow = this._infiniteTimeWindow; - var _events = _infiniteTimeWindow ? this._events : this._trimBufferThenGetEvents(); - var scheduler = this.scheduler; - var len = _events.length; - var subscription; - if (this.closed) { - throw new __WEBPACK_IMPORTED_MODULE_5__util_ObjectUnsubscribedError__["a" /* ObjectUnsubscribedError */](); - } - else if (this.isStopped || this.hasError) { - subscription = __WEBPACK_IMPORTED_MODULE_3__Subscription__["a" /* Subscription */].EMPTY; - } - else { - this.observers.push(subscriber); - subscription = new __WEBPACK_IMPORTED_MODULE_6__SubjectSubscription__["a" /* SubjectSubscription */](this, subscriber); - } - if (scheduler) { - subscriber.add(subscriber = new __WEBPACK_IMPORTED_MODULE_4__operators_observeOn__["a" /* ObserveOnSubscriber */](subscriber, scheduler)); - } - if (_infiniteTimeWindow) { - for (var i = 0; i < len && !subscriber.closed; i++) { - subscriber.next(_events[i]); - } - } - else { - for (var i = 0; i < len && !subscriber.closed; i++) { - subscriber.next(_events[i].value); - } - } - if (this.hasError) { - subscriber.error(this.thrownError); - } - else if (this.isStopped) { - subscriber.complete(); - } - return subscription; - }; - ReplaySubject.prototype._getNow = function () { - return (this.scheduler || __WEBPACK_IMPORTED_MODULE_2__scheduler_queue__["a" /* queue */]).now(); - }; - ReplaySubject.prototype._trimBufferThenGetEvents = function () { - var now = this._getNow(); - var _bufferSize = this._bufferSize; - var _windowTime = this._windowTime; - var _events = this._events; - var eventsCount = _events.length; - var spliceCount = 0; - while (spliceCount < eventsCount) { - if ((now - _events[spliceCount].time) < _windowTime) { - break; - } - spliceCount++; - } - if (eventsCount > _bufferSize) { - spliceCount = Math.max(spliceCount, eventsCount - _bufferSize); - } - if (spliceCount > 0) { - _events.splice(0, spliceCount); - } - return _events; - }; - return ReplaySubject; -}(__WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */])); +var _mkdirp2 = _interopRequireDefault(_mkdirp); -var ReplayEvent = /*@__PURE__*/ (function () { - function ReplayEvent(time, value) { - this.time = time; - this.value = value; - } - return ReplayEvent; -}()); -//# sourceMappingURL=ReplaySubject.js.map +var _ncp = __webpack_require__(135); +var _path = __webpack_require__(7); -/***/ }), -/* 66 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var _util = __webpack_require__(19); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = of; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_isScheduler__ = __webpack_require__(14); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__fromArray__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__empty__ = __webpack_require__(11); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__scalar__ = __webpack_require__(67); -/** PURE_IMPORTS_START _util_isScheduler,_fromArray,_empty,_scalar PURE_IMPORTS_END */ +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* + * 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. + */ +const stat = (0, _util.promisify)(_fs2.default.stat); +const readFile = (0, _util.promisify)(_fs2.default.readFile); +const symlink = (0, _util.promisify)(_fs2.default.symlink); +const chmod = (0, _util.promisify)(_fs2.default.chmod); +const cmdShim = (0, _util.promisify)(_cmdShim2.default); +const mkdirp = (0, _util.promisify)(_mkdirp2.default); +const unlink = exports.unlink = (0, _util.promisify)(_fs2.default.unlink); +const copyDirectory = exports.copyDirectory = (0, _util.promisify)(_ncp.ncp); +exports.chmod = chmod; +exports.readFile = readFile; +exports.mkdirp = mkdirp; -function of() { - var args = []; - for (var _i = 0; _i < arguments.length; _i++) { - args[_i] = arguments[_i]; - } - var scheduler = args[args.length - 1]; - if (Object(__WEBPACK_IMPORTED_MODULE_0__util_isScheduler__["a" /* isScheduler */])(scheduler)) { - args.pop(); - } - else { - scheduler = undefined; - } - switch (args.length) { - case 0: - return Object(__WEBPACK_IMPORTED_MODULE_2__empty__["b" /* empty */])(scheduler); - case 1: - return scheduler ? Object(__WEBPACK_IMPORTED_MODULE_1__fromArray__["a" /* fromArray */])(args, scheduler) : Object(__WEBPACK_IMPORTED_MODULE_3__scalar__["a" /* scalar */])(args[0]); - default: - return Object(__WEBPACK_IMPORTED_MODULE_1__fromArray__["a" /* fromArray */])(args, scheduler); - } -} -//# sourceMappingURL=of.js.map +/***/ }), +/* 61 */ +/***/ (function(module, exports) { +module.exports = require("events"); /***/ }), -/* 67 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 62 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = scalar; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ -function scalar(value) { - var result = new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - subscriber.next(value); - subscriber.complete(); - }); - result._isScalar = true; - result.value = value; - return result; -} -//# sourceMappingURL=scalar.js.map +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.isLinkDependency = undefined; +exports.readPackageJson = readPackageJson; +exports.writePackageJson = writePackageJson; -/***/ }), -/* 68 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var _readPkg = __webpack_require__(143); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = throwError; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ +var _readPkg2 = _interopRequireDefault(_readPkg); -function throwError(error, scheduler) { - if (!scheduler) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { return subscriber.error(error); }); - } - else { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { return scheduler.schedule(dispatch, 0, { error: error, subscriber: subscriber }); }); - } +var _writePkg = __webpack_require__(166); + +var _writePkg2 = _interopRequireDefault(_writePkg); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +/* + * 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. + */ +function readPackageJson(dir) { + return (0, _readPkg2.default)(dir, { normalize: false }); } -function dispatch(_a) { - var error = _a.error, subscriber = _a.subscriber; - subscriber.error(error); +function writePackageJson(path, json) { + return (0, _writePkg2.default)(path, json); } -//# sourceMappingURL=throwError.js.map - +const isLinkDependency = exports.isLinkDependency = depVersion => depVersion.startsWith('link:'); /***/ }), -/* 69 */ +/* 63 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["b"] = combineLatest; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return CombineLatestOperator; }); -/* unused harmony export CombineLatestSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_isScheduler__ = __webpack_require__(14); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__ = __webpack_require__(5); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__fromArray__ = __webpack_require__(20); -/** PURE_IMPORTS_START tslib,_util_isScheduler,_util_isArray,_OuterSubscriber,_util_subscribeToResult,_fromArray PURE_IMPORTS_END */ - +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return groupBy; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return GroupedObservable; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1); +/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2); +/* harmony import */ var _Subject__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8); +/** PURE_IMPORTS_START tslib,_Subscriber,_Subscription,_Observable,_Subject PURE_IMPORTS_END */ -var NONE = {}; -function combineLatest() { - var observables = []; - for (var _i = 0; _i < arguments.length; _i++) { - observables[_i] = arguments[_i]; - } - var resultSelector = null; - var scheduler = null; - if (Object(__WEBPACK_IMPORTED_MODULE_1__util_isScheduler__["a" /* isScheduler */])(observables[observables.length - 1])) { - scheduler = observables.pop(); - } - if (typeof observables[observables.length - 1] === 'function') { - resultSelector = observables.pop(); - } - if (observables.length === 1 && Object(__WEBPACK_IMPORTED_MODULE_2__util_isArray__["a" /* isArray */])(observables[0])) { - observables = observables[0]; - } - return Object(__WEBPACK_IMPORTED_MODULE_5__fromArray__["a" /* fromArray */])(observables, scheduler).lift(new CombineLatestOperator(resultSelector)); +function groupBy(keySelector, elementSelector, durationSelector, subjectSelector) { + return function (source) { + return source.lift(new GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector)); + }; } -var CombineLatestOperator = /*@__PURE__*/ (function () { - function CombineLatestOperator(resultSelector) { - this.resultSelector = resultSelector; +var GroupByOperator = /*@__PURE__*/ (function () { + function GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector) { + this.keySelector = keySelector; + this.elementSelector = elementSelector; + this.durationSelector = durationSelector; + this.subjectSelector = subjectSelector; } - CombineLatestOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new CombineLatestSubscriber(subscriber, this.resultSelector)); + GroupByOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new GroupBySubscriber(subscriber, this.keySelector, this.elementSelector, this.durationSelector, this.subjectSelector)); }; - return CombineLatestOperator; + return GroupByOperator; }()); - -var CombineLatestSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](CombineLatestSubscriber, _super); - function CombineLatestSubscriber(destination, resultSelector) { +var GroupBySubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](GroupBySubscriber, _super); + function GroupBySubscriber(destination, keySelector, elementSelector, durationSelector, subjectSelector) { var _this = _super.call(this, destination) || this; - _this.resultSelector = resultSelector; - _this.active = 0; - _this.values = []; - _this.observables = []; + _this.keySelector = keySelector; + _this.elementSelector = elementSelector; + _this.durationSelector = durationSelector; + _this.subjectSelector = subjectSelector; + _this.groups = null; + _this.attemptedToUnsubscribe = false; + _this.count = 0; return _this; } - CombineLatestSubscriber.prototype._next = function (observable) { - this.values.push(NONE); - this.observables.push(observable); + GroupBySubscriber.prototype._next = function (value) { + var key; + try { + key = this.keySelector(value); + } + catch (err) { + this.error(err); + return; + } + this._group(value, key); }; - CombineLatestSubscriber.prototype._complete = function () { - var observables = this.observables; - var len = observables.length; - if (len === 0) { - this.destination.complete(); + GroupBySubscriber.prototype._group = function (value, key) { + var groups = this.groups; + if (!groups) { + groups = this.groups = new Map(); + } + var group = groups.get(key); + var element; + if (this.elementSelector) { + try { + element = this.elementSelector(value); + } + catch (err) { + this.error(err); + } } else { - this.active = len; - this.toRespond = len; - for (var i = 0; i < len; i++) { - var observable = observables[i]; - this.add(Object(__WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__["a" /* subscribeToResult */])(this, observable, observable, i)); + element = value; + } + if (!group) { + group = (this.subjectSelector ? this.subjectSelector() : new _Subject__WEBPACK_IMPORTED_MODULE_4__[/* Subject */ "a"]()); + groups.set(key, group); + var groupedObservable = new GroupedObservable(key, group, this); + this.destination.next(groupedObservable); + if (this.durationSelector) { + var duration = void 0; + try { + duration = this.durationSelector(new GroupedObservable(key, group)); + } + catch (err) { + this.error(err); + return; + } + this.add(duration.subscribe(new GroupDurationSubscriber(key, group, this))); } } + if (!group.closed) { + group.next(element); + } }; - CombineLatestSubscriber.prototype.notifyComplete = function (unused) { - if ((this.active -= 1) === 0) { - this.destination.complete(); + GroupBySubscriber.prototype._error = function (err) { + var groups = this.groups; + if (groups) { + groups.forEach(function (group, key) { + group.error(err); + }); + groups.clear(); } + this.destination.error(err); }; - CombineLatestSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - var values = this.values; - var oldVal = values[outerIndex]; - var toRespond = !this.toRespond - ? 0 - : oldVal === NONE ? --this.toRespond : this.toRespond; - values[outerIndex] = innerValue; - if (toRespond === 0) { - if (this.resultSelector) { - this._tryResultSelector(values); - } - else { - this.destination.next(values.slice()); + GroupBySubscriber.prototype._complete = function () { + var groups = this.groups; + if (groups) { + groups.forEach(function (group, key) { + group.complete(); + }); + groups.clear(); + } + this.destination.complete(); + }; + GroupBySubscriber.prototype.removeGroup = function (key) { + this.groups.delete(key); + }; + GroupBySubscriber.prototype.unsubscribe = function () { + if (!this.closed) { + this.attemptedToUnsubscribe = true; + if (this.count === 0) { + _super.prototype.unsubscribe.call(this); } } }; - CombineLatestSubscriber.prototype._tryResultSelector = function (values) { - var result; - try { - result = this.resultSelector.apply(this, values); + return GroupBySubscriber; +}(_Subscriber__WEBPACK_IMPORTED_MODULE_1__[/* Subscriber */ "a"])); +var GroupDurationSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](GroupDurationSubscriber, _super); + function GroupDurationSubscriber(key, group, parent) { + var _this = _super.call(this, group) || this; + _this.key = key; + _this.group = group; + _this.parent = parent; + return _this; + } + GroupDurationSubscriber.prototype._next = function (value) { + this.complete(); + }; + GroupDurationSubscriber.prototype._unsubscribe = function () { + var _a = this, parent = _a.parent, key = _a.key; + this.key = this.parent = null; + if (parent) { + parent.removeGroup(key); } - catch (err) { - this.destination.error(err); - return; + }; + return GroupDurationSubscriber; +}(_Subscriber__WEBPACK_IMPORTED_MODULE_1__[/* Subscriber */ "a"])); +var GroupedObservable = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](GroupedObservable, _super); + function GroupedObservable(key, groupSubject, refCountSubscription) { + var _this = _super.call(this) || this; + _this.key = key; + _this.groupSubject = groupSubject; + _this.refCountSubscription = refCountSubscription; + return _this; + } + GroupedObservable.prototype._subscribe = function (subscriber) { + var subscription = new _Subscription__WEBPACK_IMPORTED_MODULE_2__[/* Subscription */ "a"](); + var _a = this, refCountSubscription = _a.refCountSubscription, groupSubject = _a.groupSubject; + if (refCountSubscription && !refCountSubscription.closed) { + subscription.add(new InnerRefCountSubscription(refCountSubscription)); } - this.destination.next(result); + subscription.add(groupSubject.subscribe(subscriber)); + return subscription; }; - return CombineLatestSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__["a" /* OuterSubscriber */])); - -//# sourceMappingURL=combineLatest.js.map - - -/***/ }), -/* 70 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = mergeAll; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__mergeMap__ = __webpack_require__(35); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_identity__ = __webpack_require__(25); -/** PURE_IMPORTS_START _mergeMap,_util_identity PURE_IMPORTS_END */ - + return GroupedObservable; +}(_Observable__WEBPACK_IMPORTED_MODULE_3__[/* Observable */ "a"])); -function mergeAll(concurrent) { - if (concurrent === void 0) { - concurrent = Number.POSITIVE_INFINITY; +var InnerRefCountSubscription = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](InnerRefCountSubscription, _super); + function InnerRefCountSubscription(parent) { + var _this = _super.call(this) || this; + _this.parent = parent; + parent.count++; + return _this; } - return Object(__WEBPACK_IMPORTED_MODULE_0__mergeMap__["a" /* mergeMap */])(__WEBPACK_IMPORTED_MODULE_1__util_identity__["a" /* identity */], concurrent); -} -//# sourceMappingURL=mergeAll.js.map - - -/***/ }), -/* 71 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = defer; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__from__ = __webpack_require__(18); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__empty__ = __webpack_require__(11); -/** PURE_IMPORTS_START _Observable,_from,_empty PURE_IMPORTS_END */ - - - -function defer(observableFactory) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var input; - try { - input = observableFactory(); - } - catch (err) { - subscriber.error(err); - return undefined; + InnerRefCountSubscription.prototype.unsubscribe = function () { + var parent = this.parent; + if (!parent.closed && !this.closed) { + _super.prototype.unsubscribe.call(this); + parent.count -= 1; + if (parent.count === 0 && parent.attemptedToUnsubscribe) { + parent.unsubscribe(); + } } - var source = input ? Object(__WEBPACK_IMPORTED_MODULE_1__from__["a" /* from */])(input) : Object(__WEBPACK_IMPORTED_MODULE_2__empty__["b" /* empty */])(); - return source.subscribe(subscriber); - }); -} -//# sourceMappingURL=defer.js.map + }; + return InnerRefCountSubscription; +}(_Subscription__WEBPACK_IMPORTED_MODULE_2__[/* Subscription */ "a"])); +//# sourceMappingURL=groupBy.js.map /***/ }), -/* 72 */ +/* 64 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["b"] = zip; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ZipOperator; }); -/* unused harmony export ZipSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__fromArray__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__ = __webpack_require__(5); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__internal_symbol_iterator__ = __webpack_require__(34); -/** PURE_IMPORTS_START tslib,_fromArray,_util_isArray,_Subscriber,_OuterSubscriber,_util_subscribeToResult,_.._internal_symbol_iterator PURE_IMPORTS_END */ - - +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ConnectableObservable; }); +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return connectableObservableDescriptor; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2); +/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1); +/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5); +/* harmony import */ var _operators_refCount__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(45); +/** PURE_IMPORTS_START tslib,_Subject,_Observable,_Subscriber,_Subscription,_operators_refCount PURE_IMPORTS_END */ -function zip() { - var observables = []; - for (var _i = 0; _i < arguments.length; _i++) { - observables[_i] = arguments[_i]; - } - var resultSelector = observables[observables.length - 1]; - if (typeof resultSelector === 'function') { - observables.pop(); - } - return Object(__WEBPACK_IMPORTED_MODULE_1__fromArray__["a" /* fromArray */])(observables, undefined).lift(new ZipOperator(resultSelector)); -} -var ZipOperator = /*@__PURE__*/ (function () { - function ZipOperator(resultSelector) { - this.resultSelector = resultSelector; - } - ZipOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new ZipSubscriber(subscriber, this.resultSelector)); - }; - return ZipOperator; -}()); -var ZipSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ZipSubscriber, _super); - function ZipSubscriber(destination, resultSelector, values) { - if (values === void 0) { - values = Object.create(null); - } - var _this = _super.call(this, destination) || this; - _this.iterators = []; - _this.active = 0; - _this.resultSelector = (typeof resultSelector === 'function') ? resultSelector : null; - _this.values = values; +var ConnectableObservable = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](ConnectableObservable, _super); + function ConnectableObservable(source, subjectFactory) { + var _this = _super.call(this) || this; + _this.source = source; + _this.subjectFactory = subjectFactory; + _this._refCount = 0; + _this._isComplete = false; return _this; } - ZipSubscriber.prototype._next = function (value) { - var iterators = this.iterators; - if (Object(__WEBPACK_IMPORTED_MODULE_2__util_isArray__["a" /* isArray */])(value)) { - iterators.push(new StaticArrayIterator(value)); - } - else if (typeof value[__WEBPACK_IMPORTED_MODULE_6__internal_symbol_iterator__["a" /* iterator */]] === 'function') { - iterators.push(new StaticIterator(value[__WEBPACK_IMPORTED_MODULE_6__internal_symbol_iterator__["a" /* iterator */]]())); - } - else { - iterators.push(new ZipBufferIterator(this.destination, this, value)); - } - }; - ZipSubscriber.prototype._complete = function () { - var iterators = this.iterators; - var len = iterators.length; - if (len === 0) { - this.destination.complete(); - return; - } - this.active = len; - for (var i = 0; i < len; i++) { - var iterator = iterators[i]; - if (iterator.stillUnsubscribed) { - this.add(iterator.subscribe(iterator, i)); - } - else { - this.active--; - } - } + ConnectableObservable.prototype._subscribe = function (subscriber) { + return this.getSubject().subscribe(subscriber); }; - ZipSubscriber.prototype.notifyInactive = function () { - this.active--; - if (this.active === 0) { - this.destination.complete(); + ConnectableObservable.prototype.getSubject = function () { + var subject = this._subject; + if (!subject || subject.isStopped) { + this._subject = this.subjectFactory(); } + return this._subject; }; - ZipSubscriber.prototype.checkIterators = function () { - var iterators = this.iterators; - var len = iterators.length; - var destination = this.destination; - for (var i = 0; i < len; i++) { - var iterator = iterators[i]; - if (typeof iterator.hasValue === 'function' && !iterator.hasValue()) { - return; - } - } - var shouldComplete = false; - var args = []; - for (var i = 0; i < len; i++) { - var iterator = iterators[i]; - var result = iterator.next(); - if (iterator.hasCompleted()) { - shouldComplete = true; + ConnectableObservable.prototype.connect = function () { + var connection = this._connection; + if (!connection) { + this._isComplete = false; + connection = this._connection = new _Subscription__WEBPACK_IMPORTED_MODULE_4__[/* Subscription */ "a"](); + connection.add(this.source + .subscribe(new ConnectableSubscriber(this.getSubject(), this))); + if (connection.closed) { + this._connection = null; + connection = _Subscription__WEBPACK_IMPORTED_MODULE_4__[/* Subscription */ "a"].EMPTY; } - if (result.done) { - destination.complete(); - return; + else { + this._connection = connection; } - args.push(result.value); - } - if (this.resultSelector) { - this._tryresultSelector(args); - } - else { - destination.next(args); - } - if (shouldComplete) { - destination.complete(); } + return connection; }; - ZipSubscriber.prototype._tryresultSelector = function (args) { - var result; - try { - result = this.resultSelector.apply(this, args); - } - catch (err) { - this.destination.error(err); - return; - } - this.destination.next(result); + ConnectableObservable.prototype.refCount = function () { + return Object(_operators_refCount__WEBPACK_IMPORTED_MODULE_5__[/* refCount */ "a"])()(this); }; - return ZipSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__Subscriber__["a" /* Subscriber */])); + return ConnectableObservable; +}(_Observable__WEBPACK_IMPORTED_MODULE_2__[/* Observable */ "a"])); -var StaticIterator = /*@__PURE__*/ (function () { - function StaticIterator(iterator) { - this.iterator = iterator; - this.nextResult = iterator.next(); +var connectableProto = ConnectableObservable.prototype; +var connectableObservableDescriptor = { + operator: { value: null }, + _refCount: { value: 0, writable: true }, + _subject: { value: null, writable: true }, + _connection: { value: null, writable: true }, + _subscribe: { value: connectableProto._subscribe }, + _isComplete: { value: connectableProto._isComplete, writable: true }, + getSubject: { value: connectableProto.getSubject }, + connect: { value: connectableProto.connect }, + refCount: { value: connectableProto.refCount } +}; +var ConnectableSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](ConnectableSubscriber, _super); + function ConnectableSubscriber(destination, connectable) { + var _this = _super.call(this, destination) || this; + _this.connectable = connectable; + return _this; } - StaticIterator.prototype.hasValue = function () { - return true; + ConnectableSubscriber.prototype._error = function (err) { + this._unsubscribe(); + _super.prototype._error.call(this, err); }; - StaticIterator.prototype.next = function () { - var result = this.nextResult; - this.nextResult = this.iterator.next(); - return result; + ConnectableSubscriber.prototype._complete = function () { + this.connectable._isComplete = true; + this._unsubscribe(); + _super.prototype._complete.call(this); }; - StaticIterator.prototype.hasCompleted = function () { - var nextResult = this.nextResult; - return nextResult && nextResult.done; + ConnectableSubscriber.prototype._unsubscribe = function () { + var connectable = this.connectable; + if (connectable) { + this.connectable = null; + var connection = connectable._connection; + connectable._refCount = 0; + connectable._subject = null; + connectable._connection = null; + if (connection) { + connection.unsubscribe(); + } + } }; - return StaticIterator; -}()); -var StaticArrayIterator = /*@__PURE__*/ (function () { - function StaticArrayIterator(array) { - this.array = array; - this.index = 0; - this.length = 0; - this.length = array.length; + return ConnectableSubscriber; +}(_Subject__WEBPACK_IMPORTED_MODULE_1__[/* SubjectSubscriber */ "b"])); +var RefCountOperator = /*@__PURE__*/ (function () { + function RefCountOperator(connectable) { + this.connectable = connectable; } - StaticArrayIterator.prototype[__WEBPACK_IMPORTED_MODULE_6__internal_symbol_iterator__["a" /* iterator */]] = function () { - return this; - }; - StaticArrayIterator.prototype.next = function (value) { - var i = this.index++; - var array = this.array; - return i < this.length ? { value: array[i], done: false } : { value: null, done: true }; - }; - StaticArrayIterator.prototype.hasValue = function () { - return this.array.length > this.index; - }; - StaticArrayIterator.prototype.hasCompleted = function () { - return this.array.length === this.index; + RefCountOperator.prototype.call = function (subscriber, source) { + var connectable = this.connectable; + connectable._refCount++; + var refCounter = new RefCountSubscriber(subscriber, connectable); + var subscription = source.subscribe(refCounter); + if (!refCounter.closed) { + refCounter.connection = connectable.connect(); + } + return subscription; }; - return StaticArrayIterator; + return RefCountOperator; }()); -var ZipBufferIterator = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ZipBufferIterator, _super); - function ZipBufferIterator(destination, parent, observable) { +var RefCountSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](RefCountSubscriber, _super); + function RefCountSubscriber(destination, connectable) { var _this = _super.call(this, destination) || this; - _this.parent = parent; - _this.observable = observable; - _this.stillUnsubscribed = true; - _this.buffer = []; - _this.isComplete = false; + _this.connectable = connectable; return _this; } - ZipBufferIterator.prototype[__WEBPACK_IMPORTED_MODULE_6__internal_symbol_iterator__["a" /* iterator */]] = function () { - return this; - }; - ZipBufferIterator.prototype.next = function () { - var buffer = this.buffer; - if (buffer.length === 0 && this.isComplete) { - return { value: null, done: true }; + RefCountSubscriber.prototype._unsubscribe = function () { + var connectable = this.connectable; + if (!connectable) { + this.connection = null; + return; + } + this.connectable = null; + var refCount = connectable._refCount; + if (refCount <= 0) { + this.connection = null; + return; + } + connectable._refCount = refCount - 1; + if (refCount > 1) { + this.connection = null; + return; } - else { - return { value: buffer.shift(), done: false }; + var connection = this.connection; + var sharedConnection = connectable._connection; + this.connection = null; + if (sharedConnection && (!connection || sharedConnection === connection)) { + sharedConnection.unsubscribe(); } }; - ZipBufferIterator.prototype.hasValue = function () { - return this.buffer.length > 0; - }; - ZipBufferIterator.prototype.hasCompleted = function () { - return this.buffer.length === 0 && this.isComplete; + return RefCountSubscriber; +}(_Subscriber__WEBPACK_IMPORTED_MODULE_3__[/* Subscriber */ "a"])); +//# sourceMappingURL=ConnectableObservable.js.map + + +/***/ }), +/* 65 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return BehaviorSubject; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8); +/* harmony import */ var _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(25); +/** PURE_IMPORTS_START tslib,_Subject,_util_ObjectUnsubscribedError PURE_IMPORTS_END */ + + + +var BehaviorSubject = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](BehaviorSubject, _super); + function BehaviorSubject(_value) { + var _this = _super.call(this) || this; + _this._value = _value; + return _this; + } + Object.defineProperty(BehaviorSubject.prototype, "value", { + get: function () { + return this.getValue(); + }, + enumerable: true, + configurable: true + }); + BehaviorSubject.prototype._subscribe = function (subscriber) { + var subscription = _super.prototype._subscribe.call(this, subscriber); + if (subscription && !subscription.closed) { + subscriber.next(this._value); + } + return subscription; }; - ZipBufferIterator.prototype.notifyComplete = function () { - if (this.buffer.length > 0) { - this.isComplete = true; - this.parent.notifyInactive(); + BehaviorSubject.prototype.getValue = function () { + if (this.hasError) { + throw this.thrownError; + } + else if (this.closed) { + throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_2__[/* ObjectUnsubscribedError */ "a"](); } else { - this.destination.complete(); + return this._value; } }; - ZipBufferIterator.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.buffer.push(innerValue); - this.parent.checkIterators(); - }; - ZipBufferIterator.prototype.subscribe = function (value, index) { - return Object(__WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__["a" /* subscribeToResult */])(this, this.observable, this, index); + BehaviorSubject.prototype.next = function (value) { + _super.prototype.next.call(this, this._value = value); }; - return ZipBufferIterator; -}(__WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=zip.js.map + return BehaviorSubject; +}(_Subject__WEBPACK_IMPORTED_MODULE_1__[/* Subject */ "a"])); + +//# sourceMappingURL=BehaviorSubject.js.map /***/ }), -/* 73 */ +/* 66 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = take; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_ArgumentOutOfRangeError__ = __webpack_require__(32); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__observable_empty__ = __webpack_require__(11); -/** PURE_IMPORTS_START tslib,_Subscriber,_util_ArgumentOutOfRangeError,_observable_empty PURE_IMPORTS_END */ - +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return observeOn; }); +/* unused harmony export ObserveOnOperator */ +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ObserveOnSubscriber; }); +/* unused harmony export ObserveOnMessage */ +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1); +/* harmony import */ var _Notification__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(22); +/** PURE_IMPORTS_START tslib,_Subscriber,_Notification PURE_IMPORTS_END */ -function take(count) { - return function (source) { - if (count === 0) { - return Object(__WEBPACK_IMPORTED_MODULE_3__observable_empty__["b" /* empty */])(); - } - else { - return source.lift(new TakeOperator(count)); - } +function observeOn(scheduler, delay) { + if (delay === void 0) { + delay = 0; + } + return function observeOnOperatorFunction(source) { + return source.lift(new ObserveOnOperator(scheduler, delay)); }; } -var TakeOperator = /*@__PURE__*/ (function () { - function TakeOperator(total) { - this.total = total; - if (this.total < 0) { - throw new __WEBPACK_IMPORTED_MODULE_2__util_ArgumentOutOfRangeError__["a" /* ArgumentOutOfRangeError */]; +var ObserveOnOperator = /*@__PURE__*/ (function () { + function ObserveOnOperator(scheduler, delay) { + if (delay === void 0) { + delay = 0; } + this.scheduler = scheduler; + this.delay = delay; } - TakeOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new TakeSubscriber(subscriber, this.total)); + ObserveOnOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new ObserveOnSubscriber(subscriber, this.scheduler, this.delay)); }; - return TakeOperator; + return ObserveOnOperator; }()); -var TakeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](TakeSubscriber, _super); - function TakeSubscriber(destination, total) { + +var ObserveOnSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](ObserveOnSubscriber, _super); + function ObserveOnSubscriber(destination, scheduler, delay) { + if (delay === void 0) { + delay = 0; + } var _this = _super.call(this, destination) || this; - _this.total = total; - _this.count = 0; + _this.scheduler = scheduler; + _this.delay = delay; return _this; } - TakeSubscriber.prototype._next = function (value) { - var total = this.total; - var count = ++this.count; - if (count <= total) { - this.destination.next(value); - if (count === total) { - this.destination.complete(); - this.unsubscribe(); - } - } + ObserveOnSubscriber.dispatch = function (arg) { + var notification = arg.notification, destination = arg.destination; + notification.observe(destination); + this.unsubscribe(); }; - return TakeSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=take.js.map + ObserveOnSubscriber.prototype.scheduleMessage = function (notification) { + this.add(this.scheduler.schedule(ObserveOnSubscriber.dispatch, this.delay, new ObserveOnMessage(notification, this.destination))); + }; + ObserveOnSubscriber.prototype._next = function (value) { + this.scheduleMessage(_Notification__WEBPACK_IMPORTED_MODULE_2__[/* Notification */ "a"].createNext(value)); + }; + ObserveOnSubscriber.prototype._error = function (err) { + this.scheduleMessage(_Notification__WEBPACK_IMPORTED_MODULE_2__[/* Notification */ "a"].createError(err)); + }; + ObserveOnSubscriber.prototype._complete = function () { + this.scheduleMessage(_Notification__WEBPACK_IMPORTED_MODULE_2__[/* Notification */ "a"].createComplete()); + }; + return ObserveOnSubscriber; +}(_Subscriber__WEBPACK_IMPORTED_MODULE_1__[/* Subscriber */ "a"])); + +var ObserveOnMessage = /*@__PURE__*/ (function () { + function ObserveOnMessage(notification, destination) { + this.notification = notification; + this.destination = destination; + } + return ObserveOnMessage; +}()); + +//# sourceMappingURL=observeOn.js.map /***/ }), -/* 74 */ +/* 67 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = takeLast; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_ArgumentOutOfRangeError__ = __webpack_require__(32); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__observable_empty__ = __webpack_require__(11); -/** PURE_IMPORTS_START tslib,_Subscriber,_util_ArgumentOutOfRangeError,_observable_empty PURE_IMPORTS_END */ +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return TimeoutError; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ + +var TimeoutError = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](TimeoutError, _super); + function TimeoutError() { + var _this = _super.call(this, 'Timeout has occurred') || this; + _this.name = 'TimeoutError'; + Object.setPrototypeOf(_this, TimeoutError.prototype); + return _this; + } + return TimeoutError; +}(Error)); +//# sourceMappingURL=TimeoutError.js.map +/***/ }), +/* 68 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -function takeLast(count) { - return function takeLastOperatorFunction(source) { - if (count === 0) { - return Object(__WEBPACK_IMPORTED_MODULE_3__observable_empty__["b" /* empty */])(); - } - else { - return source.lift(new TakeLastOperator(count)); - } - }; +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return concatAll; }); +/* harmony import */ var _mergeAll__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(50); +/** PURE_IMPORTS_START _mergeAll PURE_IMPORTS_END */ + +function concatAll() { + return Object(_mergeAll__WEBPACK_IMPORTED_MODULE_0__[/* mergeAll */ "a"])(1); } -var TakeLastOperator = /*@__PURE__*/ (function () { - function TakeLastOperator(total) { - this.total = total; - if (this.total < 0) { - throw new __WEBPACK_IMPORTED_MODULE_2__util_ArgumentOutOfRangeError__["a" /* ArgumentOutOfRangeError */]; +//# sourceMappingURL=concatAll.js.map + + +/***/ }), +/* 69 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return merge; }); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2); +/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(12); +/* harmony import */ var _operators_mergeAll__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(50); +/* harmony import */ var _fromArray__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(17); +/** PURE_IMPORTS_START _Observable,_util_isScheduler,_operators_mergeAll,_fromArray PURE_IMPORTS_END */ + + + + +function merge() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i] = arguments[_i]; + } + var concurrent = Number.POSITIVE_INFINITY; + var scheduler = null; + var last = observables[observables.length - 1]; + if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_1__[/* isScheduler */ "a"])(last)) { + scheduler = observables.pop(); + if (observables.length > 1 && typeof observables[observables.length - 1] === 'number') { + concurrent = observables.pop(); } } - TakeLastOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new TakeLastSubscriber(subscriber, this.total)); - }; - return TakeLastOperator; -}()); -var TakeLastSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](TakeLastSubscriber, _super); - function TakeLastSubscriber(destination, total) { - var _this = _super.call(this, destination) || this; - _this.total = total; - _this.ring = new Array(); - _this.count = 0; - return _this; + else if (typeof last === 'number') { + concurrent = observables.pop(); } - TakeLastSubscriber.prototype._next = function (value) { - var ring = this.ring; - var total = this.total; - var count = this.count++; - if (ring.length < total) { - ring.push(value); - } - else { - var index = count % total; - ring[index] = value; - } - }; - TakeLastSubscriber.prototype._complete = function () { - var destination = this.destination; - var count = this.count; - if (count > 0) { - var total = this.count >= this.total ? this.total : this.count; - var ring = this.ring; - for (var i = 0; i < total; i++) { - var idx = (count++) % total; - destination.next(ring[idx]); - } - } - destination.complete(); - }; - return TakeLastSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=takeLast.js.map + if (scheduler === null && observables.length === 1 && observables[0] instanceof _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"]) { + return observables[0]; + } + return Object(_operators_mergeAll__WEBPACK_IMPORTED_MODULE_2__[/* mergeAll */ "a"])(concurrent)(Object(_fromArray__WEBPACK_IMPORTED_MODULE_3__[/* fromArray */ "a"])(observables, scheduler)); +} +//# sourceMappingURL=merge.js.map /***/ }), -/* 75 */ +/* 70 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = scan; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return race; }); +/* unused harmony export RaceOperator */ +/* unused harmony export RaceSubscriber */ +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(11); +/* harmony import */ var _fromArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(17); +/* harmony import */ var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4); +/* harmony import */ var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3); +/** PURE_IMPORTS_START tslib,_util_isArray,_fromArray,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ + -function scan(accumulator, seed) { - var hasSeed = false; - if (arguments.length >= 2) { - hasSeed = true; + + +function race() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i] = arguments[_i]; } - return function scanOperatorFunction(source) { - return source.lift(new ScanOperator(accumulator, seed, hasSeed)); - }; -} -var ScanOperator = /*@__PURE__*/ (function () { - function ScanOperator(accumulator, seed, hasSeed) { - if (hasSeed === void 0) { - hasSeed = false; + if (observables.length === 1) { + if (Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__[/* isArray */ "a"])(observables[0])) { + observables = observables[0]; + } + else { + return observables[0]; } - this.accumulator = accumulator; - this.seed = seed; - this.hasSeed = hasSeed; } - ScanOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new ScanSubscriber(subscriber, this.accumulator, this.seed, this.hasSeed)); + return Object(_fromArray__WEBPACK_IMPORTED_MODULE_2__[/* fromArray */ "a"])(observables, undefined).lift(new RaceOperator()); +} +var RaceOperator = /*@__PURE__*/ (function () { + function RaceOperator() { + } + RaceOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new RaceSubscriber(subscriber)); }; - return ScanOperator; + return RaceOperator; }()); -var ScanSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ScanSubscriber, _super); - function ScanSubscriber(destination, accumulator, _seed, hasSeed) { + +var RaceSubscriber = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](RaceSubscriber, _super); + function RaceSubscriber(destination) { var _this = _super.call(this, destination) || this; - _this.accumulator = accumulator; - _this._seed = _seed; - _this.hasSeed = hasSeed; - _this.index = 0; + _this.hasFirst = false; + _this.observables = []; + _this.subscriptions = []; return _this; } - Object.defineProperty(ScanSubscriber.prototype, "seed", { - get: function () { - return this._seed; - }, - set: function (value) { - this.hasSeed = true; - this._seed = value; - }, - enumerable: true, - configurable: true - }); - ScanSubscriber.prototype._next = function (value) { - if (!this.hasSeed) { - this.seed = value; - this.destination.next(value); + RaceSubscriber.prototype._next = function (observable) { + this.observables.push(observable); + }; + RaceSubscriber.prototype._complete = function () { + var observables = this.observables; + var len = observables.length; + if (len === 0) { + this.destination.complete(); } else { - return this._tryNext(value); + for (var i = 0; i < len && !this.hasFirst; i++) { + var observable = observables[i]; + var subscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_4__[/* subscribeToResult */ "a"])(this, observable, observable, i); + if (this.subscriptions) { + this.subscriptions.push(subscription); + } + this.add(subscription); + } + this.observables = null; } }; - ScanSubscriber.prototype._tryNext = function (value) { - var index = this.index++; - var result; - try { - result = this.accumulator(this.seed, value, index); - } - catch (err) { - this.destination.error(err); + RaceSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + if (!this.hasFirst) { + this.hasFirst = true; + for (var i = 0; i < this.subscriptions.length; i++) { + if (i !== outerIndex) { + var subscription = this.subscriptions[i]; + subscription.unsubscribe(); + this.remove(subscription); + } + } + this.subscriptions = null; } - this.seed = result; - this.destination.next(result); + this.destination.next(innerValue); }; - return ScanSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=scan.js.map + return RaceSubscriber; +}(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_3__[/* OuterSubscriber */ "a"])); + +//# sourceMappingURL=race.js.map /***/ }), -/* 76 */ +/* 71 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = switchMap; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__map__ = __webpack_require__(15); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__observable_from__ = __webpack_require__(18); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult,_map,_observable_from PURE_IMPORTS_END */ - +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return timer; }); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2); +/* harmony import */ var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(10); +/* harmony import */ var _util_isNumeric__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(35); +/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(12); +/** PURE_IMPORTS_START _Observable,_scheduler_async,_util_isNumeric,_util_isScheduler PURE_IMPORTS_END */ -function switchMap(project, resultSelector) { - if (typeof resultSelector === 'function') { - return function (source) { return source.pipe(switchMap(function (a, i) { return Object(__WEBPACK_IMPORTED_MODULE_4__observable_from__["a" /* from */])(project(a, i)).pipe(Object(__WEBPACK_IMPORTED_MODULE_3__map__["a" /* map */])(function (b, ii) { return resultSelector(a, b, i, ii); })); })); }; +function timer(dueTime, periodOrScheduler, scheduler) { + if (dueTime === void 0) { + dueTime = 0; } - return function (source) { return source.lift(new SwitchMapOperator(project)); }; + var period = -1; + if (Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_2__[/* isNumeric */ "a"])(periodOrScheduler)) { + period = Number(periodOrScheduler) < 1 && 1 || Number(periodOrScheduler); + } + else if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_3__[/* isScheduler */ "a"])(periodOrScheduler)) { + scheduler = periodOrScheduler; + } + if (!Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_3__[/* isScheduler */ "a"])(scheduler)) { + scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_1__[/* async */ "a"]; + } + return new _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"](function (subscriber) { + var due = Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_2__[/* isNumeric */ "a"])(dueTime) + ? dueTime + : (+dueTime - scheduler.now()); + return scheduler.schedule(dispatch, due, { + index: 0, period: period, subscriber: subscriber + }); + }); } -var SwitchMapOperator = /*@__PURE__*/ (function () { - function SwitchMapOperator(project) { - this.project = project; +function dispatch(state) { + var index = state.index, period = state.period, subscriber = state.subscriber; + subscriber.next(index); + if (subscriber.closed) { + return; } - SwitchMapOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new SwitchMapSubscriber(subscriber, this.project)); - }; - return SwitchMapOperator; -}()); -var SwitchMapSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SwitchMapSubscriber, _super); - function SwitchMapSubscriber(destination, project) { - var _this = _super.call(this, destination) || this; - _this.project = project; - _this.index = 0; - return _this; + else if (period === -1) { + return subscriber.complete(); } - SwitchMapSubscriber.prototype._next = function (value) { - var result; - var index = this.index++; - try { - result = this.project(value, index); - } - catch (error) { - this.destination.error(error); - return; - } - this._innerSub(result, value, index); - }; - SwitchMapSubscriber.prototype._innerSub = function (result, value, index) { - var innerSubscription = this.innerSubscription; - if (innerSubscription) { - innerSubscription.unsubscribe(); - } - this.add(this.innerSubscription = Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(this, result, value, index)); - }; - SwitchMapSubscriber.prototype._complete = function () { - var innerSubscription = this.innerSubscription; - if (!innerSubscription || innerSubscription.closed) { - _super.prototype._complete.call(this); - } - }; - SwitchMapSubscriber.prototype._unsubscribe = function () { - this.innerSubscription = null; - }; - SwitchMapSubscriber.prototype.notifyComplete = function (innerSub) { - this.remove(innerSub); - this.innerSubscription = null; - if (this.isStopped) { - _super.prototype._complete.call(this); - } - }; - SwitchMapSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.destination.next(innerValue); - }; - return SwitchMapSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=switchMap.js.map + state.index = index + 1; + this.schedule(state, period); +} +//# sourceMappingURL=timer.js.map /***/ }), -/* 77 */ -/***/ (function(module, exports, __webpack_require__) { - -/* MIT license */ -var cssKeywords = __webpack_require__(139); +/* 72 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { -// NOTE: conversions should only return primitive values (i.e. arrays, or -// values that give correct `typeof` results). -// do not use box values types (i.e. Number(), String(), etc.) +"use strict"; -var reverseKeywords = {}; -for (var key in cssKeywords) { - if (cssKeywords.hasOwnProperty(key)) { - reverseKeywords[cssKeywords[key]] = key; - } -} +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/node_modules/tslib/tslib.es6.js +var tslib_es6 = __webpack_require__(0); -var convert = module.exports = { - rgb: {channels: 3, labels: 'rgb'}, - hsl: {channels: 3, labels: 'hsl'}, - hsv: {channels: 3, labels: 'hsv'}, - hwb: {channels: 3, labels: 'hwb'}, - cmyk: {channels: 4, labels: 'cmyk'}, - xyz: {channels: 3, labels: 'xyz'}, - lab: {channels: 3, labels: 'lab'}, - lch: {channels: 3, labels: 'lch'}, - hex: {channels: 1, labels: ['hex']}, - keyword: {channels: 1, labels: ['keyword']}, - ansi16: {channels: 1, labels: ['ansi16']}, - ansi256: {channels: 1, labels: ['ansi256']}, - hcg: {channels: 3, labels: ['h', 'c', 'g']}, - apple: {channels: 3, labels: ['r16', 'g16', 'b16']}, - gray: {channels: 1, labels: ['gray']} -}; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsyncAction.js + 1 modules +var AsyncAction = __webpack_require__(34); -// hide .channels and .labels properties -for (var model in convert) { - if (convert.hasOwnProperty(model)) { - if (!('channels' in convert[model])) { - throw new Error('missing channels property: ' + model); - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/QueueAction.js +/** PURE_IMPORTS_START tslib,_AsyncAction PURE_IMPORTS_END */ - if (!('labels' in convert[model])) { - throw new Error('missing channel labels property: ' + model); - } - if (convert[model].labels.length !== convert[model].channels) { - throw new Error('channel and label counts mismatch: ' + model); - } +var QueueAction_QueueAction = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](QueueAction, _super); + function QueueAction(scheduler, work) { + var _this = _super.call(this, scheduler, work) || this; + _this.scheduler = scheduler; + _this.work = work; + return _this; + } + QueueAction.prototype.schedule = function (state, delay) { + if (delay === void 0) { + delay = 0; + } + if (delay > 0) { + return _super.prototype.schedule.call(this, state, delay); + } + this.delay = delay; + this.state = state; + this.scheduler.flush(this); + return this; + }; + QueueAction.prototype.execute = function (state, delay) { + return (delay > 0 || this.closed) ? + _super.prototype.execute.call(this, state, delay) : + this._execute(state, delay); + }; + QueueAction.prototype.requestAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; + } + if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { + return _super.prototype.requestAsyncId.call(this, scheduler, id, delay); + } + return scheduler.flush(this); + }; + return QueueAction; +}(AsyncAction["a" /* AsyncAction */])); - var channels = convert[model].channels; - var labels = convert[model].labels; - delete convert[model].channels; - delete convert[model].labels; - Object.defineProperty(convert[model], 'channels', {value: channels}); - Object.defineProperty(convert[model], 'labels', {value: labels}); - } -} +//# sourceMappingURL=QueueAction.js.map -convert.rgb.hsl = function (rgb) { - var r = rgb[0] / 255; - var g = rgb[1] / 255; - var b = rgb[2] / 255; - var min = Math.min(r, g, b); - var max = Math.max(r, g, b); - var delta = max - min; - var h; - var s; - var l; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsyncScheduler.js +var AsyncScheduler = __webpack_require__(32); - if (max === min) { - h = 0; - } else if (r === max) { - h = (g - b) / delta; - } else if (g === max) { - h = 2 + (b - r) / delta; - } else if (b === max) { - h = 4 + (r - g) / delta; - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/QueueScheduler.js +/** PURE_IMPORTS_START tslib,_AsyncScheduler PURE_IMPORTS_END */ - h = Math.min(h * 60, 360); - if (h < 0) { - h += 360; - } +var QueueScheduler_QueueScheduler = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](QueueScheduler, _super); + function QueueScheduler() { + return _super !== null && _super.apply(this, arguments) || this; + } + return QueueScheduler; +}(AsyncScheduler["a" /* AsyncScheduler */])); - l = (min + max) / 2; +//# sourceMappingURL=QueueScheduler.js.map - if (max === min) { - s = 0; - } else if (l <= 0.5) { - s = delta / (max + min); - } else { - s = delta / (2 - max - min); - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/queue.js +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return queue; }); +/** PURE_IMPORTS_START _QueueAction,_QueueScheduler PURE_IMPORTS_END */ - return [h, s * 100, l * 100]; -}; -convert.rgb.hsv = function (rgb) { - var r = rgb[0]; - var g = rgb[1]; - var b = rgb[2]; - var min = Math.min(r, g, b); - var max = Math.max(r, g, b); - var delta = max - min; - var h; - var s; - var v; +var queue = /*@__PURE__*/ new QueueScheduler_QueueScheduler(QueueAction_QueueAction); +//# sourceMappingURL=queue.js.map - if (max === 0) { - s = 0; - } else { - s = (delta / max * 1000) / 10; - } - if (max === min) { - h = 0; - } else if (r === max) { - h = (g - b) / delta; - } else if (g === max) { - h = 2 + (b - r) / delta; - } else if (b === max) { - h = 4 + (r - g) / delta; - } +/***/ }), +/* 73 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - h = Math.min(h * 60, 360); +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isObject; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function isObject(x) { + return x != null && typeof x === 'object'; +} +//# sourceMappingURL=isObject.js.map - if (h < 0) { - h += 360; - } - v = ((max / 255) * 1000) / 10; +/***/ }), +/* 74 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - return [h, s, v]; -}; +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return SubjectSubscription; }); +/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0); +/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5); +/** PURE_IMPORTS_START tslib,_Subscription PURE_IMPORTS_END */ -convert.rgb.hwb = function (rgb) { - var r = rgb[0]; - var g = rgb[1]; - var b = rgb[2]; - var h = convert.rgb.hsl(rgb)[0]; - var w = 1 / 255 * Math.min(r, Math.min(g, b)); - b = 1 - 1 / 255 * Math.max(r, Math.max(g, b)); +var SubjectSubscription = /*@__PURE__*/ (function (_super) { + tslib__WEBPACK_IMPORTED_MODULE_0__[/* __extends */ "a"](SubjectSubscription, _super); + function SubjectSubscription(subject, subscriber) { + var _this = _super.call(this) || this; + _this.subject = subject; + _this.subscriber = subscriber; + _this.closed = false; + return _this; + } + SubjectSubscription.prototype.unsubscribe = function () { + if (this.closed) { + return; + } + this.closed = true; + var subject = this.subject; + var observers = subject.observers; + this.subject = null; + if (!observers || observers.length === 0 || subject.isStopped || subject.closed) { + return; + } + var subscriberIndex = observers.indexOf(this.subscriber); + if (subscriberIndex !== -1) { + observers.splice(subscriberIndex, 1); + } + }; + return SubjectSubscription; +}(_Subscription__WEBPACK_IMPORTED_MODULE_1__[/* Subscription */ "a"])); - return [h, w * 100, b * 100]; -}; +//# sourceMappingURL=SubjectSubscription.js.map -convert.rgb.cmyk = function (rgb) { - var r = rgb[0] / 255; - var g = rgb[1] / 255; - var b = rgb[2] / 255; - var c; - var m; - var y; - var k; - k = Math.min(1 - r, 1 - g, 1 - b); - c = (1 - r - k) / (1 - k) || 0; - m = (1 - g - k) / (1 - k) || 0; - y = (1 - b - k) / (1 - k) || 0; +/***/ }), +/* 75 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - return [c * 100, m * 100, y * 100, k * 100]; +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToArray; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +var subscribeToArray = function (array) { + return function (subscriber) { + for (var i = 0, len = array.length; i < len && !subscriber.closed; i++) { + subscriber.next(array[i]); + } + if (!subscriber.closed) { + subscriber.complete(); + } + }; }; +//# sourceMappingURL=subscribeToArray.js.map -/** - * See https://en.m.wikipedia.org/wiki/Euclidean_distance#Squared_Euclidean_distance - * */ -function comparativeDistance(x, y) { - return ( - Math.pow(x[0] - y[0], 2) + - Math.pow(x[1] - y[1], 2) + - Math.pow(x[2] - y[2], 2) - ); -} -convert.rgb.keyword = function (rgb) { - var reversed = reverseKeywords[rgb]; - if (reversed) { - return reversed; - } +/***/ }), +/* 76 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - var currentClosestDistance = Infinity; - var currentClosestKeyword; +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeTo; }); +/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2); +/* harmony import */ var _subscribeToArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(75); +/* harmony import */ var _subscribeToPromise__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(80); +/* harmony import */ var _subscribeToIterable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(81); +/* harmony import */ var _subscribeToObservable__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(77); +/* harmony import */ var _isArrayLike__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(78); +/* harmony import */ var _isPromise__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(79); +/* harmony import */ var _isObject__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(73); +/* harmony import */ var _symbol_iterator__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(23); +/* harmony import */ var _symbol_observable__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(24); +/** PURE_IMPORTS_START _Observable,_subscribeToArray,_subscribeToPromise,_subscribeToIterable,_subscribeToObservable,_isArrayLike,_isPromise,_isObject,_symbol_iterator,_symbol_observable PURE_IMPORTS_END */ - for (var keyword in cssKeywords) { - if (cssKeywords.hasOwnProperty(keyword)) { - var value = cssKeywords[keyword]; - // Compute comparative distance - var distance = comparativeDistance(rgb, value); - // Check if its less, if so set as closest - if (distance < currentClosestDistance) { - currentClosestDistance = distance; - currentClosestKeyword = keyword; - } - } - } - return currentClosestKeyword; -}; -convert.keyword.rgb = function (keyword) { - return cssKeywords[keyword]; -}; -convert.rgb.xyz = function (rgb) { - var r = rgb[0] / 255; - var g = rgb[1] / 255; - var b = rgb[2] / 255; - // assume sRGB - r = r > 0.04045 ? Math.pow(((r + 0.055) / 1.055), 2.4) : (r / 12.92); - g = g > 0.04045 ? Math.pow(((g + 0.055) / 1.055), 2.4) : (g / 12.92); - b = b > 0.04045 ? Math.pow(((b + 0.055) / 1.055), 2.4) : (b / 12.92); - var x = (r * 0.4124) + (g * 0.3576) + (b * 0.1805); - var y = (r * 0.2126) + (g * 0.7152) + (b * 0.0722); - var z = (r * 0.0193) + (g * 0.1192) + (b * 0.9505); - return [x * 100, y * 100, z * 100]; -}; -convert.rgb.lab = function (rgb) { - var xyz = convert.rgb.xyz(rgb); - var x = xyz[0]; - var y = xyz[1]; - var z = xyz[2]; - var l; - var a; - var b; +var subscribeTo = function (result) { + if (result instanceof _Observable__WEBPACK_IMPORTED_MODULE_0__[/* Observable */ "a"]) { + return function (subscriber) { + if (result._isScalar) { + subscriber.next(result.value); + subscriber.complete(); + return undefined; + } + else { + return result.subscribe(subscriber); + } + }; + } + else if (result && typeof result[_symbol_observable__WEBPACK_IMPORTED_MODULE_9__[/* observable */ "a"]] === 'function') { + return Object(_subscribeToObservable__WEBPACK_IMPORTED_MODULE_4__[/* subscribeToObservable */ "a"])(result); + } + else if (Object(_isArrayLike__WEBPACK_IMPORTED_MODULE_5__[/* isArrayLike */ "a"])(result)) { + return Object(_subscribeToArray__WEBPACK_IMPORTED_MODULE_1__[/* subscribeToArray */ "a"])(result); + } + else if (Object(_isPromise__WEBPACK_IMPORTED_MODULE_6__[/* isPromise */ "a"])(result)) { + return Object(_subscribeToPromise__WEBPACK_IMPORTED_MODULE_2__[/* subscribeToPromise */ "a"])(result); + } + else if (result && typeof result[_symbol_iterator__WEBPACK_IMPORTED_MODULE_8__[/* iterator */ "a"]] === 'function') { + return Object(_subscribeToIterable__WEBPACK_IMPORTED_MODULE_3__[/* subscribeToIterable */ "a"])(result); + } + else { + var value = Object(_isObject__WEBPACK_IMPORTED_MODULE_7__[/* isObject */ "a"])(result) ? 'an invalid object' : "'" + result + "'"; + var msg = "You provided " + value + " where a stream was expected." + + ' You can provide an Observable, Promise, Array, or Iterable.'; + throw new TypeError(msg); + } +}; +//# sourceMappingURL=subscribeTo.js.map - x /= 95.047; - y /= 100; - z /= 108.883; - x = x > 0.008856 ? Math.pow(x, 1 / 3) : (7.787 * x) + (16 / 116); - y = y > 0.008856 ? Math.pow(y, 1 / 3) : (7.787 * y) + (16 / 116); - z = z > 0.008856 ? Math.pow(z, 1 / 3) : (7.787 * z) + (16 / 116); +/***/ }), +/* 77 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - l = (116 * y) - 16; - a = 500 * (x - y); - b = 200 * (y - z); +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToObservable; }); +/* harmony import */ var _symbol_observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(24); +/** PURE_IMPORTS_START _symbol_observable PURE_IMPORTS_END */ - return [l, a, b]; +var subscribeToObservable = function (obj) { + return function (subscriber) { + var obs = obj[_symbol_observable__WEBPACK_IMPORTED_MODULE_0__[/* observable */ "a"]](); + if (typeof obs.subscribe !== 'function') { + throw new TypeError('Provided object does not correctly implement Symbol.observable'); + } + else { + return obs.subscribe(subscriber); + } + }; }; +//# sourceMappingURL=subscribeToObservable.js.map -convert.hsl.rgb = function (hsl) { - var h = hsl[0] / 360; - var s = hsl[1] / 100; - var l = hsl[2] / 100; - var t1; - var t2; - var t3; - var rgb; - var val; - - if (s === 0) { - val = l * 255; - return [val, val, val]; - } - if (l < 0.5) { - t2 = l * (1 + s); - } else { - t2 = l + s - l * s; - } +/***/ }), +/* 78 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - t1 = 2 * l - t2; +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isArrayLike; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +var isArrayLike = (function (x) { return x && typeof x.length === 'number' && typeof x !== 'function'; }); +//# sourceMappingURL=isArrayLike.js.map - rgb = [0, 0, 0]; - for (var i = 0; i < 3; i++) { - t3 = h + 1 / 3 * -(i - 1); - if (t3 < 0) { - t3++; - } - if (t3 > 1) { - t3--; - } - if (6 * t3 < 1) { - val = t1 + (t2 - t1) * 6 * t3; - } else if (2 * t3 < 1) { - val = t2; - } else if (3 * t3 < 2) { - val = t1 + (t2 - t1) * (2 / 3 - t3) * 6; - } else { - val = t1; - } +/***/ }), +/* 79 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - rgb[i] = val * 255; - } +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isPromise; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function isPromise(value) { + return value && typeof value.subscribe !== 'function' && typeof value.then === 'function'; +} +//# sourceMappingURL=isPromise.js.map - return rgb; -}; -convert.hsl.hsv = function (hsl) { - var h = hsl[0]; - var s = hsl[1] / 100; - var l = hsl[2] / 100; - var smin = s; - var lmin = Math.max(l, 0.01); - var sv; - var v; +/***/ }), +/* 80 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - l *= 2; - s *= (l <= 1) ? l : 2 - l; - smin *= lmin <= 1 ? lmin : 2 - lmin; - v = (l + s) / 2; - sv = l === 0 ? (2 * smin) / (lmin + smin) : (2 * s) / (l + s); +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToPromise; }); +/* harmony import */ var _hostReportError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(37); +/** PURE_IMPORTS_START _hostReportError PURE_IMPORTS_END */ - return [h, sv * 100, v * 100]; +var subscribeToPromise = function (promise) { + return function (subscriber) { + promise.then(function (value) { + if (!subscriber.closed) { + subscriber.next(value); + subscriber.complete(); + } + }, function (err) { return subscriber.error(err); }) + .then(null, _hostReportError__WEBPACK_IMPORTED_MODULE_0__[/* hostReportError */ "a"]); + return subscriber; + }; }; +//# sourceMappingURL=subscribeToPromise.js.map -convert.hsv.rgb = function (hsv) { - var h = hsv[0] / 60; - var s = hsv[1] / 100; - var v = hsv[2] / 100; - var hi = Math.floor(h) % 6; - var f = h - Math.floor(h); - var p = 255 * v * (1 - s); - var q = 255 * v * (1 - (s * f)); - var t = 255 * v * (1 - (s * (1 - f))); - v *= 255; +/***/ }), +/* 81 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { - switch (hi) { - case 0: - return [v, t, p]; - case 1: - return [q, v, p]; - case 2: - return [p, v, t]; - case 3: - return [p, q, v]; - case 4: - return [t, p, v]; - case 5: - return [v, p, q]; - } +"use strict"; +/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToIterable; }); +/* harmony import */ var _symbol_iterator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23); +/** PURE_IMPORTS_START _symbol_iterator PURE_IMPORTS_END */ + +var subscribeToIterable = function (iterable) { + return function (subscriber) { + var iterator = iterable[_symbol_iterator__WEBPACK_IMPORTED_MODULE_0__[/* iterator */ "a"]](); + do { + var item = iterator.next(); + if (item.done) { + subscriber.complete(); + break; + } + subscriber.next(item.value); + if (subscriber.closed) { + break; + } + } while (true); + if (typeof iterator.return === 'function') { + subscriber.add(function () { + if (iterator.return) { + iterator.return(); + } + }); + } + return subscriber; + }; }; +//# sourceMappingURL=subscribeToIterable.js.map -convert.hsv.hsl = function (hsv) { - var h = hsv[0]; - var s = hsv[1] / 100; - var v = hsv[2] / 100; - var vmin = Math.max(v, 0.01); - var lmin; - var sl; - var l; - l = (2 - s) * v; - lmin = (2 - s) * vmin; - sl = s * vmin; - sl /= (lmin <= 1) ? lmin : 2 - lmin; - sl = sl || 0; - l /= 2; +/***/ }), +/* 82 */ +/***/ (function(module, exports, __webpack_require__) { - return [h, sl * 100, l * 100]; -}; +"use strict"; -// http://dev.w3.org/csswg/css-color/#hwb-to-rgb -convert.hwb.rgb = function (hwb) { - var h = hwb[0] / 360; - var wh = hwb[1] / 100; - var bl = hwb[2] / 100; - var ratio = wh + bl; - var i; - var v; - var f; - var n; - // wh + bl cant be > 1 - if (ratio > 1) { - wh /= ratio; - bl /= ratio; +var matchOperatorsRe = /[|\\{}()[\]^$+*?.]/g; + +module.exports = function (str) { + if (typeof str !== 'string') { + throw new TypeError('Expected a string'); } - i = Math.floor(6 * h); - v = 1 - bl; - f = 6 * h - i; + return str.replace(matchOperatorsRe, '\\$&'); +}; - if ((i & 0x01) !== 0) { - f = 1 - f; - } - n = wh + f * (v - wh); // linear interpolation +/***/ }), +/* 83 */ +/***/ (function(module, exports, __webpack_require__) { - var r; - var g; - var b; - switch (i) { - default: - case 6: - case 0: r = v; g = n; b = wh; break; - case 1: r = n; g = v; b = wh; break; - case 2: r = wh; g = v; b = n; break; - case 3: r = wh; g = n; b = v; break; - case 4: r = n; g = wh; b = v; break; - case 5: r = v; g = wh; b = n; break; - } +var conversions = __webpack_require__(92); +var route = __webpack_require__(123); - return [r * 255, g * 255, b * 255]; -}; +var convert = {}; -convert.cmyk.rgb = function (cmyk) { - var c = cmyk[0] / 100; - var m = cmyk[1] / 100; - var y = cmyk[2] / 100; - var k = cmyk[3] / 100; - var r; - var g; - var b; +var models = Object.keys(conversions); + +function wrapRaw(fn) { + var wrappedFn = function (args) { + if (args === undefined || args === null) { + return args; + } - r = 1 - Math.min(1, c * (1 - k) + k); - g = 1 - Math.min(1, m * (1 - k) + k); - b = 1 - Math.min(1, y * (1 - k) + k); + if (arguments.length > 1) { + args = Array.prototype.slice.call(arguments); + } - return [r * 255, g * 255, b * 255]; -}; + return fn(args); + }; -convert.xyz.rgb = function (xyz) { - var x = xyz[0] / 100; - var y = xyz[1] / 100; - var z = xyz[2] / 100; - var r; - var g; - var b; + // preserve .conversion property if there is one + if ('conversion' in fn) { + wrappedFn.conversion = fn.conversion; + } - r = (x * 3.2406) + (y * -1.5372) + (z * -0.4986); - g = (x * -0.9689) + (y * 1.8758) + (z * 0.0415); - b = (x * 0.0557) + (y * -0.2040) + (z * 1.0570); + return wrappedFn; +} - // assume sRGB - r = r > 0.0031308 - ? ((1.055 * Math.pow(r, 1.0 / 2.4)) - 0.055) - : r * 12.92; +function wrapRounded(fn) { + var wrappedFn = function (args) { + if (args === undefined || args === null) { + return args; + } - g = g > 0.0031308 - ? ((1.055 * Math.pow(g, 1.0 / 2.4)) - 0.055) - : g * 12.92; + if (arguments.length > 1) { + args = Array.prototype.slice.call(arguments); + } - b = b > 0.0031308 - ? ((1.055 * Math.pow(b, 1.0 / 2.4)) - 0.055) - : b * 12.92; + var result = fn(args); - r = Math.min(Math.max(0, r), 1); - g = Math.min(Math.max(0, g), 1); - b = Math.min(Math.max(0, b), 1); + // we're assuming the result is an array here. + // see notice in conversions.js; don't use box types + // in conversion functions. + if (typeof result === 'object') { + for (var len = result.length, i = 0; i < len; i++) { + result[i] = Math.round(result[i]); + } + } - return [r * 255, g * 255, b * 255]; -}; + return result; + }; -convert.xyz.lab = function (xyz) { - var x = xyz[0]; - var y = xyz[1]; - var z = xyz[2]; - var l; - var a; - var b; + // preserve .conversion property if there is one + if ('conversion' in fn) { + wrappedFn.conversion = fn.conversion; + } - x /= 95.047; - y /= 100; - z /= 108.883; + return wrappedFn; +} - x = x > 0.008856 ? Math.pow(x, 1 / 3) : (7.787 * x) + (16 / 116); - y = y > 0.008856 ? Math.pow(y, 1 / 3) : (7.787 * y) + (16 / 116); - z = z > 0.008856 ? Math.pow(z, 1 / 3) : (7.787 * z) + (16 / 116); +models.forEach(function (fromModel) { + convert[fromModel] = {}; - l = (116 * y) - 16; - a = 500 * (x - y); - b = 200 * (y - z); + Object.defineProperty(convert[fromModel], 'channels', {value: conversions[fromModel].channels}); + Object.defineProperty(convert[fromModel], 'labels', {value: conversions[fromModel].labels}); - return [l, a, b]; -}; + var routes = route(fromModel); + var routeModels = Object.keys(routes); -convert.lab.xyz = function (lab) { - var l = lab[0]; - var a = lab[1]; - var b = lab[2]; - var x; - var y; - var z; + routeModels.forEach(function (toModel) { + var fn = routes[toModel]; - y = (l + 16) / 116; - x = a / 500 + y; - z = y - b / 200; + convert[fromModel][toModel] = wrapRounded(fn); + convert[fromModel][toModel].raw = wrapRaw(fn); + }); +}); - var y2 = Math.pow(y, 3); - var x2 = Math.pow(x, 3); - var z2 = Math.pow(z, 3); - y = y2 > 0.008856 ? y2 : (y - 16 / 116) / 7.787; - x = x2 > 0.008856 ? x2 : (x - 16 / 116) / 7.787; - z = z2 > 0.008856 ? z2 : (z - 16 / 116) / 7.787; +module.exports = convert; - x *= 95.047; - y *= 100; - z *= 108.883; - return [x, y, z]; -}; +/***/ }), +/* 84 */ +/***/ (function(module, exports) { -convert.lab.lch = function (lab) { - var l = lab[0]; - var a = lab[1]; - var b = lab[2]; - var hr; - var h; - var c; +module.exports = require("os"); - hr = Math.atan2(b, a); - h = hr * 360 / 2 / Math.PI; +/***/ }), +/* 85 */ +/***/ (function(module, exports, __webpack_require__) { - if (h < 0) { - h += 360; - } +"use strict"; - c = Math.sqrt(a * a + b * b); - return [l, c, h]; -}; +Object.defineProperty(exports, "__esModule", { + value: true +}); -convert.lch.lab = function (lch) { - var l = lch[0]; - var c = lch[1]; - var h = lch[2]; - var a; - var b; - var hr; +/* + * 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. + */ +let parallelizeBatches = exports.parallelizeBatches = (() => { + var _ref = _asyncToGenerator(function* (batches, fn) { + for (const batch of batches) { + // We need to make sure the entire batch has completed before we can move on + // to the next batch + yield parallelize(batch, fn); + } + }); - hr = h / 360 * 2 * Math.PI; - a = c * Math.cos(hr); - b = c * Math.sin(hr); + return function parallelizeBatches(_x, _x2) { + return _ref.apply(this, arguments); + }; +})(); - return [l, a, b]; -}; +let parallelize = exports.parallelize = (() => { + var _ref2 = _asyncToGenerator(function* (items, fn, concurrency = 4) { + if (items.length === 0) { + return; + } + return new Promise(function (resolve, reject) { + let scheduleItem = (() => { + var _ref3 = _asyncToGenerator(function* (item) { + activePromises++; + try { + yield fn(item); + activePromises--; + if (values.length > 0) { + // We have more work to do, so we schedule the next promise + scheduleItem(values.shift()); + } else if (activePromises === 0) { + // We have no more values left, and all items have completed, so we've + // completed all the work. + resolve(); + } + } catch (error) { + reject(error); + } + }); -convert.rgb.ansi16 = function (args) { - var r = args[0]; - var g = args[1]; - var b = args[2]; - var value = 1 in arguments ? arguments[1] : convert.rgb.hsv(args)[2]; // hsv -> ansi16 optimization + return function scheduleItem(_x5) { + return _ref3.apply(this, arguments); + }; + })(); - value = Math.round(value / 50); + let activePromises = 0; + const values = items.slice(0); - if (value === 0) { - return 30; - } + values.splice(0, concurrency).map(scheduleItem); + }); + }); - var ansi = 30 - + ((Math.round(b / 255) << 2) - | (Math.round(g / 255) << 1) - | Math.round(r / 255)); + return function parallelize(_x3, _x4) { + return _ref2.apply(this, arguments); + }; +})(); - if (value === 2) { - ansi += 60; - } +function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } - return ansi; -}; +/***/ }), +/* 86 */ +/***/ (function(module, exports, __webpack_require__) { -convert.hsv.ansi16 = function (args) { - // optimization here; we already know the value and don't need to get - // it converted for us. - return convert.rgb.ansi16(convert.hsv.rgb(args), args[2]); -}; +module.exports = minimatch +minimatch.Minimatch = Minimatch + +var path = { sep: '/' } +try { + path = __webpack_require__(7) +} catch (er) {} -convert.rgb.ansi256 = function (args) { - var r = args[0]; - var g = args[1]; - var b = args[2]; +var GLOBSTAR = minimatch.GLOBSTAR = Minimatch.GLOBSTAR = {} +var expand = __webpack_require__(137) - // we use the extended greyscale palette here, with the exception of - // black and white. normal palette only has 4 greyscale shades. - if (r === g && g === b) { - if (r < 8) { - return 16; - } +var plTypes = { + '!': { open: '(?:(?!(?:', close: '))[^/]*?)'}, + '?': { open: '(?:', close: ')?' }, + '+': { open: '(?:', close: ')+' }, + '*': { open: '(?:', close: ')*' }, + '@': { open: '(?:', close: ')' } +} - if (r > 248) { - return 231; - } +// any single thing other than / +// don't need to escape / when using new RegExp() +var qmark = '[^/]' - return Math.round(((r - 8) / 247) * 24) + 232; - } +// * => any number of characters +var star = qmark + '*?' - var ansi = 16 - + (36 * Math.round(r / 255 * 5)) - + (6 * Math.round(g / 255 * 5)) - + Math.round(b / 255 * 5); +// ** when dots are allowed. Anything goes, except .. and . +// not (^ or / followed by one or two dots followed by $ or /), +// followed by anything, any number of times. +var twoStarDot = '(?:(?!(?:\\\/|^)(?:\\.{1,2})($|\\\/)).)*?' - return ansi; -}; +// not a ^ or / followed by a dot, +// followed by anything, any number of times. +var twoStarNoDot = '(?:(?!(?:\\\/|^)\\.).)*?' -convert.ansi16.rgb = function (args) { - var color = args % 10; +// characters that need to be escaped in RegExp. +var reSpecials = charSet('().*{}+?[]^$\\!') - // handle greyscale - if (color === 0 || color === 7) { - if (args > 50) { - color += 3.5; - } +// "abc" -> { a:true, b:true, c:true } +function charSet (s) { + return s.split('').reduce(function (set, c) { + set[c] = true + return set + }, {}) +} - color = color / 10.5 * 255; +// normalizes slashes. +var slashSplit = /\/+/ - return [color, color, color]; - } +minimatch.filter = filter +function filter (pattern, options) { + options = options || {} + return function (p, i, list) { + return minimatch(p, pattern, options) + } +} - var mult = (~~(args > 50) + 1) * 0.5; - var r = ((color & 1) * mult) * 255; - var g = (((color >> 1) & 1) * mult) * 255; - var b = (((color >> 2) & 1) * mult) * 255; +function ext (a, b) { + a = a || {} + b = b || {} + var t = {} + Object.keys(b).forEach(function (k) { + t[k] = b[k] + }) + Object.keys(a).forEach(function (k) { + t[k] = a[k] + }) + return t +} - return [r, g, b]; -}; +minimatch.defaults = function (def) { + if (!def || !Object.keys(def).length) return minimatch -convert.ansi256.rgb = function (args) { - // handle greyscale - if (args >= 232) { - var c = (args - 232) * 10 + 8; - return [c, c, c]; - } + var orig = minimatch - args -= 16; + var m = function minimatch (p, pattern, options) { + return orig.minimatch(p, pattern, ext(def, options)) + } - var rem; - var r = Math.floor(args / 36) / 5 * 255; - var g = Math.floor((rem = args % 36) / 6) / 5 * 255; - var b = (rem % 6) / 5 * 255; + m.Minimatch = function Minimatch (pattern, options) { + return new orig.Minimatch(pattern, ext(def, options)) + } - return [r, g, b]; -}; + return m +} -convert.rgb.hex = function (args) { - var integer = ((Math.round(args[0]) & 0xFF) << 16) - + ((Math.round(args[1]) & 0xFF) << 8) - + (Math.round(args[2]) & 0xFF); +Minimatch.defaults = function (def) { + if (!def || !Object.keys(def).length) return Minimatch + return minimatch.defaults(def).Minimatch +} - var string = integer.toString(16).toUpperCase(); - return '000000'.substring(string.length) + string; -}; +function minimatch (p, pattern, options) { + if (typeof pattern !== 'string') { + throw new TypeError('glob pattern string required') + } -convert.hex.rgb = function (args) { - var match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i); - if (!match) { - return [0, 0, 0]; - } + if (!options) options = {} - var colorString = match[0]; + // shortcut: comments match nothing. + if (!options.nocomment && pattern.charAt(0) === '#') { + return false + } - if (match[0].length === 3) { - colorString = colorString.split('').map(function (char) { - return char + char; - }).join(''); - } + // "" only matches "" + if (pattern.trim() === '') return p === '' - var integer = parseInt(colorString, 16); - var r = (integer >> 16) & 0xFF; - var g = (integer >> 8) & 0xFF; - var b = integer & 0xFF; + return new Minimatch(pattern, options).match(p) +} - return [r, g, b]; -}; +function Minimatch (pattern, options) { + if (!(this instanceof Minimatch)) { + return new Minimatch(pattern, options) + } -convert.rgb.hcg = function (rgb) { - var r = rgb[0] / 255; - var g = rgb[1] / 255; - var b = rgb[2] / 255; - var max = Math.max(Math.max(r, g), b); - var min = Math.min(Math.min(r, g), b); - var chroma = (max - min); - var grayscale; - var hue; + if (typeof pattern !== 'string') { + throw new TypeError('glob pattern string required') + } - if (chroma < 1) { - grayscale = min / (1 - chroma); - } else { - grayscale = 0; - } + if (!options) options = {} + pattern = pattern.trim() - if (chroma <= 0) { - hue = 0; - } else - if (max === r) { - hue = ((g - b) / chroma) % 6; - } else - if (max === g) { - hue = 2 + (b - r) / chroma; - } else { - hue = 4 + (r - g) / chroma + 4; - } + // windows support: need to use /, not \ + if (path.sep !== '/') { + pattern = pattern.split(path.sep).join('/') + } - hue /= 6; - hue %= 1; + this.options = options + this.set = [] + this.pattern = pattern + this.regexp = null + this.negate = false + this.comment = false + this.empty = false - return [hue * 360, chroma * 100, grayscale * 100]; -}; + // make the set of regexps etc. + this.make() +} -convert.hsl.hcg = function (hsl) { - var s = hsl[1] / 100; - var l = hsl[2] / 100; - var c = 1; - var f = 0; +Minimatch.prototype.debug = function () {} - if (l < 0.5) { - c = 2.0 * s * l; - } else { - c = 2.0 * s * (1.0 - l); - } +Minimatch.prototype.make = make +function make () { + // don't do it more than once. + if (this._made) return - if (c < 1.0) { - f = (l - 0.5 * c) / (1.0 - c); - } + var pattern = this.pattern + var options = this.options - return [hsl[0], c * 100, f * 100]; -}; + // empty patterns and comments match nothing. + if (!options.nocomment && pattern.charAt(0) === '#') { + this.comment = true + return + } + if (!pattern) { + this.empty = true + return + } -convert.hsv.hcg = function (hsv) { - var s = hsv[1] / 100; - var v = hsv[2] / 100; + // step 1: figure out negation, etc. + this.parseNegate() - var c = s * v; - var f = 0; + // step 2: expand braces + var set = this.globSet = this.braceExpand() - if (c < 1.0) { - f = (v - c) / (1 - c); - } + if (options.debug) this.debug = console.error - return [hsv[0], c * 100, f * 100]; -}; + this.debug(this.pattern, set) -convert.hcg.rgb = function (hcg) { - var h = hcg[0] / 360; - var c = hcg[1] / 100; - var g = hcg[2] / 100; + // step 3: now we have a set, so turn each one into a series of path-portion + // matching patterns. + // These will be regexps, except in the case of "**", which is + // set to the GLOBSTAR object for globstar behavior, + // and will not contain any / characters + set = this.globParts = set.map(function (s) { + return s.split(slashSplit) + }) - if (c === 0.0) { - return [g * 255, g * 255, g * 255]; - } + this.debug(this.pattern, set) - var pure = [0, 0, 0]; - var hi = (h % 1) * 6; - var v = hi % 1; - var w = 1 - v; - var mg = 0; + // glob --> regexps + set = set.map(function (s, si, set) { + return s.map(this.parse, this) + }, this) - switch (Math.floor(hi)) { - case 0: - pure[0] = 1; pure[1] = v; pure[2] = 0; break; - case 1: - pure[0] = w; pure[1] = 1; pure[2] = 0; break; - case 2: - pure[0] = 0; pure[1] = 1; pure[2] = v; break; - case 3: - pure[0] = 0; pure[1] = w; pure[2] = 1; break; - case 4: - pure[0] = v; pure[1] = 0; pure[2] = 1; break; - default: - pure[0] = 1; pure[1] = 0; pure[2] = w; - } + this.debug(this.pattern, set) - mg = (1.0 - c) * g; + // filter out everything that didn't compile properly. + set = set.filter(function (s) { + return s.indexOf(false) === -1 + }) - return [ - (c * pure[0] + mg) * 255, - (c * pure[1] + mg) * 255, - (c * pure[2] + mg) * 255 - ]; -}; + this.debug(this.pattern, set) -convert.hcg.hsv = function (hcg) { - var c = hcg[1] / 100; - var g = hcg[2] / 100; + this.set = set +} - var v = c + g * (1.0 - c); - var f = 0; +Minimatch.prototype.parseNegate = parseNegate +function parseNegate () { + var pattern = this.pattern + var negate = false + var options = this.options + var negateOffset = 0 - if (v > 0.0) { - f = c / v; - } + if (options.nonegate) return - return [hcg[0], f * 100, v * 100]; -}; + for (var i = 0, l = pattern.length + ; i < l && pattern.charAt(i) === '!' + ; i++) { + negate = !negate + negateOffset++ + } -convert.hcg.hsl = function (hcg) { - var c = hcg[1] / 100; - var g = hcg[2] / 100; + if (negateOffset) this.pattern = pattern.substr(negateOffset) + this.negate = negate +} - var l = g * (1.0 - c) + 0.5 * c; - var s = 0; +// Brace expansion: +// a{b,c}d -> abd acd +// a{b,}c -> abc ac +// a{0..3}d -> a0d a1d a2d a3d +// a{b,c{d,e}f}g -> abg acdfg acefg +// a{b,c}d{e,f}g -> abdeg acdeg abdeg abdfg +// +// Invalid sets are not expanded. +// a{2..}b -> a{2..}b +// a{b}c -> a{b}c +minimatch.braceExpand = function (pattern, options) { + return braceExpand(pattern, options) +} - if (l > 0.0 && l < 0.5) { - s = c / (2 * l); - } else - if (l >= 0.5 && l < 1.0) { - s = c / (2 * (1 - l)); - } +Minimatch.prototype.braceExpand = braceExpand - return [hcg[0], s * 100, l * 100]; -}; +function braceExpand (pattern, options) { + if (!options) { + if (this instanceof Minimatch) { + options = this.options + } else { + options = {} + } + } -convert.hcg.hwb = function (hcg) { - var c = hcg[1] / 100; - var g = hcg[2] / 100; - var v = c + g * (1.0 - c); - return [hcg[0], (v - c) * 100, (1 - v) * 100]; -}; + pattern = typeof pattern === 'undefined' + ? this.pattern : pattern -convert.hwb.hcg = function (hwb) { - var w = hwb[1] / 100; - var b = hwb[2] / 100; - var v = 1 - b; - var c = v - w; - var g = 0; + if (typeof pattern === 'undefined') { + throw new TypeError('undefined pattern') + } - if (c < 1) { - g = (v - c) / (1 - c); - } + if (options.nobrace || + !pattern.match(/\{.*\}/)) { + // shortcut. no need to expand. + return [pattern] + } - return [hwb[0], c * 100, g * 100]; -}; + return expand(pattern) +} -convert.apple.rgb = function (apple) { - return [(apple[0] / 65535) * 255, (apple[1] / 65535) * 255, (apple[2] / 65535) * 255]; -}; +// parse a component of the expanded set. +// At this point, no pattern may contain "/" in it +// so we're going to return a 2d array, where each entry is the full +// pattern, split on '/', and then turned into a regular expression. +// A regexp is made at the end which joins each array with an +// escaped /, and another full one which joins each regexp with |. +// +// Following the lead of Bash 4.1, note that "**" only has special meaning +// when it is the *only* thing in a path portion. Otherwise, any series +// of * is equivalent to a single *. Globstar behavior is enabled by +// default, and can be disabled by setting options.noglobstar. +Minimatch.prototype.parse = parse +var SUBPARSE = {} +function parse (pattern, isSub) { + if (pattern.length > 1024 * 64) { + throw new TypeError('pattern is too long') + } -convert.rgb.apple = function (rgb) { - return [(rgb[0] / 255) * 65535, (rgb[1] / 255) * 65535, (rgb[2] / 255) * 65535]; -}; + var options = this.options -convert.gray.rgb = function (args) { - return [args[0] / 100 * 255, args[0] / 100 * 255, args[0] / 100 * 255]; -}; + // shortcuts + if (!options.noglobstar && pattern === '**') return GLOBSTAR + if (pattern === '') return '' -convert.gray.hsl = convert.gray.hsv = function (args) { - return [0, 0, args[0]]; -}; + var re = '' + var hasMagic = !!options.nocase + var escaping = false + // ? => one single character + var patternListStack = [] + var negativeLists = [] + var stateChar + var inClass = false + var reClassStart = -1 + var classStart = -1 + // . and .. never match anything that doesn't start with ., + // even when options.dot is set. + var patternStart = pattern.charAt(0) === '.' ? '' // anything + // not (start or / followed by . or .. followed by / or end) + : options.dot ? '(?!(?:^|\\\/)\\.{1,2}(?:$|\\\/))' + : '(?!\\.)' + var self = this -convert.gray.hwb = function (gray) { - return [0, 100, gray[0]]; -}; + function clearStateChar () { + if (stateChar) { + // we had some state-tracking character + // that wasn't consumed by this pass. + switch (stateChar) { + case '*': + re += star + hasMagic = true + break + case '?': + re += qmark + hasMagic = true + break + default: + re += '\\' + stateChar + break + } + self.debug('clearStateChar %j %j', stateChar, re) + stateChar = false + } + } -convert.gray.cmyk = function (gray) { - return [0, 0, 0, gray[0]]; -}; + for (var i = 0, len = pattern.length, c + ; (i < len) && (c = pattern.charAt(i)) + ; i++) { + this.debug('%s\t%s %s %j', pattern, i, re, c) -convert.gray.lab = function (gray) { - return [gray[0], 0, 0]; -}; + // skip over any that are escaped. + if (escaping && reSpecials[c]) { + re += '\\' + c + escaping = false + continue + } -convert.gray.hex = function (gray) { - var val = Math.round(gray[0] / 100 * 255) & 0xFF; - var integer = (val << 16) + (val << 8) + val; + switch (c) { + case '/': + // completely not allowed, even escaped. + // Should already be path-split by now. + return false - var string = integer.toString(16).toUpperCase(); - return '000000'.substring(string.length) + string; -}; + case '\\': + clearStateChar() + escaping = true + continue -convert.rgb.gray = function (rgb) { - var val = (rgb[0] + rgb[1] + rgb[2]) / 3; - return [val / 255 * 100]; -}; + // the various stateChar values + // for the "extglob" stuff. + case '?': + case '*': + case '+': + case '@': + case '!': + this.debug('%s\t%s %s %j <-- stateChar', pattern, i, re, c) + // all of those are literals inside a class, except that + // the glob [!a] means [^a] in regexp + if (inClass) { + this.debug(' in class') + if (c === '!' && i === classStart + 1) c = '^' + re += c + continue + } -/***/ }), -/* 78 */ -/***/ (function(module, exports, __webpack_require__) { + // if we already have a stateChar, then it means + // that there was something like ** or +? in there. + // Handle the stateChar, then proceed with this one. + self.debug('call clearStateChar %j', stateChar) + clearStateChar() + stateChar = c + // if extglob is disabled, then +(asdf|foo) isn't a thing. + // just clear the statechar *now*, rather than even diving into + // the patternList stuff. + if (options.noext) clearStateChar() + continue -"use strict"; + case '(': + if (inClass) { + re += '(' + continue + } -module.exports = (flag, argv) => { - argv = argv || process.argv; - const prefix = flag.startsWith('-') ? '' : (flag.length === 1 ? '-' : '--'); - const pos = argv.indexOf(prefix + flag); - const terminatorPos = argv.indexOf('--'); - return pos !== -1 && (terminatorPos === -1 ? true : pos < terminatorPos); -}; + if (!stateChar) { + re += '\\(' + continue + } + patternListStack.push({ + type: stateChar, + start: i - 1, + reStart: re.length, + open: plTypes[stateChar].open, + close: plTypes[stateChar].close + }) + // negation is (?:(?!js)[^/]*) + re += stateChar === '!' ? '(?:(?!(?:' : '(?:' + this.debug('plType %j %j', stateChar, re) + stateChar = false + continue -/***/ }), -/* 79 */ -/***/ (function(module, exports, __webpack_require__) { + case ')': + if (inClass || !patternListStack.length) { + re += '\\)' + continue + } -"use strict"; + clearStateChar() + hasMagic = true + var pl = patternListStack.pop() + // negation is (?:(?!js)[^/]*) + // The others are (?:) + re += pl.close + if (pl.type === '!') { + negativeLists.push(pl) + } + pl.reEnd = re.length + continue + case '|': + if (inClass || !patternListStack.length || escaping) { + re += '\\|' + escaping = false + continue + } -var fs = __webpack_require__(6) + clearStateChar() + re += '|' + continue -module.exports = clone(fs) + // these are mostly the same in regexp and glob + case '[': + // swallow any state-tracking char before the [ + clearStateChar() -function clone (obj) { - if (obj === null || typeof obj !== 'object') - return obj + if (inClass) { + re += '\\' + c + continue + } - if (obj instanceof Object) - var copy = { __proto__: obj.__proto__ } - else - var copy = Object.create(null) + inClass = true + classStart = i + reClassStart = re.length + re += c + continue - Object.getOwnPropertyNames(obj).forEach(function (key) { - Object.defineProperty(copy, key, Object.getOwnPropertyDescriptor(obj, key)) - }) + case ']': + // a right bracket shall lose its special + // meaning and represent itself in + // a bracket expression if it occurs + // first in the list. -- POSIX.2 2.8.3.2 + if (i === classStart + 1 || !inClass) { + re += '\\' + c + escaping = false + continue + } - return copy -} + // handle the case where we left a class open. + // "[z-a]" is valid, equivalent to "\[z-a\]" + if (inClass) { + // split where the last [ was, make sure we don't have + // an invalid re. if so, re-walk the contents of the + // would-be class to re-translate any characters that + // were passed through as-is + // TODO: It would probably be faster to determine this + // without a try/catch and a new RegExp, but it's tricky + // to do safely. For now, this is safe and works. + var cs = pattern.substring(classStart + 1, i) + try { + RegExp('[' + cs + ']') + } catch (er) { + // not a valid class! + var sp = this.parse(cs, SUBPARSE) + re = re.substr(0, reClassStart) + '\\[' + sp[0] + '\\]' + hasMagic = hasMagic || sp[1] + inClass = false + continue + } + } + // finish up the class. + hasMagic = true + inClass = false + re += c + continue -/***/ }), -/* 80 */ -/***/ (function(module, exports, __webpack_require__) { + default: + // swallow any state char that wasn't consumed + clearStateChar() -var path = __webpack_require__(2); -var fs = __webpack_require__(6); -var _0777 = parseInt('0777', 8); + if (escaping) { + // no need + escaping = false + } else if (reSpecials[c] + && !(c === '^' && inClass)) { + re += '\\' + } -module.exports = mkdirP.mkdirp = mkdirP.mkdirP = mkdirP; + re += c -function mkdirP (p, opts, f, made) { - if (typeof opts === 'function') { - f = opts; - opts = {}; - } - else if (!opts || typeof opts !== 'object') { - opts = { mode: opts }; - } - - var mode = opts.mode; - var xfs = opts.fs || fs; - - if (mode === undefined) { - mode = _0777 & (~process.umask()); - } - if (!made) made = null; - - var cb = f || function () {}; - p = path.resolve(p); - - xfs.mkdir(p, mode, function (er) { - if (!er) { - made = made || p; - return cb(null, made); - } - switch (er.code) { - case 'ENOENT': - mkdirP(path.dirname(p), opts, function (er, made) { - if (er) cb(er, made); - else mkdirP(p, opts, cb, made); - }); - break; + } // switch + } // for - // In the case of any other error, just see if there's a dir - // there already. If so, then hooray! If not, then something - // is borked. - default: - xfs.stat(p, function (er2, stat) { - // if the stat fails, then that's super weird. - // let the original error be the failure reason. - if (er2 || !stat.isDirectory()) cb(er, made) - else cb(null, made); - }); - break; - } - }); -} + // handle the case where we left a class open. + // "[abc" is valid, equivalent to "\[abc" + if (inClass) { + // split where the last [ was, and escape it + // this is a huge pita. We now have to re-walk + // the contents of the would-be class to re-translate + // any characters that were passed through as-is + cs = pattern.substr(classStart + 1) + sp = this.parse(cs, SUBPARSE) + re = re.substr(0, reClassStart) + '\\[' + sp[0] + hasMagic = hasMagic || sp[1] + } -mkdirP.sync = function sync (p, opts, made) { - if (!opts || typeof opts !== 'object') { - opts = { mode: opts }; - } - - var mode = opts.mode; - var xfs = opts.fs || fs; - - if (mode === undefined) { - mode = _0777 & (~process.umask()); - } - if (!made) made = null; + // handle the case where we had a +( thing at the *end* + // of the pattern. + // each pattern list stack adds 3 chars, and we need to go through + // and escape any | chars that were passed through as-is for the regexp. + // Go through and escape them, taking care not to double-escape any + // | chars that were already escaped. + for (pl = patternListStack.pop(); pl; pl = patternListStack.pop()) { + var tail = re.slice(pl.reStart + pl.open.length) + this.debug('setting tail', re, pl) + // maybe some even number of \, then maybe 1 \, followed by a | + tail = tail.replace(/((?:\\{2}){0,64})(\\?)\|/g, function (_, $1, $2) { + if (!$2) { + // the | isn't already escaped, so escape it. + $2 = '\\' + } - p = path.resolve(p); + // need to escape all those slashes *again*, without escaping the + // one that we need for escaping the | character. As it works out, + // escaping an even number of slashes can be done by simply repeating + // it exactly after itself. That's why this trick works. + // + // I am sorry that you have to see this. + return $1 + $1 + $2 + '|' + }) + + this.debug('tail=%j\n %s', tail, tail, pl, re) + var t = pl.type === '*' ? star + : pl.type === '?' ? qmark + : '\\' + pl.type - try { - xfs.mkdirSync(p, mode); - made = made || p; - } - catch (err0) { - switch (err0.code) { - case 'ENOENT' : - made = sync(path.dirname(p), opts, made); - sync(p, opts, made); - break; + hasMagic = true + re = re.slice(0, pl.reStart) + t + '\\(' + tail + } - // In the case of any other error, just see if there's a dir - // there already. If so, then hooray! If not, then something - // is borked. - default: - var stat; - try { - stat = xfs.statSync(p); - } - catch (err1) { - throw err0; - } - if (!stat.isDirectory()) throw err0; - break; - } - } + // handle trailing things that only matter at the very end. + clearStateChar() + if (escaping) { + // trailing \\ + re += '\\\\' + } - return made; -}; + // only need to apply the nodot start if the re starts with + // something that could conceivably capture a dot + var addPatternStart = false + switch (re.charAt(0)) { + case '.': + case '[': + case '(': addPatternStart = true + } + // Hack to work around lack of negative lookbehind in JS + // A pattern like: *.!(x).!(y|z) needs to ensure that a name + // like 'a.xyz.yz' doesn't match. So, the first negative + // lookahead, has to look ALL the way ahead, to the end of + // the pattern. + for (var n = negativeLists.length - 1; n > -1; n--) { + var nl = negativeLists[n] -/***/ }), -/* 81 */ -/***/ (function(module, exports, __webpack_require__) { + var nlBefore = re.slice(0, nl.reStart) + var nlFirst = re.slice(nl.reStart, nl.reEnd - 8) + var nlLast = re.slice(nl.reEnd - 8, nl.reEnd) + var nlAfter = re.slice(nl.reEnd) -module.exports = realpath -realpath.realpath = realpath -realpath.sync = realpathSync -realpath.realpathSync = realpathSync -realpath.monkeypatch = monkeypatch -realpath.unmonkeypatch = unmonkeypatch + nlLast += nlAfter -var fs = __webpack_require__(6) -var origRealpath = fs.realpath -var origRealpathSync = fs.realpathSync + // Handle nested stuff like *(*.js|!(*.json)), where open parens + // mean that we should *not* include the ) in the bit that is considered + // "after" the negated section. + var openParensBefore = nlBefore.split('(').length - 1 + var cleanAfter = nlAfter + for (i = 0; i < openParensBefore; i++) { + cleanAfter = cleanAfter.replace(/\)[+*?]?/, '') + } + nlAfter = cleanAfter -var version = process.version -var ok = /^v[0-5]\./.test(version) -var old = __webpack_require__(153) + var dollar = '' + if (nlAfter === '' && isSub !== SUBPARSE) { + dollar = '$' + } + var newRe = nlBefore + nlFirst + nlAfter + dollar + nlLast + re = newRe + } -function newError (er) { - return er && er.syscall === 'realpath' && ( - er.code === 'ELOOP' || - er.code === 'ENOMEM' || - er.code === 'ENAMETOOLONG' - ) -} + // if the re is not "" at this point, then we need to make sure + // it doesn't match against an empty path part. + // Otherwise a/* will match a/, which it should not. + if (re !== '' && hasMagic) { + re = '(?=.)' + re + } -function realpath (p, cache, cb) { - if (ok) { - return origRealpath(p, cache, cb) + if (addPatternStart) { + re = patternStart + re } - if (typeof cache === 'function') { - cb = cache - cache = null + // parsing just a piece of a larger pattern. + if (isSub === SUBPARSE) { + return [re, hasMagic] } - origRealpath(p, cache, function (er, result) { - if (newError(er)) { - old.realpath(p, cache, cb) - } else { - cb(er, result) - } - }) -} -function realpathSync (p, cache) { - if (ok) { - return origRealpathSync(p, cache) + // skip the regexp for non-magical patterns + // unescape anything in it, though, so that it'll be + // an exact match against a file etc. + if (!hasMagic) { + return globUnescape(pattern) } + var flags = options.nocase ? 'i' : '' try { - return origRealpathSync(p, cache) + var regExp = new RegExp('^' + re + '$', flags) } catch (er) { - if (newError(er)) { - return old.realpathSync(p, cache) - } else { - throw er - } + // If it was an invalid regular expression, then it can't match + // anything. This trick looks for a character after the end of + // the string, which is of course impossible, except in multi-line + // mode, but it's not a /m regex. + return new RegExp('$.') } -} -function monkeypatch () { - fs.realpath = realpath - fs.realpathSync = realpathSync -} + regExp._glob = pattern + regExp._src = re -function unmonkeypatch () { - fs.realpath = origRealpath - fs.realpathSync = origRealpathSync + return regExp } +minimatch.makeRe = function (pattern, options) { + return new Minimatch(pattern, options || {}).makeRe() +} -/***/ }), -/* 82 */ -/***/ (function(module, exports, __webpack_require__) { +Minimatch.prototype.makeRe = makeRe +function makeRe () { + if (this.regexp || this.regexp === false) return this.regexp -try { - var util = __webpack_require__(8); - if (typeof util.inherits !== 'function') throw ''; - module.exports = util.inherits; -} catch (e) { - module.exports = __webpack_require__(157); -} + // at this point, this.set is a 2d array of partial + // pattern strings, or "**". + // + // It's better to use .match(). This function shouldn't + // be used, really, but it's pretty convenient sometimes, + // when you just want to work with a regex. + var set = this.set + if (!set.length) { + this.regexp = false + return this.regexp + } + var options = this.options -/***/ }), -/* 83 */ -/***/ (function(module, exports, __webpack_require__) { + var twoStar = options.noglobstar ? star + : options.dot ? twoStarDot + : twoStarNoDot + var flags = options.nocase ? 'i' : '' -exports.alphasort = alphasort -exports.alphasorti = alphasorti -exports.setopts = setopts -exports.ownProp = ownProp -exports.makeAbs = makeAbs -exports.finish = finish -exports.mark = mark -exports.isIgnored = isIgnored -exports.childrenIgnored = childrenIgnored + var re = set.map(function (pattern) { + return pattern.map(function (p) { + return (p === GLOBSTAR) ? twoStar + : (typeof p === 'string') ? regExpEscape(p) + : p._src + }).join('\\\/') + }).join('|') -function ownProp (obj, field) { - return Object.prototype.hasOwnProperty.call(obj, field) -} + // must match entire pattern + // ending in a * or ** will make it less strict. + re = '^(?:' + re + ')$' -var path = __webpack_require__(2) -var minimatch = __webpack_require__(55) -var isAbsolute = __webpack_require__(56) -var Minimatch = minimatch.Minimatch + // can match anything, as long as it's not this. + if (this.negate) re = '^(?!' + re + ').*$' -function alphasorti (a, b) { - return a.toLowerCase().localeCompare(b.toLowerCase()) + try { + this.regexp = new RegExp(re, flags) + } catch (ex) { + this.regexp = false + } + return this.regexp } -function alphasort (a, b) { - return a.localeCompare(b) +minimatch.match = function (list, pattern, options) { + options = options || {} + var mm = new Minimatch(pattern, options) + list = list.filter(function (f) { + return mm.match(f) + }) + if (mm.options.nonull && !list.length) { + list.push(pattern) + } + return list } -function setupIgnores (self, options) { - self.ignore = options.ignore || [] +Minimatch.prototype.match = match +function match (f, partial) { + this.debug('match', f, this.pattern) + // short-circuit in the case of busted things. + // comments, etc. + if (this.comment) return false + if (this.empty) return f === '' + + if (f === '/' && partial) return true + + var options = this.options + + // windows: need to use /, not \ + if (path.sep !== '/') { + f = f.split(path.sep).join('/') + } + + // treat the test path as a set of pathparts. + f = f.split(slashSplit) + this.debug(this.pattern, 'split', f) + + // just ONE of the pattern sets in this.set needs to match + // in order for it to be valid. If negating, then just one + // match means that we have failed. + // Either way, return on the first hit. - if (!Array.isArray(self.ignore)) - self.ignore = [self.ignore] + var set = this.set + this.debug(this.pattern, 'set', set) - if (self.ignore.length) { - self.ignore = self.ignore.map(ignoreMap) + // Find the basename of the path by looking for the last non-empty segment + var filename + var i + for (i = f.length - 1; i >= 0; i--) { + filename = f[i] + if (filename) break } -} -// ignore patterns are always in dot:true mode. -function ignoreMap (pattern) { - var gmatcher = null - if (pattern.slice(-3) === '/**') { - var gpattern = pattern.replace(/(\/\*\*)+$/, '') - gmatcher = new Minimatch(gpattern, { dot: true }) + for (i = 0; i < set.length; i++) { + var pattern = set[i] + var file = f + if (options.matchBase && pattern.length === 1) { + file = [filename] + } + var hit = this.matchOne(file, pattern, partial) + if (hit) { + if (options.flipNegate) return true + return !this.negate + } } - return { - matcher: new Minimatch(pattern, { dot: true }), - gmatcher: gmatcher - } + // didn't get any hits. this is success if it's a negative + // pattern, failure otherwise. + if (options.flipNegate) return false + return this.negate } -function setopts (self, pattern, options) { - if (!options) - options = {} +// set partial to true to test if, for example, +// "/a/b" matches the start of "/*/b/*/d" +// Partial means, if you run out of file before you run +// out of pattern, then that's fine, as long as all +// the parts match. +Minimatch.prototype.matchOne = function (file, pattern, partial) { + var options = this.options - // base-matching: just use globstar for that. - if (options.matchBase && -1 === pattern.indexOf("/")) { - if (options.noglobstar) { - throw new Error("base matching requires globstar") - } - pattern = "**/" + pattern - } + this.debug('matchOne', + { 'this': this, file: file, pattern: pattern }) - self.silent = !!options.silent - self.pattern = pattern - self.strict = options.strict !== false - self.realpath = !!options.realpath - self.realpathCache = options.realpathCache || Object.create(null) - self.follow = !!options.follow - self.dot = !!options.dot - self.mark = !!options.mark - self.nodir = !!options.nodir - if (self.nodir) - self.mark = true - self.sync = !!options.sync - self.nounique = !!options.nounique - self.nonull = !!options.nonull - self.nosort = !!options.nosort - self.nocase = !!options.nocase - self.stat = !!options.stat - self.noprocess = !!options.noprocess - self.absolute = !!options.absolute + this.debug('matchOne', file.length, pattern.length) - self.maxLength = options.maxLength || Infinity - self.cache = options.cache || Object.create(null) - self.statCache = options.statCache || Object.create(null) - self.symlinks = options.symlinks || Object.create(null) + for (var fi = 0, + pi = 0, + fl = file.length, + pl = pattern.length + ; (fi < fl) && (pi < pl) + ; fi++, pi++) { + this.debug('matchOne loop') + var p = pattern[pi] + var f = file[fi] - setupIgnores(self, options) + this.debug(pattern, p, f) - self.changedCwd = false - var cwd = process.cwd() - if (!ownProp(options, "cwd")) - self.cwd = cwd - else { - self.cwd = path.resolve(options.cwd) - self.changedCwd = self.cwd !== cwd - } + // should be impossible. + // some invalid regexp stuff in the set. + if (p === false) return false - self.root = options.root || path.resolve(self.cwd, "/") - self.root = path.resolve(self.root) - if (process.platform === "win32") - self.root = self.root.replace(/\\/g, "/") + if (p === GLOBSTAR) { + this.debug('GLOBSTAR', [pattern, p, f]) - // TODO: is an absolute `cwd` supposed to be resolved against `root`? - // e.g. { cwd: '/test', root: __dirname } === path.join(__dirname, '/test') - self.cwdAbs = isAbsolute(self.cwd) ? self.cwd : makeAbs(self, self.cwd) - if (process.platform === "win32") - self.cwdAbs = self.cwdAbs.replace(/\\/g, "/") - self.nomount = !!options.nomount + // "**" + // a/**/b/**/c would match the following: + // a/b/x/y/z/c + // a/x/y/z/b/c + // a/b/x/b/x/c + // a/b/c + // To do this, take the rest of the pattern after + // the **, and see if it would match the file remainder. + // If so, return success. + // If not, the ** "swallows" a segment, and try again. + // This is recursively awful. + // + // a/**/b/**/c matching a/b/x/y/z/c + // - a matches a + // - doublestar + // - matchOne(b/x/y/z/c, b/**/c) + // - b matches b + // - doublestar + // - matchOne(x/y/z/c, c) -> no + // - matchOne(y/z/c, c) -> no + // - matchOne(z/c, c) -> no + // - matchOne(c, c) yes, hit + var fr = fi + var pr = pi + 1 + if (pr === pl) { + this.debug('** at the end') + // a ** at the end will just swallow the rest. + // We have found a match. + // however, it will not swallow /.x, unless + // options.dot is set. + // . and .. are *never* matched by **, for explosively + // exponential reasons. + for (; fi < fl; fi++) { + if (file[fi] === '.' || file[fi] === '..' || + (!options.dot && file[fi].charAt(0) === '.')) return false + } + return true + } - // disable comments and negation in Minimatch. - // Note that they are not supported in Glob itself anyway. - options.nonegate = true - options.nocomment = true + // ok, let's see if we can swallow whatever we can. + while (fr < fl) { + var swallowee = file[fr] - self.minimatch = new Minimatch(pattern, options) - self.options = self.minimatch.options -} + this.debug('\nglobstar while', file, fr, pattern, pr, swallowee) -function finish (self) { - var nou = self.nounique - var all = nou ? [] : Object.create(null) + // XXX remove this slice. Just pass the start index. + if (this.matchOne(file.slice(fr), pattern.slice(pr), partial)) { + this.debug('globstar found match!', fr, fl, swallowee) + // found a match. + return true + } else { + // can't swallow "." or ".." ever. + // can only swallow ".foo" when explicitly asked. + if (swallowee === '.' || swallowee === '..' || + (!options.dot && swallowee.charAt(0) === '.')) { + this.debug('dot detected!', file, fr, pattern, pr) + break + } - for (var i = 0, l = self.matches.length; i < l; i ++) { - var matches = self.matches[i] - if (!matches || Object.keys(matches).length === 0) { - if (self.nonull) { - // do like the shell, and spit out the literal glob - var literal = self.minimatch.globSet[i] - if (nou) - all.push(literal) - else - all[literal] = true + // ** swallows a segment, and continue. + this.debug('globstar swallow a segment, and continue') + fr++ + } + } + + // no match was found. + // However, in partial mode, we can't say this is necessarily over. + // If there's more *pattern* left, then + if (partial) { + // ran out of file + this.debug('\n>>> no match, partial?', file, fr, pattern, pr) + if (fr === fl) return true + } + return false + } + + // something other than ** + // non-magic patterns just have to match exactly + // patterns with magic have been turned into regexps. + var hit + if (typeof p === 'string') { + if (options.nocase) { + hit = f.toLowerCase() === p.toLowerCase() + } else { + hit = f === p } + this.debug('string match', p, f, hit) } else { - // had matches - var m = Object.keys(matches) - if (nou) - all.push.apply(all, m) - else - m.forEach(function (m) { - all[m] = true - }) + hit = f.match(p) + this.debug('pattern match', p, f, hit) } + + if (!hit) return false + } + + // Note: ending in / means that we'll get a final "" + // at the end of the pattern. This can only match a + // corresponding "" at the end of the file. + // If the file ends in /, then it can only match a + // a pattern that ends in /, unless the pattern just + // doesn't have any more for it. But, a/b/ should *not* + // match "a/b/*", even though "" matches against the + // [^/]*? pattern, except in partial mode, where it might + // simply not be reached yet. + // However, a/b/ should still satisfy a/* + + // now either we fell off the end of the pattern, or we're done. + if (fi === fl && pi === pl) { + // ran out of pattern and filename at the same time. + // an exact hit! + return true + } else if (fi === fl) { + // ran out of file, but still had pattern left. + // this is ok if we're doing the match as part of + // a glob fs traversal. + return partial + } else if (pi === pl) { + // ran out of pattern, still have file left. + // this is only acceptable if we're on the very last + // empty segment of a file with a trailing slash. + // a/* should match a/b/ + var emptyFileEnd = (fi === fl - 1) && (file[fi] === '') + return emptyFileEnd } - if (!nou) - all = Object.keys(all) + // should be unreachable. + throw new Error('wtf?') +} - if (!self.nosort) - all = all.sort(self.nocase ? alphasorti : alphasort) +// replace stuff like \* with * +function globUnescape (s) { + return s.replace(/\\(.)/g, '$1') +} - // at *some* point we statted all of these - if (self.mark) { - for (var i = 0; i < all.length; i++) { - all[i] = self._mark(all[i]) - } - if (self.nodir) { - all = all.filter(function (e) { - var notDir = !(/\/$/.test(e)) - var c = self.cache[e] || self.cache[makeAbs(self, e)] - if (notDir && c) - notDir = c !== 'DIR' && !Array.isArray(c) - return notDir - }) - } - } +function regExpEscape (s) { + return s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&') +} - if (self.ignore.length) - all = all.filter(function(m) { - return !isIgnored(self, m) - }) - self.found = all -} +/***/ }), +/* 87 */ +/***/ (function(module, exports, __webpack_require__) { -function mark (self, p) { - var abs = makeAbs(self, p) - var c = self.cache[abs] - var m = p - if (c) { - var isDir = c === 'DIR' || Array.isArray(c) - var slash = p.slice(-1) === '/' +"use strict"; - if (isDir && !slash) - m += '/' - else if (!isDir && slash) - m = m.slice(0, -1) - if (m !== p) { - var mabs = makeAbs(self, m) - self.statCache[mabs] = self.statCache[abs] - self.cache[mabs] = self.cache[abs] - } - } +function posix(path) { + return path.charAt(0) === '/'; +} - return m +function win32(path) { + // https://github.com/nodejs/node/blob/b3fcc245fb25539909ef1d5eaa01dbf92e168633/lib/path.js#L56 + var splitDeviceRe = /^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/; + var result = splitDeviceRe.exec(path); + var device = result[1] || ''; + var isUnc = Boolean(device && device.charAt(1) !== ':'); + + // UNC paths are always absolute + return Boolean(result[2] || isUnc); } -// lotta situps... -function makeAbs (self, f) { - var abs = f - if (f.charAt(0) === '/') { - abs = path.join(self.root, f) - } else if (isAbsolute(f) || f === '') { - abs = f - } else if (self.changedCwd) { - abs = path.resolve(self.cwd, f) - } else { - abs = path.resolve(f) - } +module.exports = process.platform === 'win32' ? win32 : posix; +module.exports.posix = posix; +module.exports.win32 = win32; - if (process.platform === 'win32') - abs = abs.replace(/\\/g, '/') - return abs +/***/ }), +/* 88 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +/* + * 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. + */ +class CliError extends Error { + constructor(message, meta = {}) { + super(message); + this.meta = meta; + } } +exports.CliError = CliError; +/***/ }), +/* 89 */ +/***/ (function(module, exports, __webpack_require__) { -// Return true, if pattern ends with globstar '**', for the accompanying parent directory. -// Ex:- If node_modules/** is the pattern, add 'node_modules' to ignore list along with it's contents -function isIgnored (self, path) { - if (!self.ignore.length) - return false +// Note: since nyc uses this module to output coverage, any lines +// that are in the direct sync flow of nyc's outputCoverage are +// ignored, since we can never get coverage for them. +var assert = __webpack_require__(57) +var signals = __webpack_require__(170) - return self.ignore.some(function(item) { - return item.matcher.match(path) || !!(item.gmatcher && item.gmatcher.match(path)) - }) +var EE = __webpack_require__(61) +/* istanbul ignore if */ +if (typeof EE !== 'function') { + EE = EE.EventEmitter } -function childrenIgnored (self, path) { - if (!self.ignore.length) - return false +var emitter +if (process.__signal_exit_emitter__) { + emitter = process.__signal_exit_emitter__ +} else { + emitter = process.__signal_exit_emitter__ = new EE() + emitter.count = 0 + emitter.emitted = {} +} - return self.ignore.some(function(item) { - return !!(item.gmatcher && item.gmatcher.match(path)) - }) +// Because this emitter is a global, we have to check to see if a +// previous version of this library failed to enable infinite listeners. +// I know what you're about to say. But literally everything about +// signal-exit is a compromise with evil. Get used to it. +if (!emitter.infinite) { + emitter.setMaxListeners(Infinity) + emitter.infinite = true } +module.exports = function (cb, opts) { + assert.equal(typeof cb, 'function', 'a callback must be provided for exit handler') -/***/ }), -/* 84 */ -/***/ (function(module, exports) { + if (loaded === false) { + load() + } -// Returns a wrapper function that returns a wrapped callback -// The wrapper function should do some stuff, and return a -// presumably different callback function. -// This makes sure that own properties are retained, so that -// decorations and such are not lost along the way. -module.exports = wrappy -function wrappy (fn, cb) { - if (fn && cb) return wrappy(fn)(cb) + var ev = 'exit' + if (opts && opts.alwaysLast) { + ev = 'afterexit' + } - if (typeof fn !== 'function') - throw new TypeError('need wrapper function') + var remove = function () { + emitter.removeListener(ev, cb) + if (emitter.listeners('exit').length === 0 && + emitter.listeners('afterexit').length === 0) { + unload() + } + } + emitter.on(ev, cb) - Object.keys(fn).forEach(function (k) { - wrapper[k] = fn[k] + return remove +} + +module.exports.unload = unload +function unload () { + if (!loaded) { + return + } + loaded = false + + signals.forEach(function (sig) { + try { + process.removeListener(sig, sigListeners[sig]) + } catch (er) {} }) + process.emit = originalProcessEmit + process.reallyExit = originalProcessReallyExit + emitter.count -= 1 +} - return wrapper +function emit (event, code, signal) { + if (emitter.emitted[event]) { + return + } + emitter.emitted[event] = true + emitter.emit(event, code, signal) +} - function wrapper() { - var args = new Array(arguments.length) - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i] - } - var ret = fn.apply(this, args) - var cb = args[args.length-1] - if (typeof ret === 'function' && ret !== cb) { - Object.keys(cb).forEach(function (k) { - ret[k] = cb[k] - }) +// { : , ... } +var sigListeners = {} +signals.forEach(function (sig) { + sigListeners[sig] = function listener () { + // If there are no other listeners, an exit is coming! + // Simplest way: remove us and then re-send the signal. + // We know that this will kill the process, so we can + // safely emit now. + var listeners = process.listeners(sig) + if (listeners.length === emitter.count) { + unload() + emit('exit', null, sig) + /* istanbul ignore next */ + emit('afterexit', null, sig) + /* istanbul ignore next */ + process.kill(process.pid, sig) } - return ret } +}) + +module.exports.signals = function () { + return signals } +module.exports.load = load + +var loaded = false -/***/ }), -/* 85 */ -/***/ (function(module, exports, __webpack_require__) { +function load () { + if (loaded) { + return + } + loaded = true -var wrappy = __webpack_require__(84) -module.exports = wrappy(once) -module.exports.strict = wrappy(onceStrict) + // This is the number of onSignalExit's that are in play. + // It's important so that we can count the correct number of + // listeners on signals, and don't wait for the other one to + // handle it instead of us. + emitter.count += 1 -once.proto = once(function () { - Object.defineProperty(Function.prototype, 'once', { - value: function () { - return once(this) - }, - configurable: true + signals = signals.filter(function (sig) { + try { + process.on(sig, sigListeners[sig]) + return true + } catch (er) { + return false + } }) - Object.defineProperty(Function.prototype, 'onceStrict', { - value: function () { - return onceStrict(this) - }, - configurable: true - }) -}) + process.emit = processEmit + process.reallyExit = processReallyExit +} -function once (fn) { - var f = function () { - if (f.called) return f.value - f.called = true - return f.value = fn.apply(this, arguments) - } - f.called = false - return f +var originalProcessReallyExit = process.reallyExit +function processReallyExit (code) { + process.exitCode = code || 0 + emit('exit', process.exitCode, null) + /* istanbul ignore next */ + emit('afterexit', process.exitCode, null) + /* istanbul ignore next */ + originalProcessReallyExit.call(process, process.exitCode) } -function onceStrict (fn) { - var f = function () { - if (f.called) - throw new Error(f.onceError) - f.called = true - return f.value = fn.apply(this, arguments) +var originalProcessEmit = process.emit +function processEmit (ev, arg) { + if (ev === 'exit') { + if (arg !== undefined) { + process.exitCode = arg + } + var ret = originalProcessEmit.apply(this, arguments) + emit('exit', process.exitCode, null) + /* istanbul ignore next */ + emit('afterexit', process.exitCode, null) + return ret + } else { + return originalProcessEmit.apply(this, arguments) } - var name = fn.name || 'Function wrapped with `once`' - f.onceError = name + " shouldn't be called more than once" - f.called = false - return f } /***/ }), -/* 86 */ +/* 90 */ +/***/ (function(module, exports) { + +module.exports = require("child_process"); + +/***/ }), +/* 91 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -7795,1198 +7404,1139 @@ function onceStrict (fn) { Object.defineProperty(exports, "__esModule", { value: true }); -exports.Project = undefined; - -var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; /* - * 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. - */ - - -var _chalk = __webpack_require__(17); - -var _chalk2 = _interopRequireDefault(_chalk); - -var _path = __webpack_require__(2); - -var _util = __webpack_require__(8); - -var _errors = __webpack_require__(57); - -var _log = __webpack_require__(19); - -var _package_json = __webpack_require__(41); - -var _scripts = __webpack_require__(194); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } +exports.getProjectPaths = getProjectPaths; -class Project { - constructor(packageJson, projectPath) { - this.isWorkspaceRoot = false; - this.isWorkspaceProject = false; - this.json = Object.freeze(packageJson); - this.path = projectPath; - this.packageJsonLocation = (0, _path.resolve)(this.path, 'package.json'); - this.nodeModulesLocation = (0, _path.resolve)(this.path, 'node_modules'); - this.targetLocation = (0, _path.resolve)(this.path, 'target'); - this.productionDependencies = this.json.dependencies || {}; - this.devDependencies = this.json.devDependencies || {}; - this.allDependencies = _extends({}, this.devDependencies, this.productionDependencies); - this.isWorkspaceRoot = this.json.hasOwnProperty('workspaces'); - this.scripts = this.json.scripts || {}; - } - static fromPath(path) { - return _asyncToGenerator(function* () { - const pkgJson = yield (0, _package_json.readPackageJson)(path); - return new Project(pkgJson, path); - })(); - } - get name() { - return this.json.name; - } - ensureValidProjectDependency(project, dependentProjectIsInWorkspace) { - const versionInPackageJson = this.allDependencies[project.name]; - let expectedVersionInPackageJson; - if (dependentProjectIsInWorkspace) { - expectedVersionInPackageJson = project.json.version; - } else { - const relativePathToProject = normalizePath((0, _path.relative)(this.path, project.path)); - expectedVersionInPackageJson = `link:${relativePathToProject}`; - } - // No issues! - if (versionInPackageJson === expectedVersionInPackageJson) { - return; - } - let problemMsg; - if ((0, _package_json.isLinkDependency)(versionInPackageJson) && dependentProjectIsInWorkspace) { - problemMsg = `but should be using a workspace`; - } else if ((0, _package_json.isLinkDependency)(versionInPackageJson)) { - problemMsg = `using 'link:', but the path is wrong`; - } else { - problemMsg = `but it's not using the local package`; - } - throw new _errors.CliError(`[${this.name}] depends on [${project.name}] ${problemMsg}. Update its package.json to the expected value below.`, { - actual: `"${project.name}": "${versionInPackageJson}"`, - expected: `"${project.name}": "${expectedVersionInPackageJson}"`, - package: `${this.name} (${this.packageJsonLocation})` - }); - } - getBuildConfig() { - return this.json.kibana && this.json.kibana.build || {}; - } - /** - * Returns the directory that should be copied into the Kibana build artifact. - * This config can be specified to only include the project's build artifacts - * instead of everything located in the project directory. - */ - getIntermediateBuildDirectory() { - return (0, _path.resolve)(this.path, this.getBuildConfig().intermediateBuildDirectory || '.'); - } - getCleanConfig() { - return this.json.kibana && this.json.kibana.clean || {}; - } - hasScript(name) { - return name in this.scripts; - } - getExecutables() { - const raw = this.json.bin; - if (!raw) { - return {}; - } - if (typeof raw === 'string') { - return { - [this.name]: (0, _path.resolve)(this.path, raw) - }; - } - if (typeof raw === 'object') { - const binsConfig = {}; - for (const binName of Object.keys(raw)) { - binsConfig[binName] = (0, _path.resolve)(this.path, raw[binName]); - } - return binsConfig; - } - throw new _errors.CliError(`[${this.name}] has an invalid "bin" field in its package.json, ` + `expected an object or a string`, { - binConfig: (0, _util.inspect)(raw), - package: `${this.name} (${this.packageJsonLocation})` - }); - } - runScript(scriptName, args = []) { - var _this = this; +var _path = __webpack_require__(7); - return _asyncToGenerator(function* () { - _log.log.write(_chalk2.default.bold(`\n\nRunning script [${_chalk2.default.green(scriptName)}] in [${_chalk2.default.green(_this.name)}]:\n`)); - return (0, _scripts.runScriptInPackage)(scriptName, args, _this); - })(); - } - runScriptStreaming(scriptName, args = []) { - return (0, _scripts.runScriptInPackageStreaming)(scriptName, args, this); +/** + * Returns all the paths where plugins are located + */ +function getProjectPaths(rootPath, options) { + const skipKibanaExtra = Boolean(options['skip-kibana-extra']); + const ossOnly = Boolean(options.oss); + const projectPaths = [rootPath, (0, _path.resolve)(rootPath, 'packages/*')]; + // This is needed in order to install the dependencies for the declared + // plugin functional used in the selenium functional tests. + // As we are now using the webpack dll for the client vendors dependencies + // when we run the plugin functional tests against the distributable + // dependencies used by such plugins like @eui, react and react-dom can't + // be loaded from the dll as the context is different from the one declared + // into the webpack dll reference plugin. + // In anyway, have a plugin declaring their own dependencies is the + // correct and the expect behavior. + projectPaths.push((0, _path.resolve)(rootPath, 'test/plugin_functional/plugins/*')); + if (!ossOnly) { + projectPaths.push((0, _path.resolve)(rootPath, 'x-pack')); + projectPaths.push((0, _path.resolve)(rootPath, 'x-pack/plugins/*')); } - hasDependencies() { - return Object.keys(this.allDependencies).length > 0; + if (!skipKibanaExtra) { + projectPaths.push((0, _path.resolve)(rootPath, '../kibana-extra/*')); + projectPaths.push((0, _path.resolve)(rootPath, '../kibana-extra/*/packages/*')); + projectPaths.push((0, _path.resolve)(rootPath, '../kibana-extra/*/plugins/*')); } - installDependencies({ extraArgs }) { - var _this2 = this; + return projectPaths; +} /* + * 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. + */ - return _asyncToGenerator(function* () { - _log.log.write(_chalk2.default.bold(`\n\nInstalling dependencies in [${_chalk2.default.green(_this2.name)}]:\n`)); - return (0, _scripts.installInDir)(_this2.path, extraArgs); - })(); - } +/***/ }), +/* 92 */ +/***/ (function(module, exports, __webpack_require__) { + +/* MIT license */ +var cssKeywords = __webpack_require__(122); + +// NOTE: conversions should only return primitive values (i.e. arrays, or +// values that give correct `typeof` results). +// do not use box values types (i.e. Number(), String(), etc.) + +var reverseKeywords = {}; +for (var key in cssKeywords) { + if (cssKeywords.hasOwnProperty(key)) { + reverseKeywords[cssKeywords[key]] = key; + } } -exports.Project = Project; // We normalize all path separators to `/` in generated files -function normalizePath(path) { - return path.replace(/[\\\/]+/g, '/'); +var convert = module.exports = { + rgb: {channels: 3, labels: 'rgb'}, + hsl: {channels: 3, labels: 'hsl'}, + hsv: {channels: 3, labels: 'hsv'}, + hwb: {channels: 3, labels: 'hwb'}, + cmyk: {channels: 4, labels: 'cmyk'}, + xyz: {channels: 3, labels: 'xyz'}, + lab: {channels: 3, labels: 'lab'}, + lch: {channels: 3, labels: 'lch'}, + hex: {channels: 1, labels: ['hex']}, + keyword: {channels: 1, labels: ['keyword']}, + ansi16: {channels: 1, labels: ['ansi16']}, + ansi256: {channels: 1, labels: ['ansi256']}, + hcg: {channels: 3, labels: ['h', 'c', 'g']}, + apple: {channels: 3, labels: ['r16', 'g16', 'b16']}, + gray: {channels: 1, labels: ['gray']} +}; + +// hide .channels and .labels properties +for (var model in convert) { + if (convert.hasOwnProperty(model)) { + if (!('channels' in convert[model])) { + throw new Error('missing channels property: ' + model); + } + + if (!('labels' in convert[model])) { + throw new Error('missing channel labels property: ' + model); + } + + if (convert[model].labels.length !== convert[model].channels) { + throw new Error('channel and label counts mismatch: ' + model); + } + + var channels = convert[model].channels; + var labels = convert[model].labels; + delete convert[model].channels; + delete convert[model].labels; + Object.defineProperty(convert[model], 'channels', {value: channels}); + Object.defineProperty(convert[model], 'labels', {value: labels}); + } } -/***/ }), -/* 87 */ -/***/ (function(module, exports, __webpack_require__) { +convert.rgb.hsl = function (rgb) { + var r = rgb[0] / 255; + var g = rgb[1] / 255; + var b = rgb[2] / 255; + var min = Math.min(r, g, b); + var max = Math.max(r, g, b); + var delta = max - min; + var h; + var s; + var l; -module.exports = normalize + if (max === min) { + h = 0; + } else if (r === max) { + h = (g - b) / delta; + } else if (g === max) { + h = 2 + (b - r) / delta; + } else if (b === max) { + h = 4 + (r - g) / delta; + } -var fixer = __webpack_require__(170) -normalize.fixer = fixer + h = Math.min(h * 60, 360); -var makeWarning = __webpack_require__(183) + if (h < 0) { + h += 360; + } -var fieldsToFix = ['name','version','description','repository','modules','scripts' - ,'files','bin','man','bugs','keywords','readme','homepage','license'] -var otherThingsToFix = ['dependencies','people', 'typos'] + l = (min + max) / 2; -var thingsToFix = fieldsToFix.map(function(fieldName) { - return ucFirst(fieldName) + "Field" -}) -// two ways to do this in CoffeeScript on only one line, sub-70 chars: -// thingsToFix = fieldsToFix.map (name) -> ucFirst(name) + "Field" -// thingsToFix = (ucFirst(name) + "Field" for name in fieldsToFix) -thingsToFix = thingsToFix.concat(otherThingsToFix) + if (max === min) { + s = 0; + } else if (l <= 0.5) { + s = delta / (max + min); + } else { + s = delta / (2 - max - min); + } -function normalize (data, warn, strict) { - if(warn === true) warn = null, strict = true - if(!strict) strict = false - if(!warn || data.private) warn = function(msg) { /* noop */ } + return [h, s * 100, l * 100]; +}; - if (data.scripts && - data.scripts.install === "node-gyp rebuild" && - !data.scripts.preinstall) { - data.gypfile = true - } - fixer.warn = function() { warn(makeWarning.apply(null, arguments)) } - thingsToFix.forEach(function(thingName) { - fixer["fix" + ucFirst(thingName)](data, strict) - }) - data._id = data.name + "@" + data.version -} +convert.rgb.hsv = function (rgb) { + var r = rgb[0]; + var g = rgb[1]; + var b = rgb[2]; + var min = Math.min(r, g, b); + var max = Math.max(r, g, b); + var delta = max - min; + var h; + var s; + var v; -function ucFirst (string) { - return string.charAt(0).toUpperCase() + string.slice(1); -} + if (max === 0) { + s = 0; + } else { + s = (delta / max * 1000) / 10; + } + if (max === min) { + h = 0; + } else if (r === max) { + h = (g - b) / delta; + } else if (g === max) { + h = 2 + (b - r) / delta; + } else if (b === max) { + h = 4 + (r - g) / delta; + } -/***/ }), -/* 88 */ -/***/ (function(module, exports) { + h = Math.min(h * 60, 360); -module.exports = require("url"); + if (h < 0) { + h += 360; + } -/***/ }), -/* 89 */ -/***/ (function(module, exports, __webpack_require__) { + v = ((max / 255) * 1000) / 10; -"use strict"; + return [h, s, v]; +}; +convert.rgb.hwb = function (rgb) { + var r = rgb[0]; + var g = rgb[1]; + var b = rgb[2]; + var h = convert.rgb.hsl(rgb)[0]; + var w = 1 / 255 * Math.min(r, Math.min(g, b)); -var gitHosts = module.exports = { - github: { - // First two are insecure and generally shouldn't be used any more, but - // they are still supported. - 'protocols': [ 'git', 'http', 'git+ssh', 'git+https', 'ssh', 'https' ], - 'domain': 'github.com', - 'treepath': 'tree', - 'filetemplate': 'https://{auth@}raw.githubusercontent.com/{user}/{project}/{committish}/{path}', - 'bugstemplate': 'https://{domain}/{user}/{project}/issues', - 'gittemplate': 'git://{auth@}{domain}/{user}/{project}.git{#committish}', - 'tarballtemplate': 'https://{domain}/{user}/{project}/archive/{committish}.tar.gz' - }, - bitbucket: { - 'protocols': [ 'git+ssh', 'git+https', 'ssh', 'https' ], - 'domain': 'bitbucket.org', - 'treepath': 'src', - 'tarballtemplate': 'https://{domain}/{user}/{project}/get/{committish}.tar.gz' - }, - gitlab: { - 'protocols': [ 'git+ssh', 'git+https', 'ssh', 'https' ], - 'domain': 'gitlab.com', - 'treepath': 'tree', - 'docstemplate': 'https://{domain}/{user}/{project}{/tree/committish}#README', - 'bugstemplate': 'https://{domain}/{user}/{project}/issues', - 'tarballtemplate': 'https://{domain}/{user}/{project}/repository/archive.tar.gz?ref={committish}' - }, - gist: { - 'protocols': [ 'git', 'git+ssh', 'git+https', 'ssh', 'https' ], - 'domain': 'gist.github.com', - 'pathmatch': /^[/](?:([^/]+)[/])?([a-z0-9]+)(?:[.]git)?$/, - 'filetemplate': 'https://gist.githubusercontent.com/{user}/{project}/raw{/committish}/{path}', - 'bugstemplate': 'https://{domain}/{project}', - 'gittemplate': 'git://{domain}/{project}.git{#committish}', - 'sshtemplate': 'git@{domain}:/{project}.git{#committish}', - 'sshurltemplate': 'git+ssh://git@{domain}/{project}.git{#committish}', - 'browsetemplate': 'https://{domain}/{project}{/committish}', - 'docstemplate': 'https://{domain}/{project}{/committish}', - 'httpstemplate': 'git+https://{domain}/{project}.git{#committish}', - 'shortcuttemplate': '{type}:{project}{#committish}', - 'pathtemplate': '{project}{#committish}', - 'tarballtemplate': 'https://{domain}/{user}/{project}/archive/{committish}.tar.gz' - } -} + b = 1 - 1 / 255 * Math.max(r, Math.max(g, b)); -var gitHostDefaults = { - 'sshtemplate': 'git@{domain}:{user}/{project}.git{#committish}', - 'sshurltemplate': 'git+ssh://git@{domain}/{user}/{project}.git{#committish}', - 'browsetemplate': 'https://{domain}/{user}/{project}{/tree/committish}', - 'docstemplate': 'https://{domain}/{user}/{project}{/tree/committish}#readme', - 'httpstemplate': 'git+https://{auth@}{domain}/{user}/{project}.git{#committish}', - 'filetemplate': 'https://{domain}/{user}/{project}/raw/{committish}/{path}', - 'shortcuttemplate': '{type}:{user}/{project}{#committish}', - 'pathtemplate': '{user}/{project}{#committish}', - 'pathmatch': /^[/]([^/]+)[/]([^/]+?)(?:[.]git|[/])?$/ + return [h, w * 100, b * 100]; +}; + +convert.rgb.cmyk = function (rgb) { + var r = rgb[0] / 255; + var g = rgb[1] / 255; + var b = rgb[2] / 255; + var c; + var m; + var y; + var k; + + k = Math.min(1 - r, 1 - g, 1 - b); + c = (1 - r - k) / (1 - k) || 0; + m = (1 - g - k) / (1 - k) || 0; + y = (1 - b - k) / (1 - k) || 0; + + return [c * 100, m * 100, y * 100, k * 100]; +}; + +/** + * See https://en.m.wikipedia.org/wiki/Euclidean_distance#Squared_Euclidean_distance + * */ +function comparativeDistance(x, y) { + return ( + Math.pow(x[0] - y[0], 2) + + Math.pow(x[1] - y[1], 2) + + Math.pow(x[2] - y[2], 2) + ); } -Object.keys(gitHosts).forEach(function (name) { - Object.keys(gitHostDefaults).forEach(function (key) { - if (gitHosts[name][key]) return - gitHosts[name][key] = gitHostDefaults[key] - }) - gitHosts[name].protocols_re = RegExp('^(' + - gitHosts[name].protocols.map(function (protocol) { - return protocol.replace(/([\\+*{}()[\]$^|])/g, '\\$1') - }).join('|') + '):$') -}) - +convert.rgb.keyword = function (rgb) { + var reversed = reverseKeywords[rgb]; + if (reversed) { + return reversed; + } -/***/ }), -/* 90 */ -/***/ (function(module, exports, __webpack_require__) { + var currentClosestDistance = Infinity; + var currentClosestKeyword; -"use strict"; + for (var keyword in cssKeywords) { + if (cssKeywords.hasOwnProperty(keyword)) { + var value = cssKeywords[keyword]; -const isPlainObj = __webpack_require__(190); + // Compute comparative distance + var distance = comparativeDistance(rgb, value); -module.exports = (obj, opts) => { - if (!isPlainObj(obj)) { - throw new TypeError('Expected a plain object'); + // Check if its less, if so set as closest + if (distance < currentClosestDistance) { + currentClosestDistance = distance; + currentClosestKeyword = keyword; + } + } } - opts = opts || {}; + return currentClosestKeyword; +}; - // DEPRECATED - if (typeof opts === 'function') { - throw new TypeError('Specify the compare function as an option instead'); - } +convert.keyword.rgb = function (keyword) { + return cssKeywords[keyword]; +}; - const deep = opts.deep; - const seenInput = []; - const seenOutput = []; +convert.rgb.xyz = function (rgb) { + var r = rgb[0] / 255; + var g = rgb[1] / 255; + var b = rgb[2] / 255; - const sortKeys = x => { - const seenIndex = seenInput.indexOf(x); + // assume sRGB + r = r > 0.04045 ? Math.pow(((r + 0.055) / 1.055), 2.4) : (r / 12.92); + g = g > 0.04045 ? Math.pow(((g + 0.055) / 1.055), 2.4) : (g / 12.92); + b = b > 0.04045 ? Math.pow(((b + 0.055) / 1.055), 2.4) : (b / 12.92); - if (seenIndex !== -1) { - return seenOutput[seenIndex]; - } + var x = (r * 0.4124) + (g * 0.3576) + (b * 0.1805); + var y = (r * 0.2126) + (g * 0.7152) + (b * 0.0722); + var z = (r * 0.0193) + (g * 0.1192) + (b * 0.9505); - const ret = {}; - const keys = Object.keys(x).sort(opts.compare); + return [x * 100, y * 100, z * 100]; +}; - seenInput.push(x); - seenOutput.push(ret); +convert.rgb.lab = function (rgb) { + var xyz = convert.rgb.xyz(rgb); + var x = xyz[0]; + var y = xyz[1]; + var z = xyz[2]; + var l; + var a; + var b; - for (let i = 0; i < keys.length; i++) { - const key = keys[i]; - const val = x[key]; + x /= 95.047; + y /= 100; + z /= 108.883; - if (deep && Array.isArray(val)) { - const retArr = []; + x = x > 0.008856 ? Math.pow(x, 1 / 3) : (7.787 * x) + (16 / 116); + y = y > 0.008856 ? Math.pow(y, 1 / 3) : (7.787 * y) + (16 / 116); + z = z > 0.008856 ? Math.pow(z, 1 / 3) : (7.787 * z) + (16 / 116); - for (let j = 0; j < val.length; j++) { - retArr[j] = isPlainObj(val[j]) ? sortKeys(val[j]) : val[j]; - } + l = (116 * y) - 16; + a = 500 * (x - y); + b = 200 * (y - z); - ret[key] = retArr; - continue; - } + return [l, a, b]; +}; - ret[key] = deep && isPlainObj(val) ? sortKeys(val) : val; - } +convert.hsl.rgb = function (hsl) { + var h = hsl[0] / 360; + var s = hsl[1] / 100; + var l = hsl[2] / 100; + var t1; + var t2; + var t3; + var rgb; + var val; - return ret; - }; + if (s === 0) { + val = l * 255; + return [val, val, val]; + } - return sortKeys(obj); -}; + if (l < 0.5) { + t2 = l * (1 + s); + } else { + t2 = l + s - l * s; + } + + t1 = 2 * l - t2; + rgb = [0, 0, 0]; + for (var i = 0; i < 3; i++) { + t3 = h + 1 / 3 * -(i - 1); + if (t3 < 0) { + t3++; + } + if (t3 > 1) { + t3--; + } -/***/ }), -/* 91 */ -/***/ (function(module, exports, __webpack_require__) { + if (6 * t3 < 1) { + val = t1 + (t2 - t1) * 6 * t3; + } else if (2 * t3 < 1) { + val = t2; + } else if (3 * t3 < 2) { + val = t1 + (t2 - t1) * (2 / 3 - t3) * 6; + } else { + val = t1; + } -"use strict"; + rgb[i] = val * 255; + } -const fs = __webpack_require__(6); -const path = __webpack_require__(2); -const pify = __webpack_require__(191); + return rgb; +}; -const defaults = { - mode: 0o777 & (~process.umask()), - fs +convert.hsl.hsv = function (hsl) { + var h = hsl[0]; + var s = hsl[1] / 100; + var l = hsl[2] / 100; + var smin = s; + var lmin = Math.max(l, 0.01); + var sv; + var v; + + l *= 2; + s *= (l <= 1) ? l : 2 - l; + smin *= lmin <= 1 ? lmin : 2 - lmin; + v = (l + s) / 2; + sv = l === 0 ? (2 * smin) / (lmin + smin) : (2 * s) / (l + s); + + return [h, sv * 100, v * 100]; }; -// https://github.com/nodejs/node/issues/8987 -// https://github.com/libuv/libuv/pull/1088 -const checkPath = pth => { - if (process.platform === 'win32') { - const pathHasInvalidWinCharacters = /[<>:"|?*]/.test(pth.replace(path.parse(pth).root, '')); +convert.hsv.rgb = function (hsv) { + var h = hsv[0] / 60; + var s = hsv[1] / 100; + var v = hsv[2] / 100; + var hi = Math.floor(h) % 6; - if (pathHasInvalidWinCharacters) { - const err = new Error(`Path contains invalid characters: ${pth}`); - err.code = 'EINVAL'; - throw err; - } + var f = h - Math.floor(h); + var p = 255 * v * (1 - s); + var q = 255 * v * (1 - (s * f)); + var t = 255 * v * (1 - (s * (1 - f))); + v *= 255; + + switch (hi) { + case 0: + return [v, t, p]; + case 1: + return [q, v, p]; + case 2: + return [p, v, t]; + case 3: + return [p, q, v]; + case 4: + return [t, p, v]; + case 5: + return [v, p, q]; } }; -module.exports = (input, opts) => Promise.resolve().then(() => { - checkPath(input); - opts = Object.assign({}, defaults, opts); +convert.hsv.hsl = function (hsv) { + var h = hsv[0]; + var s = hsv[1] / 100; + var v = hsv[2] / 100; + var vmin = Math.max(v, 0.01); + var lmin; + var sl; + var l; - const mkdir = pify(opts.fs.mkdir); - const stat = pify(opts.fs.stat); + l = (2 - s) * v; + lmin = (2 - s) * vmin; + sl = s * vmin; + sl /= (lmin <= 1) ? lmin : 2 - lmin; + sl = sl || 0; + l /= 2; - const make = pth => { - return mkdir(pth, opts.mode) - .then(() => pth) - .catch(err => { - if (err.code === 'ENOENT') { - if (err.message.includes('null bytes') || path.dirname(pth) === pth) { - throw err; - } + return [h, sl * 100, l * 100]; +}; - return make(path.dirname(pth)).then(() => make(pth)); - } +// http://dev.w3.org/csswg/css-color/#hwb-to-rgb +convert.hwb.rgb = function (hwb) { + var h = hwb[0] / 360; + var wh = hwb[1] / 100; + var bl = hwb[2] / 100; + var ratio = wh + bl; + var i; + var v; + var f; + var n; - return stat(pth) - .then(stats => stats.isDirectory() ? pth : Promise.reject()) - .catch(() => { - throw err; - }); - }); - }; + // wh + bl cant be > 1 + if (ratio > 1) { + wh /= ratio; + bl /= ratio; + } - return make(path.resolve(input)); -}); + i = Math.floor(6 * h); + v = 1 - bl; + f = 6 * h - i; -module.exports.sync = (input, opts) => { - checkPath(input); - opts = Object.assign({}, defaults, opts); + if ((i & 0x01) !== 0) { + f = 1 - f; + } - const make = pth => { - try { - opts.fs.mkdirSync(pth, opts.mode); - } catch (err) { - if (err.code === 'ENOENT') { - if (err.message.includes('null bytes') || path.dirname(pth) === pth) { - throw err; - } + n = wh + f * (v - wh); // linear interpolation - make(path.dirname(pth)); - return make(pth); - } + var r; + var g; + var b; + switch (i) { + default: + case 6: + case 0: r = v; g = n; b = wh; break; + case 1: r = n; g = v; b = wh; break; + case 2: r = wh; g = v; b = n; break; + case 3: r = wh; g = n; b = v; break; + case 4: r = n; g = wh; b = v; break; + case 5: r = v; g = wh; b = n; break; + } - try { - if (!opts.fs.statSync(pth).isDirectory()) { - throw new Error('The path is not a directory'); - } - } catch (_) { - throw err; - } - } + return [r * 255, g * 255, b * 255]; +}; - return pth; - }; +convert.cmyk.rgb = function (cmyk) { + var c = cmyk[0] / 100; + var m = cmyk[1] / 100; + var y = cmyk[2] / 100; + var k = cmyk[3] / 100; + var r; + var g; + var b; - return make(path.resolve(input)); + r = 1 - Math.min(1, c * (1 - k) + k); + g = 1 - Math.min(1, m * (1 - k) + k); + b = 1 - Math.min(1, y * (1 - k) + k); + + return [r * 255, g * 255, b * 255]; }; +convert.xyz.rgb = function (xyz) { + var x = xyz[0] / 100; + var y = xyz[1] / 100; + var z = xyz[2] / 100; + var r; + var g; + var b; -/***/ }), -/* 92 */ -/***/ (function(module, exports, __webpack_require__) { + r = (x * 3.2406) + (y * -1.5372) + (z * -0.4986); + g = (x * -0.9689) + (y * 1.8758) + (z * 0.0415); + b = (x * 0.0557) + (y * -0.2040) + (z * 1.0570); -"use strict"; + // assume sRGB + r = r > 0.0031308 + ? ((1.055 * Math.pow(r, 1.0 / 2.4)) - 0.055) + : r * 12.92; + g = g > 0.0031308 + ? ((1.055 * Math.pow(g, 1.0 / 2.4)) - 0.055) + : g * 12.92; -var path = __webpack_require__(2); -var which = __webpack_require__(199); -var LRU = __webpack_require__(93); + b = b > 0.0031308 + ? ((1.055 * Math.pow(b, 1.0 / 2.4)) - 0.055) + : b * 12.92; -var commandCache = new LRU({ max: 50, maxAge: 30 * 1000 }); // Cache just for 30sec + r = Math.min(Math.max(0, r), 1); + g = Math.min(Math.max(0, g), 1); + b = Math.min(Math.max(0, b), 1); -function resolveCommand(command, noExtension) { - var resolved; + return [r * 255, g * 255, b * 255]; +}; - noExtension = !!noExtension; - resolved = commandCache.get(command + '!' + noExtension); +convert.xyz.lab = function (xyz) { + var x = xyz[0]; + var y = xyz[1]; + var z = xyz[2]; + var l; + var a; + var b; - // Check if its resolved in the cache - if (commandCache.has(command)) { - return commandCache.get(command); - } + x /= 95.047; + y /= 100; + z /= 108.883; - try { - resolved = !noExtension ? - which.sync(command) : - which.sync(command, { pathExt: path.delimiter + (process.env.PATHEXT || '') }); - } catch (e) { /* empty */ } + x = x > 0.008856 ? Math.pow(x, 1 / 3) : (7.787 * x) + (16 / 116); + y = y > 0.008856 ? Math.pow(y, 1 / 3) : (7.787 * y) + (16 / 116); + z = z > 0.008856 ? Math.pow(z, 1 / 3) : (7.787 * z) + (16 / 116); - commandCache.set(command + '!' + noExtension, resolved); + l = (116 * y) - 16; + a = 500 * (x - y); + b = 200 * (y - z); - return resolved; -} + return [l, a, b]; +}; -module.exports = resolveCommand; +convert.lab.xyz = function (lab) { + var l = lab[0]; + var a = lab[1]; + var b = lab[2]; + var x; + var y; + var z; + y = (l + 16) / 116; + x = a / 500 + y; + z = y - b / 200; -/***/ }), -/* 93 */ -/***/ (function(module, exports, __webpack_require__) { + var y2 = Math.pow(y, 3); + var x2 = Math.pow(x, 3); + var z2 = Math.pow(z, 3); + y = y2 > 0.008856 ? y2 : (y - 16 / 116) / 7.787; + x = x2 > 0.008856 ? x2 : (x - 16 / 116) / 7.787; + z = z2 > 0.008856 ? z2 : (z - 16 / 116) / 7.787; -"use strict"; + x *= 95.047; + y *= 100; + z *= 108.883; + return [x, y, z]; +}; -module.exports = LRUCache +convert.lab.lch = function (lab) { + var l = lab[0]; + var a = lab[1]; + var b = lab[2]; + var hr; + var h; + var c; -// This will be a proper iterable 'Map' in engines that support it, -// or a fakey-fake PseudoMap in older versions. -var Map = __webpack_require__(203) -var util = __webpack_require__(8) + hr = Math.atan2(b, a); + h = hr * 360 / 2 / Math.PI; -// A linked list to keep track of recently-used-ness -var Yallist = __webpack_require__(205) + if (h < 0) { + h += 360; + } -// use symbols if possible, otherwise just _props -var hasSymbol = typeof Symbol === 'function' -var makeSymbol -if (hasSymbol) { - makeSymbol = function (key) { - return Symbol.for(key) - } -} else { - makeSymbol = function (key) { - return '_' + key - } -} + c = Math.sqrt(a * a + b * b); -var MAX = makeSymbol('max') -var LENGTH = makeSymbol('length') -var LENGTH_CALCULATOR = makeSymbol('lengthCalculator') -var ALLOW_STALE = makeSymbol('allowStale') -var MAX_AGE = makeSymbol('maxAge') -var DISPOSE = makeSymbol('dispose') -var NO_DISPOSE_ON_SET = makeSymbol('noDisposeOnSet') -var LRU_LIST = makeSymbol('lruList') -var CACHE = makeSymbol('cache') + return [l, c, h]; +}; -function naiveLength () { return 1 } +convert.lch.lab = function (lch) { + var l = lch[0]; + var c = lch[1]; + var h = lch[2]; + var a; + var b; + var hr; -// lruList is a yallist where the head is the youngest -// item, and the tail is the oldest. the list contains the Hit -// objects as the entries. -// Each Hit object has a reference to its Yallist.Node. This -// never changes. -// -// cache is a Map (or PseudoMap) that matches the keys to -// the Yallist.Node object. -function LRUCache (options) { - if (!(this instanceof LRUCache)) { - return new LRUCache(options) - } + hr = h / 360 * 2 * Math.PI; + a = c * Math.cos(hr); + b = c * Math.sin(hr); - if (typeof options === 'number') { - options = { max: options } - } + return [l, a, b]; +}; - if (!options) { - options = {} - } +convert.rgb.ansi16 = function (args) { + var r = args[0]; + var g = args[1]; + var b = args[2]; + var value = 1 in arguments ? arguments[1] : convert.rgb.hsv(args)[2]; // hsv -> ansi16 optimization - var max = this[MAX] = options.max - // Kind of weird to have a default max of Infinity, but oh well. - if (!max || - !(typeof max === 'number') || - max <= 0) { - this[MAX] = Infinity - } + value = Math.round(value / 50); - var lc = options.length || naiveLength - if (typeof lc !== 'function') { - lc = naiveLength - } - this[LENGTH_CALCULATOR] = lc + if (value === 0) { + return 30; + } - this[ALLOW_STALE] = options.stale || false - this[MAX_AGE] = options.maxAge || 0 - this[DISPOSE] = options.dispose - this[NO_DISPOSE_ON_SET] = options.noDisposeOnSet || false - this.reset() -} + var ansi = 30 + + ((Math.round(b / 255) << 2) + | (Math.round(g / 255) << 1) + | Math.round(r / 255)); -// resize the cache when the max changes. -Object.defineProperty(LRUCache.prototype, 'max', { - set: function (mL) { - if (!mL || !(typeof mL === 'number') || mL <= 0) { - mL = Infinity - } - this[MAX] = mL - trim(this) - }, - get: function () { - return this[MAX] - }, - enumerable: true -}) + if (value === 2) { + ansi += 60; + } -Object.defineProperty(LRUCache.prototype, 'allowStale', { - set: function (allowStale) { - this[ALLOW_STALE] = !!allowStale - }, - get: function () { - return this[ALLOW_STALE] - }, - enumerable: true -}) + return ansi; +}; -Object.defineProperty(LRUCache.prototype, 'maxAge', { - set: function (mA) { - if (!mA || !(typeof mA === 'number') || mA < 0) { - mA = 0 - } - this[MAX_AGE] = mA - trim(this) - }, - get: function () { - return this[MAX_AGE] - }, - enumerable: true -}) +convert.hsv.ansi16 = function (args) { + // optimization here; we already know the value and don't need to get + // it converted for us. + return convert.rgb.ansi16(convert.hsv.rgb(args), args[2]); +}; -// resize the cache when the lengthCalculator changes. -Object.defineProperty(LRUCache.prototype, 'lengthCalculator', { - set: function (lC) { - if (typeof lC !== 'function') { - lC = naiveLength - } - if (lC !== this[LENGTH_CALCULATOR]) { - this[LENGTH_CALCULATOR] = lC - this[LENGTH] = 0 - this[LRU_LIST].forEach(function (hit) { - hit.length = this[LENGTH_CALCULATOR](hit.value, hit.key) - this[LENGTH] += hit.length - }, this) - } - trim(this) - }, - get: function () { return this[LENGTH_CALCULATOR] }, - enumerable: true -}) +convert.rgb.ansi256 = function (args) { + var r = args[0]; + var g = args[1]; + var b = args[2]; -Object.defineProperty(LRUCache.prototype, 'length', { - get: function () { return this[LENGTH] }, - enumerable: true -}) + // we use the extended greyscale palette here, with the exception of + // black and white. normal palette only has 4 greyscale shades. + if (r === g && g === b) { + if (r < 8) { + return 16; + } -Object.defineProperty(LRUCache.prototype, 'itemCount', { - get: function () { return this[LRU_LIST].length }, - enumerable: true -}) + if (r > 248) { + return 231; + } -LRUCache.prototype.rforEach = function (fn, thisp) { - thisp = thisp || this - for (var walker = this[LRU_LIST].tail; walker !== null;) { - var prev = walker.prev - forEachStep(this, fn, walker, thisp) - walker = prev - } -} + return Math.round(((r - 8) / 247) * 24) + 232; + } -function forEachStep (self, fn, node, thisp) { - var hit = node.value - if (isStale(self, hit)) { - del(self, node) - if (!self[ALLOW_STALE]) { - hit = undefined - } - } - if (hit) { - fn.call(thisp, hit.value, hit.key, self) - } -} + var ansi = 16 + + (36 * Math.round(r / 255 * 5)) + + (6 * Math.round(g / 255 * 5)) + + Math.round(b / 255 * 5); -LRUCache.prototype.forEach = function (fn, thisp) { - thisp = thisp || this - for (var walker = this[LRU_LIST].head; walker !== null;) { - var next = walker.next - forEachStep(this, fn, walker, thisp) - walker = next - } -} + return ansi; +}; -LRUCache.prototype.keys = function () { - return this[LRU_LIST].toArray().map(function (k) { - return k.key - }, this) -} +convert.ansi16.rgb = function (args) { + var color = args % 10; -LRUCache.prototype.values = function () { - return this[LRU_LIST].toArray().map(function (k) { - return k.value - }, this) -} + // handle greyscale + if (color === 0 || color === 7) { + if (args > 50) { + color += 3.5; + } -LRUCache.prototype.reset = function () { - if (this[DISPOSE] && - this[LRU_LIST] && - this[LRU_LIST].length) { - this[LRU_LIST].forEach(function (hit) { - this[DISPOSE](hit.key, hit.value) - }, this) - } + color = color / 10.5 * 255; - this[CACHE] = new Map() // hash of items by key - this[LRU_LIST] = new Yallist() // list of items in order of use recency - this[LENGTH] = 0 // length of items in the list -} + return [color, color, color]; + } -LRUCache.prototype.dump = function () { - return this[LRU_LIST].map(function (hit) { - if (!isStale(this, hit)) { - return { - k: hit.key, - v: hit.value, - e: hit.now + (hit.maxAge || 0) - } - } - }, this).toArray().filter(function (h) { - return h - }) -} + var mult = (~~(args > 50) + 1) * 0.5; + var r = ((color & 1) * mult) * 255; + var g = (((color >> 1) & 1) * mult) * 255; + var b = (((color >> 2) & 1) * mult) * 255; -LRUCache.prototype.dumpLru = function () { - return this[LRU_LIST] -} + return [r, g, b]; +}; -LRUCache.prototype.inspect = function (n, opts) { - var str = 'LRUCache {' - var extras = false +convert.ansi256.rgb = function (args) { + // handle greyscale + if (args >= 232) { + var c = (args - 232) * 10 + 8; + return [c, c, c]; + } - var as = this[ALLOW_STALE] - if (as) { - str += '\n allowStale: true' - extras = true - } + args -= 16; - var max = this[MAX] - if (max && max !== Infinity) { - if (extras) { - str += ',' - } - str += '\n max: ' + util.inspect(max, opts) - extras = true - } + var rem; + var r = Math.floor(args / 36) / 5 * 255; + var g = Math.floor((rem = args % 36) / 6) / 5 * 255; + var b = (rem % 6) / 5 * 255; - var maxAge = this[MAX_AGE] - if (maxAge) { - if (extras) { - str += ',' - } - str += '\n maxAge: ' + util.inspect(maxAge, opts) - extras = true - } + return [r, g, b]; +}; - var lc = this[LENGTH_CALCULATOR] - if (lc && lc !== naiveLength) { - if (extras) { - str += ',' - } - str += '\n length: ' + util.inspect(this[LENGTH], opts) - extras = true - } +convert.rgb.hex = function (args) { + var integer = ((Math.round(args[0]) & 0xFF) << 16) + + ((Math.round(args[1]) & 0xFF) << 8) + + (Math.round(args[2]) & 0xFF); - var didFirst = false - this[LRU_LIST].forEach(function (item) { - if (didFirst) { - str += ',\n ' - } else { - if (extras) { - str += ',\n' - } - didFirst = true - str += '\n ' - } - var key = util.inspect(item.key).split('\n').join('\n ') - var val = { value: item.value } - if (item.maxAge !== maxAge) { - val.maxAge = item.maxAge - } - if (lc !== naiveLength) { - val.length = item.length - } - if (isStale(this, item)) { - val.stale = true - } + var string = integer.toString(16).toUpperCase(); + return '000000'.substring(string.length) + string; +}; + +convert.hex.rgb = function (args) { + var match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i); + if (!match) { + return [0, 0, 0]; + } - val = util.inspect(val, opts).split('\n').join('\n ') - str += key + ' => ' + val - }) + var colorString = match[0]; - if (didFirst || extras) { - str += '\n' - } - str += '}' + if (match[0].length === 3) { + colorString = colorString.split('').map(function (char) { + return char + char; + }).join(''); + } - return str -} + var integer = parseInt(colorString, 16); + var r = (integer >> 16) & 0xFF; + var g = (integer >> 8) & 0xFF; + var b = integer & 0xFF; -LRUCache.prototype.set = function (key, value, maxAge) { - maxAge = maxAge || this[MAX_AGE] + return [r, g, b]; +}; - var now = maxAge ? Date.now() : 0 - var len = this[LENGTH_CALCULATOR](value, key) +convert.rgb.hcg = function (rgb) { + var r = rgb[0] / 255; + var g = rgb[1] / 255; + var b = rgb[2] / 255; + var max = Math.max(Math.max(r, g), b); + var min = Math.min(Math.min(r, g), b); + var chroma = (max - min); + var grayscale; + var hue; - if (this[CACHE].has(key)) { - if (len > this[MAX]) { - del(this, this[CACHE].get(key)) - return false - } + if (chroma < 1) { + grayscale = min / (1 - chroma); + } else { + grayscale = 0; + } - var node = this[CACHE].get(key) - var item = node.value + if (chroma <= 0) { + hue = 0; + } else + if (max === r) { + hue = ((g - b) / chroma) % 6; + } else + if (max === g) { + hue = 2 + (b - r) / chroma; + } else { + hue = 4 + (r - g) / chroma + 4; + } - // dispose of the old one before overwriting - // split out into 2 ifs for better coverage tracking - if (this[DISPOSE]) { - if (!this[NO_DISPOSE_ON_SET]) { - this[DISPOSE](key, item.value) - } - } + hue /= 6; + hue %= 1; - item.now = now - item.maxAge = maxAge - item.value = value - this[LENGTH] += len - item.length - item.length = len - this.get(key) - trim(this) - return true - } + return [hue * 360, chroma * 100, grayscale * 100]; +}; - var hit = new Entry(key, value, len, now, maxAge) +convert.hsl.hcg = function (hsl) { + var s = hsl[1] / 100; + var l = hsl[2] / 100; + var c = 1; + var f = 0; - // oversized objects fall out of cache automatically. - if (hit.length > this[MAX]) { - if (this[DISPOSE]) { - this[DISPOSE](key, value) - } - return false - } + if (l < 0.5) { + c = 2.0 * s * l; + } else { + c = 2.0 * s * (1.0 - l); + } - this[LENGTH] += hit.length - this[LRU_LIST].unshift(hit) - this[CACHE].set(key, this[LRU_LIST].head) - trim(this) - return true -} + if (c < 1.0) { + f = (l - 0.5 * c) / (1.0 - c); + } -LRUCache.prototype.has = function (key) { - if (!this[CACHE].has(key)) return false - var hit = this[CACHE].get(key).value - if (isStale(this, hit)) { - return false - } - return true -} + return [hsl[0], c * 100, f * 100]; +}; -LRUCache.prototype.get = function (key) { - return get(this, key, true) -} +convert.hsv.hcg = function (hsv) { + var s = hsv[1] / 100; + var v = hsv[2] / 100; -LRUCache.prototype.peek = function (key) { - return get(this, key, false) -} + var c = s * v; + var f = 0; -LRUCache.prototype.pop = function () { - var node = this[LRU_LIST].tail - if (!node) return null - del(this, node) - return node.value -} + if (c < 1.0) { + f = (v - c) / (1 - c); + } -LRUCache.prototype.del = function (key) { - del(this, this[CACHE].get(key)) -} + return [hsv[0], c * 100, f * 100]; +}; -LRUCache.prototype.load = function (arr) { - // reset the cache - this.reset() +convert.hcg.rgb = function (hcg) { + var h = hcg[0] / 360; + var c = hcg[1] / 100; + var g = hcg[2] / 100; - var now = Date.now() - // A previous serialized cache has the most recent items first - for (var l = arr.length - 1; l >= 0; l--) { - var hit = arr[l] - var expiresAt = hit.e || 0 - if (expiresAt === 0) { - // the item was created without expiration in a non aged cache - this.set(hit.k, hit.v) - } else { - var maxAge = expiresAt - now - // dont add already expired items - if (maxAge > 0) { - this.set(hit.k, hit.v, maxAge) - } - } - } -} + if (c === 0.0) { + return [g * 255, g * 255, g * 255]; + } -LRUCache.prototype.prune = function () { - var self = this - this[CACHE].forEach(function (value, key) { - get(self, key, false) - }) -} + var pure = [0, 0, 0]; + var hi = (h % 1) * 6; + var v = hi % 1; + var w = 1 - v; + var mg = 0; -function get (self, key, doUse) { - var node = self[CACHE].get(key) - if (node) { - var hit = node.value - if (isStale(self, hit)) { - del(self, node) - if (!self[ALLOW_STALE]) hit = undefined - } else { - if (doUse) { - self[LRU_LIST].unshiftNode(node) - } - } - if (hit) hit = hit.value - } - return hit -} + switch (Math.floor(hi)) { + case 0: + pure[0] = 1; pure[1] = v; pure[2] = 0; break; + case 1: + pure[0] = w; pure[1] = 1; pure[2] = 0; break; + case 2: + pure[0] = 0; pure[1] = 1; pure[2] = v; break; + case 3: + pure[0] = 0; pure[1] = w; pure[2] = 1; break; + case 4: + pure[0] = v; pure[1] = 0; pure[2] = 1; break; + default: + pure[0] = 1; pure[1] = 0; pure[2] = w; + } -function isStale (self, hit) { - if (!hit || (!hit.maxAge && !self[MAX_AGE])) { - return false - } - var stale = false - var diff = Date.now() - hit.now - if (hit.maxAge) { - stale = diff > hit.maxAge - } else { - stale = self[MAX_AGE] && (diff > self[MAX_AGE]) - } - return stale -} + mg = (1.0 - c) * g; -function trim (self) { - if (self[LENGTH] > self[MAX]) { - for (var walker = self[LRU_LIST].tail; - self[LENGTH] > self[MAX] && walker !== null;) { - // We know that we're about to delete this one, and also - // what the next least recently used key will be, so just - // go ahead and set it now. - var prev = walker.prev - del(self, walker) - walker = prev - } - } -} + return [ + (c * pure[0] + mg) * 255, + (c * pure[1] + mg) * 255, + (c * pure[2] + mg) * 255 + ]; +}; -function del (self, node) { - if (node) { - var hit = node.value - if (self[DISPOSE]) { - self[DISPOSE](hit.key, hit.value) - } - self[LENGTH] -= hit.length - self[CACHE].delete(hit.key) - self[LRU_LIST].removeNode(node) - } -} +convert.hcg.hsv = function (hcg) { + var c = hcg[1] / 100; + var g = hcg[2] / 100; -// classy, since V8 prefers predictable objects. -function Entry (key, value, length, now, maxAge) { - this.key = key - this.value = value - this.length = length - this.now = now - this.maxAge = maxAge || 0 -} + var v = c + g * (1.0 - c); + var f = 0; + if (v > 0.0) { + f = c / v; + } -/***/ }), -/* 94 */ -/***/ (function(module, exports, __webpack_require__) { + return [hcg[0], f * 100, v * 100]; +}; -"use strict"; +convert.hcg.hsl = function (hcg) { + var c = hcg[1] / 100; + var g = hcg[2] / 100; + var l = g * (1.0 - c) + 0.5 * c; + var s = 0; -function escapeArgument(arg, quote) { - // Convert to string - arg = '' + arg; + if (l > 0.0 && l < 0.5) { + s = c / (2 * l); + } else + if (l >= 0.5 && l < 1.0) { + s = c / (2 * (1 - l)); + } - // If we are not going to quote the argument, - // escape shell metacharacters, including double and single quotes: - if (!quote) { - arg = arg.replace(/([()%!^<>&|;,"'\s])/g, '^$1'); - } else { - // Sequence of backslashes followed by a double quote: - // double up all the backslashes and escape the double quote - arg = arg.replace(/(\\*)"/g, '$1$1\\"'); + return [hcg[0], s * 100, l * 100]; +}; - // Sequence of backslashes followed by the end of the string - // (which will become a double quote later): - // double up all the backslashes - arg = arg.replace(/(\\*)$/, '$1$1'); +convert.hcg.hwb = function (hcg) { + var c = hcg[1] / 100; + var g = hcg[2] / 100; + var v = c + g * (1.0 - c); + return [hcg[0], (v - c) * 100, (1 - v) * 100]; +}; - // All other backslashes occur literally +convert.hwb.hcg = function (hwb) { + var w = hwb[1] / 100; + var b = hwb[2] / 100; + var v = 1 - b; + var c = v - w; + var g = 0; - // Quote the whole thing: - arg = '"' + arg + '"'; - } + if (c < 1) { + g = (v - c) / (1 - c); + } - return arg; -} + return [hwb[0], c * 100, g * 100]; +}; -module.exports = escapeArgument; +convert.apple.rgb = function (apple) { + return [(apple[0] / 65535) * 255, (apple[1] / 65535) * 255, (apple[2] / 65535) * 255]; +}; +convert.rgb.apple = function (rgb) { + return [(rgb[0] / 255) * 65535, (rgb[1] / 255) * 65535, (rgb[2] / 255) * 65535]; +}; -/***/ }), -/* 95 */ -/***/ (function(module, exports, __webpack_require__) { +convert.gray.rgb = function (args) { + return [args[0] / 100 * 255, args[0] / 100 * 255, args[0] / 100 * 255]; +}; -"use strict"; +convert.gray.hsl = convert.gray.hsv = function (args) { + return [0, 0, args[0]]; +}; -const chalk = __webpack_require__(222); +convert.gray.hwb = function (gray) { + return [0, 100, gray[0]]; +}; -const isSupported = process.platform !== 'win32' || process.env.CI || process.env.TERM === 'xterm-256color'; +convert.gray.cmyk = function (gray) { + return [0, 0, 0, gray[0]]; +}; -const main = { - info: chalk.blue('ℹ'), - success: chalk.green('✔'), - warning: chalk.yellow('⚠'), - error: chalk.red('✖') +convert.gray.lab = function (gray) { + return [gray[0], 0, 0]; }; -const fallbacks = { - info: chalk.blue('i'), - success: chalk.green('√'), - warning: chalk.yellow('‼'), - error: chalk.red('×') +convert.gray.hex = function (gray) { + var val = Math.round(gray[0] / 100 * 255) & 0xFF; + var integer = (val << 16) + (val << 8) + val; + + var string = integer.toString(16).toUpperCase(); + return '000000'.substring(string.length) + string; }; -module.exports = isSupported ? main : fallbacks; +convert.rgb.gray = function (rgb) { + var val = (rgb[0] + rgb[1] + rgb[2]) / 3; + return [val / 255 * 100]; +}; /***/ }), -/* 96 */ +/* 93 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -// Copyright IBM Corp. 2014,2018. All Rights Reserved. -// Node module: strong-log-transformer -// This file is licensed under the Apache License 2.0. -// License text available at https://opensource.org/licenses/Apache-2.0 + +module.exports = (flag, argv) => { + argv = argv || process.argv; + const prefix = flag.startsWith('-') ? '' : (flag.length === 1 ? '-' : '--'); + const pos = argv.indexOf(prefix + flag); + const terminatorPos = argv.indexOf('--'); + return pos !== -1 && (terminatorPos === -1 ? true : pos < terminatorPos); +}; +/***/ }), +/* 94 */ +/***/ (function(module, exports, __webpack_require__) { -var stream = __webpack_require__(21); -var util = __webpack_require__(8); -var fs = __webpack_require__(6); +"use strict"; -var byline = __webpack_require__(228); -var through = __webpack_require__(230); -var duplexer = __webpack_require__(231); -module.exports = Logger; +var fs = __webpack_require__(16) -Logger.DEFAULTS = { - format: 'text', - tag: '', - mergeMultiline: false, - timeStamp: false, -}; +module.exports = clone(fs) -var formatters = { - text: textFormatter, - json: jsonFormatter, +function clone (obj) { + if (obj === null || typeof obj !== 'object') + return obj + + if (obj instanceof Object) + var copy = { __proto__: obj.__proto__ } + else + var copy = Object.create(null) + + Object.getOwnPropertyNames(obj).forEach(function (key) { + Object.defineProperty(copy, key, Object.getOwnPropertyDescriptor(obj, key)) + }) + + return copy } -function Logger(options) { - var defaults = JSON.parse(JSON.stringify(Logger.DEFAULTS)); - options = util._extend(defaults, options || {}); - var catcher = new byline.LineStream; - var emitter = catcher; - var transforms = [ - objectifier(), - ]; - if (options.tag) { - transforms.push(staticTagger(options.tag)); - } +/***/ }), +/* 95 */ +/***/ (function(module, exports, __webpack_require__) { - if (options.mergeMultiline) { - transforms.push(lineMerger()); - } +var path = __webpack_require__(7); +var fs = __webpack_require__(16); +var _0777 = parseInt('0777', 8); - // TODO - // if (options.pidStamp) { - // transforms.push(pidStamper(options.pid)); - // } +module.exports = mkdirP.mkdirp = mkdirP.mkdirP = mkdirP; - // TODO - // if (options.workerStamp) { - // transforms.push(workerStamper(options.worker)); - // } +function mkdirP (p, opts, f, made) { + if (typeof opts === 'function') { + f = opts; + opts = {}; + } + else if (!opts || typeof opts !== 'object') { + opts = { mode: opts }; + } + + var mode = opts.mode; + var xfs = opts.fs || fs; + + if (mode === undefined) { + mode = _0777 & (~process.umask()); + } + if (!made) made = null; + + var cb = f || function () {}; + p = path.resolve(p); + + xfs.mkdir(p, mode, function (er) { + if (!er) { + made = made || p; + return cb(null, made); + } + switch (er.code) { + case 'ENOENT': + mkdirP(path.dirname(p), opts, function (er, made) { + if (er) cb(er, made); + else mkdirP(p, opts, cb, made); + }); + break; - transforms.push(formatters[options.format](options)); + // In the case of any other error, just see if there's a dir + // there already. If so, then hooray! If not, then something + // is borked. + default: + xfs.stat(p, function (er2, stat) { + // if the stat fails, then that's super weird. + // let the original error be the failure reason. + if (er2 || !stat.isDirectory()) cb(er, made) + else cb(null, made); + }); + break; + } + }); +} - // restore line endings that were removed by byline - transforms.push(reLiner()); +mkdirP.sync = function sync (p, opts, made) { + if (!opts || typeof opts !== 'object') { + opts = { mode: opts }; + } + + var mode = opts.mode; + var xfs = opts.fs || fs; + + if (mode === undefined) { + mode = _0777 & (~process.umask()); + } + if (!made) made = null; + + p = path.resolve(p); + + try { + xfs.mkdirSync(p, mode); + made = made || p; + } + catch (err0) { + switch (err0.code) { + case 'ENOENT' : + made = sync(path.dirname(p), opts, made); + sync(p, opts, made); + break; - for (var t in transforms) { - emitter = emitter.pipe(transforms[t]); - } + // In the case of any other error, just see if there's a dir + // there already. If so, then hooray! If not, then something + // is borked. + default: + var stat; + try { + stat = xfs.statSync(p); + } + catch (err1) { + throw err0; + } + if (!stat.isDirectory()) throw err0; + break; + } + } - return duplexer(catcher, emitter); -} + return made; +}; -function reLiner() { - return through(appendNewline); - function appendNewline(line) { - this.emit('data', line + '\n'); - } -} +/***/ }), +/* 96 */ +/***/ (function(module, exports, __webpack_require__) { -function objectifier() { - return through(objectify, null, {autoDestroy: false}); +module.exports = realpath +realpath.realpath = realpath +realpath.sync = realpathSync +realpath.realpathSync = realpathSync +realpath.monkeypatch = monkeypatch +realpath.unmonkeypatch = unmonkeypatch - function objectify(line) { - this.emit('data', { - msg: line, - time: Date.now(), - }); - } -} +var fs = __webpack_require__(16) +var origRealpath = fs.realpath +var origRealpathSync = fs.realpathSync -function staticTagger(tag) { - return through(tagger); +var version = process.version +var ok = /^v[0-5]\./.test(version) +var old = __webpack_require__(136) - function tagger(logEvent) { - logEvent.tag = tag; - this.emit('data', logEvent); - } +function newError (er) { + return er && er.syscall === 'realpath' && ( + er.code === 'ELOOP' || + er.code === 'ENOMEM' || + er.code === 'ENAMETOOLONG' + ) } -function textFormatter(options) { - return through(textify); - - function textify(logEvent) { - var line = util.format('%s%s', textifyTags(logEvent.tag), - logEvent.msg.toString()); - if (options.timeStamp) { - line = util.format('%s %s', new Date(logEvent.time).toISOString(), line); - } - this.emit('data', line.replace(/\n/g, '\\n')); +function realpath (p, cache, cb) { + if (ok) { + return origRealpath(p, cache, cb) } - function textifyTags(tags) { - var str = ''; - if (typeof tags === 'string') { - str = tags + ' '; - } else if (typeof tags === 'object') { - for (var t in tags) { - str += t + ':' + tags[t] + ' '; - } - } - return str; + if (typeof cache === 'function') { + cb = cache + cache = null } -} - -function jsonFormatter(options) { - return through(jsonify); - - function jsonify(logEvent) { - if (options.timeStamp) { - logEvent.time = new Date(logEvent.time).toISOString(); + origRealpath(p, cache, function (er, result) { + if (newError(er)) { + old.realpath(p, cache, cb) } else { - delete logEvent.time; + cb(er, result) } - logEvent.msg = logEvent.msg.toString(); - this.emit('data', JSON.stringify(logEvent)); - } + }) } -function lineMerger(host) { - var previousLine = null; - var flushTimer = null; - var stream = through(lineMergerWrite, lineMergerEnd); - var flush = _flush.bind(stream); - - return stream; +function realpathSync (p, cache) { + if (ok) { + return origRealpathSync(p, cache) + } - function lineMergerWrite(line) { - if (/^\s+/.test(line.msg)) { - if (previousLine) { - previousLine.msg += '\n' + line.msg; - } else { - previousLine = line; - } + try { + return origRealpathSync(p, cache) + } catch (er) { + if (newError(er)) { + return old.realpathSync(p, cache) } else { - flush(); - previousLine = line; + throw er } - // rolling timeout - clearTimeout(flushTimer); - flushTimer = setTimeout(flush.bind(this), 10); } +} - function _flush() { - if (previousLine) { - this.emit('data', previousLine); - previousLine = null; - } - } +function monkeypatch () { + fs.realpath = realpath + fs.realpathSync = realpathSync +} - function lineMergerEnd() { - flush.call(this); - this.emit('end'); - } +function unmonkeypatch () { + fs.realpath = origRealpath + fs.realpathSync = origRealpathSync } @@ -8994,230 +8544,346 @@ function lineMerger(host) { /* 97 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +try { + var util = __webpack_require__(19); + if (typeof util.inherits !== 'function') throw ''; + module.exports = util.inherits; +} catch (e) { + module.exports = __webpack_require__(140); +} -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.copyWorkspacePackages = exports.workspacePackagePaths = undefined; +/***/ }), +/* 98 */ +/***/ (function(module, exports, __webpack_require__) { -let workspacePackagePaths = exports.workspacePackagePaths = (() => { - var _ref = _asyncToGenerator(function* (rootPath) { - const rootPkgJson = yield (0, _package_json.readPackageJson)(_path2.default.join(rootPath, 'package.json')); - if (!rootPkgJson.workspaces) { - return []; - } - const workspacesPathsPatterns = rootPkgJson.workspaces.packages; - let workspaceProjectsPaths = []; - for (const pattern of workspacesPathsPatterns) { - workspaceProjectsPaths = workspaceProjectsPaths.concat((yield packagesFromGlobPattern({ pattern, rootPath }))); - } - // Filter out exclude glob patterns - for (const pattern of workspacesPathsPatterns) { - if (pattern.startsWith('!')) { - const pathToRemove = _path2.default.join(rootPath, pattern.slice(1), 'package.json'); - workspaceProjectsPaths = workspaceProjectsPaths.filter(function (p) { - return p !== pathToRemove; - }); - } - } - return workspaceProjectsPaths; - }); +exports.alphasort = alphasort +exports.alphasorti = alphasorti +exports.setopts = setopts +exports.ownProp = ownProp +exports.makeAbs = makeAbs +exports.finish = finish +exports.mark = mark +exports.isIgnored = isIgnored +exports.childrenIgnored = childrenIgnored - return function workspacePackagePaths(_x) { - return _ref.apply(this, arguments); - }; -})(); +function ownProp (obj, field) { + return Object.prototype.hasOwnProperty.call(obj, field) +} -let copyWorkspacePackages = exports.copyWorkspacePackages = (() => { - var _ref2 = _asyncToGenerator(function* (rootPath) { - const workspaceProjects = yield getWorkspaceProjects(rootPath); - for (const project of workspaceProjects.values()) { - const dest = _path2.default.resolve(rootPath, 'node_modules', project.name); - // Remove the symlink - yield (0, _fs.unlink)(dest); - // Copy in the package - yield (0, _fs.copyDirectory)(project.path, dest); - } - }); +var path = __webpack_require__(7) +var minimatch = __webpack_require__(86) +var isAbsolute = __webpack_require__(87) +var Minimatch = minimatch.Minimatch - return function copyWorkspacePackages(_x2) { - return _ref2.apply(this, arguments); - }; -})(); +function alphasorti (a, b) { + return a.toLowerCase().localeCompare(b.toLowerCase()) +} -let getWorkspaceProjects = (() => { - var _ref3 = _asyncToGenerator(function* (rootPath) { - const projectPaths = (0, _config.getProjectPaths)(rootPath, {}); - const projects = yield (0, _projects.getProjects)(rootPath, projectPaths); - for (const [key, project] of projects.entries()) { - if (!project.isWorkspaceProject) { - projects.delete(key); - } - } - return projects; - }); +function alphasort (a, b) { + return a.localeCompare(b) +} - return function getWorkspaceProjects(_x3) { - return _ref3.apply(this, arguments); - }; -})(); +function setupIgnores (self, options) { + self.ignore = options.ignore || [] -var _glob = __webpack_require__(23); + if (!Array.isArray(self.ignore)) + self.ignore = [self.ignore] -var _glob2 = _interopRequireDefault(_glob); + if (self.ignore.length) { + self.ignore = self.ignore.map(ignoreMap) + } +} -var _path = __webpack_require__(2); +// ignore patterns are always in dot:true mode. +function ignoreMap (pattern) { + var gmatcher = null + if (pattern.slice(-3) === '/**') { + var gpattern = pattern.replace(/(\/\*\*)+$/, '') + gmatcher = new Minimatch(gpattern, { dot: true }) + } -var _path2 = _interopRequireDefault(_path); + return { + matcher: new Minimatch(pattern, { dot: true }), + gmatcher: gmatcher + } +} -var _util = __webpack_require__(8); +function setopts (self, pattern, options) { + if (!options) + options = {} -var _config = __webpack_require__(60); + // base-matching: just use globstar for that. + if (options.matchBase && -1 === pattern.indexOf("/")) { + if (options.noglobstar) { + throw new Error("base matching requires globstar") + } + pattern = "**/" + pattern + } -var _fs = __webpack_require__(39); + self.silent = !!options.silent + self.pattern = pattern + self.strict = options.strict !== false + self.realpath = !!options.realpath + self.realpathCache = options.realpathCache || Object.create(null) + self.follow = !!options.follow + self.dot = !!options.dot + self.mark = !!options.mark + self.nodir = !!options.nodir + if (self.nodir) + self.mark = true + self.sync = !!options.sync + self.nounique = !!options.nounique + self.nonull = !!options.nonull + self.nosort = !!options.nosort + self.nocase = !!options.nocase + self.stat = !!options.stat + self.noprocess = !!options.noprocess + self.absolute = !!options.absolute -var _package_json = __webpack_require__(41); + self.maxLength = options.maxLength || Infinity + self.cache = options.cache || Object.create(null) + self.statCache = options.statCache || Object.create(null) + self.symlinks = options.symlinks || Object.create(null) -var _projects = __webpack_require__(22); + setupIgnores(self, options) -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + self.changedCwd = false + var cwd = process.cwd() + if (!ownProp(options, "cwd")) + self.cwd = cwd + else { + self.cwd = path.resolve(options.cwd) + self.changedCwd = self.cwd !== cwd + } -function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* - * 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. - */ + self.root = options.root || path.resolve(self.cwd, "/") + self.root = path.resolve(self.root) + if (process.platform === "win32") + self.root = self.root.replace(/\\/g, "/") + // TODO: is an absolute `cwd` supposed to be resolved against `root`? + // e.g. { cwd: '/test', root: __dirname } === path.join(__dirname, '/test') + self.cwdAbs = isAbsolute(self.cwd) ? self.cwd : makeAbs(self, self.cwd) + if (process.platform === "win32") + self.cwdAbs = self.cwdAbs.replace(/\\/g, "/") + self.nomount = !!options.nomount -const glob = (0, _util.promisify)(_glob2.default); + // disable comments and negation in Minimatch. + // Note that they are not supported in Glob itself anyway. + options.nonegate = true + options.nocomment = true -function packagesFromGlobPattern({ pattern, rootPath }) { - const globOptions = { - cwd: rootPath, - // Should throw in case of unusual errors when reading the file system - strict: true, - // Always returns absolute paths for matched files - absolute: true, - // Do not match ** against multiple filenames - // (This is only specified because we currently don't have a need for it.) - noglobstar: true - }; - return glob(_path2.default.join(pattern, 'package.json'), globOptions); + self.minimatch = new Minimatch(pattern, options) + self.options = self.minimatch.options } -/***/ }), -/* 98 */ -/***/ (function(module, exports, __webpack_require__) { +function finish (self) { + var nou = self.nounique + var all = nou ? [] : Object.create(null) -"use strict"; + for (var i = 0, l = self.matches.length; i < l; i ++) { + var matches = self.matches[i] + if (!matches || Object.keys(matches).length === 0) { + if (self.nonull) { + // do like the shell, and spit out the literal glob + var literal = self.minimatch.globSet[i] + if (nou) + all.push(literal) + else + all[literal] = true + } + } else { + // had matches + var m = Object.keys(matches) + if (nou) + all.push.apply(all, m) + else + m.forEach(function (m) { + all[m] = true + }) + } + } -const path = __webpack_require__(2); -const globby = __webpack_require__(236); -const isPathCwd = __webpack_require__(240); -const isPathInCwd = __webpack_require__(241); -const pify = __webpack_require__(244); -const rimraf = __webpack_require__(245); -const pMap = __webpack_require__(246); + if (!nou) + all = Object.keys(all) -const rimrafP = pify(rimraf); + if (!self.nosort) + all = all.sort(self.nocase ? alphasorti : alphasort) -function safeCheck(file) { - if (isPathCwd(file)) { - throw new Error('Cannot delete the current working directory. Can be overriden with the `force` option.'); - } + // at *some* point we statted all of these + if (self.mark) { + for (var i = 0; i < all.length; i++) { + all[i] = self._mark(all[i]) + } + if (self.nodir) { + all = all.filter(function (e) { + var notDir = !(/\/$/.test(e)) + var c = self.cache[e] || self.cache[makeAbs(self, e)] + if (notDir && c) + notDir = c !== 'DIR' && !Array.isArray(c) + return notDir + }) + } + } - if (!isPathInCwd(file)) { - throw new Error('Cannot delete files/folders outside the current working directory. Can be overriden with the `force` option.'); - } -} + if (self.ignore.length) + all = all.filter(function(m) { + return !isIgnored(self, m) + }) -module.exports = (patterns, opts) => { - opts = Object.assign({}, opts); + self.found = all +} - const force = opts.force; - delete opts.force; +function mark (self, p) { + var abs = makeAbs(self, p) + var c = self.cache[abs] + var m = p + if (c) { + var isDir = c === 'DIR' || Array.isArray(c) + var slash = p.slice(-1) === '/' - const dryRun = opts.dryRun; - delete opts.dryRun; + if (isDir && !slash) + m += '/' + else if (!isDir && slash) + m = m.slice(0, -1) - const mapper = file => { - if (!force) { - safeCheck(file); - } + if (m !== p) { + var mabs = makeAbs(self, m) + self.statCache[mabs] = self.statCache[abs] + self.cache[mabs] = self.cache[abs] + } + } - file = path.resolve(opts.cwd || '', file); + return m +} - if (dryRun) { - return file; - } +// lotta situps... +function makeAbs (self, f) { + var abs = f + if (f.charAt(0) === '/') { + abs = path.join(self.root, f) + } else if (isAbsolute(f) || f === '') { + abs = f + } else if (self.changedCwd) { + abs = path.resolve(self.cwd, f) + } else { + abs = path.resolve(f) + } - return rimrafP(file, {glob: false}).then(() => file); - }; + if (process.platform === 'win32') + abs = abs.replace(/\\/g, '/') - return globby(patterns, opts).then(files => pMap(files, mapper, opts)); -}; + return abs +} -module.exports.sync = (patterns, opts) => { - opts = Object.assign({}, opts); - const force = opts.force; - delete opts.force; +// Return true, if pattern ends with globstar '**', for the accompanying parent directory. +// Ex:- If node_modules/** is the pattern, add 'node_modules' to ignore list along with it's contents +function isIgnored (self, path) { + if (!self.ignore.length) + return false - const dryRun = opts.dryRun; - delete opts.dryRun; + return self.ignore.some(function(item) { + return item.matcher.match(path) || !!(item.gmatcher && item.gmatcher.match(path)) + }) +} - return globby.sync(patterns, opts).map(file => { - if (!force) { - safeCheck(file); - } +function childrenIgnored (self, path) { + if (!self.ignore.length) + return false - file = path.resolve(opts.cwd || '', file); + return self.ignore.some(function(item) { + return !!(item.gmatcher && item.gmatcher.match(path)) + }) +} - if (!dryRun) { - rimraf.sync(file, {glob: false}); - } - return file; - }); -}; +/***/ }), +/* 99 */ +/***/ (function(module, exports) { +// Returns a wrapper function that returns a wrapped callback +// The wrapper function should do some stuff, and return a +// presumably different callback function. +// This makes sure that own properties are retained, so that +// decorations and such are not lost along the way. +module.exports = wrappy +function wrappy (fn, cb) { + if (fn && cb) return wrappy(fn)(cb) -/***/ }), -/* 99 */ -/***/ (function(module, exports, __webpack_require__) { + if (typeof fn !== 'function') + throw new TypeError('need wrapper function') -"use strict"; + Object.keys(fn).forEach(function (k) { + wrapper[k] = fn[k] + }) + return wrapper -module.exports = typeof Promise === 'function' ? Promise : __webpack_require__(237); + function wrapper() { + var args = new Array(arguments.length) + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + var ret = fn.apply(this, args) + var cb = args[args.length-1] + if (typeof ret === 'function' && ret !== cb) { + Object.keys(cb).forEach(function (k) { + ret[k] = cb[k] + }) + } + return ret + } +} /***/ }), /* 100 */ /***/ (function(module, exports, __webpack_require__) { -"use strict"; +var wrappy = __webpack_require__(99) +module.exports = wrappy(once) +module.exports.strict = wrappy(onceStrict) -var arrayUniq = __webpack_require__(238); +once.proto = once(function () { + Object.defineProperty(Function.prototype, 'once', { + value: function () { + return once(this) + }, + configurable: true + }) -module.exports = function () { - return arrayUniq([].concat.apply([], arguments)); -}; + Object.defineProperty(Function.prototype, 'onceStrict', { + value: function () { + return onceStrict(this) + }, + configurable: true + }) +}) + +function once (fn) { + var f = function () { + if (f.called) return f.value + f.called = true + return f.value = fn.apply(this, arguments) + } + f.called = false + return f +} + +function onceStrict (fn) { + var f = function () { + if (f.called) + throw new Error(f.onceError) + f.called = true + return f.value = fn.apply(this, arguments) + } + var name = fn.name || 'Function wrapped with `once`' + f.onceError = name + " shouldn't be called more than once" + f.called = false + return f +} /***/ }), @@ -9225,1711 +8891,1540 @@ module.exports = function () { /***/ (function(module, exports, __webpack_require__) { "use strict"; -/* -object-assign -(c) Sindre Sorhus -@license MIT -*/ - - -/* eslint-disable no-unused-vars */ -var getOwnPropertySymbols = Object.getOwnPropertySymbols; -var hasOwnProperty = Object.prototype.hasOwnProperty; -var propIsEnumerable = Object.prototype.propertyIsEnumerable; - -function toObject(val) { - if (val === null || val === undefined) { - throw new TypeError('Object.assign cannot be called with null or undefined'); - } - - return Object(val); -} - -function shouldUseNative() { - try { - if (!Object.assign) { - return false; - } - // Detect buggy property enumeration order in older V8 versions. - // https://bugs.chromium.org/p/v8/issues/detail?id=4118 - var test1 = new String('abc'); // eslint-disable-line no-new-wrappers - test1[5] = 'de'; - if (Object.getOwnPropertyNames(test1)[0] === '5') { - return false; - } +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.Project = undefined; - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test2 = {}; - for (var i = 0; i < 10; i++) { - test2['_' + String.fromCharCode(i)] = i; - } - var order2 = Object.getOwnPropertyNames(test2).map(function (n) { - return test2[n]; - }); - if (order2.join('') !== '0123456789') { - return false; - } +var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; /* + * 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. + */ - // https://bugs.chromium.org/p/v8/issues/detail?id=3056 - var test3 = {}; - 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { - test3[letter] = letter; - }); - if (Object.keys(Object.assign({}, test3)).join('') !== - 'abcdefghijklmnopqrst') { - return false; - } - return true; - } catch (err) { - // We don't expect any of the above to throw, but better to be safe. - return false; - } -} +var _chalk = __webpack_require__(30); -module.exports = shouldUseNative() ? Object.assign : function (target, source) { - var from; - var to = toObject(target); - var symbols; +var _chalk2 = _interopRequireDefault(_chalk); - for (var s = 1; s < arguments.length; s++) { - from = Object(arguments[s]); +var _path = __webpack_require__(7); - for (var key in from) { - if (hasOwnProperty.call(from, key)) { - to[key] = from[key]; - } - } +var _util = __webpack_require__(19); - if (getOwnPropertySymbols) { - symbols = getOwnPropertySymbols(from); - for (var i = 0; i < symbols.length; i++) { - if (propIsEnumerable.call(from, symbols[i])) { - to[symbols[i]] = from[symbols[i]]; - } - } - } - } +var _errors = __webpack_require__(88); - return to; -}; +var _log = __webpack_require__(36); +var _package_json = __webpack_require__(62); -/***/ }), -/* 102 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var _scripts = __webpack_require__(173); -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return empty; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__config__ = __webpack_require__(42); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_hostReportError__ = __webpack_require__(61); -/** PURE_IMPORTS_START _config,_util_hostReportError PURE_IMPORTS_END */ +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } -var empty = { - closed: true, - next: function (value) { }, - error: function (err) { - if (__WEBPACK_IMPORTED_MODULE_0__config__["a" /* config */].useDeprecatedSynchronousErrorHandling) { - throw err; +class Project { + constructor(packageJson, projectPath) { + this.isWorkspaceRoot = false; + this.isWorkspaceProject = false; + this.json = Object.freeze(packageJson); + this.path = projectPath; + this.packageJsonLocation = (0, _path.resolve)(this.path, 'package.json'); + this.nodeModulesLocation = (0, _path.resolve)(this.path, 'node_modules'); + this.targetLocation = (0, _path.resolve)(this.path, 'target'); + this.productionDependencies = this.json.dependencies || {}; + this.devDependencies = this.json.devDependencies || {}; + this.allDependencies = _extends({}, this.devDependencies, this.productionDependencies); + this.isWorkspaceRoot = this.json.hasOwnProperty('workspaces'); + this.scripts = this.json.scripts || {}; + } + static fromPath(path) { + return _asyncToGenerator(function* () { + const pkgJson = yield (0, _package_json.readPackageJson)(path); + return new Project(pkgJson, path); + })(); + } + get name() { + return this.json.name; + } + ensureValidProjectDependency(project, dependentProjectIsInWorkspace) { + const versionInPackageJson = this.allDependencies[project.name]; + let expectedVersionInPackageJson; + if (dependentProjectIsInWorkspace) { + expectedVersionInPackageJson = project.json.version; + } else { + const relativePathToProject = normalizePath((0, _path.relative)(this.path, project.path)); + expectedVersionInPackageJson = `link:${relativePathToProject}`; + } + // No issues! + if (versionInPackageJson === expectedVersionInPackageJson) { + return; + } + let problemMsg; + if ((0, _package_json.isLinkDependency)(versionInPackageJson) && dependentProjectIsInWorkspace) { + problemMsg = `but should be using a workspace`; + } else if ((0, _package_json.isLinkDependency)(versionInPackageJson)) { + problemMsg = `using 'link:', but the path is wrong`; + } else { + problemMsg = `but it's not using the local package`; + } + throw new _errors.CliError(`[${this.name}] depends on [${project.name}] ${problemMsg}. Update its package.json to the expected value below.`, { + actual: `"${project.name}": "${versionInPackageJson}"`, + expected: `"${project.name}": "${expectedVersionInPackageJson}"`, + package: `${this.name} (${this.packageJsonLocation})` + }); + } + getBuildConfig() { + return this.json.kibana && this.json.kibana.build || {}; + } + /** + * Returns the directory that should be copied into the Kibana build artifact. + * This config can be specified to only include the project's build artifacts + * instead of everything located in the project directory. + */ + getIntermediateBuildDirectory() { + return (0, _path.resolve)(this.path, this.getBuildConfig().intermediateBuildDirectory || '.'); + } + getCleanConfig() { + return this.json.kibana && this.json.kibana.clean || {}; + } + hasScript(name) { + return name in this.scripts; + } + getExecutables() { + const raw = this.json.bin; + if (!raw) { + return {}; } - else { - Object(__WEBPACK_IMPORTED_MODULE_1__util_hostReportError__["a" /* hostReportError */])(err); + if (typeof raw === 'string') { + return { + [this.name]: (0, _path.resolve)(this.path, raw) + }; } - }, - complete: function () { } -}; -//# sourceMappingURL=Observer.js.map - + if (typeof raw === 'object') { + const binsConfig = {}; + for (const binName of Object.keys(raw)) { + binsConfig[binName] = (0, _path.resolve)(this.path, raw[binName]); + } + return binsConfig; + } + throw new _errors.CliError(`[${this.name}] has an invalid "bin" field in its package.json, ` + `expected an object or a string`, { + binConfig: (0, _util.inspect)(raw), + package: `${this.name} (${this.packageJsonLocation})` + }); + } + runScript(scriptName, args = []) { + var _this = this; -/***/ }), -/* 103 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + return _asyncToGenerator(function* () { + _log.log.write(_chalk2.default.bold(`\n\nRunning script [${_chalk2.default.green(scriptName)}] in [${_chalk2.default.green(_this.name)}]:\n`)); + return (0, _scripts.runScriptInPackage)(scriptName, args, _this); + })(); + } + runScriptStreaming(scriptName, args = []) { + return (0, _scripts.runScriptInPackageStreaming)(scriptName, args, this); + } + hasDependencies() { + return Object.keys(this.allDependencies).length > 0; + } + installDependencies({ extraArgs }) { + var _this2 = this; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isObject; -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function isObject(x) { - return x != null && typeof x === 'object'; + return _asyncToGenerator(function* () { + _log.log.write(_chalk2.default.bold(`\n\nInstalling dependencies in [${_chalk2.default.green(_this2.name)}]:\n`)); + return (0, _scripts.installInDir)(_this2.path, extraArgs); + })(); + } } -//# sourceMappingURL=isObject.js.map +exports.Project = Project; // We normalize all path separators to `/` in generated files +function normalizePath(path) { + return path.replace(/[\\\/]+/g, '/'); +} /***/ }), -/* 104 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return UnsubscriptionError; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ - -var UnsubscriptionError = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](UnsubscriptionError, _super); - function UnsubscriptionError(errors) { - var _this = _super.call(this, errors ? - errors.length + " errors occurred during unsubscription:\n " + errors.map(function (err, i) { return i + 1 + ") " + err.toString(); }).join('\n ') : '') || this; - _this.errors = errors; - _this.name = 'UnsubscriptionError'; - Object.setPrototypeOf(_this, UnsubscriptionError.prototype); - return _this; - } - return UnsubscriptionError; -}(Error)); - -//# sourceMappingURL=UnsubscriptionError.js.map +/* 102 */ +/***/ (function(module, exports, __webpack_require__) { +module.exports = normalize -/***/ }), -/* 105 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var fixer = __webpack_require__(151) +normalize.fixer = fixer -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ConnectableObservable; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return connectableObservableDescriptor; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__operators_refCount__ = __webpack_require__(64); -/** PURE_IMPORTS_START tslib,_Subject,_Observable,_Subscriber,_Subscription,_operators_refCount PURE_IMPORTS_END */ +var makeWarning = __webpack_require__(164) +var fieldsToFix = ['name','version','description','repository','modules','scripts' + ,'files','bin','man','bugs','keywords','readme','homepage','license'] +var otherThingsToFix = ['dependencies','people', 'typos'] +var thingsToFix = fieldsToFix.map(function(fieldName) { + return ucFirst(fieldName) + "Field" +}) +// two ways to do this in CoffeeScript on only one line, sub-70 chars: +// thingsToFix = fieldsToFix.map (name) -> ucFirst(name) + "Field" +// thingsToFix = (ucFirst(name) + "Field" for name in fieldsToFix) +thingsToFix = thingsToFix.concat(otherThingsToFix) +function normalize (data, warn, strict) { + if(warn === true) warn = null, strict = true + if(!strict) strict = false + if(!warn || data.private) warn = function(msg) { /* noop */ } + if (data.scripts && + data.scripts.install === "node-gyp rebuild" && + !data.scripts.preinstall) { + data.gypfile = true + } + fixer.warn = function() { warn(makeWarning.apply(null, arguments)) } + thingsToFix.forEach(function(thingName) { + fixer["fix" + ucFirst(thingName)](data, strict) + }) + data._id = data.name + "@" + data.version +} +function ucFirst (string) { + return string.charAt(0).toUpperCase() + string.slice(1); +} -var ConnectableObservable = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ConnectableObservable, _super); - function ConnectableObservable(source, subjectFactory) { - var _this = _super.call(this) || this; - _this.source = source; - _this.subjectFactory = subjectFactory; - _this._refCount = 0; - _this._isComplete = false; - return _this; - } - ConnectableObservable.prototype._subscribe = function (subscriber) { - return this.getSubject().subscribe(subscriber); - }; - ConnectableObservable.prototype.getSubject = function () { - var subject = this._subject; - if (!subject || subject.isStopped) { - this._subject = this.subjectFactory(); - } - return this._subject; - }; - ConnectableObservable.prototype.connect = function () { - var connection = this._connection; - if (!connection) { - this._isComplete = false; - connection = this._connection = new __WEBPACK_IMPORTED_MODULE_4__Subscription__["a" /* Subscription */](); - connection.add(this.source - .subscribe(new ConnectableSubscriber(this.getSubject(), this))); - if (connection.closed) { - this._connection = null; - connection = __WEBPACK_IMPORTED_MODULE_4__Subscription__["a" /* Subscription */].EMPTY; - } - else { - this._connection = connection; - } - } - return connection; - }; - ConnectableObservable.prototype.refCount = function () { - return Object(__WEBPACK_IMPORTED_MODULE_5__operators_refCount__["a" /* refCount */])()(this); - }; - return ConnectableObservable; -}(__WEBPACK_IMPORTED_MODULE_2__Observable__["a" /* Observable */])); -var connectableProto = ConnectableObservable.prototype; -var connectableObservableDescriptor = { - operator: { value: null }, - _refCount: { value: 0, writable: true }, - _subject: { value: null, writable: true }, - _connection: { value: null, writable: true }, - _subscribe: { value: connectableProto._subscribe }, - _isComplete: { value: connectableProto._isComplete, writable: true }, - getSubject: { value: connectableProto.getSubject }, - connect: { value: connectableProto.connect }, - refCount: { value: connectableProto.refCount } -}; -var ConnectableSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ConnectableSubscriber, _super); - function ConnectableSubscriber(destination, connectable) { - var _this = _super.call(this, destination) || this; - _this.connectable = connectable; - return _this; - } - ConnectableSubscriber.prototype._error = function (err) { - this._unsubscribe(); - _super.prototype._error.call(this, err); - }; - ConnectableSubscriber.prototype._complete = function () { - this.connectable._isComplete = true; - this._unsubscribe(); - _super.prototype._complete.call(this); - }; - ConnectableSubscriber.prototype._unsubscribe = function () { - var connectable = this.connectable; - if (connectable) { - this.connectable = null; - var connection = connectable._connection; - connectable._refCount = 0; - connectable._subject = null; - connectable._connection = null; - if (connection) { - connection.unsubscribe(); - } - } - }; - return ConnectableSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subject__["b" /* SubjectSubscriber */])); -var RefCountOperator = /*@__PURE__*/ (function () { - function RefCountOperator(connectable) { - this.connectable = connectable; - } - RefCountOperator.prototype.call = function (subscriber, source) { - var connectable = this.connectable; - connectable._refCount++; - var refCounter = new RefCountSubscriber(subscriber, connectable); - var subscription = source.subscribe(refCounter); - if (!refCounter.closed) { - refCounter.connection = connectable.connect(); - } - return subscription; - }; - return RefCountOperator; -}()); -var RefCountSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](RefCountSubscriber, _super); - function RefCountSubscriber(destination, connectable) { - var _this = _super.call(this, destination) || this; - _this.connectable = connectable; - return _this; - } - RefCountSubscriber.prototype._unsubscribe = function () { - var connectable = this.connectable; - if (!connectable) { - this.connection = null; - return; - } - this.connectable = null; - var refCount = connectable._refCount; - if (refCount <= 0) { - this.connection = null; - return; - } - connectable._refCount = refCount - 1; - if (refCount > 1) { - this.connection = null; - return; - } - var connection = this.connection; - var sharedConnection = connectable._connection; - this.connection = null; - if (sharedConnection && (!connection || sharedConnection === connection)) { - sharedConnection.unsubscribe(); - } - }; - return RefCountSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=ConnectableObservable.js.map +/***/ }), +/* 103 */ +/***/ (function(module, exports) { +module.exports = require("url"); /***/ }), -/* 106 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 104 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return SubjectSubscription; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/** PURE_IMPORTS_START tslib,_Subscription PURE_IMPORTS_END */ -var SubjectSubscription = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SubjectSubscription, _super); - function SubjectSubscription(subject, subscriber) { - var _this = _super.call(this) || this; - _this.subject = subject; - _this.subscriber = subscriber; - _this.closed = false; - return _this; - } - SubjectSubscription.prototype.unsubscribe = function () { - if (this.closed) { - return; - } - this.closed = true; - var subject = this.subject; - var observers = subject.observers; - this.subject = null; - if (!observers || observers.length === 0 || subject.isStopped || subject.closed) { - return; - } - var subscriberIndex = observers.indexOf(this.subscriber); - if (subscriberIndex !== -1) { - observers.splice(subscriberIndex, 1); - } - }; - return SubjectSubscription; -}(__WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */])); +var gitHosts = module.exports = { + github: { + // First two are insecure and generally shouldn't be used any more, but + // they are still supported. + 'protocols': [ 'git', 'http', 'git+ssh', 'git+https', 'ssh', 'https' ], + 'domain': 'github.com', + 'treepath': 'tree', + 'filetemplate': 'https://{auth@}raw.githubusercontent.com/{user}/{project}/{committish}/{path}', + 'bugstemplate': 'https://{domain}/{user}/{project}/issues', + 'gittemplate': 'git://{auth@}{domain}/{user}/{project}.git{#committish}', + 'tarballtemplate': 'https://{domain}/{user}/{project}/archive/{committish}.tar.gz' + }, + bitbucket: { + 'protocols': [ 'git+ssh', 'git+https', 'ssh', 'https' ], + 'domain': 'bitbucket.org', + 'treepath': 'src', + 'tarballtemplate': 'https://{domain}/{user}/{project}/get/{committish}.tar.gz' + }, + gitlab: { + 'protocols': [ 'git+ssh', 'git+https', 'ssh', 'https' ], + 'domain': 'gitlab.com', + 'treepath': 'tree', + 'docstemplate': 'https://{domain}/{user}/{project}{/tree/committish}#README', + 'bugstemplate': 'https://{domain}/{user}/{project}/issues', + 'tarballtemplate': 'https://{domain}/{user}/{project}/repository/archive.tar.gz?ref={committish}' + }, + gist: { + 'protocols': [ 'git', 'git+ssh', 'git+https', 'ssh', 'https' ], + 'domain': 'gist.github.com', + 'pathmatch': /^[/](?:([^/]+)[/])?([a-z0-9]+)(?:[.]git)?$/, + 'filetemplate': 'https://gist.githubusercontent.com/{user}/{project}/raw{/committish}/{path}', + 'bugstemplate': 'https://{domain}/{project}', + 'gittemplate': 'git://{domain}/{project}.git{#committish}', + 'sshtemplate': 'git@{domain}:/{project}.git{#committish}', + 'sshurltemplate': 'git+ssh://git@{domain}/{project}.git{#committish}', + 'browsetemplate': 'https://{domain}/{project}{/committish}', + 'docstemplate': 'https://{domain}/{project}{/committish}', + 'httpstemplate': 'git+https://{domain}/{project}.git{#committish}', + 'shortcuttemplate': '{type}:{project}{#committish}', + 'pathtemplate': '{project}{#committish}', + 'tarballtemplate': 'https://{domain}/{user}/{project}/archive/{committish}.tar.gz' + } +} + +var gitHostDefaults = { + 'sshtemplate': 'git@{domain}:{user}/{project}.git{#committish}', + 'sshurltemplate': 'git+ssh://git@{domain}/{user}/{project}.git{#committish}', + 'browsetemplate': 'https://{domain}/{user}/{project}{/tree/committish}', + 'docstemplate': 'https://{domain}/{user}/{project}{/tree/committish}#readme', + 'httpstemplate': 'git+https://{auth@}{domain}/{user}/{project}.git{#committish}', + 'filetemplate': 'https://{domain}/{user}/{project}/raw/{committish}/{path}', + 'shortcuttemplate': '{type}:{user}/{project}{#committish}', + 'pathtemplate': '{user}/{project}{#committish}', + 'pathmatch': /^[/]([^/]+)[/]([^/]+?)(?:[.]git|[/])?$/ +} -//# sourceMappingURL=SubjectSubscription.js.map +Object.keys(gitHosts).forEach(function (name) { + Object.keys(gitHostDefaults).forEach(function (key) { + if (gitHosts[name][key]) return + gitHosts[name][key] = gitHostDefaults[key] + }) + gitHosts[name].protocols_re = RegExp('^(' + + gitHosts[name].protocols.map(function (protocol) { + return protocol.replace(/([\\+*{}()[\]$^|])/g, '\\$1') + }).join('|') + '):$') +}) /***/ }), -/* 107 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 105 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["b"] = groupBy; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return GroupedObservable; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__Subject__ = __webpack_require__(9); -/** PURE_IMPORTS_START tslib,_Subscriber,_Subscription,_Observable,_Subject PURE_IMPORTS_END */ +const isPlainObj = __webpack_require__(171); +module.exports = (obj, opts) => { + if (!isPlainObj(obj)) { + throw new TypeError('Expected a plain object'); + } + opts = opts || {}; + // DEPRECATED + if (typeof opts === 'function') { + throw new TypeError('Specify the compare function as an option instead'); + } -function groupBy(keySelector, elementSelector, durationSelector, subjectSelector) { - return function (source) { - return source.lift(new GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector)); - }; -} -var GroupByOperator = /*@__PURE__*/ (function () { - function GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector) { - this.keySelector = keySelector; - this.elementSelector = elementSelector; - this.durationSelector = durationSelector; - this.subjectSelector = subjectSelector; - } - GroupByOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new GroupBySubscriber(subscriber, this.keySelector, this.elementSelector, this.durationSelector, this.subjectSelector)); - }; - return GroupByOperator; -}()); -var GroupBySubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](GroupBySubscriber, _super); - function GroupBySubscriber(destination, keySelector, elementSelector, durationSelector, subjectSelector) { - var _this = _super.call(this, destination) || this; - _this.keySelector = keySelector; - _this.elementSelector = elementSelector; - _this.durationSelector = durationSelector; - _this.subjectSelector = subjectSelector; - _this.groups = null; - _this.attemptedToUnsubscribe = false; - _this.count = 0; - return _this; - } - GroupBySubscriber.prototype._next = function (value) { - var key; - try { - key = this.keySelector(value); - } - catch (err) { - this.error(err); - return; - } - this._group(value, key); - }; - GroupBySubscriber.prototype._group = function (value, key) { - var groups = this.groups; - if (!groups) { - groups = this.groups = new Map(); - } - var group = groups.get(key); - var element; - if (this.elementSelector) { - try { - element = this.elementSelector(value); - } - catch (err) { - this.error(err); - } - } - else { - element = value; - } - if (!group) { - group = (this.subjectSelector ? this.subjectSelector() : new __WEBPACK_IMPORTED_MODULE_4__Subject__["a" /* Subject */]()); - groups.set(key, group); - var groupedObservable = new GroupedObservable(key, group, this); - this.destination.next(groupedObservable); - if (this.durationSelector) { - var duration = void 0; - try { - duration = this.durationSelector(new GroupedObservable(key, group)); - } - catch (err) { - this.error(err); - return; - } - this.add(duration.subscribe(new GroupDurationSubscriber(key, group, this))); - } - } - if (!group.closed) { - group.next(element); - } - }; - GroupBySubscriber.prototype._error = function (err) { - var groups = this.groups; - if (groups) { - groups.forEach(function (group, key) { - group.error(err); - }); - groups.clear(); - } - this.destination.error(err); - }; - GroupBySubscriber.prototype._complete = function () { - var groups = this.groups; - if (groups) { - groups.forEach(function (group, key) { - group.complete(); - }); - groups.clear(); - } - this.destination.complete(); - }; - GroupBySubscriber.prototype.removeGroup = function (key) { - this.groups.delete(key); - }; - GroupBySubscriber.prototype.unsubscribe = function () { - if (!this.closed) { - this.attemptedToUnsubscribe = true; - if (this.count === 0) { - _super.prototype.unsubscribe.call(this); - } - } - }; - return GroupBySubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -var GroupDurationSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](GroupDurationSubscriber, _super); - function GroupDurationSubscriber(key, group, parent) { - var _this = _super.call(this, group) || this; - _this.key = key; - _this.group = group; - _this.parent = parent; - return _this; - } - GroupDurationSubscriber.prototype._next = function (value) { - this.complete(); - }; - GroupDurationSubscriber.prototype._unsubscribe = function () { - var _a = this, parent = _a.parent, key = _a.key; - this.key = this.parent = null; - if (parent) { - parent.removeGroup(key); - } - }; - return GroupDurationSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -var GroupedObservable = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](GroupedObservable, _super); - function GroupedObservable(key, groupSubject, refCountSubscription) { - var _this = _super.call(this) || this; - _this.key = key; - _this.groupSubject = groupSubject; - _this.refCountSubscription = refCountSubscription; - return _this; - } - GroupedObservable.prototype._subscribe = function (subscriber) { - var subscription = new __WEBPACK_IMPORTED_MODULE_2__Subscription__["a" /* Subscription */](); - var _a = this, refCountSubscription = _a.refCountSubscription, groupSubject = _a.groupSubject; - if (refCountSubscription && !refCountSubscription.closed) { - subscription.add(new InnerRefCountSubscription(refCountSubscription)); - } - subscription.add(groupSubject.subscribe(subscriber)); - return subscription; - }; - return GroupedObservable; -}(__WEBPACK_IMPORTED_MODULE_3__Observable__["a" /* Observable */])); + const deep = opts.deep; + const seenInput = []; + const seenOutput = []; + + const sortKeys = x => { + const seenIndex = seenInput.indexOf(x); -var InnerRefCountSubscription = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](InnerRefCountSubscription, _super); - function InnerRefCountSubscription(parent) { - var _this = _super.call(this) || this; - _this.parent = parent; - parent.count++; - return _this; - } - InnerRefCountSubscription.prototype.unsubscribe = function () { - var parent = this.parent; - if (!parent.closed && !this.closed) { - _super.prototype.unsubscribe.call(this); - parent.count -= 1; - if (parent.count === 0 && parent.attemptedToUnsubscribe) { - parent.unsubscribe(); - } - } - }; - return InnerRefCountSubscription; -}(__WEBPACK_IMPORTED_MODULE_2__Subscription__["a" /* Subscription */])); -//# sourceMappingURL=groupBy.js.map + if (seenIndex !== -1) { + return seenOutput[seenIndex]; + } + + const ret = {}; + const keys = Object.keys(x).sort(opts.compare); + + seenInput.push(x); + seenOutput.push(ret); + + for (let i = 0; i < keys.length; i++) { + const key = keys[i]; + const val = x[key]; + + if (deep && Array.isArray(val)) { + const retArr = []; + + for (let j = 0; j < val.length; j++) { + retArr[j] = isPlainObj(val[j]) ? sortKeys(val[j]) : val[j]; + } + + ret[key] = retArr; + continue; + } + + ret[key] = deep && isPlainObj(val) ? sortKeys(val) : val; + } + + return ret; + }; + + return sortKeys(obj); +}; /***/ }), -/* 108 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 106 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return BehaviorSubject; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_ObjectUnsubscribedError__ = __webpack_require__(44); -/** PURE_IMPORTS_START tslib,_Subject,_util_ObjectUnsubscribedError PURE_IMPORTS_END */ +const fs = __webpack_require__(16); +const path = __webpack_require__(7); +const pify = __webpack_require__(44); +const defaults = { + mode: 0o777 & (~process.umask()), + fs +}; -var BehaviorSubject = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](BehaviorSubject, _super); - function BehaviorSubject(_value) { - var _this = _super.call(this) || this; - _this._value = _value; - return _this; - } - Object.defineProperty(BehaviorSubject.prototype, "value", { - get: function () { - return this.getValue(); - }, - enumerable: true, - configurable: true - }); - BehaviorSubject.prototype._subscribe = function (subscriber) { - var subscription = _super.prototype._subscribe.call(this, subscriber); - if (subscription && !subscription.closed) { - subscriber.next(this._value); - } - return subscription; - }; - BehaviorSubject.prototype.getValue = function () { - if (this.hasError) { - throw this.thrownError; - } - else if (this.closed) { - throw new __WEBPACK_IMPORTED_MODULE_2__util_ObjectUnsubscribedError__["a" /* ObjectUnsubscribedError */](); - } - else { - return this._value; - } - }; - BehaviorSubject.prototype.next = function (value) { - _super.prototype.next.call(this, this._value = value); - }; - return BehaviorSubject; -}(__WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */])); +// https://github.com/nodejs/node/issues/8987 +// https://github.com/libuv/libuv/pull/1088 +const checkPath = pth => { + if (process.platform === 'win32') { + const pathHasInvalidWinCharacters = /[<>:"|?*]/.test(pth.replace(path.parse(pth).root, '')); -//# sourceMappingURL=BehaviorSubject.js.map + if (pathHasInvalidWinCharacters) { + const err = new Error(`Path contains invalid characters: ${pth}`); + err.code = 'EINVAL'; + throw err; + } + } +}; + +module.exports = (input, opts) => Promise.resolve().then(() => { + checkPath(input); + opts = Object.assign({}, defaults, opts); + + const mkdir = pify(opts.fs.mkdir); + const stat = pify(opts.fs.stat); + + const make = pth => { + return mkdir(pth, opts.mode) + .then(() => pth) + .catch(err => { + if (err.code === 'ENOENT') { + if (err.message.includes('null bytes') || path.dirname(pth) === pth) { + throw err; + } + + return make(path.dirname(pth)).then(() => make(pth)); + } + + return stat(pth) + .then(stats => stats.isDirectory() ? pth : Promise.reject()) + .catch(() => { + throw err; + }); + }); + }; + + return make(path.resolve(input)); +}); + +module.exports.sync = (input, opts) => { + checkPath(input); + opts = Object.assign({}, defaults, opts); + + const make = pth => { + try { + opts.fs.mkdirSync(pth, opts.mode); + } catch (err) { + if (err.code === 'ENOENT') { + if (err.message.includes('null bytes') || path.dirname(pth) === pth) { + throw err; + } + + make(path.dirname(pth)); + return make(pth); + } + + try { + if (!opts.fs.statSync(pth).isDirectory()) { + throw new Error('The path is not a directory'); + } + } catch (_) { + throw err; + } + } + + return pth; + }; + + return make(path.resolve(input)); +}; /***/ }), -/* 109 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 107 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return queue; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__QueueAction__ = __webpack_require__(263); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__QueueScheduler__ = __webpack_require__(265); -/** PURE_IMPORTS_START _QueueAction,_QueueScheduler PURE_IMPORTS_END */ -var queue = /*@__PURE__*/ new __WEBPACK_IMPORTED_MODULE_1__QueueScheduler__["a" /* QueueScheduler */](__WEBPACK_IMPORTED_MODULE_0__QueueAction__["a" /* QueueAction */]); -//# sourceMappingURL=queue.js.map +var path = __webpack_require__(7); +var which = __webpack_require__(178); +var LRU = __webpack_require__(108); + +var commandCache = new LRU({ max: 50, maxAge: 30 * 1000 }); // Cache just for 30sec + +function resolveCommand(command, noExtension) { + var resolved; + + noExtension = !!noExtension; + resolved = commandCache.get(command + '!' + noExtension); + + // Check if its resolved in the cache + if (commandCache.has(command)) { + return commandCache.get(command); + } + + try { + resolved = !noExtension ? + which.sync(command) : + which.sync(command, { pathExt: path.delimiter + (process.env.PATHEXT || '') }); + } catch (e) { /* empty */ } + + commandCache.set(command + '!' + noExtension, resolved); + + return resolved; +} + +module.exports = resolveCommand; /***/ }), -/* 110 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 108 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Scheduler; }); -var Scheduler = /*@__PURE__*/ (function () { - function Scheduler(SchedulerAction, now) { - if (now === void 0) { - now = Scheduler.now; - } - this.SchedulerAction = SchedulerAction; - this.now = now; - } - Scheduler.prototype.schedule = function (work, delay, state) { - if (delay === void 0) { - delay = 0; - } - return new this.SchedulerAction(this, work).schedule(state, delay); - }; - Scheduler.now = Date.now ? Date.now : function () { return +new Date(); }; - return Scheduler; -}()); -//# sourceMappingURL=Scheduler.js.map +module.exports = LRUCache + +// This will be a proper iterable 'Map' in engines that support it, +// or a fakey-fake PseudoMap in older versions. +var Map = __webpack_require__(182) +var util = __webpack_require__(19) + +// A linked list to keep track of recently-used-ness +var Yallist = __webpack_require__(184) + +// use symbols if possible, otherwise just _props +var hasSymbol = typeof Symbol === 'function' +var makeSymbol +if (hasSymbol) { + makeSymbol = function (key) { + return Symbol.for(key) + } +} else { + makeSymbol = function (key) { + return '_' + key + } +} + +var MAX = makeSymbol('max') +var LENGTH = makeSymbol('length') +var LENGTH_CALCULATOR = makeSymbol('lengthCalculator') +var ALLOW_STALE = makeSymbol('allowStale') +var MAX_AGE = makeSymbol('maxAge') +var DISPOSE = makeSymbol('dispose') +var NO_DISPOSE_ON_SET = makeSymbol('noDisposeOnSet') +var LRU_LIST = makeSymbol('lruList') +var CACHE = makeSymbol('cache') + +function naiveLength () { return 1 } + +// lruList is a yallist where the head is the youngest +// item, and the tail is the oldest. the list contains the Hit +// objects as the entries. +// Each Hit object has a reference to its Yallist.Node. This +// never changes. +// +// cache is a Map (or PseudoMap) that matches the keys to +// the Yallist.Node object. +function LRUCache (options) { + if (!(this instanceof LRUCache)) { + return new LRUCache(options) + } -/***/ }), -/* 111 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + if (typeof options === 'number') { + options = { max: options } + } -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["b"] = observeOn; -/* unused harmony export ObserveOnOperator */ -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ObserveOnSubscriber; }); -/* unused harmony export ObserveOnMessage */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Notification__ = __webpack_require__(45); -/** PURE_IMPORTS_START tslib,_Subscriber,_Notification PURE_IMPORTS_END */ + if (!options) { + options = {} + } + var max = this[MAX] = options.max + // Kind of weird to have a default max of Infinity, but oh well. + if (!max || + !(typeof max === 'number') || + max <= 0) { + this[MAX] = Infinity + } + var lc = options.length || naiveLength + if (typeof lc !== 'function') { + lc = naiveLength + } + this[LENGTH_CALCULATOR] = lc -function observeOn(scheduler, delay) { - if (delay === void 0) { - delay = 0; - } - return function observeOnOperatorFunction(source) { - return source.lift(new ObserveOnOperator(scheduler, delay)); - }; + this[ALLOW_STALE] = options.stale || false + this[MAX_AGE] = options.maxAge || 0 + this[DISPOSE] = options.dispose + this[NO_DISPOSE_ON_SET] = options.noDisposeOnSet || false + this.reset() } -var ObserveOnOperator = /*@__PURE__*/ (function () { - function ObserveOnOperator(scheduler, delay) { - if (delay === void 0) { - delay = 0; - } - this.scheduler = scheduler; - this.delay = delay; + +// resize the cache when the max changes. +Object.defineProperty(LRUCache.prototype, 'max', { + set: function (mL) { + if (!mL || !(typeof mL === 'number') || mL <= 0) { + mL = Infinity } - ObserveOnOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new ObserveOnSubscriber(subscriber, this.scheduler, this.delay)); - }; - return ObserveOnOperator; -}()); + this[MAX] = mL + trim(this) + }, + get: function () { + return this[MAX] + }, + enumerable: true +}) -var ObserveOnSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ObserveOnSubscriber, _super); - function ObserveOnSubscriber(destination, scheduler, delay) { - if (delay === void 0) { - delay = 0; - } - var _this = _super.call(this, destination) || this; - _this.scheduler = scheduler; - _this.delay = delay; - return _this; +Object.defineProperty(LRUCache.prototype, 'allowStale', { + set: function (allowStale) { + this[ALLOW_STALE] = !!allowStale + }, + get: function () { + return this[ALLOW_STALE] + }, + enumerable: true +}) + +Object.defineProperty(LRUCache.prototype, 'maxAge', { + set: function (mA) { + if (!mA || !(typeof mA === 'number') || mA < 0) { + mA = 0 } - ObserveOnSubscriber.dispatch = function (arg) { - var notification = arg.notification, destination = arg.destination; - notification.observe(destination); - this.unsubscribe(); - }; - ObserveOnSubscriber.prototype.scheduleMessage = function (notification) { - this.add(this.scheduler.schedule(ObserveOnSubscriber.dispatch, this.delay, new ObserveOnMessage(notification, this.destination))); - }; - ObserveOnSubscriber.prototype._next = function (value) { - this.scheduleMessage(__WEBPACK_IMPORTED_MODULE_2__Notification__["a" /* Notification */].createNext(value)); - }; - ObserveOnSubscriber.prototype._error = function (err) { - this.scheduleMessage(__WEBPACK_IMPORTED_MODULE_2__Notification__["a" /* Notification */].createError(err)); - }; - ObserveOnSubscriber.prototype._complete = function () { - this.scheduleMessage(__WEBPACK_IMPORTED_MODULE_2__Notification__["a" /* Notification */].createComplete()); - }; - return ObserveOnSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); + this[MAX_AGE] = mA + trim(this) + }, + get: function () { + return this[MAX_AGE] + }, + enumerable: true +}) -var ObserveOnMessage = /*@__PURE__*/ (function () { - function ObserveOnMessage(notification, destination) { - this.notification = notification; - this.destination = destination; +// resize the cache when the lengthCalculator changes. +Object.defineProperty(LRUCache.prototype, 'lengthCalculator', { + set: function (lC) { + if (typeof lC !== 'function') { + lC = naiveLength } - return ObserveOnMessage; -}()); + if (lC !== this[LENGTH_CALCULATOR]) { + this[LENGTH_CALCULATOR] = lC + this[LENGTH] = 0 + this[LRU_LIST].forEach(function (hit) { + hit.length = this[LENGTH_CALCULATOR](hit.value, hit.key) + this[LENGTH] += hit.length + }, this) + } + trim(this) + }, + get: function () { return this[LENGTH_CALCULATOR] }, + enumerable: true +}) -//# sourceMappingURL=observeOn.js.map +Object.defineProperty(LRUCache.prototype, 'length', { + get: function () { return this[LENGTH] }, + enumerable: true +}) +Object.defineProperty(LRUCache.prototype, 'itemCount', { + get: function () { return this[LRU_LIST].length }, + enumerable: true +}) -/***/ }), -/* 112 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +LRUCache.prototype.rforEach = function (fn, thisp) { + thisp = thisp || this + for (var walker = this[LRU_LIST].tail; walker !== null;) { + var prev = walker.prev + forEachStep(this, fn, walker, thisp) + walker = prev + } +} -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToArray; }); -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -var subscribeToArray = function (array) { - return function (subscriber) { - for (var i = 0, len = array.length; i < len && !subscriber.closed; i++) { - subscriber.next(array[i]); - } - if (!subscriber.closed) { - subscriber.complete(); - } - }; -}; -//# sourceMappingURL=subscribeToArray.js.map +function forEachStep (self, fn, node, thisp) { + var hit = node.value + if (isStale(self, hit)) { + del(self, node) + if (!self[ALLOW_STALE]) { + hit = undefined + } + } + if (hit) { + fn.call(thisp, hit.value, hit.key, self) + } +} +LRUCache.prototype.forEach = function (fn, thisp) { + thisp = thisp || this + for (var walker = this[LRU_LIST].head; walker !== null;) { + var next = walker.next + forEachStep(this, fn, walker, thisp) + walker = next + } +} -/***/ }), -/* 113 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +LRUCache.prototype.keys = function () { + return this[LRU_LIST].toArray().map(function (k) { + return k.key + }, this) +} -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return asap; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__AsapAction__ = __webpack_require__(266); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsapScheduler__ = __webpack_require__(268); -/** PURE_IMPORTS_START _AsapAction,_AsapScheduler PURE_IMPORTS_END */ +LRUCache.prototype.values = function () { + return this[LRU_LIST].toArray().map(function (k) { + return k.value + }, this) +} + +LRUCache.prototype.reset = function () { + if (this[DISPOSE] && + this[LRU_LIST] && + this[LRU_LIST].length) { + this[LRU_LIST].forEach(function (hit) { + this[DISPOSE](hit.key, hit.value) + }, this) + } + this[CACHE] = new Map() // hash of items by key + this[LRU_LIST] = new Yallist() // list of items in order of use recency + this[LENGTH] = 0 // length of items in the list +} -var asap = /*@__PURE__*/ new __WEBPACK_IMPORTED_MODULE_1__AsapScheduler__["a" /* AsapScheduler */](__WEBPACK_IMPORTED_MODULE_0__AsapAction__["a" /* AsapAction */]); -//# sourceMappingURL=asap.js.map +LRUCache.prototype.dump = function () { + return this[LRU_LIST].map(function (hit) { + if (!isStale(this, hit)) { + return { + k: hit.key, + v: hit.value, + e: hit.now + (hit.maxAge || 0) + } + } + }, this).toArray().filter(function (h) { + return h + }) +} +LRUCache.prototype.dumpLru = function () { + return this[LRU_LIST] +} -/***/ }), -/* 114 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +LRUCache.prototype.inspect = function (n, opts) { + var str = 'LRUCache {' + var extras = false -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return TimeoutError; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/** PURE_IMPORTS_START tslib PURE_IMPORTS_END */ + var as = this[ALLOW_STALE] + if (as) { + str += '\n allowStale: true' + extras = true + } -var TimeoutError = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](TimeoutError, _super); - function TimeoutError() { - var _this = _super.call(this, 'Timeout has occurred') || this; - _this.name = 'TimeoutError'; - Object.setPrototypeOf(_this, TimeoutError.prototype); - return _this; + var max = this[MAX] + if (max && max !== Infinity) { + if (extras) { + str += ',' } - return TimeoutError; -}(Error)); + str += '\n max: ' + util.inspect(max, opts) + extras = true + } -//# sourceMappingURL=TimeoutError.js.map + var maxAge = this[MAX_AGE] + if (maxAge) { + if (extras) { + str += ',' + } + str += '\n maxAge: ' + util.inspect(maxAge, opts) + extras = true + } + var lc = this[LENGTH_CALCULATOR] + if (lc && lc !== naiveLength) { + if (extras) { + str += ',' + } + str += '\n length: ' + util.inspect(this[LENGTH], opts) + extras = true + } -/***/ }), -/* 115 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + var didFirst = false + this[LRU_LIST].forEach(function (item) { + if (didFirst) { + str += ',\n ' + } else { + if (extras) { + str += ',\n' + } + didFirst = true + str += '\n ' + } + var key = util.inspect(item.key).split('\n').join('\n ') + var val = { value: item.value } + if (item.maxAge !== maxAge) { + val.maxAge = item.maxAge + } + if (lc !== naiveLength) { + val.length = item.length + } + if (isStale(this, item)) { + val.stale = true + } -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeTo; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__subscribeToArray__ = __webpack_require__(112); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__subscribeToPromise__ = __webpack_require__(116); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__subscribeToIterable__ = __webpack_require__(117); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__subscribeToObservable__ = __webpack_require__(118); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__isArrayLike__ = __webpack_require__(119); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__isPromise__ = __webpack_require__(120); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__isObject__ = __webpack_require__(103); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__symbol_iterator__ = __webpack_require__(34); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__symbol_observable__ = __webpack_require__(24); -/** PURE_IMPORTS_START _Observable,_subscribeToArray,_subscribeToPromise,_subscribeToIterable,_subscribeToObservable,_isArrayLike,_isPromise,_isObject,_symbol_iterator,_symbol_observable PURE_IMPORTS_END */ + val = util.inspect(val, opts).split('\n').join('\n ') + str += key + ' => ' + val + }) + if (didFirst || extras) { + str += '\n' + } + str += '}' + return str +} +LRUCache.prototype.set = function (key, value, maxAge) { + maxAge = maxAge || this[MAX_AGE] + var now = maxAge ? Date.now() : 0 + var len = this[LENGTH_CALCULATOR](value, key) + if (this[CACHE].has(key)) { + if (len > this[MAX]) { + del(this, this[CACHE].get(key)) + return false + } + var node = this[CACHE].get(key) + var item = node.value + // dispose of the old one before overwriting + // split out into 2 ifs for better coverage tracking + if (this[DISPOSE]) { + if (!this[NO_DISPOSE_ON_SET]) { + this[DISPOSE](key, item.value) + } + } + item.now = now + item.maxAge = maxAge + item.value = value + this[LENGTH] += len - item.length + item.length = len + this.get(key) + trim(this) + return true + } + var hit = new Entry(key, value, len, now, maxAge) -var subscribeTo = function (result) { - if (result instanceof __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */]) { - return function (subscriber) { - if (result._isScalar) { - subscriber.next(result.value); - subscriber.complete(); - return undefined; - } - else { - return result.subscribe(subscriber); - } - }; - } - else if (result && typeof result[__WEBPACK_IMPORTED_MODULE_9__symbol_observable__["a" /* observable */]] === 'function') { - return Object(__WEBPACK_IMPORTED_MODULE_4__subscribeToObservable__["a" /* subscribeToObservable */])(result); - } - else if (Object(__WEBPACK_IMPORTED_MODULE_5__isArrayLike__["a" /* isArrayLike */])(result)) { - return Object(__WEBPACK_IMPORTED_MODULE_1__subscribeToArray__["a" /* subscribeToArray */])(result); - } - else if (Object(__WEBPACK_IMPORTED_MODULE_6__isPromise__["a" /* isPromise */])(result)) { - return Object(__WEBPACK_IMPORTED_MODULE_2__subscribeToPromise__["a" /* subscribeToPromise */])(result); - } - else if (result && typeof result[__WEBPACK_IMPORTED_MODULE_8__symbol_iterator__["a" /* iterator */]] === 'function') { - return Object(__WEBPACK_IMPORTED_MODULE_3__subscribeToIterable__["a" /* subscribeToIterable */])(result); - } - else { - var value = Object(__WEBPACK_IMPORTED_MODULE_7__isObject__["a" /* isObject */])(result) ? 'an invalid object' : "'" + result + "'"; - var msg = "You provided " + value + " where a stream was expected." - + ' You can provide an Observable, Promise, Array, or Iterable.'; - throw new TypeError(msg); + // oversized objects fall out of cache automatically. + if (hit.length > this[MAX]) { + if (this[DISPOSE]) { + this[DISPOSE](key, value) } -}; -//# sourceMappingURL=subscribeTo.js.map + return false + } + this[LENGTH] += hit.length + this[LRU_LIST].unshift(hit) + this[CACHE].set(key, this[LRU_LIST].head) + trim(this) + return true +} -/***/ }), -/* 116 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +LRUCache.prototype.has = function (key) { + if (!this[CACHE].has(key)) return false + var hit = this[CACHE].get(key).value + if (isStale(this, hit)) { + return false + } + return true +} -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToPromise; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__hostReportError__ = __webpack_require__(61); -/** PURE_IMPORTS_START _hostReportError PURE_IMPORTS_END */ +LRUCache.prototype.get = function (key) { + return get(this, key, true) +} -var subscribeToPromise = function (promise) { - return function (subscriber) { - promise.then(function (value) { - if (!subscriber.closed) { - subscriber.next(value); - subscriber.complete(); - } - }, function (err) { return subscriber.error(err); }) - .then(null, __WEBPACK_IMPORTED_MODULE_0__hostReportError__["a" /* hostReportError */]); - return subscriber; - }; -}; -//# sourceMappingURL=subscribeToPromise.js.map +LRUCache.prototype.peek = function (key) { + return get(this, key, false) +} +LRUCache.prototype.pop = function () { + var node = this[LRU_LIST].tail + if (!node) return null + del(this, node) + return node.value +} -/***/ }), -/* 117 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +LRUCache.prototype.del = function (key) { + del(this, this[CACHE].get(key)) +} -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToIterable; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__symbol_iterator__ = __webpack_require__(34); -/** PURE_IMPORTS_START _symbol_iterator PURE_IMPORTS_END */ +LRUCache.prototype.load = function (arr) { + // reset the cache + this.reset() -var subscribeToIterable = function (iterable) { - return function (subscriber) { - var iterator = iterable[__WEBPACK_IMPORTED_MODULE_0__symbol_iterator__["a" /* iterator */]](); - do { - var item = iterator.next(); - if (item.done) { - subscriber.complete(); - break; - } - subscriber.next(item.value); - if (subscriber.closed) { - break; - } - } while (true); - if (typeof iterator.return === 'function') { - subscriber.add(function () { - if (iterator.return) { - iterator.return(); - } - }); - } - return subscriber; - }; -}; -//# sourceMappingURL=subscribeToIterable.js.map + var now = Date.now() + // A previous serialized cache has the most recent items first + for (var l = arr.length - 1; l >= 0; l--) { + var hit = arr[l] + var expiresAt = hit.e || 0 + if (expiresAt === 0) { + // the item was created without expiration in a non aged cache + this.set(hit.k, hit.v) + } else { + var maxAge = expiresAt - now + // dont add already expired items + if (maxAge > 0) { + this.set(hit.k, hit.v, maxAge) + } + } + } +} + +LRUCache.prototype.prune = function () { + var self = this + this[CACHE].forEach(function (value, key) { + get(self, key, false) + }) +} + +function get (self, key, doUse) { + var node = self[CACHE].get(key) + if (node) { + var hit = node.value + if (isStale(self, hit)) { + del(self, node) + if (!self[ALLOW_STALE]) hit = undefined + } else { + if (doUse) { + self[LRU_LIST].unshiftNode(node) + } + } + if (hit) hit = hit.value + } + return hit +} +function isStale (self, hit) { + if (!hit || (!hit.maxAge && !self[MAX_AGE])) { + return false + } + var stale = false + var diff = Date.now() - hit.now + if (hit.maxAge) { + stale = diff > hit.maxAge + } else { + stale = self[MAX_AGE] && (diff > self[MAX_AGE]) + } + return stale +} -/***/ }), -/* 118 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +function trim (self) { + if (self[LENGTH] > self[MAX]) { + for (var walker = self[LRU_LIST].tail; + self[LENGTH] > self[MAX] && walker !== null;) { + // We know that we're about to delete this one, and also + // what the next least recently used key will be, so just + // go ahead and set it now. + var prev = walker.prev + del(self, walker) + walker = prev + } + } +} -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return subscribeToObservable; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__symbol_observable__ = __webpack_require__(24); -/** PURE_IMPORTS_START _symbol_observable PURE_IMPORTS_END */ +function del (self, node) { + if (node) { + var hit = node.value + if (self[DISPOSE]) { + self[DISPOSE](hit.key, hit.value) + } + self[LENGTH] -= hit.length + self[CACHE].delete(hit.key) + self[LRU_LIST].removeNode(node) + } +} -var subscribeToObservable = function (obj) { - return function (subscriber) { - var obs = obj[__WEBPACK_IMPORTED_MODULE_0__symbol_observable__["a" /* observable */]](); - if (typeof obs.subscribe !== 'function') { - throw new TypeError('Provided object does not correctly implement Symbol.observable'); - } - else { - return obs.subscribe(subscriber); - } - }; -}; -//# sourceMappingURL=subscribeToObservable.js.map +// classy, since V8 prefers predictable objects. +function Entry (key, value, length, now, maxAge) { + this.key = key + this.value = value + this.length = length + this.now = now + this.maxAge = maxAge || 0 +} /***/ }), -/* 119 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 109 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return isArrayLike; }); -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -var isArrayLike = (function (x) { return x && typeof x.length === 'number' && typeof x !== 'function'; }); -//# sourceMappingURL=isArrayLike.js.map -/***/ }), -/* 120 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +function escapeArgument(arg, quote) { + // Convert to string + arg = '' + arg; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isPromise; -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function isPromise(value) { - return value && typeof value.subscribe !== 'function' && typeof value.then === 'function'; -} -//# sourceMappingURL=isPromise.js.map + // If we are not going to quote the argument, + // escape shell metacharacters, including double and single quotes: + if (!quote) { + arg = arg.replace(/([()%!^<>&|;,"'\s])/g, '^$1'); + } else { + // Sequence of backslashes followed by a double quote: + // double up all the backslashes and escape the double quote + arg = arg.replace(/(\\*)"/g, '$1$1\\"'); + // Sequence of backslashes followed by the end of the string + // (which will become a double quote later): + // double up all the backslashes + arg = arg.replace(/(\\*)$/, '$1$1'); -/***/ }), -/* 121 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + // All other backslashes occur literally -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = concatAll; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__mergeAll__ = __webpack_require__(70); -/** PURE_IMPORTS_START _mergeAll PURE_IMPORTS_END */ + // Quote the whole thing: + arg = '"' + arg + '"'; + } -function concatAll() { - return Object(__WEBPACK_IMPORTED_MODULE_0__mergeAll__["a" /* mergeAll */])(1); + return arg; } -//# sourceMappingURL=concatAll.js.map + +module.exports = escapeArgument; /***/ }), -/* 122 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 110 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = merge; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_isScheduler__ = __webpack_require__(14); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__operators_mergeAll__ = __webpack_require__(70); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__fromArray__ = __webpack_require__(20); -/** PURE_IMPORTS_START _Observable,_util_isScheduler,_operators_mergeAll,_fromArray PURE_IMPORTS_END */ +const chalk = __webpack_require__(201); +const isSupported = process.platform !== 'win32' || process.env.CI || process.env.TERM === 'xterm-256color'; +const main = { + info: chalk.blue('ℹ'), + success: chalk.green('✔'), + warning: chalk.yellow('⚠'), + error: chalk.red('✖') +}; -function merge() { - var observables = []; - for (var _i = 0; _i < arguments.length; _i++) { - observables[_i] = arguments[_i]; - } - var concurrent = Number.POSITIVE_INFINITY; - var scheduler = null; - var last = observables[observables.length - 1]; - if (Object(__WEBPACK_IMPORTED_MODULE_1__util_isScheduler__["a" /* isScheduler */])(last)) { - scheduler = observables.pop(); - if (observables.length > 1 && typeof observables[observables.length - 1] === 'number') { - concurrent = observables.pop(); - } - } - else if (typeof last === 'number') { - concurrent = observables.pop(); - } - if (scheduler === null && observables.length === 1 && observables[0] instanceof __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */]) { - return observables[0]; - } - return Object(__WEBPACK_IMPORTED_MODULE_2__operators_mergeAll__["a" /* mergeAll */])(concurrent)(Object(__WEBPACK_IMPORTED_MODULE_3__fromArray__["a" /* fromArray */])(observables, scheduler)); -} -//# sourceMappingURL=merge.js.map +const fallbacks = { + info: chalk.blue('i'), + success: chalk.green('√'), + warning: chalk.yellow('‼'), + error: chalk.red('×') +}; + +module.exports = isSupported ? main : fallbacks; /***/ }), -/* 123 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 111 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return NEVER; }); -/* harmony export (immutable) */ __webpack_exports__["b"] = never; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_noop__ = __webpack_require__(43); -/** PURE_IMPORTS_START _Observable,_util_noop PURE_IMPORTS_END */ - +// Copyright IBM Corp. 2014,2018. All Rights Reserved. +// Node module: strong-log-transformer +// This file is licensed under the Apache License 2.0. +// License text available at https://opensource.org/licenses/Apache-2.0 -var NEVER = /*@__PURE__*/ new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](__WEBPACK_IMPORTED_MODULE_1__util_noop__["a" /* noop */]); -function never() { - return NEVER; -} -//# sourceMappingURL=never.js.map -/***/ }), -/* 124 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var stream = __webpack_require__(41); +var util = __webpack_require__(19); +var fs = __webpack_require__(16); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = race; -/* unused harmony export RaceOperator */ -/* unused harmony export RaceSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__fromArray__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_util_isArray,_fromArray,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +var byline = __webpack_require__(207); +var through = __webpack_require__(209); +var duplexer = __webpack_require__(210); +module.exports = Logger; +Logger.DEFAULTS = { + format: 'text', + tag: '', + mergeMultiline: false, + timeStamp: false, +}; +var formatters = { + text: textFormatter, + json: jsonFormatter, +} +function Logger(options) { + var defaults = JSON.parse(JSON.stringify(Logger.DEFAULTS)); + options = util._extend(defaults, options || {}); + var catcher = new byline.LineStream; + var emitter = catcher; + var transforms = [ + objectifier(), + ]; -function race() { - var observables = []; - for (var _i = 0; _i < arguments.length; _i++) { - observables[_i] = arguments[_i]; - } - if (observables.length === 1) { - if (Object(__WEBPACK_IMPORTED_MODULE_1__util_isArray__["a" /* isArray */])(observables[0])) { - observables = observables[0]; - } - else { - return observables[0]; - } - } - return Object(__WEBPACK_IMPORTED_MODULE_2__fromArray__["a" /* fromArray */])(observables, undefined).lift(new RaceOperator()); -} -var RaceOperator = /*@__PURE__*/ (function () { - function RaceOperator() { - } - RaceOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new RaceSubscriber(subscriber)); - }; - return RaceOperator; -}()); + if (options.tag) { + transforms.push(staticTagger(options.tag)); + } -var RaceSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](RaceSubscriber, _super); - function RaceSubscriber(destination) { - var _this = _super.call(this, destination) || this; - _this.hasFirst = false; - _this.observables = []; - _this.subscriptions = []; - return _this; - } - RaceSubscriber.prototype._next = function (observable) { - this.observables.push(observable); - }; - RaceSubscriber.prototype._complete = function () { - var observables = this.observables; - var len = observables.length; - if (len === 0) { - this.destination.complete(); - } - else { - for (var i = 0; i < len && !this.hasFirst; i++) { - var observable = observables[i]; - var subscription = Object(__WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__["a" /* subscribeToResult */])(this, observable, observable, i); - if (this.subscriptions) { - this.subscriptions.push(subscription); - } - this.add(subscription); - } - this.observables = null; - } - }; - RaceSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - if (!this.hasFirst) { - this.hasFirst = true; - for (var i = 0; i < this.subscriptions.length; i++) { - if (i !== outerIndex) { - var subscription = this.subscriptions[i]; - subscription.unsubscribe(); - this.remove(subscription); - } - } - this.subscriptions = null; - } - this.destination.next(innerValue); - }; - return RaceSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__["a" /* OuterSubscriber */])); + if (options.mergeMultiline) { + transforms.push(lineMerger()); + } -//# sourceMappingURL=race.js.map + // TODO + // if (options.pidStamp) { + // transforms.push(pidStamper(options.pid)); + // } + // TODO + // if (options.workerStamp) { + // transforms.push(workerStamper(options.worker)); + // } -/***/ }), -/* 125 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + transforms.push(formatters[options.format](options)); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = timer; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isNumeric__ = __webpack_require__(48); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_isScheduler__ = __webpack_require__(14); -/** PURE_IMPORTS_START _Observable,_scheduler_async,_util_isNumeric,_util_isScheduler PURE_IMPORTS_END */ + // restore line endings that were removed by byline + transforms.push(reLiner()); + for (var t in transforms) { + emitter = emitter.pipe(transforms[t]); + } + return duplexer(catcher, emitter); +} +function reLiner() { + return through(appendNewline); -function timer(dueTime, periodOrScheduler, scheduler) { - if (dueTime === void 0) { - dueTime = 0; - } - var period = -1; - if (Object(__WEBPACK_IMPORTED_MODULE_2__util_isNumeric__["a" /* isNumeric */])(periodOrScheduler)) { - period = Number(periodOrScheduler) < 1 && 1 || Number(periodOrScheduler); + function appendNewline(line) { + this.emit('data', line + '\n'); + } +} + +function objectifier() { + return through(objectify, null, {autoDestroy: false}); + + function objectify(line) { + this.emit('data', { + msg: line, + time: Date.now(), + }); + } +} + +function staticTagger(tag) { + return through(tagger); + + function tagger(logEvent) { + logEvent.tag = tag; + this.emit('data', logEvent); + } +} + +function textFormatter(options) { + return through(textify); + + function textify(logEvent) { + var line = util.format('%s%s', textifyTags(logEvent.tag), + logEvent.msg.toString()); + if (options.timeStamp) { + line = util.format('%s %s', new Date(logEvent.time).toISOString(), line); } - else if (Object(__WEBPACK_IMPORTED_MODULE_3__util_isScheduler__["a" /* isScheduler */])(periodOrScheduler)) { - scheduler = periodOrScheduler; + this.emit('data', line.replace(/\n/g, '\\n')); + } + + function textifyTags(tags) { + var str = ''; + if (typeof tags === 'string') { + str = tags + ' '; + } else if (typeof tags === 'object') { + for (var t in tags) { + str += t + ':' + tags[t] + ' '; + } } - if (!Object(__WEBPACK_IMPORTED_MODULE_3__util_isScheduler__["a" /* isScheduler */])(scheduler)) { - scheduler = __WEBPACK_IMPORTED_MODULE_1__scheduler_async__["a" /* async */]; + return str; + } +} + +function jsonFormatter(options) { + return through(jsonify); + + function jsonify(logEvent) { + if (options.timeStamp) { + logEvent.time = new Date(logEvent.time).toISOString(); + } else { + delete logEvent.time; } - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var due = Object(__WEBPACK_IMPORTED_MODULE_2__util_isNumeric__["a" /* isNumeric */])(dueTime) - ? dueTime - : (+dueTime - scheduler.now()); - return scheduler.schedule(dispatch, due, { - index: 0, period: period, subscriber: subscriber - }); - }); + logEvent.msg = logEvent.msg.toString(); + this.emit('data', JSON.stringify(logEvent)); + } } -function dispatch(state) { - var index = state.index, period = state.period, subscriber = state.subscriber; - subscriber.next(index); - if (subscriber.closed) { - return; + +function lineMerger(host) { + var previousLine = null; + var flushTimer = null; + var stream = through(lineMergerWrite, lineMergerEnd); + var flush = _flush.bind(stream); + + return stream; + + function lineMergerWrite(line) { + if (/^\s+/.test(line.msg)) { + if (previousLine) { + previousLine.msg += '\n' + line.msg; + } else { + previousLine = line; + } + } else { + flush(); + previousLine = line; } - else if (period === -1) { - return subscriber.complete(); + // rolling timeout + clearTimeout(flushTimer); + flushTimer = setTimeout(flush.bind(this), 10); + } + + function _flush() { + if (previousLine) { + this.emit('data', previousLine); + previousLine = null; } - state.index = index + 1; - this.schedule(state, period); + } + + function lineMergerEnd() { + flush.call(this); + this.emit('end'); + } } -//# sourceMappingURL=timer.js.map /***/ }), -/* 126 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 112 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = audit; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - - +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.copyWorkspacePackages = exports.workspacePackagePaths = undefined; -function audit(durationSelector) { - return function auditOperatorFunction(source) { - return source.lift(new AuditOperator(durationSelector)); - }; -} -var AuditOperator = /*@__PURE__*/ (function () { - function AuditOperator(durationSelector) { - this.durationSelector = durationSelector; - } - AuditOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new AuditSubscriber(subscriber, this.durationSelector)); - }; - return AuditOperator; -}()); -var AuditSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AuditSubscriber, _super); - function AuditSubscriber(destination, durationSelector) { - var _this = _super.call(this, destination) || this; - _this.durationSelector = durationSelector; - _this.hasValue = false; - return _this; - } - AuditSubscriber.prototype._next = function (value) { - this.value = value; - this.hasValue = true; - if (!this.throttled) { - var duration = Object(__WEBPACK_IMPORTED_MODULE_1__util_tryCatch__["a" /* tryCatch */])(this.durationSelector)(value); - if (duration === __WEBPACK_IMPORTED_MODULE_2__util_errorObject__["a" /* errorObject */]) { - this.destination.error(__WEBPACK_IMPORTED_MODULE_2__util_errorObject__["a" /* errorObject */].e); - } - else { - var innerSubscription = Object(__WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__["a" /* subscribeToResult */])(this, duration); - if (!innerSubscription || innerSubscription.closed) { - this.clearThrottle(); - } - else { - this.add(this.throttled = innerSubscription); - } - } +let workspacePackagePaths = exports.workspacePackagePaths = (() => { + var _ref = _asyncToGenerator(function* (rootPath) { + const rootPkgJson = yield (0, _package_json.readPackageJson)(_path2.default.join(rootPath, 'package.json')); + if (!rootPkgJson.workspaces) { + return []; } - }; - AuditSubscriber.prototype.clearThrottle = function () { - var _a = this, value = _a.value, hasValue = _a.hasValue, throttled = _a.throttled; - if (throttled) { - this.remove(throttled); - this.throttled = null; - throttled.unsubscribe(); + const workspacesPathsPatterns = rootPkgJson.workspaces.packages; + let workspaceProjectsPaths = []; + for (const pattern of workspacesPathsPatterns) { + workspaceProjectsPaths = workspaceProjectsPaths.concat((yield packagesFromGlobPattern({ pattern, rootPath }))); } - if (hasValue) { - this.value = null; - this.hasValue = false; - this.destination.next(value); + // Filter out exclude glob patterns + for (const pattern of workspacesPathsPatterns) { + if (pattern.startsWith('!')) { + const pathToRemove = _path2.default.join(rootPath, pattern.slice(1), 'package.json'); + workspaceProjectsPaths = workspaceProjectsPaths.filter(function (p) { + return p !== pathToRemove; + }); + } } + return workspaceProjectsPaths; + }); + + return function workspacePackagePaths(_x) { + return _ref.apply(this, arguments); }; - AuditSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex) { - this.clearThrottle(); +})(); + +let copyWorkspacePackages = exports.copyWorkspacePackages = (() => { + var _ref2 = _asyncToGenerator(function* (rootPath) { + const workspaceProjects = yield getWorkspaceProjects(rootPath); + for (const project of workspaceProjects.values()) { + const dest = _path2.default.resolve(rootPath, 'node_modules', project.name); + // Remove the symlink + yield (0, _fs.unlink)(dest); + // Copy in the package + yield (0, _fs.copyDirectory)(project.path, dest); + } + }); + + return function copyWorkspacePackages(_x2) { + return _ref2.apply(this, arguments); }; - AuditSubscriber.prototype.notifyComplete = function () { - this.clearThrottle(); +})(); + +let getWorkspaceProjects = (() => { + var _ref3 = _asyncToGenerator(function* (rootPath) { + const projectPaths = (0, _config.getProjectPaths)(rootPath, {}); + const projects = yield (0, _projects.getProjects)(rootPath, projectPaths); + for (const [key, project] of projects.entries()) { + if (!project.isWorkspaceProject) { + projects.delete(key); + } + } + return projects; + }); + + return function getWorkspaceProjects(_x3) { + return _ref3.apply(this, arguments); }; - return AuditSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=audit.js.map +})(); + +var _glob = __webpack_require__(43); +var _glob2 = _interopRequireDefault(_glob); -/***/ }), -/* 127 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var _path = __webpack_require__(7); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = concatMap; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__mergeMap__ = __webpack_require__(35); -/** PURE_IMPORTS_START _mergeMap PURE_IMPORTS_END */ +var _path2 = _interopRequireDefault(_path); -function concatMap(project, resultSelector) { - return Object(__WEBPACK_IMPORTED_MODULE_0__mergeMap__["a" /* mergeMap */])(project, resultSelector, 1); -} -//# sourceMappingURL=concatMap.js.map +var _util = __webpack_require__(19); +var _config = __webpack_require__(91); -/***/ }), -/* 128 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var _fs = __webpack_require__(60); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isDate; -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function isDate(value) { - return value instanceof Date && !isNaN(+value); -} -//# sourceMappingURL=isDate.js.map +var _package_json = __webpack_require__(62); + +var _projects = __webpack_require__(42); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* + * 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. + */ + + +const glob = (0, _util.promisify)(_glob2.default); +function packagesFromGlobPattern({ pattern, rootPath }) { + const globOptions = { + cwd: rootPath, + // Should throw in case of unusual errors when reading the file system + strict: true, + // Always returns absolute paths for matched files + absolute: true, + // Do not match ** against multiple filenames + // (This is only specified because we currently don't have a need for it.) + noglobstar: true + }; + return glob(_path2.default.join(pattern, 'package.json'), globOptions); +} /***/ }), -/* 129 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 113 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = distinctUntilChanged; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_errorObject__ = __webpack_require__(13); -/** PURE_IMPORTS_START tslib,_Subscriber,_util_tryCatch,_util_errorObject PURE_IMPORTS_END */ +const path = __webpack_require__(7); +const globby = __webpack_require__(215); +const isPathCwd = __webpack_require__(219); +const isPathInCwd = __webpack_require__(220); +const pify = __webpack_require__(44); +const rimraf = __webpack_require__(223); +const pMap = __webpack_require__(224); +const rimrafP = pify(rimraf); +function safeCheck(file) { + if (isPathCwd(file)) { + throw new Error('Cannot delete the current working directory. Can be overriden with the `force` option.'); + } -function distinctUntilChanged(compare, keySelector) { - return function (source) { return source.lift(new DistinctUntilChangedOperator(compare, keySelector)); }; + if (!isPathInCwd(file)) { + throw new Error('Cannot delete files/folders outside the current working directory. Can be overriden with the `force` option.'); + } } -var DistinctUntilChangedOperator = /*@__PURE__*/ (function () { - function DistinctUntilChangedOperator(compare, keySelector) { - this.compare = compare; - this.keySelector = keySelector; - } - DistinctUntilChangedOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new DistinctUntilChangedSubscriber(subscriber, this.compare, this.keySelector)); - }; - return DistinctUntilChangedOperator; -}()); -var DistinctUntilChangedSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](DistinctUntilChangedSubscriber, _super); - function DistinctUntilChangedSubscriber(destination, compare, keySelector) { - var _this = _super.call(this, destination) || this; - _this.keySelector = keySelector; - _this.hasKey = false; - if (typeof compare === 'function') { - _this.compare = compare; - } - return _this; - } - DistinctUntilChangedSubscriber.prototype.compare = function (x, y) { - return x === y; - }; - DistinctUntilChangedSubscriber.prototype._next = function (value) { - var keySelector = this.keySelector; - var key = value; - if (keySelector) { - key = Object(__WEBPACK_IMPORTED_MODULE_2__util_tryCatch__["a" /* tryCatch */])(this.keySelector)(value); - if (key === __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */]) { - return this.destination.error(__WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */].e); - } - } - var result = false; - if (this.hasKey) { - result = Object(__WEBPACK_IMPORTED_MODULE_2__util_tryCatch__["a" /* tryCatch */])(this.compare)(this.key, key); - if (result === __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */]) { - return this.destination.error(__WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */].e); - } - } - else { - this.hasKey = true; - } - if (Boolean(result) === false) { - this.key = key; - this.destination.next(value); - } - }; - return DistinctUntilChangedSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=distinctUntilChanged.js.map +module.exports = (patterns, opts) => { + opts = Object.assign({}, opts); -/***/ }), -/* 130 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + const force = opts.force; + delete opts.force; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = tap; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_noop__ = __webpack_require__(43); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_isFunction__ = __webpack_require__(29); -/** PURE_IMPORTS_START tslib,_Subscriber,_util_noop,_util_isFunction PURE_IMPORTS_END */ + const dryRun = opts.dryRun; + delete opts.dryRun; + const mapper = file => { + if (!force) { + safeCheck(file); + } + file = path.resolve(opts.cwd || '', file); + if (dryRun) { + return file; + } -function tap(nextOrObserver, error, complete) { - return function tapOperatorFunction(source) { - return source.lift(new DoOperator(nextOrObserver, error, complete)); - }; -} -var DoOperator = /*@__PURE__*/ (function () { - function DoOperator(nextOrObserver, error, complete) { - this.nextOrObserver = nextOrObserver; - this.error = error; - this.complete = complete; - } - DoOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new TapSubscriber(subscriber, this.nextOrObserver, this.error, this.complete)); - }; - return DoOperator; -}()); -var TapSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](TapSubscriber, _super); - function TapSubscriber(destination, observerOrNext, error, complete) { - var _this = _super.call(this, destination) || this; - _this._tapNext = __WEBPACK_IMPORTED_MODULE_2__util_noop__["a" /* noop */]; - _this._tapError = __WEBPACK_IMPORTED_MODULE_2__util_noop__["a" /* noop */]; - _this._tapComplete = __WEBPACK_IMPORTED_MODULE_2__util_noop__["a" /* noop */]; - _this._tapError = error || __WEBPACK_IMPORTED_MODULE_2__util_noop__["a" /* noop */]; - _this._tapComplete = complete || __WEBPACK_IMPORTED_MODULE_2__util_noop__["a" /* noop */]; - if (Object(__WEBPACK_IMPORTED_MODULE_3__util_isFunction__["a" /* isFunction */])(observerOrNext)) { - _this._context = _this; - _this._tapNext = observerOrNext; - } - else if (observerOrNext) { - _this._context = observerOrNext; - _this._tapNext = observerOrNext.next || __WEBPACK_IMPORTED_MODULE_2__util_noop__["a" /* noop */]; - _this._tapError = observerOrNext.error || __WEBPACK_IMPORTED_MODULE_2__util_noop__["a" /* noop */]; - _this._tapComplete = observerOrNext.complete || __WEBPACK_IMPORTED_MODULE_2__util_noop__["a" /* noop */]; - } - return _this; - } - TapSubscriber.prototype._next = function (value) { - try { - this._tapNext.call(this._context, value); - } - catch (err) { - this.destination.error(err); - return; - } - this.destination.next(value); - }; - TapSubscriber.prototype._error = function (err) { - try { - this._tapError.call(this._context, err); - } - catch (err) { - this.destination.error(err); - return; - } - this.destination.error(err); - }; - TapSubscriber.prototype._complete = function () { - try { - this._tapComplete.call(this._context); - } - catch (err) { - this.destination.error(err); - return; - } - return this.destination.complete(); - }; - return TapSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=tap.js.map + return rimrafP(file, {glob: false}).then(() => file); + }; + return globby(patterns, opts).then(files => pMap(files, mapper, opts)); +}; -/***/ }), -/* 131 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +module.exports.sync = (patterns, opts) => { + opts = Object.assign({}, opts); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["b"] = find; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return FindValueOperator; }); -/* unused harmony export FindValueSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ + const force = opts.force; + delete opts.force; + const dryRun = opts.dryRun; + delete opts.dryRun; -function find(predicate, thisArg) { - if (typeof predicate !== 'function') { - throw new TypeError('predicate is not a function'); - } - return function (source) { return source.lift(new FindValueOperator(predicate, source, false, thisArg)); }; -} -var FindValueOperator = /*@__PURE__*/ (function () { - function FindValueOperator(predicate, source, yieldIndex, thisArg) { - this.predicate = predicate; - this.source = source; - this.yieldIndex = yieldIndex; - this.thisArg = thisArg; - } - FindValueOperator.prototype.call = function (observer, source) { - return source.subscribe(new FindValueSubscriber(observer, this.predicate, this.source, this.yieldIndex, this.thisArg)); - }; - return FindValueOperator; -}()); + return globby.sync(patterns, opts).map(file => { + if (!force) { + safeCheck(file); + } -var FindValueSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](FindValueSubscriber, _super); - function FindValueSubscriber(destination, predicate, source, yieldIndex, thisArg) { - var _this = _super.call(this, destination) || this; - _this.predicate = predicate; - _this.source = source; - _this.yieldIndex = yieldIndex; - _this.thisArg = thisArg; - _this.index = 0; - return _this; - } - FindValueSubscriber.prototype.notifyComplete = function (value) { - var destination = this.destination; - destination.next(value); - destination.complete(); - }; - FindValueSubscriber.prototype._next = function (value) { - var _a = this, predicate = _a.predicate, thisArg = _a.thisArg; - var index = this.index++; - try { - var result = predicate.call(thisArg || this, value, index, this.source); - if (result) { - this.notifyComplete(this.yieldIndex ? index : value); - } - } - catch (err) { - this.destination.error(err); - } - }; - FindValueSubscriber.prototype._complete = function () { - this.notifyComplete(this.yieldIndex ? -1 : undefined); - }; - return FindValueSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); + file = path.resolve(opts.cwd || '', file); -//# sourceMappingURL=find.js.map + if (!dryRun) { + rimraf.sync(file, {glob: false}); + } + + return file; + }); +}; /***/ }), -/* 132 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 114 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return defaultThrottleConfig; }); -/* harmony export (immutable) */ __webpack_exports__["b"] = throttle; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +module.exports = typeof Promise === 'function' ? Promise : __webpack_require__(216); -var defaultThrottleConfig = { - leading: true, - trailing: false + +/***/ }), +/* 115 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +var arrayUniq = __webpack_require__(217); + +module.exports = function () { + return arrayUniq([].concat.apply([], arguments)); }; -function throttle(durationSelector, config) { - if (config === void 0) { - config = defaultThrottleConfig; - } - return function (source) { return source.lift(new ThrottleOperator(durationSelector, config.leading, config.trailing)); }; -} -var ThrottleOperator = /*@__PURE__*/ (function () { - function ThrottleOperator(durationSelector, leading, trailing) { - this.durationSelector = durationSelector; - this.leading = leading; - this.trailing = trailing; - } - ThrottleOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new ThrottleSubscriber(subscriber, this.durationSelector, this.leading, this.trailing)); - }; - return ThrottleOperator; -}()); -var ThrottleSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ThrottleSubscriber, _super); - function ThrottleSubscriber(destination, durationSelector, _leading, _trailing) { - var _this = _super.call(this, destination) || this; - _this.destination = destination; - _this.durationSelector = durationSelector; - _this._leading = _leading; - _this._trailing = _trailing; - _this._hasValue = false; - return _this; - } - ThrottleSubscriber.prototype._next = function (value) { - this._hasValue = true; - this._sendValue = value; - if (!this._throttled) { - if (this._leading) { - this.send(); - } - else { - this.throttle(value); - } - } - }; - ThrottleSubscriber.prototype.send = function () { - var _a = this, _hasValue = _a._hasValue, _sendValue = _a._sendValue; - if (_hasValue) { - this.destination.next(_sendValue); - this.throttle(_sendValue); - } - this._hasValue = false; - this._sendValue = null; - }; - ThrottleSubscriber.prototype.throttle = function (value) { - var duration = this.tryDurationSelector(value); - if (duration) { - this.add(this._throttled = Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(this, duration)); - } - }; - ThrottleSubscriber.prototype.tryDurationSelector = function (value) { - try { - return this.durationSelector(value); - } - catch (err) { - this.destination.error(err); - return null; - } - }; - ThrottleSubscriber.prototype.throttlingDone = function () { - var _a = this, _throttled = _a._throttled, _trailing = _a._trailing; - if (_throttled) { - _throttled.unsubscribe(); - } - this._throttled = null; - if (_trailing) { - this.send(); - } - }; - ThrottleSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.throttlingDone(); - }; - ThrottleSubscriber.prototype.notifyComplete = function () { - this.throttlingDone(); - }; - return ThrottleSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=throttle.js.map /***/ }), -/* 133 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 116 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = timeoutWith; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isDate__ = __webpack_require__(128); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_scheduler_async,_util_isDate,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +/* +object-assign +(c) Sindre Sorhus +@license MIT +*/ +/* eslint-disable no-unused-vars */ +var getOwnPropertySymbols = Object.getOwnPropertySymbols; +var hasOwnProperty = Object.prototype.hasOwnProperty; +var propIsEnumerable = Object.prototype.propertyIsEnumerable; +function toObject(val) { + if (val === null || val === undefined) { + throw new TypeError('Object.assign cannot be called with null or undefined'); + } + return Object(val); +} -function timeoutWith(due, withObservable, scheduler) { - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_1__scheduler_async__["a" /* async */]; - } - return function (source) { - var absoluteTimeout = Object(__WEBPACK_IMPORTED_MODULE_2__util_isDate__["a" /* isDate */])(due); - var waitFor = absoluteTimeout ? (+due - scheduler.now()) : Math.abs(due); - return source.lift(new TimeoutWithOperator(waitFor, absoluteTimeout, withObservable, scheduler)); - }; +function shouldUseNative() { + try { + if (!Object.assign) { + return false; + } + + // Detect buggy property enumeration order in older V8 versions. + + // https://bugs.chromium.org/p/v8/issues/detail?id=4118 + var test1 = new String('abc'); // eslint-disable-line no-new-wrappers + test1[5] = 'de'; + if (Object.getOwnPropertyNames(test1)[0] === '5') { + return false; + } + + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test2 = {}; + for (var i = 0; i < 10; i++) { + test2['_' + String.fromCharCode(i)] = i; + } + var order2 = Object.getOwnPropertyNames(test2).map(function (n) { + return test2[n]; + }); + if (order2.join('') !== '0123456789') { + return false; + } + + // https://bugs.chromium.org/p/v8/issues/detail?id=3056 + var test3 = {}; + 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { + test3[letter] = letter; + }); + if (Object.keys(Object.assign({}, test3)).join('') !== + 'abcdefghijklmnopqrst') { + return false; + } + + return true; + } catch (err) { + // We don't expect any of the above to throw, but better to be safe. + return false; + } } -var TimeoutWithOperator = /*@__PURE__*/ (function () { - function TimeoutWithOperator(waitFor, absoluteTimeout, withObservable, scheduler) { - this.waitFor = waitFor; - this.absoluteTimeout = absoluteTimeout; - this.withObservable = withObservable; - this.scheduler = scheduler; - } - TimeoutWithOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new TimeoutWithSubscriber(subscriber, this.absoluteTimeout, this.waitFor, this.withObservable, this.scheduler)); - }; - return TimeoutWithOperator; -}()); -var TimeoutWithSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](TimeoutWithSubscriber, _super); - function TimeoutWithSubscriber(destination, absoluteTimeout, waitFor, withObservable, scheduler) { - var _this = _super.call(this, destination) || this; - _this.absoluteTimeout = absoluteTimeout; - _this.waitFor = waitFor; - _this.withObservable = withObservable; - _this.scheduler = scheduler; - _this.action = null; - _this.scheduleTimeout(); - return _this; - } - TimeoutWithSubscriber.dispatchTimeout = function (subscriber) { - var withObservable = subscriber.withObservable; - subscriber._unsubscribeAndRecycle(); - subscriber.add(Object(__WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__["a" /* subscribeToResult */])(subscriber, withObservable)); - }; - TimeoutWithSubscriber.prototype.scheduleTimeout = function () { - var action = this.action; - if (action) { - this.action = action.schedule(this, this.waitFor); - } - else { - this.add(this.action = this.scheduler.schedule(TimeoutWithSubscriber.dispatchTimeout, this.waitFor, this)); - } - }; - TimeoutWithSubscriber.prototype._next = function (value) { - if (!this.absoluteTimeout) { - this.scheduleTimeout(); - } - _super.prototype._next.call(this, value); - }; - TimeoutWithSubscriber.prototype._unsubscribe = function () { - this.action = null; - this.scheduler = null; - this.withObservable = null; - }; - return TimeoutWithSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=timeoutWith.js.map + +module.exports = shouldUseNative() ? Object.assign : function (target, source) { + var from; + var to = toObject(target); + var symbols; + + for (var s = 1; s < arguments.length; s++) { + from = Object(arguments[s]); + + for (var key in from) { + if (hasOwnProperty.call(from, key)) { + to[key] = from[key]; + } + } + + if (getOwnPropertySymbols) { + symbols = getOwnPropertySymbols(from); + for (var i = 0; i < symbols.length; i++) { + if (propIsEnumerable.call(from, symbols[i])) { + to[symbols[i]] = from[symbols[i]]; + } + } + } + } + + return to; +}; /***/ }), -/* 134 */ +/* 117 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const NestedError = __webpack_require__(135); +const NestedError = __webpack_require__(118); class CpFileError extends NestedError { constructor(message, nested) { @@ -10943,10 +10438,10 @@ module.exports = CpFileError; /***/ }), -/* 135 */ +/* 118 */ /***/ (function(module, exports, __webpack_require__) { -var inherits = __webpack_require__(82); +var inherits = __webpack_require__(97); var NestedError = function (message, nested) { this.nested = nested; @@ -10997,7 +10492,7 @@ module.exports = NestedError; /***/ }), -/* 136 */ +/* 119 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -11007,7 +10502,7 @@ Object.defineProperty(exports, "__esModule", { value: true }); -var _cli = __webpack_require__(137); +var _cli = __webpack_require__(120); Object.defineProperty(exports, 'run', { enumerable: true, @@ -11016,7 +10511,7 @@ Object.defineProperty(exports, 'run', { } }); -var _production = __webpack_require__(385); +var _production = __webpack_require__(249); Object.defineProperty(exports, 'buildProductionProjects', { enumerable: true, @@ -11031,7 +10526,7 @@ Object.defineProperty(exports, 'prepareExternalProjectDependencies', { } }); -var _workspaces = __webpack_require__(97); +var _workspaces = __webpack_require__(112); Object.defineProperty(exports, 'copyWorkspacePackages', { enumerable: true, @@ -11041,7 +10536,7 @@ Object.defineProperty(exports, 'copyWorkspacePackages', { }); /***/ }), -/* 137 */ +/* 120 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -11093,25 +10588,25 @@ let run = exports.run = (() => { }; })(); -var _chalk = __webpack_require__(17); +var _chalk = __webpack_require__(30); var _chalk2 = _interopRequireDefault(_chalk); -var _dedent = __webpack_require__(143); +var _dedent = __webpack_require__(126); var _dedent2 = _interopRequireDefault(_dedent); -var _getopts = __webpack_require__(144); +var _getopts = __webpack_require__(127); var _getopts2 = _interopRequireDefault(_getopts); -var _path = __webpack_require__(2); +var _path = __webpack_require__(7); -var _commands = __webpack_require__(145); +var _commands = __webpack_require__(128); -var _run = __webpack_require__(375); +var _run = __webpack_require__(239); -var _log = __webpack_require__(19); +var _log = __webpack_require__(36); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -11157,12 +10652,12 @@ function help() { } /***/ }), -/* 138 */ +/* 121 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(module) { -const colorConvert = __webpack_require__(52); +const colorConvert = __webpack_require__(83); const wrapAnsi16 = (fn, offset) => function () { const code = fn.apply(colorConvert, arguments); @@ -11327,10 +10822,10 @@ Object.defineProperty(module, 'exports', { get: assembleStyles }); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(38)(module))) +/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(59)(module))) /***/ }), -/* 139 */ +/* 122 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -11489,10 +10984,10 @@ module.exports = { /***/ }), -/* 140 */ +/* 123 */ /***/ (function(module, exports, __webpack_require__) { -var conversions = __webpack_require__(77); +var conversions = __webpack_require__(92); /* this function routes a model to all other models. @@ -11592,13 +11087,13 @@ module.exports = function (fromModel) { /***/ }), -/* 141 */ +/* 124 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const os = __webpack_require__(53); -const hasFlag = __webpack_require__(78); +const os = __webpack_require__(84); +const hasFlag = __webpack_require__(93); const env = process.env; @@ -11734,7 +11229,7 @@ module.exports = { /***/ }), -/* 142 */ +/* 125 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -11869,7 +11364,7 @@ module.exports = (chalk, tmp) => { /***/ }), -/* 143 */ +/* 126 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -11935,7 +11430,7 @@ if (true) { /***/ }), -/* 144 */ +/* 127 */ /***/ (function(module, exports) { const SHORTSPLIT = /$|[!-@\[-`{-~].*/g @@ -12103,7 +11598,7 @@ module.exports = function(argv, opts) { /***/ }), -/* 145 */ +/* 128 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -12114,13 +11609,13 @@ Object.defineProperty(exports, "__esModule", { }); exports.commands = undefined; -var _bootstrap = __webpack_require__(146); +var _bootstrap = __webpack_require__(129); -var _clean = __webpack_require__(235); +var _clean = __webpack_require__(214); -var _run = __webpack_require__(258); +var _run = __webpack_require__(236); -var _watch = __webpack_require__(259); +var _watch = __webpack_require__(237); /* * Licensed to Elasticsearch B.V. under one or more contributor @@ -12148,7 +11643,7 @@ const commands = exports.commands = { }; /***/ }), -/* 146 */ +/* 129 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -12159,17 +11654,17 @@ Object.defineProperty(exports, "__esModule", { }); exports.BootstrapCommand = undefined; -var _chalk = __webpack_require__(17); +var _chalk = __webpack_require__(30); var _chalk2 = _interopRequireDefault(_chalk); -var _link_project_executables = __webpack_require__(147); +var _link_project_executables = __webpack_require__(130); -var _log = __webpack_require__(19); +var _log = __webpack_require__(36); -var _parallelize = __webpack_require__(54); +var _parallelize = __webpack_require__(85); -var _projects = __webpack_require__(22); +var _projects = __webpack_require__(42); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -12241,7 +11736,7 @@ const BootstrapCommand = exports.BootstrapCommand = { }; /***/ }), -/* 147 */ +/* 130 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -12291,15 +11786,15 @@ let linkProjectExecutables = exports.linkProjectExecutables = (() => { }; })(); -var _path = __webpack_require__(2); +var _path = __webpack_require__(7); -var _chalk = __webpack_require__(17); +var _chalk = __webpack_require__(30); var _chalk2 = _interopRequireDefault(_chalk); -var _fs = __webpack_require__(39); +var _fs = __webpack_require__(60); -var _log = __webpack_require__(19); +var _log = __webpack_require__(36); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -12323,7 +11818,7 @@ function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, a */ /***/ }), -/* 148 */ +/* 131 */ /***/ (function(module, exports, __webpack_require__) { // On windows, create a .cmd file. @@ -12339,10 +11834,10 @@ function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, a module.exports = cmdShim cmdShim.ifExists = cmdShimIfExists -var fs = __webpack_require__(27) +var fs = __webpack_require__(56) -var mkdir = __webpack_require__(80) - , path = __webpack_require__(2) +var mkdir = __webpack_require__(95) + , path = __webpack_require__(7) , shebangExpr = /^#\!\s*(?:\/usr\/bin\/env)?\s*([^ \t]+)(.*)$/ function cmdShimIfExists (from, to, cb) { @@ -12509,11 +12004,11 @@ function times(n, ok, cb) { /***/ }), -/* 149 */ +/* 132 */ /***/ (function(module, exports, __webpack_require__) { -var fs = __webpack_require__(79) -var constants = __webpack_require__(150) +var fs = __webpack_require__(94) +var constants = __webpack_require__(133) var origCwd = process.cwd var cwd = null @@ -12845,16 +12340,16 @@ function chownErOk (er) { /***/ }), -/* 150 */ +/* 133 */ /***/ (function(module, exports) { module.exports = require("constants"); /***/ }), -/* 151 */ +/* 134 */ /***/ (function(module, exports, __webpack_require__) { -var Stream = __webpack_require__(21).Stream +var Stream = __webpack_require__(41).Stream module.exports = legacy @@ -12975,11 +12470,11 @@ function legacy (fs) { /***/ }), -/* 152 */ +/* 135 */ /***/ (function(module, exports, __webpack_require__) { -var fs = __webpack_require__(6), - path = __webpack_require__(2); +var fs = __webpack_require__(16), + path = __webpack_require__(7); module.exports = ncp; ncp.ncp = ncp; @@ -13242,7 +12737,7 @@ function ncp (source, dest, options, callback) { /***/ }), -/* 153 */ +/* 136 */ /***/ (function(module, exports, __webpack_require__) { // Copyright Joyent, Inc. and other Node contributors. @@ -13266,9 +12761,9 @@ function ncp (source, dest, options, callback) { // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE // USE OR OTHER DEALINGS IN THE SOFTWARE. -var pathModule = __webpack_require__(2); +var pathModule = __webpack_require__(7); var isWindows = process.platform === 'win32'; -var fs = __webpack_require__(6); +var fs = __webpack_require__(16); // JavaScript implementation of realpath, ported from node pre-v6 @@ -13551,11 +13046,11 @@ exports.realpath = function realpath(p, cache, cb) { /***/ }), -/* 154 */ +/* 137 */ /***/ (function(module, exports, __webpack_require__) { -var concatMap = __webpack_require__(155); -var balanced = __webpack_require__(156); +var concatMap = __webpack_require__(138); +var balanced = __webpack_require__(139); module.exports = expandTop; @@ -13758,7 +13253,7 @@ function expand(str, isTop) { /***/ }), -/* 155 */ +/* 138 */ /***/ (function(module, exports) { module.exports = function (xs, fn) { @@ -13777,7 +13272,7 @@ var isArray = Array.isArray || function (xs) { /***/ }), -/* 156 */ +/* 139 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -13843,7 +13338,7 @@ function range(a, b, str) { /***/ }), -/* 157 */ +/* 140 */ /***/ (function(module, exports) { if (typeof Object.create === 'function') { @@ -13872,22 +13367,22 @@ if (typeof Object.create === 'function') { /***/ }), -/* 158 */ +/* 141 */ /***/ (function(module, exports, __webpack_require__) { module.exports = globSync globSync.GlobSync = GlobSync -var fs = __webpack_require__(6) -var rp = __webpack_require__(81) -var minimatch = __webpack_require__(55) +var fs = __webpack_require__(16) +var rp = __webpack_require__(96) +var minimatch = __webpack_require__(86) var Minimatch = minimatch.Minimatch -var Glob = __webpack_require__(23).Glob -var util = __webpack_require__(8) -var path = __webpack_require__(2) -var assert = __webpack_require__(28) -var isAbsolute = __webpack_require__(56) -var common = __webpack_require__(83) +var Glob = __webpack_require__(43).Glob +var util = __webpack_require__(19) +var path = __webpack_require__(7) +var assert = __webpack_require__(57) +var isAbsolute = __webpack_require__(87) +var common = __webpack_require__(98) var alphasort = common.alphasort var alphasorti = common.alphasorti var setopts = common.setopts @@ -14364,12 +13859,12 @@ GlobSync.prototype._makeAbs = function (f) { /***/ }), -/* 159 */ +/* 142 */ /***/ (function(module, exports, __webpack_require__) { -var wrappy = __webpack_require__(84) +var wrappy = __webpack_require__(99) var reqs = Object.create(null) -var once = __webpack_require__(85) +var once = __webpack_require__(100) module.exports = wrappy(inflight) @@ -14424,14 +13919,14 @@ function slice (args) { /***/ }), -/* 160 */ +/* 143 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const path = __webpack_require__(2); -const loadJsonFile = __webpack_require__(161); -const pathType = __webpack_require__(168); +const path = __webpack_require__(7); +const loadJsonFile = __webpack_require__(144); +const pathType = __webpack_require__(150); module.exports = (fp, opts) => { if (typeof fp !== 'string') { @@ -14451,7 +13946,7 @@ module.exports = (fp, opts) => { }) .then(x => { if (opts.normalize !== false) { - __webpack_require__(87)(x); + __webpack_require__(102)(x); } return x; @@ -14470,7 +13965,7 @@ module.exports.sync = (fp, opts) => { const x = loadJsonFile.sync(fp); if (opts.normalize !== false) { - __webpack_require__(87)(x); + __webpack_require__(102)(x); } return x; @@ -14478,16 +13973,16 @@ module.exports.sync = (fp, opts) => { /***/ }), -/* 161 */ +/* 144 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const path = __webpack_require__(2); -const fs = __webpack_require__(27); -const stripBom = __webpack_require__(162); -const parseJson = __webpack_require__(163); -const pify = __webpack_require__(167); +const path = __webpack_require__(7); +const fs = __webpack_require__(56); +const stripBom = __webpack_require__(145); +const parseJson = __webpack_require__(146); +const pify = __webpack_require__(44); const parse = (data, fp) => parseJson(stripBom(data), path.relative('.', fp)); @@ -14496,7 +13991,7 @@ module.exports.sync = fp => parse(fs.readFileSync(fp, 'utf8'), fp); /***/ }), -/* 162 */ +/* 145 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -14517,13 +14012,13 @@ module.exports = x => { /***/ }), -/* 163 */ +/* 146 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const errorEx = __webpack_require__(164); -const fallback = __webpack_require__(166); +const errorEx = __webpack_require__(147); +const fallback = __webpack_require__(149); const JSONError = errorEx('JSONError', { fileName: errorEx.append('in %s') @@ -14557,14 +14052,14 @@ module.exports = (input, reviver, filename) => { /***/ }), -/* 164 */ +/* 147 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var util = __webpack_require__(8); -var isArrayish = __webpack_require__(165); +var util = __webpack_require__(19); +var isArrayish = __webpack_require__(148); var errorEx = function errorEx(name, properties) { if (!name || name.constructor !== String) { @@ -14697,7 +14192,7 @@ module.exports = errorEx; /***/ }), -/* 165 */ +/* 148 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -14714,7 +14209,7 @@ module.exports = function isArrayish(obj) { /***/ }), -/* 166 */ +/* 149 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -14753,104 +14248,13 @@ function parseJson (txt, reviver, context) { /***/ }), -/* 167 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -const processFn = (fn, opts) => function () { - const P = opts.promiseModule; - const args = new Array(arguments.length); - - for (let i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } - - return new P((resolve, reject) => { - if (opts.errorFirst) { - args.push(function (err, result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 1; i < arguments.length; i++) { - results[i - 1] = arguments[i]; - } - - if (err) { - results.unshift(err); - reject(results); - } else { - resolve(results); - } - } else if (err) { - reject(err); - } else { - resolve(result); - } - }); - } else { - args.push(function (result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 0; i < arguments.length; i++) { - results[i] = arguments[i]; - } - - resolve(results); - } else { - resolve(result); - } - }); - } - - fn.apply(this, args); - }); -}; - -module.exports = (obj, opts) => { - opts = Object.assign({ - exclude: [/.+(Sync|Stream)$/], - errorFirst: true, - promiseModule: Promise - }, opts); - - const filter = key => { - const match = pattern => typeof pattern === 'string' ? key === pattern : pattern.test(key); - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; - - let ret; - if (typeof obj === 'function') { - ret = function () { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } - - return processFn(obj, opts).apply(this, arguments); - }; - } else { - ret = Object.create(Object.getPrototypeOf(obj)); - } - - for (const key in obj) { // eslint-disable-line guard-for-in - const x = obj[key]; - ret[key] = typeof x === 'function' && filter(key) ? processFn(x, opts) : x; - } - - return ret; -}; - - -/***/ }), -/* 168 */ +/* 150 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const fs = __webpack_require__(6); -const pify = __webpack_require__(169); +const fs = __webpack_require__(16); +const pify = __webpack_require__(44); function type(fn, fn2, fp) { if (typeof fp !== 'string') { @@ -14867,134 +14271,43 @@ function type(fn, fn2, fp) { throw err; }); } - -function typeSync(fn, fn2, fp) { - if (typeof fp !== 'string') { - throw new TypeError(`Expected a string, got ${typeof fp}`); - } - - try { - return fs[fn](fp)[fn2](); - } catch (err) { - if (err.code === 'ENOENT') { - return false; - } - - throw err; - } -} - -exports.file = type.bind(null, 'stat', 'isFile'); -exports.dir = type.bind(null, 'stat', 'isDirectory'); -exports.symlink = type.bind(null, 'lstat', 'isSymbolicLink'); -exports.fileSync = typeSync.bind(null, 'statSync', 'isFile'); -exports.dirSync = typeSync.bind(null, 'statSync', 'isDirectory'); -exports.symlinkSync = typeSync.bind(null, 'lstatSync', 'isSymbolicLink'); - - -/***/ }), -/* 169 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -const processFn = (fn, opts) => function () { - const P = opts.promiseModule; - const args = new Array(arguments.length); - - for (let i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } - - return new P((resolve, reject) => { - if (opts.errorFirst) { - args.push(function (err, result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 1; i < arguments.length; i++) { - results[i - 1] = arguments[i]; - } - - if (err) { - results.unshift(err); - reject(results); - } else { - resolve(results); - } - } else if (err) { - reject(err); - } else { - resolve(result); - } - }); - } else { - args.push(function (result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 0; i < arguments.length; i++) { - results[i] = arguments[i]; - } - - resolve(results); - } else { - resolve(result); - } - }); - } - - fn.apply(this, args); - }); -}; - -module.exports = (obj, opts) => { - opts = Object.assign({ - exclude: [/.+(Sync|Stream)$/], - errorFirst: true, - promiseModule: Promise - }, opts); - - const filter = key => { - const match = pattern => typeof pattern === 'string' ? key === pattern : pattern.test(key); - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; - - let ret; - if (typeof obj === 'function') { - ret = function () { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } - - return processFn(obj, opts).apply(this, arguments); - }; - } else { - ret = Object.create(Object.getPrototypeOf(obj)); + +function typeSync(fn, fn2, fp) { + if (typeof fp !== 'string') { + throw new TypeError(`Expected a string, got ${typeof fp}`); } - for (const key in obj) { // eslint-disable-line guard-for-in - const x = obj[key]; - ret[key] = typeof x === 'function' && filter(key) ? processFn(x, opts) : x; + try { + return fs[fn](fp)[fn2](); + } catch (err) { + if (err.code === 'ENOENT') { + return false; + } + + throw err; } +} - return ret; -}; +exports.file = type.bind(null, 'stat', 'isFile'); +exports.dir = type.bind(null, 'stat', 'isDirectory'); +exports.symlink = type.bind(null, 'lstat', 'isSymbolicLink'); +exports.fileSync = typeSync.bind(null, 'statSync', 'isFile'); +exports.dirSync = typeSync.bind(null, 'statSync', 'isDirectory'); +exports.symlinkSync = typeSync.bind(null, 'lstatSync', 'isSymbolicLink'); /***/ }), -/* 170 */ +/* 151 */ /***/ (function(module, exports, __webpack_require__) { -var semver = __webpack_require__(171) -var validateLicense = __webpack_require__(172); -var hostedGitInfo = __webpack_require__(177) -var isBuiltinModule = __webpack_require__(179) +var semver = __webpack_require__(152) +var validateLicense = __webpack_require__(153); +var hostedGitInfo = __webpack_require__(158) +var isBuiltinModule = __webpack_require__(160) var depTypes = ["dependencies","devDependencies","optionalDependencies"] -var extractDescription = __webpack_require__(181) -var url = __webpack_require__(88) -var typos = __webpack_require__(182) +var extractDescription = __webpack_require__(162) +var url = __webpack_require__(103) +var typos = __webpack_require__(163) var fixer = module.exports = { // default warning function @@ -15407,7 +14720,7 @@ function bugsTypos(bugs, warn) { /***/ }), -/* 171 */ +/* 152 */ /***/ (function(module, exports) { exports = module.exports = SemVer; @@ -16709,11 +16022,11 @@ function intersects(r1, r2, loose) { /***/ }), -/* 172 */ +/* 153 */ /***/ (function(module, exports, __webpack_require__) { -var parse = __webpack_require__(173); -var correct = __webpack_require__(175); +var parse = __webpack_require__(154); +var correct = __webpack_require__(156); var genericWarning = ( 'license should be ' + @@ -16799,10 +16112,10 @@ module.exports = function(argument) { /***/ }), -/* 173 */ +/* 154 */ /***/ (function(module, exports, __webpack_require__) { -var parser = __webpack_require__(174).parser +var parser = __webpack_require__(155).parser module.exports = function (argument) { return parser.parse(argument) @@ -16810,7 +16123,7 @@ module.exports = function (argument) { /***/ }), -/* 174 */ +/* 155 */ /***/ (function(module, exports, __webpack_require__) { /* WEBPACK VAR INJECTION */(function(module) {/* parser generated by jison 0.4.17 */ @@ -18163,21 +17476,21 @@ exports.main = function commonjsMain(args) { console.log('Usage: '+args[0]+' FILE'); process.exit(1); } - var source = __webpack_require__(6).readFileSync(__webpack_require__(2).normalize(args[1]), "utf8"); + var source = __webpack_require__(16).readFileSync(__webpack_require__(7).normalize(args[1]), "utf8"); return exports.parser.parse(source); }; -if (typeof module !== 'undefined' && __webpack_require__.c[__webpack_require__.s] === module) { +if ( true && __webpack_require__.c[__webpack_require__.s] === module) { exports.main(process.argv.slice(1)); } } -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(38)(module))) +/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(59)(module))) /***/ }), -/* 175 */ +/* 156 */ /***/ (function(module, exports, __webpack_require__) { -var licenseIDs = __webpack_require__(176); +var licenseIDs = __webpack_require__(157); function valid(string) { return licenseIDs.indexOf(string) > -1; @@ -18417,20 +17730,20 @@ module.exports = function(identifier) { /***/ }), -/* 176 */ -/***/ (function(module, exports) { +/* 157 */ +/***/ (function(module) { -module.exports = ["Glide","Abstyles","AFL-1.1","AFL-1.2","AFL-2.0","AFL-2.1","AFL-3.0","AMPAS","APL-1.0","Adobe-Glyph","APAFML","Adobe-2006","AGPL-1.0","Afmparse","Aladdin","ADSL","AMDPLPA","ANTLR-PD","Apache-1.0","Apache-1.1","Apache-2.0","AML","APSL-1.0","APSL-1.1","APSL-1.2","APSL-2.0","Artistic-1.0","Artistic-1.0-Perl","Artistic-1.0-cl8","Artistic-2.0","AAL","Bahyph","Barr","Beerware","BitTorrent-1.0","BitTorrent-1.1","BSL-1.0","Borceux","BSD-2-Clause","BSD-2-Clause-FreeBSD","BSD-2-Clause-NetBSD","BSD-3-Clause","BSD-3-Clause-Clear","BSD-4-Clause","BSD-Protection","BSD-Source-Code","BSD-3-Clause-Attribution","0BSD","BSD-4-Clause-UC","bzip2-1.0.5","bzip2-1.0.6","Caldera","CECILL-1.0","CECILL-1.1","CECILL-2.0","CECILL-2.1","CECILL-B","CECILL-C","ClArtistic","MIT-CMU","CNRI-Jython","CNRI-Python","CNRI-Python-GPL-Compatible","CPOL-1.02","CDDL-1.0","CDDL-1.1","CPAL-1.0","CPL-1.0","CATOSL-1.1","Condor-1.1","CC-BY-1.0","CC-BY-2.0","CC-BY-2.5","CC-BY-3.0","CC-BY-4.0","CC-BY-ND-1.0","CC-BY-ND-2.0","CC-BY-ND-2.5","CC-BY-ND-3.0","CC-BY-ND-4.0","CC-BY-NC-1.0","CC-BY-NC-2.0","CC-BY-NC-2.5","CC-BY-NC-3.0","CC-BY-NC-4.0","CC-BY-NC-ND-1.0","CC-BY-NC-ND-2.0","CC-BY-NC-ND-2.5","CC-BY-NC-ND-3.0","CC-BY-NC-ND-4.0","CC-BY-NC-SA-1.0","CC-BY-NC-SA-2.0","CC-BY-NC-SA-2.5","CC-BY-NC-SA-3.0","CC-BY-NC-SA-4.0","CC-BY-SA-1.0","CC-BY-SA-2.0","CC-BY-SA-2.5","CC-BY-SA-3.0","CC-BY-SA-4.0","CC0-1.0","Crossword","CrystalStacker","CUA-OPL-1.0","Cube","curl","D-FSL-1.0","diffmark","WTFPL","DOC","Dotseqn","DSDP","dvipdfm","EPL-1.0","ECL-1.0","ECL-2.0","eGenix","EFL-1.0","EFL-2.0","MIT-advertising","MIT-enna","Entessa","ErlPL-1.1","EUDatagrid","EUPL-1.0","EUPL-1.1","Eurosym","Fair","MIT-feh","Frameworx-1.0","FreeImage","FTL","FSFAP","FSFUL","FSFULLR","Giftware","GL2PS","Glulxe","AGPL-3.0","GFDL-1.1","GFDL-1.2","GFDL-1.3","GPL-1.0","GPL-2.0","GPL-3.0","LGPL-2.1","LGPL-3.0","LGPL-2.0","gnuplot","gSOAP-1.3b","HaskellReport","HPND","IBM-pibs","IPL-1.0","ICU","ImageMagick","iMatix","Imlib2","IJG","Info-ZIP","Intel-ACPI","Intel","Interbase-1.0","IPA","ISC","JasPer-2.0","JSON","LPPL-1.0","LPPL-1.1","LPPL-1.2","LPPL-1.3a","LPPL-1.3c","Latex2e","BSD-3-Clause-LBNL","Leptonica","LGPLLR","Libpng","libtiff","LAL-1.2","LAL-1.3","LiLiQ-P-1.1","LiLiQ-Rplus-1.1","LiLiQ-R-1.1","LPL-1.02","LPL-1.0","MakeIndex","MTLL","MS-PL","MS-RL","MirOS","MITNFA","MIT","Motosoto","MPL-1.0","MPL-1.1","MPL-2.0","MPL-2.0-no-copyleft-exception","mpich2","Multics","Mup","NASA-1.3","Naumen","NBPL-1.0","NetCDF","NGPL","NOSL","NPL-1.0","NPL-1.1","Newsletr","NLPL","Nokia","NPOSL-3.0","NLOD-1.0","Noweb","NRL","NTP","Nunit","OCLC-2.0","ODbL-1.0","PDDL-1.0","OCCT-PL","OGTSL","OLDAP-2.2.2","OLDAP-1.1","OLDAP-1.2","OLDAP-1.3","OLDAP-1.4","OLDAP-2.0","OLDAP-2.0.1","OLDAP-2.1","OLDAP-2.2","OLDAP-2.2.1","OLDAP-2.3","OLDAP-2.4","OLDAP-2.5","OLDAP-2.6","OLDAP-2.7","OLDAP-2.8","OML","OPL-1.0","OSL-1.0","OSL-1.1","OSL-2.0","OSL-2.1","OSL-3.0","OpenSSL","OSET-PL-2.1","PHP-3.0","PHP-3.01","Plexus","PostgreSQL","psfrag","psutils","Python-2.0","QPL-1.0","Qhull","Rdisc","RPSL-1.0","RPL-1.1","RPL-1.5","RHeCos-1.1","RSCPL","RSA-MD","Ruby","SAX-PD","Saxpath","SCEA","SWL","SMPPL","Sendmail","SGI-B-1.0","SGI-B-1.1","SGI-B-2.0","OFL-1.0","OFL-1.1","SimPL-2.0","Sleepycat","SNIA","Spencer-86","Spencer-94","Spencer-99","SMLNJ","SugarCRM-1.1.3","SISSL","SISSL-1.2","SPL-1.0","Watcom-1.0","TCL","Unlicense","TMate","TORQUE-1.1","TOSL","Unicode-TOU","UPL-1.0","NCSA","Vim","VOSTROM","VSL-1.0","W3C-19980720","W3C","Wsuipa","Xnet","X11","Xerox","XFree86-1.1","xinetd","xpp","XSkat","YPL-1.0","YPL-1.1","Zed","Zend-2.0","Zimbra-1.3","Zimbra-1.4","Zlib","zlib-acknowledgement","ZPL-1.1","ZPL-2.0","ZPL-2.1","BSD-3-Clause-No-Nuclear-License","BSD-3-Clause-No-Nuclear-Warranty","BSD-3-Clause-No-Nuclear-License-2014","eCos-2.0","GPL-2.0-with-autoconf-exception","GPL-2.0-with-bison-exception","GPL-2.0-with-classpath-exception","GPL-2.0-with-font-exception","GPL-2.0-with-GCC-exception","GPL-3.0-with-autoconf-exception","GPL-3.0-with-GCC-exception","StandardML-NJ","WXwindows"] +module.exports = ["Glide","Abstyles","AFL-1.1","AFL-1.2","AFL-2.0","AFL-2.1","AFL-3.0","AMPAS","APL-1.0","Adobe-Glyph","APAFML","Adobe-2006","AGPL-1.0","Afmparse","Aladdin","ADSL","AMDPLPA","ANTLR-PD","Apache-1.0","Apache-1.1","Apache-2.0","AML","APSL-1.0","APSL-1.1","APSL-1.2","APSL-2.0","Artistic-1.0","Artistic-1.0-Perl","Artistic-1.0-cl8","Artistic-2.0","AAL","Bahyph","Barr","Beerware","BitTorrent-1.0","BitTorrent-1.1","BSL-1.0","Borceux","BSD-2-Clause","BSD-2-Clause-FreeBSD","BSD-2-Clause-NetBSD","BSD-3-Clause","BSD-3-Clause-Clear","BSD-4-Clause","BSD-Protection","BSD-Source-Code","BSD-3-Clause-Attribution","0BSD","BSD-4-Clause-UC","bzip2-1.0.5","bzip2-1.0.6","Caldera","CECILL-1.0","CECILL-1.1","CECILL-2.0","CECILL-2.1","CECILL-B","CECILL-C","ClArtistic","MIT-CMU","CNRI-Jython","CNRI-Python","CNRI-Python-GPL-Compatible","CPOL-1.02","CDDL-1.0","CDDL-1.1","CPAL-1.0","CPL-1.0","CATOSL-1.1","Condor-1.1","CC-BY-1.0","CC-BY-2.0","CC-BY-2.5","CC-BY-3.0","CC-BY-4.0","CC-BY-ND-1.0","CC-BY-ND-2.0","CC-BY-ND-2.5","CC-BY-ND-3.0","CC-BY-ND-4.0","CC-BY-NC-1.0","CC-BY-NC-2.0","CC-BY-NC-2.5","CC-BY-NC-3.0","CC-BY-NC-4.0","CC-BY-NC-ND-1.0","CC-BY-NC-ND-2.0","CC-BY-NC-ND-2.5","CC-BY-NC-ND-3.0","CC-BY-NC-ND-4.0","CC-BY-NC-SA-1.0","CC-BY-NC-SA-2.0","CC-BY-NC-SA-2.5","CC-BY-NC-SA-3.0","CC-BY-NC-SA-4.0","CC-BY-SA-1.0","CC-BY-SA-2.0","CC-BY-SA-2.5","CC-BY-SA-3.0","CC-BY-SA-4.0","CC0-1.0","Crossword","CrystalStacker","CUA-OPL-1.0","Cube","curl","D-FSL-1.0","diffmark","WTFPL","DOC","Dotseqn","DSDP","dvipdfm","EPL-1.0","ECL-1.0","ECL-2.0","eGenix","EFL-1.0","EFL-2.0","MIT-advertising","MIT-enna","Entessa","ErlPL-1.1","EUDatagrid","EUPL-1.0","EUPL-1.1","Eurosym","Fair","MIT-feh","Frameworx-1.0","FreeImage","FTL","FSFAP","FSFUL","FSFULLR","Giftware","GL2PS","Glulxe","AGPL-3.0","GFDL-1.1","GFDL-1.2","GFDL-1.3","GPL-1.0","GPL-2.0","GPL-3.0","LGPL-2.1","LGPL-3.0","LGPL-2.0","gnuplot","gSOAP-1.3b","HaskellReport","HPND","IBM-pibs","IPL-1.0","ICU","ImageMagick","iMatix","Imlib2","IJG","Info-ZIP","Intel-ACPI","Intel","Interbase-1.0","IPA","ISC","JasPer-2.0","JSON","LPPL-1.0","LPPL-1.1","LPPL-1.2","LPPL-1.3a","LPPL-1.3c","Latex2e","BSD-3-Clause-LBNL","Leptonica","LGPLLR","Libpng","libtiff","LAL-1.2","LAL-1.3","LiLiQ-P-1.1","LiLiQ-Rplus-1.1","LiLiQ-R-1.1","LPL-1.02","LPL-1.0","MakeIndex","MTLL","MS-PL","MS-RL","MirOS","MITNFA","MIT","Motosoto","MPL-1.0","MPL-1.1","MPL-2.0","MPL-2.0-no-copyleft-exception","mpich2","Multics","Mup","NASA-1.3","Naumen","NBPL-1.0","NetCDF","NGPL","NOSL","NPL-1.0","NPL-1.1","Newsletr","NLPL","Nokia","NPOSL-3.0","NLOD-1.0","Noweb","NRL","NTP","Nunit","OCLC-2.0","ODbL-1.0","PDDL-1.0","OCCT-PL","OGTSL","OLDAP-2.2.2","OLDAP-1.1","OLDAP-1.2","OLDAP-1.3","OLDAP-1.4","OLDAP-2.0","OLDAP-2.0.1","OLDAP-2.1","OLDAP-2.2","OLDAP-2.2.1","OLDAP-2.3","OLDAP-2.4","OLDAP-2.5","OLDAP-2.6","OLDAP-2.7","OLDAP-2.8","OML","OPL-1.0","OSL-1.0","OSL-1.1","OSL-2.0","OSL-2.1","OSL-3.0","OpenSSL","OSET-PL-2.1","PHP-3.0","PHP-3.01","Plexus","PostgreSQL","psfrag","psutils","Python-2.0","QPL-1.0","Qhull","Rdisc","RPSL-1.0","RPL-1.1","RPL-1.5","RHeCos-1.1","RSCPL","RSA-MD","Ruby","SAX-PD","Saxpath","SCEA","SWL","SMPPL","Sendmail","SGI-B-1.0","SGI-B-1.1","SGI-B-2.0","OFL-1.0","OFL-1.1","SimPL-2.0","Sleepycat","SNIA","Spencer-86","Spencer-94","Spencer-99","SMLNJ","SugarCRM-1.1.3","SISSL","SISSL-1.2","SPL-1.0","Watcom-1.0","TCL","Unlicense","TMate","TORQUE-1.1","TOSL","Unicode-TOU","UPL-1.0","NCSA","Vim","VOSTROM","VSL-1.0","W3C-19980720","W3C","Wsuipa","Xnet","X11","Xerox","XFree86-1.1","xinetd","xpp","XSkat","YPL-1.0","YPL-1.1","Zed","Zend-2.0","Zimbra-1.3","Zimbra-1.4","Zlib","zlib-acknowledgement","ZPL-1.1","ZPL-2.0","ZPL-2.1","BSD-3-Clause-No-Nuclear-License","BSD-3-Clause-No-Nuclear-Warranty","BSD-3-Clause-No-Nuclear-License-2014","eCos-2.0","GPL-2.0-with-autoconf-exception","GPL-2.0-with-bison-exception","GPL-2.0-with-classpath-exception","GPL-2.0-with-font-exception","GPL-2.0-with-GCC-exception","GPL-3.0-with-autoconf-exception","GPL-3.0-with-GCC-exception","StandardML-NJ","WXwindows"]; /***/ }), -/* 177 */ +/* 158 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var url = __webpack_require__(88) -var gitHosts = __webpack_require__(89) -var GitHost = module.exports = __webpack_require__(178) +var url = __webpack_require__(103) +var gitHosts = __webpack_require__(104) +var GitHost = module.exports = __webpack_require__(159) var protocolToRepresentationMap = { 'git+ssh': 'sshurl', @@ -18551,13 +17864,13 @@ function parseGitUrl (giturl) { /***/ }), -/* 178 */ +/* 159 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var gitHosts = __webpack_require__(89) -var extend = Object.assign || __webpack_require__(8)._extend +var gitHosts = __webpack_require__(104) +var extend = Object.assign || __webpack_require__(19)._extend var GitHost = module.exports = function (type, user, auth, project, committish, defaultRepresentation, opts) { var gitHostInfo = this @@ -18672,12 +17985,12 @@ GitHost.prototype.toString = function (opts) { /***/ }), -/* 179 */ +/* 160 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var builtinModules = __webpack_require__(180); +var builtinModules = __webpack_require__(161); module.exports = function (str) { if (typeof str !== 'string') { @@ -18689,7 +18002,7 @@ module.exports = function (str) { /***/ }), -/* 180 */ +/* 161 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -18706,7 +18019,7 @@ module.exports = Object.keys(process.binding('natives')).filter(function (el) { /***/ }), -/* 181 */ +/* 162 */ /***/ (function(module, exports) { module.exports = extractDescription @@ -18726,17 +18039,17 @@ function extractDescription (d) { /***/ }), -/* 182 */ -/***/ (function(module, exports) { +/* 163 */ +/***/ (function(module) { -module.exports = {"topLevel":{"dependancies":"dependencies","dependecies":"dependencies","depdenencies":"dependencies","devEependencies":"devDependencies","depends":"dependencies","dev-dependencies":"devDependencies","devDependences":"devDependencies","devDepenencies":"devDependencies","devdependencies":"devDependencies","repostitory":"repository","repo":"repository","prefereGlobal":"preferGlobal","hompage":"homepage","hampage":"homepage","autohr":"author","autor":"author","contributers":"contributors","publicationConfig":"publishConfig","script":"scripts"},"bugs":{"web":"url","name":"url"},"script":{"server":"start","tests":"test"}} +module.exports = {"topLevel":{"dependancies":"dependencies","dependecies":"dependencies","depdenencies":"dependencies","devEependencies":"devDependencies","depends":"dependencies","dev-dependencies":"devDependencies","devDependences":"devDependencies","devDepenencies":"devDependencies","devdependencies":"devDependencies","repostitory":"repository","repo":"repository","prefereGlobal":"preferGlobal","hompage":"homepage","hampage":"homepage","autohr":"author","autor":"author","contributers":"contributors","publicationConfig":"publishConfig","script":"scripts"},"bugs":{"web":"url","name":"url"},"script":{"server":"start","tests":"test"}}; /***/ }), -/* 183 */ +/* 164 */ /***/ (function(module, exports, __webpack_require__) { -var util = __webpack_require__(8) -var messages = __webpack_require__(184) +var util = __webpack_require__(19) +var messages = __webpack_require__(165) module.exports = function() { var args = Array.prototype.slice.call(arguments, 0) @@ -18761,20 +18074,20 @@ function makeTypoWarning (providedName, probableName, field) { /***/ }), -/* 184 */ -/***/ (function(module, exports) { +/* 165 */ +/***/ (function(module) { -module.exports = {"repositories":"'repositories' (plural) Not supported. Please pick one as the 'repository' field","missingRepository":"No repository field.","brokenGitUrl":"Probably broken git url: %s","nonObjectScripts":"scripts must be an object","nonStringScript":"script values must be string commands","nonArrayFiles":"Invalid 'files' member","invalidFilename":"Invalid filename in 'files' list: %s","nonArrayBundleDependencies":"Invalid 'bundleDependencies' list. Must be array of package names","nonStringBundleDependency":"Invalid bundleDependencies member: %s","nonDependencyBundleDependency":"Non-dependency in bundleDependencies: %s","nonObjectDependencies":"%s field must be an object","nonStringDependency":"Invalid dependency: %s %s","deprecatedArrayDependencies":"specifying %s as array is deprecated","deprecatedModules":"modules field is deprecated","nonArrayKeywords":"keywords should be an array of strings","nonStringKeyword":"keywords should be an array of strings","conflictingName":"%s is also the name of a node core module.","nonStringDescription":"'description' field should be a string","missingDescription":"No description","missingReadme":"No README data","missingLicense":"No license field.","nonEmailUrlBugsString":"Bug string field must be url, email, or {email,url}","nonUrlBugsUrlField":"bugs.url field must be a string url. Deleted.","nonEmailBugsEmailField":"bugs.email field must be a string email. Deleted.","emptyNormalizedBugs":"Normalized value of bugs field is an empty object. Deleted.","nonUrlHomepage":"homepage field must be a string url. Deleted.","invalidLicense":"license should be a valid SPDX license expression","typo":"%s should probably be %s."} +module.exports = {"repositories":"'repositories' (plural) Not supported. Please pick one as the 'repository' field","missingRepository":"No repository field.","brokenGitUrl":"Probably broken git url: %s","nonObjectScripts":"scripts must be an object","nonStringScript":"script values must be string commands","nonArrayFiles":"Invalid 'files' member","invalidFilename":"Invalid filename in 'files' list: %s","nonArrayBundleDependencies":"Invalid 'bundleDependencies' list. Must be array of package names","nonStringBundleDependency":"Invalid bundleDependencies member: %s","nonDependencyBundleDependency":"Non-dependency in bundleDependencies: %s","nonObjectDependencies":"%s field must be an object","nonStringDependency":"Invalid dependency: %s %s","deprecatedArrayDependencies":"specifying %s as array is deprecated","deprecatedModules":"modules field is deprecated","nonArrayKeywords":"keywords should be an array of strings","nonStringKeyword":"keywords should be an array of strings","conflictingName":"%s is also the name of a node core module.","nonStringDescription":"'description' field should be a string","missingDescription":"No description","missingReadme":"No README data","missingLicense":"No license field.","nonEmailUrlBugsString":"Bug string field must be url, email, or {email,url}","nonUrlBugsUrlField":"bugs.url field must be a string url. Deleted.","nonEmailBugsEmailField":"bugs.email field must be a string email. Deleted.","emptyNormalizedBugs":"Normalized value of bugs field is an empty object. Deleted.","nonUrlHomepage":"homepage field must be a string url. Deleted.","invalidLicense":"license should be a valid SPDX license expression","typo":"%s should probably be %s."}; /***/ }), -/* 185 */ +/* 166 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const path = __webpack_require__(2); -const writeJsonFile = __webpack_require__(186); -const sortKeys = __webpack_require__(90); +const path = __webpack_require__(7); +const writeJsonFile = __webpack_require__(167); +const sortKeys = __webpack_require__(105); const opts = {detectIndent: true}; @@ -18827,18 +18140,18 @@ module.exports.sync = (fp, data) => { /***/ }), -/* 186 */ +/* 167 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const path = __webpack_require__(2); -const fs = __webpack_require__(27); -const writeFileAtomic = __webpack_require__(187); -const sortKeys = __webpack_require__(90); -const makeDir = __webpack_require__(91); -const pify = __webpack_require__(192); -const detectIndent = __webpack_require__(193); +const path = __webpack_require__(7); +const fs = __webpack_require__(56); +const writeFileAtomic = __webpack_require__(168); +const sortKeys = __webpack_require__(105); +const makeDir = __webpack_require__(106); +const pify = __webpack_require__(44); +const detectIndent = __webpack_require__(172); const init = (fn, fp, data, opts) => { if (!fp) { @@ -18907,7 +18220,7 @@ module.exports.sync = (fp, data, opts) => { /***/ }), -/* 187 */ +/* 168 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -18917,10 +18230,10 @@ module.exports.sync = writeFileSync module.exports._getTmpname = getTmpname // for testing module.exports._cleanupOnExit = cleanupOnExit -var fs = __webpack_require__(27) -var MurmurHash3 = __webpack_require__(188) -var onExit = __webpack_require__(58) -var path = __webpack_require__(2) +var fs = __webpack_require__(56) +var MurmurHash3 = __webpack_require__(169) +var onExit = __webpack_require__(89) +var path = __webpack_require__(7) var activeFiles = {} var invocations = 0 @@ -19113,7 +18426,7 @@ function writeFileSync (filename, data, options) { /***/ }), -/* 188 */ +/* 169 */ /***/ (function(module, exports, __webpack_require__) { /** @@ -19250,14 +18563,12 @@ function writeFileSync (filename, data, options) { if (true) { module.exports = MurmurHash3; - } else { - this.MurmurHash3 = MurmurHash3; - } + } else {} }()); /***/ }), -/* 189 */ +/* 170 */ /***/ (function(module, exports) { // This is not the set of all possible signals. @@ -19285,234 +18596,52 @@ module.exports = [ 'SIGALRM', 'SIGHUP', 'SIGINT', - 'SIGTERM' -] - -if (process.platform !== 'win32') { - module.exports.push( - 'SIGVTALRM', - 'SIGXCPU', - 'SIGXFSZ', - 'SIGUSR2', - 'SIGTRAP', - 'SIGSYS', - 'SIGQUIT', - 'SIGIOT' - // should detect profiler and enable/disable accordingly. - // see #21 - // 'SIGPROF' - ) -} - -if (process.platform === 'linux') { - module.exports.push( - 'SIGIO', - 'SIGPOLL', - 'SIGPWR', - 'SIGSTKFLT', - 'SIGUNUSED' - ) -} - - -/***/ }), -/* 190 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - -var toString = Object.prototype.toString; - -module.exports = function (x) { - var prototype; - return toString.call(x) === '[object Object]' && (prototype = Object.getPrototypeOf(x), prototype === null || prototype === Object.getPrototypeOf({})); -}; - - -/***/ }), -/* 191 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -const processFn = (fn, opts) => function () { - const P = opts.promiseModule; - const args = new Array(arguments.length); - - for (let i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } - - return new P((resolve, reject) => { - if (opts.errorFirst) { - args.push(function (err, result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 1; i < arguments.length; i++) { - results[i - 1] = arguments[i]; - } - - if (err) { - results.unshift(err); - reject(results); - } else { - resolve(results); - } - } else if (err) { - reject(err); - } else { - resolve(result); - } - }); - } else { - args.push(function (result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 0; i < arguments.length; i++) { - results[i] = arguments[i]; - } - - resolve(results); - } else { - resolve(result); - } - }); - } - - fn.apply(this, args); - }); -}; - -module.exports = (obj, opts) => { - opts = Object.assign({ - exclude: [/.+(Sync|Stream)$/], - errorFirst: true, - promiseModule: Promise - }, opts); - - const filter = key => { - const match = pattern => typeof pattern === 'string' ? key === pattern : pattern.test(key); - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; - - let ret; - if (typeof obj === 'function') { - ret = function () { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } - - return processFn(obj, opts).apply(this, arguments); - }; - } else { - ret = Object.create(Object.getPrototypeOf(obj)); - } - - for (const key in obj) { // eslint-disable-line guard-for-in - const x = obj[key]; - ret[key] = typeof x === 'function' && filter(key) ? processFn(x, opts) : x; - } - - return ret; -}; - - -/***/ }), -/* 192 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -const processFn = (fn, opts) => function () { - const P = opts.promiseModule; - const args = new Array(arguments.length); - - for (let i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } - - return new P((resolve, reject) => { - if (opts.errorFirst) { - args.push(function (err, result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 1; i < arguments.length; i++) { - results[i - 1] = arguments[i]; - } - - if (err) { - results.unshift(err); - reject(results); - } else { - resolve(results); - } - } else if (err) { - reject(err); - } else { - resolve(result); - } - }); - } else { - args.push(function (result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 0; i < arguments.length; i++) { - results[i] = arguments[i]; - } - - resolve(results); - } else { - resolve(result); - } - }); - } + 'SIGTERM' +] - fn.apply(this, args); - }); -}; +if (process.platform !== 'win32') { + module.exports.push( + 'SIGVTALRM', + 'SIGXCPU', + 'SIGXFSZ', + 'SIGUSR2', + 'SIGTRAP', + 'SIGSYS', + 'SIGQUIT', + 'SIGIOT' + // should detect profiler and enable/disable accordingly. + // see #21 + // 'SIGPROF' + ) +} -module.exports = (obj, opts) => { - opts = Object.assign({ - exclude: [/.+(Sync|Stream)$/], - errorFirst: true, - promiseModule: Promise - }, opts); +if (process.platform === 'linux') { + module.exports.push( + 'SIGIO', + 'SIGPOLL', + 'SIGPWR', + 'SIGSTKFLT', + 'SIGUNUSED' + ) +} - const filter = key => { - const match = pattern => typeof pattern === 'string' ? key === pattern : pattern.test(key); - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; - let ret; - if (typeof obj === 'function') { - ret = function () { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } +/***/ }), +/* 171 */ +/***/ (function(module, exports, __webpack_require__) { - return processFn(obj, opts).apply(this, arguments); - }; - } else { - ret = Object.create(Object.getPrototypeOf(obj)); - } +"use strict"; - for (const key in obj) { // eslint-disable-line guard-for-in - const x = obj[key]; - ret[key] = typeof x === 'function' && filter(key) ? processFn(x, opts) : x; - } +var toString = Object.prototype.toString; - return ret; +module.exports = function (x) { + var prototype; + return toString.call(x) === '[object Object]' && (prototype = Object.getPrototypeOf(x), prototype === null || prototype === Object.getPrototypeOf({})); }; /***/ }), -/* 193 */ +/* 172 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -19641,7 +18770,7 @@ module.exports = str => { /***/ }), -/* 194 */ +/* 173 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -19693,7 +18822,7 @@ let runScriptInPackage = exports.runScriptInPackage = (() => { exports.runScriptInPackageStreaming = runScriptInPackageStreaming; -var _child_process = __webpack_require__(195); +var _child_process = __webpack_require__(174); function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* * Licensed to Elasticsearch B.V. under one or more contributor @@ -19725,7 +18854,7 @@ function runScriptInPackageStreaming(script, args, pkg) { } /***/ }), -/* 195 */ +/* 174 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -19758,19 +18887,19 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument exports.spawn = spawn; exports.spawnStreaming = spawnStreaming; -var _chalk = __webpack_require__(17); +var _chalk = __webpack_require__(30); var _chalk2 = _interopRequireDefault(_chalk); -var _execa = __webpack_require__(196); +var _execa = __webpack_require__(175); var _execa2 = _interopRequireDefault(_execa); -var _logSymbols = __webpack_require__(95); +var _logSymbols = __webpack_require__(110); var _logSymbols2 = _interopRequireDefault(_logSymbols); -var _strongLogTransformer = __webpack_require__(227); +var _strongLogTransformer = __webpack_require__(206); var _strongLogTransformer2 = _interopRequireDefault(_strongLogTransformer); @@ -19804,23 +18933,23 @@ function spawnStreaming(command, args, opts, { prefix }) { } /***/ }), -/* 196 */ +/* 175 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const path = __webpack_require__(2); -const childProcess = __webpack_require__(59); -const util = __webpack_require__(8); -const crossSpawn = __webpack_require__(197); -const stripEof = __webpack_require__(213); -const npmRunPath = __webpack_require__(214); -const isStream = __webpack_require__(216); -const _getStream = __webpack_require__(217); -const pFinally = __webpack_require__(219); -const onExit = __webpack_require__(58); -const errname = __webpack_require__(220); -const stdio = __webpack_require__(221); +const path = __webpack_require__(7); +const childProcess = __webpack_require__(90); +const util = __webpack_require__(19); +const crossSpawn = __webpack_require__(176); +const stripEof = __webpack_require__(192); +const npmRunPath = __webpack_require__(193); +const isStream = __webpack_require__(195); +const _getStream = __webpack_require__(196); +const pFinally = __webpack_require__(198); +const onExit = __webpack_require__(89); +const errname = __webpack_require__(199); +const stdio = __webpack_require__(200); const TEN_MEGABYTES = 1000 * 1000 * 10; @@ -20174,15 +19303,15 @@ module.exports.spawn = util.deprecate(module.exports, 'execa.spawn() is deprecat /***/ }), -/* 197 */ +/* 176 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var cp = __webpack_require__(59); -var parse = __webpack_require__(198); -var enoent = __webpack_require__(211); +var cp = __webpack_require__(90); +var parse = __webpack_require__(177); +var enoent = __webpack_require__(190); var cpSpawnSync = cp.spawnSync; @@ -20209,7 +19338,7 @@ function spawnSync(command, args, options) { if (!cpSpawnSync) { try { - cpSpawnSync = __webpack_require__(212); // eslint-disable-line global-require + cpSpawnSync = __webpack_require__(191); // eslint-disable-line global-require } catch (ex) { throw new Error( 'In order to use spawnSync on node 0.10 or older, you must ' + @@ -20240,17 +19369,17 @@ module.exports._enoent = enoent; /***/ }), -/* 198 */ +/* 177 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var resolveCommand = __webpack_require__(92); -var hasEmptyArgumentBug = __webpack_require__(206); -var escapeArgument = __webpack_require__(94); -var escapeCommand = __webpack_require__(207); -var readShebang = __webpack_require__(208); +var resolveCommand = __webpack_require__(107); +var hasEmptyArgumentBug = __webpack_require__(185); +var escapeArgument = __webpack_require__(109); +var escapeCommand = __webpack_require__(186); +var readShebang = __webpack_require__(187); var isWin = process.platform === 'win32'; var skipShellRegExp = /\.(?:com|exe)$/i; @@ -20360,7 +19489,7 @@ module.exports = parse; /***/ }), -/* 199 */ +/* 178 */ /***/ (function(module, exports, __webpack_require__) { module.exports = which @@ -20370,9 +19499,9 @@ var isWindows = process.platform === 'win32' || process.env.OSTYPE === 'cygwin' || process.env.OSTYPE === 'msys' -var path = __webpack_require__(2) +var path = __webpack_require__(7) var COLON = isWindows ? ';' : ':' -var isexe = __webpack_require__(200) +var isexe = __webpack_require__(179) function getNotFoundError (cmd) { var er = new Error('not found: ' + cmd) @@ -20501,15 +19630,15 @@ function whichSync (cmd, opt) { /***/ }), -/* 200 */ +/* 179 */ /***/ (function(module, exports, __webpack_require__) { -var fs = __webpack_require__(6) +var fs = __webpack_require__(16) var core if (process.platform === 'win32' || global.TESTING_WINDOWS) { - core = __webpack_require__(201) + core = __webpack_require__(180) } else { - core = __webpack_require__(202) + core = __webpack_require__(181) } module.exports = isexe @@ -20564,13 +19693,13 @@ function sync (path, options) { /***/ }), -/* 201 */ +/* 180 */ /***/ (function(module, exports, __webpack_require__) { module.exports = isexe isexe.sync = sync -var fs = __webpack_require__(6) +var fs = __webpack_require__(16) function checkPathExt (path, options) { var pathext = options.pathExt !== undefined ? @@ -20612,13 +19741,13 @@ function sync (path, options) { /***/ }), -/* 202 */ +/* 181 */ /***/ (function(module, exports, __webpack_require__) { module.exports = isexe isexe.sync = sync -var fs = __webpack_require__(6) +var fs = __webpack_require__(16) function isexe (path, options, cb) { fs.stat(path, function (er, stat) { @@ -20659,7 +19788,7 @@ function checkMode (stat, options) { /***/ }), -/* 203 */ +/* 182 */ /***/ (function(module, exports, __webpack_require__) { if (process.env.npm_package_name === 'pseudomap' && @@ -20669,12 +19798,12 @@ if (process.env.npm_package_name === 'pseudomap' && if (typeof Map === 'function' && !process.env.TEST_PSEUDOMAP) { module.exports = Map } else { - module.exports = __webpack_require__(204) + module.exports = __webpack_require__(183) } /***/ }), -/* 204 */ +/* 183 */ /***/ (function(module, exports) { var hasOwnProperty = Object.prototype.hasOwnProperty @@ -20793,7 +19922,7 @@ function set (data, k, v) { /***/ }), -/* 205 */ +/* 184 */ /***/ (function(module, exports) { module.exports = Yallist @@ -21169,7 +20298,7 @@ function Node (value, prev, next, list) { /***/ }), -/* 206 */ +/* 185 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21194,13 +20323,13 @@ module.exports = hasEmptyArgumentBug(); /***/ }), -/* 207 */ +/* 186 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var escapeArgument = __webpack_require__(94); +var escapeArgument = __webpack_require__(109); function escapeCommand(command) { // Do not escape if this command is not dangerous.. @@ -21213,15 +20342,15 @@ module.exports = escapeCommand; /***/ }), -/* 208 */ +/* 187 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var fs = __webpack_require__(6); -var LRU = __webpack_require__(93); -var shebangCommand = __webpack_require__(209); +var fs = __webpack_require__(16); +var LRU = __webpack_require__(108); +var shebangCommand = __webpack_require__(188); var shebangCache = new LRU({ max: 50, maxAge: 30 * 1000 }); // Cache just for 30sec @@ -21257,12 +20386,12 @@ module.exports = readShebang; /***/ }), -/* 209 */ +/* 188 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var shebangRegex = __webpack_require__(210); +var shebangRegex = __webpack_require__(189); module.exports = function (str) { var match = str.match(shebangRegex); @@ -21283,7 +20412,7 @@ module.exports = function (str) { /***/ }), -/* 210 */ +/* 189 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21292,14 +20421,14 @@ module.exports = /^#!.*/; /***/ }), -/* 211 */ +/* 190 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; var isWin = process.platform === 'win32'; -var resolveCommand = __webpack_require__(92); +var resolveCommand = __webpack_require__(107); var isNode10 = process.version.indexOf('v0.10.') === 0; @@ -21372,17 +20501,17 @@ module.exports.notFoundError = notFoundError; /***/ }), -/* 212 */ +/* 191 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -module.exports = __webpack_require__(59).spawnSync; +module.exports = __webpack_require__(90).spawnSync; /***/ }), -/* 213 */ +/* 192 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21404,13 +20533,13 @@ module.exports = function (x) { /***/ }), -/* 214 */ +/* 193 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const path = __webpack_require__(2); -const pathKey = __webpack_require__(215); +const path = __webpack_require__(7); +const pathKey = __webpack_require__(194); module.exports = opts => { opts = Object.assign({ @@ -21450,7 +20579,7 @@ module.exports.env = opts => { /***/ }), -/* 215 */ +/* 194 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21470,7 +20599,7 @@ module.exports = opts => { /***/ }), -/* 216 */ +/* 195 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21498,12 +20627,12 @@ isStream.transform = function (stream) { /***/ }), -/* 217 */ +/* 196 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const bufferStream = __webpack_require__(218); +const bufferStream = __webpack_require__(197); function getStream(inputStream, opts) { if (!inputStream) { @@ -21556,12 +20685,12 @@ module.exports.array = (stream, opts) => getStream(stream, Object.assign({}, opt /***/ }), -/* 218 */ +/* 197 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const PassThrough = __webpack_require__(21).PassThrough; +const PassThrough = __webpack_require__(41).PassThrough; module.exports = opts => { opts = Object.assign({}, opts); @@ -21614,7 +20743,7 @@ module.exports = opts => { /***/ }), -/* 219 */ +/* 198 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21636,7 +20765,7 @@ module.exports = (promise, onFinally) => { /***/ }), -/* 220 */ +/* 199 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21680,7 +20809,7 @@ module.exports.__test__ = errname; /***/ }), -/* 221 */ +/* 200 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -21728,16 +20857,16 @@ module.exports = opts => { /***/ }), -/* 222 */ +/* 201 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const escapeStringRegexp = __webpack_require__(51); -const ansiStyles = __webpack_require__(223); -const supportsColor = __webpack_require__(224); +const escapeStringRegexp = __webpack_require__(82); +const ansiStyles = __webpack_require__(202); +const supportsColor = __webpack_require__(203); -const template = __webpack_require__(226); +const template = __webpack_require__(205); const isSimpleWindowsTerm = process.platform === 'win32' && !(process.env.TERM || '').toLowerCase().startsWith('xterm'); @@ -21963,12 +21092,12 @@ module.exports.default = module.exports; // For TypeScript /***/ }), -/* 223 */ +/* 202 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(module) { -const colorConvert = __webpack_require__(52); +const colorConvert = __webpack_require__(83); const wrapAnsi16 = (fn, offset) => function () { const code = fn.apply(colorConvert, arguments); @@ -22120,16 +21249,16 @@ Object.defineProperty(module, 'exports', { get: assembleStyles }); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(38)(module))) +/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(59)(module))) /***/ }), -/* 224 */ +/* 203 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const os = __webpack_require__(53); -const hasFlag = __webpack_require__(225); +const os = __webpack_require__(84); +const hasFlag = __webpack_require__(204); const env = process.env; @@ -22245,7 +21374,7 @@ module.exports = process && support(supportLevel); /***/ }), -/* 225 */ +/* 204 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -22262,7 +21391,7 @@ module.exports = function (flag, argv) { /***/ }), -/* 226 */ +/* 205 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -22397,7 +21526,7 @@ module.exports = (chalk, tmp) => { /***/ }), -/* 227 */ +/* 206 */ /***/ (function(module, exports, __webpack_require__) { // Copyright IBM Corp. 2014,2018. All Rights Reserved. @@ -22405,12 +21534,12 @@ module.exports = (chalk, tmp) => { // This file is licensed under the Apache License 2.0. // License text available at https://opensource.org/licenses/Apache-2.0 -module.exports = __webpack_require__(96); -module.exports.cli = __webpack_require__(232); +module.exports = __webpack_require__(111); +module.exports.cli = __webpack_require__(211); /***/ }), -/* 228 */ +/* 207 */ /***/ (function(module, exports, __webpack_require__) { // Copyright (C) 2011-2015 John Hewson @@ -22433,9 +21562,9 @@ module.exports.cli = __webpack_require__(232); // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS // IN THE SOFTWARE. -var stream = __webpack_require__(21), - util = __webpack_require__(8), - timers = __webpack_require__(229); +var stream = __webpack_require__(41), + util = __webpack_require__(19), + timers = __webpack_require__(208); // convinience API module.exports = function(readStream, options) { @@ -22571,16 +21700,16 @@ LineStream.prototype._reencode = function(line, chunkEncoding) { /***/ }), -/* 229 */ +/* 208 */ /***/ (function(module, exports) { module.exports = require("timers"); /***/ }), -/* 230 */ +/* 209 */ /***/ (function(module, exports, __webpack_require__) { -var Stream = __webpack_require__(21) +var Stream = __webpack_require__(41) // through // @@ -22691,10 +21820,10 @@ function through (write, end, opts) { /***/ }), -/* 231 */ +/* 210 */ /***/ (function(module, exports, __webpack_require__) { -var Stream = __webpack_require__(21) +var Stream = __webpack_require__(41) var writeMethods = ["write", "end", "destroy"] var readMethods = ["resume", "pause"] var readEvents = ["data", "close"] @@ -22784,7 +21913,7 @@ function duplex(writer, reader) { /***/ }), -/* 232 */ +/* 211 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -22795,11 +21924,11 @@ function duplex(writer, reader) { -var minimist = __webpack_require__(233); -var path = __webpack_require__(2); +var minimist = __webpack_require__(212); +var path = __webpack_require__(7); -var Logger = __webpack_require__(96); -var pkg = __webpack_require__(234); +var Logger = __webpack_require__(111); +var pkg = __webpack_require__(213); module.exports = cli; @@ -22853,7 +21982,7 @@ function usage($0, p) { /***/ }), -/* 233 */ +/* 212 */ /***/ (function(module, exports) { module.exports = function (args, opts) { @@ -23095,13 +22224,13 @@ function isNumber (x) { /***/ }), -/* 234 */ -/***/ (function(module, exports) { +/* 213 */ +/***/ (function(module) { -module.exports = {"name":"strong-log-transformer","version":"2.0.0","description":"Stream transformer that prefixes lines with timestamps and other things.","author":"Ryan Graham ","license":"Apache-2.0","repository":{"type":"git","url":"git://github.com/strongloop/strong-log-transformer"},"keywords":["logging","streams"],"bugs":{"url":"https://github.com/strongloop/strong-log-transformer/issues"},"homepage":"https://github.com/strongloop/strong-log-transformer","directories":{"test":"test"},"bin":{"sl-log-transformer":"bin/sl-log-transformer.js"},"main":"index.js","scripts":{"test":"tap --100 test/test-*"},"dependencies":{"byline":"^5.0.0","duplexer":"^0.1.1","minimist":"^1.2.0","through":"^2.3.4"},"devDependencies":{"tap":"^12.0.1"},"engines":{"node":">=4"}} +module.exports = {"name":"strong-log-transformer","version":"2.0.0","description":"Stream transformer that prefixes lines with timestamps and other things.","author":"Ryan Graham ","license":"Apache-2.0","repository":{"type":"git","url":"git://github.com/strongloop/strong-log-transformer"},"keywords":["logging","streams"],"bugs":{"url":"https://github.com/strongloop/strong-log-transformer/issues"},"homepage":"https://github.com/strongloop/strong-log-transformer","directories":{"test":"test"},"bin":{"sl-log-transformer":"bin/sl-log-transformer.js"},"main":"index.js","scripts":{"test":"tap --100 test/test-*"},"dependencies":{"byline":"^5.0.0","duplexer":"^0.1.1","minimist":"^1.2.0","through":"^2.3.4"},"devDependencies":{"tap":"^12.0.1"},"engines":{"node":">=4"}}; /***/ }), -/* 235 */ +/* 214 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -23112,23 +22241,23 @@ Object.defineProperty(exports, "__esModule", { }); exports.CleanCommand = undefined; -var _chalk = __webpack_require__(17); +var _chalk = __webpack_require__(30); var _chalk2 = _interopRequireDefault(_chalk); -var _del = __webpack_require__(98); +var _del = __webpack_require__(113); var _del2 = _interopRequireDefault(_del); -var _ora = __webpack_require__(247); +var _ora = __webpack_require__(225); var _ora2 = _interopRequireDefault(_ora); -var _path = __webpack_require__(2); +var _path = __webpack_require__(7); -var _fs = __webpack_require__(39); +var _fs = __webpack_require__(60); -var _log = __webpack_require__(19); +var _log = __webpack_require__(36); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -23211,16 +22340,16 @@ const CleanCommand = exports.CleanCommand = { }; /***/ }), -/* 236 */ +/* 215 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var Promise = __webpack_require__(99); -var arrayUnion = __webpack_require__(100); -var objectAssign = __webpack_require__(101); -var glob = __webpack_require__(23); -var pify = __webpack_require__(239); +var Promise = __webpack_require__(114); +var arrayUnion = __webpack_require__(115); +var objectAssign = __webpack_require__(116); +var glob = __webpack_require__(43); +var pify = __webpack_require__(218); var globP = pify(glob, Promise).bind(glob); @@ -23306,7 +22435,7 @@ module.exports.hasMagic = function (patterns, opts) { /***/ }), -/* 237 */ +/* 216 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -23605,7 +22734,7 @@ module.exports = Promise; /***/ }), -/* 238 */ +/* 217 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -23674,7 +22803,7 @@ if ('Set' in global) { /***/ }), -/* 239 */ +/* 218 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -23749,12 +22878,12 @@ pify.all = pify; /***/ }), -/* 240 */ +/* 219 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var path = __webpack_require__(2); +var path = __webpack_require__(7); module.exports = function (str) { return path.resolve(str) === path.resolve(process.cwd()); @@ -23762,12 +22891,12 @@ module.exports = function (str) { /***/ }), -/* 241 */ +/* 220 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -var isPathInside = __webpack_require__(242); +var isPathInside = __webpack_require__(221); module.exports = function (str) { return isPathInside(str, process.cwd()); @@ -23775,163 +22904,72 @@ module.exports = function (str) { /***/ }), -/* 242 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - -var path = __webpack_require__(2); -var pathIsInside = __webpack_require__(243); - -module.exports = function (a, b) { - a = path.resolve(a); - b = path.resolve(b); - - if (a === b) { - return false; - } - - return pathIsInside(a, b); -}; - - -/***/ }), -/* 243 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -var path = __webpack_require__(2); - -module.exports = function (thePath, potentialParent) { - // For inside-directory checking, we want to allow trailing slashes, so normalize. - thePath = stripTrailingSep(thePath); - potentialParent = stripTrailingSep(potentialParent); - - // Node treats only Windows as case-insensitive in its path module; we follow those conventions. - if (process.platform === "win32") { - thePath = thePath.toLowerCase(); - potentialParent = potentialParent.toLowerCase(); - } - - return thePath.lastIndexOf(potentialParent, 0) === 0 && - ( - thePath[potentialParent.length] === path.sep || - thePath[potentialParent.length] === undefined - ); -}; - -function stripTrailingSep(thePath) { - if (thePath[thePath.length - 1] === path.sep) { - return thePath.slice(0, -1); - } - return thePath; -} - - -/***/ }), -/* 244 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -const processFn = (fn, opts) => function () { - const P = opts.promiseModule; - const args = new Array(arguments.length); - - for (let i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } - - return new P((resolve, reject) => { - if (opts.errorFirst) { - args.push(function (err, result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - - for (let i = 1; i < arguments.length; i++) { - results[i - 1] = arguments[i]; - } - - if (err) { - results.unshift(err); - reject(results); - } else { - resolve(results); - } - } else if (err) { - reject(err); - } else { - resolve(result); - } - }); - } else { - args.push(function (result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); +/* 221 */ +/***/ (function(module, exports, __webpack_require__) { - for (let i = 0; i < arguments.length; i++) { - results[i] = arguments[i]; - } +"use strict"; - resolve(results); - } else { - resolve(result); - } - }); - } +var path = __webpack_require__(7); +var pathIsInside = __webpack_require__(222); - fn.apply(this, args); - }); +module.exports = function (a, b) { + a = path.resolve(a); + b = path.resolve(b); + + if (a === b) { + return false; + } + + return pathIsInside(a, b); }; -module.exports = (obj, opts) => { - opts = Object.assign({ - exclude: [/.+(Sync|Stream)$/], - errorFirst: true, - promiseModule: Promise - }, opts); - const filter = key => { - const match = pattern => typeof pattern === 'string' ? key === pattern : pattern.test(key); - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; +/***/ }), +/* 222 */ +/***/ (function(module, exports, __webpack_require__) { - let ret; - if (typeof obj === 'function') { - ret = function () { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } +"use strict"; - return processFn(obj, opts).apply(this, arguments); - }; - } else { - ret = Object.create(Object.getPrototypeOf(obj)); - } - for (const key in obj) { // eslint-disable-line guard-for-in - const x = obj[key]; - ret[key] = typeof x === 'function' && filter(key) ? processFn(x, opts) : x; - } +var path = __webpack_require__(7); - return ret; +module.exports = function (thePath, potentialParent) { + // For inside-directory checking, we want to allow trailing slashes, so normalize. + thePath = stripTrailingSep(thePath); + potentialParent = stripTrailingSep(potentialParent); + + // Node treats only Windows as case-insensitive in its path module; we follow those conventions. + if (process.platform === "win32") { + thePath = thePath.toLowerCase(); + potentialParent = potentialParent.toLowerCase(); + } + + return thePath.lastIndexOf(potentialParent, 0) === 0 && + ( + thePath[potentialParent.length] === path.sep || + thePath[potentialParent.length] === undefined + ); }; +function stripTrailingSep(thePath) { + if (thePath[thePath.length - 1] === path.sep) { + return thePath.slice(0, -1); + } + return thePath; +} + /***/ }), -/* 245 */ +/* 223 */ /***/ (function(module, exports, __webpack_require__) { module.exports = rimraf rimraf.sync = rimrafSync -var assert = __webpack_require__(28) -var path = __webpack_require__(2) -var fs = __webpack_require__(6) -var glob = __webpack_require__(23) +var assert = __webpack_require__(57) +var path = __webpack_require__(7) +var fs = __webpack_require__(16) +var glob = __webpack_require__(43) var _0666 = parseInt('666', 8) var defaultGlobOpts = { @@ -24292,7 +23330,7 @@ function rmkidsSync (p, options) { /***/ }), -/* 246 */ +/* 224 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -24366,15 +23404,15 @@ module.exports = (iterable, mapper, opts) => new Promise((resolve, reject) => { /***/ }), -/* 247 */ +/* 225 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const chalk = __webpack_require__(248); -const cliCursor = __webpack_require__(252); -const cliSpinners = __webpack_require__(256); -const logSymbols = __webpack_require__(95); +const chalk = __webpack_require__(226); +const cliCursor = __webpack_require__(230); +const cliSpinners = __webpack_require__(234); +const logSymbols = __webpack_require__(110); class Ora { constructor(options) { @@ -24521,16 +23559,16 @@ module.exports.promise = (action, options) => { /***/ }), -/* 248 */ +/* 226 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const escapeStringRegexp = __webpack_require__(51); -const ansiStyles = __webpack_require__(249); -const stdoutColor = __webpack_require__(250).stdout; +const escapeStringRegexp = __webpack_require__(82); +const ansiStyles = __webpack_require__(227); +const stdoutColor = __webpack_require__(228).stdout; -const template = __webpack_require__(251); +const template = __webpack_require__(229); const isSimpleWindowsTerm = process.platform === 'win32' && !(process.env.TERM || '').toLowerCase().startsWith('xterm'); @@ -24756,12 +23794,12 @@ module.exports.default = module.exports; // For TypeScript /***/ }), -/* 249 */ +/* 227 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; /* WEBPACK VAR INJECTION */(function(module) { -const colorConvert = __webpack_require__(52); +const colorConvert = __webpack_require__(83); const wrapAnsi16 = (fn, offset) => function () { const code = fn.apply(colorConvert, arguments); @@ -24926,16 +23964,16 @@ Object.defineProperty(module, 'exports', { get: assembleStyles }); -/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(38)(module))) +/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(59)(module))) /***/ }), -/* 250 */ +/* 228 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const os = __webpack_require__(53); -const hasFlag = __webpack_require__(78); +const os = __webpack_require__(84); +const hasFlag = __webpack_require__(93); const env = process.env; @@ -25071,7 +24109,7 @@ module.exports = { /***/ }), -/* 251 */ +/* 229 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -25206,12 +24244,12 @@ module.exports = (chalk, tmp) => { /***/ }), -/* 252 */ +/* 230 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const restoreCursor = __webpack_require__(253); +const restoreCursor = __webpack_require__(231); let hidden = false; @@ -25252,13 +24290,13 @@ exports.toggle = (force, stream) => { /***/ }), -/* 253 */ +/* 231 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const onetime = __webpack_require__(254); -const signalExit = __webpack_require__(58); +const onetime = __webpack_require__(232); +const signalExit = __webpack_require__(89); module.exports = onetime(() => { signalExit(() => { @@ -25268,12 +24306,12 @@ module.exports = onetime(() => { /***/ }), -/* 254 */ +/* 232 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -const mimicFn = __webpack_require__(255); +const mimicFn = __webpack_require__(233); module.exports = (fn, opts) => { // TODO: Remove this in v3 @@ -25314,7 +24352,7 @@ module.exports = (fn, opts) => { /***/ }), -/* 255 */ +/* 233 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -25328,22 +24366,22 @@ module.exports = (to, from) => { /***/ }), -/* 256 */ +/* 234 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; -module.exports = __webpack_require__(257); +module.exports = __webpack_require__(235); /***/ }), -/* 257 */ -/***/ (function(module, exports) { +/* 235 */ +/***/ (function(module) { -module.exports = {"dots":{"interval":80,"frames":["⠋","⠙","⠹","⠸","⠼","⠴","⠦","⠧","⠇","⠏"]},"dots2":{"interval":80,"frames":["⣾","⣽","⣻","⢿","⡿","⣟","⣯","⣷"]},"dots3":{"interval":80,"frames":["⠋","⠙","⠚","⠞","⠖","⠦","⠴","⠲","⠳","⠓"]},"dots4":{"interval":80,"frames":["⠄","⠆","⠇","⠋","⠙","⠸","⠰","⠠","⠰","⠸","⠙","⠋","⠇","⠆"]},"dots5":{"interval":80,"frames":["⠋","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋"]},"dots6":{"interval":80,"frames":["⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠴","⠲","⠒","⠂","⠂","⠒","⠚","⠙","⠉","⠁"]},"dots7":{"interval":80,"frames":["⠈","⠉","⠋","⠓","⠒","⠐","⠐","⠒","⠖","⠦","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈"]},"dots8":{"interval":80,"frames":["⠁","⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈","⠈"]},"dots9":{"interval":80,"frames":["⢹","⢺","⢼","⣸","⣇","⡧","⡗","⡏"]},"dots10":{"interval":80,"frames":["⢄","⢂","⢁","⡁","⡈","⡐","⡠"]},"dots11":{"interval":100,"frames":["⠁","⠂","⠄","⡀","⢀","⠠","⠐","⠈"]},"dots12":{"interval":80,"frames":["⢀⠀","⡀⠀","⠄⠀","⢂⠀","⡂⠀","⠅⠀","⢃⠀","⡃⠀","⠍⠀","⢋⠀","⡋⠀","⠍⠁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⢈⠩","⡀⢙","⠄⡙","⢂⠩","⡂⢘","⠅⡘","⢃⠨","⡃⢐","⠍⡐","⢋⠠","⡋⢀","⠍⡁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⠈⠩","⠀⢙","⠀⡙","⠀⠩","⠀⢘","⠀⡘","⠀⠨","⠀⢐","⠀⡐","⠀⠠","⠀⢀","⠀⡀"]},"line":{"interval":130,"frames":["-","\\","|","/"]},"line2":{"interval":100,"frames":["⠂","-","–","—","–","-"]},"pipe":{"interval":100,"frames":["┤","┘","┴","└","├","┌","┬","┐"]},"simpleDots":{"interval":400,"frames":[". ",".. ","..."," "]},"simpleDotsScrolling":{"interval":200,"frames":[". ",".. ","..."," .."," ."," "]},"star":{"interval":70,"frames":["✶","✸","✹","✺","✹","✷"]},"star2":{"interval":80,"frames":["+","x","*"]},"flip":{"interval":70,"frames":["_","_","_","-","`","`","'","´","-","_","_","_"]},"hamburger":{"interval":100,"frames":["☱","☲","☴"]},"growVertical":{"interval":120,"frames":["▁","▃","▄","▅","▆","▇","▆","▅","▄","▃"]},"growHorizontal":{"interval":120,"frames":["▏","▎","▍","▌","▋","▊","▉","▊","▋","▌","▍","▎"]},"balloon":{"interval":140,"frames":[" ",".","o","O","@","*"," "]},"balloon2":{"interval":120,"frames":[".","o","O","°","O","o","."]},"noise":{"interval":100,"frames":["▓","▒","░"]},"bounce":{"interval":120,"frames":["⠁","⠂","⠄","⠂"]},"boxBounce":{"interval":120,"frames":["▖","▘","▝","▗"]},"boxBounce2":{"interval":100,"frames":["▌","▀","▐","▄"]},"triangle":{"interval":50,"frames":["◢","◣","◤","◥"]},"arc":{"interval":100,"frames":["◜","◠","◝","◞","◡","◟"]},"circle":{"interval":120,"frames":["◡","⊙","◠"]},"squareCorners":{"interval":180,"frames":["◰","◳","◲","◱"]},"circleQuarters":{"interval":120,"frames":["◴","◷","◶","◵"]},"circleHalves":{"interval":50,"frames":["◐","◓","◑","◒"]},"squish":{"interval":100,"frames":["╫","╪"]},"toggle":{"interval":250,"frames":["⊶","⊷"]},"toggle2":{"interval":80,"frames":["▫","▪"]},"toggle3":{"interval":120,"frames":["□","■"]},"toggle4":{"interval":100,"frames":["■","□","▪","▫"]},"toggle5":{"interval":100,"frames":["▮","▯"]},"toggle6":{"interval":300,"frames":["ဝ","၀"]},"toggle7":{"interval":80,"frames":["⦾","⦿"]},"toggle8":{"interval":100,"frames":["◍","◌"]},"toggle9":{"interval":100,"frames":["◉","◎"]},"toggle10":{"interval":100,"frames":["㊂","㊀","㊁"]},"toggle11":{"interval":50,"frames":["⧇","⧆"]},"toggle12":{"interval":120,"frames":["☗","☖"]},"toggle13":{"interval":80,"frames":["=","*","-"]},"arrow":{"interval":100,"frames":["←","↖","↑","↗","→","↘","↓","↙"]},"arrow2":{"interval":80,"frames":["⬆️ ","↗️ ","➡️ ","↘️ ","⬇️ ","↙️ ","⬅️ ","↖️ "]},"arrow3":{"interval":120,"frames":["▹▹▹▹▹","▸▹▹▹▹","▹▸▹▹▹","▹▹▸▹▹","▹▹▹▸▹","▹▹▹▹▸"]},"bouncingBar":{"interval":80,"frames":["[ ]","[= ]","[== ]","[=== ]","[ ===]","[ ==]","[ =]","[ ]","[ =]","[ ==]","[ ===]","[====]","[=== ]","[== ]","[= ]"]},"bouncingBall":{"interval":80,"frames":["( ● )","( ● )","( ● )","( ● )","( ●)","( ● )","( ● )","( ● )","( ● )","(● )"]},"smiley":{"interval":200,"frames":["😄 ","😝 "]},"monkey":{"interval":300,"frames":["🙈 ","🙈 ","🙉 ","🙊 "]},"hearts":{"interval":100,"frames":["💛 ","💙 ","💜 ","💚 ","❤️ "]},"clock":{"interval":100,"frames":["🕐 ","🕑 ","🕒 ","🕓 ","🕔 ","🕕 ","🕖 ","🕗 ","🕘 ","🕙 ","🕚 "]},"earth":{"interval":180,"frames":["🌍 ","🌎 ","🌏 "]},"moon":{"interval":80,"frames":["🌑 ","🌒 ","🌓 ","🌔 ","🌕 ","🌖 ","🌗 ","🌘 "]},"runner":{"interval":140,"frames":["🚶 ","🏃 "]},"pong":{"interval":80,"frames":["▐⠂ ▌","▐⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂▌","▐ ⠠▌","▐ ⡀▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐⠠ ▌"]},"shark":{"interval":120,"frames":["▐|\\____________▌","▐_|\\___________▌","▐__|\\__________▌","▐___|\\_________▌","▐____|\\________▌","▐_____|\\_______▌","▐______|\\______▌","▐_______|\\_____▌","▐________|\\____▌","▐_________|\\___▌","▐__________|\\__▌","▐___________|\\_▌","▐____________|\\▌","▐____________/|▌","▐___________/|_▌","▐__________/|__▌","▐_________/|___▌","▐________/|____▌","▐_______/|_____▌","▐______/|______▌","▐_____/|_______▌","▐____/|________▌","▐___/|_________▌","▐__/|__________▌","▐_/|___________▌","▐/|____________▌"]},"dqpb":{"interval":100,"frames":["d","q","p","b"]},"weather":{"interval":100,"frames":["☀️ ","☀️ ","☀️ ","🌤 ","⛅️ ","🌥 ","☁️ ","🌧 ","🌨 ","🌧 ","🌨 ","🌧 ","🌨 ","⛈ ","🌨 ","🌧 ","🌨 ","☁️ ","🌥 ","⛅️ ","🌤 ","☀️ ","☀️ "]},"christmas":{"interval":400,"frames":["🌲","🎄"]}} +module.exports = {"dots":{"interval":80,"frames":["⠋","⠙","⠹","⠸","⠼","⠴","⠦","⠧","⠇","⠏"]},"dots2":{"interval":80,"frames":["⣾","⣽","⣻","⢿","⡿","⣟","⣯","⣷"]},"dots3":{"interval":80,"frames":["⠋","⠙","⠚","⠞","⠖","⠦","⠴","⠲","⠳","⠓"]},"dots4":{"interval":80,"frames":["⠄","⠆","⠇","⠋","⠙","⠸","⠰","⠠","⠰","⠸","⠙","⠋","⠇","⠆"]},"dots5":{"interval":80,"frames":["⠋","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋"]},"dots6":{"interval":80,"frames":["⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠴","⠲","⠒","⠂","⠂","⠒","⠚","⠙","⠉","⠁"]},"dots7":{"interval":80,"frames":["⠈","⠉","⠋","⠓","⠒","⠐","⠐","⠒","⠖","⠦","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈"]},"dots8":{"interval":80,"frames":["⠁","⠁","⠉","⠙","⠚","⠒","⠂","⠂","⠒","⠲","⠴","⠤","⠄","⠄","⠤","⠠","⠠","⠤","⠦","⠖","⠒","⠐","⠐","⠒","⠓","⠋","⠉","⠈","⠈"]},"dots9":{"interval":80,"frames":["⢹","⢺","⢼","⣸","⣇","⡧","⡗","⡏"]},"dots10":{"interval":80,"frames":["⢄","⢂","⢁","⡁","⡈","⡐","⡠"]},"dots11":{"interval":100,"frames":["⠁","⠂","⠄","⡀","⢀","⠠","⠐","⠈"]},"dots12":{"interval":80,"frames":["⢀⠀","⡀⠀","⠄⠀","⢂⠀","⡂⠀","⠅⠀","⢃⠀","⡃⠀","⠍⠀","⢋⠀","⡋⠀","⠍⠁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⢈⠩","⡀⢙","⠄⡙","⢂⠩","⡂⢘","⠅⡘","⢃⠨","⡃⢐","⠍⡐","⢋⠠","⡋⢀","⠍⡁","⢋⠁","⡋⠁","⠍⠉","⠋⠉","⠋⠉","⠉⠙","⠉⠙","⠉⠩","⠈⢙","⠈⡙","⠈⠩","⠀⢙","⠀⡙","⠀⠩","⠀⢘","⠀⡘","⠀⠨","⠀⢐","⠀⡐","⠀⠠","⠀⢀","⠀⡀"]},"line":{"interval":130,"frames":["-","\\","|","/"]},"line2":{"interval":100,"frames":["⠂","-","–","—","–","-"]},"pipe":{"interval":100,"frames":["┤","┘","┴","└","├","┌","┬","┐"]},"simpleDots":{"interval":400,"frames":[". ",".. ","..."," "]},"simpleDotsScrolling":{"interval":200,"frames":[". ",".. ","..."," .."," ."," "]},"star":{"interval":70,"frames":["✶","✸","✹","✺","✹","✷"]},"star2":{"interval":80,"frames":["+","x","*"]},"flip":{"interval":70,"frames":["_","_","_","-","`","`","'","´","-","_","_","_"]},"hamburger":{"interval":100,"frames":["☱","☲","☴"]},"growVertical":{"interval":120,"frames":["▁","▃","▄","▅","▆","▇","▆","▅","▄","▃"]},"growHorizontal":{"interval":120,"frames":["▏","▎","▍","▌","▋","▊","▉","▊","▋","▌","▍","▎"]},"balloon":{"interval":140,"frames":[" ",".","o","O","@","*"," "]},"balloon2":{"interval":120,"frames":[".","o","O","°","O","o","."]},"noise":{"interval":100,"frames":["▓","▒","░"]},"bounce":{"interval":120,"frames":["⠁","⠂","⠄","⠂"]},"boxBounce":{"interval":120,"frames":["▖","▘","▝","▗"]},"boxBounce2":{"interval":100,"frames":["▌","▀","▐","▄"]},"triangle":{"interval":50,"frames":["◢","◣","◤","◥"]},"arc":{"interval":100,"frames":["◜","◠","◝","◞","◡","◟"]},"circle":{"interval":120,"frames":["◡","⊙","◠"]},"squareCorners":{"interval":180,"frames":["◰","◳","◲","◱"]},"circleQuarters":{"interval":120,"frames":["◴","◷","◶","◵"]},"circleHalves":{"interval":50,"frames":["◐","◓","◑","◒"]},"squish":{"interval":100,"frames":["╫","╪"]},"toggle":{"interval":250,"frames":["⊶","⊷"]},"toggle2":{"interval":80,"frames":["▫","▪"]},"toggle3":{"interval":120,"frames":["□","■"]},"toggle4":{"interval":100,"frames":["■","□","▪","▫"]},"toggle5":{"interval":100,"frames":["▮","▯"]},"toggle6":{"interval":300,"frames":["ဝ","၀"]},"toggle7":{"interval":80,"frames":["⦾","⦿"]},"toggle8":{"interval":100,"frames":["◍","◌"]},"toggle9":{"interval":100,"frames":["◉","◎"]},"toggle10":{"interval":100,"frames":["㊂","㊀","㊁"]},"toggle11":{"interval":50,"frames":["⧇","⧆"]},"toggle12":{"interval":120,"frames":["☗","☖"]},"toggle13":{"interval":80,"frames":["=","*","-"]},"arrow":{"interval":100,"frames":["←","↖","↑","↗","→","↘","↓","↙"]},"arrow2":{"interval":80,"frames":["⬆️ ","↗️ ","➡️ ","↘️ ","⬇️ ","↙️ ","⬅️ ","↖️ "]},"arrow3":{"interval":120,"frames":["▹▹▹▹▹","▸▹▹▹▹","▹▸▹▹▹","▹▹▸▹▹","▹▹▹▸▹","▹▹▹▹▸"]},"bouncingBar":{"interval":80,"frames":["[ ]","[= ]","[== ]","[=== ]","[ ===]","[ ==]","[ =]","[ ]","[ =]","[ ==]","[ ===]","[====]","[=== ]","[== ]","[= ]"]},"bouncingBall":{"interval":80,"frames":["( ● )","( ● )","( ● )","( ● )","( ●)","( ● )","( ● )","( ● )","( ● )","(● )"]},"smiley":{"interval":200,"frames":["😄 ","😝 "]},"monkey":{"interval":300,"frames":["🙈 ","🙈 ","🙉 ","🙊 "]},"hearts":{"interval":100,"frames":["💛 ","💙 ","💜 ","💚 ","❤️ "]},"clock":{"interval":100,"frames":["🕐 ","🕑 ","🕒 ","🕓 ","🕔 ","🕕 ","🕖 ","🕗 ","🕘 ","🕙 ","🕚 "]},"earth":{"interval":180,"frames":["🌍 ","🌎 ","🌏 "]},"moon":{"interval":80,"frames":["🌑 ","🌒 ","🌓 ","🌔 ","🌕 ","🌖 ","🌗 ","🌘 "]},"runner":{"interval":140,"frames":["🚶 ","🏃 "]},"pong":{"interval":80,"frames":["▐⠂ ▌","▐⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂▌","▐ ⠠▌","▐ ⡀▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐ ⠠ ▌","▐ ⠂ ▌","▐ ⠈ ▌","▐ ⠂ ▌","▐ ⠠ ▌","▐ ⡀ ▌","▐⠠ ▌"]},"shark":{"interval":120,"frames":["▐|\\____________▌","▐_|\\___________▌","▐__|\\__________▌","▐___|\\_________▌","▐____|\\________▌","▐_____|\\_______▌","▐______|\\______▌","▐_______|\\_____▌","▐________|\\____▌","▐_________|\\___▌","▐__________|\\__▌","▐___________|\\_▌","▐____________|\\▌","▐____________/|▌","▐___________/|_▌","▐__________/|__▌","▐_________/|___▌","▐________/|____▌","▐_______/|_____▌","▐______/|______▌","▐_____/|_______▌","▐____/|________▌","▐___/|_________▌","▐__/|__________▌","▐_/|___________▌","▐/|____________▌"]},"dqpb":{"interval":100,"frames":["d","q","p","b"]},"weather":{"interval":100,"frames":["☀️ ","☀️ ","☀️ ","🌤 ","⛅️ ","🌥 ","☁️ ","🌧 ","🌨 ","🌧 ","🌨 ","🌧 ","🌨 ","⛈ ","🌨 ","🌧 ","🌨 ","☁️ ","🌥 ","⛅️ ","🌤 ","☀️ ","☀️ "]},"christmas":{"interval":400,"frames":["🌲","🎄"]}}; /***/ }), -/* 258 */ +/* 236 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -25354,15 +24392,15 @@ Object.defineProperty(exports, "__esModule", { }); exports.RunCommand = undefined; -var _chalk = __webpack_require__(17); +var _chalk = __webpack_require__(30); var _chalk2 = _interopRequireDefault(_chalk); -var _log = __webpack_require__(19); +var _log = __webpack_require__(36); -var _parallelize = __webpack_require__(54); +var _parallelize = __webpack_require__(85); -var _projects = __webpack_require__(22); +var _projects = __webpack_require__(42); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -25415,7 +24453,7 @@ const RunCommand = exports.RunCommand = { }; /***/ }), -/* 259 */ +/* 237 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -25426,17 +24464,17 @@ Object.defineProperty(exports, "__esModule", { }); exports.WatchCommand = undefined; -var _chalk = __webpack_require__(17); +var _chalk = __webpack_require__(30); var _chalk2 = _interopRequireDefault(_chalk); -var _log = __webpack_require__(19); +var _log = __webpack_require__(36); -var _parallelize = __webpack_require__(54); +var _parallelize = __webpack_require__(85); -var _projects = __webpack_require__(22); +var _projects = __webpack_require__(42); -var _watch = __webpack_require__(260); +var _watch = __webpack_require__(238); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } @@ -25518,7 +24556,7 @@ const WatchCommand = exports.WatchCommand = { }; /***/ }), -/* 260 */ +/* 238 */ /***/ (function(module, exports, __webpack_require__) { "use strict"; @@ -25529,11 +24567,11 @@ Object.defineProperty(exports, "__esModule", { }); exports.waitUntilWatchIsReady = waitUntilWatchIsReady; -var _rxjs = __webpack_require__(261); +var _rxjs = __webpack_require__(263); var Rx = _interopRequireWildcard(_rxjs); -var _operators = __webpack_require__(292); +var _operators = __webpack_require__(262); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } @@ -25587,2058 +24625,1760 @@ function waitUntilWatchIsReady(stream, opts = {}) { } /***/ }), -/* 261 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 239 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__internal_Observable__ = __webpack_require__(3); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Observable", function() { return __WEBPACK_IMPORTED_MODULE_0__internal_Observable__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__internal_observable_ConnectableObservable__ = __webpack_require__(105); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "ConnectableObservable", function() { return __WEBPACK_IMPORTED_MODULE_1__internal_observable_ConnectableObservable__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__internal_operators_groupBy__ = __webpack_require__(107); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "GroupedObservable", function() { return __WEBPACK_IMPORTED_MODULE_2__internal_operators_groupBy__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__internal_symbol_observable__ = __webpack_require__(24); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "observable", function() { return __WEBPACK_IMPORTED_MODULE_3__internal_symbol_observable__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__internal_Subject__ = __webpack_require__(9); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Subject", function() { return __WEBPACK_IMPORTED_MODULE_4__internal_Subject__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__internal_BehaviorSubject__ = __webpack_require__(108); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "BehaviorSubject", function() { return __WEBPACK_IMPORTED_MODULE_5__internal_BehaviorSubject__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__internal_ReplaySubject__ = __webpack_require__(65); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "ReplaySubject", function() { return __WEBPACK_IMPORTED_MODULE_6__internal_ReplaySubject__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__internal_AsyncSubject__ = __webpack_require__(46); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "AsyncSubject", function() { return __WEBPACK_IMPORTED_MODULE_7__internal_AsyncSubject__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__internal_scheduler_asap__ = __webpack_require__(113); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "asapScheduler", function() { return __WEBPACK_IMPORTED_MODULE_8__internal_scheduler_asap__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__internal_scheduler_async__ = __webpack_require__(12); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "asyncScheduler", function() { return __WEBPACK_IMPORTED_MODULE_9__internal_scheduler_async__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__internal_scheduler_queue__ = __webpack_require__(109); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "queueScheduler", function() { return __WEBPACK_IMPORTED_MODULE_10__internal_scheduler_queue__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__internal_scheduler_animationFrame__ = __webpack_require__(269); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "animationFrameScheduler", function() { return __WEBPACK_IMPORTED_MODULE_11__internal_scheduler_animationFrame__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__internal_scheduler_VirtualTimeScheduler__ = __webpack_require__(272); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "VirtualTimeScheduler", function() { return __WEBPACK_IMPORTED_MODULE_12__internal_scheduler_VirtualTimeScheduler__["b"]; }); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "VirtualAction", function() { return __WEBPACK_IMPORTED_MODULE_12__internal_scheduler_VirtualTimeScheduler__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__internal_Scheduler__ = __webpack_require__(110); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Scheduler", function() { return __WEBPACK_IMPORTED_MODULE_13__internal_Scheduler__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__internal_Subscription__ = __webpack_require__(7); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Subscription", function() { return __WEBPACK_IMPORTED_MODULE_14__internal_Subscription__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__internal_Subscriber__ = __webpack_require__(1); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Subscriber", function() { return __WEBPACK_IMPORTED_MODULE_15__internal_Subscriber__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_16__internal_Notification__ = __webpack_require__(45); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Notification", function() { return __WEBPACK_IMPORTED_MODULE_16__internal_Notification__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_17__internal_util_pipe__ = __webpack_require__(63); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "pipe", function() { return __WEBPACK_IMPORTED_MODULE_17__internal_util_pipe__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_18__internal_util_noop__ = __webpack_require__(43); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "noop", function() { return __WEBPACK_IMPORTED_MODULE_18__internal_util_noop__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_19__internal_util_identity__ = __webpack_require__(25); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "identity", function() { return __WEBPACK_IMPORTED_MODULE_19__internal_util_identity__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_20__internal_util_isObservable__ = __webpack_require__(273); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "isObservable", function() { return __WEBPACK_IMPORTED_MODULE_20__internal_util_isObservable__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_21__internal_util_ArgumentOutOfRangeError__ = __webpack_require__(32); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "ArgumentOutOfRangeError", function() { return __WEBPACK_IMPORTED_MODULE_21__internal_util_ArgumentOutOfRangeError__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_22__internal_util_EmptyError__ = __webpack_require__(33); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "EmptyError", function() { return __WEBPACK_IMPORTED_MODULE_22__internal_util_EmptyError__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_23__internal_util_ObjectUnsubscribedError__ = __webpack_require__(44); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "ObjectUnsubscribedError", function() { return __WEBPACK_IMPORTED_MODULE_23__internal_util_ObjectUnsubscribedError__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_24__internal_util_UnsubscriptionError__ = __webpack_require__(104); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "UnsubscriptionError", function() { return __WEBPACK_IMPORTED_MODULE_24__internal_util_UnsubscriptionError__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_25__internal_util_TimeoutError__ = __webpack_require__(114); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "TimeoutError", function() { return __WEBPACK_IMPORTED_MODULE_25__internal_util_TimeoutError__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_26__internal_observable_bindCallback__ = __webpack_require__(274); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "bindCallback", function() { return __WEBPACK_IMPORTED_MODULE_26__internal_observable_bindCallback__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_27__internal_observable_bindNodeCallback__ = __webpack_require__(275); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "bindNodeCallback", function() { return __WEBPACK_IMPORTED_MODULE_27__internal_observable_bindNodeCallback__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_28__internal_observable_combineLatest__ = __webpack_require__(69); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "combineLatest", function() { return __WEBPACK_IMPORTED_MODULE_28__internal_observable_combineLatest__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_29__internal_observable_concat__ = __webpack_require__(47); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "concat", function() { return __WEBPACK_IMPORTED_MODULE_29__internal_observable_concat__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_30__internal_observable_defer__ = __webpack_require__(71); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "defer", function() { return __WEBPACK_IMPORTED_MODULE_30__internal_observable_defer__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_31__internal_observable_empty__ = __webpack_require__(11); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "empty", function() { return __WEBPACK_IMPORTED_MODULE_31__internal_observable_empty__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_32__internal_observable_forkJoin__ = __webpack_require__(282); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "forkJoin", function() { return __WEBPACK_IMPORTED_MODULE_32__internal_observable_forkJoin__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_33__internal_observable_from__ = __webpack_require__(18); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "from", function() { return __WEBPACK_IMPORTED_MODULE_33__internal_observable_from__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_34__internal_observable_fromEvent__ = __webpack_require__(283); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "fromEvent", function() { return __WEBPACK_IMPORTED_MODULE_34__internal_observable_fromEvent__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_35__internal_observable_fromEventPattern__ = __webpack_require__(284); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "fromEventPattern", function() { return __WEBPACK_IMPORTED_MODULE_35__internal_observable_fromEventPattern__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_36__internal_observable_generate__ = __webpack_require__(285); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "generate", function() { return __WEBPACK_IMPORTED_MODULE_36__internal_observable_generate__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_37__internal_observable_iif__ = __webpack_require__(286); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "iif", function() { return __WEBPACK_IMPORTED_MODULE_37__internal_observable_iif__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_38__internal_observable_interval__ = __webpack_require__(287); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "interval", function() { return __WEBPACK_IMPORTED_MODULE_38__internal_observable_interval__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_39__internal_observable_merge__ = __webpack_require__(122); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "merge", function() { return __WEBPACK_IMPORTED_MODULE_39__internal_observable_merge__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_40__internal_observable_never__ = __webpack_require__(123); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "never", function() { return __WEBPACK_IMPORTED_MODULE_40__internal_observable_never__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_41__internal_observable_of__ = __webpack_require__(66); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "of", function() { return __WEBPACK_IMPORTED_MODULE_41__internal_observable_of__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_42__internal_observable_onErrorResumeNext__ = __webpack_require__(288); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "onErrorResumeNext", function() { return __WEBPACK_IMPORTED_MODULE_42__internal_observable_onErrorResumeNext__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_43__internal_observable_pairs__ = __webpack_require__(289); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "pairs", function() { return __WEBPACK_IMPORTED_MODULE_43__internal_observable_pairs__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_44__internal_observable_race__ = __webpack_require__(124); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "race", function() { return __WEBPACK_IMPORTED_MODULE_44__internal_observable_race__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_45__internal_observable_range__ = __webpack_require__(290); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "range", function() { return __WEBPACK_IMPORTED_MODULE_45__internal_observable_range__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_46__internal_observable_throwError__ = __webpack_require__(68); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "throwError", function() { return __WEBPACK_IMPORTED_MODULE_46__internal_observable_throwError__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_47__internal_observable_timer__ = __webpack_require__(125); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "timer", function() { return __WEBPACK_IMPORTED_MODULE_47__internal_observable_timer__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_48__internal_observable_using__ = __webpack_require__(291); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "using", function() { return __WEBPACK_IMPORTED_MODULE_48__internal_observable_using__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_49__internal_observable_zip__ = __webpack_require__(72); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "zip", function() { return __WEBPACK_IMPORTED_MODULE_49__internal_observable_zip__["b"]; }); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "EMPTY", function() { return __WEBPACK_IMPORTED_MODULE_31__internal_observable_empty__["a"]; }); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "NEVER", function() { return __WEBPACK_IMPORTED_MODULE_40__internal_observable_never__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_50__internal_config__ = __webpack_require__(42); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "config", function() { return __WEBPACK_IMPORTED_MODULE_50__internal_config__["a"]; }); -/** PURE_IMPORTS_START PURE_IMPORTS_END */ - - - - - - - - - - - - - - - - - - - - - - - +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.runCommand = undefined; +let runCommand = exports.runCommand = (() => { + var _ref = _asyncToGenerator(function* (command, config) { + try { + _log.log.write(_chalk2.default.bold(`Running [${_chalk2.default.green(command.name)}] command from [${_chalk2.default.yellow(config.rootPath)}]:\n`)); + const projectPaths = (0, _config.getProjectPaths)(config.rootPath, config.options); + const projects = yield (0, _projects.getProjects)(config.rootPath, projectPaths, { + exclude: toArray(config.options.exclude), + include: toArray(config.options.include) + }); + if (projects.size === 0) { + _log.log.write(_chalk2.default.red(`There are no projects found. Double check project name(s) in '-i/--include' and '-e/--exclude' filters.\n`)); + return process.exit(1); + } + const projectGraph = (0, _projects.buildProjectGraph)(projects); + _log.log.write(_chalk2.default.bold(`Found [${_chalk2.default.green(projects.size.toString())}] projects:\n`)); + _log.log.write((0, _projects_tree.renderProjectsTree)(config.rootPath, projects)); + yield command.run(projects, projectGraph, config); + } catch (e) { + _log.log.write(_chalk2.default.bold.red(`\n[${command.name}] failed:\n`)); + if (e instanceof _errors.CliError) { + const msg = _chalk2.default.red(`CliError: ${e.message}\n`); + _log.log.write((0, _wrapAnsi2.default)(msg, 80)); + const keys = Object.keys(e.meta); + if (keys.length > 0) { + const metaOutput = keys.map(function (key) { + const value = e.meta[key]; + return `${key}: ${value}`; + }); + _log.log.write('Additional debugging info:\n'); + _log.log.write((0, _indentString2.default)(metaOutput.join('\n'), 3)); + } + } else { + _log.log.write(e.stack); + } + process.exit(1); + } + }); + return function runCommand(_x, _x2) { + return _ref.apply(this, arguments); + }; +})(); +var _chalk = __webpack_require__(30); +var _chalk2 = _interopRequireDefault(_chalk); +var _indentString = __webpack_require__(240); +var _indentString2 = _interopRequireDefault(_indentString); +var _wrapAnsi = __webpack_require__(241); +var _wrapAnsi2 = _interopRequireDefault(_wrapAnsi); +var _config = __webpack_require__(91); +var _errors = __webpack_require__(88); +var _log = __webpack_require__(36); +var _projects = __webpack_require__(42); +var _projects_tree = __webpack_require__(248); +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* + * 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. + */ +function toArray(value) { + if (value == null) { + return []; + } + return Array.isArray(value) ? value : [value]; +} +/***/ }), +/* 240 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +module.exports = (str, count, opts) => { + // Support older versions: use the third parameter as options.indent + // TODO: Remove the workaround in the next major version + const options = typeof opts === 'object' ? Object.assign({indent: ' '}, opts) : {indent: opts || ' '}; + count = count === undefined ? 1 : count; + if (typeof str !== 'string') { + throw new TypeError(`Expected \`input\` to be a \`string\`, got \`${typeof str}\``); + } + if (typeof count !== 'number') { + throw new TypeError(`Expected \`count\` to be a \`number\`, got \`${typeof count}\``); + } + if (typeof options.indent !== 'string') { + throw new TypeError(`Expected \`options.indent\` to be a \`string\`, got \`${typeof options.indent}\``); + } + if (count === 0) { + return str; + } + const regex = options.includeEmptyLines ? /^/mg : /^(?!\s*$)/mg; + return str.replace(regex, options.indent.repeat(count)); +} +; +/***/ }), +/* 241 */ +/***/ (function(module, exports, __webpack_require__) { -//# sourceMappingURL=index.js.map +"use strict"; +const stringWidth = __webpack_require__(242); +const stripAnsi = __webpack_require__(246); -/***/ }), -/* 262 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +const ESCAPES = new Set([ + '\u001B', + '\u009B' +]); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = toSubscriber; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__symbol_rxSubscriber__ = __webpack_require__(62); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Observer__ = __webpack_require__(102); -/** PURE_IMPORTS_START _Subscriber,_symbol_rxSubscriber,_Observer PURE_IMPORTS_END */ +const END_CODE = 39; +const ESCAPE_CODES = new Map([ + [0, 0], + [1, 22], + [2, 22], + [3, 23], + [4, 24], + [7, 27], + [8, 28], + [9, 29], + [30, 39], + [31, 39], + [32, 39], + [33, 39], + [34, 39], + [35, 39], + [36, 39], + [37, 39], + [90, 39], + [40, 49], + [41, 49], + [42, 49], + [43, 49], + [44, 49], + [45, 49], + [46, 49], + [47, 49] +]); +const wrapAnsi = code => `${ESCAPES.values().next().value}[${code}m`; -function toSubscriber(nextOrObserver, error, complete) { - if (nextOrObserver) { - if (nextOrObserver instanceof __WEBPACK_IMPORTED_MODULE_0__Subscriber__["a" /* Subscriber */]) { - return nextOrObserver; - } - if (nextOrObserver[__WEBPACK_IMPORTED_MODULE_1__symbol_rxSubscriber__["a" /* rxSubscriber */]]) { - return nextOrObserver[__WEBPACK_IMPORTED_MODULE_1__symbol_rxSubscriber__["a" /* rxSubscriber */]](); - } - } - if (!nextOrObserver && !error && !complete) { - return new __WEBPACK_IMPORTED_MODULE_0__Subscriber__["a" /* Subscriber */](__WEBPACK_IMPORTED_MODULE_2__Observer__["a" /* empty */]); - } - return new __WEBPACK_IMPORTED_MODULE_0__Subscriber__["a" /* Subscriber */](nextOrObserver, error, complete); -} -//# sourceMappingURL=toSubscriber.js.map +// Calculate the length of words split on ' ', ignoring +// the extra characters added by ansi escape codes +const wordLengths = str => str.split(' ').map(s => stringWidth(s)); +// Wrap a long word across multiple rows +// Ansi escape codes do not count towards length +const wrapWord = (rows, word, cols) => { + const arr = Array.from(word); -/***/ }), -/* 263 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + let insideEscape = false; + let visible = stringWidth(stripAnsi(rows[rows.length - 1])); -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return QueueAction; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncAction__ = __webpack_require__(30); -/** PURE_IMPORTS_START tslib,_AsyncAction PURE_IMPORTS_END */ + for (const item of arr.entries()) { + const i = item[0]; + const char = item[1]; + const charLength = stringWidth(char); + if (visible + charLength <= cols) { + rows[rows.length - 1] += char; + } else { + rows.push(char); + visible = 0; + } -var QueueAction = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](QueueAction, _super); - function QueueAction(scheduler, work) { - var _this = _super.call(this, scheduler, work) || this; - _this.scheduler = scheduler; - _this.work = work; - return _this; - } - QueueAction.prototype.schedule = function (state, delay) { - if (delay === void 0) { - delay = 0; - } - if (delay > 0) { - return _super.prototype.schedule.call(this, state, delay); - } - this.delay = delay; - this.state = state; - this.scheduler.flush(this); - return this; - }; - QueueAction.prototype.execute = function (state, delay) { - return (delay > 0 || this.closed) ? - _super.prototype.execute.call(this, state, delay) : - this._execute(state, delay); - }; - QueueAction.prototype.requestAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { - return _super.prototype.requestAsyncId.call(this, scheduler, id, delay); - } - return scheduler.flush(this); - }; - return QueueAction; -}(__WEBPACK_IMPORTED_MODULE_1__AsyncAction__["a" /* AsyncAction */])); + if (ESCAPES.has(char)) { + insideEscape = true; + } else if (insideEscape && char === 'm') { + insideEscape = false; + continue; + } -//# sourceMappingURL=QueueAction.js.map + if (insideEscape) { + continue; + } + visible += charLength; -/***/ }), -/* 264 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + if (visible === cols && i < arr.length - 1) { + rows.push(''); + visible = 0; + } + } -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Action; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/** PURE_IMPORTS_START tslib,_Subscription PURE_IMPORTS_END */ + // It's possible that the last row we copy over is only + // ansi escape characters, handle this edge-case + if (!visible && rows[rows.length - 1].length > 0 && rows.length > 1) { + rows[rows.length - 2] += rows.pop(); + } +}; +// The wrap-ansi module can be invoked +// in either 'hard' or 'soft' wrap mode +// +// 'hard' will never allow a string to take up more +// than cols characters +// +// 'soft' allows long words to expand past the column length +const exec = (str, cols, opts) => { + const options = opts || {}; -var Action = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](Action, _super); - function Action(scheduler, work) { - return _super.call(this) || this; - } - Action.prototype.schedule = function (state, delay) { - if (delay === void 0) { - delay = 0; - } - return this; - }; - return Action; -}(__WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */])); + if (str.trim() === '') { + return options.trim === false ? str : str.trim(); + } -//# sourceMappingURL=Action.js.map + let pre = ''; + let ret = ''; + let escapeCode; + const lengths = wordLengths(str); + const words = str.split(' '); + const rows = ['']; -/***/ }), -/* 265 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + for (const item of Array.from(words).entries()) { + const i = item[0]; + const word = item[1]; -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return QueueScheduler; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncScheduler__ = __webpack_require__(31); -/** PURE_IMPORTS_START tslib,_AsyncScheduler PURE_IMPORTS_END */ + rows[rows.length - 1] = options.trim === false ? rows[rows.length - 1] : rows[rows.length - 1].trim(); + let rowLength = stringWidth(rows[rows.length - 1]); + if (rowLength || word === '') { + if (rowLength === cols && options.wordWrap === false) { + // If we start with a new word but the current row length equals the length of the columns, add a new row + rows.push(''); + rowLength = 0; + } -var QueueScheduler = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](QueueScheduler, _super); - function QueueScheduler() { - return _super !== null && _super.apply(this, arguments) || this; - } - return QueueScheduler; -}(__WEBPACK_IMPORTED_MODULE_1__AsyncScheduler__["a" /* AsyncScheduler */])); + rows[rows.length - 1] += ' '; + rowLength++; + } -//# sourceMappingURL=QueueScheduler.js.map + // In 'hard' wrap mode, the length of a line is + // never allowed to extend past 'cols' + if (lengths[i] > cols && options.hard) { + if (rowLength) { + rows.push(''); + } + wrapWord(rows, word, cols); + continue; + } + if (rowLength + lengths[i] > cols && rowLength > 0) { + if (options.wordWrap === false && rowLength < cols) { + wrapWord(rows, word, cols); + continue; + } -/***/ }), -/* 266 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + rows.push(''); + } -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AsapAction; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_Immediate__ = __webpack_require__(267); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__AsyncAction__ = __webpack_require__(30); -/** PURE_IMPORTS_START tslib,_util_Immediate,_AsyncAction PURE_IMPORTS_END */ + if (rowLength + lengths[i] > cols && options.wordWrap === false) { + wrapWord(rows, word, cols); + continue; + } + rows[rows.length - 1] += word; + } + pre = rows.map(r => options.trim === false ? r : r.trim()).join('\n'); -var AsapAction = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AsapAction, _super); - function AsapAction(scheduler, work) { - var _this = _super.call(this, scheduler, work) || this; - _this.scheduler = scheduler; - _this.work = work; - return _this; - } - AsapAction.prototype.requestAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - if (delay !== null && delay > 0) { - return _super.prototype.requestAsyncId.call(this, scheduler, id, delay); - } - scheduler.actions.push(this); - return scheduler.scheduled || (scheduler.scheduled = __WEBPACK_IMPORTED_MODULE_1__util_Immediate__["a" /* Immediate */].setImmediate(scheduler.flush.bind(scheduler, null))); - }; - AsapAction.prototype.recycleAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { - return _super.prototype.recycleAsyncId.call(this, scheduler, id, delay); - } - if (scheduler.actions.length === 0) { - __WEBPACK_IMPORTED_MODULE_1__util_Immediate__["a" /* Immediate */].clearImmediate(id); - scheduler.scheduled = undefined; - } - return undefined; - }; - return AsapAction; -}(__WEBPACK_IMPORTED_MODULE_2__AsyncAction__["a" /* AsyncAction */])); + for (const item of Array.from(pre).entries()) { + const i = item[0]; + const char = item[1]; -//# sourceMappingURL=AsapAction.js.map + ret += char; + if (ESCAPES.has(char)) { + const code = parseFloat(/\d[^m]*/.exec(pre.slice(i, i + 4))); + escapeCode = code === END_CODE ? null : code; + } -/***/ }), -/* 267 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + const code = ESCAPE_CODES.get(Number(escapeCode)); -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Immediate; }); -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -var nextHandle = 1; -var tasksByHandle = {}; -function runIfPresent(handle) { - var cb = tasksByHandle[handle]; - if (cb) { - cb(); - } -} -var Immediate = { - setImmediate: function (cb) { - var handle = nextHandle++; - tasksByHandle[handle] = cb; - Promise.resolve().then(function () { return runIfPresent(handle); }); - return handle; - }, - clearImmediate: function (handle) { - delete tasksByHandle[handle]; - }, + if (escapeCode && code) { + if (pre[i + 1] === '\n') { + ret += wrapAnsi(code); + } else if (char === '\n') { + ret += wrapAnsi(escapeCode); + } + } + } + + return ret; +}; + +// For each newline, invoke the method separately +module.exports = (str, cols, opts) => { + return String(str) + .normalize() + .split('\n') + .map(line => exec(line, cols, opts)) + .join('\n'); }; -//# sourceMappingURL=Immediate.js.map /***/ }), -/* 268 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 242 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AsapScheduler; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncScheduler__ = __webpack_require__(31); -/** PURE_IMPORTS_START tslib,_AsyncScheduler PURE_IMPORTS_END */ +const stripAnsi = __webpack_require__(243); +const isFullwidthCodePoint = __webpack_require__(245); -var AsapScheduler = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AsapScheduler, _super); - function AsapScheduler() { - return _super !== null && _super.apply(this, arguments) || this; - } - AsapScheduler.prototype.flush = function (action) { - this.active = true; - this.scheduled = undefined; - var actions = this.actions; - var error; - var index = -1; - var count = actions.length; - action = action || actions.shift(); - do { - if (error = action.execute(action.state, action.delay)) { - break; - } - } while (++index < count && (action = actions.shift())); - this.active = false; - if (error) { - while (++index < count && (action = actions.shift())) { - action.unsubscribe(); - } - throw error; - } - }; - return AsapScheduler; -}(__WEBPACK_IMPORTED_MODULE_1__AsyncScheduler__["a" /* AsyncScheduler */])); +module.exports = str => { + if (typeof str !== 'string' || str.length === 0) { + return 0; + } -//# sourceMappingURL=AsapScheduler.js.map + str = stripAnsi(str); + let width = 0; -/***/ }), -/* 269 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + for (let i = 0; i < str.length; i++) { + const code = str.codePointAt(i); -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return animationFrame; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__AnimationFrameAction__ = __webpack_require__(270); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AnimationFrameScheduler__ = __webpack_require__(271); -/** PURE_IMPORTS_START _AnimationFrameAction,_AnimationFrameScheduler PURE_IMPORTS_END */ + // Ignore control characters + if (code <= 0x1F || (code >= 0x7F && code <= 0x9F)) { + continue; + } + + // Ignore combining characters + if (code >= 0x300 && code <= 0x36F) { + continue; + } + + // Surrogates + if (code > 0xFFFF) { + i++; + } + width += isFullwidthCodePoint(code) ? 2 : 1; + } -var animationFrame = /*@__PURE__*/ new __WEBPACK_IMPORTED_MODULE_1__AnimationFrameScheduler__["a" /* AnimationFrameScheduler */](__WEBPACK_IMPORTED_MODULE_0__AnimationFrameAction__["a" /* AnimationFrameAction */]); -//# sourceMappingURL=animationFrame.js.map + return width; +}; /***/ }), -/* 270 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 243 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AnimationFrameAction; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncAction__ = __webpack_require__(30); -/** PURE_IMPORTS_START tslib,_AsyncAction PURE_IMPORTS_END */ +const ansiRegex = __webpack_require__(244); -var AnimationFrameAction = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AnimationFrameAction, _super); - function AnimationFrameAction(scheduler, work) { - var _this = _super.call(this, scheduler, work) || this; - _this.scheduler = scheduler; - _this.work = work; - return _this; - } - AnimationFrameAction.prototype.requestAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - if (delay !== null && delay > 0) { - return _super.prototype.requestAsyncId.call(this, scheduler, id, delay); - } - scheduler.actions.push(this); - return scheduler.scheduled || (scheduler.scheduled = requestAnimationFrame(function () { return scheduler.flush(null); })); - }; - AnimationFrameAction.prototype.recycleAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { - return _super.prototype.recycleAsyncId.call(this, scheduler, id, delay); - } - if (scheduler.actions.length === 0) { - cancelAnimationFrame(id); - scheduler.scheduled = undefined; - } - return undefined; - }; - return AnimationFrameAction; -}(__WEBPACK_IMPORTED_MODULE_1__AsyncAction__["a" /* AsyncAction */])); - -//# sourceMappingURL=AnimationFrameAction.js.map +module.exports = input => typeof input === 'string' ? input.replace(ansiRegex(), '') : input; /***/ }), -/* 271 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 244 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AnimationFrameScheduler; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncScheduler__ = __webpack_require__(31); -/** PURE_IMPORTS_START tslib,_AsyncScheduler PURE_IMPORTS_END */ -var AnimationFrameScheduler = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](AnimationFrameScheduler, _super); - function AnimationFrameScheduler() { - return _super !== null && _super.apply(this, arguments) || this; - } - AnimationFrameScheduler.prototype.flush = function (action) { - this.active = true; - this.scheduled = undefined; - var actions = this.actions; - var error; - var index = -1; - var count = actions.length; - action = action || actions.shift(); - do { - if (error = action.execute(action.state, action.delay)) { - break; - } - } while (++index < count && (action = actions.shift())); - this.active = false; - if (error) { - while (++index < count && (action = actions.shift())) { - action.unsubscribe(); - } - throw error; - } - }; - return AnimationFrameScheduler; -}(__WEBPACK_IMPORTED_MODULE_1__AsyncScheduler__["a" /* AsyncScheduler */])); +module.exports = () => { + const pattern = [ + '[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[a-zA-Z\\d]*)*)?\\u0007)', + '(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PRZcf-ntqry=><~]))' + ].join('|'); -//# sourceMappingURL=AnimationFrameScheduler.js.map + return new RegExp(pattern, 'g'); +}; /***/ }), -/* 272 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 245 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return VirtualTimeScheduler; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return VirtualAction; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncAction__ = __webpack_require__(30); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__AsyncScheduler__ = __webpack_require__(31); -/** PURE_IMPORTS_START tslib,_AsyncAction,_AsyncScheduler PURE_IMPORTS_END */ - - - -var VirtualTimeScheduler = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](VirtualTimeScheduler, _super); - function VirtualTimeScheduler(SchedulerAction, maxFrames) { - if (SchedulerAction === void 0) { - SchedulerAction = VirtualAction; - } - if (maxFrames === void 0) { - maxFrames = Number.POSITIVE_INFINITY; - } - var _this = _super.call(this, SchedulerAction, function () { return _this.frame; }) || this; - _this.maxFrames = maxFrames; - _this.frame = 0; - _this.index = -1; - return _this; - } - VirtualTimeScheduler.prototype.flush = function () { - var _a = this, actions = _a.actions, maxFrames = _a.maxFrames; - var error, action; - while ((action = actions.shift()) && (this.frame = action.delay) <= maxFrames) { - if (error = action.execute(action.state, action.delay)) { - break; - } - } - if (error) { - while (action = actions.shift()) { - action.unsubscribe(); - } - throw error; - } - }; - VirtualTimeScheduler.frameTimeFactor = 10; - return VirtualTimeScheduler; -}(__WEBPACK_IMPORTED_MODULE_2__AsyncScheduler__["a" /* AsyncScheduler */])); -var VirtualAction = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](VirtualAction, _super); - function VirtualAction(scheduler, work, index) { - if (index === void 0) { - index = scheduler.index += 1; - } - var _this = _super.call(this, scheduler, work) || this; - _this.scheduler = scheduler; - _this.work = work; - _this.index = index; - _this.active = true; - _this.index = scheduler.index = index; - return _this; - } - VirtualAction.prototype.schedule = function (state, delay) { - if (delay === void 0) { - delay = 0; - } - if (!this.id) { - return _super.prototype.schedule.call(this, state, delay); - } - this.active = false; - var action = new VirtualAction(this.scheduler, this.work); - this.add(action); - return action.schedule(state, delay); - }; - VirtualAction.prototype.requestAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - this.delay = scheduler.frame + delay; - var actions = scheduler.actions; - actions.push(this); - actions.sort(VirtualAction.sortActions); - return true; - }; - VirtualAction.prototype.recycleAsyncId = function (scheduler, id, delay) { - if (delay === void 0) { - delay = 0; - } - return undefined; - }; - VirtualAction.prototype._execute = function (state, delay) { - if (this.active === true) { - return _super.prototype._execute.call(this, state, delay); - } - }; - VirtualAction.sortActions = function (a, b) { - if (a.delay === b.delay) { - if (a.index === b.index) { - return 0; - } - else if (a.index > b.index) { - return 1; - } - else { - return -1; - } - } - else if (a.delay > b.delay) { - return 1; - } - else { - return -1; - } - }; - return VirtualAction; -}(__WEBPACK_IMPORTED_MODULE_1__AsyncAction__["a" /* AsyncAction */])); +/* eslint-disable yoda */ +module.exports = x => { + if (Number.isNaN(x)) { + return false; + } -//# sourceMappingURL=VirtualTimeScheduler.js.map + // code points are derived from: + // http://www.unix.org/Public/UNIDATA/EastAsianWidth.txt + if ( + x >= 0x1100 && ( + x <= 0x115f || // Hangul Jamo + x === 0x2329 || // LEFT-POINTING ANGLE BRACKET + x === 0x232a || // RIGHT-POINTING ANGLE BRACKET + // CJK Radicals Supplement .. Enclosed CJK Letters and Months + (0x2e80 <= x && x <= 0x3247 && x !== 0x303f) || + // Enclosed CJK Letters and Months .. CJK Unified Ideographs Extension A + (0x3250 <= x && x <= 0x4dbf) || + // CJK Unified Ideographs .. Yi Radicals + (0x4e00 <= x && x <= 0xa4c6) || + // Hangul Jamo Extended-A + (0xa960 <= x && x <= 0xa97c) || + // Hangul Syllables + (0xac00 <= x && x <= 0xd7a3) || + // CJK Compatibility Ideographs + (0xf900 <= x && x <= 0xfaff) || + // Vertical Forms + (0xfe10 <= x && x <= 0xfe19) || + // CJK Compatibility Forms .. Small Form Variants + (0xfe30 <= x && x <= 0xfe6b) || + // Halfwidth and Fullwidth Forms + (0xff01 <= x && x <= 0xff60) || + (0xffe0 <= x && x <= 0xffe6) || + // Kana Supplement + (0x1b000 <= x && x <= 0x1b001) || + // Enclosed Ideographic Supplement + (0x1f200 <= x && x <= 0x1f251) || + // CJK Unified Ideographs Extension B .. Tertiary Ideographic Plane + (0x20000 <= x && x <= 0x3fffd) + ) + ) { + return true; + } + + return false; +}; /***/ }), -/* 273 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 246 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isObservable; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ -function isObservable(obj) { - return !!obj && (obj instanceof __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */] || (typeof obj.lift === 'function' && typeof obj.subscribe === 'function')); -} -//# sourceMappingURL=isObservable.js.map +const ansiRegex = __webpack_require__(247); + +module.exports = input => typeof input === 'string' ? input.replace(ansiRegex(), '') : input; /***/ }), -/* 274 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 247 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = bindCallback; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncSubject__ = __webpack_require__(46); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__operators_map__ = __webpack_require__(15); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_isScheduler__ = __webpack_require__(14); -/** PURE_IMPORTS_START _Observable,_AsyncSubject,_operators_map,_util_isArray,_util_isScheduler PURE_IMPORTS_END */ +module.exports = () => { + const pattern = [ + '[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[a-zA-Z\\d]*)*)?\\u0007)', + '(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PRZcf-ntqry=><~]))' + ].join('|'); + return new RegExp(pattern, 'g'); +}; -function bindCallback(callbackFunc, resultSelector, scheduler) { - if (resultSelector) { - if (Object(__WEBPACK_IMPORTED_MODULE_4__util_isScheduler__["a" /* isScheduler */])(resultSelector)) { - scheduler = resultSelector; +/***/ }), +/* 248 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + + +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.renderProjectsTree = renderProjectsTree; + +var _chalk = __webpack_require__(30); + +var _chalk2 = _interopRequireDefault(_chalk); + +var _path = __webpack_require__(7); + +var _path2 = _interopRequireDefault(_path); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +/* + * 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. + */ +const projectKey = Symbol('__project'); +function renderProjectsTree(rootPath, projects) { + const projectsTree = buildProjectsTree(rootPath, projects); + return treeToString(createTreeStructure(projectsTree)); +} +function treeToString(tree) { + return [tree.name].concat(childrenToStrings(tree.children, '')).join('\n'); +} +function childrenToStrings(tree, treePrefix) { + if (tree === undefined) { + return []; + } + let strings = []; + tree.forEach((node, index) => { + const isLastNode = tree.length - 1 === index; + const nodePrefix = isLastNode ? '└── ' : '├── '; + const childPrefix = isLastNode ? ' ' : '│ '; + const childrenPrefix = treePrefix + childPrefix; + strings.push(`${treePrefix}${nodePrefix}${node.name}`); + strings = strings.concat(childrenToStrings(node.children, childrenPrefix)); + }); + return strings; +} +function createTreeStructure(tree) { + let name; + const children = []; + for (const [dir, project] of tree.entries()) { + // This is a leaf node (aka a project) + if (typeof project === 'string') { + name = _chalk2.default.green(project); + continue; } - else { - return function () { - var args = []; - for (var _i = 0; _i < arguments.length; _i++) { - args[_i] = arguments[_i]; - } - return bindCallback(callbackFunc, scheduler).apply(void 0, args).pipe(Object(__WEBPACK_IMPORTED_MODULE_2__operators_map__["a" /* map */])(function (args) { return Object(__WEBPACK_IMPORTED_MODULE_3__util_isArray__["a" /* isArray */])(args) ? resultSelector.apply(void 0, args) : resultSelector(args); })); - }; + // If there's only one project and the key indicates it's a leaf node, we + // know that we're at a package folder that contains a package.json, so we + // "inline it" so we don't get unnecessary levels, i.e. we'll just see + // `foo` instead of `foo -> foo`. + if (project.size === 1 && project.has(projectKey)) { + const projectName = project.get(projectKey); + children.push({ + children: [], + name: dirOrProjectName(dir, projectName) + }); + continue; } - } - return function () { - var args = []; - for (var _i = 0; _i < arguments.length; _i++) { - args[_i] = arguments[_i]; + const subtree = createTreeStructure(project); + // If the name is specified, we know there's a package at the "root" of the + // subtree itself. + if (subtree.name !== undefined) { + const projectName = subtree.name; + children.push({ + children: subtree.children, + name: dirOrProjectName(dir, projectName) + }); + continue; } - var context = this; - var subject; - var params = { - context: context, - subject: subject, - callbackFunc: callbackFunc, - scheduler: scheduler, - }; - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - if (!scheduler) { - if (!subject) { - subject = new __WEBPACK_IMPORTED_MODULE_1__AsyncSubject__["a" /* AsyncSubject */](); - var handler = function () { - var innerArgs = []; - for (var _i = 0; _i < arguments.length; _i++) { - innerArgs[_i] = arguments[_i]; - } - subject.next(innerArgs.length <= 1 ? innerArgs[0] : innerArgs); - subject.complete(); - }; - try { - callbackFunc.apply(context, args.concat([handler])); - } - catch (err) { - subject.error(err); - } - } - return subject.subscribe(subscriber); - } - else { - var state = { - args: args, subscriber: subscriber, params: params, - }; - return scheduler.schedule(dispatch, 0, state); - } + // Special-case whenever we have one child, so we don't get unnecessary + // folders in the output. E.g. instead of `foo -> bar -> baz` we get + // `foo/bar/baz` instead. + if (subtree.children && subtree.children.length === 1) { + const child = subtree.children[0]; + const newName = _chalk2.default.dim(_path2.default.join(dir.toString(), child.name)); + children.push({ + children: child.children, + name: newName + }); + continue; + } + children.push({ + children: subtree.children, + name: _chalk2.default.dim(dir.toString()) }); - }; + } + return { name, children }; } -function dispatch(state) { - var _this = this; - var self = this; - var args = state.args, subscriber = state.subscriber, params = state.params; - var callbackFunc = params.callbackFunc, context = params.context, scheduler = params.scheduler; - var subject = params.subject; - if (!subject) { - subject = params.subject = new __WEBPACK_IMPORTED_MODULE_1__AsyncSubject__["a" /* AsyncSubject */](); - var handler = function () { - var innerArgs = []; - for (var _i = 0; _i < arguments.length; _i++) { - innerArgs[_i] = arguments[_i]; - } - var value = innerArgs.length <= 1 ? innerArgs[0] : innerArgs; - _this.add(scheduler.schedule(dispatchNext, 0, { value: value, subject: subject })); - }; - try { - callbackFunc.apply(context, args.concat([handler])); +function dirOrProjectName(dir, projectName) { + return dir === projectName ? _chalk2.default.green(dir) : _chalk2.default`{dim ${dir.toString()} ({reset.green ${projectName}})}`; +} +function buildProjectsTree(rootPath, projects) { + const tree = new Map(); + for (const project of projects.values()) { + if (rootPath === project.path) { + tree.set(projectKey, project.name); + } else { + const relativeProjectPath = _path2.default.relative(rootPath, project.path); + addProjectToTree(tree, relativeProjectPath.split(_path2.default.sep), project); } - catch (err) { - subject.error(err); + } + return tree; +} +function addProjectToTree(tree, pathParts, project) { + if (pathParts.length === 0) { + tree.set(projectKey, project.name); + } else { + const [currentDir, ...rest] = pathParts; + if (!tree.has(currentDir)) { + tree.set(currentDir, new Map()); } + const subtree = tree.get(currentDir); + addProjectToTree(subtree, rest, project); } - this.add(subject.subscribe(subscriber)); -} -function dispatchNext(state) { - var value = state.value, subject = state.subject; - subject.next(value); - subject.complete(); -} -function dispatchError(state) { - var err = state.err, subject = state.subject; - subject.error(err); } -//# sourceMappingURL=bindCallback.js.map - /***/ }), -/* 275 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 249 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = bindNodeCallback; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__AsyncSubject__ = __webpack_require__(46); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__operators_map__ = __webpack_require__(15); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_isScheduler__ = __webpack_require__(14); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_isArray__ = __webpack_require__(10); -/** PURE_IMPORTS_START _Observable,_AsyncSubject,_operators_map,_util_isScheduler,_util_isArray PURE_IMPORTS_END */ +Object.defineProperty(exports, "__esModule", { + value: true +}); +var _build_production_projects = __webpack_require__(250); +Object.defineProperty(exports, 'buildProductionProjects', { + enumerable: true, + get: function () { + return _build_production_projects.buildProductionProjects; + } +}); -function bindNodeCallback(callbackFunc, resultSelector, scheduler) { - if (resultSelector) { - if (Object(__WEBPACK_IMPORTED_MODULE_3__util_isScheduler__["a" /* isScheduler */])(resultSelector)) { - scheduler = resultSelector; - } - else { - return function () { - var args = []; - for (var _i = 0; _i < arguments.length; _i++) { - args[_i] = arguments[_i]; - } - return bindNodeCallback(callbackFunc, scheduler).apply(void 0, args).pipe(Object(__WEBPACK_IMPORTED_MODULE_2__operators_map__["a" /* map */])(function (args) { return Object(__WEBPACK_IMPORTED_MODULE_4__util_isArray__["a" /* isArray */])(args) ? resultSelector.apply(void 0, args) : resultSelector(args); })); - }; - } - } - return function () { - var args = []; - for (var _i = 0; _i < arguments.length; _i++) { - args[_i] = arguments[_i]; - } - var params = { - subject: undefined, - args: args, - callbackFunc: callbackFunc, - scheduler: scheduler, - context: this, - }; - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var context = params.context; - var subject = params.subject; - if (!scheduler) { - if (!subject) { - subject = params.subject = new __WEBPACK_IMPORTED_MODULE_1__AsyncSubject__["a" /* AsyncSubject */](); - var handler = function () { - var innerArgs = []; - for (var _i = 0; _i < arguments.length; _i++) { - innerArgs[_i] = arguments[_i]; - } - var err = innerArgs.shift(); - if (err) { - subject.error(err); - return; - } - subject.next(innerArgs.length <= 1 ? innerArgs[0] : innerArgs); - subject.complete(); - }; - try { - callbackFunc.apply(context, args.concat([handler])); - } - catch (err) { - subject.error(err); - } - } - return subject.subscribe(subscriber); - } - else { - return scheduler.schedule(dispatch, 0, { params: params, subscriber: subscriber, context: context }); - } - }); - }; -} -function dispatch(state) { - var _this = this; - var params = state.params, subscriber = state.subscriber, context = state.context; - var callbackFunc = params.callbackFunc, args = params.args, scheduler = params.scheduler; - var subject = params.subject; - if (!subject) { - subject = params.subject = new __WEBPACK_IMPORTED_MODULE_1__AsyncSubject__["a" /* AsyncSubject */](); - var handler = function () { - var innerArgs = []; - for (var _i = 0; _i < arguments.length; _i++) { - innerArgs[_i] = arguments[_i]; - } - var err = innerArgs.shift(); - if (err) { - _this.add(scheduler.schedule(dispatchError, 0, { err: err, subject: subject })); - } - else { - var value = innerArgs.length <= 1 ? innerArgs[0] : innerArgs; - _this.add(scheduler.schedule(dispatchNext, 0, { value: value, subject: subject })); - } - }; - try { - callbackFunc.apply(context, args.concat([handler])); - } - catch (err) { - this.add(scheduler.schedule(dispatchError, 0, { err: err, subject: subject })); - } - } - this.add(subject.subscribe(subscriber)); -} -function dispatchNext(arg) { - var value = arg.value, subject = arg.subject; - subject.next(value); - subject.complete(); -} -function dispatchError(arg) { - var err = arg.err, subject = arg.subject; - subject.error(err); -} -//# sourceMappingURL=bindNodeCallback.js.map +var _prepare_project_dependencies = __webpack_require__(261); +Object.defineProperty(exports, 'prepareExternalProjectDependencies', { + enumerable: true, + get: function () { + return _prepare_project_dependencies.prepareExternalProjectDependencies; + } +}); /***/ }), -/* 276 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 250 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return InnerSubscriber; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -var InnerSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](InnerSubscriber, _super); - function InnerSubscriber(parent, outerValue, outerIndex) { - var _this = _super.call(this) || this; - _this.parent = parent; - _this.outerValue = outerValue; - _this.outerIndex = outerIndex; - _this.index = 0; - return _this; - } - InnerSubscriber.prototype._next = function (value) { - this.parent.notifyNext(this.outerValue, value, this.outerIndex, this.index++, this); +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.buildProductionProjects = undefined; + +let buildProductionProjects = exports.buildProductionProjects = (() => { + var _ref = _asyncToGenerator(function* ({ kibanaRoot, buildRoots }) { + const projects = yield getProductionProjects(kibanaRoot); + const projectGraph = (0, _projects.buildProjectGraph)(projects); + const batchedProjects = (0, _projects.topologicallyBatchProjects)(projects, projectGraph); + const projectNames = [...projects.values()].map(function (project) { + return project.name; + }); + _log.log.write(`Preparing production build for [${projectNames.join(', ')}]`); + for (const batch of batchedProjects) { + for (const project of batch) { + yield deleteTarget(project); + yield buildProject(project); + for (const buildRoot of buildRoots) { + yield copyToBuild(project, kibanaRoot, buildRoot); + } + } + } + }); + + return function buildProductionProjects(_x) { + return _ref.apply(this, arguments); }; - InnerSubscriber.prototype._error = function (error) { - this.parent.notifyError(error, this); - this.unsubscribe(); +})(); +/** + * Returns the subset of projects that should be built into the production + * bundle. As we copy these into Kibana's `node_modules` during the build step, + * and let Kibana's build process be responsible for installing dependencies, + * we only include Kibana's transitive _production_ dependencies. + */ + + +let getProductionProjects = (() => { + var _ref2 = _asyncToGenerator(function* (rootPath) { + const projectPaths = (0, _config.getProjectPaths)(rootPath, {}); + const projects = yield (0, _projects.getProjects)(rootPath, projectPaths); + const productionProjects = (0, _projects.includeTransitiveProjects)([projects.get('kibana')], projects, { + onlyProductionDependencies: true + }); + // We remove Kibana, as we're already building Kibana + productionProjects.delete('kibana'); + return productionProjects; + }); + + return function getProductionProjects(_x2) { + return _ref2.apply(this, arguments); }; - InnerSubscriber.prototype._complete = function () { - this.parent.notifyComplete(this); - this.unsubscribe(); +})(); + +let deleteTarget = (() => { + var _ref3 = _asyncToGenerator(function* (project) { + const targetDir = project.targetLocation; + if (yield (0, _fs.isDirectory)(targetDir)) { + yield (0, _del2.default)(targetDir, { force: true }); + } + }); + + return function deleteTarget(_x3) { + return _ref3.apply(this, arguments); }; - return InnerSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); +})(); -//# sourceMappingURL=InnerSubscriber.js.map +let buildProject = (() => { + var _ref4 = _asyncToGenerator(function* (project) { + if (project.hasScript('build')) { + yield project.runScript('build'); + } + }); + return function buildProject(_x4) { + return _ref4.apply(this, arguments); + }; +})(); +/** + * Copy all the project's files from its "intermediate build directory" and + * into the build. The intermediate directory can either be the root of the + * project or some other location defined in the project's `package.json`. + * + * When copying all the files into the build, we exclude `node_modules` because + * we want the Kibana build to be responsible for actually installing all + * dependencies. The primary reason for allowing the Kibana build process to + * manage dependencies is that it will "dedupe" them, so we don't include + * unnecessary copies of dependencies. + */ -/***/ }), -/* 277 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isInteropObservable; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__symbol_observable__ = __webpack_require__(24); -/** PURE_IMPORTS_START _symbol_observable PURE_IMPORTS_END */ +let copyToBuild = (() => { + var _ref5 = _asyncToGenerator(function* (project, kibanaRoot, buildRoot) { + // We want the package to have the same relative location within the build + const relativeProjectPath = (0, _path.relative)(kibanaRoot, project.path); + const buildProjectPath = (0, _path.resolve)(buildRoot, relativeProjectPath); + yield (0, _cpy2.default)(['**/*', '!node_modules/**'], buildProjectPath, { + cwd: project.getIntermediateBuildDirectory(), + dot: true, + nodir: true, + parents: true + }); + // If a project is using an intermediate build directory, we special-case our + // handling of `package.json`, as the project build process might have copied + // (a potentially modified) `package.json` into the intermediate build + // directory already. If so, we want to use that `package.json` as the basis + // for creating the production-ready `package.json`. If it's not present in + // the intermediate build, we fall back to using the project's already defined + // `package.json`. + const packageJson = (yield (0, _fs.isFile)((0, _path.join)(buildProjectPath, 'package.json'))) ? yield (0, _package_json.readPackageJson)(buildProjectPath) : project.json; + yield (0, _package_json.writePackageJson)(buildProjectPath, packageJson); + }); -function isInteropObservable(input) { - return input && typeof input[__WEBPACK_IMPORTED_MODULE_0__symbol_observable__["a" /* observable */]] === 'function'; -} -//# sourceMappingURL=isInteropObservable.js.map + return function copyToBuild(_x5, _x6, _x7) { + return _ref5.apply(this, arguments); + }; +})(); +var _cpy = __webpack_require__(251); -/***/ }), -/* 278 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var _cpy2 = _interopRequireDefault(_cpy); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isIterable; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__symbol_iterator__ = __webpack_require__(34); -/** PURE_IMPORTS_START _symbol_iterator PURE_IMPORTS_END */ +var _del = __webpack_require__(113); -function isIterable(input) { - return input && typeof input[__WEBPACK_IMPORTED_MODULE_0__symbol_iterator__["a" /* iterator */]] === 'function'; -} -//# sourceMappingURL=isIterable.js.map +var _del2 = _interopRequireDefault(_del); +var _path = __webpack_require__(7); -/***/ }), -/* 279 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var _config = __webpack_require__(91); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = fromPromise; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToPromise__ = __webpack_require__(116); -/** PURE_IMPORTS_START _Observable,_Subscription,_util_subscribeToPromise PURE_IMPORTS_END */ +var _fs = __webpack_require__(60); +var _log = __webpack_require__(36); +var _package_json = __webpack_require__(62); -function fromPromise(input, scheduler) { - if (!scheduler) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToPromise__["a" /* subscribeToPromise */])(input)); - } - else { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var sub = new __WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */](); - sub.add(scheduler.schedule(function () { - return input.then(function (value) { - sub.add(scheduler.schedule(function () { - subscriber.next(value); - sub.add(scheduler.schedule(function () { return subscriber.complete(); })); - })); - }, function (err) { - sub.add(scheduler.schedule(function () { return subscriber.error(err); })); - }); - })); - return sub; - }); - } -} -//# sourceMappingURL=fromPromise.js.map +var _projects = __webpack_require__(42); + +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } +function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* + * 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. + */ /***/ }), -/* 280 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 251 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = fromIterable; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__symbol_iterator__ = __webpack_require__(34); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_subscribeToIterable__ = __webpack_require__(117); -/** PURE_IMPORTS_START _Observable,_Subscription,_symbol_iterator,_util_subscribeToIterable PURE_IMPORTS_END */ - +const EventEmitter = __webpack_require__(61); +const path = __webpack_require__(7); +const arrify = __webpack_require__(252); +const globby = __webpack_require__(253); +const cpFile = __webpack_require__(255); +const CpyError = __webpack_require__(260); +const preprocessSrcPath = (srcPath, opts) => opts.cwd ? path.resolve(opts.cwd, srcPath) : srcPath; -function fromIterable(input, scheduler) { - if (!input) { - throw new Error('Iterable cannot be null'); - } - if (!scheduler) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](Object(__WEBPACK_IMPORTED_MODULE_3__util_subscribeToIterable__["a" /* subscribeToIterable */])(input)); - } - else { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var sub = new __WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */](); - var iterator; - sub.add(function () { - if (iterator && typeof iterator.return === 'function') { - iterator.return(); - } - }); - sub.add(scheduler.schedule(function () { - iterator = input[__WEBPACK_IMPORTED_MODULE_2__symbol_iterator__["a" /* iterator */]](); - sub.add(scheduler.schedule(function () { - if (subscriber.closed) { - return; - } - var value; - var done; - try { - var result = iterator.next(); - value = result.value; - done = result.done; - } - catch (err) { - subscriber.error(err); - return; - } - if (done) { - subscriber.complete(); - } - else { - subscriber.next(value); - this.schedule(); - } - })); - })); - return sub; - }); - } -} -//# sourceMappingURL=fromIterable.js.map - - -/***/ }), -/* 281 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +const preprocessDestPath = (srcPath, dest, opts) => { + let basename = path.basename(srcPath); + const dirname = path.dirname(srcPath); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = fromObservable; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__symbol_observable__ = __webpack_require__(24); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_subscribeToObservable__ = __webpack_require__(118); -/** PURE_IMPORTS_START _Observable,_Subscription,_symbol_observable,_util_subscribeToObservable PURE_IMPORTS_END */ + if (typeof opts.rename === 'string') { + basename = opts.rename; + } else if (typeof opts.rename === 'function') { + basename = opts.rename(basename); + } + if (opts.cwd) { + dest = path.resolve(opts.cwd, dest); + } + if (opts.parents) { + return path.join(dest, dirname, basename); + } + return path.join(dest, basename); +}; -function fromObservable(input, scheduler) { - if (!scheduler) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](Object(__WEBPACK_IMPORTED_MODULE_3__util_subscribeToObservable__["a" /* subscribeToObservable */])(input)); - } - else { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var sub = new __WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */](); - sub.add(scheduler.schedule(function () { - var observable = input[__WEBPACK_IMPORTED_MODULE_2__symbol_observable__["a" /* observable */]](); - sub.add(observable.subscribe({ - next: function (value) { sub.add(scheduler.schedule(function () { return subscriber.next(value); })); }, - error: function (err) { sub.add(scheduler.schedule(function () { return subscriber.error(err); })); }, - complete: function () { sub.add(scheduler.schedule(function () { return subscriber.complete(); })); }, - })); - })); - return sub; - }); - } -} -//# sourceMappingURL=fromObservable.js.map +module.exports = (src, dest, opts) => { + src = arrify(src); + opts = opts || {}; + if (src.length === 0 || !dest) { + return Promise.reject(new CpyError('`files` and `destination` required')); + } -/***/ }), -/* 282 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + const progressEmitter = new EventEmitter(); + const copyStatus = new Map(); + let completedFiles = 0; + let completedSize = 0; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = forkJoin; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__empty__ = __webpack_require__(11); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__ = __webpack_require__(5); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__operators_map__ = __webpack_require__(15); -/** PURE_IMPORTS_START tslib,_Observable,_util_isArray,_empty,_util_subscribeToResult,_OuterSubscriber,_operators_map PURE_IMPORTS_END */ + const promise = globby(src, opts) + .catch(err => { + throw new CpyError(`Cannot glob \`${src}\`: ${err.message}`, err); + }) + .then(files => { + if (files.length === 0) { + progressEmitter.emit('progress', { + totalFiles: 0, + percent: 1, + completedFiles: 0, + completedSize: 0 + }); + } + return Promise.all(files.map(srcPath => { + const from = preprocessSrcPath(srcPath, opts); + const to = preprocessDestPath(srcPath, dest, opts); + return cpFile(from, to, opts) + .on('progress', event => { + const fileStatus = copyStatus.get(event.src) || {written: 0, percent: 0}; + if (fileStatus.written !== event.written || fileStatus.percent !== event.percent) { + completedSize -= fileStatus.written; + completedSize += event.written; + if (event.percent === 1 && fileStatus.percent !== 1) { + completedFiles++; + } + copyStatus.set(event.src, {written: event.written, percent: event.percent}); + progressEmitter.emit('progress', { + totalFiles: files.length, + percent: completedFiles / files.length, + completedFiles, + completedSize + }); + } + }) + .catch(err => { + throw new CpyError(`Cannot copy from \`${from}\` to \`${to}\`: ${err.message}`, err); + }); + })); + }); -function forkJoin() { - var sources = []; - for (var _i = 0; _i < arguments.length; _i++) { - sources[_i] = arguments[_i]; - } - var resultSelector; - if (typeof sources[sources.length - 1] === 'function') { - resultSelector = sources.pop(); - } - if (sources.length === 1 && Object(__WEBPACK_IMPORTED_MODULE_2__util_isArray__["a" /* isArray */])(sources[0])) { - sources = sources[0]; - } - if (sources.length === 0) { - return __WEBPACK_IMPORTED_MODULE_3__empty__["a" /* EMPTY */]; - } - if (resultSelector) { - return forkJoin(sources).pipe(Object(__WEBPACK_IMPORTED_MODULE_6__operators_map__["a" /* map */])(function (args) { return resultSelector.apply(void 0, args); })); - } - return new __WEBPACK_IMPORTED_MODULE_1__Observable__["a" /* Observable */](function (subscriber) { - return new ForkJoinSubscriber(subscriber, sources); - }); -} -var ForkJoinSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ForkJoinSubscriber, _super); - function ForkJoinSubscriber(destination, sources) { - var _this = _super.call(this, destination) || this; - _this.sources = sources; - _this.completed = 0; - _this.haveValues = 0; - var len = sources.length; - _this.values = new Array(len); - for (var i = 0; i < len; i++) { - var source = sources[i]; - var innerSubscription = Object(__WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__["a" /* subscribeToResult */])(_this, source, null, i); - if (innerSubscription) { - _this.add(innerSubscription); - } - } - return _this; - } - ForkJoinSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.values[outerIndex] = innerValue; - if (!innerSub._hasValue) { - innerSub._hasValue = true; - this.haveValues++; - } - }; - ForkJoinSubscriber.prototype.notifyComplete = function (innerSub) { - var _a = this, destination = _a.destination, haveValues = _a.haveValues, values = _a.values; - var len = values.length; - if (!innerSub._hasValue) { - destination.complete(); - return; - } - this.completed++; - if (this.completed !== len) { - return; - } - if (haveValues === len) { - destination.next(values); - } - destination.complete(); - }; - return ForkJoinSubscriber; -}(__WEBPACK_IMPORTED_MODULE_5__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=forkJoin.js.map + promise.on = function () { + progressEmitter.on.apply(progressEmitter, arguments); + return promise; + }; + + return promise; +}; /***/ }), -/* 283 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 252 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = fromEvent; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isFunction__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__operators_map__ = __webpack_require__(15); -/** PURE_IMPORTS_START _Observable,_util_isArray,_util_isFunction,_operators_map PURE_IMPORTS_END */ - - +module.exports = function (val) { + if (val === null || val === undefined) { + return []; + } -var toString = Object.prototype.toString; -function fromEvent(target, eventName, options, resultSelector) { - if (Object(__WEBPACK_IMPORTED_MODULE_2__util_isFunction__["a" /* isFunction */])(options)) { - resultSelector = options; - options = undefined; - } - if (resultSelector) { - return fromEvent(target, eventName, options).pipe(Object(__WEBPACK_IMPORTED_MODULE_3__operators_map__["a" /* map */])(function (args) { return Object(__WEBPACK_IMPORTED_MODULE_1__util_isArray__["a" /* isArray */])(args) ? resultSelector.apply(void 0, args) : resultSelector(args); })); - } - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - function handler(e) { - if (arguments.length > 1) { - subscriber.next(Array.prototype.slice.call(arguments)); - } - else { - subscriber.next(e); - } - } - setupSubscription(target, eventName, handler, subscriber, options); - }); -} -function setupSubscription(sourceObj, eventName, handler, subscriber, options) { - var unsubscribe; - if (isEventTarget(sourceObj)) { - var source_1 = sourceObj; - sourceObj.addEventListener(eventName, handler, options); - unsubscribe = function () { return source_1.removeEventListener(eventName, handler, options); }; - } - else if (isJQueryStyleEventEmitter(sourceObj)) { - var source_2 = sourceObj; - sourceObj.on(eventName, handler); - unsubscribe = function () { return source_2.off(eventName, handler); }; - } - else if (isNodeStyleEventEmitter(sourceObj)) { - var source_3 = sourceObj; - sourceObj.addListener(eventName, handler); - unsubscribe = function () { return source_3.removeListener(eventName, handler); }; - } - else if (sourceObj && sourceObj.length) { - for (var i = 0, len = sourceObj.length; i < len; i++) { - setupSubscription(sourceObj[i], eventName, handler, subscriber, options); - } - } - else { - throw new TypeError('Invalid event target'); - } - subscriber.add(unsubscribe); -} -function isNodeStyleEventEmitter(sourceObj) { - return sourceObj && typeof sourceObj.addListener === 'function' && typeof sourceObj.removeListener === 'function'; -} -function isJQueryStyleEventEmitter(sourceObj) { - return sourceObj && typeof sourceObj.on === 'function' && typeof sourceObj.off === 'function'; -} -function isEventTarget(sourceObj) { - return sourceObj && typeof sourceObj.addEventListener === 'function' && typeof sourceObj.removeEventListener === 'function'; -} -//# sourceMappingURL=fromEvent.js.map + return Array.isArray(val) ? val : [val]; +}; /***/ }), -/* 284 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 253 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = fromEventPattern; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isFunction__ = __webpack_require__(29); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__operators_map__ = __webpack_require__(15); -/** PURE_IMPORTS_START _Observable,_util_isArray,_util_isFunction,_operators_map PURE_IMPORTS_END */ +var Promise = __webpack_require__(114); +var arrayUnion = __webpack_require__(115); +var objectAssign = __webpack_require__(116); +var glob = __webpack_require__(43); +var pify = __webpack_require__(254); +var globP = pify(glob, Promise).bind(glob); +function isNegative(pattern) { + return pattern[0] === '!'; +} -function fromEventPattern(addHandler, removeHandler, resultSelector) { - if (resultSelector) { - return fromEventPattern(addHandler, removeHandler).pipe(Object(__WEBPACK_IMPORTED_MODULE_3__operators_map__["a" /* map */])(function (args) { return Object(__WEBPACK_IMPORTED_MODULE_1__util_isArray__["a" /* isArray */])(args) ? resultSelector.apply(void 0, args) : resultSelector(args); })); - } - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var handler = function () { - var e = []; - for (var _i = 0; _i < arguments.length; _i++) { - e[_i] = arguments[_i]; - } - return subscriber.next(e.length === 1 ? e[0] : e); - }; - var retValue; - try { - retValue = addHandler(handler); - } - catch (err) { - subscriber.error(err); - return undefined; - } - if (!Object(__WEBPACK_IMPORTED_MODULE_2__util_isFunction__["a" /* isFunction */])(removeHandler)) { - return undefined; - } - return function () { return removeHandler(handler, retValue); }; - }); +function isString(value) { + return typeof value === 'string'; +} + +function assertPatternsInput(patterns) { + if (!patterns.every(isString)) { + throw new TypeError('patterns must be a string or an array of strings'); + } } -//# sourceMappingURL=fromEventPattern.js.map +function generateGlobTasks(patterns, opts) { + patterns = [].concat(patterns); + assertPatternsInput(patterns); -/***/ }), -/* 285 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + var globTasks = []; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = generate; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_identity__ = __webpack_require__(25); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isScheduler__ = __webpack_require__(14); -/** PURE_IMPORTS_START _Observable,_util_identity,_util_isScheduler PURE_IMPORTS_END */ + opts = objectAssign({ + cache: Object.create(null), + statCache: Object.create(null), + realpathCache: Object.create(null), + symlinks: Object.create(null), + ignore: [] + }, opts); + patterns.forEach(function (pattern, i) { + if (isNegative(pattern)) { + return; + } + var ignore = patterns.slice(i).filter(isNegative).map(function (pattern) { + return pattern.slice(1); + }); -function generate(initialStateOrOptions, condition, iterate, resultSelectorOrObservable, scheduler) { - var resultSelector; - var initialState; - if (arguments.length == 1) { - var options = initialStateOrOptions; - initialState = options.initialState; - condition = options.condition; - iterate = options.iterate; - resultSelector = options.resultSelector || __WEBPACK_IMPORTED_MODULE_1__util_identity__["a" /* identity */]; - scheduler = options.scheduler; - } - else if (resultSelectorOrObservable === undefined || Object(__WEBPACK_IMPORTED_MODULE_2__util_isScheduler__["a" /* isScheduler */])(resultSelectorOrObservable)) { - initialState = initialStateOrOptions; - resultSelector = __WEBPACK_IMPORTED_MODULE_1__util_identity__["a" /* identity */]; - scheduler = resultSelectorOrObservable; - } - else { - initialState = initialStateOrOptions; - resultSelector = resultSelectorOrObservable; - } - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var state = initialState; - if (scheduler) { - return scheduler.schedule(dispatch, 0, { - subscriber: subscriber, - iterate: iterate, - condition: condition, - resultSelector: resultSelector, - state: state - }); - } - do { - if (condition) { - var conditionResult = void 0; - try { - conditionResult = condition(state); - } - catch (err) { - subscriber.error(err); - return undefined; - } - if (!conditionResult) { - subscriber.complete(); - break; - } - } - var value = void 0; - try { - value = resultSelector(state); - } - catch (err) { - subscriber.error(err); - return undefined; - } - subscriber.next(value); - if (subscriber.closed) { - break; - } - try { - state = iterate(state); - } - catch (err) { - subscriber.error(err); - return undefined; - } - } while (true); - return undefined; - }); -} -function dispatch(state) { - var subscriber = state.subscriber, condition = state.condition; - if (subscriber.closed) { - return undefined; - } - if (state.needIterate) { - try { - state.state = state.iterate(state.state); - } - catch (err) { - subscriber.error(err); - return undefined; - } - } - else { - state.needIterate = true; - } - if (condition) { - var conditionResult = void 0; - try { - conditionResult = condition(state.state); - } - catch (err) { - subscriber.error(err); - return undefined; - } - if (!conditionResult) { - subscriber.complete(); - return undefined; - } - if (subscriber.closed) { - return undefined; - } - } - var value; - try { - value = state.resultSelector(state.state); - } - catch (err) { - subscriber.error(err); - return undefined; - } - if (subscriber.closed) { - return undefined; - } - subscriber.next(value); - if (subscriber.closed) { - return undefined; - } - return this.schedule(state); + globTasks.push({ + pattern: pattern, + opts: objectAssign({}, opts, { + ignore: opts.ignore.concat(ignore) + }) + }); + }); + + return globTasks; } -//# sourceMappingURL=generate.js.map +module.exports = function (patterns, opts) { + var globTasks; -/***/ }), -/* 286 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + try { + globTasks = generateGlobTasks(patterns, opts); + } catch (err) { + return Promise.reject(err); + } -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = iif; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__defer__ = __webpack_require__(71); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__empty__ = __webpack_require__(11); -/** PURE_IMPORTS_START _defer,_empty PURE_IMPORTS_END */ + return Promise.all(globTasks.map(function (task) { + return globP(task.pattern, task.opts); + })).then(function (paths) { + return arrayUnion.apply(null, paths); + }); +}; +module.exports.sync = function (patterns, opts) { + var globTasks = generateGlobTasks(patterns, opts); -function iif(condition, trueResult, falseResult) { - if (trueResult === void 0) { - trueResult = __WEBPACK_IMPORTED_MODULE_1__empty__["a" /* EMPTY */]; - } - if (falseResult === void 0) { - falseResult = __WEBPACK_IMPORTED_MODULE_1__empty__["a" /* EMPTY */]; - } - return Object(__WEBPACK_IMPORTED_MODULE_0__defer__["a" /* defer */])(function () { return condition() ? trueResult : falseResult; }); -} -//# sourceMappingURL=iif.js.map + return globTasks.reduce(function (matches, task) { + return arrayUnion(matches, glob.sync(task.pattern, task.opts)); + }, []); +}; +module.exports.generateGlobTasks = generateGlobTasks; -/***/ }), -/* 287 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +module.exports.hasMagic = function (patterns, opts) { + return [].concat(patterns).some(function (pattern) { + return glob.hasMagic(pattern, opts); + }); +}; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = interval; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isNumeric__ = __webpack_require__(48); -/** PURE_IMPORTS_START _Observable,_scheduler_async,_util_isNumeric PURE_IMPORTS_END */ +/***/ }), +/* 254 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; -function interval(period, scheduler) { - if (period === void 0) { - period = 0; - } - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_1__scheduler_async__["a" /* async */]; - } - if (!Object(__WEBPACK_IMPORTED_MODULE_2__util_isNumeric__["a" /* isNumeric */])(period) || period < 0) { - period = 0; - } - if (!scheduler || typeof scheduler.schedule !== 'function') { - scheduler = __WEBPACK_IMPORTED_MODULE_1__scheduler_async__["a" /* async */]; - } - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - subscriber.add(scheduler.schedule(dispatch, period, { subscriber: subscriber, counter: 0, period: period })); - return subscriber; - }); -} -function dispatch(state) { - var subscriber = state.subscriber, counter = state.counter, period = state.period; - subscriber.next(counter); - this.schedule({ subscriber: subscriber, counter: counter + 1, period: period }, period); -} -//# sourceMappingURL=interval.js.map +var processFn = function (fn, P, opts) { + return function () { + var that = this; + var args = new Array(arguments.length); -/***/ }), -/* 288 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + for (var i = 0; i < arguments.length; i++) { + args[i] = arguments[i]; + } -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = onErrorResumeNext; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__from__ = __webpack_require__(18); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__empty__ = __webpack_require__(11); -/** PURE_IMPORTS_START _Observable,_from,_util_isArray,_empty PURE_IMPORTS_END */ + return new P(function (resolve, reject) { + args.push(function (err, result) { + if (err) { + reject(err); + } else if (opts.multiArgs) { + var results = new Array(arguments.length - 1); + for (var i = 1; i < arguments.length; i++) { + results[i - 1] = arguments[i]; + } + resolve(results); + } else { + resolve(result); + } + }); + fn.apply(that, args); + }); + }; +}; -function onErrorResumeNext() { - var sources = []; - for (var _i = 0; _i < arguments.length; _i++) { - sources[_i] = arguments[_i]; - } - if (sources.length === 0) { - return __WEBPACK_IMPORTED_MODULE_3__empty__["a" /* EMPTY */]; - } - var first = sources[0], remainder = sources.slice(1); - if (sources.length === 1 && Object(__WEBPACK_IMPORTED_MODULE_2__util_isArray__["a" /* isArray */])(first)) { - return onErrorResumeNext.apply(void 0, first); - } - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var subNext = function () { return subscriber.add(onErrorResumeNext.apply(void 0, remainder).subscribe(subscriber)); }; - return Object(__WEBPACK_IMPORTED_MODULE_1__from__["a" /* from */])(first).subscribe({ - next: function (value) { subscriber.next(value); }, - error: subNext, - complete: subNext, - }); - }); -} -//# sourceMappingURL=onErrorResumeNext.js.map +var pify = module.exports = function (obj, P, opts) { + if (typeof P !== 'function') { + opts = P; + P = Promise; + } + opts = opts || {}; + opts.exclude = opts.exclude || [/.+Sync$/]; -/***/ }), -/* 289 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + var filter = function (key) { + var match = function (pattern) { + return typeof pattern === 'string' ? key === pattern : pattern.test(key); + }; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = pairs; -/* unused harmony export dispatch */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/** PURE_IMPORTS_START _Observable,_Subscription PURE_IMPORTS_END */ + return opts.include ? opts.include.some(match) : !opts.exclude.some(match); + }; + var ret = typeof obj === 'function' ? function () { + if (opts.excludeMain) { + return obj.apply(this, arguments); + } -function pairs(obj, scheduler) { - if (!scheduler) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var keys = Object.keys(obj); - for (var i = 0; i < keys.length && !subscriber.closed; i++) { - var key = keys[i]; - if (obj.hasOwnProperty(key)) { - subscriber.next([key, obj[key]]); - } - } - subscriber.complete(); - }); - } - else { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var keys = Object.keys(obj); - var subscription = new __WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */](); - subscription.add(scheduler.schedule(dispatch, 0, { keys: keys, index: 0, subscriber: subscriber, subscription: subscription, obj: obj })); - return subscription; - }); - } -} -function dispatch(state) { - var keys = state.keys, index = state.index, subscriber = state.subscriber, subscription = state.subscription, obj = state.obj; - if (!subscriber.closed) { - if (index < keys.length) { - var key = keys[index]; - subscriber.next([key, obj[key]]); - subscription.add(this.schedule({ keys: keys, index: index + 1, subscriber: subscriber, subscription: subscription, obj: obj })); - } - else { - subscriber.complete(); - } - } -} -//# sourceMappingURL=pairs.js.map + return processFn(obj, P, opts).apply(this, arguments); + } : {}; + return Object.keys(obj).reduce(function (ret, key) { + var x = obj[key]; -/***/ }), -/* 290 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + ret[key] = typeof x === 'function' && filter(key) ? processFn(x, P, opts) : x; -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = range; -/* unused harmony export dispatch */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ + return ret; + }, ret); +}; -function range(start, count, scheduler) { - if (start === void 0) { - start = 0; - } - if (count === void 0) { - count = 0; - } - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var index = 0; - var current = start; - if (scheduler) { - return scheduler.schedule(dispatch, 0, { - index: index, count: count, start: start, subscriber: subscriber - }); - } - else { - do { - if (index++ >= count) { - subscriber.complete(); - break; - } - subscriber.next(current++); - if (subscriber.closed) { - break; - } - } while (true); - } - return undefined; - }); -} -function dispatch(state) { - var start = state.start, index = state.index, count = state.count, subscriber = state.subscriber; - if (index >= count) { - subscriber.complete(); - return; - } - subscriber.next(start); - if (subscriber.closed) { - return; - } - state.index = index + 1; - state.start = start + 1; - this.schedule(state); -} -//# sourceMappingURL=range.js.map +pify.all = pify; /***/ }), -/* 291 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +/* 255 */ +/***/ (function(module, exports, __webpack_require__) { "use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = using; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__from__ = __webpack_require__(18); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__empty__ = __webpack_require__(11); -/** PURE_IMPORTS_START _Observable,_from,_empty PURE_IMPORTS_END */ +const path = __webpack_require__(7); +const fsConstants = __webpack_require__(16).constants; +const Buffer = __webpack_require__(256).Buffer; +const CpFileError = __webpack_require__(117); +const fs = __webpack_require__(258); +const ProgressEmitter = __webpack_require__(259); +module.exports = (src, dest, opts) => { + if (!src || !dest) { + return Promise.reject(new CpFileError('`src` and `dest` required')); + } -function using(resourceFactory, observableFactory) { - return new __WEBPACK_IMPORTED_MODULE_0__Observable__["a" /* Observable */](function (subscriber) { - var resource; - try { - resource = resourceFactory(); - } - catch (err) { - subscriber.error(err); - return undefined; - } - var result; - try { - result = observableFactory(resource); - } - catch (err) { - subscriber.error(err); - return undefined; - } - var source = result ? Object(__WEBPACK_IMPORTED_MODULE_1__from__["a" /* from */])(result) : __WEBPACK_IMPORTED_MODULE_2__empty__["a" /* EMPTY */]; - var subscription = source.subscribe(subscriber); - return function () { - subscription.unsubscribe(); - if (resource) { - resource.unsubscribe(); - } - }; - }); -} -//# sourceMappingURL=using.js.map - + opts = Object.assign({overwrite: true}, opts); -/***/ }), -/* 292 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + const progressEmitter = new ProgressEmitter(path.resolve(src), path.resolve(dest)); -"use strict"; -Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__internal_operators_audit__ = __webpack_require__(126); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "audit", function() { return __WEBPACK_IMPORTED_MODULE_0__internal_operators_audit__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__internal_operators_auditTime__ = __webpack_require__(293); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "auditTime", function() { return __WEBPACK_IMPORTED_MODULE_1__internal_operators_auditTime__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__internal_operators_buffer__ = __webpack_require__(294); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "buffer", function() { return __WEBPACK_IMPORTED_MODULE_2__internal_operators_buffer__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__internal_operators_bufferCount__ = __webpack_require__(295); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "bufferCount", function() { return __WEBPACK_IMPORTED_MODULE_3__internal_operators_bufferCount__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__internal_operators_bufferTime__ = __webpack_require__(296); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "bufferTime", function() { return __WEBPACK_IMPORTED_MODULE_4__internal_operators_bufferTime__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__internal_operators_bufferToggle__ = __webpack_require__(297); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "bufferToggle", function() { return __WEBPACK_IMPORTED_MODULE_5__internal_operators_bufferToggle__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__internal_operators_bufferWhen__ = __webpack_require__(298); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "bufferWhen", function() { return __WEBPACK_IMPORTED_MODULE_6__internal_operators_bufferWhen__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__internal_operators_catchError__ = __webpack_require__(299); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "catchError", function() { return __WEBPACK_IMPORTED_MODULE_7__internal_operators_catchError__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__internal_operators_combineAll__ = __webpack_require__(300); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "combineAll", function() { return __WEBPACK_IMPORTED_MODULE_8__internal_operators_combineAll__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__internal_operators_combineLatest__ = __webpack_require__(301); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "combineLatest", function() { return __WEBPACK_IMPORTED_MODULE_9__internal_operators_combineLatest__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__internal_operators_concat__ = __webpack_require__(302); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "concat", function() { return __WEBPACK_IMPORTED_MODULE_10__internal_operators_concat__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__internal_operators_concatAll__ = __webpack_require__(121); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "concatAll", function() { return __WEBPACK_IMPORTED_MODULE_11__internal_operators_concatAll__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__internal_operators_concatMap__ = __webpack_require__(127); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "concatMap", function() { return __WEBPACK_IMPORTED_MODULE_12__internal_operators_concatMap__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__internal_operators_concatMapTo__ = __webpack_require__(303); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "concatMapTo", function() { return __WEBPACK_IMPORTED_MODULE_13__internal_operators_concatMapTo__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__internal_operators_count__ = __webpack_require__(304); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "count", function() { return __WEBPACK_IMPORTED_MODULE_14__internal_operators_count__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__internal_operators_debounce__ = __webpack_require__(305); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "debounce", function() { return __WEBPACK_IMPORTED_MODULE_15__internal_operators_debounce__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_16__internal_operators_debounceTime__ = __webpack_require__(306); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "debounceTime", function() { return __WEBPACK_IMPORTED_MODULE_16__internal_operators_debounceTime__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_17__internal_operators_defaultIfEmpty__ = __webpack_require__(36); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "defaultIfEmpty", function() { return __WEBPACK_IMPORTED_MODULE_17__internal_operators_defaultIfEmpty__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_18__internal_operators_delay__ = __webpack_require__(307); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "delay", function() { return __WEBPACK_IMPORTED_MODULE_18__internal_operators_delay__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_19__internal_operators_delayWhen__ = __webpack_require__(308); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "delayWhen", function() { return __WEBPACK_IMPORTED_MODULE_19__internal_operators_delayWhen__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_20__internal_operators_dematerialize__ = __webpack_require__(309); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "dematerialize", function() { return __WEBPACK_IMPORTED_MODULE_20__internal_operators_dematerialize__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_21__internal_operators_distinct__ = __webpack_require__(310); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "distinct", function() { return __WEBPACK_IMPORTED_MODULE_21__internal_operators_distinct__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_22__internal_operators_distinctUntilChanged__ = __webpack_require__(129); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "distinctUntilChanged", function() { return __WEBPACK_IMPORTED_MODULE_22__internal_operators_distinctUntilChanged__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_23__internal_operators_distinctUntilKeyChanged__ = __webpack_require__(311); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "distinctUntilKeyChanged", function() { return __WEBPACK_IMPORTED_MODULE_23__internal_operators_distinctUntilKeyChanged__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_24__internal_operators_elementAt__ = __webpack_require__(312); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "elementAt", function() { return __WEBPACK_IMPORTED_MODULE_24__internal_operators_elementAt__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_25__internal_operators_endWith__ = __webpack_require__(313); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "endWith", function() { return __WEBPACK_IMPORTED_MODULE_25__internal_operators_endWith__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_26__internal_operators_every__ = __webpack_require__(314); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "every", function() { return __WEBPACK_IMPORTED_MODULE_26__internal_operators_every__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_27__internal_operators_exhaust__ = __webpack_require__(315); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "exhaust", function() { return __WEBPACK_IMPORTED_MODULE_27__internal_operators_exhaust__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_28__internal_operators_exhaustMap__ = __webpack_require__(316); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "exhaustMap", function() { return __WEBPACK_IMPORTED_MODULE_28__internal_operators_exhaustMap__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_29__internal_operators_expand__ = __webpack_require__(317); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "expand", function() { return __WEBPACK_IMPORTED_MODULE_29__internal_operators_expand__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_30__internal_operators_filter__ = __webpack_require__(37); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "filter", function() { return __WEBPACK_IMPORTED_MODULE_30__internal_operators_filter__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_31__internal_operators_finalize__ = __webpack_require__(318); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "finalize", function() { return __WEBPACK_IMPORTED_MODULE_31__internal_operators_finalize__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_32__internal_operators_find__ = __webpack_require__(131); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "find", function() { return __WEBPACK_IMPORTED_MODULE_32__internal_operators_find__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_33__internal_operators_findIndex__ = __webpack_require__(319); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "findIndex", function() { return __WEBPACK_IMPORTED_MODULE_33__internal_operators_findIndex__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_34__internal_operators_first__ = __webpack_require__(320); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "first", function() { return __WEBPACK_IMPORTED_MODULE_34__internal_operators_first__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_35__internal_operators_groupBy__ = __webpack_require__(107); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "groupBy", function() { return __WEBPACK_IMPORTED_MODULE_35__internal_operators_groupBy__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_36__internal_operators_ignoreElements__ = __webpack_require__(321); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "ignoreElements", function() { return __WEBPACK_IMPORTED_MODULE_36__internal_operators_ignoreElements__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_37__internal_operators_isEmpty__ = __webpack_require__(322); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "isEmpty", function() { return __WEBPACK_IMPORTED_MODULE_37__internal_operators_isEmpty__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_38__internal_operators_last__ = __webpack_require__(323); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "last", function() { return __WEBPACK_IMPORTED_MODULE_38__internal_operators_last__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_39__internal_operators_map__ = __webpack_require__(15); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "map", function() { return __WEBPACK_IMPORTED_MODULE_39__internal_operators_map__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_40__internal_operators_mapTo__ = __webpack_require__(324); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "mapTo", function() { return __WEBPACK_IMPORTED_MODULE_40__internal_operators_mapTo__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_41__internal_operators_materialize__ = __webpack_require__(325); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "materialize", function() { return __WEBPACK_IMPORTED_MODULE_41__internal_operators_materialize__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_42__internal_operators_max__ = __webpack_require__(326); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "max", function() { return __WEBPACK_IMPORTED_MODULE_42__internal_operators_max__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_43__internal_operators_merge__ = __webpack_require__(327); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "merge", function() { return __WEBPACK_IMPORTED_MODULE_43__internal_operators_merge__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_44__internal_operators_mergeAll__ = __webpack_require__(70); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "mergeAll", function() { return __WEBPACK_IMPORTED_MODULE_44__internal_operators_mergeAll__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_45__internal_operators_mergeMap__ = __webpack_require__(35); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "mergeMap", function() { return __WEBPACK_IMPORTED_MODULE_45__internal_operators_mergeMap__["a"]; }); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "flatMap", function() { return __WEBPACK_IMPORTED_MODULE_45__internal_operators_mergeMap__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_46__internal_operators_mergeMapTo__ = __webpack_require__(328); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "mergeMapTo", function() { return __WEBPACK_IMPORTED_MODULE_46__internal_operators_mergeMapTo__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_47__internal_operators_mergeScan__ = __webpack_require__(329); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "mergeScan", function() { return __WEBPACK_IMPORTED_MODULE_47__internal_operators_mergeScan__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_48__internal_operators_min__ = __webpack_require__(330); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "min", function() { return __WEBPACK_IMPORTED_MODULE_48__internal_operators_min__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_49__internal_operators_multicast__ = __webpack_require__(26); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "multicast", function() { return __WEBPACK_IMPORTED_MODULE_49__internal_operators_multicast__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_50__internal_operators_observeOn__ = __webpack_require__(111); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "observeOn", function() { return __WEBPACK_IMPORTED_MODULE_50__internal_operators_observeOn__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_51__internal_operators_onErrorResumeNext__ = __webpack_require__(331); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "onErrorResumeNext", function() { return __WEBPACK_IMPORTED_MODULE_51__internal_operators_onErrorResumeNext__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_52__internal_operators_pairwise__ = __webpack_require__(332); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "pairwise", function() { return __WEBPACK_IMPORTED_MODULE_52__internal_operators_pairwise__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_53__internal_operators_partition__ = __webpack_require__(333); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "partition", function() { return __WEBPACK_IMPORTED_MODULE_53__internal_operators_partition__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_54__internal_operators_pluck__ = __webpack_require__(335); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "pluck", function() { return __WEBPACK_IMPORTED_MODULE_54__internal_operators_pluck__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_55__internal_operators_publish__ = __webpack_require__(336); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "publish", function() { return __WEBPACK_IMPORTED_MODULE_55__internal_operators_publish__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_56__internal_operators_publishBehavior__ = __webpack_require__(337); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "publishBehavior", function() { return __WEBPACK_IMPORTED_MODULE_56__internal_operators_publishBehavior__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_57__internal_operators_publishLast__ = __webpack_require__(338); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "publishLast", function() { return __WEBPACK_IMPORTED_MODULE_57__internal_operators_publishLast__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_58__internal_operators_publishReplay__ = __webpack_require__(339); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "publishReplay", function() { return __WEBPACK_IMPORTED_MODULE_58__internal_operators_publishReplay__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_59__internal_operators_race__ = __webpack_require__(340); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "race", function() { return __WEBPACK_IMPORTED_MODULE_59__internal_operators_race__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_60__internal_operators_reduce__ = __webpack_require__(50); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "reduce", function() { return __WEBPACK_IMPORTED_MODULE_60__internal_operators_reduce__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_61__internal_operators_repeat__ = __webpack_require__(341); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "repeat", function() { return __WEBPACK_IMPORTED_MODULE_61__internal_operators_repeat__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_62__internal_operators_repeatWhen__ = __webpack_require__(342); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "repeatWhen", function() { return __WEBPACK_IMPORTED_MODULE_62__internal_operators_repeatWhen__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_63__internal_operators_retry__ = __webpack_require__(343); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "retry", function() { return __WEBPACK_IMPORTED_MODULE_63__internal_operators_retry__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_64__internal_operators_retryWhen__ = __webpack_require__(344); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "retryWhen", function() { return __WEBPACK_IMPORTED_MODULE_64__internal_operators_retryWhen__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_65__internal_operators_refCount__ = __webpack_require__(64); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "refCount", function() { return __WEBPACK_IMPORTED_MODULE_65__internal_operators_refCount__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_66__internal_operators_sample__ = __webpack_require__(345); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "sample", function() { return __WEBPACK_IMPORTED_MODULE_66__internal_operators_sample__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_67__internal_operators_sampleTime__ = __webpack_require__(346); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "sampleTime", function() { return __WEBPACK_IMPORTED_MODULE_67__internal_operators_sampleTime__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_68__internal_operators_scan__ = __webpack_require__(75); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "scan", function() { return __WEBPACK_IMPORTED_MODULE_68__internal_operators_scan__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_69__internal_operators_sequenceEqual__ = __webpack_require__(347); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "sequenceEqual", function() { return __WEBPACK_IMPORTED_MODULE_69__internal_operators_sequenceEqual__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_70__internal_operators_share__ = __webpack_require__(348); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "share", function() { return __WEBPACK_IMPORTED_MODULE_70__internal_operators_share__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_71__internal_operators_shareReplay__ = __webpack_require__(349); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "shareReplay", function() { return __WEBPACK_IMPORTED_MODULE_71__internal_operators_shareReplay__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_72__internal_operators_single__ = __webpack_require__(350); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "single", function() { return __WEBPACK_IMPORTED_MODULE_72__internal_operators_single__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_73__internal_operators_skip__ = __webpack_require__(351); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "skip", function() { return __WEBPACK_IMPORTED_MODULE_73__internal_operators_skip__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_74__internal_operators_skipLast__ = __webpack_require__(352); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "skipLast", function() { return __WEBPACK_IMPORTED_MODULE_74__internal_operators_skipLast__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_75__internal_operators_skipUntil__ = __webpack_require__(353); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "skipUntil", function() { return __WEBPACK_IMPORTED_MODULE_75__internal_operators_skipUntil__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_76__internal_operators_skipWhile__ = __webpack_require__(354); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "skipWhile", function() { return __WEBPACK_IMPORTED_MODULE_76__internal_operators_skipWhile__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_77__internal_operators_startWith__ = __webpack_require__(355); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "startWith", function() { return __WEBPACK_IMPORTED_MODULE_77__internal_operators_startWith__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_78__internal_operators_subscribeOn__ = __webpack_require__(356); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "subscribeOn", function() { return __WEBPACK_IMPORTED_MODULE_78__internal_operators_subscribeOn__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_79__internal_operators_switchAll__ = __webpack_require__(358); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "switchAll", function() { return __WEBPACK_IMPORTED_MODULE_79__internal_operators_switchAll__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_80__internal_operators_switchMap__ = __webpack_require__(76); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "switchMap", function() { return __WEBPACK_IMPORTED_MODULE_80__internal_operators_switchMap__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_81__internal_operators_switchMapTo__ = __webpack_require__(359); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "switchMapTo", function() { return __WEBPACK_IMPORTED_MODULE_81__internal_operators_switchMapTo__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_82__internal_operators_take__ = __webpack_require__(73); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "take", function() { return __WEBPACK_IMPORTED_MODULE_82__internal_operators_take__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_83__internal_operators_takeLast__ = __webpack_require__(74); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "takeLast", function() { return __WEBPACK_IMPORTED_MODULE_83__internal_operators_takeLast__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_84__internal_operators_takeUntil__ = __webpack_require__(360); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "takeUntil", function() { return __WEBPACK_IMPORTED_MODULE_84__internal_operators_takeUntil__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_85__internal_operators_takeWhile__ = __webpack_require__(361); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "takeWhile", function() { return __WEBPACK_IMPORTED_MODULE_85__internal_operators_takeWhile__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_86__internal_operators_tap__ = __webpack_require__(130); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "tap", function() { return __WEBPACK_IMPORTED_MODULE_86__internal_operators_tap__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_87__internal_operators_throttle__ = __webpack_require__(132); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "throttle", function() { return __WEBPACK_IMPORTED_MODULE_87__internal_operators_throttle__["b"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_88__internal_operators_throttleTime__ = __webpack_require__(362); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "throttleTime", function() { return __WEBPACK_IMPORTED_MODULE_88__internal_operators_throttleTime__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_89__internal_operators_throwIfEmpty__ = __webpack_require__(49); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "throwIfEmpty", function() { return __WEBPACK_IMPORTED_MODULE_89__internal_operators_throwIfEmpty__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_90__internal_operators_timeInterval__ = __webpack_require__(363); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "timeInterval", function() { return __WEBPACK_IMPORTED_MODULE_90__internal_operators_timeInterval__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_91__internal_operators_timeout__ = __webpack_require__(364); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "timeout", function() { return __WEBPACK_IMPORTED_MODULE_91__internal_operators_timeout__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_92__internal_operators_timeoutWith__ = __webpack_require__(133); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "timeoutWith", function() { return __WEBPACK_IMPORTED_MODULE_92__internal_operators_timeoutWith__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_93__internal_operators_timestamp__ = __webpack_require__(365); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "timestamp", function() { return __WEBPACK_IMPORTED_MODULE_93__internal_operators_timestamp__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_94__internal_operators_toArray__ = __webpack_require__(366); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "toArray", function() { return __WEBPACK_IMPORTED_MODULE_94__internal_operators_toArray__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_95__internal_operators_window__ = __webpack_require__(367); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "window", function() { return __WEBPACK_IMPORTED_MODULE_95__internal_operators_window__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_96__internal_operators_windowCount__ = __webpack_require__(368); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "windowCount", function() { return __WEBPACK_IMPORTED_MODULE_96__internal_operators_windowCount__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_97__internal_operators_windowTime__ = __webpack_require__(369); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "windowTime", function() { return __WEBPACK_IMPORTED_MODULE_97__internal_operators_windowTime__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_98__internal_operators_windowToggle__ = __webpack_require__(370); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "windowToggle", function() { return __WEBPACK_IMPORTED_MODULE_98__internal_operators_windowToggle__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_99__internal_operators_windowWhen__ = __webpack_require__(371); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "windowWhen", function() { return __WEBPACK_IMPORTED_MODULE_99__internal_operators_windowWhen__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_100__internal_operators_withLatestFrom__ = __webpack_require__(372); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "withLatestFrom", function() { return __WEBPACK_IMPORTED_MODULE_100__internal_operators_withLatestFrom__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_101__internal_operators_zip__ = __webpack_require__(373); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "zip", function() { return __WEBPACK_IMPORTED_MODULE_101__internal_operators_zip__["a"]; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_102__internal_operators_zipAll__ = __webpack_require__(374); -/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "zipAll", function() { return __WEBPACK_IMPORTED_MODULE_102__internal_operators_zipAll__["a"]; }); -/** PURE_IMPORTS_START PURE_IMPORTS_END */ + const promise = fs + .stat(src) + .then(stat => { + progressEmitter.size = stat.size; + }) + .then(() => fs.createReadStream(src)) + .then(read => fs.makeDir(path.dirname(dest)).then(() => read)) + .then(read => new Promise((resolve, reject) => { + const write = fs.createWriteStream(dest, {flags: opts.overwrite ? 'w' : 'wx'}); + read.on('data', () => { + progressEmitter.written = write.bytesWritten; + }); + write.on('error', err => { + if (!opts.overwrite && err.code === 'EEXIST') { + resolve(false); + return; + } + reject(new CpFileError(`Cannot write to \`${dest}\`: ${err.message}`, err)); + }); + write.on('close', () => { + progressEmitter.written = progressEmitter.size; + resolve(true); + }); + read.pipe(write); + })) + .then(updateStats => { + if (updateStats) { + return fs.lstat(src).then(stats => Promise.all([ + fs.utimes(dest, stats.atime, stats.mtime), + fs.chmod(dest, stats.mode), + fs.chown(dest, stats.uid, stats.gid) + ])); + } + }); + promise.on = function () { + progressEmitter.on.apply(progressEmitter, arguments); + return promise; + }; + return promise; +}; +const checkSrcIsFile = (stat, src) => { + if (stat.isDirectory()) { + throw Object.assign(new CpFileError(`EISDIR: illegal operation on a directory '${src}'`), { + errno: -21, + code: 'EISDIR', + src + }); + } +}; +const fixupAttributes = (dest, stat) => { + fs.chmodSync(dest, stat.mode); + fs.chownSync(dest, stat.uid, stat.gid); +}; +const copySyncNative = (src, dest, opts) => { + const stat = fs.statSync(src); + checkSrcIsFile(stat, src); + fs.makeDirSync(path.dirname(dest)); + const flags = opts.overwrite ? null : fsConstants.COPYFILE_EXCL; + try { + fs.copyFileSync(src, dest, flags); + } catch (err) { + if (!opts.overwrite && err.code === 'EEXIST') { + return; + } + throw err; + } + fs.utimesSync(dest, stat.atime, stat.mtime); + fixupAttributes(dest, stat); +}; +const copySyncFallback = (src, dest, opts) => { + let read; // eslint-disable-line prefer-const + let bytesRead; + let pos; + let write; + const BUF_LENGTH = 100 * 1024; + const buf = Buffer.alloc(BUF_LENGTH); + const readSync = pos => fs.readSync(read, buf, 0, BUF_LENGTH, pos, src); + const writeSync = () => fs.writeSync(write, buf, 0, bytesRead, undefined, dest); + read = fs.openSync(src, 'r'); + bytesRead = readSync(0); + pos = bytesRead; + fs.makeDirSync(path.dirname(dest)); + try { + write = fs.openSync(dest, opts.overwrite ? 'w' : 'wx'); + } catch (err) { + if (!opts.overwrite && err.code === 'EEXIST') { + return; + } + throw err; + } + writeSync(); + while (bytesRead === BUF_LENGTH) { + bytesRead = readSync(pos); + writeSync(); + pos += bytesRead; + } + const stat = fs.fstatSync(read, src); + fs.futimesSync(write, stat.atime, stat.mtime, dest); + fs.closeSync(read); + fs.closeSync(write); + fixupAttributes(dest, stat); +}; +module.exports.sync = (src, dest, opts) => { + if (!src || !dest) { + throw new CpFileError('`src` and `dest` required'); + } + opts = Object.assign({overwrite: true}, opts); + if (fs.copyFileSync) { + copySyncNative(src, dest, opts); + } else { + copySyncFallback(src, dest, opts); + } +}; +/***/ }), +/* 256 */ +/***/ (function(module, exports, __webpack_require__) { +/* eslint-disable node/no-deprecated-api */ +var buffer = __webpack_require__(257) +var Buffer = buffer.Buffer +// alternative to using Object.keys for old browsers +function copyProps (src, dst) { + for (var key in src) { + dst[key] = src[key] + } +} +if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { + module.exports = buffer +} else { + // Copy properties from require('buffer') + copyProps(buffer, exports) + exports.Buffer = SafeBuffer +} +function SafeBuffer (arg, encodingOrOffset, length) { + return Buffer(arg, encodingOrOffset, length) +} +// Copy static methods from Buffer +copyProps(Buffer, SafeBuffer) +SafeBuffer.from = function (arg, encodingOrOffset, length) { + if (typeof arg === 'number') { + throw new TypeError('Argument must not be a number') + } + return Buffer(arg, encodingOrOffset, length) +} +SafeBuffer.alloc = function (size, fill, encoding) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + var buf = Buffer(size) + if (fill !== undefined) { + if (typeof encoding === 'string') { + buf.fill(fill, encoding) + } else { + buf.fill(fill) + } + } else { + buf.fill(0) + } + return buf +} +SafeBuffer.allocUnsafe = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return Buffer(size) +} +SafeBuffer.allocUnsafeSlow = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return buffer.SlowBuffer(size) +} +/***/ }), +/* 257 */ +/***/ (function(module, exports) { +module.exports = require("buffer"); +/***/ }), +/* 258 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +const fs = __webpack_require__(56); +const makeDir = __webpack_require__(106); +const pify = __webpack_require__(44); +const CpFileError = __webpack_require__(117); +const fsP = pify(fs); +exports.closeSync = fs.closeSync.bind(fs); +exports.createWriteStream = fs.createWriteStream.bind(fs); +exports.createReadStream = (path, options) => new Promise((resolve, reject) => { + const read = fs.createReadStream(path, options); + read.on('error', err => { + reject(new CpFileError(`Cannot read from \`${path}\`: ${err.message}`, err)); + }); + read.on('readable', () => { + resolve(read); + }); + read.on('end', () => { + resolve(read); + }); +}); +exports.stat = path => fsP.stat(path).catch(err => { + throw new CpFileError(`Cannot stat path \`${path}\`: ${err.message}`, err); +}); +exports.lstat = path => fsP.lstat(path).catch(err => { + throw new CpFileError(`lstat \`${path}\` failed: ${err.message}`, err); +}); +exports.utimes = (path, atime, mtime) => fsP.utimes(path, atime, mtime).catch(err => { + throw new CpFileError(`utimes \`${path}\` failed: ${err.message}`, err); +}); +exports.chmod = (path, mode) => fsP.chmod(path, mode).catch(err => { + throw new CpFileError(`chmod \`${path}\` failed: ${err.message}`, err); +}); +exports.chown = (path, uid, gid) => fsP.chown(path, uid, gid).catch(err => { + throw new CpFileError(`chown \`${path}\` failed: ${err.message}`, err); +}); +exports.openSync = (path, flags, mode) => { + try { + return fs.openSync(path, flags, mode); + } catch (err) { + if (flags.includes('w')) { + throw new CpFileError(`Cannot write to \`${path}\`: ${err.message}`, err); + } + throw new CpFileError(`Cannot open \`${path}\`: ${err.message}`, err); + } +}; +// eslint-disable-next-line max-params +exports.readSync = (fd, buffer, offset, length, position, path) => { + try { + return fs.readSync(fd, buffer, offset, length, position); + } catch (err) { + throw new CpFileError(`Cannot read from \`${path}\`: ${err.message}`, err); + } +}; +// eslint-disable-next-line max-params +exports.writeSync = (fd, buffer, offset, length, position, path) => { + try { + return fs.writeSync(fd, buffer, offset, length, position); + } catch (err) { + throw new CpFileError(`Cannot write to \`${path}\`: ${err.message}`, err); + } +}; +exports.statSync = path => { + try { + return fs.statSync(path); + } catch (err) { + throw new CpFileError(`stat \`${path}\` failed: ${err.message}`, err); + } +}; +exports.fstatSync = (fd, path) => { + try { + return fs.fstatSync(fd); + } catch (err) { + throw new CpFileError(`fstat \`${path}\` failed: ${err.message}`, err); + } +}; +exports.futimesSync = (fd, atime, mtime, path) => { + try { + return fs.futimesSync(fd, atime, mtime, path); + } catch (err) { + throw new CpFileError(`futimes \`${path}\` failed: ${err.message}`, err); + } +}; +exports.utimesSync = (path, atime, mtime) => { + try { + return fs.utimesSync(path, atime, mtime); + } catch (err) { + throw new CpFileError(`utimes \`${path}\` failed: ${err.message}`, err); + } +}; +exports.chmodSync = (path, mode) => { + try { + return fs.chmodSync(path, mode); + } catch (err) { + throw new CpFileError(`chmod \`${path}\` failed: ${err.message}`, err); + } +}; +exports.chownSync = (path, uid, gid) => { + try { + return fs.chownSync(path, uid, gid); + } catch (err) { + throw new CpFileError(`chown \`${path}\` failed: ${err.message}`, err); + } +}; +exports.makeDir = path => makeDir(path, {fs}).catch(err => { + throw new CpFileError(`Cannot create directory \`${path}\`: ${err.message}`, err); +}); +exports.makeDirSync = path => { + try { + makeDir.sync(path, {fs}); + } catch (err) { + throw new CpFileError(`Cannot create directory \`${path}\`: ${err.message}`, err); + } +}; +if (fs.copyFileSync) { + exports.copyFileSync = (src, dest, flags) => { + try { + fs.copyFileSync(src, dest, flags); + } catch (err) { + throw new CpFileError(`Cannot copy from \`${src}\` to \`${dest}\`: ${err.message}`, err); + } + }; +} +/***/ }), +/* 259 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +const EventEmitter = __webpack_require__(61); +const written = new WeakMap(); +class ProgressEmitter extends EventEmitter { + constructor(src, dest) { + super(); + this.src = src; + this.dest = dest; + } + set written(value) { + written.set(this, value); + this.emitProgress(); + } + get written() { + return written.get(this); + } + emitProgress() { + const size = this.size; + const written = this.written; + this.emit('progress', { + src: this.src, + dest: this.dest, + size, + written, + percent: written === size ? 1 : written / size + }); + } +} +module.exports = ProgressEmitter; +/***/ }), +/* 260 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +const NestedError = __webpack_require__(118); +class CpyError extends NestedError { + constructor(message, nested) { + super(message, nested); + Object.assign(this, nested); + this.name = 'CpyError'; + } +} +module.exports = CpyError; +/***/ }), +/* 261 */ +/***/ (function(module, exports, __webpack_require__) { +"use strict"; +Object.defineProperty(exports, "__esModule", { + value: true +}); +exports.prepareExternalProjectDependencies = undefined; +/** + * This prepares the dependencies for an _external_ project. + */ +let prepareExternalProjectDependencies = exports.prepareExternalProjectDependencies = (() => { + var _ref = _asyncToGenerator(function* (projectPath) { + const project = yield _project.Project.fromPath(projectPath); + if (!project.hasDependencies()) { + return; + } + const deps = project.allDependencies; + for (const depName of Object.keys(deps)) { + const depVersion = deps[depName]; + // Kibana currently only supports `link:` dependencies on Kibana's own + // packages, as these are packaged into the `node_modules` folder when + // Kibana is built, so we don't need to take any action to enable + // `require(...)` to resolve for these packages. + if ((0, _package_json.isLinkDependency)(depVersion) && !isKibanaDep(depVersion)) { + // For non-Kibana packages we need to set up symlinks during the + // installation process, but this is not something we support yet. + throw new Error('This plugin is using `link:` dependencies for non-Kibana packages'); + } + } + }); + return function prepareExternalProjectDependencies(_x) { + return _ref.apply(this, arguments); + }; +})(); +var _package_json = __webpack_require__(62); +var _project = __webpack_require__(101); +function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* + * 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. + */ +/** + * All external projects are located within `../kibana-extra/{plugin}` relative + * to Kibana itself. + */ +const isKibanaDep = depVersion => depVersion.includes('../../kibana/'); +/***/ }), +/* 262 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { +"use strict"; +__webpack_require__.r(__webpack_exports__); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/node_modules/tslib/tslib.es6.js +var tslib_es6 = __webpack_require__(0); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/tryCatch.js +var tryCatch = __webpack_require__(14); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/errorObject.js +var errorObject = __webpack_require__(6); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/OuterSubscriber.js +var OuterSubscriber = __webpack_require__(4); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/subscribeToResult.js + 1 modules +var subscribeToResult = __webpack_require__(3); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/audit.js +/** PURE_IMPORTS_START tslib,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -//# sourceMappingURL=index.js.map +function audit(durationSelector) { + return function auditOperatorFunction(source) { + return source.lift(new AuditOperator(durationSelector)); + }; +} +var AuditOperator = /*@__PURE__*/ (function () { + function AuditOperator(durationSelector) { + this.durationSelector = durationSelector; + } + AuditOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new audit_AuditSubscriber(subscriber, this.durationSelector)); + }; + return AuditOperator; +}()); +var audit_AuditSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](AuditSubscriber, _super); + function AuditSubscriber(destination, durationSelector) { + var _this = _super.call(this, destination) || this; + _this.durationSelector = durationSelector; + _this.hasValue = false; + return _this; + } + AuditSubscriber.prototype._next = function (value) { + this.value = value; + this.hasValue = true; + if (!this.throttled) { + var duration = Object(tryCatch["a" /* tryCatch */])(this.durationSelector)(value); + if (duration === errorObject["a" /* errorObject */]) { + this.destination.error(errorObject["a" /* errorObject */].e); + } + else { + var innerSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(this, duration); + if (!innerSubscription || innerSubscription.closed) { + this.clearThrottle(); + } + else { + this.add(this.throttled = innerSubscription); + } + } + } + }; + AuditSubscriber.prototype.clearThrottle = function () { + var _a = this, value = _a.value, hasValue = _a.hasValue, throttled = _a.throttled; + if (throttled) { + this.remove(throttled); + this.throttled = null; + throttled.unsubscribe(); + } + if (hasValue) { + this.value = null; + this.hasValue = false; + this.destination.next(value); + } + }; + AuditSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex) { + this.clearThrottle(); + }; + AuditSubscriber.prototype.notifyComplete = function () { + this.clearThrottle(); + }; + return AuditSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=audit.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/async.js +var scheduler_async = __webpack_require__(10); -/***/ }), -/* 293 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/timer.js +var timer = __webpack_require__(71); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = auditTime; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__audit__ = __webpack_require__(126); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__observable_timer__ = __webpack_require__(125); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/auditTime.js /** PURE_IMPORTS_START _scheduler_async,_audit,_observable_timer PURE_IMPORTS_END */ function auditTime(duration, scheduler) { if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_0__scheduler_async__["a" /* async */]; + scheduler = scheduler_async["a" /* async */]; } - return Object(__WEBPACK_IMPORTED_MODULE_1__audit__["a" /* audit */])(function () { return Object(__WEBPACK_IMPORTED_MODULE_2__observable_timer__["a" /* timer */])(duration, scheduler); }); + return audit(function () { return Object(timer["a" /* timer */])(duration, scheduler); }); } //# sourceMappingURL=auditTime.js.map - -/***/ }), -/* 294 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = buffer; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/buffer.js /** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function buffer(closingNotifier) { +function buffer_buffer(closingNotifier) { return function bufferOperatorFunction(source) { return source.lift(new BufferOperator(closingNotifier)); }; @@ -27648,16 +26388,16 @@ var BufferOperator = /*@__PURE__*/ (function () { this.closingNotifier = closingNotifier; } BufferOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new BufferSubscriber(subscriber, this.closingNotifier)); + return source.subscribe(new buffer_BufferSubscriber(subscriber, this.closingNotifier)); }; return BufferOperator; }()); -var BufferSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](BufferSubscriber, _super); +var buffer_BufferSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](BufferSubscriber, _super); function BufferSubscriber(destination, closingNotifier) { var _this = _super.call(this, destination) || this; _this.buffer = []; - _this.add(Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(_this, closingNotifier)); + _this.add(Object(subscribeToResult["a" /* subscribeToResult */])(_this, closingNotifier)); return _this; } BufferSubscriber.prototype._next = function (value) { @@ -27669,18 +26409,13 @@ var BufferSubscriber = /*@__PURE__*/ (function (_super) { this.destination.next(buffer); }; return BufferSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); +}(OuterSubscriber["a" /* OuterSubscriber */])); //# sourceMappingURL=buffer.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subscriber.js +var Subscriber = __webpack_require__(1); -/***/ }), -/* 295 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = bufferCount; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/bufferCount.js /** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ @@ -27697,10 +26432,10 @@ var BufferCountOperator = /*@__PURE__*/ (function () { this.bufferSize = bufferSize; this.startBufferEvery = startBufferEvery; if (!startBufferEvery || bufferSize === startBufferEvery) { - this.subscriberClass = BufferCountSubscriber; + this.subscriberClass = bufferCount_BufferCountSubscriber; } else { - this.subscriberClass = BufferSkipCountSubscriber; + this.subscriberClass = bufferCount_BufferSkipCountSubscriber; } } BufferCountOperator.prototype.call = function (subscriber, source) { @@ -27708,8 +26443,8 @@ var BufferCountOperator = /*@__PURE__*/ (function () { }; return BufferCountOperator; }()); -var BufferCountSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](BufferCountSubscriber, _super); +var bufferCount_BufferCountSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](BufferCountSubscriber, _super); function BufferCountSubscriber(destination, bufferSize) { var _this = _super.call(this, destination) || this; _this.bufferSize = bufferSize; @@ -27732,9 +26467,9 @@ var BufferCountSubscriber = /*@__PURE__*/ (function (_super) { _super.prototype._complete.call(this); }; return BufferCountSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -var BufferSkipCountSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](BufferSkipCountSubscriber, _super); +}(Subscriber["a" /* Subscriber */])); +var bufferCount_BufferSkipCountSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](BufferSkipCountSubscriber, _super); function BufferSkipCountSubscriber(destination, bufferSize, startBufferEvery) { var _this = _super.call(this, destination) || this; _this.bufferSize = bufferSize; @@ -27769,20 +26504,13 @@ var BufferSkipCountSubscriber = /*@__PURE__*/ (function (_super) { _super.prototype._complete.call(this); }; return BufferSkipCountSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); +}(Subscriber["a" /* Subscriber */])); //# sourceMappingURL=bufferCount.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isScheduler.js +var isScheduler = __webpack_require__(12); -/***/ }), -/* 296 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = bufferTime; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_isScheduler__ = __webpack_require__(14); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/bufferTime.js /** PURE_IMPORTS_START tslib,_scheduler_async,_Subscriber,_util_isScheduler PURE_IMPORTS_END */ @@ -27790,8 +26518,8 @@ var BufferSkipCountSubscriber = /*@__PURE__*/ (function (_super) { function bufferTime(bufferTimeSpan) { var length = arguments.length; - var scheduler = __WEBPACK_IMPORTED_MODULE_1__scheduler_async__["a" /* async */]; - if (Object(__WEBPACK_IMPORTED_MODULE_3__util_isScheduler__["a" /* isScheduler */])(arguments[arguments.length - 1])) { + var scheduler = scheduler_async["a" /* async */]; + if (Object(isScheduler["a" /* isScheduler */])(arguments[arguments.length - 1])) { scheduler = arguments[arguments.length - 1]; length--; } @@ -27815,7 +26543,7 @@ var BufferTimeOperator = /*@__PURE__*/ (function () { this.scheduler = scheduler; } BufferTimeOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new BufferTimeSubscriber(subscriber, this.bufferTimeSpan, this.bufferCreationInterval, this.maxBufferSize, this.scheduler)); + return source.subscribe(new bufferTime_BufferTimeSubscriber(subscriber, this.bufferTimeSpan, this.bufferCreationInterval, this.maxBufferSize, this.scheduler)); }; return BufferTimeOperator; }()); @@ -27825,8 +26553,8 @@ var Context = /*@__PURE__*/ (function () { } return Context; }()); -var BufferTimeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](BufferTimeSubscriber, _super); +var bufferTime_BufferTimeSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](BufferTimeSubscriber, _super); function BufferTimeSubscriber(destination, bufferTimeSpan, bufferCreationInterval, maxBufferSize, scheduler) { var _this = _super.call(this, destination) || this; _this.bufferTimeSpan = bufferTimeSpan; @@ -27905,7 +26633,7 @@ var BufferTimeSubscriber = /*@__PURE__*/ (function (_super) { } }; return BufferTimeSubscriber; -}(__WEBPACK_IMPORTED_MODULE_2__Subscriber__["a" /* Subscriber */])); +}(Subscriber["a" /* Subscriber */])); function dispatchBufferTimeSpanOnly(state) { var subscriber = state.subscriber; var prevContext = state.context; @@ -27932,17 +26660,10 @@ function dispatchBufferClose(arg) { } //# sourceMappingURL=bufferTime.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subscription.js +var Subscription = __webpack_require__(5); -/***/ }), -/* 297 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = bufferToggle; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__ = __webpack_require__(4); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/bufferToggle.js /** PURE_IMPORTS_START tslib,_Subscription,_util_subscribeToResult,_OuterSubscriber PURE_IMPORTS_END */ @@ -27959,18 +26680,18 @@ var BufferToggleOperator = /*@__PURE__*/ (function () { this.closingSelector = closingSelector; } BufferToggleOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new BufferToggleSubscriber(subscriber, this.openings, this.closingSelector)); + return source.subscribe(new bufferToggle_BufferToggleSubscriber(subscriber, this.openings, this.closingSelector)); }; return BufferToggleOperator; }()); -var BufferToggleSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](BufferToggleSubscriber, _super); +var bufferToggle_BufferToggleSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](BufferToggleSubscriber, _super); function BufferToggleSubscriber(destination, openings, closingSelector) { var _this = _super.call(this, destination) || this; _this.openings = openings; _this.closingSelector = closingSelector; _this.contexts = []; - _this.add(Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(_this, openings)); + _this.add(Object(subscribeToResult["a" /* subscribeToResult */])(_this, openings)); return _this; } BufferToggleSubscriber.prototype._next = function (value) { @@ -28034,10 +26755,10 @@ var BufferToggleSubscriber = /*@__PURE__*/ (function (_super) { BufferToggleSubscriber.prototype.trySubscribe = function (closingNotifier) { var contexts = this.contexts; var buffer = []; - var subscription = new __WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */](); + var subscription = new Subscription["a" /* Subscription */](); var context = { buffer: buffer, subscription: subscription }; contexts.push(context); - var innerSubscription = Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(this, closingNotifier, context); + var innerSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(this, closingNotifier, context); if (!innerSubscription || innerSubscription.closed) { this.closeBuffer(context); } @@ -28048,22 +26769,10 @@ var BufferToggleSubscriber = /*@__PURE__*/ (function (_super) { } }; return BufferToggleSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__["a" /* OuterSubscriber */])); +}(OuterSubscriber["a" /* OuterSubscriber */])); //# sourceMappingURL=bufferToggle.js.map - -/***/ }), -/* 298 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = bufferWhen; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__ = __webpack_require__(5); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/bufferWhen.js /** PURE_IMPORTS_START tslib,_Subscription,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ @@ -28081,12 +26790,12 @@ var BufferWhenOperator = /*@__PURE__*/ (function () { this.closingSelector = closingSelector; } BufferWhenOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new BufferWhenSubscriber(subscriber, this.closingSelector)); + return source.subscribe(new bufferWhen_BufferWhenSubscriber(subscriber, this.closingSelector)); }; return BufferWhenOperator; }()); -var BufferWhenSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](BufferWhenSubscriber, _super); +var bufferWhen_BufferWhenSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](BufferWhenSubscriber, _super); function BufferWhenSubscriber(destination, closingSelector) { var _this = _super.call(this, destination) || this; _this.closingSelector = closingSelector; @@ -28130,33 +26839,24 @@ var BufferWhenSubscriber = /*@__PURE__*/ (function (_super) { this.destination.next(buffer); } this.buffer = []; - var closingNotifier = Object(__WEBPACK_IMPORTED_MODULE_2__util_tryCatch__["a" /* tryCatch */])(this.closingSelector)(); - if (closingNotifier === __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */]) { - this.error(__WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */].e); + var closingNotifier = Object(tryCatch["a" /* tryCatch */])(this.closingSelector)(); + if (closingNotifier === errorObject["a" /* errorObject */]) { + this.error(errorObject["a" /* errorObject */].e); } else { - closingSubscription = new __WEBPACK_IMPORTED_MODULE_1__Subscription__["a" /* Subscription */](); + closingSubscription = new Subscription["a" /* Subscription */](); this.closingSubscription = closingSubscription; this.add(closingSubscription); this.subscribing = true; - closingSubscription.add(Object(__WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__["a" /* subscribeToResult */])(this, closingNotifier)); + closingSubscription.add(Object(subscribeToResult["a" /* subscribeToResult */])(this, closingNotifier)); this.subscribing = false; } }; return BufferWhenSubscriber; -}(__WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__["a" /* OuterSubscriber */])); +}(OuterSubscriber["a" /* OuterSubscriber */])); //# sourceMappingURL=bufferWhen.js.map - -/***/ }), -/* 299 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = catchError; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/catchError.js /** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ @@ -28173,12 +26873,12 @@ var CatchOperator = /*@__PURE__*/ (function () { this.selector = selector; } CatchOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new CatchSubscriber(subscriber, this.selector, this.caught)); + return source.subscribe(new catchError_CatchSubscriber(subscriber, this.selector, this.caught)); }; return CatchOperator; }()); -var CatchSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](CatchSubscriber, _super); +var catchError_CatchSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](CatchSubscriber, _super); function CatchSubscriber(destination, selector, caught) { var _this = _super.call(this, destination) || this; _this.selector = selector; @@ -28196,44 +26896,37 @@ var CatchSubscriber = /*@__PURE__*/ (function (_super) { return; } this._unsubscribeAndRecycle(); - this.add(Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(this, result)); + this.add(Object(subscribeToResult["a" /* subscribeToResult */])(this, result)); } }; return CatchSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); +}(OuterSubscriber["a" /* OuterSubscriber */])); //# sourceMappingURL=catchError.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/combineLatest.js +var combineLatest = __webpack_require__(49); -/***/ }), -/* 300 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = combineAll; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_combineLatest__ = __webpack_require__(69); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/combineAll.js /** PURE_IMPORTS_START _observable_combineLatest PURE_IMPORTS_END */ function combineAll(project) { - return function (source) { return source.lift(new __WEBPACK_IMPORTED_MODULE_0__observable_combineLatest__["a" /* CombineLatestOperator */](project)); }; + return function (source) { return source.lift(new combineLatest["a" /* CombineLatestOperator */](project)); }; } //# sourceMappingURL=combineAll.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isArray.js +var isArray = __webpack_require__(11); -/***/ }), -/* 301 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/from.js + 5 modules +var from = __webpack_require__(15); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = combineLatest; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__observable_combineLatest__ = __webpack_require__(69); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__observable_from__ = __webpack_require__(18); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/combineLatest.js /** PURE_IMPORTS_START _util_isArray,_observable_combineLatest,_observable_from PURE_IMPORTS_END */ var none = {}; -function combineLatest() { +function combineLatest_combineLatest() { var observables = []; for (var _i = 0; _i < arguments.length; _i++) { observables[_i] = arguments[_i]; @@ -28242,60 +26935,55 @@ function combineLatest() { if (typeof observables[observables.length - 1] === 'function') { project = observables.pop(); } - if (observables.length === 1 && Object(__WEBPACK_IMPORTED_MODULE_0__util_isArray__["a" /* isArray */])(observables[0])) { + if (observables.length === 1 && Object(isArray["a" /* isArray */])(observables[0])) { observables = observables[0].slice(); } - return function (source) { return source.lift.call(Object(__WEBPACK_IMPORTED_MODULE_2__observable_from__["a" /* from */])([source].concat(observables)), new __WEBPACK_IMPORTED_MODULE_1__observable_combineLatest__["a" /* CombineLatestOperator */](project)); }; + return function (source) { return source.lift.call(Object(from["a" /* from */])([source].concat(observables)), new combineLatest["a" /* CombineLatestOperator */](project)); }; } //# sourceMappingURL=combineLatest.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/concat.js +var concat = __webpack_require__(26); -/***/ }), -/* 302 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = concat; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_concat__ = __webpack_require__(47); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/concat.js /** PURE_IMPORTS_START _observable_concat PURE_IMPORTS_END */ -function concat() { +function concat_concat() { var observables = []; for (var _i = 0; _i < arguments.length; _i++) { observables[_i] = arguments[_i]; } - return function (source) { return source.lift.call(__WEBPACK_IMPORTED_MODULE_0__observable_concat__["a" /* concat */].apply(void 0, [source].concat(observables))); }; + return function (source) { return source.lift.call(concat["a" /* concat */].apply(void 0, [source].concat(observables))); }; } //# sourceMappingURL=concat.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/concatAll.js +var concatAll = __webpack_require__(68); -/***/ }), -/* 303 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/mergeMap.js +var mergeMap = __webpack_require__(27); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/concatMap.js +/** PURE_IMPORTS_START _mergeMap PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = concatMapTo; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__concatMap__ = __webpack_require__(127); +function concatMap(project, resultSelector) { + return Object(mergeMap["a" /* mergeMap */])(project, resultSelector, 1); +} +//# sourceMappingURL=concatMap.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/concatMapTo.js /** PURE_IMPORTS_START _concatMap PURE_IMPORTS_END */ function concatMapTo(innerObservable, resultSelector) { - return Object(__WEBPACK_IMPORTED_MODULE_0__concatMap__["a" /* concatMap */])(function () { return innerObservable; }, resultSelector); + return concatMap(function () { return innerObservable; }, resultSelector); } //# sourceMappingURL=concatMapTo.js.map - -/***/ }), -/* 304 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = count; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/count.js /** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function count(predicate) { +function count_count(predicate) { return function (source) { return source.lift(new CountOperator(predicate, source)); }; } var CountOperator = /*@__PURE__*/ (function () { @@ -28304,12 +26992,12 @@ var CountOperator = /*@__PURE__*/ (function () { this.source = source; } CountOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new CountSubscriber(subscriber, this.predicate, this.source)); + return source.subscribe(new count_CountSubscriber(subscriber, this.predicate, this.source)); }; return CountOperator; }()); -var CountSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](CountSubscriber, _super); +var count_CountSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](CountSubscriber, _super); function CountSubscriber(destination, predicate, source) { var _this = _super.call(this, destination) || this; _this.predicate = predicate; @@ -28336,5516 +27024,5422 @@ var CountSubscriber = /*@__PURE__*/ (function (_super) { return; } if (result) { - this.count++; - } - }; - CountSubscriber.prototype._complete = function () { - this.destination.next(this.count); - this.destination.complete(); - }; - return CountSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=count.js.map - - -/***/ }), -/* 305 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = debounce; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - - - -function debounce(durationSelector) { - return function (source) { return source.lift(new DebounceOperator(durationSelector)); }; -} -var DebounceOperator = /*@__PURE__*/ (function () { - function DebounceOperator(durationSelector) { - this.durationSelector = durationSelector; - } - DebounceOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new DebounceSubscriber(subscriber, this.durationSelector)); - }; - return DebounceOperator; -}()); -var DebounceSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](DebounceSubscriber, _super); - function DebounceSubscriber(destination, durationSelector) { - var _this = _super.call(this, destination) || this; - _this.durationSelector = durationSelector; - _this.hasValue = false; - _this.durationSubscription = null; - return _this; - } - DebounceSubscriber.prototype._next = function (value) { - try { - var result = this.durationSelector.call(this, value); - if (result) { - this._tryNext(value, result); - } - } - catch (err) { - this.destination.error(err); - } - }; - DebounceSubscriber.prototype._complete = function () { - this.emitValue(); - this.destination.complete(); - }; - DebounceSubscriber.prototype._tryNext = function (value, duration) { - var subscription = this.durationSubscription; - this.value = value; - this.hasValue = true; - if (subscription) { - subscription.unsubscribe(); - this.remove(subscription); - } - subscription = Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(this, duration); - if (subscription && !subscription.closed) { - this.add(this.durationSubscription = subscription); - } - }; - DebounceSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.emitValue(); - }; - DebounceSubscriber.prototype.notifyComplete = function () { - this.emitValue(); - }; - DebounceSubscriber.prototype.emitValue = function () { - if (this.hasValue) { - var value = this.value; - var subscription = this.durationSubscription; - if (subscription) { - this.durationSubscription = null; - subscription.unsubscribe(); - this.remove(subscription); - } - this.value = null; - this.hasValue = false; - _super.prototype._next.call(this, value); - } - }; - return DebounceSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=debounce.js.map - - -/***/ }), -/* 306 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = debounceTime; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__scheduler_async__ = __webpack_require__(12); -/** PURE_IMPORTS_START tslib,_Subscriber,_scheduler_async PURE_IMPORTS_END */ - - - -function debounceTime(dueTime, scheduler) { - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_2__scheduler_async__["a" /* async */]; - } - return function (source) { return source.lift(new DebounceTimeOperator(dueTime, scheduler)); }; -} -var DebounceTimeOperator = /*@__PURE__*/ (function () { - function DebounceTimeOperator(dueTime, scheduler) { - this.dueTime = dueTime; - this.scheduler = scheduler; - } - DebounceTimeOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new DebounceTimeSubscriber(subscriber, this.dueTime, this.scheduler)); - }; - return DebounceTimeOperator; -}()); -var DebounceTimeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](DebounceTimeSubscriber, _super); - function DebounceTimeSubscriber(destination, dueTime, scheduler) { - var _this = _super.call(this, destination) || this; - _this.dueTime = dueTime; - _this.scheduler = scheduler; - _this.debouncedSubscription = null; - _this.lastValue = null; - _this.hasValue = false; - return _this; - } - DebounceTimeSubscriber.prototype._next = function (value) { - this.clearDebounce(); - this.lastValue = value; - this.hasValue = true; - this.add(this.debouncedSubscription = this.scheduler.schedule(dispatchNext, this.dueTime, this)); - }; - DebounceTimeSubscriber.prototype._complete = function () { - this.debouncedNext(); - this.destination.complete(); - }; - DebounceTimeSubscriber.prototype.debouncedNext = function () { - this.clearDebounce(); - if (this.hasValue) { - var lastValue = this.lastValue; - this.lastValue = null; - this.hasValue = false; - this.destination.next(lastValue); - } - }; - DebounceTimeSubscriber.prototype.clearDebounce = function () { - var debouncedSubscription = this.debouncedSubscription; - if (debouncedSubscription !== null) { - this.remove(debouncedSubscription); - debouncedSubscription.unsubscribe(); - this.debouncedSubscription = null; - } - }; - return DebounceTimeSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -function dispatchNext(subscriber) { - subscriber.debouncedNext(); -} -//# sourceMappingURL=debounceTime.js.map - - -/***/ }), -/* 307 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = delay; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isDate__ = __webpack_require__(128); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__Notification__ = __webpack_require__(45); -/** PURE_IMPORTS_START tslib,_scheduler_async,_util_isDate,_Subscriber,_Notification PURE_IMPORTS_END */ - - - - - -function delay(delay, scheduler) { - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_1__scheduler_async__["a" /* async */]; - } - var absoluteDelay = Object(__WEBPACK_IMPORTED_MODULE_2__util_isDate__["a" /* isDate */])(delay); - var delayFor = absoluteDelay ? (+delay - scheduler.now()) : Math.abs(delay); - return function (source) { return source.lift(new DelayOperator(delayFor, scheduler)); }; -} -var DelayOperator = /*@__PURE__*/ (function () { - function DelayOperator(delay, scheduler) { - this.delay = delay; - this.scheduler = scheduler; - } - DelayOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new DelaySubscriber(subscriber, this.delay, this.scheduler)); - }; - return DelayOperator; -}()); -var DelaySubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](DelaySubscriber, _super); - function DelaySubscriber(destination, delay, scheduler) { - var _this = _super.call(this, destination) || this; - _this.delay = delay; - _this.scheduler = scheduler; - _this.queue = []; - _this.active = false; - _this.errored = false; - return _this; - } - DelaySubscriber.dispatch = function (state) { - var source = state.source; - var queue = source.queue; - var scheduler = state.scheduler; - var destination = state.destination; - while (queue.length > 0 && (queue[0].time - scheduler.now()) <= 0) { - queue.shift().notification.observe(destination); - } - if (queue.length > 0) { - var delay_1 = Math.max(0, queue[0].time - scheduler.now()); - this.schedule(state, delay_1); - } - else { - this.unsubscribe(); - source.active = false; - } - }; - DelaySubscriber.prototype._schedule = function (scheduler) { - this.active = true; - this.add(scheduler.schedule(DelaySubscriber.dispatch, this.delay, { - source: this, destination: this.destination, scheduler: scheduler - })); - }; - DelaySubscriber.prototype.scheduleNotification = function (notification) { - if (this.errored === true) { - return; - } - var scheduler = this.scheduler; - var message = new DelayMessage(scheduler.now() + this.delay, notification); - this.queue.push(message); - if (this.active === false) { - this._schedule(scheduler); - } - }; - DelaySubscriber.prototype._next = function (value) { - this.scheduleNotification(__WEBPACK_IMPORTED_MODULE_4__Notification__["a" /* Notification */].createNext(value)); - }; - DelaySubscriber.prototype._error = function (err) { - this.errored = true; - this.queue = []; - this.destination.error(err); - }; - DelaySubscriber.prototype._complete = function () { - this.scheduleNotification(__WEBPACK_IMPORTED_MODULE_4__Notification__["a" /* Notification */].createComplete()); - }; - return DelaySubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__Subscriber__["a" /* Subscriber */])); -var DelayMessage = /*@__PURE__*/ (function () { - function DelayMessage(time, notification) { - this.time = time; - this.notification = notification; - } - return DelayMessage; -}()); -//# sourceMappingURL=delay.js.map - - -/***/ }), -/* 308 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = delayWhen; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_Subscriber,_Observable,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - + this.count++; + } + }; + CountSubscriber.prototype._complete = function () { + this.destination.next(this.count); + this.destination.complete(); + }; + return CountSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=count.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/debounce.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function delayWhen(delayDurationSelector, subscriptionDelay) { - if (subscriptionDelay) { - return function (source) { - return new SubscriptionDelayObservable(source, subscriptionDelay) - .lift(new DelayWhenOperator(delayDurationSelector)); - }; - } - return function (source) { return source.lift(new DelayWhenOperator(delayDurationSelector)); }; +function debounce(durationSelector) { + return function (source) { return source.lift(new DebounceOperator(durationSelector)); }; } -var DelayWhenOperator = /*@__PURE__*/ (function () { - function DelayWhenOperator(delayDurationSelector) { - this.delayDurationSelector = delayDurationSelector; +var DebounceOperator = /*@__PURE__*/ (function () { + function DebounceOperator(durationSelector) { + this.durationSelector = durationSelector; } - DelayWhenOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new DelayWhenSubscriber(subscriber, this.delayDurationSelector)); + DebounceOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new debounce_DebounceSubscriber(subscriber, this.durationSelector)); }; - return DelayWhenOperator; + return DebounceOperator; }()); -var DelayWhenSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](DelayWhenSubscriber, _super); - function DelayWhenSubscriber(destination, delayDurationSelector) { +var debounce_DebounceSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](DebounceSubscriber, _super); + function DebounceSubscriber(destination, durationSelector) { var _this = _super.call(this, destination) || this; - _this.delayDurationSelector = delayDurationSelector; - _this.completed = false; - _this.delayNotifierSubscriptions = []; + _this.durationSelector = durationSelector; + _this.hasValue = false; + _this.durationSubscription = null; return _this; } - DelayWhenSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.destination.next(outerValue); - this.removeSubscription(innerSub); - this.tryComplete(); - }; - DelayWhenSubscriber.prototype.notifyError = function (error, innerSub) { - this._error(error); - }; - DelayWhenSubscriber.prototype.notifyComplete = function (innerSub) { - var value = this.removeSubscription(innerSub); - if (value) { - this.destination.next(value); - } - this.tryComplete(); - }; - DelayWhenSubscriber.prototype._next = function (value) { + DebounceSubscriber.prototype._next = function (value) { try { - var delayNotifier = this.delayDurationSelector(value); - if (delayNotifier) { - this.tryDelay(delayNotifier, value); + var result = this.durationSelector.call(this, value); + if (result) { + this._tryNext(value, result); } } catch (err) { this.destination.error(err); } }; - DelayWhenSubscriber.prototype._complete = function () { - this.completed = true; - this.tryComplete(); - }; - DelayWhenSubscriber.prototype.removeSubscription = function (subscription) { - subscription.unsubscribe(); - var subscriptionIdx = this.delayNotifierSubscriptions.indexOf(subscription); - if (subscriptionIdx !== -1) { - this.delayNotifierSubscriptions.splice(subscriptionIdx, 1); - } - return subscription.outerValue; + DebounceSubscriber.prototype._complete = function () { + this.emitValue(); + this.destination.complete(); }; - DelayWhenSubscriber.prototype.tryDelay = function (delayNotifier, value) { - var notifierSubscription = Object(__WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__["a" /* subscribeToResult */])(this, delayNotifier, value); - if (notifierSubscription && !notifierSubscription.closed) { - this.add(notifierSubscription); - this.delayNotifierSubscriptions.push(notifierSubscription); + DebounceSubscriber.prototype._tryNext = function (value, duration) { + var subscription = this.durationSubscription; + this.value = value; + this.hasValue = true; + if (subscription) { + subscription.unsubscribe(); + this.remove(subscription); } - }; - DelayWhenSubscriber.prototype.tryComplete = function () { - if (this.completed && this.delayNotifierSubscriptions.length === 0) { - this.destination.complete(); + subscription = Object(subscribeToResult["a" /* subscribeToResult */])(this, duration); + if (subscription && !subscription.closed) { + this.add(this.durationSubscription = subscription); } }; - return DelayWhenSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__["a" /* OuterSubscriber */])); -var SubscriptionDelayObservable = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SubscriptionDelayObservable, _super); - function SubscriptionDelayObservable(source, subscriptionDelay) { - var _this = _super.call(this) || this; - _this.source = source; - _this.subscriptionDelay = subscriptionDelay; - return _this; - } - SubscriptionDelayObservable.prototype._subscribe = function (subscriber) { - this.subscriptionDelay.subscribe(new SubscriptionDelaySubscriber(subscriber, this.source)); - }; - return SubscriptionDelayObservable; -}(__WEBPACK_IMPORTED_MODULE_2__Observable__["a" /* Observable */])); -var SubscriptionDelaySubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SubscriptionDelaySubscriber, _super); - function SubscriptionDelaySubscriber(parent, source) { - var _this = _super.call(this) || this; - _this.parent = parent; - _this.source = source; - _this.sourceSubscribed = false; - return _this; - } - SubscriptionDelaySubscriber.prototype._next = function (unused) { - this.subscribeToSource(); - }; - SubscriptionDelaySubscriber.prototype._error = function (err) { - this.unsubscribe(); - this.parent.error(err); + DebounceSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.emitValue(); }; - SubscriptionDelaySubscriber.prototype._complete = function () { - this.subscribeToSource(); + DebounceSubscriber.prototype.notifyComplete = function () { + this.emitValue(); }; - SubscriptionDelaySubscriber.prototype.subscribeToSource = function () { - if (!this.sourceSubscribed) { - this.sourceSubscribed = true; - this.unsubscribe(); - this.source.subscribe(this.parent); + DebounceSubscriber.prototype.emitValue = function () { + if (this.hasValue) { + var value = this.value; + var subscription = this.durationSubscription; + if (subscription) { + this.durationSubscription = null; + subscription.unsubscribe(); + this.remove(subscription); + } + this.value = null; + this.hasValue = false; + _super.prototype._next.call(this, value); } }; - return SubscriptionDelaySubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=delayWhen.js.map - + return DebounceSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=debounce.js.map -/***/ }), -/* 309 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/debounceTime.js +/** PURE_IMPORTS_START tslib,_Subscriber,_scheduler_async PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = dematerialize; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function dematerialize() { - return function dematerializeOperatorFunction(source) { - return source.lift(new DeMaterializeOperator()); - }; -} -var DeMaterializeOperator = /*@__PURE__*/ (function () { - function DeMaterializeOperator() { - } - DeMaterializeOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new DeMaterializeSubscriber(subscriber)); - }; - return DeMaterializeOperator; -}()); -var DeMaterializeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](DeMaterializeSubscriber, _super); - function DeMaterializeSubscriber(destination) { - return _super.call(this, destination) || this; +function debounceTime(dueTime, scheduler) { + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; } - DeMaterializeSubscriber.prototype._next = function (value) { - value.observe(this.destination); - }; - return DeMaterializeSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=dematerialize.js.map - - -/***/ }), -/* 310 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = distinct; -/* unused harmony export DistinctSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - - - -function distinct(keySelector, flushes) { - return function (source) { return source.lift(new DistinctOperator(keySelector, flushes)); }; + return function (source) { return source.lift(new DebounceTimeOperator(dueTime, scheduler)); }; } -var DistinctOperator = /*@__PURE__*/ (function () { - function DistinctOperator(keySelector, flushes) { - this.keySelector = keySelector; - this.flushes = flushes; +var DebounceTimeOperator = /*@__PURE__*/ (function () { + function DebounceTimeOperator(dueTime, scheduler) { + this.dueTime = dueTime; + this.scheduler = scheduler; } - DistinctOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new DistinctSubscriber(subscriber, this.keySelector, this.flushes)); + DebounceTimeOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new debounceTime_DebounceTimeSubscriber(subscriber, this.dueTime, this.scheduler)); }; - return DistinctOperator; + return DebounceTimeOperator; }()); -var DistinctSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](DistinctSubscriber, _super); - function DistinctSubscriber(destination, keySelector, flushes) { +var debounceTime_DebounceTimeSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](DebounceTimeSubscriber, _super); + function DebounceTimeSubscriber(destination, dueTime, scheduler) { var _this = _super.call(this, destination) || this; - _this.keySelector = keySelector; - _this.values = new Set(); - if (flushes) { - _this.add(Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(_this, flushes)); - } + _this.dueTime = dueTime; + _this.scheduler = scheduler; + _this.debouncedSubscription = null; + _this.lastValue = null; + _this.hasValue = false; return _this; } - DistinctSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.values.clear(); + DebounceTimeSubscriber.prototype._next = function (value) { + this.clearDebounce(); + this.lastValue = value; + this.hasValue = true; + this.add(this.debouncedSubscription = this.scheduler.schedule(dispatchNext, this.dueTime, this)); }; - DistinctSubscriber.prototype.notifyError = function (error, innerSub) { - this._error(error); + DebounceTimeSubscriber.prototype._complete = function () { + this.debouncedNext(); + this.destination.complete(); }; - DistinctSubscriber.prototype._next = function (value) { - if (this.keySelector) { - this._useKeySelector(value); + DebounceTimeSubscriber.prototype.debouncedNext = function () { + this.clearDebounce(); + if (this.hasValue) { + var lastValue = this.lastValue; + this.lastValue = null; + this.hasValue = false; + this.destination.next(lastValue); } - else { - this._finalizeNext(value, value); + }; + DebounceTimeSubscriber.prototype.clearDebounce = function () { + var debouncedSubscription = this.debouncedSubscription; + if (debouncedSubscription !== null) { + this.remove(debouncedSubscription); + debouncedSubscription.unsubscribe(); + this.debouncedSubscription = null; } }; - DistinctSubscriber.prototype._useKeySelector = function (value) { - var key; - var destination = this.destination; - try { - key = this.keySelector(value); - } - catch (err) { - destination.error(err); - return; - } - this._finalizeNext(key, value); + return DebounceTimeSubscriber; +}(Subscriber["a" /* Subscriber */])); +function dispatchNext(subscriber) { + subscriber.debouncedNext(); +} +//# sourceMappingURL=debounceTime.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/defaultIfEmpty.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ + + +function defaultIfEmpty(defaultValue) { + if (defaultValue === void 0) { + defaultValue = null; + } + return function (source) { return source.lift(new DefaultIfEmptyOperator(defaultValue)); }; +} +var DefaultIfEmptyOperator = /*@__PURE__*/ (function () { + function DefaultIfEmptyOperator(defaultValue) { + this.defaultValue = defaultValue; + } + DefaultIfEmptyOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new defaultIfEmpty_DefaultIfEmptySubscriber(subscriber, this.defaultValue)); + }; + return DefaultIfEmptyOperator; +}()); +var defaultIfEmpty_DefaultIfEmptySubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](DefaultIfEmptySubscriber, _super); + function DefaultIfEmptySubscriber(destination, defaultValue) { + var _this = _super.call(this, destination) || this; + _this.defaultValue = defaultValue; + _this.isEmpty = true; + return _this; + } + DefaultIfEmptySubscriber.prototype._next = function (value) { + this.isEmpty = false; + this.destination.next(value); }; - DistinctSubscriber.prototype._finalizeNext = function (key, value) { - var values = this.values; - if (!values.has(key)) { - values.add(key); - this.destination.next(value); + DefaultIfEmptySubscriber.prototype._complete = function () { + if (this.isEmpty) { + this.destination.next(this.defaultValue); } + this.destination.complete(); }; - return DistinctSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); - -//# sourceMappingURL=distinct.js.map - - -/***/ }), -/* 311 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = distinctUntilKeyChanged; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__distinctUntilChanged__ = __webpack_require__(129); -/** PURE_IMPORTS_START _distinctUntilChanged PURE_IMPORTS_END */ + return DefaultIfEmptySubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=defaultIfEmpty.js.map -function distinctUntilKeyChanged(key, compare) { - return Object(__WEBPACK_IMPORTED_MODULE_0__distinctUntilChanged__["a" /* distinctUntilChanged */])(function (x, y) { return compare ? compare(x[key], y[key]) : x[key] === y[key]; }); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isDate.js +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function isDate(value) { + return value instanceof Date && !isNaN(+value); } -//# sourceMappingURL=distinctUntilKeyChanged.js.map - +//# sourceMappingURL=isDate.js.map -/***/ }), -/* 312 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Notification.js +var Notification = __webpack_require__(22); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = elementAt; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_ArgumentOutOfRangeError__ = __webpack_require__(32); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__filter__ = __webpack_require__(37); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__throwIfEmpty__ = __webpack_require__(49); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__defaultIfEmpty__ = __webpack_require__(36); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__take__ = __webpack_require__(73); -/** PURE_IMPORTS_START _util_ArgumentOutOfRangeError,_filter,_throwIfEmpty,_defaultIfEmpty,_take PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/delay.js +/** PURE_IMPORTS_START tslib,_scheduler_async,_util_isDate,_Subscriber,_Notification PURE_IMPORTS_END */ -function elementAt(index, defaultValue) { - if (index < 0) { - throw new __WEBPACK_IMPORTED_MODULE_0__util_ArgumentOutOfRangeError__["a" /* ArgumentOutOfRangeError */](); +function delay_delay(delay, scheduler) { + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; } - var hasDefaultValue = arguments.length >= 2; - return function (source) { - return source.pipe(Object(__WEBPACK_IMPORTED_MODULE_1__filter__["a" /* filter */])(function (v, i) { return i === index; }), Object(__WEBPACK_IMPORTED_MODULE_4__take__["a" /* take */])(1), hasDefaultValue - ? Object(__WEBPACK_IMPORTED_MODULE_3__defaultIfEmpty__["a" /* defaultIfEmpty */])(defaultValue) - : Object(__WEBPACK_IMPORTED_MODULE_2__throwIfEmpty__["a" /* throwIfEmpty */])(function () { return new __WEBPACK_IMPORTED_MODULE_0__util_ArgumentOutOfRangeError__["a" /* ArgumentOutOfRangeError */](); })); - }; + var absoluteDelay = isDate(delay); + var delayFor = absoluteDelay ? (+delay - scheduler.now()) : Math.abs(delay); + return function (source) { return source.lift(new DelayOperator(delayFor, scheduler)); }; } -//# sourceMappingURL=elementAt.js.map - - -/***/ }), -/* 313 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = endWith; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_fromArray__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__observable_scalar__ = __webpack_require__(67); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__observable_empty__ = __webpack_require__(11); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__observable_concat__ = __webpack_require__(47); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_isScheduler__ = __webpack_require__(14); -/** PURE_IMPORTS_START _observable_fromArray,_observable_scalar,_observable_empty,_observable_concat,_util_isScheduler PURE_IMPORTS_END */ - - - - - -function endWith() { - var array = []; - for (var _i = 0; _i < arguments.length; _i++) { - array[_i] = arguments[_i]; +var DelayOperator = /*@__PURE__*/ (function () { + function DelayOperator(delay, scheduler) { + this.delay = delay; + this.scheduler = scheduler; } - return function (source) { - var scheduler = array[array.length - 1]; - if (Object(__WEBPACK_IMPORTED_MODULE_4__util_isScheduler__["a" /* isScheduler */])(scheduler)) { - array.pop(); + DelayOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new delay_DelaySubscriber(subscriber, this.delay, this.scheduler)); + }; + return DelayOperator; +}()); +var delay_DelaySubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](DelaySubscriber, _super); + function DelaySubscriber(destination, delay, scheduler) { + var _this = _super.call(this, destination) || this; + _this.delay = delay; + _this.scheduler = scheduler; + _this.queue = []; + _this.active = false; + _this.errored = false; + return _this; + } + DelaySubscriber.dispatch = function (state) { + var source = state.source; + var queue = source.queue; + var scheduler = state.scheduler; + var destination = state.destination; + while (queue.length > 0 && (queue[0].time - scheduler.now()) <= 0) { + queue.shift().notification.observe(destination); } - else { - scheduler = null; + if (queue.length > 0) { + var delay_1 = Math.max(0, queue[0].time - scheduler.now()); + this.schedule(state, delay_1); } - var len = array.length; - if (len === 1 && !scheduler) { - return Object(__WEBPACK_IMPORTED_MODULE_3__observable_concat__["a" /* concat */])(source, Object(__WEBPACK_IMPORTED_MODULE_1__observable_scalar__["a" /* scalar */])(array[0])); + else { + this.unsubscribe(); + source.active = false; } - else if (len > 0) { - return Object(__WEBPACK_IMPORTED_MODULE_3__observable_concat__["a" /* concat */])(source, Object(__WEBPACK_IMPORTED_MODULE_0__observable_fromArray__["a" /* fromArray */])(array, scheduler)); + }; + DelaySubscriber.prototype._schedule = function (scheduler) { + this.active = true; + this.add(scheduler.schedule(DelaySubscriber.dispatch, this.delay, { + source: this, destination: this.destination, scheduler: scheduler + })); + }; + DelaySubscriber.prototype.scheduleNotification = function (notification) { + if (this.errored === true) { + return; } - else { - return Object(__WEBPACK_IMPORTED_MODULE_3__observable_concat__["a" /* concat */])(source, Object(__WEBPACK_IMPORTED_MODULE_2__observable_empty__["b" /* empty */])(scheduler)); + var scheduler = this.scheduler; + var message = new DelayMessage(scheduler.now() + this.delay, notification); + this.queue.push(message); + if (this.active === false) { + this._schedule(scheduler); } }; -} -//# sourceMappingURL=endWith.js.map + DelaySubscriber.prototype._next = function (value) { + this.scheduleNotification(Notification["a" /* Notification */].createNext(value)); + }; + DelaySubscriber.prototype._error = function (err) { + this.errored = true; + this.queue = []; + this.destination.error(err); + }; + DelaySubscriber.prototype._complete = function () { + this.scheduleNotification(Notification["a" /* Notification */].createComplete()); + }; + return DelaySubscriber; +}(Subscriber["a" /* Subscriber */])); +var DelayMessage = /*@__PURE__*/ (function () { + function DelayMessage(time, notification) { + this.time = time; + this.notification = notification; + } + return DelayMessage; +}()); +//# sourceMappingURL=delay.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Observable.js + 1 modules +var Observable = __webpack_require__(2); -/***/ }), -/* 314 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/delayWhen.js +/** PURE_IMPORTS_START tslib,_Subscriber,_Observable,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = every; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function every(predicate, thisArg) { - return function (source) { return source.lift(new EveryOperator(predicate, thisArg, source)); }; + + +function delayWhen(delayDurationSelector, subscriptionDelay) { + if (subscriptionDelay) { + return function (source) { + return new delayWhen_SubscriptionDelayObservable(source, subscriptionDelay) + .lift(new DelayWhenOperator(delayDurationSelector)); + }; + } + return function (source) { return source.lift(new DelayWhenOperator(delayDurationSelector)); }; } -var EveryOperator = /*@__PURE__*/ (function () { - function EveryOperator(predicate, thisArg, source) { - this.predicate = predicate; - this.thisArg = thisArg; - this.source = source; +var DelayWhenOperator = /*@__PURE__*/ (function () { + function DelayWhenOperator(delayDurationSelector) { + this.delayDurationSelector = delayDurationSelector; } - EveryOperator.prototype.call = function (observer, source) { - return source.subscribe(new EverySubscriber(observer, this.predicate, this.thisArg, this.source)); + DelayWhenOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new delayWhen_DelayWhenSubscriber(subscriber, this.delayDurationSelector)); }; - return EveryOperator; + return DelayWhenOperator; }()); -var EverySubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](EverySubscriber, _super); - function EverySubscriber(destination, predicate, thisArg, source) { +var delayWhen_DelayWhenSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](DelayWhenSubscriber, _super); + function DelayWhenSubscriber(destination, delayDurationSelector) { var _this = _super.call(this, destination) || this; - _this.predicate = predicate; - _this.thisArg = thisArg; - _this.source = source; - _this.index = 0; - _this.thisArg = thisArg || _this; + _this.delayDurationSelector = delayDurationSelector; + _this.completed = false; + _this.delayNotifierSubscriptions = []; return _this; } - EverySubscriber.prototype.notifyComplete = function (everyValueMatch) { - this.destination.next(everyValueMatch); - this.destination.complete(); + DelayWhenSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.destination.next(outerValue); + this.removeSubscription(innerSub); + this.tryComplete(); }; - EverySubscriber.prototype._next = function (value) { - var result = false; + DelayWhenSubscriber.prototype.notifyError = function (error, innerSub) { + this._error(error); + }; + DelayWhenSubscriber.prototype.notifyComplete = function (innerSub) { + var value = this.removeSubscription(innerSub); + if (value) { + this.destination.next(value); + } + this.tryComplete(); + }; + DelayWhenSubscriber.prototype._next = function (value) { try { - result = this.predicate.call(this.thisArg, value, this.index++, this.source); + var delayNotifier = this.delayDurationSelector(value); + if (delayNotifier) { + this.tryDelay(delayNotifier, value); + } } catch (err) { this.destination.error(err); - return; } - if (!result) { - this.notifyComplete(false); + }; + DelayWhenSubscriber.prototype._complete = function () { + this.completed = true; + this.tryComplete(); + }; + DelayWhenSubscriber.prototype.removeSubscription = function (subscription) { + subscription.unsubscribe(); + var subscriptionIdx = this.delayNotifierSubscriptions.indexOf(subscription); + if (subscriptionIdx !== -1) { + this.delayNotifierSubscriptions.splice(subscriptionIdx, 1); } + return subscription.outerValue; }; - EverySubscriber.prototype._complete = function () { - this.notifyComplete(true); + DelayWhenSubscriber.prototype.tryDelay = function (delayNotifier, value) { + var notifierSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(this, delayNotifier, value); + if (notifierSubscription && !notifierSubscription.closed) { + this.add(notifierSubscription); + this.delayNotifierSubscriptions.push(notifierSubscription); + } }; - return EverySubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=every.js.map - - -/***/ }), -/* 315 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = exhaust; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - - - -function exhaust() { - return function (source) { return source.lift(new SwitchFirstOperator()); }; -} -var SwitchFirstOperator = /*@__PURE__*/ (function () { - function SwitchFirstOperator() { + DelayWhenSubscriber.prototype.tryComplete = function () { + if (this.completed && this.delayNotifierSubscriptions.length === 0) { + this.destination.complete(); + } + }; + return DelayWhenSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +var delayWhen_SubscriptionDelayObservable = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SubscriptionDelayObservable, _super); + function SubscriptionDelayObservable(source, subscriptionDelay) { + var _this = _super.call(this) || this; + _this.source = source; + _this.subscriptionDelay = subscriptionDelay; + return _this; } - SwitchFirstOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new SwitchFirstSubscriber(subscriber)); + SubscriptionDelayObservable.prototype._subscribe = function (subscriber) { + this.subscriptionDelay.subscribe(new delayWhen_SubscriptionDelaySubscriber(subscriber, this.source)); }; - return SwitchFirstOperator; -}()); -var SwitchFirstSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SwitchFirstSubscriber, _super); - function SwitchFirstSubscriber(destination) { - var _this = _super.call(this, destination) || this; - _this.hasCompleted = false; - _this.hasSubscription = false; + return SubscriptionDelayObservable; +}(Observable["a" /* Observable */])); +var delayWhen_SubscriptionDelaySubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SubscriptionDelaySubscriber, _super); + function SubscriptionDelaySubscriber(parent, source) { + var _this = _super.call(this) || this; + _this.parent = parent; + _this.source = source; + _this.sourceSubscribed = false; return _this; } - SwitchFirstSubscriber.prototype._next = function (value) { - if (!this.hasSubscription) { - this.hasSubscription = true; - this.add(Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(this, value)); - } + SubscriptionDelaySubscriber.prototype._next = function (unused) { + this.subscribeToSource(); }; - SwitchFirstSubscriber.prototype._complete = function () { - this.hasCompleted = true; - if (!this.hasSubscription) { - this.destination.complete(); - } + SubscriptionDelaySubscriber.prototype._error = function (err) { + this.unsubscribe(); + this.parent.error(err); }; - SwitchFirstSubscriber.prototype.notifyComplete = function (innerSub) { - this.remove(innerSub); - this.hasSubscription = false; - if (this.hasCompleted) { - this.destination.complete(); + SubscriptionDelaySubscriber.prototype._complete = function () { + this.subscribeToSource(); + }; + SubscriptionDelaySubscriber.prototype.subscribeToSource = function () { + if (!this.sourceSubscribed) { + this.sourceSubscribed = true; + this.unsubscribe(); + this.source.subscribe(this.parent); } }; - return SwitchFirstSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=exhaust.js.map - + return SubscriptionDelaySubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=delayWhen.js.map -/***/ }), -/* 316 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/dematerialize.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = exhaustMap; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__map__ = __webpack_require__(15); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__observable_from__ = __webpack_require__(18); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult,_map,_observable_from PURE_IMPORTS_END */ +function dematerialize() { + return function dematerializeOperatorFunction(source) { + return source.lift(new DeMaterializeOperator()); + }; +} +var DeMaterializeOperator = /*@__PURE__*/ (function () { + function DeMaterializeOperator() { + } + DeMaterializeOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new dematerialize_DeMaterializeSubscriber(subscriber)); + }; + return DeMaterializeOperator; +}()); +var dematerialize_DeMaterializeSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](DeMaterializeSubscriber, _super); + function DeMaterializeSubscriber(destination) { + return _super.call(this, destination) || this; + } + DeMaterializeSubscriber.prototype._next = function (value) { + value.observe(this.destination); + }; + return DeMaterializeSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=dematerialize.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/distinct.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function exhaustMap(project, resultSelector) { - if (resultSelector) { - return function (source) { return source.pipe(exhaustMap(function (a, i) { return Object(__WEBPACK_IMPORTED_MODULE_4__observable_from__["a" /* from */])(project(a, i)).pipe(Object(__WEBPACK_IMPORTED_MODULE_3__map__["a" /* map */])(function (b, ii) { return resultSelector(a, b, i, ii); })); })); }; - } - return function (source) { - return source.lift(new ExhauseMapOperator(project)); - }; +function distinct(keySelector, flushes) { + return function (source) { return source.lift(new DistinctOperator(keySelector, flushes)); }; } -var ExhauseMapOperator = /*@__PURE__*/ (function () { - function ExhauseMapOperator(project) { - this.project = project; +var DistinctOperator = /*@__PURE__*/ (function () { + function DistinctOperator(keySelector, flushes) { + this.keySelector = keySelector; + this.flushes = flushes; } - ExhauseMapOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new ExhaustMapSubscriber(subscriber, this.project)); + DistinctOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new distinct_DistinctSubscriber(subscriber, this.keySelector, this.flushes)); }; - return ExhauseMapOperator; + return DistinctOperator; }()); -var ExhaustMapSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ExhaustMapSubscriber, _super); - function ExhaustMapSubscriber(destination, project) { +var distinct_DistinctSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](DistinctSubscriber, _super); + function DistinctSubscriber(destination, keySelector, flushes) { var _this = _super.call(this, destination) || this; - _this.project = project; - _this.hasSubscription = false; - _this.hasCompleted = false; - _this.index = 0; + _this.keySelector = keySelector; + _this.values = new Set(); + if (flushes) { + _this.add(Object(subscribeToResult["a" /* subscribeToResult */])(_this, flushes)); + } return _this; } - ExhaustMapSubscriber.prototype._next = function (value) { - if (!this.hasSubscription) { - this.tryNext(value); + DistinctSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.values.clear(); + }; + DistinctSubscriber.prototype.notifyError = function (error, innerSub) { + this._error(error); + }; + DistinctSubscriber.prototype._next = function (value) { + if (this.keySelector) { + this._useKeySelector(value); + } + else { + this._finalizeNext(value, value); } }; - ExhaustMapSubscriber.prototype.tryNext = function (value) { - var index = this.index++; + DistinctSubscriber.prototype._useKeySelector = function (value) { + var key; var destination = this.destination; try { - var result = this.project(value, index); - this.hasSubscription = true; - this.add(Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(this, result, value, index)); + key = this.keySelector(value); } catch (err) { destination.error(err); + return; } + this._finalizeNext(key, value); }; - ExhaustMapSubscriber.prototype._complete = function () { - this.hasCompleted = true; - if (!this.hasSubscription) { - this.destination.complete(); - } - }; - ExhaustMapSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.destination.next(innerValue); - }; - ExhaustMapSubscriber.prototype.notifyError = function (err) { - this.destination.error(err); - }; - ExhaustMapSubscriber.prototype.notifyComplete = function (innerSub) { - this.remove(innerSub); - this.hasSubscription = false; - if (this.hasCompleted) { - this.destination.complete(); + DistinctSubscriber.prototype._finalizeNext = function (key, value) { + var values = this.values; + if (!values.has(key)) { + values.add(key); + this.destination.next(value); } }; - return ExhaustMapSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=exhaustMap.js.map - - -/***/ }), -/* 317 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + return DistinctSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = expand; -/* unused harmony export ExpandOperator */ -/* unused harmony export ExpandSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +//# sourceMappingURL=distinct.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/distinctUntilChanged.js +/** PURE_IMPORTS_START tslib,_Subscriber,_util_tryCatch,_util_errorObject PURE_IMPORTS_END */ -function expand(project, concurrent, scheduler) { - if (concurrent === void 0) { - concurrent = Number.POSITIVE_INFINITY; - } - if (scheduler === void 0) { - scheduler = undefined; - } - concurrent = (concurrent || 0) < 1 ? Number.POSITIVE_INFINITY : concurrent; - return function (source) { return source.lift(new ExpandOperator(project, concurrent, scheduler)); }; +function distinctUntilChanged(compare, keySelector) { + return function (source) { return source.lift(new DistinctUntilChangedOperator(compare, keySelector)); }; } -var ExpandOperator = /*@__PURE__*/ (function () { - function ExpandOperator(project, concurrent, scheduler) { - this.project = project; - this.concurrent = concurrent; - this.scheduler = scheduler; +var DistinctUntilChangedOperator = /*@__PURE__*/ (function () { + function DistinctUntilChangedOperator(compare, keySelector) { + this.compare = compare; + this.keySelector = keySelector; } - ExpandOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new ExpandSubscriber(subscriber, this.project, this.concurrent, this.scheduler)); + DistinctUntilChangedOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new distinctUntilChanged_DistinctUntilChangedSubscriber(subscriber, this.compare, this.keySelector)); }; - return ExpandOperator; + return DistinctUntilChangedOperator; }()); - -var ExpandSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ExpandSubscriber, _super); - function ExpandSubscriber(destination, project, concurrent, scheduler) { +var distinctUntilChanged_DistinctUntilChangedSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](DistinctUntilChangedSubscriber, _super); + function DistinctUntilChangedSubscriber(destination, compare, keySelector) { var _this = _super.call(this, destination) || this; - _this.project = project; - _this.concurrent = concurrent; - _this.scheduler = scheduler; - _this.index = 0; - _this.active = 0; - _this.hasCompleted = false; - if (concurrent < Number.POSITIVE_INFINITY) { - _this.buffer = []; + _this.keySelector = keySelector; + _this.hasKey = false; + if (typeof compare === 'function') { + _this.compare = compare; } return _this; } - ExpandSubscriber.dispatch = function (arg) { - var subscriber = arg.subscriber, result = arg.result, value = arg.value, index = arg.index; - subscriber.subscribeToProjection(result, value, index); - }; - ExpandSubscriber.prototype._next = function (value) { - var destination = this.destination; - if (destination.closed) { - this._complete(); - return; - } - var index = this.index++; - if (this.active < this.concurrent) { - destination.next(value); - var result = Object(__WEBPACK_IMPORTED_MODULE_1__util_tryCatch__["a" /* tryCatch */])(this.project)(value, index); - if (result === __WEBPACK_IMPORTED_MODULE_2__util_errorObject__["a" /* errorObject */]) { - destination.error(__WEBPACK_IMPORTED_MODULE_2__util_errorObject__["a" /* errorObject */].e); - } - else if (!this.scheduler) { - this.subscribeToProjection(result, value, index); - } - else { - var state = { subscriber: this, result: result, value: value, index: index }; - this.add(this.scheduler.schedule(ExpandSubscriber.dispatch, 0, state)); - } - } - else { - this.buffer.push(value); - } - }; - ExpandSubscriber.prototype.subscribeToProjection = function (result, value, index) { - this.active++; - this.add(Object(__WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__["a" /* subscribeToResult */])(this, result, value, index)); - }; - ExpandSubscriber.prototype._complete = function () { - this.hasCompleted = true; - if (this.hasCompleted && this.active === 0) { - this.destination.complete(); - } - }; - ExpandSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this._next(innerValue); + DistinctUntilChangedSubscriber.prototype.compare = function (x, y) { + return x === y; }; - ExpandSubscriber.prototype.notifyComplete = function (innerSub) { - var buffer = this.buffer; - this.remove(innerSub); - this.active--; - if (buffer && buffer.length > 0) { - this._next(buffer.shift()); + DistinctUntilChangedSubscriber.prototype._next = function (value) { + var keySelector = this.keySelector; + var key = value; + if (keySelector) { + key = Object(tryCatch["a" /* tryCatch */])(this.keySelector)(value); + if (key === errorObject["a" /* errorObject */]) { + return this.destination.error(errorObject["a" /* errorObject */].e); + } } - if (this.hasCompleted && this.active === 0) { - this.destination.complete(); + var result = false; + if (this.hasKey) { + result = Object(tryCatch["a" /* tryCatch */])(this.compare)(this.key, key); + if (result === errorObject["a" /* errorObject */]) { + return this.destination.error(errorObject["a" /* errorObject */].e); + } + } + else { + this.hasKey = true; + } + if (Boolean(result) === false) { + this.key = key; + this.destination.next(value); } }; - return ExpandSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__["a" /* OuterSubscriber */])); - -//# sourceMappingURL=expand.js.map + return DistinctUntilChangedSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=distinctUntilChanged.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/distinctUntilKeyChanged.js +/** PURE_IMPORTS_START _distinctUntilChanged PURE_IMPORTS_END */ -/***/ }), -/* 318 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +function distinctUntilKeyChanged(key, compare) { + return distinctUntilChanged(function (x, y) { return compare ? compare(x[key], y[key]) : x[key] === y[key]; }); +} +//# sourceMappingURL=distinctUntilKeyChanged.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = finalize; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Subscription__ = __webpack_require__(7); -/** PURE_IMPORTS_START tslib,_Subscriber,_Subscription PURE_IMPORTS_END */ +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/ArgumentOutOfRangeError.js +var ArgumentOutOfRangeError = __webpack_require__(28); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/filter.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function finalize(callback) { - return function (source) { return source.lift(new FinallyOperator(callback)); }; +function filter(predicate, thisArg) { + return function filterOperatorFunction(source) { + return source.lift(new FilterOperator(predicate, thisArg)); + }; } -var FinallyOperator = /*@__PURE__*/ (function () { - function FinallyOperator(callback) { - this.callback = callback; +var FilterOperator = /*@__PURE__*/ (function () { + function FilterOperator(predicate, thisArg) { + this.predicate = predicate; + this.thisArg = thisArg; } - FinallyOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new FinallySubscriber(subscriber, this.callback)); + FilterOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new filter_FilterSubscriber(subscriber, this.predicate, this.thisArg)); }; - return FinallyOperator; + return FilterOperator; }()); -var FinallySubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](FinallySubscriber, _super); - function FinallySubscriber(destination, callback) { +var filter_FilterSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](FilterSubscriber, _super); + function FilterSubscriber(destination, predicate, thisArg) { var _this = _super.call(this, destination) || this; - _this.add(new __WEBPACK_IMPORTED_MODULE_2__Subscription__["a" /* Subscription */](callback)); + _this.predicate = predicate; + _this.thisArg = thisArg; + _this.count = 0; return _this; } - return FinallySubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=finalize.js.map - - -/***/ }), -/* 319 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + FilterSubscriber.prototype._next = function (value) { + var result; + try { + result = this.predicate.call(this.thisArg, value, this.count++); + } + catch (err) { + this.destination.error(err); + return; + } + if (result) { + this.destination.next(value); + } + }; + return FilterSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=filter.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = findIndex; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__operators_find__ = __webpack_require__(131); -/** PURE_IMPORTS_START _operators_find PURE_IMPORTS_END */ +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/noop.js +var noop = __webpack_require__(20); -function findIndex(predicate, thisArg) { - return function (source) { return source.lift(new __WEBPACK_IMPORTED_MODULE_0__operators_find__["a" /* FindValueOperator */](predicate, source, true, thisArg)); }; -} -//# sourceMappingURL=findIndex.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isFunction.js +var isFunction = __webpack_require__(29); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/tap.js +/** PURE_IMPORTS_START tslib,_Subscriber,_util_noop,_util_isFunction PURE_IMPORTS_END */ -/***/ }), -/* 320 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = first; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_EmptyError__ = __webpack_require__(33); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__filter__ = __webpack_require__(37); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__take__ = __webpack_require__(73); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__defaultIfEmpty__ = __webpack_require__(36); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__throwIfEmpty__ = __webpack_require__(49); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_identity__ = __webpack_require__(25); -/** PURE_IMPORTS_START _util_EmptyError,_filter,_take,_defaultIfEmpty,_throwIfEmpty,_util_identity PURE_IMPORTS_END */ +function tap(nextOrObserver, error, complete) { + return function tapOperatorFunction(source) { + return source.lift(new DoOperator(nextOrObserver, error, complete)); + }; +} +var DoOperator = /*@__PURE__*/ (function () { + function DoOperator(nextOrObserver, error, complete) { + this.nextOrObserver = nextOrObserver; + this.error = error; + this.complete = complete; + } + DoOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new tap_TapSubscriber(subscriber, this.nextOrObserver, this.error, this.complete)); + }; + return DoOperator; +}()); +var tap_TapSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](TapSubscriber, _super); + function TapSubscriber(destination, observerOrNext, error, complete) { + var _this = _super.call(this, destination) || this; + _this._tapNext = noop["a" /* noop */]; + _this._tapError = noop["a" /* noop */]; + _this._tapComplete = noop["a" /* noop */]; + _this._tapError = error || noop["a" /* noop */]; + _this._tapComplete = complete || noop["a" /* noop */]; + if (Object(isFunction["a" /* isFunction */])(observerOrNext)) { + _this._context = _this; + _this._tapNext = observerOrNext; + } + else if (observerOrNext) { + _this._context = observerOrNext; + _this._tapNext = observerOrNext.next || noop["a" /* noop */]; + _this._tapError = observerOrNext.error || noop["a" /* noop */]; + _this._tapComplete = observerOrNext.complete || noop["a" /* noop */]; + } + return _this; + } + TapSubscriber.prototype._next = function (value) { + try { + this._tapNext.call(this._context, value); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(value); + }; + TapSubscriber.prototype._error = function (err) { + try { + this._tapError.call(this._context, err); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.error(err); + }; + TapSubscriber.prototype._complete = function () { + try { + this._tapComplete.call(this._context); + } + catch (err) { + this.destination.error(err); + return; + } + return this.destination.complete(); + }; + return TapSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=tap.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/EmptyError.js +var EmptyError = __webpack_require__(31); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/throwIfEmpty.js +/** PURE_IMPORTS_START _tap,_util_EmptyError PURE_IMPORTS_END */ -function first(predicate, defaultValue) { - var hasDefaultValue = arguments.length >= 2; - return function (source) { return source.pipe(predicate ? Object(__WEBPACK_IMPORTED_MODULE_1__filter__["a" /* filter */])(function (v, i) { return predicate(v, i, source); }) : __WEBPACK_IMPORTED_MODULE_5__util_identity__["a" /* identity */], Object(__WEBPACK_IMPORTED_MODULE_2__take__["a" /* take */])(1), hasDefaultValue ? Object(__WEBPACK_IMPORTED_MODULE_3__defaultIfEmpty__["a" /* defaultIfEmpty */])(defaultValue) : Object(__WEBPACK_IMPORTED_MODULE_4__throwIfEmpty__["a" /* throwIfEmpty */])(function () { return new __WEBPACK_IMPORTED_MODULE_0__util_EmptyError__["a" /* EmptyError */](); })); }; +var throwIfEmpty = function (errorFactory) { + if (errorFactory === void 0) { + errorFactory = defaultErrorFactory; + } + return tap({ + hasValue: false, + next: function () { this.hasValue = true; }, + complete: function () { + if (!this.hasValue) { + throw errorFactory(); + } + } + }); +}; +function defaultErrorFactory() { + return new EmptyError["a" /* EmptyError */](); } -//# sourceMappingURL=first.js.map +//# sourceMappingURL=throwIfEmpty.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/empty.js +var empty = __webpack_require__(9); -/***/ }), -/* 321 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/take.js +/** PURE_IMPORTS_START tslib,_Subscriber,_util_ArgumentOutOfRangeError,_observable_empty PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = ignoreElements; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function ignoreElements() { - return function ignoreElementsOperatorFunction(source) { - return source.lift(new IgnoreElementsOperator()); + +function take(count) { + return function (source) { + if (count === 0) { + return Object(empty["b" /* empty */])(); + } + else { + return source.lift(new take_TakeOperator(count)); + } }; } -var IgnoreElementsOperator = /*@__PURE__*/ (function () { - function IgnoreElementsOperator() { +var take_TakeOperator = /*@__PURE__*/ (function () { + function TakeOperator(total) { + this.total = total; + if (this.total < 0) { + throw new ArgumentOutOfRangeError["a" /* ArgumentOutOfRangeError */]; + } } - IgnoreElementsOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new IgnoreElementsSubscriber(subscriber)); + TakeOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new take_TakeSubscriber(subscriber, this.total)); }; - return IgnoreElementsOperator; + return TakeOperator; }()); -var IgnoreElementsSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](IgnoreElementsSubscriber, _super); - function IgnoreElementsSubscriber() { - return _super !== null && _super.apply(this, arguments) || this; +var take_TakeSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](TakeSubscriber, _super); + function TakeSubscriber(destination, total) { + var _this = _super.call(this, destination) || this; + _this.total = total; + _this.count = 0; + return _this; } - IgnoreElementsSubscriber.prototype._next = function (unused) { + TakeSubscriber.prototype._next = function (value) { + var total = this.total; + var count = ++this.count; + if (count <= total) { + this.destination.next(value); + if (count === total) { + this.destination.complete(); + this.unsubscribe(); + } + } }; - return IgnoreElementsSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=ignoreElements.js.map + return TakeSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=take.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/elementAt.js +/** PURE_IMPORTS_START _util_ArgumentOutOfRangeError,_filter,_throwIfEmpty,_defaultIfEmpty,_take PURE_IMPORTS_END */ -/***/ }), -/* 322 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = isEmpty; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function isEmpty() { - return function (source) { return source.lift(new IsEmptyOperator()); }; -} -var IsEmptyOperator = /*@__PURE__*/ (function () { - function IsEmptyOperator() { - } - IsEmptyOperator.prototype.call = function (observer, source) { - return source.subscribe(new IsEmptySubscriber(observer)); - }; - return IsEmptyOperator; -}()); -var IsEmptySubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](IsEmptySubscriber, _super); - function IsEmptySubscriber(destination) { - return _super.call(this, destination) || this; + +function elementAt(index, defaultValue) { + if (index < 0) { + throw new ArgumentOutOfRangeError["a" /* ArgumentOutOfRangeError */](); } - IsEmptySubscriber.prototype.notifyComplete = function (isEmpty) { - var destination = this.destination; - destination.next(isEmpty); - destination.complete(); - }; - IsEmptySubscriber.prototype._next = function (value) { - this.notifyComplete(false); - }; - IsEmptySubscriber.prototype._complete = function () { - this.notifyComplete(true); + var hasDefaultValue = arguments.length >= 2; + return function (source) { + return source.pipe(filter(function (v, i) { return i === index; }), take(1), hasDefaultValue + ? defaultIfEmpty(defaultValue) + : throwIfEmpty(function () { return new ArgumentOutOfRangeError["a" /* ArgumentOutOfRangeError */](); })); }; - return IsEmptySubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=isEmpty.js.map - +} +//# sourceMappingURL=elementAt.js.map -/***/ }), -/* 323 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/fromArray.js +var fromArray = __webpack_require__(17); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = last; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_EmptyError__ = __webpack_require__(33); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__filter__ = __webpack_require__(37); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__takeLast__ = __webpack_require__(74); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__throwIfEmpty__ = __webpack_require__(49); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__defaultIfEmpty__ = __webpack_require__(36); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_identity__ = __webpack_require__(25); -/** PURE_IMPORTS_START _util_EmptyError,_filter,_takeLast,_throwIfEmpty,_defaultIfEmpty,_util_identity PURE_IMPORTS_END */ +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/scalar.js +var scalar = __webpack_require__(53); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/endWith.js +/** PURE_IMPORTS_START _observable_fromArray,_observable_scalar,_observable_empty,_observable_concat,_util_isScheduler PURE_IMPORTS_END */ -function last(predicate, defaultValue) { - var hasDefaultValue = arguments.length >= 2; - return function (source) { return source.pipe(predicate ? Object(__WEBPACK_IMPORTED_MODULE_1__filter__["a" /* filter */])(function (v, i) { return predicate(v, i, source); }) : __WEBPACK_IMPORTED_MODULE_5__util_identity__["a" /* identity */], Object(__WEBPACK_IMPORTED_MODULE_2__takeLast__["a" /* takeLast */])(1), hasDefaultValue ? Object(__WEBPACK_IMPORTED_MODULE_4__defaultIfEmpty__["a" /* defaultIfEmpty */])(defaultValue) : Object(__WEBPACK_IMPORTED_MODULE_3__throwIfEmpty__["a" /* throwIfEmpty */])(function () { return new __WEBPACK_IMPORTED_MODULE_0__util_EmptyError__["a" /* EmptyError */](); })); }; +function endWith() { + var array = []; + for (var _i = 0; _i < arguments.length; _i++) { + array[_i] = arguments[_i]; + } + return function (source) { + var scheduler = array[array.length - 1]; + if (Object(isScheduler["a" /* isScheduler */])(scheduler)) { + array.pop(); + } + else { + scheduler = null; + } + var len = array.length; + if (len === 1 && !scheduler) { + return Object(concat["a" /* concat */])(source, Object(scalar["a" /* scalar */])(array[0])); + } + else if (len > 0) { + return Object(concat["a" /* concat */])(source, Object(fromArray["a" /* fromArray */])(array, scheduler)); + } + else { + return Object(concat["a" /* concat */])(source, Object(empty["b" /* empty */])(scheduler)); + } + }; } -//# sourceMappingURL=last.js.map - - -/***/ }), -/* 324 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +//# sourceMappingURL=endWith.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = mapTo; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/every.js /** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function mapTo(value) { - return function (source) { return source.lift(new MapToOperator(value)); }; +function every(predicate, thisArg) { + return function (source) { return source.lift(new EveryOperator(predicate, thisArg, source)); }; } -var MapToOperator = /*@__PURE__*/ (function () { - function MapToOperator(value) { - this.value = value; +var EveryOperator = /*@__PURE__*/ (function () { + function EveryOperator(predicate, thisArg, source) { + this.predicate = predicate; + this.thisArg = thisArg; + this.source = source; } - MapToOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new MapToSubscriber(subscriber, this.value)); + EveryOperator.prototype.call = function (observer, source) { + return source.subscribe(new every_EverySubscriber(observer, this.predicate, this.thisArg, this.source)); }; - return MapToOperator; + return EveryOperator; }()); -var MapToSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](MapToSubscriber, _super); - function MapToSubscriber(destination, value) { +var every_EverySubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](EverySubscriber, _super); + function EverySubscriber(destination, predicate, thisArg, source) { var _this = _super.call(this, destination) || this; - _this.value = value; + _this.predicate = predicate; + _this.thisArg = thisArg; + _this.source = source; + _this.index = 0; + _this.thisArg = thisArg || _this; return _this; } - MapToSubscriber.prototype._next = function (x) { - this.destination.next(this.value); + EverySubscriber.prototype.notifyComplete = function (everyValueMatch) { + this.destination.next(everyValueMatch); + this.destination.complete(); }; - return MapToSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=mapTo.js.map - - -/***/ }), -/* 325 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + EverySubscriber.prototype._next = function (value) { + var result = false; + try { + result = this.predicate.call(this.thisArg, value, this.index++, this.source); + } + catch (err) { + this.destination.error(err); + return; + } + if (!result) { + this.notifyComplete(false); + } + }; + EverySubscriber.prototype._complete = function () { + this.notifyComplete(true); + }; + return EverySubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=every.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = materialize; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Notification__ = __webpack_require__(45); -/** PURE_IMPORTS_START tslib,_Subscriber,_Notification PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/exhaust.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function materialize() { - return function materializeOperatorFunction(source) { - return source.lift(new MaterializeOperator()); - }; +function exhaust() { + return function (source) { return source.lift(new SwitchFirstOperator()); }; } -var MaterializeOperator = /*@__PURE__*/ (function () { - function MaterializeOperator() { +var SwitchFirstOperator = /*@__PURE__*/ (function () { + function SwitchFirstOperator() { } - MaterializeOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new MaterializeSubscriber(subscriber)); + SwitchFirstOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new exhaust_SwitchFirstSubscriber(subscriber)); }; - return MaterializeOperator; + return SwitchFirstOperator; }()); -var MaterializeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](MaterializeSubscriber, _super); - function MaterializeSubscriber(destination) { - return _super.call(this, destination) || this; +var exhaust_SwitchFirstSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SwitchFirstSubscriber, _super); + function SwitchFirstSubscriber(destination) { + var _this = _super.call(this, destination) || this; + _this.hasCompleted = false; + _this.hasSubscription = false; + return _this; } - MaterializeSubscriber.prototype._next = function (value) { - this.destination.next(__WEBPACK_IMPORTED_MODULE_2__Notification__["a" /* Notification */].createNext(value)); + SwitchFirstSubscriber.prototype._next = function (value) { + if (!this.hasSubscription) { + this.hasSubscription = true; + this.add(Object(subscribeToResult["a" /* subscribeToResult */])(this, value)); + } }; - MaterializeSubscriber.prototype._error = function (err) { - var destination = this.destination; - destination.next(__WEBPACK_IMPORTED_MODULE_2__Notification__["a" /* Notification */].createError(err)); - destination.complete(); + SwitchFirstSubscriber.prototype._complete = function () { + this.hasCompleted = true; + if (!this.hasSubscription) { + this.destination.complete(); + } }; - MaterializeSubscriber.prototype._complete = function () { - var destination = this.destination; - destination.next(__WEBPACK_IMPORTED_MODULE_2__Notification__["a" /* Notification */].createComplete()); - destination.complete(); + SwitchFirstSubscriber.prototype.notifyComplete = function (innerSub) { + this.remove(innerSub); + this.hasSubscription = false; + if (this.hasCompleted) { + this.destination.complete(); + } }; - return MaterializeSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=materialize.js.map - + return SwitchFirstSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=exhaust.js.map -/***/ }), -/* 326 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/map.js +var map = __webpack_require__(13); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = max; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__reduce__ = __webpack_require__(50); -/** PURE_IMPORTS_START _reduce PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/exhaustMap.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult,_map,_observable_from PURE_IMPORTS_END */ -function max(comparer) { - var max = (typeof comparer === 'function') - ? function (x, y) { return comparer(x, y) > 0 ? x : y; } - : function (x, y) { return x > y ? x : y; }; - return Object(__WEBPACK_IMPORTED_MODULE_0__reduce__["a" /* reduce */])(max); -} -//# sourceMappingURL=max.js.map -/***/ }), -/* 327 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = merge; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_merge__ = __webpack_require__(122); -/** PURE_IMPORTS_START _observable_merge PURE_IMPORTS_END */ -function merge() { - var observables = []; - for (var _i = 0; _i < arguments.length; _i++) { - observables[_i] = arguments[_i]; +function exhaustMap(project, resultSelector) { + if (resultSelector) { + return function (source) { return source.pipe(exhaustMap(function (a, i) { return Object(from["a" /* from */])(project(a, i)).pipe(Object(map["a" /* map */])(function (b, ii) { return resultSelector(a, b, i, ii); })); })); }; } - return function (source) { return source.lift.call(__WEBPACK_IMPORTED_MODULE_0__observable_merge__["a" /* merge */].apply(void 0, [source].concat(observables))); }; + return function (source) { + return source.lift(new ExhauseMapOperator(project)); + }; } -//# sourceMappingURL=merge.js.map - - -/***/ }), -/* 328 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = mergeMapTo; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__mergeMap__ = __webpack_require__(35); -/** PURE_IMPORTS_START _mergeMap PURE_IMPORTS_END */ - -function mergeMapTo(innerObservable, resultSelector, concurrent) { - if (concurrent === void 0) { - concurrent = Number.POSITIVE_INFINITY; - } - if (typeof resultSelector === 'function') { - return Object(__WEBPACK_IMPORTED_MODULE_0__mergeMap__["a" /* mergeMap */])(function () { return innerObservable; }, resultSelector, concurrent); +var ExhauseMapOperator = /*@__PURE__*/ (function () { + function ExhauseMapOperator(project) { + this.project = project; } - if (typeof resultSelector === 'number') { - concurrent = resultSelector; + ExhauseMapOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new exhaustMap_ExhaustMapSubscriber(subscriber, this.project)); + }; + return ExhauseMapOperator; +}()); +var exhaustMap_ExhaustMapSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](ExhaustMapSubscriber, _super); + function ExhaustMapSubscriber(destination, project) { + var _this = _super.call(this, destination) || this; + _this.project = project; + _this.hasSubscription = false; + _this.hasCompleted = false; + _this.index = 0; + return _this; } - return Object(__WEBPACK_IMPORTED_MODULE_0__mergeMap__["a" /* mergeMap */])(function () { return innerObservable; }, concurrent); -} -//# sourceMappingURL=mergeMapTo.js.map - - -/***/ }), -/* 329 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + ExhaustMapSubscriber.prototype._next = function (value) { + if (!this.hasSubscription) { + this.tryNext(value); + } + }; + ExhaustMapSubscriber.prototype.tryNext = function (value) { + var index = this.index++; + var destination = this.destination; + try { + var result = this.project(value, index); + this.hasSubscription = true; + this.add(Object(subscribeToResult["a" /* subscribeToResult */])(this, result, value, index)); + } + catch (err) { + destination.error(err); + } + }; + ExhaustMapSubscriber.prototype._complete = function () { + this.hasCompleted = true; + if (!this.hasSubscription) { + this.destination.complete(); + } + }; + ExhaustMapSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.destination.next(innerValue); + }; + ExhaustMapSubscriber.prototype.notifyError = function (err) { + this.destination.error(err); + }; + ExhaustMapSubscriber.prototype.notifyComplete = function (innerSub) { + this.remove(innerSub); + this.hasSubscription = false; + if (this.hasCompleted) { + this.destination.complete(); + } + }; + return ExhaustMapSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=exhaustMap.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = mergeScan; -/* unused harmony export MergeScanOperator */ -/* unused harmony export MergeScanSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_subscribeToResult__ = __webpack_require__(5); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__ = __webpack_require__(4); -/** PURE_IMPORTS_START tslib,_util_tryCatch,_util_errorObject,_util_subscribeToResult,_OuterSubscriber PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/expand.js +/** PURE_IMPORTS_START tslib,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function mergeScan(accumulator, seed, concurrent) { +function expand(project, concurrent, scheduler) { if (concurrent === void 0) { concurrent = Number.POSITIVE_INFINITY; } - return function (source) { return source.lift(new MergeScanOperator(accumulator, seed, concurrent)); }; + if (scheduler === void 0) { + scheduler = undefined; + } + concurrent = (concurrent || 0) < 1 ? Number.POSITIVE_INFINITY : concurrent; + return function (source) { return source.lift(new ExpandOperator(project, concurrent, scheduler)); }; } -var MergeScanOperator = /*@__PURE__*/ (function () { - function MergeScanOperator(accumulator, seed, concurrent) { - this.accumulator = accumulator; - this.seed = seed; +var ExpandOperator = /*@__PURE__*/ (function () { + function ExpandOperator(project, concurrent, scheduler) { + this.project = project; this.concurrent = concurrent; + this.scheduler = scheduler; } - MergeScanOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new MergeScanSubscriber(subscriber, this.accumulator, this.seed, this.concurrent)); + ExpandOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new expand_ExpandSubscriber(subscriber, this.project, this.concurrent, this.scheduler)); }; - return MergeScanOperator; + return ExpandOperator; }()); -var MergeScanSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](MergeScanSubscriber, _super); - function MergeScanSubscriber(destination, accumulator, acc, concurrent) { +var expand_ExpandSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](ExpandSubscriber, _super); + function ExpandSubscriber(destination, project, concurrent, scheduler) { var _this = _super.call(this, destination) || this; - _this.accumulator = accumulator; - _this.acc = acc; + _this.project = project; _this.concurrent = concurrent; - _this.hasValue = false; - _this.hasCompleted = false; - _this.buffer = []; - _this.active = 0; + _this.scheduler = scheduler; _this.index = 0; + _this.active = 0; + _this.hasCompleted = false; + if (concurrent < Number.POSITIVE_INFINITY) { + _this.buffer = []; + } return _this; } - MergeScanSubscriber.prototype._next = function (value) { + ExpandSubscriber.dispatch = function (arg) { + var subscriber = arg.subscriber, result = arg.result, value = arg.value, index = arg.index; + subscriber.subscribeToProjection(result, value, index); + }; + ExpandSubscriber.prototype._next = function (value) { + var destination = this.destination; + if (destination.closed) { + this._complete(); + return; + } + var index = this.index++; if (this.active < this.concurrent) { - var index = this.index++; - var ish = Object(__WEBPACK_IMPORTED_MODULE_1__util_tryCatch__["a" /* tryCatch */])(this.accumulator)(this.acc, value); - var destination = this.destination; - if (ish === __WEBPACK_IMPORTED_MODULE_2__util_errorObject__["a" /* errorObject */]) { - destination.error(__WEBPACK_IMPORTED_MODULE_2__util_errorObject__["a" /* errorObject */].e); + destination.next(value); + var result = Object(tryCatch["a" /* tryCatch */])(this.project)(value, index); + if (result === errorObject["a" /* errorObject */]) { + destination.error(errorObject["a" /* errorObject */].e); + } + else if (!this.scheduler) { + this.subscribeToProjection(result, value, index); } else { - this.active++; - this._innerSub(ish, value, index); + var state = { subscriber: this, result: result, value: value, index: index }; + this.add(this.scheduler.schedule(ExpandSubscriber.dispatch, 0, state)); } } else { this.buffer.push(value); } }; - MergeScanSubscriber.prototype._innerSub = function (ish, value, index) { - this.add(Object(__WEBPACK_IMPORTED_MODULE_3__util_subscribeToResult__["a" /* subscribeToResult */])(this, ish, value, index)); + ExpandSubscriber.prototype.subscribeToProjection = function (result, value, index) { + this.active++; + this.add(Object(subscribeToResult["a" /* subscribeToResult */])(this, result, value, index)); }; - MergeScanSubscriber.prototype._complete = function () { + ExpandSubscriber.prototype._complete = function () { this.hasCompleted = true; - if (this.active === 0 && this.buffer.length === 0) { - if (this.hasValue === false) { - this.destination.next(this.acc); - } + if (this.hasCompleted && this.active === 0) { this.destination.complete(); } }; - MergeScanSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - var destination = this.destination; - this.acc = innerValue; - this.hasValue = true; - destination.next(innerValue); + ExpandSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this._next(innerValue); }; - MergeScanSubscriber.prototype.notifyComplete = function (innerSub) { + ExpandSubscriber.prototype.notifyComplete = function (innerSub) { var buffer = this.buffer; this.remove(innerSub); this.active--; - if (buffer.length > 0) { + if (buffer && buffer.length > 0) { this._next(buffer.shift()); } - else if (this.active === 0 && this.hasCompleted) { - if (this.hasValue === false) { - this.destination.next(this.acc); - } + if (this.hasCompleted && this.active === 0) { this.destination.complete(); } }; - return MergeScanSubscriber; -}(__WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__["a" /* OuterSubscriber */])); - -//# sourceMappingURL=mergeScan.js.map - - -/***/ }), -/* 330 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = min; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__reduce__ = __webpack_require__(50); -/** PURE_IMPORTS_START _reduce PURE_IMPORTS_END */ - -function min(comparer) { - var min = (typeof comparer === 'function') - ? function (x, y) { return comparer(x, y) < 0 ? x : y; } - : function (x, y) { return x < y ? x : y; }; - return Object(__WEBPACK_IMPORTED_MODULE_0__reduce__["a" /* reduce */])(min); -} -//# sourceMappingURL=min.js.map - - -/***/ }), -/* 331 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = onErrorResumeNext; -/* unused harmony export onErrorResumeNextStatic */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__observable_from__ = __webpack_require__(18); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_observable_from,_util_isArray,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ + return ExpandSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=expand.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/finalize.js +/** PURE_IMPORTS_START tslib,_Subscriber,_Subscription PURE_IMPORTS_END */ -function onErrorResumeNext() { - var nextSources = []; - for (var _i = 0; _i < arguments.length; _i++) { - nextSources[_i] = arguments[_i]; - } - if (nextSources.length === 1 && Object(__WEBPACK_IMPORTED_MODULE_2__util_isArray__["a" /* isArray */])(nextSources[0])) { - nextSources = nextSources[0]; - } - return function (source) { return source.lift(new OnErrorResumeNextOperator(nextSources)); }; -} -function onErrorResumeNextStatic() { - var nextSources = []; - for (var _i = 0; _i < arguments.length; _i++) { - nextSources[_i] = arguments[_i]; - } - var source = null; - if (nextSources.length === 1 && Object(__WEBPACK_IMPORTED_MODULE_2__util_isArray__["a" /* isArray */])(nextSources[0])) { - nextSources = nextSources[0]; - } - source = nextSources.shift(); - return Object(__WEBPACK_IMPORTED_MODULE_1__observable_from__["a" /* from */])(source, null).lift(new OnErrorResumeNextOperator(nextSources)); +function finalize(callback) { + return function (source) { return source.lift(new FinallyOperator(callback)); }; } -var OnErrorResumeNextOperator = /*@__PURE__*/ (function () { - function OnErrorResumeNextOperator(nextSources) { - this.nextSources = nextSources; +var FinallyOperator = /*@__PURE__*/ (function () { + function FinallyOperator(callback) { + this.callback = callback; } - OnErrorResumeNextOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new OnErrorResumeNextSubscriber(subscriber, this.nextSources)); + FinallyOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new finalize_FinallySubscriber(subscriber, this.callback)); }; - return OnErrorResumeNextOperator; + return FinallyOperator; }()); -var OnErrorResumeNextSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](OnErrorResumeNextSubscriber, _super); - function OnErrorResumeNextSubscriber(destination, nextSources) { +var finalize_FinallySubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](FinallySubscriber, _super); + function FinallySubscriber(destination, callback) { var _this = _super.call(this, destination) || this; - _this.destination = destination; - _this.nextSources = nextSources; + _this.add(new Subscription["a" /* Subscription */](callback)); return _this; } - OnErrorResumeNextSubscriber.prototype.notifyError = function (error, innerSub) { - this.subscribeToNextSource(); - }; - OnErrorResumeNextSubscriber.prototype.notifyComplete = function (innerSub) { - this.subscribeToNextSource(); - }; - OnErrorResumeNextSubscriber.prototype._error = function (err) { - this.subscribeToNextSource(); - }; - OnErrorResumeNextSubscriber.prototype._complete = function () { - this.subscribeToNextSource(); - }; - OnErrorResumeNextSubscriber.prototype.subscribeToNextSource = function () { - var next = this.nextSources.shift(); - if (next) { - this.add(Object(__WEBPACK_IMPORTED_MODULE_4__util_subscribeToResult__["a" /* subscribeToResult */])(this, next)); - } - else { - this.destination.complete(); - } - }; - return OnErrorResumeNextSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=onErrorResumeNext.js.map - - -/***/ }), -/* 332 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + return FinallySubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=finalize.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = pairwise; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/find.js /** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function pairwise() { - return function (source) { return source.lift(new PairwiseOperator()); }; +function find(predicate, thisArg) { + if (typeof predicate !== 'function') { + throw new TypeError('predicate is not a function'); + } + return function (source) { return source.lift(new FindValueOperator(predicate, source, false, thisArg)); }; } -var PairwiseOperator = /*@__PURE__*/ (function () { - function PairwiseOperator() { +var FindValueOperator = /*@__PURE__*/ (function () { + function FindValueOperator(predicate, source, yieldIndex, thisArg) { + this.predicate = predicate; + this.source = source; + this.yieldIndex = yieldIndex; + this.thisArg = thisArg; } - PairwiseOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new PairwiseSubscriber(subscriber)); + FindValueOperator.prototype.call = function (observer, source) { + return source.subscribe(new find_FindValueSubscriber(observer, this.predicate, this.source, this.yieldIndex, this.thisArg)); }; - return PairwiseOperator; + return FindValueOperator; }()); -var PairwiseSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](PairwiseSubscriber, _super); - function PairwiseSubscriber(destination) { + +var find_FindValueSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](FindValueSubscriber, _super); + function FindValueSubscriber(destination, predicate, source, yieldIndex, thisArg) { var _this = _super.call(this, destination) || this; - _this.hasPrev = false; + _this.predicate = predicate; + _this.source = source; + _this.yieldIndex = yieldIndex; + _this.thisArg = thisArg; + _this.index = 0; return _this; } - PairwiseSubscriber.prototype._next = function (value) { - if (this.hasPrev) { - this.destination.next([this.prev, value]); - } - else { - this.hasPrev = true; - } - this.prev = value; - }; - return PairwiseSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=pairwise.js.map - - -/***/ }), -/* 333 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = partition; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_not__ = __webpack_require__(334); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__filter__ = __webpack_require__(37); -/** PURE_IMPORTS_START _util_not,_filter PURE_IMPORTS_END */ - - -function partition(predicate, thisArg) { - return function (source) { - return [ - Object(__WEBPACK_IMPORTED_MODULE_1__filter__["a" /* filter */])(predicate, thisArg)(source), - Object(__WEBPACK_IMPORTED_MODULE_1__filter__["a" /* filter */])(Object(__WEBPACK_IMPORTED_MODULE_0__util_not__["a" /* not */])(predicate, thisArg))(source) - ]; + FindValueSubscriber.prototype.notifyComplete = function (value) { + var destination = this.destination; + destination.next(value); + destination.complete(); }; -} -//# sourceMappingURL=partition.js.map - - -/***/ }), -/* 334 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = not; -/** PURE_IMPORTS_START PURE_IMPORTS_END */ -function not(pred, thisArg) { - function notPred() { - return !(notPred.pred.apply(notPred.thisArg, arguments)); - } - notPred.pred = pred; - notPred.thisArg = thisArg; - return notPred; -} -//# sourceMappingURL=not.js.map - - -/***/ }), -/* 335 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = pluck; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__map__ = __webpack_require__(15); -/** PURE_IMPORTS_START _map PURE_IMPORTS_END */ - -function pluck() { - var properties = []; - for (var _i = 0; _i < arguments.length; _i++) { - properties[_i] = arguments[_i]; - } - var length = properties.length; - if (length === 0) { - throw new Error('list of properties cannot be empty.'); - } - return function (source) { return Object(__WEBPACK_IMPORTED_MODULE_0__map__["a" /* map */])(plucker(properties, length))(source); }; -} -function plucker(props, length) { - var mapper = function (x) { - var currentProp = x; - for (var i = 0; i < length; i++) { - var p = currentProp[props[i]]; - if (typeof p !== 'undefined') { - currentProp = p; - } - else { - return undefined; + FindValueSubscriber.prototype._next = function (value) { + var _a = this, predicate = _a.predicate, thisArg = _a.thisArg; + var index = this.index++; + try { + var result = predicate.call(thisArg || this, value, index, this.source); + if (result) { + this.notifyComplete(this.yieldIndex ? index : value); } } - return currentProp; - }; - return mapper; -} -//# sourceMappingURL=pluck.js.map - - -/***/ }), -/* 336 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + catch (err) { + this.destination.error(err); + } + }; + FindValueSubscriber.prototype._complete = function () { + this.notifyComplete(this.yieldIndex ? -1 : undefined); + }; + return FindValueSubscriber; +}(Subscriber["a" /* Subscriber */])); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = publish; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__multicast__ = __webpack_require__(26); -/** PURE_IMPORTS_START _Subject,_multicast PURE_IMPORTS_END */ +//# sourceMappingURL=find.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/findIndex.js +/** PURE_IMPORTS_START _operators_find PURE_IMPORTS_END */ -function publish(selector) { - return selector ? - Object(__WEBPACK_IMPORTED_MODULE_1__multicast__["a" /* multicast */])(function () { return new __WEBPACK_IMPORTED_MODULE_0__Subject__["a" /* Subject */](); }, selector) : - Object(__WEBPACK_IMPORTED_MODULE_1__multicast__["a" /* multicast */])(new __WEBPACK_IMPORTED_MODULE_0__Subject__["a" /* Subject */]()); +function findIndex(predicate, thisArg) { + return function (source) { return source.lift(new FindValueOperator(predicate, source, true, thisArg)); }; } -//# sourceMappingURL=publish.js.map - - -/***/ }), -/* 337 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +//# sourceMappingURL=findIndex.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = publishBehavior; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__BehaviorSubject__ = __webpack_require__(108); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__multicast__ = __webpack_require__(26); -/** PURE_IMPORTS_START _BehaviorSubject,_multicast PURE_IMPORTS_END */ +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/identity.js +var identity = __webpack_require__(21); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/first.js +/** PURE_IMPORTS_START _util_EmptyError,_filter,_take,_defaultIfEmpty,_throwIfEmpty,_util_identity PURE_IMPORTS_END */ -function publishBehavior(value) { - return function (source) { return Object(__WEBPACK_IMPORTED_MODULE_1__multicast__["a" /* multicast */])(new __WEBPACK_IMPORTED_MODULE_0__BehaviorSubject__["a" /* BehaviorSubject */](value))(source); }; -} -//# sourceMappingURL=publishBehavior.js.map -/***/ }), -/* 338 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = publishLast; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__AsyncSubject__ = __webpack_require__(46); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__multicast__ = __webpack_require__(26); -/** PURE_IMPORTS_START _AsyncSubject,_multicast PURE_IMPORTS_END */ -function publishLast() { - return function (source) { return Object(__WEBPACK_IMPORTED_MODULE_1__multicast__["a" /* multicast */])(new __WEBPACK_IMPORTED_MODULE_0__AsyncSubject__["a" /* AsyncSubject */]())(source); }; +function first(predicate, defaultValue) { + var hasDefaultValue = arguments.length >= 2; + return function (source) { return source.pipe(predicate ? filter(function (v, i) { return predicate(v, i, source); }) : identity["a" /* identity */], take(1), hasDefaultValue ? defaultIfEmpty(defaultValue) : throwIfEmpty(function () { return new EmptyError["a" /* EmptyError */](); })); }; } -//# sourceMappingURL=publishLast.js.map - +//# sourceMappingURL=first.js.map -/***/ }), -/* 339 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/groupBy.js +var groupBy = __webpack_require__(63); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = publishReplay; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__ReplaySubject__ = __webpack_require__(65); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__multicast__ = __webpack_require__(26); -/** PURE_IMPORTS_START _ReplaySubject,_multicast PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/ignoreElements.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function publishReplay(bufferSize, windowTime, selectorOrScheduler, scheduler) { - if (selectorOrScheduler && typeof selectorOrScheduler !== 'function') { - scheduler = selectorOrScheduler; - } - var selector = typeof selectorOrScheduler === 'function' ? selectorOrScheduler : undefined; - var subject = new __WEBPACK_IMPORTED_MODULE_0__ReplaySubject__["a" /* ReplaySubject */](bufferSize, windowTime, scheduler); - return function (source) { return Object(__WEBPACK_IMPORTED_MODULE_1__multicast__["a" /* multicast */])(function () { return subject; }, selector)(source); }; +function ignoreElements() { + return function ignoreElementsOperatorFunction(source) { + return source.lift(new IgnoreElementsOperator()); + }; } -//# sourceMappingURL=publishReplay.js.map - - -/***/ }), -/* 340 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +var IgnoreElementsOperator = /*@__PURE__*/ (function () { + function IgnoreElementsOperator() { + } + IgnoreElementsOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new ignoreElements_IgnoreElementsSubscriber(subscriber)); + }; + return IgnoreElementsOperator; +}()); +var ignoreElements_IgnoreElementsSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](IgnoreElementsSubscriber, _super); + function IgnoreElementsSubscriber() { + return _super !== null && _super.apply(this, arguments) || this; + } + IgnoreElementsSubscriber.prototype._next = function (unused) { + }; + return IgnoreElementsSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=ignoreElements.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = race; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__util_isArray__ = __webpack_require__(10); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__observable_race__ = __webpack_require__(124); -/** PURE_IMPORTS_START _util_isArray,_observable_race PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/isEmpty.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function race() { - var observables = []; - for (var _i = 0; _i < arguments.length; _i++) { - observables[_i] = arguments[_i]; +function isEmpty() { + return function (source) { return source.lift(new IsEmptyOperator()); }; +} +var IsEmptyOperator = /*@__PURE__*/ (function () { + function IsEmptyOperator() { } - return function raceOperatorFunction(source) { - if (observables.length === 1 && Object(__WEBPACK_IMPORTED_MODULE_0__util_isArray__["a" /* isArray */])(observables[0])) { - observables = observables[0]; - } - return source.lift.call(__WEBPACK_IMPORTED_MODULE_1__observable_race__["a" /* race */].apply(void 0, [source].concat(observables))); + IsEmptyOperator.prototype.call = function (observer, source) { + return source.subscribe(new isEmpty_IsEmptySubscriber(observer)); }; -} -//# sourceMappingURL=race.js.map - + return IsEmptyOperator; +}()); +var isEmpty_IsEmptySubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](IsEmptySubscriber, _super); + function IsEmptySubscriber(destination) { + return _super.call(this, destination) || this; + } + IsEmptySubscriber.prototype.notifyComplete = function (isEmpty) { + var destination = this.destination; + destination.next(isEmpty); + destination.complete(); + }; + IsEmptySubscriber.prototype._next = function (value) { + this.notifyComplete(false); + }; + IsEmptySubscriber.prototype._complete = function () { + this.notifyComplete(true); + }; + return IsEmptySubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=isEmpty.js.map -/***/ }), -/* 341 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/takeLast.js +/** PURE_IMPORTS_START tslib,_Subscriber,_util_ArgumentOutOfRangeError,_observable_empty PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = repeat; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__observable_empty__ = __webpack_require__(11); -/** PURE_IMPORTS_START tslib,_Subscriber,_observable_empty PURE_IMPORTS_END */ -function repeat(count) { - if (count === void 0) { - count = -1; - } - return function (source) { +function takeLast(count) { + return function takeLastOperatorFunction(source) { if (count === 0) { - return Object(__WEBPACK_IMPORTED_MODULE_2__observable_empty__["b" /* empty */])(); - } - else if (count < 0) { - return source.lift(new RepeatOperator(-1, source)); + return Object(empty["b" /* empty */])(); } else { - return source.lift(new RepeatOperator(count - 1, source)); + return source.lift(new takeLast_TakeLastOperator(count)); } }; } -var RepeatOperator = /*@__PURE__*/ (function () { - function RepeatOperator(count, source) { - this.count = count; - this.source = source; +var takeLast_TakeLastOperator = /*@__PURE__*/ (function () { + function TakeLastOperator(total) { + this.total = total; + if (this.total < 0) { + throw new ArgumentOutOfRangeError["a" /* ArgumentOutOfRangeError */]; + } } - RepeatOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new RepeatSubscriber(subscriber, this.count, this.source)); + TakeLastOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new takeLast_TakeLastSubscriber(subscriber, this.total)); }; - return RepeatOperator; + return TakeLastOperator; }()); -var RepeatSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](RepeatSubscriber, _super); - function RepeatSubscriber(destination, count, source) { +var takeLast_TakeLastSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](TakeLastSubscriber, _super); + function TakeLastSubscriber(destination, total) { var _this = _super.call(this, destination) || this; - _this.count = count; - _this.source = source; + _this.total = total; + _this.ring = new Array(); + _this.count = 0; return _this; } - RepeatSubscriber.prototype.complete = function () { - if (!this.isStopped) { - var _a = this, source = _a.source, count = _a.count; - if (count === 0) { - return _super.prototype.complete.call(this); - } - else if (count > -1) { - this.count = count - 1; + TakeLastSubscriber.prototype._next = function (value) { + var ring = this.ring; + var total = this.total; + var count = this.count++; + if (ring.length < total) { + ring.push(value); + } + else { + var index = count % total; + ring[index] = value; + } + }; + TakeLastSubscriber.prototype._complete = function () { + var destination = this.destination; + var count = this.count; + if (count > 0) { + var total = this.count >= this.total ? this.total : this.count; + var ring = this.ring; + for (var i = 0; i < total; i++) { + var idx = (count++) % total; + destination.next(ring[idx]); } - source.subscribe(this._unsubscribeAndRecycle()); } + destination.complete(); }; - return RepeatSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=repeat.js.map + return TakeLastSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=takeLast.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/last.js +/** PURE_IMPORTS_START _util_EmptyError,_filter,_takeLast,_throwIfEmpty,_defaultIfEmpty,_util_identity PURE_IMPORTS_END */ -/***/ }), -/* 342 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = repeatWhen; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_Subject,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +function last(predicate, defaultValue) { + var hasDefaultValue = arguments.length >= 2; + return function (source) { return source.pipe(predicate ? filter(function (v, i) { return predicate(v, i, source); }) : identity["a" /* identity */], takeLast(1), hasDefaultValue ? defaultIfEmpty(defaultValue) : throwIfEmpty(function () { return new EmptyError["a" /* EmptyError */](); })); }; +} +//# sourceMappingURL=last.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/mapTo.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function repeatWhen(notifier) { - return function (source) { return source.lift(new RepeatWhenOperator(notifier)); }; +function mapTo(value) { + return function (source) { return source.lift(new MapToOperator(value)); }; } -var RepeatWhenOperator = /*@__PURE__*/ (function () { - function RepeatWhenOperator(notifier) { - this.notifier = notifier; +var MapToOperator = /*@__PURE__*/ (function () { + function MapToOperator(value) { + this.value = value; + } + MapToOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new mapTo_MapToSubscriber(subscriber, this.value)); + }; + return MapToOperator; +}()); +var mapTo_MapToSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](MapToSubscriber, _super); + function MapToSubscriber(destination, value) { + var _this = _super.call(this, destination) || this; + _this.value = value; + return _this; + } + MapToSubscriber.prototype._next = function (x) { + this.destination.next(this.value); + }; + return MapToSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=mapTo.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/materialize.js +/** PURE_IMPORTS_START tslib,_Subscriber,_Notification PURE_IMPORTS_END */ + + + +function materialize() { + return function materializeOperatorFunction(source) { + return source.lift(new MaterializeOperator()); + }; +} +var MaterializeOperator = /*@__PURE__*/ (function () { + function MaterializeOperator() { + } + MaterializeOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new materialize_MaterializeSubscriber(subscriber)); + }; + return MaterializeOperator; +}()); +var materialize_MaterializeSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](MaterializeSubscriber, _super); + function MaterializeSubscriber(destination) { + return _super.call(this, destination) || this; + } + MaterializeSubscriber.prototype._next = function (value) { + this.destination.next(Notification["a" /* Notification */].createNext(value)); + }; + MaterializeSubscriber.prototype._error = function (err) { + var destination = this.destination; + destination.next(Notification["a" /* Notification */].createError(err)); + destination.complete(); + }; + MaterializeSubscriber.prototype._complete = function () { + var destination = this.destination; + destination.next(Notification["a" /* Notification */].createComplete()); + destination.complete(); + }; + return MaterializeSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=materialize.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/scan.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ + + +function scan(accumulator, seed) { + var hasSeed = false; + if (arguments.length >= 2) { + hasSeed = true; + } + return function scanOperatorFunction(source) { + return source.lift(new ScanOperator(accumulator, seed, hasSeed)); + }; +} +var ScanOperator = /*@__PURE__*/ (function () { + function ScanOperator(accumulator, seed, hasSeed) { + if (hasSeed === void 0) { + hasSeed = false; + } + this.accumulator = accumulator; + this.seed = seed; + this.hasSeed = hasSeed; } - RepeatWhenOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new RepeatWhenSubscriber(subscriber, this.notifier, source)); + ScanOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new scan_ScanSubscriber(subscriber, this.accumulator, this.seed, this.hasSeed)); }; - return RepeatWhenOperator; + return ScanOperator; }()); -var RepeatWhenSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](RepeatWhenSubscriber, _super); - function RepeatWhenSubscriber(destination, notifier, source) { +var scan_ScanSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](ScanSubscriber, _super); + function ScanSubscriber(destination, accumulator, _seed, hasSeed) { var _this = _super.call(this, destination) || this; - _this.notifier = notifier; - _this.source = source; - _this.sourceIsBeingSubscribedTo = true; + _this.accumulator = accumulator; + _this._seed = _seed; + _this.hasSeed = hasSeed; + _this.index = 0; return _this; } - RepeatWhenSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.sourceIsBeingSubscribedTo = true; - this.source.subscribe(this); - }; - RepeatWhenSubscriber.prototype.notifyComplete = function (innerSub) { - if (this.sourceIsBeingSubscribedTo === false) { - return _super.prototype.complete.call(this); + Object.defineProperty(ScanSubscriber.prototype, "seed", { + get: function () { + return this._seed; + }, + set: function (value) { + this.hasSeed = true; + this._seed = value; + }, + enumerable: true, + configurable: true + }); + ScanSubscriber.prototype._next = function (value) { + if (!this.hasSeed) { + this.seed = value; + this.destination.next(value); } - }; - RepeatWhenSubscriber.prototype.complete = function () { - this.sourceIsBeingSubscribedTo = false; - if (!this.isStopped) { - if (!this.retries) { - this.subscribeToRetries(); - } - if (!this.retriesSubscription || this.retriesSubscription.closed) { - return _super.prototype.complete.call(this); - } - this._unsubscribeAndRecycle(); - this.notifications.next(); + else { + return this._tryNext(value); } }; - RepeatWhenSubscriber.prototype._unsubscribe = function () { - var _a = this, notifications = _a.notifications, retriesSubscription = _a.retriesSubscription; - if (notifications) { - notifications.unsubscribe(); - this.notifications = null; - } - if (retriesSubscription) { - retriesSubscription.unsubscribe(); - this.retriesSubscription = null; + ScanSubscriber.prototype._tryNext = function (value) { + var index = this.index++; + var result; + try { + result = this.accumulator(this.seed, value, index); } - this.retries = null; - }; - RepeatWhenSubscriber.prototype._unsubscribeAndRecycle = function () { - var _unsubscribe = this._unsubscribe; - this._unsubscribe = null; - _super.prototype._unsubscribeAndRecycle.call(this); - this._unsubscribe = _unsubscribe; - return this; - }; - RepeatWhenSubscriber.prototype.subscribeToRetries = function () { - this.notifications = new __WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */](); - var retries = Object(__WEBPACK_IMPORTED_MODULE_2__util_tryCatch__["a" /* tryCatch */])(this.notifier)(this.notifications); - if (retries === __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */]) { - return _super.prototype.complete.call(this); + catch (err) { + this.destination.error(err); } - this.retries = retries; - this.retriesSubscription = Object(__WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__["a" /* subscribeToResult */])(this, retries); + this.seed = result; + this.destination.next(result); }; - return RepeatWhenSubscriber; -}(__WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=repeatWhen.js.map + return ScanSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=scan.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/pipe.js +var pipe = __webpack_require__(39); -/***/ }), -/* 343 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/reduce.js +/** PURE_IMPORTS_START _scan,_takeLast,_defaultIfEmpty,_util_pipe PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = retry; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function retry(count) { - if (count === void 0) { - count = -1; - } - return function (source) { return source.lift(new RetryOperator(count, source)); }; -} -var RetryOperator = /*@__PURE__*/ (function () { - function RetryOperator(count, source) { - this.count = count; - this.source = source; + +function reduce(accumulator, seed) { + if (arguments.length >= 2) { + return function reduceOperatorFunctionWithSeed(source) { + return Object(pipe["a" /* pipe */])(scan(accumulator, seed), takeLast(1), defaultIfEmpty(seed))(source); + }; } - RetryOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new RetrySubscriber(subscriber, this.count, this.source)); + return function reduceOperatorFunction(source) { + return Object(pipe["a" /* pipe */])(scan(function (acc, value, index) { + return accumulator(acc, value, index + 1); + }), takeLast(1))(source); }; - return RetryOperator; -}()); -var RetrySubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](RetrySubscriber, _super); - function RetrySubscriber(destination, count, source) { - var _this = _super.call(this, destination) || this; - _this.count = count; - _this.source = source; - return _this; +} +//# sourceMappingURL=reduce.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/max.js +/** PURE_IMPORTS_START _reduce PURE_IMPORTS_END */ + +function max_max(comparer) { + var max = (typeof comparer === 'function') + ? function (x, y) { return comparer(x, y) > 0 ? x : y; } + : function (x, y) { return x > y ? x : y; }; + return reduce(max); +} +//# sourceMappingURL=max.js.map + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/merge.js +var merge = __webpack_require__(69); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/merge.js +/** PURE_IMPORTS_START _observable_merge PURE_IMPORTS_END */ + +function merge_merge() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i] = arguments[_i]; } - RetrySubscriber.prototype.error = function (err) { - if (!this.isStopped) { - var _a = this, source = _a.source, count = _a.count; - if (count === 0) { - return _super.prototype.error.call(this, err); - } - else if (count > -1) { - this.count = count - 1; - } - source.subscribe(this._unsubscribeAndRecycle()); - } - }; - return RetrySubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=retry.js.map + return function (source) { return source.lift.call(merge["a" /* merge */].apply(void 0, [source].concat(observables))); }; +} +//# sourceMappingURL=merge.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/mergeAll.js +var mergeAll = __webpack_require__(50); -/***/ }), -/* 344 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/mergeMapTo.js +/** PURE_IMPORTS_START _mergeMap PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = retryWhen; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_Subject,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +function mergeMapTo(innerObservable, resultSelector, concurrent) { + if (concurrent === void 0) { + concurrent = Number.POSITIVE_INFINITY; + } + if (typeof resultSelector === 'function') { + return Object(mergeMap["a" /* mergeMap */])(function () { return innerObservable; }, resultSelector, concurrent); + } + if (typeof resultSelector === 'number') { + concurrent = resultSelector; + } + return Object(mergeMap["a" /* mergeMap */])(function () { return innerObservable; }, concurrent); +} +//# sourceMappingURL=mergeMapTo.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/mergeScan.js +/** PURE_IMPORTS_START tslib,_util_tryCatch,_util_errorObject,_util_subscribeToResult,_OuterSubscriber PURE_IMPORTS_END */ -function retryWhen(notifier) { - return function (source) { return source.lift(new RetryWhenOperator(notifier, source)); }; +function mergeScan(accumulator, seed, concurrent) { + if (concurrent === void 0) { + concurrent = Number.POSITIVE_INFINITY; + } + return function (source) { return source.lift(new MergeScanOperator(accumulator, seed, concurrent)); }; } -var RetryWhenOperator = /*@__PURE__*/ (function () { - function RetryWhenOperator(notifier, source) { - this.notifier = notifier; - this.source = source; +var MergeScanOperator = /*@__PURE__*/ (function () { + function MergeScanOperator(accumulator, seed, concurrent) { + this.accumulator = accumulator; + this.seed = seed; + this.concurrent = concurrent; } - RetryWhenOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new RetryWhenSubscriber(subscriber, this.notifier, this.source)); + MergeScanOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new mergeScan_MergeScanSubscriber(subscriber, this.accumulator, this.seed, this.concurrent)); }; - return RetryWhenOperator; + return MergeScanOperator; }()); -var RetryWhenSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](RetryWhenSubscriber, _super); - function RetryWhenSubscriber(destination, notifier, source) { + +var mergeScan_MergeScanSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](MergeScanSubscriber, _super); + function MergeScanSubscriber(destination, accumulator, acc, concurrent) { var _this = _super.call(this, destination) || this; - _this.notifier = notifier; - _this.source = source; + _this.accumulator = accumulator; + _this.acc = acc; + _this.concurrent = concurrent; + _this.hasValue = false; + _this.hasCompleted = false; + _this.buffer = []; + _this.active = 0; + _this.index = 0; return _this; } - RetryWhenSubscriber.prototype.error = function (err) { - if (!this.isStopped) { - var errors = this.errors; - var retries = this.retries; - var retriesSubscription = this.retriesSubscription; - if (!retries) { - errors = new __WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */](); - retries = Object(__WEBPACK_IMPORTED_MODULE_2__util_tryCatch__["a" /* tryCatch */])(this.notifier)(errors); - if (retries === __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */]) { - return _super.prototype.error.call(this, __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */].e); - } - retriesSubscription = Object(__WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__["a" /* subscribeToResult */])(this, retries); + MergeScanSubscriber.prototype._next = function (value) { + if (this.active < this.concurrent) { + var index = this.index++; + var ish = Object(tryCatch["a" /* tryCatch */])(this.accumulator)(this.acc, value); + var destination = this.destination; + if (ish === errorObject["a" /* errorObject */]) { + destination.error(errorObject["a" /* errorObject */].e); } else { - this.errors = null; - this.retriesSubscription = null; + this.active++; + this._innerSub(ish, value, index); } - this._unsubscribeAndRecycle(); - this.errors = errors; - this.retries = retries; - this.retriesSubscription = retriesSubscription; - errors.next(err); + } + else { + this.buffer.push(value); } }; - RetryWhenSubscriber.prototype._unsubscribe = function () { - var _a = this, errors = _a.errors, retriesSubscription = _a.retriesSubscription; - if (errors) { - errors.unsubscribe(); - this.errors = null; + MergeScanSubscriber.prototype._innerSub = function (ish, value, index) { + this.add(Object(subscribeToResult["a" /* subscribeToResult */])(this, ish, value, index)); + }; + MergeScanSubscriber.prototype._complete = function () { + this.hasCompleted = true; + if (this.active === 0 && this.buffer.length === 0) { + if (this.hasValue === false) { + this.destination.next(this.acc); + } + this.destination.complete(); + } + }; + MergeScanSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + var destination = this.destination; + this.acc = innerValue; + this.hasValue = true; + destination.next(innerValue); + }; + MergeScanSubscriber.prototype.notifyComplete = function (innerSub) { + var buffer = this.buffer; + this.remove(innerSub); + this.active--; + if (buffer.length > 0) { + this._next(buffer.shift()); } - if (retriesSubscription) { - retriesSubscription.unsubscribe(); - this.retriesSubscription = null; + else if (this.active === 0 && this.hasCompleted) { + if (this.hasValue === false) { + this.destination.next(this.acc); + } + this.destination.complete(); } - this.retries = null; - }; - RetryWhenSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - var _unsubscribe = this._unsubscribe; - this._unsubscribe = null; - this._unsubscribeAndRecycle(); - this._unsubscribe = _unsubscribe; - this.source.subscribe(this); }; - return RetryWhenSubscriber; -}(__WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=retryWhen.js.map + return MergeScanSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=mergeScan.js.map -/***/ }), -/* 345 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/min.js +/** PURE_IMPORTS_START _reduce PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = sample; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +function min_min(comparer) { + var min = (typeof comparer === 'function') + ? function (x, y) { return comparer(x, y) < 0 ? x : y; } + : function (x, y) { return x < y ? x : y; }; + return reduce(min); +} +//# sourceMappingURL=min.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/ConnectableObservable.js +var ConnectableObservable = __webpack_require__(64); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/multicast.js +/** PURE_IMPORTS_START _observable_ConnectableObservable PURE_IMPORTS_END */ -function sample(notifier) { - return function (source) { return source.lift(new SampleOperator(notifier)); }; +function multicast(subjectOrSubjectFactory, selector) { + return function multicastOperatorFunction(source) { + var subjectFactory; + if (typeof subjectOrSubjectFactory === 'function') { + subjectFactory = subjectOrSubjectFactory; + } + else { + subjectFactory = function subjectFactory() { + return subjectOrSubjectFactory; + }; + } + if (typeof selector === 'function') { + return source.lift(new MulticastOperator(subjectFactory, selector)); + } + var connectable = Object.create(source, ConnectableObservable["b" /* connectableObservableDescriptor */]); + connectable.source = source; + connectable.subjectFactory = subjectFactory; + return connectable; + }; } -var SampleOperator = /*@__PURE__*/ (function () { - function SampleOperator(notifier) { - this.notifier = notifier; +var MulticastOperator = /*@__PURE__*/ (function () { + function MulticastOperator(subjectFactory, selector) { + this.subjectFactory = subjectFactory; + this.selector = selector; } - SampleOperator.prototype.call = function (subscriber, source) { - var sampleSubscriber = new SampleSubscriber(subscriber); - var subscription = source.subscribe(sampleSubscriber); - subscription.add(Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(sampleSubscriber, this.notifier)); + MulticastOperator.prototype.call = function (subscriber, source) { + var selector = this.selector; + var subject = this.subjectFactory(); + var subscription = selector(subject).subscribe(subscriber); + subscription.add(source.subscribe(subject)); return subscription; }; - return SampleOperator; + return MulticastOperator; }()); -var SampleSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SampleSubscriber, _super); - function SampleSubscriber() { - var _this = _super !== null && _super.apply(this, arguments) || this; - _this.hasValue = false; - return _this; - } - SampleSubscriber.prototype._next = function (value) { - this.value = value; - this.hasValue = true; - }; - SampleSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.emitValue(); - }; - SampleSubscriber.prototype.notifyComplete = function () { - this.emitValue(); - }; - SampleSubscriber.prototype.emitValue = function () { - if (this.hasValue) { - this.hasValue = false; - this.destination.next(this.value); - } - }; - return SampleSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=sample.js.map +//# sourceMappingURL=multicast.js.map -/***/ }), -/* 346 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/observeOn.js +var observeOn = __webpack_require__(66); -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = sampleTime; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__scheduler_async__ = __webpack_require__(12); -/** PURE_IMPORTS_START tslib,_Subscriber,_scheduler_async PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/onErrorResumeNext.js +/** PURE_IMPORTS_START tslib,_observable_from,_util_isArray,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function sampleTime(period, scheduler) { - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_2__scheduler_async__["a" /* async */]; + + +function onErrorResumeNext() { + var nextSources = []; + for (var _i = 0; _i < arguments.length; _i++) { + nextSources[_i] = arguments[_i]; } - return function (source) { return source.lift(new SampleTimeOperator(period, scheduler)); }; + if (nextSources.length === 1 && Object(isArray["a" /* isArray */])(nextSources[0])) { + nextSources = nextSources[0]; + } + return function (source) { return source.lift(new OnErrorResumeNextOperator(nextSources)); }; } -var SampleTimeOperator = /*@__PURE__*/ (function () { - function SampleTimeOperator(period, scheduler) { - this.period = period; - this.scheduler = scheduler; +function onErrorResumeNextStatic() { + var nextSources = []; + for (var _i = 0; _i < arguments.length; _i++) { + nextSources[_i] = arguments[_i]; } - SampleTimeOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new SampleTimeSubscriber(subscriber, this.period, this.scheduler)); + var source = null; + if (nextSources.length === 1 && Object(isArray["a" /* isArray */])(nextSources[0])) { + nextSources = nextSources[0]; + } + source = nextSources.shift(); + return Object(from["a" /* from */])(source, null).lift(new OnErrorResumeNextOperator(nextSources)); +} +var OnErrorResumeNextOperator = /*@__PURE__*/ (function () { + function OnErrorResumeNextOperator(nextSources) { + this.nextSources = nextSources; + } + OnErrorResumeNextOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new onErrorResumeNext_OnErrorResumeNextSubscriber(subscriber, this.nextSources)); }; - return SampleTimeOperator; + return OnErrorResumeNextOperator; }()); -var SampleTimeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SampleTimeSubscriber, _super); - function SampleTimeSubscriber(destination, period, scheduler) { +var onErrorResumeNext_OnErrorResumeNextSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](OnErrorResumeNextSubscriber, _super); + function OnErrorResumeNextSubscriber(destination, nextSources) { var _this = _super.call(this, destination) || this; - _this.period = period; - _this.scheduler = scheduler; - _this.hasValue = false; - _this.add(scheduler.schedule(dispatchNotification, period, { subscriber: _this, period: period })); + _this.destination = destination; + _this.nextSources = nextSources; return _this; } - SampleTimeSubscriber.prototype._next = function (value) { - this.lastValue = value; - this.hasValue = true; + OnErrorResumeNextSubscriber.prototype.notifyError = function (error, innerSub) { + this.subscribeToNextSource(); }; - SampleTimeSubscriber.prototype.notifyNext = function () { - if (this.hasValue) { - this.hasValue = false; - this.destination.next(this.lastValue); + OnErrorResumeNextSubscriber.prototype.notifyComplete = function (innerSub) { + this.subscribeToNextSource(); + }; + OnErrorResumeNextSubscriber.prototype._error = function (err) { + this.subscribeToNextSource(); + }; + OnErrorResumeNextSubscriber.prototype._complete = function () { + this.subscribeToNextSource(); + }; + OnErrorResumeNextSubscriber.prototype.subscribeToNextSource = function () { + var next = this.nextSources.shift(); + if (next) { + this.add(Object(subscribeToResult["a" /* subscribeToResult */])(this, next)); + } + else { + this.destination.complete(); } }; - return SampleTimeSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -function dispatchNotification(state) { - var subscriber = state.subscriber, period = state.period; - subscriber.notifyNext(); - this.schedule(state, period); -} -//# sourceMappingURL=sampleTime.js.map - - -/***/ }), -/* 347 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = sequenceEqual; -/* unused harmony export SequenceEqualOperator */ -/* unused harmony export SequenceEqualSubscriber */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_errorObject__ = __webpack_require__(13); -/** PURE_IMPORTS_START tslib,_Subscriber,_util_tryCatch,_util_errorObject PURE_IMPORTS_END */ - + return OnErrorResumeNextSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=onErrorResumeNext.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/pairwise.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function sequenceEqual(compareTo, comparor) { - return function (source) { return source.lift(new SequenceEqualOperator(compareTo, comparor)); }; +function pairwise() { + return function (source) { return source.lift(new PairwiseOperator()); }; } -var SequenceEqualOperator = /*@__PURE__*/ (function () { - function SequenceEqualOperator(compareTo, comparor) { - this.compareTo = compareTo; - this.comparor = comparor; +var PairwiseOperator = /*@__PURE__*/ (function () { + function PairwiseOperator() { } - SequenceEqualOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new SequenceEqualSubscriber(subscriber, this.compareTo, this.comparor)); + PairwiseOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new pairwise_PairwiseSubscriber(subscriber)); }; - return SequenceEqualOperator; + return PairwiseOperator; }()); - -var SequenceEqualSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SequenceEqualSubscriber, _super); - function SequenceEqualSubscriber(destination, compareTo, comparor) { +var pairwise_PairwiseSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](PairwiseSubscriber, _super); + function PairwiseSubscriber(destination) { var _this = _super.call(this, destination) || this; - _this.compareTo = compareTo; - _this.comparor = comparor; - _this._a = []; - _this._b = []; - _this._oneComplete = false; - _this.add(compareTo.subscribe(new SequenceEqualCompareToSubscriber(destination, _this))); + _this.hasPrev = false; return _this; } - SequenceEqualSubscriber.prototype._next = function (value) { - if (this._oneComplete && this._b.length === 0) { - this.emit(false); + PairwiseSubscriber.prototype._next = function (value) { + if (this.hasPrev) { + this.destination.next([this.prev, value]); } else { - this._a.push(value); - this.checkValues(); + this.hasPrev = true; } + this.prev = value; }; - SequenceEqualSubscriber.prototype._complete = function () { - if (this._oneComplete) { - this.emit(this._a.length === 0 && this._b.length === 0); - } - else { - this._oneComplete = true; - } + return PairwiseSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=pairwise.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/not.js +/** PURE_IMPORTS_START PURE_IMPORTS_END */ +function not(pred, thisArg) { + function notPred() { + return !(notPred.pred.apply(notPred.thisArg, arguments)); + } + notPred.pred = pred; + notPred.thisArg = thisArg; + return notPred; +} +//# sourceMappingURL=not.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/partition.js +/** PURE_IMPORTS_START _util_not,_filter PURE_IMPORTS_END */ + + +function partition(predicate, thisArg) { + return function (source) { + return [ + filter(predicate, thisArg)(source), + filter(not(predicate, thisArg))(source) + ]; }; - SequenceEqualSubscriber.prototype.checkValues = function () { - var _c = this, _a = _c._a, _b = _c._b, comparor = _c.comparor; - while (_a.length > 0 && _b.length > 0) { - var a = _a.shift(); - var b = _b.shift(); - var areEqual = false; - if (comparor) { - areEqual = Object(__WEBPACK_IMPORTED_MODULE_2__util_tryCatch__["a" /* tryCatch */])(comparor)(a, b); - if (areEqual === __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */]) { - this.destination.error(__WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */].e); - } +} +//# sourceMappingURL=partition.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/pluck.js +/** PURE_IMPORTS_START _map PURE_IMPORTS_END */ + +function pluck() { + var properties = []; + for (var _i = 0; _i < arguments.length; _i++) { + properties[_i] = arguments[_i]; + } + var length = properties.length; + if (length === 0) { + throw new Error('list of properties cannot be empty.'); + } + return function (source) { return Object(map["a" /* map */])(plucker(properties, length))(source); }; +} +function plucker(props, length) { + var mapper = function (x) { + var currentProp = x; + for (var i = 0; i < length; i++) { + var p = currentProp[props[i]]; + if (typeof p !== 'undefined') { + currentProp = p; } else { - areEqual = a === b; - } - if (!areEqual) { - this.emit(false); + return undefined; } } + return currentProp; }; - SequenceEqualSubscriber.prototype.emit = function (value) { - var destination = this.destination; - destination.next(value); - destination.complete(); - }; - SequenceEqualSubscriber.prototype.nextB = function (value) { - if (this._oneComplete && this._a.length === 0) { - this.emit(false); - } - else { - this._b.push(value); - this.checkValues(); - } - }; - return SequenceEqualSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); + return mapper; +} +//# sourceMappingURL=pluck.js.map -var SequenceEqualCompareToSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SequenceEqualCompareToSubscriber, _super); - function SequenceEqualCompareToSubscriber(destination, parent) { - var _this = _super.call(this, destination) || this; - _this.parent = parent; - return _this; - } - SequenceEqualCompareToSubscriber.prototype._next = function (value) { - this.parent.nextB(value); - }; - SequenceEqualCompareToSubscriber.prototype._error = function (err) { - this.parent.error(err); - }; - SequenceEqualCompareToSubscriber.prototype._complete = function () { - this.parent._complete(); - }; - return SequenceEqualCompareToSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=sequenceEqual.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subject.js +var Subject = __webpack_require__(8); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/publish.js +/** PURE_IMPORTS_START _Subject,_multicast PURE_IMPORTS_END */ -/***/ }), -/* 348 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = share; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__multicast__ = __webpack_require__(26); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__refCount__ = __webpack_require__(64); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Subject__ = __webpack_require__(9); -/** PURE_IMPORTS_START _multicast,_refCount,_Subject PURE_IMPORTS_END */ +function publish(selector) { + return selector ? + multicast(function () { return new Subject["a" /* Subject */](); }, selector) : + multicast(new Subject["a" /* Subject */]()); +} +//# sourceMappingURL=publish.js.map + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/BehaviorSubject.js +var BehaviorSubject = __webpack_require__(65); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/publishBehavior.js +/** PURE_IMPORTS_START _BehaviorSubject,_multicast PURE_IMPORTS_END */ -function shareSubjectFactory() { - return new __WEBPACK_IMPORTED_MODULE_2__Subject__["a" /* Subject */](); +function publishBehavior(value) { + return function (source) { return multicast(new BehaviorSubject["a" /* BehaviorSubject */](value))(source); }; } -function share() { - return function (source) { return Object(__WEBPACK_IMPORTED_MODULE_1__refCount__["a" /* refCount */])()(Object(__WEBPACK_IMPORTED_MODULE_0__multicast__["a" /* multicast */])(shareSubjectFactory)(source)); }; +//# sourceMappingURL=publishBehavior.js.map + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/AsyncSubject.js +var AsyncSubject = __webpack_require__(33); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/publishLast.js +/** PURE_IMPORTS_START _AsyncSubject,_multicast PURE_IMPORTS_END */ + + +function publishLast() { + return function (source) { return multicast(new AsyncSubject["a" /* AsyncSubject */]())(source); }; } -//# sourceMappingURL=share.js.map +//# sourceMappingURL=publishLast.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/ReplaySubject.js +var ReplaySubject = __webpack_require__(46); -/***/ }), -/* 349 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/publishReplay.js +/** PURE_IMPORTS_START _ReplaySubject,_multicast PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = shareReplay; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__ReplaySubject__ = __webpack_require__(65); -/** PURE_IMPORTS_START _ReplaySubject PURE_IMPORTS_END */ -function shareReplay(bufferSize, windowTime, scheduler) { - return function (source) { return source.lift(shareReplayOperator(bufferSize, windowTime, scheduler)); }; +function publishReplay(bufferSize, windowTime, selectorOrScheduler, scheduler) { + if (selectorOrScheduler && typeof selectorOrScheduler !== 'function') { + scheduler = selectorOrScheduler; + } + var selector = typeof selectorOrScheduler === 'function' ? selectorOrScheduler : undefined; + var subject = new ReplaySubject["a" /* ReplaySubject */](bufferSize, windowTime, scheduler); + return function (source) { return multicast(function () { return subject; }, selector)(source); }; } -function shareReplayOperator(bufferSize, windowTime, scheduler) { - var subject; - var refCount = 0; - var subscription; - var hasError = false; - var isComplete = false; - return function shareReplayOperation(source) { - refCount++; - if (!subject || hasError) { - hasError = false; - subject = new __WEBPACK_IMPORTED_MODULE_0__ReplaySubject__["a" /* ReplaySubject */](bufferSize, windowTime, scheduler); - subscription = source.subscribe({ - next: function (value) { subject.next(value); }, - error: function (err) { - hasError = true; - subject.error(err); - }, - complete: function () { - isComplete = true; - subject.complete(); - }, - }); +//# sourceMappingURL=publishReplay.js.map + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/race.js +var race = __webpack_require__(70); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/race.js +/** PURE_IMPORTS_START _util_isArray,_observable_race PURE_IMPORTS_END */ + + +function race_race() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i] = arguments[_i]; + } + return function raceOperatorFunction(source) { + if (observables.length === 1 && Object(isArray["a" /* isArray */])(observables[0])) { + observables = observables[0]; } - var innerSub = subject.subscribe(this); - return function () { - refCount--; - innerSub.unsubscribe(); - if (subscription && refCount === 0 && isComplete) { - subscription.unsubscribe(); - } - }; + return source.lift.call(race["a" /* race */].apply(void 0, [source].concat(observables))); }; } -//# sourceMappingURL=shareReplay.js.map - - -/***/ }), -/* 350 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +//# sourceMappingURL=race.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = single; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_EmptyError__ = __webpack_require__(33); -/** PURE_IMPORTS_START tslib,_Subscriber,_util_EmptyError PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/repeat.js +/** PURE_IMPORTS_START tslib,_Subscriber,_observable_empty PURE_IMPORTS_END */ -function single(predicate) { - return function (source) { return source.lift(new SingleOperator(predicate, source)); }; +function repeat(count) { + if (count === void 0) { + count = -1; + } + return function (source) { + if (count === 0) { + return Object(empty["b" /* empty */])(); + } + else if (count < 0) { + return source.lift(new RepeatOperator(-1, source)); + } + else { + return source.lift(new RepeatOperator(count - 1, source)); + } + }; } -var SingleOperator = /*@__PURE__*/ (function () { - function SingleOperator(predicate, source) { - this.predicate = predicate; +var RepeatOperator = /*@__PURE__*/ (function () { + function RepeatOperator(count, source) { + this.count = count; this.source = source; } - SingleOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new SingleSubscriber(subscriber, this.predicate, this.source)); + RepeatOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new repeat_RepeatSubscriber(subscriber, this.count, this.source)); }; - return SingleOperator; + return RepeatOperator; }()); -var SingleSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SingleSubscriber, _super); - function SingleSubscriber(destination, predicate, source) { +var repeat_RepeatSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](RepeatSubscriber, _super); + function RepeatSubscriber(destination, count, source) { var _this = _super.call(this, destination) || this; - _this.predicate = predicate; + _this.count = count; _this.source = source; - _this.seenValue = false; - _this.index = 0; return _this; } - SingleSubscriber.prototype.applySingleValue = function (value) { - if (this.seenValue) { - this.destination.error('Sequence contains more than one element'); - } - else { - this.seenValue = true; - this.singleValue = value; + RepeatSubscriber.prototype.complete = function () { + if (!this.isStopped) { + var _a = this, source = _a.source, count = _a.count; + if (count === 0) { + return _super.prototype.complete.call(this); + } + else if (count > -1) { + this.count = count - 1; + } + source.subscribe(this._unsubscribeAndRecycle()); } }; - SingleSubscriber.prototype._next = function (value) { - var index = this.index++; - if (this.predicate) { - this.tryNext(value, index); - } - else { - this.applySingleValue(value); + return RepeatSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=repeat.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/repeatWhen.js +/** PURE_IMPORTS_START tslib,_Subject,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ + + + + + + +function repeatWhen(notifier) { + return function (source) { return source.lift(new RepeatWhenOperator(notifier)); }; +} +var RepeatWhenOperator = /*@__PURE__*/ (function () { + function RepeatWhenOperator(notifier) { + this.notifier = notifier; + } + RepeatWhenOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new repeatWhen_RepeatWhenSubscriber(subscriber, this.notifier, source)); + }; + return RepeatWhenOperator; +}()); +var repeatWhen_RepeatWhenSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](RepeatWhenSubscriber, _super); + function RepeatWhenSubscriber(destination, notifier, source) { + var _this = _super.call(this, destination) || this; + _this.notifier = notifier; + _this.source = source; + _this.sourceIsBeingSubscribedTo = true; + return _this; + } + RepeatWhenSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.sourceIsBeingSubscribedTo = true; + this.source.subscribe(this); + }; + RepeatWhenSubscriber.prototype.notifyComplete = function (innerSub) { + if (this.sourceIsBeingSubscribedTo === false) { + return _super.prototype.complete.call(this); } }; - SingleSubscriber.prototype.tryNext = function (value, index) { - try { - if (this.predicate(value, index, this.source)) { - this.applySingleValue(value); + RepeatWhenSubscriber.prototype.complete = function () { + this.sourceIsBeingSubscribedTo = false; + if (!this.isStopped) { + if (!this.retries) { + this.subscribeToRetries(); } - } - catch (err) { - this.destination.error(err); + if (!this.retriesSubscription || this.retriesSubscription.closed) { + return _super.prototype.complete.call(this); + } + this._unsubscribeAndRecycle(); + this.notifications.next(); } }; - SingleSubscriber.prototype._complete = function () { - var destination = this.destination; - if (this.index > 0) { - destination.next(this.seenValue ? this.singleValue : undefined); - destination.complete(); + RepeatWhenSubscriber.prototype._unsubscribe = function () { + var _a = this, notifications = _a.notifications, retriesSubscription = _a.retriesSubscription; + if (notifications) { + notifications.unsubscribe(); + this.notifications = null; } - else { - destination.error(new __WEBPACK_IMPORTED_MODULE_2__util_EmptyError__["a" /* EmptyError */]); + if (retriesSubscription) { + retriesSubscription.unsubscribe(); + this.retriesSubscription = null; } + this.retries = null; }; - return SingleSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=single.js.map - - -/***/ }), -/* 351 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = skip; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ - - -function skip(count) { - return function (source) { return source.lift(new SkipOperator(count)); }; -} -var SkipOperator = /*@__PURE__*/ (function () { - function SkipOperator(total) { - this.total = total; - } - SkipOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new SkipSubscriber(subscriber, this.total)); + RepeatWhenSubscriber.prototype._unsubscribeAndRecycle = function () { + var _unsubscribe = this._unsubscribe; + this._unsubscribe = null; + _super.prototype._unsubscribeAndRecycle.call(this); + this._unsubscribe = _unsubscribe; + return this; }; - return SkipOperator; -}()); -var SkipSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SkipSubscriber, _super); - function SkipSubscriber(destination, total) { - var _this = _super.call(this, destination) || this; - _this.total = total; - _this.count = 0; - return _this; - } - SkipSubscriber.prototype._next = function (x) { - if (++this.count > this.total) { - this.destination.next(x); + RepeatWhenSubscriber.prototype.subscribeToRetries = function () { + this.notifications = new Subject["a" /* Subject */](); + var retries = Object(tryCatch["a" /* tryCatch */])(this.notifier)(this.notifications); + if (retries === errorObject["a" /* errorObject */]) { + return _super.prototype.complete.call(this); } + this.retries = retries; + this.retriesSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(this, retries); }; - return SkipSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=skip.js.map - - -/***/ }), -/* 352 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = skipLast; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_ArgumentOutOfRangeError__ = __webpack_require__(32); -/** PURE_IMPORTS_START tslib,_Subscriber,_util_ArgumentOutOfRangeError PURE_IMPORTS_END */ + return RepeatWhenSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=repeatWhen.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/retry.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function skipLast(count) { - return function (source) { return source.lift(new SkipLastOperator(count)); }; +function retry(count) { + if (count === void 0) { + count = -1; + } + return function (source) { return source.lift(new RetryOperator(count, source)); }; } -var SkipLastOperator = /*@__PURE__*/ (function () { - function SkipLastOperator(_skipCount) { - this._skipCount = _skipCount; - if (this._skipCount < 0) { - throw new __WEBPACK_IMPORTED_MODULE_2__util_ArgumentOutOfRangeError__["a" /* ArgumentOutOfRangeError */]; - } +var RetryOperator = /*@__PURE__*/ (function () { + function RetryOperator(count, source) { + this.count = count; + this.source = source; } - SkipLastOperator.prototype.call = function (subscriber, source) { - if (this._skipCount === 0) { - return source.subscribe(new __WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */](subscriber)); - } - else { - return source.subscribe(new SkipLastSubscriber(subscriber, this._skipCount)); - } + RetryOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new retry_RetrySubscriber(subscriber, this.count, this.source)); }; - return SkipLastOperator; + return RetryOperator; }()); -var SkipLastSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SkipLastSubscriber, _super); - function SkipLastSubscriber(destination, _skipCount) { +var retry_RetrySubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](RetrySubscriber, _super); + function RetrySubscriber(destination, count, source) { var _this = _super.call(this, destination) || this; - _this._skipCount = _skipCount; - _this._count = 0; - _this._ring = new Array(_skipCount); + _this.count = count; + _this.source = source; return _this; } - SkipLastSubscriber.prototype._next = function (value) { - var skipCount = this._skipCount; - var count = this._count++; - if (count < skipCount) { - this._ring[count] = value; - } - else { - var currentIndex = count % skipCount; - var ring = this._ring; - var oldValue = ring[currentIndex]; - ring[currentIndex] = value; - this.destination.next(oldValue); + RetrySubscriber.prototype.error = function (err) { + if (!this.isStopped) { + var _a = this, source = _a.source, count = _a.count; + if (count === 0) { + return _super.prototype.error.call(this, err); + } + else if (count > -1) { + this.count = count - 1; + } + source.subscribe(this._unsubscribeAndRecycle()); } }; - return SkipLastSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=skipLast.js.map + return RetrySubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=retry.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/retryWhen.js +/** PURE_IMPORTS_START tslib,_Subject,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -/***/ }), -/* 353 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = skipUntil; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function skipUntil(notifier) { - return function (source) { return source.lift(new SkipUntilOperator(notifier)); }; + +function retryWhen(notifier) { + return function (source) { return source.lift(new RetryWhenOperator(notifier, source)); }; } -var SkipUntilOperator = /*@__PURE__*/ (function () { - function SkipUntilOperator(notifier) { +var RetryWhenOperator = /*@__PURE__*/ (function () { + function RetryWhenOperator(notifier, source) { this.notifier = notifier; + this.source = source; } - SkipUntilOperator.prototype.call = function (destination, source) { - return source.subscribe(new SkipUntilSubscriber(destination, this.notifier)); + RetryWhenOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new retryWhen_RetryWhenSubscriber(subscriber, this.notifier, this.source)); }; - return SkipUntilOperator; + return RetryWhenOperator; }()); -var SkipUntilSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SkipUntilSubscriber, _super); - function SkipUntilSubscriber(destination, notifier) { +var retryWhen_RetryWhenSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](RetryWhenSubscriber, _super); + function RetryWhenSubscriber(destination, notifier, source) { var _this = _super.call(this, destination) || this; - _this.hasValue = false; - _this.add(_this.innerSubscription = Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(_this, notifier)); + _this.notifier = notifier; + _this.source = source; return _this; } - SkipUntilSubscriber.prototype._next = function (value) { - if (this.hasValue) { - _super.prototype._next.call(this, value); + RetryWhenSubscriber.prototype.error = function (err) { + if (!this.isStopped) { + var errors = this.errors; + var retries = this.retries; + var retriesSubscription = this.retriesSubscription; + if (!retries) { + errors = new Subject["a" /* Subject */](); + retries = Object(tryCatch["a" /* tryCatch */])(this.notifier)(errors); + if (retries === errorObject["a" /* errorObject */]) { + return _super.prototype.error.call(this, errorObject["a" /* errorObject */].e); + } + retriesSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(this, retries); + } + else { + this.errors = null; + this.retriesSubscription = null; + } + this._unsubscribeAndRecycle(); + this.errors = errors; + this.retries = retries; + this.retriesSubscription = retriesSubscription; + errors.next(err); } }; - SkipUntilSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.hasValue = true; - if (this.innerSubscription) { - this.innerSubscription.unsubscribe(); + RetryWhenSubscriber.prototype._unsubscribe = function () { + var _a = this, errors = _a.errors, retriesSubscription = _a.retriesSubscription; + if (errors) { + errors.unsubscribe(); + this.errors = null; + } + if (retriesSubscription) { + retriesSubscription.unsubscribe(); + this.retriesSubscription = null; } + this.retries = null; }; - SkipUntilSubscriber.prototype.notifyComplete = function () { + RetryWhenSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + var _unsubscribe = this._unsubscribe; + this._unsubscribe = null; + this._unsubscribeAndRecycle(); + this._unsubscribe = _unsubscribe; + this.source.subscribe(this); }; - return SkipUntilSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=skipUntil.js.map + return RetryWhenSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=retryWhen.js.map +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/refCount.js +var operators_refCount = __webpack_require__(45); -/***/ }), -/* 354 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/sample.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = skipWhile; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function skipWhile(predicate) { - return function (source) { return source.lift(new SkipWhileOperator(predicate)); }; +function sample(notifier) { + return function (source) { return source.lift(new sample_SampleOperator(notifier)); }; } -var SkipWhileOperator = /*@__PURE__*/ (function () { - function SkipWhileOperator(predicate) { - this.predicate = predicate; +var sample_SampleOperator = /*@__PURE__*/ (function () { + function SampleOperator(notifier) { + this.notifier = notifier; } - SkipWhileOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new SkipWhileSubscriber(subscriber, this.predicate)); + SampleOperator.prototype.call = function (subscriber, source) { + var sampleSubscriber = new sample_SampleSubscriber(subscriber); + var subscription = source.subscribe(sampleSubscriber); + subscription.add(Object(subscribeToResult["a" /* subscribeToResult */])(sampleSubscriber, this.notifier)); + return subscription; }; - return SkipWhileOperator; + return SampleOperator; }()); -var SkipWhileSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SkipWhileSubscriber, _super); - function SkipWhileSubscriber(destination, predicate) { - var _this = _super.call(this, destination) || this; - _this.predicate = predicate; - _this.skipping = true; - _this.index = 0; +var sample_SampleSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SampleSubscriber, _super); + function SampleSubscriber() { + var _this = _super !== null && _super.apply(this, arguments) || this; + _this.hasValue = false; return _this; } - SkipWhileSubscriber.prototype._next = function (value) { - var destination = this.destination; - if (this.skipping) { - this.tryCallPredicate(value); - } - if (!this.skipping) { - destination.next(value); - } - }; - SkipWhileSubscriber.prototype.tryCallPredicate = function (value) { - try { - var result = this.predicate(value, this.index++); - this.skipping = Boolean(result); - } - catch (err) { - this.destination.error(err); - } - }; - return SkipWhileSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=skipWhile.js.map - - -/***/ }), -/* 355 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = startWith; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_fromArray__ = __webpack_require__(20); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__observable_scalar__ = __webpack_require__(67); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__observable_empty__ = __webpack_require__(11); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__observable_concat__ = __webpack_require__(47); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_isScheduler__ = __webpack_require__(14); -/** PURE_IMPORTS_START _observable_fromArray,_observable_scalar,_observable_empty,_observable_concat,_util_isScheduler PURE_IMPORTS_END */ - - - - - -function startWith() { - var array = []; - for (var _i = 0; _i < arguments.length; _i++) { - array[_i] = arguments[_i]; - } - return function (source) { - var scheduler = array[array.length - 1]; - if (Object(__WEBPACK_IMPORTED_MODULE_4__util_isScheduler__["a" /* isScheduler */])(scheduler)) { - array.pop(); - } - else { - scheduler = null; - } - var len = array.length; - if (len === 1 && !scheduler) { - return Object(__WEBPACK_IMPORTED_MODULE_3__observable_concat__["a" /* concat */])(Object(__WEBPACK_IMPORTED_MODULE_1__observable_scalar__["a" /* scalar */])(array[0]), source); - } - else if (len > 0) { - return Object(__WEBPACK_IMPORTED_MODULE_3__observable_concat__["a" /* concat */])(Object(__WEBPACK_IMPORTED_MODULE_0__observable_fromArray__["a" /* fromArray */])(array, scheduler), source); - } - else { - return Object(__WEBPACK_IMPORTED_MODULE_3__observable_concat__["a" /* concat */])(Object(__WEBPACK_IMPORTED_MODULE_2__observable_empty__["b" /* empty */])(scheduler), source); + SampleSubscriber.prototype._next = function (value) { + this.value = value; + this.hasValue = true; + }; + SampleSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.emitValue(); + }; + SampleSubscriber.prototype.notifyComplete = function () { + this.emitValue(); + }; + SampleSubscriber.prototype.emitValue = function () { + if (this.hasValue) { + this.hasValue = false; + this.destination.next(this.value); } }; -} -//# sourceMappingURL=startWith.js.map + return SampleSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=sample.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/sampleTime.js +/** PURE_IMPORTS_START tslib,_Subscriber,_scheduler_async PURE_IMPORTS_END */ -/***/ }), -/* 356 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = subscribeOn; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_SubscribeOnObservable__ = __webpack_require__(357); -/** PURE_IMPORTS_START _observable_SubscribeOnObservable PURE_IMPORTS_END */ -function subscribeOn(scheduler, delay) { - if (delay === void 0) { - delay = 0; +function sampleTime(period, scheduler) { + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; } - return function subscribeOnOperatorFunction(source) { - return source.lift(new SubscribeOnOperator(scheduler, delay)); - }; + return function (source) { return source.lift(new SampleTimeOperator(period, scheduler)); }; } -var SubscribeOnOperator = /*@__PURE__*/ (function () { - function SubscribeOnOperator(scheduler, delay) { +var SampleTimeOperator = /*@__PURE__*/ (function () { + function SampleTimeOperator(period, scheduler) { + this.period = period; this.scheduler = scheduler; - this.delay = delay; } - SubscribeOnOperator.prototype.call = function (subscriber, source) { - return new __WEBPACK_IMPORTED_MODULE_0__observable_SubscribeOnObservable__["a" /* SubscribeOnObservable */](source, this.delay, this.scheduler).subscribe(subscriber); + SampleTimeOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new sampleTime_SampleTimeSubscriber(subscriber, this.period, this.scheduler)); }; - return SubscribeOnOperator; + return SampleTimeOperator; }()); -//# sourceMappingURL=subscribeOn.js.map - +var sampleTime_SampleTimeSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SampleTimeSubscriber, _super); + function SampleTimeSubscriber(destination, period, scheduler) { + var _this = _super.call(this, destination) || this; + _this.period = period; + _this.scheduler = scheduler; + _this.hasValue = false; + _this.add(scheduler.schedule(dispatchNotification, period, { subscriber: _this, period: period })); + return _this; + } + SampleTimeSubscriber.prototype._next = function (value) { + this.lastValue = value; + this.hasValue = true; + }; + SampleTimeSubscriber.prototype.notifyNext = function () { + if (this.hasValue) { + this.hasValue = false; + this.destination.next(this.lastValue); + } + }; + return SampleTimeSubscriber; +}(Subscriber["a" /* Subscriber */])); +function dispatchNotification(state) { + var subscriber = state.subscriber, period = state.period; + subscriber.notifyNext(); + this.schedule(state, period); +} +//# sourceMappingURL=sampleTime.js.map -/***/ }), -/* 357 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/sequenceEqual.js +/** PURE_IMPORTS_START tslib,_Subscriber,_util_tryCatch,_util_errorObject PURE_IMPORTS_END */ -"use strict"; -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return SubscribeOnObservable; }); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Observable__ = __webpack_require__(3); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__scheduler_asap__ = __webpack_require__(113); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_isNumeric__ = __webpack_require__(48); -/** PURE_IMPORTS_START tslib,_Observable,_scheduler_asap,_util_isNumeric PURE_IMPORTS_END */ +function sequenceEqual(compareTo, comparor) { + return function (source) { return source.lift(new SequenceEqualOperator(compareTo, comparor)); }; +} +var SequenceEqualOperator = /*@__PURE__*/ (function () { + function SequenceEqualOperator(compareTo, comparor) { + this.compareTo = compareTo; + this.comparor = comparor; + } + SequenceEqualOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new sequenceEqual_SequenceEqualSubscriber(subscriber, this.compareTo, this.comparor)); + }; + return SequenceEqualOperator; +}()); -var SubscribeOnObservable = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](SubscribeOnObservable, _super); - function SubscribeOnObservable(source, delayTime, scheduler) { - if (delayTime === void 0) { - delayTime = 0; - } - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_2__scheduler_asap__["a" /* asap */]; +var sequenceEqual_SequenceEqualSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SequenceEqualSubscriber, _super); + function SequenceEqualSubscriber(destination, compareTo, comparor) { + var _this = _super.call(this, destination) || this; + _this.compareTo = compareTo; + _this.comparor = comparor; + _this._a = []; + _this._b = []; + _this._oneComplete = false; + _this.add(compareTo.subscribe(new sequenceEqual_SequenceEqualCompareToSubscriber(destination, _this))); + return _this; + } + SequenceEqualSubscriber.prototype._next = function (value) { + if (this._oneComplete && this._b.length === 0) { + this.emit(false); } - var _this = _super.call(this) || this; - _this.source = source; - _this.delayTime = delayTime; - _this.scheduler = scheduler; - if (!Object(__WEBPACK_IMPORTED_MODULE_3__util_isNumeric__["a" /* isNumeric */])(delayTime) || delayTime < 0) { - _this.delayTime = 0; + else { + this._a.push(value); + this.checkValues(); } - if (!scheduler || typeof scheduler.schedule !== 'function') { - _this.scheduler = __WEBPACK_IMPORTED_MODULE_2__scheduler_asap__["a" /* asap */]; + }; + SequenceEqualSubscriber.prototype._complete = function () { + if (this._oneComplete) { + this.emit(this._a.length === 0 && this._b.length === 0); } - return _this; - } - SubscribeOnObservable.create = function (source, delay, scheduler) { - if (delay === void 0) { - delay = 0; + else { + this._oneComplete = true; } - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_2__scheduler_asap__["a" /* asap */]; + }; + SequenceEqualSubscriber.prototype.checkValues = function () { + var _c = this, _a = _c._a, _b = _c._b, comparor = _c.comparor; + while (_a.length > 0 && _b.length > 0) { + var a = _a.shift(); + var b = _b.shift(); + var areEqual = false; + if (comparor) { + areEqual = Object(tryCatch["a" /* tryCatch */])(comparor)(a, b); + if (areEqual === errorObject["a" /* errorObject */]) { + this.destination.error(errorObject["a" /* errorObject */].e); + } + } + else { + areEqual = a === b; + } + if (!areEqual) { + this.emit(false); + } } - return new SubscribeOnObservable(source, delay, scheduler); }; - SubscribeOnObservable.dispatch = function (arg) { - var source = arg.source, subscriber = arg.subscriber; - return this.add(source.subscribe(subscriber)); + SequenceEqualSubscriber.prototype.emit = function (value) { + var destination = this.destination; + destination.next(value); + destination.complete(); }; - SubscribeOnObservable.prototype._subscribe = function (subscriber) { - var delay = this.delayTime; - var source = this.source; - var scheduler = this.scheduler; - return scheduler.schedule(SubscribeOnObservable.dispatch, delay, { - source: source, subscriber: subscriber - }); + SequenceEqualSubscriber.prototype.nextB = function (value) { + if (this._oneComplete && this._a.length === 0) { + this.emit(false); + } + else { + this._b.push(value); + this.checkValues(); + } }; - return SubscribeOnObservable; -}(__WEBPACK_IMPORTED_MODULE_1__Observable__["a" /* Observable */])); - -//# sourceMappingURL=SubscribeOnObservable.js.map + return SequenceEqualSubscriber; +}(Subscriber["a" /* Subscriber */])); +var sequenceEqual_SequenceEqualCompareToSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SequenceEqualCompareToSubscriber, _super); + function SequenceEqualCompareToSubscriber(destination, parent) { + var _this = _super.call(this, destination) || this; + _this.parent = parent; + return _this; + } + SequenceEqualCompareToSubscriber.prototype._next = function (value) { + this.parent.nextB(value); + }; + SequenceEqualCompareToSubscriber.prototype._error = function (err) { + this.parent.error(err); + }; + SequenceEqualCompareToSubscriber.prototype._complete = function () { + this.parent._complete(); + }; + return SequenceEqualCompareToSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=sequenceEqual.js.map -/***/ }), -/* 358 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/share.js +/** PURE_IMPORTS_START _multicast,_refCount,_Subject PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = switchAll; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__switchMap__ = __webpack_require__(76); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_identity__ = __webpack_require__(25); -/** PURE_IMPORTS_START _switchMap,_util_identity PURE_IMPORTS_END */ -function switchAll() { - return Object(__WEBPACK_IMPORTED_MODULE_0__switchMap__["a" /* switchMap */])(__WEBPACK_IMPORTED_MODULE_1__util_identity__["a" /* identity */]); +function shareSubjectFactory() { + return new Subject["a" /* Subject */](); } -//# sourceMappingURL=switchAll.js.map - - -/***/ }), -/* 359 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = switchMapTo; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__switchMap__ = __webpack_require__(76); -/** PURE_IMPORTS_START _switchMap PURE_IMPORTS_END */ - -function switchMapTo(innerObservable, resultSelector) { - return resultSelector ? Object(__WEBPACK_IMPORTED_MODULE_0__switchMap__["a" /* switchMap */])(function () { return innerObservable; }, resultSelector) : Object(__WEBPACK_IMPORTED_MODULE_0__switchMap__["a" /* switchMap */])(function () { return innerObservable; }); +function share() { + return function (source) { return Object(operators_refCount["a" /* refCount */])()(multicast(shareSubjectFactory)(source)); }; } -//# sourceMappingURL=switchMapTo.js.map - - -/***/ }), -/* 360 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = takeUntil; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - +//# sourceMappingURL=share.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/shareReplay.js +/** PURE_IMPORTS_START _ReplaySubject PURE_IMPORTS_END */ -function takeUntil(notifier) { - return function (source) { return source.lift(new TakeUntilOperator(notifier)); }; +function shareReplay(bufferSize, windowTime, scheduler) { + return function (source) { return source.lift(shareReplayOperator(bufferSize, windowTime, scheduler)); }; } -var TakeUntilOperator = /*@__PURE__*/ (function () { - function TakeUntilOperator(notifier) { - this.notifier = notifier; - } - TakeUntilOperator.prototype.call = function (subscriber, source) { - var takeUntilSubscriber = new TakeUntilSubscriber(subscriber); - var notifierSubscription = Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(takeUntilSubscriber, this.notifier); - if (notifierSubscription && !notifierSubscription.closed) { - takeUntilSubscriber.add(notifierSubscription); - return source.subscribe(takeUntilSubscriber); +function shareReplayOperator(bufferSize, windowTime, scheduler) { + var subject; + var refCount = 0; + var subscription; + var hasError = false; + var isComplete = false; + return function shareReplayOperation(source) { + refCount++; + if (!subject || hasError) { + hasError = false; + subject = new ReplaySubject["a" /* ReplaySubject */](bufferSize, windowTime, scheduler); + subscription = source.subscribe({ + next: function (value) { subject.next(value); }, + error: function (err) { + hasError = true; + subject.error(err); + }, + complete: function () { + isComplete = true; + subject.complete(); + }, + }); } - return takeUntilSubscriber; - }; - return TakeUntilOperator; -}()); -var TakeUntilSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](TakeUntilSubscriber, _super); - function TakeUntilSubscriber(destination) { - return _super.call(this, destination) || this; - } - TakeUntilSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.complete(); - }; - TakeUntilSubscriber.prototype.notifyComplete = function () { + var innerSub = subject.subscribe(this); + return function () { + refCount--; + innerSub.unsubscribe(); + if (subscription && refCount === 0 && isComplete) { + subscription.unsubscribe(); + } + }; }; - return TakeUntilSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=takeUntil.js.map - +} +//# sourceMappingURL=shareReplay.js.map -/***/ }), -/* 361 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/single.js +/** PURE_IMPORTS_START tslib,_Subscriber,_util_EmptyError PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = takeWhile; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function takeWhile(predicate) { - return function (source) { return source.lift(new TakeWhileOperator(predicate)); }; +function single(predicate) { + return function (source) { return source.lift(new SingleOperator(predicate, source)); }; } -var TakeWhileOperator = /*@__PURE__*/ (function () { - function TakeWhileOperator(predicate) { +var SingleOperator = /*@__PURE__*/ (function () { + function SingleOperator(predicate, source) { this.predicate = predicate; + this.source = source; } - TakeWhileOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new TakeWhileSubscriber(subscriber, this.predicate)); + SingleOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new single_SingleSubscriber(subscriber, this.predicate, this.source)); }; - return TakeWhileOperator; + return SingleOperator; }()); -var TakeWhileSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](TakeWhileSubscriber, _super); - function TakeWhileSubscriber(destination, predicate) { +var single_SingleSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SingleSubscriber, _super); + function SingleSubscriber(destination, predicate, source) { var _this = _super.call(this, destination) || this; _this.predicate = predicate; + _this.source = source; + _this.seenValue = false; _this.index = 0; return _this; } - TakeWhileSubscriber.prototype._next = function (value) { - var destination = this.destination; - var result; - try { - result = this.predicate(value, this.index++); + SingleSubscriber.prototype.applySingleValue = function (value) { + if (this.seenValue) { + this.destination.error('Sequence contains more than one element'); } - catch (err) { - destination.error(err); - return; + else { + this.seenValue = true; + this.singleValue = value; } - this.nextOrComplete(value, result); }; - TakeWhileSubscriber.prototype.nextOrComplete = function (value, predicateResult) { - var destination = this.destination; - if (Boolean(predicateResult)) { - destination.next(value); + SingleSubscriber.prototype._next = function (value) { + var index = this.index++; + if (this.predicate) { + this.tryNext(value, index); } else { - destination.complete(); + this.applySingleValue(value); } }; - return TakeWhileSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=takeWhile.js.map - - -/***/ }), -/* 362 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = throttleTime; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__throttle__ = __webpack_require__(132); -/** PURE_IMPORTS_START tslib,_Subscriber,_scheduler_async,_throttle PURE_IMPORTS_END */ - - - - -function throttleTime(duration, scheduler, config) { - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_2__scheduler_async__["a" /* async */]; - } - if (config === void 0) { - config = __WEBPACK_IMPORTED_MODULE_3__throttle__["a" /* defaultThrottleConfig */]; - } - return function (source) { return source.lift(new ThrottleTimeOperator(duration, scheduler, config.leading, config.trailing)); }; -} -var ThrottleTimeOperator = /*@__PURE__*/ (function () { - function ThrottleTimeOperator(duration, scheduler, leading, trailing) { - this.duration = duration; - this.scheduler = scheduler; - this.leading = leading; - this.trailing = trailing; - } - ThrottleTimeOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new ThrottleTimeSubscriber(subscriber, this.duration, this.scheduler, this.leading, this.trailing)); - }; - return ThrottleTimeOperator; -}()); -var ThrottleTimeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](ThrottleTimeSubscriber, _super); - function ThrottleTimeSubscriber(destination, duration, scheduler, leading, trailing) { - var _this = _super.call(this, destination) || this; - _this.duration = duration; - _this.scheduler = scheduler; - _this.leading = leading; - _this.trailing = trailing; - _this._hasTrailingValue = false; - _this._trailingValue = null; - return _this; - } - ThrottleTimeSubscriber.prototype._next = function (value) { - if (this.throttled) { - if (this.trailing) { - this._trailingValue = value; - this._hasTrailingValue = true; + SingleSubscriber.prototype.tryNext = function (value, index) { + try { + if (this.predicate(value, index, this.source)) { + this.applySingleValue(value); } } - else { - this.add(this.throttled = this.scheduler.schedule(dispatchNext, this.duration, { subscriber: this })); - if (this.leading) { - this.destination.next(value); - } + catch (err) { + this.destination.error(err); } }; - ThrottleTimeSubscriber.prototype._complete = function () { - if (this._hasTrailingValue) { - this.destination.next(this._trailingValue); - this.destination.complete(); + SingleSubscriber.prototype._complete = function () { + var destination = this.destination; + if (this.index > 0) { + destination.next(this.seenValue ? this.singleValue : undefined); + destination.complete(); } else { - this.destination.complete(); - } - }; - ThrottleTimeSubscriber.prototype.clearThrottle = function () { - var throttled = this.throttled; - if (throttled) { - if (this.trailing && this._hasTrailingValue) { - this.destination.next(this._trailingValue); - this._trailingValue = null; - this._hasTrailingValue = false; - } - throttled.unsubscribe(); - this.remove(throttled); - this.throttled = null; + destination.error(new EmptyError["a" /* EmptyError */]); } }; - return ThrottleTimeSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -function dispatchNext(arg) { - var subscriber = arg.subscriber; - subscriber.clearThrottle(); -} -//# sourceMappingURL=throttleTime.js.map - - -/***/ }), -/* 363 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = timeInterval; -/* unused harmony export TimeInterval */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__scan__ = __webpack_require__(75); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__observable_defer__ = __webpack_require__(71); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__map__ = __webpack_require__(15); -/** PURE_IMPORTS_START _scheduler_async,_scan,_observable_defer,_map PURE_IMPORTS_END */ - + return SingleSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=single.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/skip.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function timeInterval(scheduler) { - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_0__scheduler_async__["a" /* async */]; - } - return function (source) { - return Object(__WEBPACK_IMPORTED_MODULE_2__observable_defer__["a" /* defer */])(function () { - return source.pipe(Object(__WEBPACK_IMPORTED_MODULE_1__scan__["a" /* scan */])(function (_a, value) { - var current = _a.current; - return ({ value: value, current: scheduler.now(), last: current }); - }, { current: scheduler.now(), value: undefined, last: undefined }), Object(__WEBPACK_IMPORTED_MODULE_3__map__["a" /* map */])(function (_a) { - var current = _a.current, last = _a.last, value = _a.value; - return new TimeInterval(value, current - last); - })); - }); - }; +function skip(count) { + return function (source) { return source.lift(new SkipOperator(count)); }; } -var TimeInterval = /*@__PURE__*/ (function () { - function TimeInterval(value, interval) { - this.value = value; - this.interval = interval; +var SkipOperator = /*@__PURE__*/ (function () { + function SkipOperator(total) { + this.total = total; } - return TimeInterval; + SkipOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new skip_SkipSubscriber(subscriber, this.total)); + }; + return SkipOperator; }()); - -//# sourceMappingURL=timeInterval.js.map - - -/***/ }), -/* 364 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = timeout; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util_TimeoutError__ = __webpack_require__(114); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__timeoutWith__ = __webpack_require__(133); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__observable_throwError__ = __webpack_require__(68); -/** PURE_IMPORTS_START _scheduler_async,_util_TimeoutError,_timeoutWith,_observable_throwError PURE_IMPORTS_END */ - - - - -function timeout(due, scheduler) { - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_0__scheduler_async__["a" /* async */]; +var skip_SkipSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SkipSubscriber, _super); + function SkipSubscriber(destination, total) { + var _this = _super.call(this, destination) || this; + _this.total = total; + _this.count = 0; + return _this; } - return Object(__WEBPACK_IMPORTED_MODULE_2__timeoutWith__["a" /* timeoutWith */])(due, Object(__WEBPACK_IMPORTED_MODULE_3__observable_throwError__["a" /* throwError */])(new __WEBPACK_IMPORTED_MODULE_1__util_TimeoutError__["a" /* TimeoutError */]()), scheduler); -} -//# sourceMappingURL=timeout.js.map - + SkipSubscriber.prototype._next = function (x) { + if (++this.count > this.total) { + this.destination.next(x); + } + }; + return SkipSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=skip.js.map -/***/ }), -/* 365 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/skipLast.js +/** PURE_IMPORTS_START tslib,_Subscriber,_util_ArgumentOutOfRangeError PURE_IMPORTS_END */ -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = timestamp; -/* unused harmony export Timestamp */ -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__map__ = __webpack_require__(15); -/** PURE_IMPORTS_START _scheduler_async,_map PURE_IMPORTS_END */ -function timestamp(scheduler) { - if (scheduler === void 0) { - scheduler = __WEBPACK_IMPORTED_MODULE_0__scheduler_async__["a" /* async */]; - } - return Object(__WEBPACK_IMPORTED_MODULE_1__map__["a" /* map */])(function (value) { return new Timestamp(value, scheduler.now()); }); +function skipLast(count) { + return function (source) { return source.lift(new skipLast_SkipLastOperator(count)); }; } -var Timestamp = /*@__PURE__*/ (function () { - function Timestamp(value, timestamp) { - this.value = value; - this.timestamp = timestamp; - } - return Timestamp; -}()); - -//# sourceMappingURL=timestamp.js.map - - -/***/ }), -/* 366 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = toArray; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__reduce__ = __webpack_require__(50); -/** PURE_IMPORTS_START _reduce PURE_IMPORTS_END */ - -function toArrayReducer(arr, item, index) { - if (index === 0) { - return [item]; +var skipLast_SkipLastOperator = /*@__PURE__*/ (function () { + function SkipLastOperator(_skipCount) { + this._skipCount = _skipCount; + if (this._skipCount < 0) { + throw new ArgumentOutOfRangeError["a" /* ArgumentOutOfRangeError */]; + } } - arr.push(item); - return arr; -} -function toArray() { - return Object(__WEBPACK_IMPORTED_MODULE_0__reduce__["a" /* reduce */])(toArrayReducer, []); -} -//# sourceMappingURL=toArray.js.map - - -/***/ }), -/* 367 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = window; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_Subject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ + SkipLastOperator.prototype.call = function (subscriber, source) { + if (this._skipCount === 0) { + return source.subscribe(new Subscriber["a" /* Subscriber */](subscriber)); + } + else { + return source.subscribe(new skipLast_SkipLastSubscriber(subscriber, this._skipCount)); + } + }; + return SkipLastOperator; +}()); +var skipLast_SkipLastSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SkipLastSubscriber, _super); + function SkipLastSubscriber(destination, _skipCount) { + var _this = _super.call(this, destination) || this; + _this._skipCount = _skipCount; + _this._count = 0; + _this._ring = new Array(_skipCount); + return _this; + } + SkipLastSubscriber.prototype._next = function (value) { + var skipCount = this._skipCount; + var count = this._count++; + if (count < skipCount) { + this._ring[count] = value; + } + else { + var currentIndex = count % skipCount; + var ring = this._ring; + var oldValue = ring[currentIndex]; + ring[currentIndex] = value; + this.destination.next(oldValue); + } + }; + return SkipLastSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=skipLast.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/skipUntil.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function window(windowBoundaries) { - return function windowOperatorFunction(source) { - return source.lift(new WindowOperator(windowBoundaries)); - }; +function skipUntil(notifier) { + return function (source) { return source.lift(new SkipUntilOperator(notifier)); }; } -var WindowOperator = /*@__PURE__*/ (function () { - function WindowOperator(windowBoundaries) { - this.windowBoundaries = windowBoundaries; +var SkipUntilOperator = /*@__PURE__*/ (function () { + function SkipUntilOperator(notifier) { + this.notifier = notifier; } - WindowOperator.prototype.call = function (subscriber, source) { - var windowSubscriber = new WindowSubscriber(subscriber); - var sourceSubscription = source.subscribe(windowSubscriber); - if (!sourceSubscription.closed) { - windowSubscriber.add(Object(__WEBPACK_IMPORTED_MODULE_3__util_subscribeToResult__["a" /* subscribeToResult */])(windowSubscriber, this.windowBoundaries)); - } - return sourceSubscription; + SkipUntilOperator.prototype.call = function (destination, source) { + return source.subscribe(new skipUntil_SkipUntilSubscriber(destination, this.notifier)); }; - return WindowOperator; + return SkipUntilOperator; }()); -var WindowSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](WindowSubscriber, _super); - function WindowSubscriber(destination) { +var skipUntil_SkipUntilSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SkipUntilSubscriber, _super); + function SkipUntilSubscriber(destination, notifier) { var _this = _super.call(this, destination) || this; - _this.window = new __WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */](); - destination.next(_this.window); + _this.hasValue = false; + _this.add(_this.innerSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(_this, notifier)); return _this; } - WindowSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.openWindow(); - }; - WindowSubscriber.prototype.notifyError = function (error, innerSub) { - this._error(error); - }; - WindowSubscriber.prototype.notifyComplete = function (innerSub) { - this._complete(); - }; - WindowSubscriber.prototype._next = function (value) { - this.window.next(value); - }; - WindowSubscriber.prototype._error = function (err) { - this.window.error(err); - this.destination.error(err); - }; - WindowSubscriber.prototype._complete = function () { - this.window.complete(); - this.destination.complete(); - }; - WindowSubscriber.prototype._unsubscribe = function () { - this.window = null; + SkipUntilSubscriber.prototype._next = function (value) { + if (this.hasValue) { + _super.prototype._next.call(this, value); + } }; - WindowSubscriber.prototype.openWindow = function () { - var prevWindow = this.window; - if (prevWindow) { - prevWindow.complete(); + SkipUntilSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.hasValue = true; + if (this.innerSubscription) { + this.innerSubscription.unsubscribe(); } - var destination = this.destination; - var newWindow = this.window = new __WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */](); - destination.next(newWindow); }; - return WindowSubscriber; -}(__WEBPACK_IMPORTED_MODULE_2__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=window.js.map - - -/***/ }), -/* 368 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = windowCount; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Subject__ = __webpack_require__(9); -/** PURE_IMPORTS_START tslib,_Subscriber,_Subject PURE_IMPORTS_END */ + SkipUntilSubscriber.prototype.notifyComplete = function () { + }; + return SkipUntilSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=skipUntil.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/skipWhile.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ -function windowCount(windowSize, startWindowEvery) { - if (startWindowEvery === void 0) { - startWindowEvery = 0; - } - return function windowCountOperatorFunction(source) { - return source.lift(new WindowCountOperator(windowSize, startWindowEvery)); - }; +function skipWhile(predicate) { + return function (source) { return source.lift(new SkipWhileOperator(predicate)); }; } -var WindowCountOperator = /*@__PURE__*/ (function () { - function WindowCountOperator(windowSize, startWindowEvery) { - this.windowSize = windowSize; - this.startWindowEvery = startWindowEvery; +var SkipWhileOperator = /*@__PURE__*/ (function () { + function SkipWhileOperator(predicate) { + this.predicate = predicate; } - WindowCountOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new WindowCountSubscriber(subscriber, this.windowSize, this.startWindowEvery)); + SkipWhileOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new skipWhile_SkipWhileSubscriber(subscriber, this.predicate)); }; - return WindowCountOperator; + return SkipWhileOperator; }()); -var WindowCountSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](WindowCountSubscriber, _super); - function WindowCountSubscriber(destination, windowSize, startWindowEvery) { +var skipWhile_SkipWhileSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SkipWhileSubscriber, _super); + function SkipWhileSubscriber(destination, predicate) { var _this = _super.call(this, destination) || this; - _this.destination = destination; - _this.windowSize = windowSize; - _this.startWindowEvery = startWindowEvery; - _this.windows = [new __WEBPACK_IMPORTED_MODULE_2__Subject__["a" /* Subject */]()]; - _this.count = 0; - destination.next(_this.windows[0]); + _this.predicate = predicate; + _this.skipping = true; + _this.index = 0; return _this; } - WindowCountSubscriber.prototype._next = function (value) { - var startWindowEvery = (this.startWindowEvery > 0) ? this.startWindowEvery : this.windowSize; + SkipWhileSubscriber.prototype._next = function (value) { var destination = this.destination; - var windowSize = this.windowSize; - var windows = this.windows; - var len = windows.length; - for (var i = 0; i < len && !this.closed; i++) { - windows[i].next(value); - } - var c = this.count - windowSize + 1; - if (c >= 0 && c % startWindowEvery === 0 && !this.closed) { - windows.shift().complete(); + if (this.skipping) { + this.tryCallPredicate(value); } - if (++this.count % startWindowEvery === 0 && !this.closed) { - var window_1 = new __WEBPACK_IMPORTED_MODULE_2__Subject__["a" /* Subject */](); - windows.push(window_1); - destination.next(window_1); + if (!this.skipping) { + destination.next(value); } }; - WindowCountSubscriber.prototype._error = function (err) { - var windows = this.windows; - if (windows) { - while (windows.length > 0 && !this.closed) { - windows.shift().error(err); - } + SkipWhileSubscriber.prototype.tryCallPredicate = function (value) { + try { + var result = this.predicate(value, this.index++); + this.skipping = Boolean(result); } - this.destination.error(err); - }; - WindowCountSubscriber.prototype._complete = function () { - var windows = this.windows; - if (windows) { - while (windows.length > 0 && !this.closed) { - windows.shift().complete(); - } + catch (err) { + this.destination.error(err); } - this.destination.complete(); }; - WindowCountSubscriber.prototype._unsubscribe = function () { - this.count = 0; - this.windows = null; - }; - return WindowCountSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__Subscriber__["a" /* Subscriber */])); -//# sourceMappingURL=windowCount.js.map - - -/***/ }), -/* 369 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = windowTime; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__scheduler_async__ = __webpack_require__(12); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Subscriber__ = __webpack_require__(1); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_isNumeric__ = __webpack_require__(48); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_isScheduler__ = __webpack_require__(14); -/** PURE_IMPORTS_START tslib,_Subject,_scheduler_async,_Subscriber,_util_isNumeric,_util_isScheduler PURE_IMPORTS_END */ + return SkipWhileSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=skipWhile.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/startWith.js +/** PURE_IMPORTS_START _observable_fromArray,_observable_scalar,_observable_empty,_observable_concat,_util_isScheduler PURE_IMPORTS_END */ -function windowTime(windowTimeSpan) { - var scheduler = __WEBPACK_IMPORTED_MODULE_2__scheduler_async__["a" /* async */]; - var windowCreationInterval = null; - var maxWindowSize = Number.POSITIVE_INFINITY; - if (Object(__WEBPACK_IMPORTED_MODULE_5__util_isScheduler__["a" /* isScheduler */])(arguments[3])) { - scheduler = arguments[3]; - } - if (Object(__WEBPACK_IMPORTED_MODULE_5__util_isScheduler__["a" /* isScheduler */])(arguments[2])) { - scheduler = arguments[2]; - } - else if (Object(__WEBPACK_IMPORTED_MODULE_4__util_isNumeric__["a" /* isNumeric */])(arguments[2])) { - maxWindowSize = arguments[2]; - } - if (Object(__WEBPACK_IMPORTED_MODULE_5__util_isScheduler__["a" /* isScheduler */])(arguments[1])) { - scheduler = arguments[1]; - } - else if (Object(__WEBPACK_IMPORTED_MODULE_4__util_isNumeric__["a" /* isNumeric */])(arguments[1])) { - windowCreationInterval = arguments[1]; - } - return function windowTimeOperatorFunction(source) { - return source.lift(new WindowTimeOperator(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler)); - }; -} -var WindowTimeOperator = /*@__PURE__*/ (function () { - function WindowTimeOperator(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler) { - this.windowTimeSpan = windowTimeSpan; - this.windowCreationInterval = windowCreationInterval; - this.maxWindowSize = maxWindowSize; - this.scheduler = scheduler; - } - WindowTimeOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new WindowTimeSubscriber(subscriber, this.windowTimeSpan, this.windowCreationInterval, this.maxWindowSize, this.scheduler)); - }; - return WindowTimeOperator; -}()); -var CountedSubject = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](CountedSubject, _super); - function CountedSubject() { - var _this = _super !== null && _super.apply(this, arguments) || this; - _this._numberOfNextedValues = 0; - return _this; +function startWith() { + var array = []; + for (var _i = 0; _i < arguments.length; _i++) { + array[_i] = arguments[_i]; } - CountedSubject.prototype.next = function (value) { - this._numberOfNextedValues++; - _super.prototype.next.call(this, value); - }; - Object.defineProperty(CountedSubject.prototype, "numberOfNextedValues", { - get: function () { - return this._numberOfNextedValues; - }, - enumerable: true, - configurable: true - }); - return CountedSubject; -}(__WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */])); -var WindowTimeSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](WindowTimeSubscriber, _super); - function WindowTimeSubscriber(destination, windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler) { - var _this = _super.call(this, destination) || this; - _this.destination = destination; - _this.windowTimeSpan = windowTimeSpan; - _this.windowCreationInterval = windowCreationInterval; - _this.maxWindowSize = maxWindowSize; - _this.scheduler = scheduler; - _this.windows = []; - var window = _this.openWindow(); - if (windowCreationInterval !== null && windowCreationInterval >= 0) { - var closeState = { subscriber: _this, window: window, context: null }; - var creationState = { windowTimeSpan: windowTimeSpan, windowCreationInterval: windowCreationInterval, subscriber: _this, scheduler: scheduler }; - _this.add(scheduler.schedule(dispatchWindowClose, windowTimeSpan, closeState)); - _this.add(scheduler.schedule(dispatchWindowCreation, windowCreationInterval, creationState)); + return function (source) { + var scheduler = array[array.length - 1]; + if (Object(isScheduler["a" /* isScheduler */])(scheduler)) { + array.pop(); + } + else { + scheduler = null; + } + var len = array.length; + if (len === 1 && !scheduler) { + return Object(concat["a" /* concat */])(Object(scalar["a" /* scalar */])(array[0]), source); + } + else if (len > 0) { + return Object(concat["a" /* concat */])(Object(fromArray["a" /* fromArray */])(array, scheduler), source); } else { - var timeSpanOnlyState = { subscriber: _this, window: window, windowTimeSpan: windowTimeSpan }; - _this.add(scheduler.schedule(dispatchWindowTimeSpanOnly, windowTimeSpan, timeSpanOnlyState)); + return Object(concat["a" /* concat */])(Object(empty["b" /* empty */])(scheduler), source); + } + }; +} +//# sourceMappingURL=startWith.js.map + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/asap.js + 3 modules +var asap = __webpack_require__(54); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isNumeric.js +var isNumeric = __webpack_require__(35); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/SubscribeOnObservable.js +/** PURE_IMPORTS_START tslib,_Observable,_scheduler_asap,_util_isNumeric PURE_IMPORTS_END */ + + + + +var SubscribeOnObservable_SubscribeOnObservable = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SubscribeOnObservable, _super); + function SubscribeOnObservable(source, delayTime, scheduler) { + if (delayTime === void 0) { + delayTime = 0; + } + if (scheduler === void 0) { + scheduler = asap["a" /* asap */]; + } + var _this = _super.call(this) || this; + _this.source = source; + _this.delayTime = delayTime; + _this.scheduler = scheduler; + if (!Object(isNumeric["a" /* isNumeric */])(delayTime) || delayTime < 0) { + _this.delayTime = 0; + } + if (!scheduler || typeof scheduler.schedule !== 'function') { + _this.scheduler = asap["a" /* asap */]; } return _this; } - WindowTimeSubscriber.prototype._next = function (value) { - var windows = this.windows; - var len = windows.length; - for (var i = 0; i < len; i++) { - var window_1 = windows[i]; - if (!window_1.closed) { - window_1.next(value); - if (window_1.numberOfNextedValues >= this.maxWindowSize) { - this.closeWindow(window_1); - } - } - } - }; - WindowTimeSubscriber.prototype._error = function (err) { - var windows = this.windows; - while (windows.length > 0) { - windows.shift().error(err); + SubscribeOnObservable.create = function (source, delay, scheduler) { + if (delay === void 0) { + delay = 0; } - this.destination.error(err); - }; - WindowTimeSubscriber.prototype._complete = function () { - var windows = this.windows; - while (windows.length > 0) { - var window_2 = windows.shift(); - if (!window_2.closed) { - window_2.complete(); - } + if (scheduler === void 0) { + scheduler = asap["a" /* asap */]; } - this.destination.complete(); + return new SubscribeOnObservable(source, delay, scheduler); }; - WindowTimeSubscriber.prototype.openWindow = function () { - var window = new CountedSubject(); - this.windows.push(window); - var destination = this.destination; - destination.next(window); - return window; + SubscribeOnObservable.dispatch = function (arg) { + var source = arg.source, subscriber = arg.subscriber; + return this.add(source.subscribe(subscriber)); }; - WindowTimeSubscriber.prototype.closeWindow = function (window) { - window.complete(); - var windows = this.windows; - windows.splice(windows.indexOf(window), 1); + SubscribeOnObservable.prototype._subscribe = function (subscriber) { + var delay = this.delayTime; + var source = this.source; + var scheduler = this.scheduler; + return scheduler.schedule(SubscribeOnObservable.dispatch, delay, { + source: source, subscriber: subscriber + }); }; - return WindowTimeSubscriber; -}(__WEBPACK_IMPORTED_MODULE_3__Subscriber__["a" /* Subscriber */])); -function dispatchWindowTimeSpanOnly(state) { - var subscriber = state.subscriber, windowTimeSpan = state.windowTimeSpan, window = state.window; - if (window) { - subscriber.closeWindow(window); - } - state.window = subscriber.openWindow(); - this.schedule(state, windowTimeSpan); -} -function dispatchWindowCreation(state) { - var windowTimeSpan = state.windowTimeSpan, subscriber = state.subscriber, scheduler = state.scheduler, windowCreationInterval = state.windowCreationInterval; - var window = subscriber.openWindow(); - var action = this; - var context = { action: action, subscription: null }; - var timeSpanState = { subscriber: subscriber, window: window, context: context }; - context.subscription = scheduler.schedule(dispatchWindowClose, windowTimeSpan, timeSpanState); - action.add(context.subscription); - action.schedule(state, windowCreationInterval); -} -function dispatchWindowClose(state) { - var subscriber = state.subscriber, window = state.window, context = state.context; - if (context && context.action && context.subscription) { - context.action.remove(context.subscription); - } - subscriber.closeWindow(window); -} -//# sourceMappingURL=windowTime.js.map - + return SubscribeOnObservable; +}(Observable["a" /* Observable */])); -/***/ }), -/* 370 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { +//# sourceMappingURL=SubscribeOnObservable.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = windowToggle; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Subscription__ = __webpack_require__(7); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_Subject,_Subscription,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/subscribeOn.js +/** PURE_IMPORTS_START _observable_SubscribeOnObservable PURE_IMPORTS_END */ +function subscribeOn(scheduler, delay) { + if (delay === void 0) { + delay = 0; + } + return function subscribeOnOperatorFunction(source) { + return source.lift(new subscribeOn_SubscribeOnOperator(scheduler, delay)); + }; +} +var subscribeOn_SubscribeOnOperator = /*@__PURE__*/ (function () { + function SubscribeOnOperator(scheduler, delay) { + this.scheduler = scheduler; + this.delay = delay; + } + SubscribeOnOperator.prototype.call = function (subscriber, source) { + return new SubscribeOnObservable_SubscribeOnObservable(source, this.delay, this.scheduler).subscribe(subscriber); + }; + return SubscribeOnOperator; +}()); +//# sourceMappingURL=subscribeOn.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/switchMap.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult,_map,_observable_from PURE_IMPORTS_END */ -function windowToggle(openings, closingSelector) { - return function (source) { return source.lift(new WindowToggleOperator(openings, closingSelector)); }; +function switchMap(project, resultSelector) { + if (typeof resultSelector === 'function') { + return function (source) { return source.pipe(switchMap(function (a, i) { return Object(from["a" /* from */])(project(a, i)).pipe(Object(map["a" /* map */])(function (b, ii) { return resultSelector(a, b, i, ii); })); })); }; + } + return function (source) { return source.lift(new SwitchMapOperator(project)); }; } -var WindowToggleOperator = /*@__PURE__*/ (function () { - function WindowToggleOperator(openings, closingSelector) { - this.openings = openings; - this.closingSelector = closingSelector; +var SwitchMapOperator = /*@__PURE__*/ (function () { + function SwitchMapOperator(project) { + this.project = project; } - WindowToggleOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new WindowToggleSubscriber(subscriber, this.openings, this.closingSelector)); + SwitchMapOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new switchMap_SwitchMapSubscriber(subscriber, this.project)); }; - return WindowToggleOperator; + return SwitchMapOperator; }()); -var WindowToggleSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](WindowToggleSubscriber, _super); - function WindowToggleSubscriber(destination, openings, closingSelector) { +var switchMap_SwitchMapSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](SwitchMapSubscriber, _super); + function SwitchMapSubscriber(destination, project) { var _this = _super.call(this, destination) || this; - _this.openings = openings; - _this.closingSelector = closingSelector; - _this.contexts = []; - _this.add(_this.openSubscription = Object(__WEBPACK_IMPORTED_MODULE_6__util_subscribeToResult__["a" /* subscribeToResult */])(_this, openings, openings)); + _this.project = project; + _this.index = 0; return _this; } - WindowToggleSubscriber.prototype._next = function (value) { - var contexts = this.contexts; - if (contexts) { - var len = contexts.length; - for (var i = 0; i < len; i++) { - contexts[i].window.next(value); - } - } - }; - WindowToggleSubscriber.prototype._error = function (err) { - var contexts = this.contexts; - this.contexts = null; - if (contexts) { - var len = contexts.length; - var index = -1; - while (++index < len) { - var context_1 = contexts[index]; - context_1.window.error(err); - context_1.subscription.unsubscribe(); - } + SwitchMapSubscriber.prototype._next = function (value) { + var result; + var index = this.index++; + try { + result = this.project(value, index); } - _super.prototype._error.call(this, err); - }; - WindowToggleSubscriber.prototype._complete = function () { - var contexts = this.contexts; - this.contexts = null; - if (contexts) { - var len = contexts.length; - var index = -1; - while (++index < len) { - var context_2 = contexts[index]; - context_2.window.complete(); - context_2.subscription.unsubscribe(); - } + catch (error) { + this.destination.error(error); + return; } - _super.prototype._complete.call(this); + this._innerSub(result, value, index); }; - WindowToggleSubscriber.prototype._unsubscribe = function () { - var contexts = this.contexts; - this.contexts = null; - if (contexts) { - var len = contexts.length; - var index = -1; - while (++index < len) { - var context_3 = contexts[index]; - context_3.window.unsubscribe(); - context_3.subscription.unsubscribe(); - } + SwitchMapSubscriber.prototype._innerSub = function (result, value, index) { + var innerSubscription = this.innerSubscription; + if (innerSubscription) { + innerSubscription.unsubscribe(); } + this.add(this.innerSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(this, result, value, index)); }; - WindowToggleSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - if (outerValue === this.openings) { - var closingSelector = this.closingSelector; - var closingNotifier = Object(__WEBPACK_IMPORTED_MODULE_3__util_tryCatch__["a" /* tryCatch */])(closingSelector)(innerValue); - if (closingNotifier === __WEBPACK_IMPORTED_MODULE_4__util_errorObject__["a" /* errorObject */]) { - return this.error(__WEBPACK_IMPORTED_MODULE_4__util_errorObject__["a" /* errorObject */].e); - } - else { - var window_1 = new __WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */](); - var subscription = new __WEBPACK_IMPORTED_MODULE_2__Subscription__["a" /* Subscription */](); - var context_4 = { window: window_1, subscription: subscription }; - this.contexts.push(context_4); - var innerSubscription = Object(__WEBPACK_IMPORTED_MODULE_6__util_subscribeToResult__["a" /* subscribeToResult */])(this, closingNotifier, context_4); - if (innerSubscription.closed) { - this.closeWindow(this.contexts.length - 1); - } - else { - innerSubscription.context = context_4; - subscription.add(innerSubscription); - } - this.destination.next(window_1); - } - } - else { - this.closeWindow(this.contexts.indexOf(outerValue)); + SwitchMapSubscriber.prototype._complete = function () { + var innerSubscription = this.innerSubscription; + if (!innerSubscription || innerSubscription.closed) { + _super.prototype._complete.call(this); } }; - WindowToggleSubscriber.prototype.notifyError = function (err) { - this.error(err); - }; - WindowToggleSubscriber.prototype.notifyComplete = function (inner) { - if (inner !== this.openSubscription) { - this.closeWindow(this.contexts.indexOf(inner.context)); - } + SwitchMapSubscriber.prototype._unsubscribe = function () { + this.innerSubscription = null; }; - WindowToggleSubscriber.prototype.closeWindow = function (index) { - if (index === -1) { - return; - } - var contexts = this.contexts; - var context = contexts[index]; - var window = context.window, subscription = context.subscription; - contexts.splice(index, 1); - window.complete(); - subscription.unsubscribe(); + SwitchMapSubscriber.prototype.notifyComplete = function (innerSub) { + this.remove(innerSub); + this.innerSubscription = null; + if (this.isStopped) { + _super.prototype._complete.call(this); + } }; - return WindowToggleSubscriber; -}(__WEBPACK_IMPORTED_MODULE_5__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=windowToggle.js.map + SwitchMapSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.destination.next(innerValue); + }; + return SwitchMapSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=switchMap.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/switchAll.js +/** PURE_IMPORTS_START _switchMap,_util_identity PURE_IMPORTS_END */ -/***/ }), -/* 371 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = windowWhen; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Subject__ = __webpack_require__(9); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_tryCatch__ = __webpack_require__(16); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__util_errorObject__ = __webpack_require__(13); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__ = __webpack_require__(5); -/** PURE_IMPORTS_START tslib,_Subject,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ +function switchAll() { + return switchMap(identity["a" /* identity */]); +} +//# sourceMappingURL=switchAll.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/switchMapTo.js +/** PURE_IMPORTS_START _switchMap PURE_IMPORTS_END */ +function switchMapTo(innerObservable, resultSelector) { + return resultSelector ? switchMap(function () { return innerObservable; }, resultSelector) : switchMap(function () { return innerObservable; }); +} +//# sourceMappingURL=switchMapTo.js.map +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/takeUntil.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function windowWhen(closingSelector) { - return function windowWhenOperatorFunction(source) { - return source.lift(new WindowOperator(closingSelector)); - }; +function takeUntil(notifier) { + return function (source) { return source.lift(new takeUntil_TakeUntilOperator(notifier)); }; } -var WindowOperator = /*@__PURE__*/ (function () { - function WindowOperator(closingSelector) { - this.closingSelector = closingSelector; +var takeUntil_TakeUntilOperator = /*@__PURE__*/ (function () { + function TakeUntilOperator(notifier) { + this.notifier = notifier; } - WindowOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new WindowSubscriber(subscriber, this.closingSelector)); + TakeUntilOperator.prototype.call = function (subscriber, source) { + var takeUntilSubscriber = new takeUntil_TakeUntilSubscriber(subscriber); + var notifierSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(takeUntilSubscriber, this.notifier); + if (notifierSubscription && !notifierSubscription.closed) { + takeUntilSubscriber.add(notifierSubscription); + return source.subscribe(takeUntilSubscriber); + } + return takeUntilSubscriber; }; - return WindowOperator; + return TakeUntilOperator; }()); -var WindowSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](WindowSubscriber, _super); - function WindowSubscriber(destination, closingSelector) { - var _this = _super.call(this, destination) || this; - _this.destination = destination; - _this.closingSelector = closingSelector; - _this.openWindow(); - return _this; +var takeUntil_TakeUntilSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](TakeUntilSubscriber, _super); + function TakeUntilSubscriber(destination) { + return _super.call(this, destination) || this; } - WindowSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.openWindow(innerSub); - }; - WindowSubscriber.prototype.notifyError = function (error, innerSub) { - this._error(error); - }; - WindowSubscriber.prototype.notifyComplete = function (innerSub) { - this.openWindow(innerSub); - }; - WindowSubscriber.prototype._next = function (value) { - this.window.next(value); - }; - WindowSubscriber.prototype._error = function (err) { - this.window.error(err); - this.destination.error(err); - this.unsubscribeClosingNotification(); + TakeUntilSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.complete(); }; - WindowSubscriber.prototype._complete = function () { - this.window.complete(); - this.destination.complete(); - this.unsubscribeClosingNotification(); + TakeUntilSubscriber.prototype.notifyComplete = function () { }; - WindowSubscriber.prototype.unsubscribeClosingNotification = function () { - if (this.closingNotification) { - this.closingNotification.unsubscribe(); - } + return TakeUntilSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=takeUntil.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/takeWhile.js +/** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */ + + +function takeWhile(predicate) { + return function (source) { return source.lift(new TakeWhileOperator(predicate)); }; +} +var TakeWhileOperator = /*@__PURE__*/ (function () { + function TakeWhileOperator(predicate) { + this.predicate = predicate; + } + TakeWhileOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new takeWhile_TakeWhileSubscriber(subscriber, this.predicate)); }; - WindowSubscriber.prototype.openWindow = function (innerSub) { - if (innerSub === void 0) { - innerSub = null; - } - if (innerSub) { - this.remove(innerSub); - innerSub.unsubscribe(); + return TakeWhileOperator; +}()); +var takeWhile_TakeWhileSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](TakeWhileSubscriber, _super); + function TakeWhileSubscriber(destination, predicate) { + var _this = _super.call(this, destination) || this; + _this.predicate = predicate; + _this.index = 0; + return _this; + } + TakeWhileSubscriber.prototype._next = function (value) { + var destination = this.destination; + var result; + try { + result = this.predicate(value, this.index++); } - var prevWindow = this.window; - if (prevWindow) { - prevWindow.complete(); + catch (err) { + destination.error(err); + return; } - var window = this.window = new __WEBPACK_IMPORTED_MODULE_1__Subject__["a" /* Subject */](); - this.destination.next(window); - var closingNotifier = Object(__WEBPACK_IMPORTED_MODULE_2__util_tryCatch__["a" /* tryCatch */])(this.closingSelector)(); - if (closingNotifier === __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */]) { - var err = __WEBPACK_IMPORTED_MODULE_3__util_errorObject__["a" /* errorObject */].e; - this.destination.error(err); - this.window.error(err); + this.nextOrComplete(value, result); + }; + TakeWhileSubscriber.prototype.nextOrComplete = function (value, predicateResult) { + var destination = this.destination; + if (Boolean(predicateResult)) { + destination.next(value); } else { - this.add(this.closingNotification = Object(__WEBPACK_IMPORTED_MODULE_5__util_subscribeToResult__["a" /* subscribeToResult */])(this, closingNotifier)); + destination.complete(); } }; - return WindowSubscriber; -}(__WEBPACK_IMPORTED_MODULE_4__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=windowWhen.js.map - - -/***/ }), -/* 372 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { + return TakeWhileSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=takeWhile.js.map -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = withLatestFrom; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tslib__ = __webpack_require__(0); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__ = __webpack_require__(4); -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__ = __webpack_require__(5); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/throttle.js /** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -function withLatestFrom() { - var args = []; - for (var _i = 0; _i < arguments.length; _i++) { - args[_i] = arguments[_i]; +var defaultThrottleConfig = { + leading: true, + trailing: false +}; +function throttle(durationSelector, config) { + if (config === void 0) { + config = defaultThrottleConfig; } - return function (source) { - var project; - if (typeof args[args.length - 1] === 'function') { - project = args.pop(); - } - var observables = args; - return source.lift(new WithLatestFromOperator(observables, project)); - }; + return function (source) { return source.lift(new ThrottleOperator(durationSelector, config.leading, config.trailing)); }; } -var WithLatestFromOperator = /*@__PURE__*/ (function () { - function WithLatestFromOperator(observables, project) { - this.observables = observables; - this.project = project; +var ThrottleOperator = /*@__PURE__*/ (function () { + function ThrottleOperator(durationSelector, leading, trailing) { + this.durationSelector = durationSelector; + this.leading = leading; + this.trailing = trailing; } - WithLatestFromOperator.prototype.call = function (subscriber, source) { - return source.subscribe(new WithLatestFromSubscriber(subscriber, this.observables, this.project)); + ThrottleOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new throttle_ThrottleSubscriber(subscriber, this.durationSelector, this.leading, this.trailing)); }; - return WithLatestFromOperator; + return ThrottleOperator; }()); -var WithLatestFromSubscriber = /*@__PURE__*/ (function (_super) { - __WEBPACK_IMPORTED_MODULE_0_tslib__["a" /* __extends */](WithLatestFromSubscriber, _super); - function WithLatestFromSubscriber(destination, observables, project) { +var throttle_ThrottleSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](ThrottleSubscriber, _super); + function ThrottleSubscriber(destination, durationSelector, _leading, _trailing) { var _this = _super.call(this, destination) || this; - _this.observables = observables; - _this.project = project; - _this.toRespond = []; - var len = observables.length; - _this.values = new Array(len); - for (var i = 0; i < len; i++) { - _this.toRespond.push(i); + _this.destination = destination; + _this.durationSelector = durationSelector; + _this._leading = _leading; + _this._trailing = _trailing; + _this._hasValue = false; + return _this; + } + ThrottleSubscriber.prototype._next = function (value) { + this._hasValue = true; + this._sendValue = value; + if (!this._throttled) { + if (this._leading) { + this.send(); + } + else { + this.throttle(value); + } } - for (var i = 0; i < len; i++) { - var observable = observables[i]; - _this.add(Object(__WEBPACK_IMPORTED_MODULE_2__util_subscribeToResult__["a" /* subscribeToResult */])(_this, observable, observable, i)); + }; + ThrottleSubscriber.prototype.send = function () { + var _a = this, _hasValue = _a._hasValue, _sendValue = _a._sendValue; + if (_hasValue) { + this.destination.next(_sendValue); + this.throttle(_sendValue); + } + this._hasValue = false; + this._sendValue = null; + }; + ThrottleSubscriber.prototype.throttle = function (value) { + var duration = this.tryDurationSelector(value); + if (duration) { + this.add(this._throttled = Object(subscribeToResult["a" /* subscribeToResult */])(this, duration)); + } + }; + ThrottleSubscriber.prototype.tryDurationSelector = function (value) { + try { + return this.durationSelector(value); + } + catch (err) { + this.destination.error(err); + return null; + } + }; + ThrottleSubscriber.prototype.throttlingDone = function () { + var _a = this, _throttled = _a._throttled, _trailing = _a._trailing; + if (_throttled) { + _throttled.unsubscribe(); } + this._throttled = null; + if (_trailing) { + this.send(); + } + }; + ThrottleSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.throttlingDone(); + }; + ThrottleSubscriber.prototype.notifyComplete = function () { + this.throttlingDone(); + }; + return ThrottleSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=throttle.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/throttleTime.js +/** PURE_IMPORTS_START tslib,_Subscriber,_scheduler_async,_throttle PURE_IMPORTS_END */ + + + + +function throttleTime(duration, scheduler, config) { + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; + } + if (config === void 0) { + config = defaultThrottleConfig; + } + return function (source) { return source.lift(new ThrottleTimeOperator(duration, scheduler, config.leading, config.trailing)); }; +} +var ThrottleTimeOperator = /*@__PURE__*/ (function () { + function ThrottleTimeOperator(duration, scheduler, leading, trailing) { + this.duration = duration; + this.scheduler = scheduler; + this.leading = leading; + this.trailing = trailing; + } + ThrottleTimeOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new throttleTime_ThrottleTimeSubscriber(subscriber, this.duration, this.scheduler, this.leading, this.trailing)); + }; + return ThrottleTimeOperator; +}()); +var throttleTime_ThrottleTimeSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](ThrottleTimeSubscriber, _super); + function ThrottleTimeSubscriber(destination, duration, scheduler, leading, trailing) { + var _this = _super.call(this, destination) || this; + _this.duration = duration; + _this.scheduler = scheduler; + _this.leading = leading; + _this.trailing = trailing; + _this._hasTrailingValue = false; + _this._trailingValue = null; return _this; } - WithLatestFromSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { - this.values[outerIndex] = innerValue; - var toRespond = this.toRespond; - if (toRespond.length > 0) { - var found = toRespond.indexOf(outerIndex); - if (found !== -1) { - toRespond.splice(found, 1); + ThrottleTimeSubscriber.prototype._next = function (value) { + if (this.throttled) { + if (this.trailing) { + this._trailingValue = value; + this._hasTrailingValue = true; } } - }; - WithLatestFromSubscriber.prototype.notifyComplete = function () { - }; - WithLatestFromSubscriber.prototype._next = function (value) { - if (this.toRespond.length === 0) { - var args = [value].concat(this.values); - if (this.project) { - this._tryProject(args); - } - else { - this.destination.next(args); + else { + this.add(this.throttled = this.scheduler.schedule(throttleTime_dispatchNext, this.duration, { subscriber: this })); + if (this.leading) { + this.destination.next(value); } } }; - WithLatestFromSubscriber.prototype._tryProject = function (args) { - var result; - try { - result = this.project.apply(this, args); + ThrottleTimeSubscriber.prototype._complete = function () { + if (this._hasTrailingValue) { + this.destination.next(this._trailingValue); + this.destination.complete(); } - catch (err) { - this.destination.error(err); - return; + else { + this.destination.complete(); } - this.destination.next(result); - }; - return WithLatestFromSubscriber; -}(__WEBPACK_IMPORTED_MODULE_1__OuterSubscriber__["a" /* OuterSubscriber */])); -//# sourceMappingURL=withLatestFrom.js.map - - -/***/ }), -/* 373 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = zip; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_zip__ = __webpack_require__(72); -/** PURE_IMPORTS_START _observable_zip PURE_IMPORTS_END */ - -function zip() { - var observables = []; - for (var _i = 0; _i < arguments.length; _i++) { - observables[_i] = arguments[_i]; - } - return function zipOperatorFunction(source) { - return source.lift.call(__WEBPACK_IMPORTED_MODULE_0__observable_zip__["b" /* zip */].apply(void 0, [source].concat(observables))); }; -} -//# sourceMappingURL=zip.js.map - - -/***/ }), -/* 374 */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony export (immutable) */ __webpack_exports__["a"] = zipAll; -/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__observable_zip__ = __webpack_require__(72); -/** PURE_IMPORTS_START _observable_zip PURE_IMPORTS_END */ - -function zipAll(project) { - return function (source) { return source.lift(new __WEBPACK_IMPORTED_MODULE_0__observable_zip__["a" /* ZipOperator */](project)); }; -} -//# sourceMappingURL=zipAll.js.map - - -/***/ }), -/* 375 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - - -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.runCommand = undefined; - -let runCommand = exports.runCommand = (() => { - var _ref = _asyncToGenerator(function* (command, config) { - try { - _log.log.write(_chalk2.default.bold(`Running [${_chalk2.default.green(command.name)}] command from [${_chalk2.default.yellow(config.rootPath)}]:\n`)); - const projectPaths = (0, _config.getProjectPaths)(config.rootPath, config.options); - const projects = yield (0, _projects.getProjects)(config.rootPath, projectPaths, { - exclude: toArray(config.options.exclude), - include: toArray(config.options.include) - }); - if (projects.size === 0) { - _log.log.write(_chalk2.default.red(`There are no projects found. Double check project name(s) in '-i/--include' and '-e/--exclude' filters.\n`)); - return process.exit(1); - } - const projectGraph = (0, _projects.buildProjectGraph)(projects); - _log.log.write(_chalk2.default.bold(`Found [${_chalk2.default.green(projects.size.toString())}] projects:\n`)); - _log.log.write((0, _projects_tree.renderProjectsTree)(config.rootPath, projects)); - yield command.run(projects, projectGraph, config); - } catch (e) { - _log.log.write(_chalk2.default.bold.red(`\n[${command.name}] failed:\n`)); - if (e instanceof _errors.CliError) { - const msg = _chalk2.default.red(`CliError: ${e.message}\n`); - _log.log.write((0, _wrapAnsi2.default)(msg, 80)); - const keys = Object.keys(e.meta); - if (keys.length > 0) { - const metaOutput = keys.map(function (key) { - const value = e.meta[key]; - return `${key}: ${value}`; - }); - _log.log.write('Additional debugging info:\n'); - _log.log.write((0, _indentString2.default)(metaOutput.join('\n'), 3)); - } - } else { - _log.log.write(e.stack); + ThrottleTimeSubscriber.prototype.clearThrottle = function () { + var throttled = this.throttled; + if (throttled) { + if (this.trailing && this._hasTrailingValue) { + this.destination.next(this._trailingValue); + this._trailingValue = null; + this._hasTrailingValue = false; } - process.exit(1); + throttled.unsubscribe(); + this.remove(throttled); + this.throttled = null; } - }); - - return function runCommand(_x, _x2) { - return _ref.apply(this, arguments); }; -})(); - -var _chalk = __webpack_require__(17); + return ThrottleTimeSubscriber; +}(Subscriber["a" /* Subscriber */])); +function throttleTime_dispatchNext(arg) { + var subscriber = arg.subscriber; + subscriber.clearThrottle(); +} +//# sourceMappingURL=throttleTime.js.map -var _chalk2 = _interopRequireDefault(_chalk); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/defer.js +var defer = __webpack_require__(51); -var _indentString = __webpack_require__(376); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/timeInterval.js +/** PURE_IMPORTS_START _scheduler_async,_scan,_observable_defer,_map PURE_IMPORTS_END */ -var _indentString2 = _interopRequireDefault(_indentString); -var _wrapAnsi = __webpack_require__(377); -var _wrapAnsi2 = _interopRequireDefault(_wrapAnsi); -var _config = __webpack_require__(60); +function timeInterval(scheduler) { + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; + } + return function (source) { + return Object(defer["a" /* defer */])(function () { + return source.pipe(scan(function (_a, value) { + var current = _a.current; + return ({ value: value, current: scheduler.now(), last: current }); + }, { current: scheduler.now(), value: undefined, last: undefined }), Object(map["a" /* map */])(function (_a) { + var current = _a.current, last = _a.last, value = _a.value; + return new TimeInterval(value, current - last); + })); + }); + }; +} +var TimeInterval = /*@__PURE__*/ (function () { + function TimeInterval(value, interval) { + this.value = value; + this.interval = interval; + } + return TimeInterval; +}()); -var _errors = __webpack_require__(57); +//# sourceMappingURL=timeInterval.js.map -var _log = __webpack_require__(19); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/TimeoutError.js +var TimeoutError = __webpack_require__(67); -var _projects = __webpack_require__(22); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/timeoutWith.js +/** PURE_IMPORTS_START tslib,_scheduler_async,_util_isDate,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ -var _projects_tree = __webpack_require__(384); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* - * 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. - */ -function toArray(value) { - if (value == null) { - return []; +function timeoutWith(due, withObservable, scheduler) { + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; } - return Array.isArray(value) ? value : [value]; + return function (source) { + var absoluteTimeout = isDate(due); + var waitFor = absoluteTimeout ? (+due - scheduler.now()) : Math.abs(due); + return source.lift(new TimeoutWithOperator(waitFor, absoluteTimeout, withObservable, scheduler)); + }; } +var TimeoutWithOperator = /*@__PURE__*/ (function () { + function TimeoutWithOperator(waitFor, absoluteTimeout, withObservable, scheduler) { + this.waitFor = waitFor; + this.absoluteTimeout = absoluteTimeout; + this.withObservable = withObservable; + this.scheduler = scheduler; + } + TimeoutWithOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new timeoutWith_TimeoutWithSubscriber(subscriber, this.absoluteTimeout, this.waitFor, this.withObservable, this.scheduler)); + }; + return TimeoutWithOperator; +}()); +var timeoutWith_TimeoutWithSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](TimeoutWithSubscriber, _super); + function TimeoutWithSubscriber(destination, absoluteTimeout, waitFor, withObservable, scheduler) { + var _this = _super.call(this, destination) || this; + _this.absoluteTimeout = absoluteTimeout; + _this.waitFor = waitFor; + _this.withObservable = withObservable; + _this.scheduler = scheduler; + _this.action = null; + _this.scheduleTimeout(); + return _this; + } + TimeoutWithSubscriber.dispatchTimeout = function (subscriber) { + var withObservable = subscriber.withObservable; + subscriber._unsubscribeAndRecycle(); + subscriber.add(Object(subscribeToResult["a" /* subscribeToResult */])(subscriber, withObservable)); + }; + TimeoutWithSubscriber.prototype.scheduleTimeout = function () { + var action = this.action; + if (action) { + this.action = action.schedule(this, this.waitFor); + } + else { + this.add(this.action = this.scheduler.schedule(TimeoutWithSubscriber.dispatchTimeout, this.waitFor, this)); + } + }; + TimeoutWithSubscriber.prototype._next = function (value) { + if (!this.absoluteTimeout) { + this.scheduleTimeout(); + } + _super.prototype._next.call(this, value); + }; + TimeoutWithSubscriber.prototype._unsubscribe = function () { + this.action = null; + this.scheduler = null; + this.withObservable = null; + }; + return TimeoutWithSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=timeoutWith.js.map -/***/ }), -/* 376 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - -module.exports = (str, count, opts) => { - // Support older versions: use the third parameter as options.indent - // TODO: Remove the workaround in the next major version - const options = typeof opts === 'object' ? Object.assign({indent: ' '}, opts) : {indent: opts || ' '}; - count = count === undefined ? 1 : count; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/throwError.js +var throwError = __webpack_require__(48); - if (typeof str !== 'string') { - throw new TypeError(`Expected \`input\` to be a \`string\`, got \`${typeof str}\``); - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/timeout.js +/** PURE_IMPORTS_START _scheduler_async,_util_TimeoutError,_timeoutWith,_observable_throwError PURE_IMPORTS_END */ - if (typeof count !== 'number') { - throw new TypeError(`Expected \`count\` to be a \`number\`, got \`${typeof count}\``); - } - if (typeof options.indent !== 'string') { - throw new TypeError(`Expected \`options.indent\` to be a \`string\`, got \`${typeof options.indent}\``); - } - if (count === 0) { - return str; - } - const regex = options.includeEmptyLines ? /^/mg : /^(?!\s*$)/mg; - return str.replace(regex, options.indent.repeat(count)); +function timeout(due, scheduler) { + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; + } + return timeoutWith(due, Object(throwError["a" /* throwError */])(new TimeoutError["a" /* TimeoutError */]()), scheduler); } -; - - -/***/ }), -/* 377 */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - -const stringWidth = __webpack_require__(378); -const stripAnsi = __webpack_require__(382); - -const ESCAPES = new Set([ - '\u001B', - '\u009B' -]); - -const END_CODE = 39; +//# sourceMappingURL=timeout.js.map -const ESCAPE_CODES = new Map([ - [0, 0], - [1, 22], - [2, 22], - [3, 23], - [4, 24], - [7, 27], - [8, 28], - [9, 29], - [30, 39], - [31, 39], - [32, 39], - [33, 39], - [34, 39], - [35, 39], - [36, 39], - [37, 39], - [90, 39], - [40, 49], - [41, 49], - [42, 49], - [43, 49], - [44, 49], - [45, 49], - [46, 49], - [47, 49] -]); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/timestamp.js +/** PURE_IMPORTS_START _scheduler_async,_map PURE_IMPORTS_END */ -const wrapAnsi = code => `${ESCAPES.values().next().value}[${code}m`; -// Calculate the length of words split on ' ', ignoring -// the extra characters added by ansi escape codes -const wordLengths = str => str.split(' ').map(s => stringWidth(s)); +function timestamp(scheduler) { + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; + } + return Object(map["a" /* map */])(function (value) { return new Timestamp(value, scheduler.now()); }); +} +var Timestamp = /*@__PURE__*/ (function () { + function Timestamp(value, timestamp) { + this.value = value; + this.timestamp = timestamp; + } + return Timestamp; +}()); -// Wrap a long word across multiple rows -// Ansi escape codes do not count towards length -const wrapWord = (rows, word, cols) => { - const arr = Array.from(word); +//# sourceMappingURL=timestamp.js.map - let insideEscape = false; - let visible = stringWidth(stripAnsi(rows[rows.length - 1])); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/toArray.js +/** PURE_IMPORTS_START _reduce PURE_IMPORTS_END */ - for (const item of arr.entries()) { - const i = item[0]; - const char = item[1]; - const charLength = stringWidth(char); +function toArrayReducer(arr, item, index) { + if (index === 0) { + return [item]; + } + arr.push(item); + return arr; +} +function toArray() { + return reduce(toArrayReducer, []); +} +//# sourceMappingURL=toArray.js.map - if (visible + charLength <= cols) { - rows[rows.length - 1] += char; - } else { - rows.push(char); - visible = 0; - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/window.js +/** PURE_IMPORTS_START tslib,_Subject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - if (ESCAPES.has(char)) { - insideEscape = true; - } else if (insideEscape && char === 'm') { - insideEscape = false; - continue; - } - if (insideEscape) { - continue; - } - visible += charLength; - if (visible === cols && i < arr.length - 1) { - rows.push(''); - visible = 0; - } - } +function window_window(windowBoundaries) { + return function windowOperatorFunction(source) { + return source.lift(new window_WindowOperator(windowBoundaries)); + }; +} +var window_WindowOperator = /*@__PURE__*/ (function () { + function WindowOperator(windowBoundaries) { + this.windowBoundaries = windowBoundaries; + } + WindowOperator.prototype.call = function (subscriber, source) { + var windowSubscriber = new window_WindowSubscriber(subscriber); + var sourceSubscription = source.subscribe(windowSubscriber); + if (!sourceSubscription.closed) { + windowSubscriber.add(Object(subscribeToResult["a" /* subscribeToResult */])(windowSubscriber, this.windowBoundaries)); + } + return sourceSubscription; + }; + return WindowOperator; +}()); +var window_WindowSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](WindowSubscriber, _super); + function WindowSubscriber(destination) { + var _this = _super.call(this, destination) || this; + _this.window = new Subject["a" /* Subject */](); + destination.next(_this.window); + return _this; + } + WindowSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.openWindow(); + }; + WindowSubscriber.prototype.notifyError = function (error, innerSub) { + this._error(error); + }; + WindowSubscriber.prototype.notifyComplete = function (innerSub) { + this._complete(); + }; + WindowSubscriber.prototype._next = function (value) { + this.window.next(value); + }; + WindowSubscriber.prototype._error = function (err) { + this.window.error(err); + this.destination.error(err); + }; + WindowSubscriber.prototype._complete = function () { + this.window.complete(); + this.destination.complete(); + }; + WindowSubscriber.prototype._unsubscribe = function () { + this.window = null; + }; + WindowSubscriber.prototype.openWindow = function () { + var prevWindow = this.window; + if (prevWindow) { + prevWindow.complete(); + } + var destination = this.destination; + var newWindow = this.window = new Subject["a" /* Subject */](); + destination.next(newWindow); + }; + return WindowSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=window.js.map - // It's possible that the last row we copy over is only - // ansi escape characters, handle this edge-case - if (!visible && rows[rows.length - 1].length > 0 && rows.length > 1) { - rows[rows.length - 2] += rows.pop(); - } -}; +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/windowCount.js +/** PURE_IMPORTS_START tslib,_Subscriber,_Subject PURE_IMPORTS_END */ -// The wrap-ansi module can be invoked -// in either 'hard' or 'soft' wrap mode -// -// 'hard' will never allow a string to take up more -// than cols characters -// -// 'soft' allows long words to expand past the column length -const exec = (str, cols, opts) => { - const options = opts || {}; - if (str.trim() === '') { - return options.trim === false ? str : str.trim(); - } - let pre = ''; - let ret = ''; - let escapeCode; +function windowCount(windowSize, startWindowEvery) { + if (startWindowEvery === void 0) { + startWindowEvery = 0; + } + return function windowCountOperatorFunction(source) { + return source.lift(new WindowCountOperator(windowSize, startWindowEvery)); + }; +} +var WindowCountOperator = /*@__PURE__*/ (function () { + function WindowCountOperator(windowSize, startWindowEvery) { + this.windowSize = windowSize; + this.startWindowEvery = startWindowEvery; + } + WindowCountOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new windowCount_WindowCountSubscriber(subscriber, this.windowSize, this.startWindowEvery)); + }; + return WindowCountOperator; +}()); +var windowCount_WindowCountSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](WindowCountSubscriber, _super); + function WindowCountSubscriber(destination, windowSize, startWindowEvery) { + var _this = _super.call(this, destination) || this; + _this.destination = destination; + _this.windowSize = windowSize; + _this.startWindowEvery = startWindowEvery; + _this.windows = [new Subject["a" /* Subject */]()]; + _this.count = 0; + destination.next(_this.windows[0]); + return _this; + } + WindowCountSubscriber.prototype._next = function (value) { + var startWindowEvery = (this.startWindowEvery > 0) ? this.startWindowEvery : this.windowSize; + var destination = this.destination; + var windowSize = this.windowSize; + var windows = this.windows; + var len = windows.length; + for (var i = 0; i < len && !this.closed; i++) { + windows[i].next(value); + } + var c = this.count - windowSize + 1; + if (c >= 0 && c % startWindowEvery === 0 && !this.closed) { + windows.shift().complete(); + } + if (++this.count % startWindowEvery === 0 && !this.closed) { + var window_1 = new Subject["a" /* Subject */](); + windows.push(window_1); + destination.next(window_1); + } + }; + WindowCountSubscriber.prototype._error = function (err) { + var windows = this.windows; + if (windows) { + while (windows.length > 0 && !this.closed) { + windows.shift().error(err); + } + } + this.destination.error(err); + }; + WindowCountSubscriber.prototype._complete = function () { + var windows = this.windows; + if (windows) { + while (windows.length > 0 && !this.closed) { + windows.shift().complete(); + } + } + this.destination.complete(); + }; + WindowCountSubscriber.prototype._unsubscribe = function () { + this.count = 0; + this.windows = null; + }; + return WindowCountSubscriber; +}(Subscriber["a" /* Subscriber */])); +//# sourceMappingURL=windowCount.js.map - const lengths = wordLengths(str); - const words = str.split(' '); - const rows = ['']; +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/windowTime.js +/** PURE_IMPORTS_START tslib,_Subject,_scheduler_async,_Subscriber,_util_isNumeric,_util_isScheduler PURE_IMPORTS_END */ - for (const item of Array.from(words).entries()) { - const i = item[0]; - const word = item[1]; - rows[rows.length - 1] = options.trim === false ? rows[rows.length - 1] : rows[rows.length - 1].trim(); - let rowLength = stringWidth(rows[rows.length - 1]); - if (rowLength || word === '') { - if (rowLength === cols && options.wordWrap === false) { - // If we start with a new word but the current row length equals the length of the columns, add a new row - rows.push(''); - rowLength = 0; - } - rows[rows.length - 1] += ' '; - rowLength++; - } - // In 'hard' wrap mode, the length of a line is - // never allowed to extend past 'cols' - if (lengths[i] > cols && options.hard) { - if (rowLength) { - rows.push(''); - } - wrapWord(rows, word, cols); - continue; - } - if (rowLength + lengths[i] > cols && rowLength > 0) { - if (options.wordWrap === false && rowLength < cols) { - wrapWord(rows, word, cols); - continue; - } +function windowTime_windowTime(windowTimeSpan) { + var scheduler = scheduler_async["a" /* async */]; + var windowCreationInterval = null; + var maxWindowSize = Number.POSITIVE_INFINITY; + if (Object(isScheduler["a" /* isScheduler */])(arguments[3])) { + scheduler = arguments[3]; + } + if (Object(isScheduler["a" /* isScheduler */])(arguments[2])) { + scheduler = arguments[2]; + } + else if (Object(isNumeric["a" /* isNumeric */])(arguments[2])) { + maxWindowSize = arguments[2]; + } + if (Object(isScheduler["a" /* isScheduler */])(arguments[1])) { + scheduler = arguments[1]; + } + else if (Object(isNumeric["a" /* isNumeric */])(arguments[1])) { + windowCreationInterval = arguments[1]; + } + return function windowTimeOperatorFunction(source) { + return source.lift(new WindowTimeOperator(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler)); + }; +} +var WindowTimeOperator = /*@__PURE__*/ (function () { + function WindowTimeOperator(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler) { + this.windowTimeSpan = windowTimeSpan; + this.windowCreationInterval = windowCreationInterval; + this.maxWindowSize = maxWindowSize; + this.scheduler = scheduler; + } + WindowTimeOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new windowTime_WindowTimeSubscriber(subscriber, this.windowTimeSpan, this.windowCreationInterval, this.maxWindowSize, this.scheduler)); + }; + return WindowTimeOperator; +}()); +var windowTime_CountedSubject = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](CountedSubject, _super); + function CountedSubject() { + var _this = _super !== null && _super.apply(this, arguments) || this; + _this._numberOfNextedValues = 0; + return _this; + } + CountedSubject.prototype.next = function (value) { + this._numberOfNextedValues++; + _super.prototype.next.call(this, value); + }; + Object.defineProperty(CountedSubject.prototype, "numberOfNextedValues", { + get: function () { + return this._numberOfNextedValues; + }, + enumerable: true, + configurable: true + }); + return CountedSubject; +}(Subject["a" /* Subject */])); +var windowTime_WindowTimeSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](WindowTimeSubscriber, _super); + function WindowTimeSubscriber(destination, windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler) { + var _this = _super.call(this, destination) || this; + _this.destination = destination; + _this.windowTimeSpan = windowTimeSpan; + _this.windowCreationInterval = windowCreationInterval; + _this.maxWindowSize = maxWindowSize; + _this.scheduler = scheduler; + _this.windows = []; + var window = _this.openWindow(); + if (windowCreationInterval !== null && windowCreationInterval >= 0) { + var closeState = { subscriber: _this, window: window, context: null }; + var creationState = { windowTimeSpan: windowTimeSpan, windowCreationInterval: windowCreationInterval, subscriber: _this, scheduler: scheduler }; + _this.add(scheduler.schedule(dispatchWindowClose, windowTimeSpan, closeState)); + _this.add(scheduler.schedule(dispatchWindowCreation, windowCreationInterval, creationState)); + } + else { + var timeSpanOnlyState = { subscriber: _this, window: window, windowTimeSpan: windowTimeSpan }; + _this.add(scheduler.schedule(dispatchWindowTimeSpanOnly, windowTimeSpan, timeSpanOnlyState)); + } + return _this; + } + WindowTimeSubscriber.prototype._next = function (value) { + var windows = this.windows; + var len = windows.length; + for (var i = 0; i < len; i++) { + var window_1 = windows[i]; + if (!window_1.closed) { + window_1.next(value); + if (window_1.numberOfNextedValues >= this.maxWindowSize) { + this.closeWindow(window_1); + } + } + } + }; + WindowTimeSubscriber.prototype._error = function (err) { + var windows = this.windows; + while (windows.length > 0) { + windows.shift().error(err); + } + this.destination.error(err); + }; + WindowTimeSubscriber.prototype._complete = function () { + var windows = this.windows; + while (windows.length > 0) { + var window_2 = windows.shift(); + if (!window_2.closed) { + window_2.complete(); + } + } + this.destination.complete(); + }; + WindowTimeSubscriber.prototype.openWindow = function () { + var window = new windowTime_CountedSubject(); + this.windows.push(window); + var destination = this.destination; + destination.next(window); + return window; + }; + WindowTimeSubscriber.prototype.closeWindow = function (window) { + window.complete(); + var windows = this.windows; + windows.splice(windows.indexOf(window), 1); + }; + return WindowTimeSubscriber; +}(Subscriber["a" /* Subscriber */])); +function dispatchWindowTimeSpanOnly(state) { + var subscriber = state.subscriber, windowTimeSpan = state.windowTimeSpan, window = state.window; + if (window) { + subscriber.closeWindow(window); + } + state.window = subscriber.openWindow(); + this.schedule(state, windowTimeSpan); +} +function dispatchWindowCreation(state) { + var windowTimeSpan = state.windowTimeSpan, subscriber = state.subscriber, scheduler = state.scheduler, windowCreationInterval = state.windowCreationInterval; + var window = subscriber.openWindow(); + var action = this; + var context = { action: action, subscription: null }; + var timeSpanState = { subscriber: subscriber, window: window, context: context }; + context.subscription = scheduler.schedule(dispatchWindowClose, windowTimeSpan, timeSpanState); + action.add(context.subscription); + action.schedule(state, windowCreationInterval); +} +function dispatchWindowClose(state) { + var subscriber = state.subscriber, window = state.window, context = state.context; + if (context && context.action && context.subscription) { + context.action.remove(context.subscription); + } + subscriber.closeWindow(window); +} +//# sourceMappingURL=windowTime.js.map - rows.push(''); - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/windowToggle.js +/** PURE_IMPORTS_START tslib,_Subject,_Subscription,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - if (rowLength + lengths[i] > cols && options.wordWrap === false) { - wrapWord(rows, word, cols); - continue; - } - rows[rows.length - 1] += word; - } - pre = rows.map(r => options.trim === false ? r : r.trim()).join('\n'); - for (const item of Array.from(pre).entries()) { - const i = item[0]; - const char = item[1]; - ret += char; - if (ESCAPES.has(char)) { - const code = parseFloat(/\d[^m]*/.exec(pre.slice(i, i + 4))); - escapeCode = code === END_CODE ? null : code; - } - const code = ESCAPE_CODES.get(Number(escapeCode)); +function windowToggle(openings, closingSelector) { + return function (source) { return source.lift(new WindowToggleOperator(openings, closingSelector)); }; +} +var WindowToggleOperator = /*@__PURE__*/ (function () { + function WindowToggleOperator(openings, closingSelector) { + this.openings = openings; + this.closingSelector = closingSelector; + } + WindowToggleOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new windowToggle_WindowToggleSubscriber(subscriber, this.openings, this.closingSelector)); + }; + return WindowToggleOperator; +}()); +var windowToggle_WindowToggleSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](WindowToggleSubscriber, _super); + function WindowToggleSubscriber(destination, openings, closingSelector) { + var _this = _super.call(this, destination) || this; + _this.openings = openings; + _this.closingSelector = closingSelector; + _this.contexts = []; + _this.add(_this.openSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(_this, openings, openings)); + return _this; + } + WindowToggleSubscriber.prototype._next = function (value) { + var contexts = this.contexts; + if (contexts) { + var len = contexts.length; + for (var i = 0; i < len; i++) { + contexts[i].window.next(value); + } + } + }; + WindowToggleSubscriber.prototype._error = function (err) { + var contexts = this.contexts; + this.contexts = null; + if (contexts) { + var len = contexts.length; + var index = -1; + while (++index < len) { + var context_1 = contexts[index]; + context_1.window.error(err); + context_1.subscription.unsubscribe(); + } + } + _super.prototype._error.call(this, err); + }; + WindowToggleSubscriber.prototype._complete = function () { + var contexts = this.contexts; + this.contexts = null; + if (contexts) { + var len = contexts.length; + var index = -1; + while (++index < len) { + var context_2 = contexts[index]; + context_2.window.complete(); + context_2.subscription.unsubscribe(); + } + } + _super.prototype._complete.call(this); + }; + WindowToggleSubscriber.prototype._unsubscribe = function () { + var contexts = this.contexts; + this.contexts = null; + if (contexts) { + var len = contexts.length; + var index = -1; + while (++index < len) { + var context_3 = contexts[index]; + context_3.window.unsubscribe(); + context_3.subscription.unsubscribe(); + } + } + }; + WindowToggleSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + if (outerValue === this.openings) { + var closingSelector = this.closingSelector; + var closingNotifier = Object(tryCatch["a" /* tryCatch */])(closingSelector)(innerValue); + if (closingNotifier === errorObject["a" /* errorObject */]) { + return this.error(errorObject["a" /* errorObject */].e); + } + else { + var window_1 = new Subject["a" /* Subject */](); + var subscription = new Subscription["a" /* Subscription */](); + var context_4 = { window: window_1, subscription: subscription }; + this.contexts.push(context_4); + var innerSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(this, closingNotifier, context_4); + if (innerSubscription.closed) { + this.closeWindow(this.contexts.length - 1); + } + else { + innerSubscription.context = context_4; + subscription.add(innerSubscription); + } + this.destination.next(window_1); + } + } + else { + this.closeWindow(this.contexts.indexOf(outerValue)); + } + }; + WindowToggleSubscriber.prototype.notifyError = function (err) { + this.error(err); + }; + WindowToggleSubscriber.prototype.notifyComplete = function (inner) { + if (inner !== this.openSubscription) { + this.closeWindow(this.contexts.indexOf(inner.context)); + } + }; + WindowToggleSubscriber.prototype.closeWindow = function (index) { + if (index === -1) { + return; + } + var contexts = this.contexts; + var context = contexts[index]; + var window = context.window, subscription = context.subscription; + contexts.splice(index, 1); + window.complete(); + subscription.unsubscribe(); + }; + return WindowToggleSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=windowToggle.js.map - if (escapeCode && code) { - if (pre[i + 1] === '\n') { - ret += wrapAnsi(code); - } else if (char === '\n') { - ret += wrapAnsi(escapeCode); - } - } - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/windowWhen.js +/** PURE_IMPORTS_START tslib,_Subject,_util_tryCatch,_util_errorObject,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - return ret; -}; -// For each newline, invoke the method separately -module.exports = (str, cols, opts) => { - return String(str) - .normalize() - .split('\n') - .map(line => exec(line, cols, opts)) - .join('\n'); -}; -/***/ }), -/* 378 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -const stripAnsi = __webpack_require__(379); -const isFullwidthCodePoint = __webpack_require__(381); +function windowWhen(closingSelector) { + return function windowWhenOperatorFunction(source) { + return source.lift(new windowWhen_WindowOperator(closingSelector)); + }; +} +var windowWhen_WindowOperator = /*@__PURE__*/ (function () { + function WindowOperator(closingSelector) { + this.closingSelector = closingSelector; + } + WindowOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new windowWhen_WindowSubscriber(subscriber, this.closingSelector)); + }; + return WindowOperator; +}()); +var windowWhen_WindowSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](WindowSubscriber, _super); + function WindowSubscriber(destination, closingSelector) { + var _this = _super.call(this, destination) || this; + _this.destination = destination; + _this.closingSelector = closingSelector; + _this.openWindow(); + return _this; + } + WindowSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.openWindow(innerSub); + }; + WindowSubscriber.prototype.notifyError = function (error, innerSub) { + this._error(error); + }; + WindowSubscriber.prototype.notifyComplete = function (innerSub) { + this.openWindow(innerSub); + }; + WindowSubscriber.prototype._next = function (value) { + this.window.next(value); + }; + WindowSubscriber.prototype._error = function (err) { + this.window.error(err); + this.destination.error(err); + this.unsubscribeClosingNotification(); + }; + WindowSubscriber.prototype._complete = function () { + this.window.complete(); + this.destination.complete(); + this.unsubscribeClosingNotification(); + }; + WindowSubscriber.prototype.unsubscribeClosingNotification = function () { + if (this.closingNotification) { + this.closingNotification.unsubscribe(); + } + }; + WindowSubscriber.prototype.openWindow = function (innerSub) { + if (innerSub === void 0) { + innerSub = null; + } + if (innerSub) { + this.remove(innerSub); + innerSub.unsubscribe(); + } + var prevWindow = this.window; + if (prevWindow) { + prevWindow.complete(); + } + var window = this.window = new Subject["a" /* Subject */](); + this.destination.next(window); + var closingNotifier = Object(tryCatch["a" /* tryCatch */])(this.closingSelector)(); + if (closingNotifier === errorObject["a" /* errorObject */]) { + var err = errorObject["a" /* errorObject */].e; + this.destination.error(err); + this.window.error(err); + } + else { + this.add(this.closingNotification = Object(subscribeToResult["a" /* subscribeToResult */])(this, closingNotifier)); + } + }; + return WindowSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=windowWhen.js.map -module.exports = str => { - if (typeof str !== 'string' || str.length === 0) { - return 0; - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/withLatestFrom.js +/** PURE_IMPORTS_START tslib,_OuterSubscriber,_util_subscribeToResult PURE_IMPORTS_END */ - str = stripAnsi(str); - let width = 0; - for (let i = 0; i < str.length; i++) { - const code = str.codePointAt(i); +function withLatestFrom() { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + return function (source) { + var project; + if (typeof args[args.length - 1] === 'function') { + project = args.pop(); + } + var observables = args; + return source.lift(new WithLatestFromOperator(observables, project)); + }; +} +var WithLatestFromOperator = /*@__PURE__*/ (function () { + function WithLatestFromOperator(observables, project) { + this.observables = observables; + this.project = project; + } + WithLatestFromOperator.prototype.call = function (subscriber, source) { + return source.subscribe(new withLatestFrom_WithLatestFromSubscriber(subscriber, this.observables, this.project)); + }; + return WithLatestFromOperator; +}()); +var withLatestFrom_WithLatestFromSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](WithLatestFromSubscriber, _super); + function WithLatestFromSubscriber(destination, observables, project) { + var _this = _super.call(this, destination) || this; + _this.observables = observables; + _this.project = project; + _this.toRespond = []; + var len = observables.length; + _this.values = new Array(len); + for (var i = 0; i < len; i++) { + _this.toRespond.push(i); + } + for (var i = 0; i < len; i++) { + var observable = observables[i]; + _this.add(Object(subscribeToResult["a" /* subscribeToResult */])(_this, observable, observable, i)); + } + return _this; + } + WithLatestFromSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.values[outerIndex] = innerValue; + var toRespond = this.toRespond; + if (toRespond.length > 0) { + var found = toRespond.indexOf(outerIndex); + if (found !== -1) { + toRespond.splice(found, 1); + } + } + }; + WithLatestFromSubscriber.prototype.notifyComplete = function () { + }; + WithLatestFromSubscriber.prototype._next = function (value) { + if (this.toRespond.length === 0) { + var args = [value].concat(this.values); + if (this.project) { + this._tryProject(args); + } + else { + this.destination.next(args); + } + } + }; + WithLatestFromSubscriber.prototype._tryProject = function (args) { + var result; + try { + result = this.project.apply(this, args); + } + catch (err) { + this.destination.error(err); + return; + } + this.destination.next(result); + }; + return WithLatestFromSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=withLatestFrom.js.map - // Ignore control characters - if (code <= 0x1F || (code >= 0x7F && code <= 0x9F)) { - continue; - } +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/zip.js +var zip = __webpack_require__(52); - // Ignore combining characters - if (code >= 0x300 && code <= 0x36F) { - continue; - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/zip.js +/** PURE_IMPORTS_START _observable_zip PURE_IMPORTS_END */ - // Surrogates - if (code > 0xFFFF) { - i++; - } +function zip_zip() { + var observables = []; + for (var _i = 0; _i < arguments.length; _i++) { + observables[_i] = arguments[_i]; + } + return function zipOperatorFunction(source) { + return source.lift.call(zip["b" /* zip */].apply(void 0, [source].concat(observables))); + }; +} +//# sourceMappingURL=zip.js.map - width += isFullwidthCodePoint(code) ? 2 : 1; - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/zipAll.js +/** PURE_IMPORTS_START _observable_zip PURE_IMPORTS_END */ - return width; -}; +function zipAll(project) { + return function (source) { return source.lift(new zip["a" /* ZipOperator */](project)); }; +} +//# sourceMappingURL=zipAll.js.map + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/operators/index.js +/* concated harmony reexport audit */__webpack_require__.d(__webpack_exports__, "audit", function() { return audit; }); +/* concated harmony reexport auditTime */__webpack_require__.d(__webpack_exports__, "auditTime", function() { return auditTime; }); +/* concated harmony reexport buffer */__webpack_require__.d(__webpack_exports__, "buffer", function() { return buffer_buffer; }); +/* concated harmony reexport bufferCount */__webpack_require__.d(__webpack_exports__, "bufferCount", function() { return bufferCount; }); +/* concated harmony reexport bufferTime */__webpack_require__.d(__webpack_exports__, "bufferTime", function() { return bufferTime; }); +/* concated harmony reexport bufferToggle */__webpack_require__.d(__webpack_exports__, "bufferToggle", function() { return bufferToggle; }); +/* concated harmony reexport bufferWhen */__webpack_require__.d(__webpack_exports__, "bufferWhen", function() { return bufferWhen; }); +/* concated harmony reexport catchError */__webpack_require__.d(__webpack_exports__, "catchError", function() { return catchError; }); +/* concated harmony reexport combineAll */__webpack_require__.d(__webpack_exports__, "combineAll", function() { return combineAll; }); +/* concated harmony reexport combineLatest */__webpack_require__.d(__webpack_exports__, "combineLatest", function() { return combineLatest_combineLatest; }); +/* concated harmony reexport concat */__webpack_require__.d(__webpack_exports__, "concat", function() { return concat_concat; }); +/* concated harmony reexport concatAll */__webpack_require__.d(__webpack_exports__, "concatAll", function() { return concatAll["a" /* concatAll */]; }); +/* concated harmony reexport concatMap */__webpack_require__.d(__webpack_exports__, "concatMap", function() { return concatMap; }); +/* concated harmony reexport concatMapTo */__webpack_require__.d(__webpack_exports__, "concatMapTo", function() { return concatMapTo; }); +/* concated harmony reexport count */__webpack_require__.d(__webpack_exports__, "count", function() { return count_count; }); +/* concated harmony reexport debounce */__webpack_require__.d(__webpack_exports__, "debounce", function() { return debounce; }); +/* concated harmony reexport debounceTime */__webpack_require__.d(__webpack_exports__, "debounceTime", function() { return debounceTime; }); +/* concated harmony reexport defaultIfEmpty */__webpack_require__.d(__webpack_exports__, "defaultIfEmpty", function() { return defaultIfEmpty; }); +/* concated harmony reexport delay */__webpack_require__.d(__webpack_exports__, "delay", function() { return delay_delay; }); +/* concated harmony reexport delayWhen */__webpack_require__.d(__webpack_exports__, "delayWhen", function() { return delayWhen; }); +/* concated harmony reexport dematerialize */__webpack_require__.d(__webpack_exports__, "dematerialize", function() { return dematerialize; }); +/* concated harmony reexport distinct */__webpack_require__.d(__webpack_exports__, "distinct", function() { return distinct; }); +/* concated harmony reexport distinctUntilChanged */__webpack_require__.d(__webpack_exports__, "distinctUntilChanged", function() { return distinctUntilChanged; }); +/* concated harmony reexport distinctUntilKeyChanged */__webpack_require__.d(__webpack_exports__, "distinctUntilKeyChanged", function() { return distinctUntilKeyChanged; }); +/* concated harmony reexport elementAt */__webpack_require__.d(__webpack_exports__, "elementAt", function() { return elementAt; }); +/* concated harmony reexport endWith */__webpack_require__.d(__webpack_exports__, "endWith", function() { return endWith; }); +/* concated harmony reexport every */__webpack_require__.d(__webpack_exports__, "every", function() { return every; }); +/* concated harmony reexport exhaust */__webpack_require__.d(__webpack_exports__, "exhaust", function() { return exhaust; }); +/* concated harmony reexport exhaustMap */__webpack_require__.d(__webpack_exports__, "exhaustMap", function() { return exhaustMap; }); +/* concated harmony reexport expand */__webpack_require__.d(__webpack_exports__, "expand", function() { return expand; }); +/* concated harmony reexport filter */__webpack_require__.d(__webpack_exports__, "filter", function() { return filter; }); +/* concated harmony reexport finalize */__webpack_require__.d(__webpack_exports__, "finalize", function() { return finalize; }); +/* concated harmony reexport find */__webpack_require__.d(__webpack_exports__, "find", function() { return find; }); +/* concated harmony reexport findIndex */__webpack_require__.d(__webpack_exports__, "findIndex", function() { return findIndex; }); +/* concated harmony reexport first */__webpack_require__.d(__webpack_exports__, "first", function() { return first; }); +/* concated harmony reexport groupBy */__webpack_require__.d(__webpack_exports__, "groupBy", function() { return groupBy["b" /* groupBy */]; }); +/* concated harmony reexport ignoreElements */__webpack_require__.d(__webpack_exports__, "ignoreElements", function() { return ignoreElements; }); +/* concated harmony reexport isEmpty */__webpack_require__.d(__webpack_exports__, "isEmpty", function() { return isEmpty; }); +/* concated harmony reexport last */__webpack_require__.d(__webpack_exports__, "last", function() { return last; }); +/* concated harmony reexport map */__webpack_require__.d(__webpack_exports__, "map", function() { return map["a" /* map */]; }); +/* concated harmony reexport mapTo */__webpack_require__.d(__webpack_exports__, "mapTo", function() { return mapTo; }); +/* concated harmony reexport materialize */__webpack_require__.d(__webpack_exports__, "materialize", function() { return materialize; }); +/* concated harmony reexport max */__webpack_require__.d(__webpack_exports__, "max", function() { return max_max; }); +/* concated harmony reexport merge */__webpack_require__.d(__webpack_exports__, "merge", function() { return merge_merge; }); +/* concated harmony reexport mergeAll */__webpack_require__.d(__webpack_exports__, "mergeAll", function() { return mergeAll["a" /* mergeAll */]; }); +/* concated harmony reexport mergeMap */__webpack_require__.d(__webpack_exports__, "mergeMap", function() { return mergeMap["a" /* mergeMap */]; }); +/* concated harmony reexport flatMap */__webpack_require__.d(__webpack_exports__, "flatMap", function() { return mergeMap["a" /* mergeMap */]; }); +/* concated harmony reexport mergeMapTo */__webpack_require__.d(__webpack_exports__, "mergeMapTo", function() { return mergeMapTo; }); +/* concated harmony reexport mergeScan */__webpack_require__.d(__webpack_exports__, "mergeScan", function() { return mergeScan; }); +/* concated harmony reexport min */__webpack_require__.d(__webpack_exports__, "min", function() { return min_min; }); +/* concated harmony reexport multicast */__webpack_require__.d(__webpack_exports__, "multicast", function() { return multicast; }); +/* concated harmony reexport observeOn */__webpack_require__.d(__webpack_exports__, "observeOn", function() { return observeOn["b" /* observeOn */]; }); +/* concated harmony reexport onErrorResumeNext */__webpack_require__.d(__webpack_exports__, "onErrorResumeNext", function() { return onErrorResumeNext; }); +/* concated harmony reexport pairwise */__webpack_require__.d(__webpack_exports__, "pairwise", function() { return pairwise; }); +/* concated harmony reexport partition */__webpack_require__.d(__webpack_exports__, "partition", function() { return partition; }); +/* concated harmony reexport pluck */__webpack_require__.d(__webpack_exports__, "pluck", function() { return pluck; }); +/* concated harmony reexport publish */__webpack_require__.d(__webpack_exports__, "publish", function() { return publish; }); +/* concated harmony reexport publishBehavior */__webpack_require__.d(__webpack_exports__, "publishBehavior", function() { return publishBehavior; }); +/* concated harmony reexport publishLast */__webpack_require__.d(__webpack_exports__, "publishLast", function() { return publishLast; }); +/* concated harmony reexport publishReplay */__webpack_require__.d(__webpack_exports__, "publishReplay", function() { return publishReplay; }); +/* concated harmony reexport race */__webpack_require__.d(__webpack_exports__, "race", function() { return race_race; }); +/* concated harmony reexport reduce */__webpack_require__.d(__webpack_exports__, "reduce", function() { return reduce; }); +/* concated harmony reexport repeat */__webpack_require__.d(__webpack_exports__, "repeat", function() { return repeat; }); +/* concated harmony reexport repeatWhen */__webpack_require__.d(__webpack_exports__, "repeatWhen", function() { return repeatWhen; }); +/* concated harmony reexport retry */__webpack_require__.d(__webpack_exports__, "retry", function() { return retry; }); +/* concated harmony reexport retryWhen */__webpack_require__.d(__webpack_exports__, "retryWhen", function() { return retryWhen; }); +/* concated harmony reexport refCount */__webpack_require__.d(__webpack_exports__, "refCount", function() { return operators_refCount["a" /* refCount */]; }); +/* concated harmony reexport sample */__webpack_require__.d(__webpack_exports__, "sample", function() { return sample; }); +/* concated harmony reexport sampleTime */__webpack_require__.d(__webpack_exports__, "sampleTime", function() { return sampleTime; }); +/* concated harmony reexport scan */__webpack_require__.d(__webpack_exports__, "scan", function() { return scan; }); +/* concated harmony reexport sequenceEqual */__webpack_require__.d(__webpack_exports__, "sequenceEqual", function() { return sequenceEqual; }); +/* concated harmony reexport share */__webpack_require__.d(__webpack_exports__, "share", function() { return share; }); +/* concated harmony reexport shareReplay */__webpack_require__.d(__webpack_exports__, "shareReplay", function() { return shareReplay; }); +/* concated harmony reexport single */__webpack_require__.d(__webpack_exports__, "single", function() { return single; }); +/* concated harmony reexport skip */__webpack_require__.d(__webpack_exports__, "skip", function() { return skip; }); +/* concated harmony reexport skipLast */__webpack_require__.d(__webpack_exports__, "skipLast", function() { return skipLast; }); +/* concated harmony reexport skipUntil */__webpack_require__.d(__webpack_exports__, "skipUntil", function() { return skipUntil; }); +/* concated harmony reexport skipWhile */__webpack_require__.d(__webpack_exports__, "skipWhile", function() { return skipWhile; }); +/* concated harmony reexport startWith */__webpack_require__.d(__webpack_exports__, "startWith", function() { return startWith; }); +/* concated harmony reexport subscribeOn */__webpack_require__.d(__webpack_exports__, "subscribeOn", function() { return subscribeOn; }); +/* concated harmony reexport switchAll */__webpack_require__.d(__webpack_exports__, "switchAll", function() { return switchAll; }); +/* concated harmony reexport switchMap */__webpack_require__.d(__webpack_exports__, "switchMap", function() { return switchMap; }); +/* concated harmony reexport switchMapTo */__webpack_require__.d(__webpack_exports__, "switchMapTo", function() { return switchMapTo; }); +/* concated harmony reexport take */__webpack_require__.d(__webpack_exports__, "take", function() { return take; }); +/* concated harmony reexport takeLast */__webpack_require__.d(__webpack_exports__, "takeLast", function() { return takeLast; }); +/* concated harmony reexport takeUntil */__webpack_require__.d(__webpack_exports__, "takeUntil", function() { return takeUntil; }); +/* concated harmony reexport takeWhile */__webpack_require__.d(__webpack_exports__, "takeWhile", function() { return takeWhile; }); +/* concated harmony reexport tap */__webpack_require__.d(__webpack_exports__, "tap", function() { return tap; }); +/* concated harmony reexport throttle */__webpack_require__.d(__webpack_exports__, "throttle", function() { return throttle; }); +/* concated harmony reexport throttleTime */__webpack_require__.d(__webpack_exports__, "throttleTime", function() { return throttleTime; }); +/* concated harmony reexport throwIfEmpty */__webpack_require__.d(__webpack_exports__, "throwIfEmpty", function() { return throwIfEmpty; }); +/* concated harmony reexport timeInterval */__webpack_require__.d(__webpack_exports__, "timeInterval", function() { return timeInterval; }); +/* concated harmony reexport timeout */__webpack_require__.d(__webpack_exports__, "timeout", function() { return timeout; }); +/* concated harmony reexport timeoutWith */__webpack_require__.d(__webpack_exports__, "timeoutWith", function() { return timeoutWith; }); +/* concated harmony reexport timestamp */__webpack_require__.d(__webpack_exports__, "timestamp", function() { return timestamp; }); +/* concated harmony reexport toArray */__webpack_require__.d(__webpack_exports__, "toArray", function() { return toArray; }); +/* concated harmony reexport window */__webpack_require__.d(__webpack_exports__, "window", function() { return window_window; }); +/* concated harmony reexport windowCount */__webpack_require__.d(__webpack_exports__, "windowCount", function() { return windowCount; }); +/* concated harmony reexport windowTime */__webpack_require__.d(__webpack_exports__, "windowTime", function() { return windowTime_windowTime; }); +/* concated harmony reexport windowToggle */__webpack_require__.d(__webpack_exports__, "windowToggle", function() { return windowToggle; }); +/* concated harmony reexport windowWhen */__webpack_require__.d(__webpack_exports__, "windowWhen", function() { return windowWhen; }); +/* concated harmony reexport withLatestFrom */__webpack_require__.d(__webpack_exports__, "withLatestFrom", function() { return withLatestFrom; }); +/* concated harmony reexport zip */__webpack_require__.d(__webpack_exports__, "zip", function() { return zip_zip; }); +/* concated harmony reexport zipAll */__webpack_require__.d(__webpack_exports__, "zipAll", function() { return zipAll; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ -/***/ }), -/* 379 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -const ansiRegex = __webpack_require__(380); -module.exports = input => typeof input === 'string' ? input.replace(ansiRegex(), '') : input; -/***/ }), -/* 380 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -module.exports = () => { - const pattern = [ - '[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[a-zA-Z\\d]*)*)?\\u0007)', - '(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PRZcf-ntqry=><~]))' - ].join('|'); - return new RegExp(pattern, 'g'); -}; -/***/ }), -/* 381 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -/* eslint-disable yoda */ -module.exports = x => { - if (Number.isNaN(x)) { - return false; - } - // code points are derived from: - // http://www.unix.org/Public/UNIDATA/EastAsianWidth.txt - if ( - x >= 0x1100 && ( - x <= 0x115f || // Hangul Jamo - x === 0x2329 || // LEFT-POINTING ANGLE BRACKET - x === 0x232a || // RIGHT-POINTING ANGLE BRACKET - // CJK Radicals Supplement .. Enclosed CJK Letters and Months - (0x2e80 <= x && x <= 0x3247 && x !== 0x303f) || - // Enclosed CJK Letters and Months .. CJK Unified Ideographs Extension A - (0x3250 <= x && x <= 0x4dbf) || - // CJK Unified Ideographs .. Yi Radicals - (0x4e00 <= x && x <= 0xa4c6) || - // Hangul Jamo Extended-A - (0xa960 <= x && x <= 0xa97c) || - // Hangul Syllables - (0xac00 <= x && x <= 0xd7a3) || - // CJK Compatibility Ideographs - (0xf900 <= x && x <= 0xfaff) || - // Vertical Forms - (0xfe10 <= x && x <= 0xfe19) || - // CJK Compatibility Forms .. Small Form Variants - (0xfe30 <= x && x <= 0xfe6b) || - // Halfwidth and Fullwidth Forms - (0xff01 <= x && x <= 0xff60) || - (0xffe0 <= x && x <= 0xffe6) || - // Kana Supplement - (0x1b000 <= x && x <= 0x1b001) || - // Enclosed Ideographic Supplement - (0x1f200 <= x && x <= 0x1f251) || - // CJK Unified Ideographs Extension B .. Tertiary Ideographic Plane - (0x20000 <= x && x <= 0x3fffd) - ) - ) { - return true; - } - return false; -}; -/***/ }), -/* 382 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -const ansiRegex = __webpack_require__(383); -module.exports = input => typeof input === 'string' ? input.replace(ansiRegex(), '') : input; -/***/ }), -/* 383 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -module.exports = () => { - const pattern = [ - '[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[a-zA-Z\\d]*)*)?\\u0007)', - '(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PRZcf-ntqry=><~]))' - ].join('|'); - return new RegExp(pattern, 'g'); -}; -/***/ }), -/* 384 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.renderProjectsTree = renderProjectsTree; -var _chalk = __webpack_require__(17); -var _chalk2 = _interopRequireDefault(_chalk); -var _path = __webpack_require__(2); -var _path2 = _interopRequireDefault(_path); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -/* - * 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. - */ -const projectKey = Symbol('__project'); -function renderProjectsTree(rootPath, projects) { - const projectsTree = buildProjectsTree(rootPath, projects); - return treeToString(createTreeStructure(projectsTree)); -} -function treeToString(tree) { - return [tree.name].concat(childrenToStrings(tree.children, '')).join('\n'); -} -function childrenToStrings(tree, treePrefix) { - if (tree === undefined) { - return []; - } - let strings = []; - tree.forEach((node, index) => { - const isLastNode = tree.length - 1 === index; - const nodePrefix = isLastNode ? '└── ' : '├── '; - const childPrefix = isLastNode ? ' ' : '│ '; - const childrenPrefix = treePrefix + childPrefix; - strings.push(`${treePrefix}${nodePrefix}${node.name}`); - strings = strings.concat(childrenToStrings(node.children, childrenPrefix)); - }); - return strings; -} -function createTreeStructure(tree) { - let name; - const children = []; - for (const [dir, project] of tree.entries()) { - // This is a leaf node (aka a project) - if (typeof project === 'string') { - name = _chalk2.default.green(project); - continue; - } - // If there's only one project and the key indicates it's a leaf node, we - // know that we're at a package folder that contains a package.json, so we - // "inline it" so we don't get unnecessary levels, i.e. we'll just see - // `foo` instead of `foo -> foo`. - if (project.size === 1 && project.has(projectKey)) { - const projectName = project.get(projectKey); - children.push({ - children: [], - name: dirOrProjectName(dir, projectName) - }); - continue; - } - const subtree = createTreeStructure(project); - // If the name is specified, we know there's a package at the "root" of the - // subtree itself. - if (subtree.name !== undefined) { - const projectName = subtree.name; - children.push({ - children: subtree.children, - name: dirOrProjectName(dir, projectName) - }); - continue; - } - // Special-case whenever we have one child, so we don't get unnecessary - // folders in the output. E.g. instead of `foo -> bar -> baz` we get - // `foo/bar/baz` instead. - if (subtree.children && subtree.children.length === 1) { - const child = subtree.children[0]; - const newName = _chalk2.default.dim(_path2.default.join(dir.toString(), child.name)); - children.push({ - children: child.children, - name: newName - }); - continue; - } - children.push({ - children: subtree.children, - name: _chalk2.default.dim(dir.toString()) - }); - } - return { name, children }; -} -function dirOrProjectName(dir, projectName) { - return dir === projectName ? _chalk2.default.green(dir) : _chalk2.default`{dim ${dir.toString()} ({reset.green ${projectName}})}`; -} -function buildProjectsTree(rootPath, projects) { - const tree = new Map(); - for (const project of projects.values()) { - if (rootPath === project.path) { - tree.set(projectKey, project.name); - } else { - const relativeProjectPath = _path2.default.relative(rootPath, project.path); - addProjectToTree(tree, relativeProjectPath.split(_path2.default.sep), project); - } - } - return tree; -} -function addProjectToTree(tree, pathParts, project) { - if (pathParts.length === 0) { - tree.set(projectKey, project.name); - } else { - const [currentDir, ...rest] = pathParts; - if (!tree.has(currentDir)) { - tree.set(currentDir, new Map()); - } - const subtree = tree.get(currentDir); - addProjectToTree(subtree, rest, project); - } -} -/***/ }), -/* 385 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); -var _build_production_projects = __webpack_require__(386); -Object.defineProperty(exports, 'buildProductionProjects', { - enumerable: true, - get: function () { - return _build_production_projects.buildProductionProjects; - } -}); -var _prepare_project_dependencies = __webpack_require__(398); -Object.defineProperty(exports, 'prepareExternalProjectDependencies', { - enumerable: true, - get: function () { - return _prepare_project_dependencies.prepareExternalProjectDependencies; - } -}); -/***/ }), -/* 386 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.buildProductionProjects = undefined; -let buildProductionProjects = exports.buildProductionProjects = (() => { - var _ref = _asyncToGenerator(function* ({ kibanaRoot, buildRoots }) { - const projects = yield getProductionProjects(kibanaRoot); - const projectGraph = (0, _projects.buildProjectGraph)(projects); - const batchedProjects = (0, _projects.topologicallyBatchProjects)(projects, projectGraph); - const projectNames = [...projects.values()].map(function (project) { - return project.name; - }); - _log.log.write(`Preparing production build for [${projectNames.join(', ')}]`); - for (const batch of batchedProjects) { - for (const project of batch) { - yield deleteTarget(project); - yield buildProject(project); - for (const buildRoot of buildRoots) { - yield copyToBuild(project, kibanaRoot, buildRoot); - } - } - } - }); - return function buildProductionProjects(_x) { - return _ref.apply(this, arguments); - }; -})(); -/** - * Returns the subset of projects that should be built into the production - * bundle. As we copy these into Kibana's `node_modules` during the build step, - * and let Kibana's build process be responsible for installing dependencies, - * we only include Kibana's transitive _production_ dependencies. - */ -let getProductionProjects = (() => { - var _ref2 = _asyncToGenerator(function* (rootPath) { - const projectPaths = (0, _config.getProjectPaths)(rootPath, {}); - const projects = yield (0, _projects.getProjects)(rootPath, projectPaths); - const productionProjects = (0, _projects.includeTransitiveProjects)([projects.get('kibana')], projects, { - onlyProductionDependencies: true - }); - // We remove Kibana, as we're already building Kibana - productionProjects.delete('kibana'); - return productionProjects; - }); - return function getProductionProjects(_x2) { - return _ref2.apply(this, arguments); - }; -})(); -let deleteTarget = (() => { - var _ref3 = _asyncToGenerator(function* (project) { - const targetDir = project.targetLocation; - if (yield (0, _fs.isDirectory)(targetDir)) { - yield (0, _del2.default)(targetDir, { force: true }); - } - }); - return function deleteTarget(_x3) { - return _ref3.apply(this, arguments); - }; -})(); -let buildProject = (() => { - var _ref4 = _asyncToGenerator(function* (project) { - if (project.hasScript('build')) { - yield project.runScript('build'); - } - }); - return function buildProject(_x4) { - return _ref4.apply(this, arguments); - }; -})(); -/** - * Copy all the project's files from its "intermediate build directory" and - * into the build. The intermediate directory can either be the root of the - * project or some other location defined in the project's `package.json`. - * - * When copying all the files into the build, we exclude `node_modules` because - * we want the Kibana build to be responsible for actually installing all - * dependencies. The primary reason for allowing the Kibana build process to - * manage dependencies is that it will "dedupe" them, so we don't include - * unnecessary copies of dependencies. - */ -let copyToBuild = (() => { - var _ref5 = _asyncToGenerator(function* (project, kibanaRoot, buildRoot) { - // We want the package to have the same relative location within the build - const relativeProjectPath = (0, _path.relative)(kibanaRoot, project.path); - const buildProjectPath = (0, _path.resolve)(buildRoot, relativeProjectPath); - yield (0, _cpy2.default)(['**/*', '!node_modules/**'], buildProjectPath, { - cwd: project.getIntermediateBuildDirectory(), - dot: true, - nodir: true, - parents: true - }); - // If a project is using an intermediate build directory, we special-case our - // handling of `package.json`, as the project build process might have copied - // (a potentially modified) `package.json` into the intermediate build - // directory already. If so, we want to use that `package.json` as the basis - // for creating the production-ready `package.json`. If it's not present in - // the intermediate build, we fall back to using the project's already defined - // `package.json`. - const packageJson = (yield (0, _fs.isFile)((0, _path.join)(buildProjectPath, 'package.json'))) ? yield (0, _package_json.readPackageJson)(buildProjectPath) : project.json; - yield (0, _package_json.writePackageJson)(buildProjectPath, packageJson); - }); - return function copyToBuild(_x5, _x6, _x7) { - return _ref5.apply(this, arguments); - }; -})(); -var _cpy = __webpack_require__(387); -var _cpy2 = _interopRequireDefault(_cpy); -var _del = __webpack_require__(98); -var _del2 = _interopRequireDefault(_del); -var _path = __webpack_require__(2); -var _config = __webpack_require__(60); -var _fs = __webpack_require__(39); -var _log = __webpack_require__(19); -var _package_json = __webpack_require__(41); -var _projects = __webpack_require__(22); -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* - * 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. - */ -/***/ }), -/* 387 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -const EventEmitter = __webpack_require__(40); -const path = __webpack_require__(2); -const arrify = __webpack_require__(388); -const globby = __webpack_require__(389); -const cpFile = __webpack_require__(391); -const CpyError = __webpack_require__(397); -const preprocessSrcPath = (srcPath, opts) => opts.cwd ? path.resolve(opts.cwd, srcPath) : srcPath; -const preprocessDestPath = (srcPath, dest, opts) => { - let basename = path.basename(srcPath); - const dirname = path.dirname(srcPath); - if (typeof opts.rename === 'string') { - basename = opts.rename; - } else if (typeof opts.rename === 'function') { - basename = opts.rename(basename); - } - if (opts.cwd) { - dest = path.resolve(opts.cwd, dest); - } - if (opts.parents) { - return path.join(dest, dirname, basename); - } - return path.join(dest, basename); -}; -module.exports = (src, dest, opts) => { - src = arrify(src); - opts = opts || {}; - if (src.length === 0 || !dest) { - return Promise.reject(new CpyError('`files` and `destination` required')); - } - const progressEmitter = new EventEmitter(); - const copyStatus = new Map(); - let completedFiles = 0; - let completedSize = 0; - const promise = globby(src, opts) - .catch(err => { - throw new CpyError(`Cannot glob \`${src}\`: ${err.message}`, err); - }) - .then(files => { - if (files.length === 0) { - progressEmitter.emit('progress', { - totalFiles: 0, - percent: 1, - completedFiles: 0, - completedSize: 0 - }); - } - return Promise.all(files.map(srcPath => { - const from = preprocessSrcPath(srcPath, opts); - const to = preprocessDestPath(srcPath, dest, opts); - return cpFile(from, to, opts) - .on('progress', event => { - const fileStatus = copyStatus.get(event.src) || {written: 0, percent: 0}; - if (fileStatus.written !== event.written || fileStatus.percent !== event.percent) { - completedSize -= fileStatus.written; - completedSize += event.written; - if (event.percent === 1 && fileStatus.percent !== 1) { - completedFiles++; - } - copyStatus.set(event.src, {written: event.written, percent: event.percent}); - progressEmitter.emit('progress', { - totalFiles: files.length, - percent: completedFiles / files.length, - completedFiles, - completedSize - }); - } - }) - .catch(err => { - throw new CpyError(`Cannot copy from \`${from}\` to \`${to}\`: ${err.message}`, err); - }); - })); - }); - promise.on = function () { - progressEmitter.on.apply(progressEmitter, arguments); - return promise; - }; - return promise; -}; -/***/ }), -/* 388 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -module.exports = function (val) { - if (val === null || val === undefined) { - return []; - } - return Array.isArray(val) ? val : [val]; -}; + + + +//# sourceMappingURL=index.js.map /***/ }), -/* 389 */ -/***/ (function(module, exports, __webpack_require__) { +/* 263 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; +__webpack_require__.r(__webpack_exports__); -var Promise = __webpack_require__(99); -var arrayUnion = __webpack_require__(100); -var objectAssign = __webpack_require__(101); -var glob = __webpack_require__(23); -var pify = __webpack_require__(390); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Observable.js + 1 modules +var Observable = __webpack_require__(2); -var globP = pify(glob, Promise).bind(glob); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/ConnectableObservable.js +var ConnectableObservable = __webpack_require__(64); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/groupBy.js +var groupBy = __webpack_require__(63); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/symbol/observable.js +var observable = __webpack_require__(24); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subject.js +var Subject = __webpack_require__(8); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/BehaviorSubject.js +var BehaviorSubject = __webpack_require__(65); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/ReplaySubject.js +var ReplaySubject = __webpack_require__(46); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/AsyncSubject.js +var AsyncSubject = __webpack_require__(33); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/asap.js + 3 modules +var asap = __webpack_require__(54); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/async.js +var scheduler_async = __webpack_require__(10); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/queue.js + 2 modules +var queue = __webpack_require__(72); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/node_modules/tslib/tslib.es6.js +var tslib_es6 = __webpack_require__(0); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsyncAction.js + 1 modules +var AsyncAction = __webpack_require__(34); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AnimationFrameAction.js +/** PURE_IMPORTS_START tslib,_AsyncAction PURE_IMPORTS_END */ + + +var AnimationFrameAction_AnimationFrameAction = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](AnimationFrameAction, _super); + function AnimationFrameAction(scheduler, work) { + var _this = _super.call(this, scheduler, work) || this; + _this.scheduler = scheduler; + _this.work = work; + return _this; + } + AnimationFrameAction.prototype.requestAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; + } + if (delay !== null && delay > 0) { + return _super.prototype.requestAsyncId.call(this, scheduler, id, delay); + } + scheduler.actions.push(this); + return scheduler.scheduled || (scheduler.scheduled = requestAnimationFrame(function () { return scheduler.flush(null); })); + }; + AnimationFrameAction.prototype.recycleAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; + } + if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { + return _super.prototype.recycleAsyncId.call(this, scheduler, id, delay); + } + if (scheduler.actions.length === 0) { + cancelAnimationFrame(id); + scheduler.scheduled = undefined; + } + return undefined; + }; + return AnimationFrameAction; +}(AsyncAction["a" /* AsyncAction */])); + +//# sourceMappingURL=AnimationFrameAction.js.map + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AsyncScheduler.js +var AsyncScheduler = __webpack_require__(32); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/AnimationFrameScheduler.js +/** PURE_IMPORTS_START tslib,_AsyncScheduler PURE_IMPORTS_END */ + + +var AnimationFrameScheduler_AnimationFrameScheduler = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](AnimationFrameScheduler, _super); + function AnimationFrameScheduler() { + return _super !== null && _super.apply(this, arguments) || this; + } + AnimationFrameScheduler.prototype.flush = function (action) { + this.active = true; + this.scheduled = undefined; + var actions = this.actions; + var error; + var index = -1; + var count = actions.length; + action = action || actions.shift(); + do { + if (error = action.execute(action.state, action.delay)) { + break; + } + } while (++index < count && (action = actions.shift())); + this.active = false; + if (error) { + while (++index < count && (action = actions.shift())) { + action.unsubscribe(); + } + throw error; + } + }; + return AnimationFrameScheduler; +}(AsyncScheduler["a" /* AsyncScheduler */])); -function isNegative(pattern) { - return pattern[0] === '!'; -} +//# sourceMappingURL=AnimationFrameScheduler.js.map -function isString(value) { - return typeof value === 'string'; -} +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/animationFrame.js +/** PURE_IMPORTS_START _AnimationFrameAction,_AnimationFrameScheduler PURE_IMPORTS_END */ -function assertPatternsInput(patterns) { - if (!patterns.every(isString)) { - throw new TypeError('patterns must be a string or an array of strings'); - } -} -function generateGlobTasks(patterns, opts) { - patterns = [].concat(patterns); - assertPatternsInput(patterns); +var animationFrame = /*@__PURE__*/ new AnimationFrameScheduler_AnimationFrameScheduler(AnimationFrameAction_AnimationFrameAction); +//# sourceMappingURL=animationFrame.js.map - var globTasks = []; +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/scheduler/VirtualTimeScheduler.js +/** PURE_IMPORTS_START tslib,_AsyncAction,_AsyncScheduler PURE_IMPORTS_END */ - opts = objectAssign({ - cache: Object.create(null), - statCache: Object.create(null), - realpathCache: Object.create(null), - symlinks: Object.create(null), - ignore: [] - }, opts); - patterns.forEach(function (pattern, i) { - if (isNegative(pattern)) { - return; - } - var ignore = patterns.slice(i).filter(isNegative).map(function (pattern) { - return pattern.slice(1); - }); +var VirtualTimeScheduler_VirtualTimeScheduler = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](VirtualTimeScheduler, _super); + function VirtualTimeScheduler(SchedulerAction, maxFrames) { + if (SchedulerAction === void 0) { + SchedulerAction = VirtualTimeScheduler_VirtualAction; + } + if (maxFrames === void 0) { + maxFrames = Number.POSITIVE_INFINITY; + } + var _this = _super.call(this, SchedulerAction, function () { return _this.frame; }) || this; + _this.maxFrames = maxFrames; + _this.frame = 0; + _this.index = -1; + return _this; + } + VirtualTimeScheduler.prototype.flush = function () { + var _a = this, actions = _a.actions, maxFrames = _a.maxFrames; + var error, action; + while ((action = actions.shift()) && (this.frame = action.delay) <= maxFrames) { + if (error = action.execute(action.state, action.delay)) { + break; + } + } + if (error) { + while (action = actions.shift()) { + action.unsubscribe(); + } + throw error; + } + }; + VirtualTimeScheduler.frameTimeFactor = 10; + return VirtualTimeScheduler; +}(AsyncScheduler["a" /* AsyncScheduler */])); - globTasks.push({ - pattern: pattern, - opts: objectAssign({}, opts, { - ignore: opts.ignore.concat(ignore) - }) - }); - }); +var VirtualTimeScheduler_VirtualAction = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](VirtualAction, _super); + function VirtualAction(scheduler, work, index) { + if (index === void 0) { + index = scheduler.index += 1; + } + var _this = _super.call(this, scheduler, work) || this; + _this.scheduler = scheduler; + _this.work = work; + _this.index = index; + _this.active = true; + _this.index = scheduler.index = index; + return _this; + } + VirtualAction.prototype.schedule = function (state, delay) { + if (delay === void 0) { + delay = 0; + } + if (!this.id) { + return _super.prototype.schedule.call(this, state, delay); + } + this.active = false; + var action = new VirtualAction(this.scheduler, this.work); + this.add(action); + return action.schedule(state, delay); + }; + VirtualAction.prototype.requestAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; + } + this.delay = scheduler.frame + delay; + var actions = scheduler.actions; + actions.push(this); + actions.sort(VirtualAction.sortActions); + return true; + }; + VirtualAction.prototype.recycleAsyncId = function (scheduler, id, delay) { + if (delay === void 0) { + delay = 0; + } + return undefined; + }; + VirtualAction.prototype._execute = function (state, delay) { + if (this.active === true) { + return _super.prototype._execute.call(this, state, delay); + } + }; + VirtualAction.sortActions = function (a, b) { + if (a.delay === b.delay) { + if (a.index === b.index) { + return 0; + } + else if (a.index > b.index) { + return 1; + } + else { + return -1; + } + } + else if (a.delay > b.delay) { + return 1; + } + else { + return -1; + } + }; + return VirtualAction; +}(AsyncAction["a" /* AsyncAction */])); - return globTasks; -} +//# sourceMappingURL=VirtualTimeScheduler.js.map -module.exports = function (patterns, opts) { - var globTasks; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Scheduler.js +var Scheduler = __webpack_require__(58); - try { - globTasks = generateGlobTasks(patterns, opts); - } catch (err) { - return Promise.reject(err); - } +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subscription.js +var Subscription = __webpack_require__(5); - return Promise.all(globTasks.map(function (task) { - return globP(task.pattern, task.opts); - })).then(function (paths) { - return arrayUnion.apply(null, paths); - }); -}; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Subscriber.js +var Subscriber = __webpack_require__(1); -module.exports.sync = function (patterns, opts) { - var globTasks = generateGlobTasks(patterns, opts); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/Notification.js +var Notification = __webpack_require__(22); - return globTasks.reduce(function (matches, task) { - return arrayUnion(matches, glob.sync(task.pattern, task.opts)); - }, []); -}; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/pipe.js +var pipe = __webpack_require__(39); -module.exports.generateGlobTasks = generateGlobTasks; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/noop.js +var noop = __webpack_require__(20); -module.exports.hasMagic = function (patterns, opts) { - return [].concat(patterns).some(function (pattern) { - return glob.hasMagic(pattern, opts); - }); -}; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/identity.js +var identity = __webpack_require__(21); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isObservable.js +/** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ -/***/ }), -/* 390 */ -/***/ (function(module, exports, __webpack_require__) { +function isObservable(obj) { + return !!obj && (obj instanceof Observable["a" /* Observable */] || (typeof obj.lift === 'function' && typeof obj.subscribe === 'function')); +} +//# sourceMappingURL=isObservable.js.map -"use strict"; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/ArgumentOutOfRangeError.js +var ArgumentOutOfRangeError = __webpack_require__(28); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/EmptyError.js +var EmptyError = __webpack_require__(31); -var processFn = function (fn, P, opts) { - return function () { - var that = this; - var args = new Array(arguments.length); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/ObjectUnsubscribedError.js +var ObjectUnsubscribedError = __webpack_require__(25); - for (var i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/UnsubscriptionError.js +var UnsubscriptionError = __webpack_require__(40); - return new P(function (resolve, reject) { - args.push(function (err, result) { - if (err) { - reject(err); - } else if (opts.multiArgs) { - var results = new Array(arguments.length - 1); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/TimeoutError.js +var TimeoutError = __webpack_require__(67); - for (var i = 1; i < arguments.length; i++) { - results[i - 1] = arguments[i]; - } +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/operators/map.js +var map = __webpack_require__(13); - resolve(results); - } else { - resolve(result); - } - }); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isArray.js +var isArray = __webpack_require__(11); - fn.apply(that, args); - }); - }; -}; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isScheduler.js +var isScheduler = __webpack_require__(12); -var pify = module.exports = function (obj, P, opts) { - if (typeof P !== 'function') { - opts = P; - P = Promise; - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/bindCallback.js +/** PURE_IMPORTS_START _Observable,_AsyncSubject,_operators_map,_util_isArray,_util_isScheduler PURE_IMPORTS_END */ - opts = opts || {}; - opts.exclude = opts.exclude || [/.+Sync$/]; - var filter = function (key) { - var match = function (pattern) { - return typeof pattern === 'string' ? key === pattern : pattern.test(key); - }; - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; - var ret = typeof obj === 'function' ? function () { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } - return processFn(obj, P, opts).apply(this, arguments); - } : {}; +function bindCallback(callbackFunc, resultSelector, scheduler) { + if (resultSelector) { + if (Object(isScheduler["a" /* isScheduler */])(resultSelector)) { + scheduler = resultSelector; + } + else { + return function () { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + return bindCallback(callbackFunc, scheduler).apply(void 0, args).pipe(Object(map["a" /* map */])(function (args) { return Object(isArray["a" /* isArray */])(args) ? resultSelector.apply(void 0, args) : resultSelector(args); })); + }; + } + } + return function () { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + var context = this; + var subject; + var params = { + context: context, + subject: subject, + callbackFunc: callbackFunc, + scheduler: scheduler, + }; + return new Observable["a" /* Observable */](function (subscriber) { + if (!scheduler) { + if (!subject) { + subject = new AsyncSubject["a" /* AsyncSubject */](); + var handler = function () { + var innerArgs = []; + for (var _i = 0; _i < arguments.length; _i++) { + innerArgs[_i] = arguments[_i]; + } + subject.next(innerArgs.length <= 1 ? innerArgs[0] : innerArgs); + subject.complete(); + }; + try { + callbackFunc.apply(context, args.concat([handler])); + } + catch (err) { + subject.error(err); + } + } + return subject.subscribe(subscriber); + } + else { + var state = { + args: args, subscriber: subscriber, params: params, + }; + return scheduler.schedule(dispatch, 0, state); + } + }); + }; +} +function dispatch(state) { + var _this = this; + var self = this; + var args = state.args, subscriber = state.subscriber, params = state.params; + var callbackFunc = params.callbackFunc, context = params.context, scheduler = params.scheduler; + var subject = params.subject; + if (!subject) { + subject = params.subject = new AsyncSubject["a" /* AsyncSubject */](); + var handler = function () { + var innerArgs = []; + for (var _i = 0; _i < arguments.length; _i++) { + innerArgs[_i] = arguments[_i]; + } + var value = innerArgs.length <= 1 ? innerArgs[0] : innerArgs; + _this.add(scheduler.schedule(dispatchNext, 0, { value: value, subject: subject })); + }; + try { + callbackFunc.apply(context, args.concat([handler])); + } + catch (err) { + subject.error(err); + } + } + this.add(subject.subscribe(subscriber)); +} +function dispatchNext(state) { + var value = state.value, subject = state.subject; + subject.next(value); + subject.complete(); +} +function dispatchError(state) { + var err = state.err, subject = state.subject; + subject.error(err); +} +//# sourceMappingURL=bindCallback.js.map - return Object.keys(obj).reduce(function (ret, key) { - var x = obj[key]; +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/bindNodeCallback.js +/** PURE_IMPORTS_START _Observable,_AsyncSubject,_operators_map,_util_isScheduler,_util_isArray PURE_IMPORTS_END */ - ret[key] = typeof x === 'function' && filter(key) ? processFn(x, P, opts) : x; - return ret; - }, ret); -}; -pify.all = pify; -/***/ }), -/* 391 */ -/***/ (function(module, exports, __webpack_require__) { +function bindNodeCallback(callbackFunc, resultSelector, scheduler) { + if (resultSelector) { + if (Object(isScheduler["a" /* isScheduler */])(resultSelector)) { + scheduler = resultSelector; + } + else { + return function () { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + return bindNodeCallback(callbackFunc, scheduler).apply(void 0, args).pipe(Object(map["a" /* map */])(function (args) { return Object(isArray["a" /* isArray */])(args) ? resultSelector.apply(void 0, args) : resultSelector(args); })); + }; + } + } + return function () { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + var params = { + subject: undefined, + args: args, + callbackFunc: callbackFunc, + scheduler: scheduler, + context: this, + }; + return new Observable["a" /* Observable */](function (subscriber) { + var context = params.context; + var subject = params.subject; + if (!scheduler) { + if (!subject) { + subject = params.subject = new AsyncSubject["a" /* AsyncSubject */](); + var handler = function () { + var innerArgs = []; + for (var _i = 0; _i < arguments.length; _i++) { + innerArgs[_i] = arguments[_i]; + } + var err = innerArgs.shift(); + if (err) { + subject.error(err); + return; + } + subject.next(innerArgs.length <= 1 ? innerArgs[0] : innerArgs); + subject.complete(); + }; + try { + callbackFunc.apply(context, args.concat([handler])); + } + catch (err) { + subject.error(err); + } + } + return subject.subscribe(subscriber); + } + else { + return scheduler.schedule(bindNodeCallback_dispatch, 0, { params: params, subscriber: subscriber, context: context }); + } + }); + }; +} +function bindNodeCallback_dispatch(state) { + var _this = this; + var params = state.params, subscriber = state.subscriber, context = state.context; + var callbackFunc = params.callbackFunc, args = params.args, scheduler = params.scheduler; + var subject = params.subject; + if (!subject) { + subject = params.subject = new AsyncSubject["a" /* AsyncSubject */](); + var handler = function () { + var innerArgs = []; + for (var _i = 0; _i < arguments.length; _i++) { + innerArgs[_i] = arguments[_i]; + } + var err = innerArgs.shift(); + if (err) { + _this.add(scheduler.schedule(bindNodeCallback_dispatchError, 0, { err: err, subject: subject })); + } + else { + var value = innerArgs.length <= 1 ? innerArgs[0] : innerArgs; + _this.add(scheduler.schedule(bindNodeCallback_dispatchNext, 0, { value: value, subject: subject })); + } + }; + try { + callbackFunc.apply(context, args.concat([handler])); + } + catch (err) { + this.add(scheduler.schedule(bindNodeCallback_dispatchError, 0, { err: err, subject: subject })); + } + } + this.add(subject.subscribe(subscriber)); +} +function bindNodeCallback_dispatchNext(arg) { + var value = arg.value, subject = arg.subject; + subject.next(value); + subject.complete(); +} +function bindNodeCallback_dispatchError(arg) { + var err = arg.err, subject = arg.subject; + subject.error(err); +} +//# sourceMappingURL=bindNodeCallback.js.map -"use strict"; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/combineLatest.js +var combineLatest = __webpack_require__(49); -const path = __webpack_require__(2); -const fsConstants = __webpack_require__(6).constants; -const Buffer = __webpack_require__(392).Buffer; -const CpFileError = __webpack_require__(134); -const fs = __webpack_require__(394); -const ProgressEmitter = __webpack_require__(396); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/concat.js +var concat = __webpack_require__(26); -module.exports = (src, dest, opts) => { - if (!src || !dest) { - return Promise.reject(new CpFileError('`src` and `dest` required')); - } +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/defer.js +var defer = __webpack_require__(51); - opts = Object.assign({overwrite: true}, opts); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/empty.js +var empty = __webpack_require__(9); - const progressEmitter = new ProgressEmitter(path.resolve(src), path.resolve(dest)); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/subscribeToResult.js + 1 modules +var subscribeToResult = __webpack_require__(3); - const promise = fs - .stat(src) - .then(stat => { - progressEmitter.size = stat.size; - }) - .then(() => fs.createReadStream(src)) - .then(read => fs.makeDir(path.dirname(dest)).then(() => read)) - .then(read => new Promise((resolve, reject) => { - const write = fs.createWriteStream(dest, {flags: opts.overwrite ? 'w' : 'wx'}); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/OuterSubscriber.js +var OuterSubscriber = __webpack_require__(4); - read.on('data', () => { - progressEmitter.written = write.bytesWritten; - }); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/forkJoin.js +/** PURE_IMPORTS_START tslib,_Observable,_util_isArray,_empty,_util_subscribeToResult,_OuterSubscriber,_operators_map PURE_IMPORTS_END */ - write.on('error', err => { - if (!opts.overwrite && err.code === 'EEXIST') { - resolve(false); - return; - } - reject(new CpFileError(`Cannot write to \`${dest}\`: ${err.message}`, err)); - }); - write.on('close', () => { - progressEmitter.written = progressEmitter.size; - resolve(true); - }); - read.pipe(write); - })) - .then(updateStats => { - if (updateStats) { - return fs.lstat(src).then(stats => Promise.all([ - fs.utimes(dest, stats.atime, stats.mtime), - fs.chmod(dest, stats.mode), - fs.chown(dest, stats.uid, stats.gid) - ])); - } - }); - promise.on = function () { - progressEmitter.on.apply(progressEmitter, arguments); - return promise; - }; - return promise; -}; -const checkSrcIsFile = (stat, src) => { - if (stat.isDirectory()) { - throw Object.assign(new CpFileError(`EISDIR: illegal operation on a directory '${src}'`), { - errno: -21, - code: 'EISDIR', - src - }); - } -}; +function forkJoin() { + var sources = []; + for (var _i = 0; _i < arguments.length; _i++) { + sources[_i] = arguments[_i]; + } + var resultSelector; + if (typeof sources[sources.length - 1] === 'function') { + resultSelector = sources.pop(); + } + if (sources.length === 1 && Object(isArray["a" /* isArray */])(sources[0])) { + sources = sources[0]; + } + if (sources.length === 0) { + return empty["a" /* EMPTY */]; + } + if (resultSelector) { + return forkJoin(sources).pipe(Object(map["a" /* map */])(function (args) { return resultSelector.apply(void 0, args); })); + } + return new Observable["a" /* Observable */](function (subscriber) { + return new forkJoin_ForkJoinSubscriber(subscriber, sources); + }); +} +var forkJoin_ForkJoinSubscriber = /*@__PURE__*/ (function (_super) { + tslib_es6["a" /* __extends */](ForkJoinSubscriber, _super); + function ForkJoinSubscriber(destination, sources) { + var _this = _super.call(this, destination) || this; + _this.sources = sources; + _this.completed = 0; + _this.haveValues = 0; + var len = sources.length; + _this.values = new Array(len); + for (var i = 0; i < len; i++) { + var source = sources[i]; + var innerSubscription = Object(subscribeToResult["a" /* subscribeToResult */])(_this, source, null, i); + if (innerSubscription) { + _this.add(innerSubscription); + } + } + return _this; + } + ForkJoinSubscriber.prototype.notifyNext = function (outerValue, innerValue, outerIndex, innerIndex, innerSub) { + this.values[outerIndex] = innerValue; + if (!innerSub._hasValue) { + innerSub._hasValue = true; + this.haveValues++; + } + }; + ForkJoinSubscriber.prototype.notifyComplete = function (innerSub) { + var _a = this, destination = _a.destination, haveValues = _a.haveValues, values = _a.values; + var len = values.length; + if (!innerSub._hasValue) { + destination.complete(); + return; + } + this.completed++; + if (this.completed !== len) { + return; + } + if (haveValues === len) { + destination.next(values); + } + destination.complete(); + }; + return ForkJoinSubscriber; +}(OuterSubscriber["a" /* OuterSubscriber */])); +//# sourceMappingURL=forkJoin.js.map -const fixupAttributes = (dest, stat) => { - fs.chmodSync(dest, stat.mode); - fs.chownSync(dest, stat.uid, stat.gid); -}; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/from.js + 5 modules +var from = __webpack_require__(15); -const copySyncNative = (src, dest, opts) => { - const stat = fs.statSync(src); - checkSrcIsFile(stat, src); - fs.makeDirSync(path.dirname(dest)); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isFunction.js +var isFunction = __webpack_require__(29); - const flags = opts.overwrite ? null : fsConstants.COPYFILE_EXCL; - try { - fs.copyFileSync(src, dest, flags); - } catch (err) { - if (!opts.overwrite && err.code === 'EEXIST') { - return; - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/fromEvent.js +/** PURE_IMPORTS_START _Observable,_util_isArray,_util_isFunction,_operators_map PURE_IMPORTS_END */ - throw err; - } - fs.utimesSync(dest, stat.atime, stat.mtime); - fixupAttributes(dest, stat); -}; -const copySyncFallback = (src, dest, opts) => { - let read; // eslint-disable-line prefer-const - let bytesRead; - let pos; - let write; - const BUF_LENGTH = 100 * 1024; - const buf = Buffer.alloc(BUF_LENGTH); - const readSync = pos => fs.readSync(read, buf, 0, BUF_LENGTH, pos, src); - const writeSync = () => fs.writeSync(write, buf, 0, bytesRead, undefined, dest); - read = fs.openSync(src, 'r'); - bytesRead = readSync(0); - pos = bytesRead; - fs.makeDirSync(path.dirname(dest)); +var fromEvent_toString = Object.prototype.toString; +function fromEvent(target, eventName, options, resultSelector) { + if (Object(isFunction["a" /* isFunction */])(options)) { + resultSelector = options; + options = undefined; + } + if (resultSelector) { + return fromEvent(target, eventName, options).pipe(Object(map["a" /* map */])(function (args) { return Object(isArray["a" /* isArray */])(args) ? resultSelector.apply(void 0, args) : resultSelector(args); })); + } + return new Observable["a" /* Observable */](function (subscriber) { + function handler(e) { + if (arguments.length > 1) { + subscriber.next(Array.prototype.slice.call(arguments)); + } + else { + subscriber.next(e); + } + } + setupSubscription(target, eventName, handler, subscriber, options); + }); +} +function setupSubscription(sourceObj, eventName, handler, subscriber, options) { + var unsubscribe; + if (isEventTarget(sourceObj)) { + var source_1 = sourceObj; + sourceObj.addEventListener(eventName, handler, options); + unsubscribe = function () { return source_1.removeEventListener(eventName, handler, options); }; + } + else if (isJQueryStyleEventEmitter(sourceObj)) { + var source_2 = sourceObj; + sourceObj.on(eventName, handler); + unsubscribe = function () { return source_2.off(eventName, handler); }; + } + else if (isNodeStyleEventEmitter(sourceObj)) { + var source_3 = sourceObj; + sourceObj.addListener(eventName, handler); + unsubscribe = function () { return source_3.removeListener(eventName, handler); }; + } + else if (sourceObj && sourceObj.length) { + for (var i = 0, len = sourceObj.length; i < len; i++) { + setupSubscription(sourceObj[i], eventName, handler, subscriber, options); + } + } + else { + throw new TypeError('Invalid event target'); + } + subscriber.add(unsubscribe); +} +function isNodeStyleEventEmitter(sourceObj) { + return sourceObj && typeof sourceObj.addListener === 'function' && typeof sourceObj.removeListener === 'function'; +} +function isJQueryStyleEventEmitter(sourceObj) { + return sourceObj && typeof sourceObj.on === 'function' && typeof sourceObj.off === 'function'; +} +function isEventTarget(sourceObj) { + return sourceObj && typeof sourceObj.addEventListener === 'function' && typeof sourceObj.removeEventListener === 'function'; +} +//# sourceMappingURL=fromEvent.js.map - try { - write = fs.openSync(dest, opts.overwrite ? 'w' : 'wx'); - } catch (err) { - if (!opts.overwrite && err.code === 'EEXIST') { - return; - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/fromEventPattern.js +/** PURE_IMPORTS_START _Observable,_util_isArray,_util_isFunction,_operators_map PURE_IMPORTS_END */ - throw err; - } - writeSync(); - while (bytesRead === BUF_LENGTH) { - bytesRead = readSync(pos); - writeSync(); - pos += bytesRead; - } - const stat = fs.fstatSync(read, src); - fs.futimesSync(write, stat.atime, stat.mtime, dest); - fs.closeSync(read); - fs.closeSync(write); - fixupAttributes(dest, stat); -}; +function fromEventPattern(addHandler, removeHandler, resultSelector) { + if (resultSelector) { + return fromEventPattern(addHandler, removeHandler).pipe(Object(map["a" /* map */])(function (args) { return Object(isArray["a" /* isArray */])(args) ? resultSelector.apply(void 0, args) : resultSelector(args); })); + } + return new Observable["a" /* Observable */](function (subscriber) { + var handler = function () { + var e = []; + for (var _i = 0; _i < arguments.length; _i++) { + e[_i] = arguments[_i]; + } + return subscriber.next(e.length === 1 ? e[0] : e); + }; + var retValue; + try { + retValue = addHandler(handler); + } + catch (err) { + subscriber.error(err); + return undefined; + } + if (!Object(isFunction["a" /* isFunction */])(removeHandler)) { + return undefined; + } + return function () { return removeHandler(handler, retValue); }; + }); +} +//# sourceMappingURL=fromEventPattern.js.map -module.exports.sync = (src, dest, opts) => { - if (!src || !dest) { - throw new CpFileError('`src` and `dest` required'); - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/generate.js +/** PURE_IMPORTS_START _Observable,_util_identity,_util_isScheduler PURE_IMPORTS_END */ - opts = Object.assign({overwrite: true}, opts); - if (fs.copyFileSync) { - copySyncNative(src, dest, opts); - } else { - copySyncFallback(src, dest, opts); - } -}; +function generate(initialStateOrOptions, condition, iterate, resultSelectorOrObservable, scheduler) { + var resultSelector; + var initialState; + if (arguments.length == 1) { + var options = initialStateOrOptions; + initialState = options.initialState; + condition = options.condition; + iterate = options.iterate; + resultSelector = options.resultSelector || identity["a" /* identity */]; + scheduler = options.scheduler; + } + else if (resultSelectorOrObservable === undefined || Object(isScheduler["a" /* isScheduler */])(resultSelectorOrObservable)) { + initialState = initialStateOrOptions; + resultSelector = identity["a" /* identity */]; + scheduler = resultSelectorOrObservable; + } + else { + initialState = initialStateOrOptions; + resultSelector = resultSelectorOrObservable; + } + return new Observable["a" /* Observable */](function (subscriber) { + var state = initialState; + if (scheduler) { + return scheduler.schedule(generate_dispatch, 0, { + subscriber: subscriber, + iterate: iterate, + condition: condition, + resultSelector: resultSelector, + state: state + }); + } + do { + if (condition) { + var conditionResult = void 0; + try { + conditionResult = condition(state); + } + catch (err) { + subscriber.error(err); + return undefined; + } + if (!conditionResult) { + subscriber.complete(); + break; + } + } + var value = void 0; + try { + value = resultSelector(state); + } + catch (err) { + subscriber.error(err); + return undefined; + } + subscriber.next(value); + if (subscriber.closed) { + break; + } + try { + state = iterate(state); + } + catch (err) { + subscriber.error(err); + return undefined; + } + } while (true); + return undefined; + }); +} +function generate_dispatch(state) { + var subscriber = state.subscriber, condition = state.condition; + if (subscriber.closed) { + return undefined; + } + if (state.needIterate) { + try { + state.state = state.iterate(state.state); + } + catch (err) { + subscriber.error(err); + return undefined; + } + } + else { + state.needIterate = true; + } + if (condition) { + var conditionResult = void 0; + try { + conditionResult = condition(state.state); + } + catch (err) { + subscriber.error(err); + return undefined; + } + if (!conditionResult) { + subscriber.complete(); + return undefined; + } + if (subscriber.closed) { + return undefined; + } + } + var value; + try { + value = state.resultSelector(state.state); + } + catch (err) { + subscriber.error(err); + return undefined; + } + if (subscriber.closed) { + return undefined; + } + subscriber.next(value); + if (subscriber.closed) { + return undefined; + } + return this.schedule(state); +} +//# sourceMappingURL=generate.js.map -/***/ }), -/* 392 */ -/***/ (function(module, exports, __webpack_require__) { +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/iif.js +/** PURE_IMPORTS_START _defer,_empty PURE_IMPORTS_END */ -/* eslint-disable node/no-deprecated-api */ -var buffer = __webpack_require__(393) -var Buffer = buffer.Buffer -// alternative to using Object.keys for old browsers -function copyProps (src, dst) { - for (var key in src) { - dst[key] = src[key] - } -} -if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { - module.exports = buffer -} else { - // Copy properties from require('buffer') - copyProps(buffer, exports) - exports.Buffer = SafeBuffer +function iif(condition, trueResult, falseResult) { + if (trueResult === void 0) { + trueResult = empty["a" /* EMPTY */]; + } + if (falseResult === void 0) { + falseResult = empty["a" /* EMPTY */]; + } + return Object(defer["a" /* defer */])(function () { return condition() ? trueResult : falseResult; }); } +//# sourceMappingURL=iif.js.map -function SafeBuffer (arg, encodingOrOffset, length) { - return Buffer(arg, encodingOrOffset, length) -} +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/util/isNumeric.js +var isNumeric = __webpack_require__(35); -// Copy static methods from Buffer -copyProps(Buffer, SafeBuffer) +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/interval.js +/** PURE_IMPORTS_START _Observable,_scheduler_async,_util_isNumeric PURE_IMPORTS_END */ -SafeBuffer.from = function (arg, encodingOrOffset, length) { - if (typeof arg === 'number') { - throw new TypeError('Argument must not be a number') - } - return Buffer(arg, encodingOrOffset, length) -} -SafeBuffer.alloc = function (size, fill, encoding) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - var buf = Buffer(size) - if (fill !== undefined) { - if (typeof encoding === 'string') { - buf.fill(fill, encoding) - } else { - buf.fill(fill) + +function interval(period, scheduler) { + if (period === void 0) { + period = 0; } - } else { - buf.fill(0) - } - return buf + if (scheduler === void 0) { + scheduler = scheduler_async["a" /* async */]; + } + if (!Object(isNumeric["a" /* isNumeric */])(period) || period < 0) { + period = 0; + } + if (!scheduler || typeof scheduler.schedule !== 'function') { + scheduler = scheduler_async["a" /* async */]; + } + return new Observable["a" /* Observable */](function (subscriber) { + subscriber.add(scheduler.schedule(interval_dispatch, period, { subscriber: subscriber, counter: 0, period: period })); + return subscriber; + }); } - -SafeBuffer.allocUnsafe = function (size) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - return Buffer(size) +function interval_dispatch(state) { + var subscriber = state.subscriber, counter = state.counter, period = state.period; + subscriber.next(counter); + this.schedule({ subscriber: subscriber, counter: counter + 1, period: period }, period); } +//# sourceMappingURL=interval.js.map -SafeBuffer.allocUnsafeSlow = function (size) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - return buffer.SlowBuffer(size) -} +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/merge.js +var merge = __webpack_require__(69); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/never.js +/** PURE_IMPORTS_START _Observable,_util_noop PURE_IMPORTS_END */ -/***/ }), -/* 393 */ -/***/ (function(module, exports) { -module.exports = require("buffer"); +var NEVER = /*@__PURE__*/ new Observable["a" /* Observable */](noop["a" /* noop */]); +function never() { + return NEVER; +} +//# sourceMappingURL=never.js.map -/***/ }), -/* 394 */ -/***/ (function(module, exports, __webpack_require__) { +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/of.js +var of = __webpack_require__(47); -"use strict"; +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/onErrorResumeNext.js +/** PURE_IMPORTS_START _Observable,_from,_util_isArray,_empty PURE_IMPORTS_END */ -const fs = __webpack_require__(27); -const makeDir = __webpack_require__(91); -const pify = __webpack_require__(395); -const CpFileError = __webpack_require__(134); -const fsP = pify(fs); -exports.closeSync = fs.closeSync.bind(fs); -exports.createWriteStream = fs.createWriteStream.bind(fs); -exports.createReadStream = (path, options) => new Promise((resolve, reject) => { - const read = fs.createReadStream(path, options); +function onErrorResumeNext() { + var sources = []; + for (var _i = 0; _i < arguments.length; _i++) { + sources[_i] = arguments[_i]; + } + if (sources.length === 0) { + return empty["a" /* EMPTY */]; + } + var first = sources[0], remainder = sources.slice(1); + if (sources.length === 1 && Object(isArray["a" /* isArray */])(first)) { + return onErrorResumeNext.apply(void 0, first); + } + return new Observable["a" /* Observable */](function (subscriber) { + var subNext = function () { return subscriber.add(onErrorResumeNext.apply(void 0, remainder).subscribe(subscriber)); }; + return Object(from["a" /* from */])(first).subscribe({ + next: function (value) { subscriber.next(value); }, + error: subNext, + complete: subNext, + }); + }); +} +//# sourceMappingURL=onErrorResumeNext.js.map - read.on('error', err => { - reject(new CpFileError(`Cannot read from \`${path}\`: ${err.message}`, err)); - }); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/pairs.js +/** PURE_IMPORTS_START _Observable,_Subscription PURE_IMPORTS_END */ - read.on('readable', () => { - resolve(read); - }); - read.on('end', () => { - resolve(read); - }); -}); +function pairs(obj, scheduler) { + if (!scheduler) { + return new Observable["a" /* Observable */](function (subscriber) { + var keys = Object.keys(obj); + for (var i = 0; i < keys.length && !subscriber.closed; i++) { + var key = keys[i]; + if (obj.hasOwnProperty(key)) { + subscriber.next([key, obj[key]]); + } + } + subscriber.complete(); + }); + } + else { + return new Observable["a" /* Observable */](function (subscriber) { + var keys = Object.keys(obj); + var subscription = new Subscription["a" /* Subscription */](); + subscription.add(scheduler.schedule(pairs_dispatch, 0, { keys: keys, index: 0, subscriber: subscriber, subscription: subscription, obj: obj })); + return subscription; + }); + } +} +function pairs_dispatch(state) { + var keys = state.keys, index = state.index, subscriber = state.subscriber, subscription = state.subscription, obj = state.obj; + if (!subscriber.closed) { + if (index < keys.length) { + var key = keys[index]; + subscriber.next([key, obj[key]]); + subscription.add(this.schedule({ keys: keys, index: index + 1, subscriber: subscriber, subscription: subscription, obj: obj })); + } + else { + subscriber.complete(); + } + } +} +//# sourceMappingURL=pairs.js.map -exports.stat = path => fsP.stat(path).catch(err => { - throw new CpFileError(`Cannot stat path \`${path}\`: ${err.message}`, err); -}); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/race.js +var race = __webpack_require__(70); -exports.lstat = path => fsP.lstat(path).catch(err => { - throw new CpFileError(`lstat \`${path}\` failed: ${err.message}`, err); -}); +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/range.js +/** PURE_IMPORTS_START _Observable PURE_IMPORTS_END */ -exports.utimes = (path, atime, mtime) => fsP.utimes(path, atime, mtime).catch(err => { - throw new CpFileError(`utimes \`${path}\` failed: ${err.message}`, err); -}); +function range(start, count, scheduler) { + if (start === void 0) { + start = 0; + } + if (count === void 0) { + count = 0; + } + return new Observable["a" /* Observable */](function (subscriber) { + var index = 0; + var current = start; + if (scheduler) { + return scheduler.schedule(range_dispatch, 0, { + index: index, count: count, start: start, subscriber: subscriber + }); + } + else { + do { + if (index++ >= count) { + subscriber.complete(); + break; + } + subscriber.next(current++); + if (subscriber.closed) { + break; + } + } while (true); + } + return undefined; + }); +} +function range_dispatch(state) { + var start = state.start, index = state.index, count = state.count, subscriber = state.subscriber; + if (index >= count) { + subscriber.complete(); + return; + } + subscriber.next(start); + if (subscriber.closed) { + return; + } + state.index = index + 1; + state.start = start + 1; + this.schedule(state); +} +//# sourceMappingURL=range.js.map -exports.chmod = (path, mode) => fsP.chmod(path, mode).catch(err => { - throw new CpFileError(`chmod \`${path}\` failed: ${err.message}`, err); -}); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/throwError.js +var throwError = __webpack_require__(48); -exports.chown = (path, uid, gid) => fsP.chown(path, uid, gid).catch(err => { - throw new CpFileError(`chown \`${path}\` failed: ${err.message}`, err); -}); +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/timer.js +var timer = __webpack_require__(71); -exports.openSync = (path, flags, mode) => { - try { - return fs.openSync(path, flags, mode); - } catch (err) { - if (flags.includes('w')) { - throw new CpFileError(`Cannot write to \`${path}\`: ${err.message}`, err); - } +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/using.js +/** PURE_IMPORTS_START _Observable,_from,_empty PURE_IMPORTS_END */ - throw new CpFileError(`Cannot open \`${path}\`: ${err.message}`, err); - } -}; -// eslint-disable-next-line max-params -exports.readSync = (fd, buffer, offset, length, position, path) => { - try { - return fs.readSync(fd, buffer, offset, length, position); - } catch (err) { - throw new CpFileError(`Cannot read from \`${path}\`: ${err.message}`, err); - } -}; -// eslint-disable-next-line max-params -exports.writeSync = (fd, buffer, offset, length, position, path) => { - try { - return fs.writeSync(fd, buffer, offset, length, position); - } catch (err) { - throw new CpFileError(`Cannot write to \`${path}\`: ${err.message}`, err); - } -}; +function using(resourceFactory, observableFactory) { + return new Observable["a" /* Observable */](function (subscriber) { + var resource; + try { + resource = resourceFactory(); + } + catch (err) { + subscriber.error(err); + return undefined; + } + var result; + try { + result = observableFactory(resource); + } + catch (err) { + subscriber.error(err); + return undefined; + } + var source = result ? Object(from["a" /* from */])(result) : empty["a" /* EMPTY */]; + var subscription = source.subscribe(subscriber); + return function () { + subscription.unsubscribe(); + if (resource) { + resource.unsubscribe(); + } + }; + }); +} +//# sourceMappingURL=using.js.map -exports.statSync = path => { - try { - return fs.statSync(path); - } catch (err) { - throw new CpFileError(`stat \`${path}\` failed: ${err.message}`, err); - } -}; +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/observable/zip.js +var zip = __webpack_require__(52); + +// EXTERNAL MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/internal/config.js +var config = __webpack_require__(18); + +// CONCATENATED MODULE: /Users/tiagocosta/elastic/kibana/node_modules/rxjs/_esm5/index.js +/* concated harmony reexport Observable */__webpack_require__.d(__webpack_exports__, "Observable", function() { return Observable["a" /* Observable */]; }); +/* concated harmony reexport ConnectableObservable */__webpack_require__.d(__webpack_exports__, "ConnectableObservable", function() { return ConnectableObservable["a" /* ConnectableObservable */]; }); +/* concated harmony reexport GroupedObservable */__webpack_require__.d(__webpack_exports__, "GroupedObservable", function() { return groupBy["a" /* GroupedObservable */]; }); +/* concated harmony reexport observable */__webpack_require__.d(__webpack_exports__, "observable", function() { return observable["a" /* observable */]; }); +/* concated harmony reexport Subject */__webpack_require__.d(__webpack_exports__, "Subject", function() { return Subject["a" /* Subject */]; }); +/* concated harmony reexport BehaviorSubject */__webpack_require__.d(__webpack_exports__, "BehaviorSubject", function() { return BehaviorSubject["a" /* BehaviorSubject */]; }); +/* concated harmony reexport ReplaySubject */__webpack_require__.d(__webpack_exports__, "ReplaySubject", function() { return ReplaySubject["a" /* ReplaySubject */]; }); +/* concated harmony reexport AsyncSubject */__webpack_require__.d(__webpack_exports__, "AsyncSubject", function() { return AsyncSubject["a" /* AsyncSubject */]; }); +/* concated harmony reexport asapScheduler */__webpack_require__.d(__webpack_exports__, "asapScheduler", function() { return asap["a" /* asap */]; }); +/* concated harmony reexport asyncScheduler */__webpack_require__.d(__webpack_exports__, "asyncScheduler", function() { return scheduler_async["a" /* async */]; }); +/* concated harmony reexport queueScheduler */__webpack_require__.d(__webpack_exports__, "queueScheduler", function() { return queue["a" /* queue */]; }); +/* concated harmony reexport animationFrameScheduler */__webpack_require__.d(__webpack_exports__, "animationFrameScheduler", function() { return animationFrame; }); +/* concated harmony reexport VirtualTimeScheduler */__webpack_require__.d(__webpack_exports__, "VirtualTimeScheduler", function() { return VirtualTimeScheduler_VirtualTimeScheduler; }); +/* concated harmony reexport VirtualAction */__webpack_require__.d(__webpack_exports__, "VirtualAction", function() { return VirtualTimeScheduler_VirtualAction; }); +/* concated harmony reexport Scheduler */__webpack_require__.d(__webpack_exports__, "Scheduler", function() { return Scheduler["a" /* Scheduler */]; }); +/* concated harmony reexport Subscription */__webpack_require__.d(__webpack_exports__, "Subscription", function() { return Subscription["a" /* Subscription */]; }); +/* concated harmony reexport Subscriber */__webpack_require__.d(__webpack_exports__, "Subscriber", function() { return Subscriber["a" /* Subscriber */]; }); +/* concated harmony reexport Notification */__webpack_require__.d(__webpack_exports__, "Notification", function() { return Notification["a" /* Notification */]; }); +/* concated harmony reexport pipe */__webpack_require__.d(__webpack_exports__, "pipe", function() { return pipe["a" /* pipe */]; }); +/* concated harmony reexport noop */__webpack_require__.d(__webpack_exports__, "noop", function() { return noop["a" /* noop */]; }); +/* concated harmony reexport identity */__webpack_require__.d(__webpack_exports__, "identity", function() { return identity["a" /* identity */]; }); +/* concated harmony reexport isObservable */__webpack_require__.d(__webpack_exports__, "isObservable", function() { return isObservable; }); +/* concated harmony reexport ArgumentOutOfRangeError */__webpack_require__.d(__webpack_exports__, "ArgumentOutOfRangeError", function() { return ArgumentOutOfRangeError["a" /* ArgumentOutOfRangeError */]; }); +/* concated harmony reexport EmptyError */__webpack_require__.d(__webpack_exports__, "EmptyError", function() { return EmptyError["a" /* EmptyError */]; }); +/* concated harmony reexport ObjectUnsubscribedError */__webpack_require__.d(__webpack_exports__, "ObjectUnsubscribedError", function() { return ObjectUnsubscribedError["a" /* ObjectUnsubscribedError */]; }); +/* concated harmony reexport UnsubscriptionError */__webpack_require__.d(__webpack_exports__, "UnsubscriptionError", function() { return UnsubscriptionError["a" /* UnsubscriptionError */]; }); +/* concated harmony reexport TimeoutError */__webpack_require__.d(__webpack_exports__, "TimeoutError", function() { return TimeoutError["a" /* TimeoutError */]; }); +/* concated harmony reexport bindCallback */__webpack_require__.d(__webpack_exports__, "bindCallback", function() { return bindCallback; }); +/* concated harmony reexport bindNodeCallback */__webpack_require__.d(__webpack_exports__, "bindNodeCallback", function() { return bindNodeCallback; }); +/* concated harmony reexport combineLatest */__webpack_require__.d(__webpack_exports__, "combineLatest", function() { return combineLatest["b" /* combineLatest */]; }); +/* concated harmony reexport concat */__webpack_require__.d(__webpack_exports__, "concat", function() { return concat["a" /* concat */]; }); +/* concated harmony reexport defer */__webpack_require__.d(__webpack_exports__, "defer", function() { return defer["a" /* defer */]; }); +/* concated harmony reexport empty */__webpack_require__.d(__webpack_exports__, "empty", function() { return empty["b" /* empty */]; }); +/* concated harmony reexport forkJoin */__webpack_require__.d(__webpack_exports__, "forkJoin", function() { return forkJoin; }); +/* concated harmony reexport from */__webpack_require__.d(__webpack_exports__, "from", function() { return from["a" /* from */]; }); +/* concated harmony reexport fromEvent */__webpack_require__.d(__webpack_exports__, "fromEvent", function() { return fromEvent; }); +/* concated harmony reexport fromEventPattern */__webpack_require__.d(__webpack_exports__, "fromEventPattern", function() { return fromEventPattern; }); +/* concated harmony reexport generate */__webpack_require__.d(__webpack_exports__, "generate", function() { return generate; }); +/* concated harmony reexport iif */__webpack_require__.d(__webpack_exports__, "iif", function() { return iif; }); +/* concated harmony reexport interval */__webpack_require__.d(__webpack_exports__, "interval", function() { return interval; }); +/* concated harmony reexport merge */__webpack_require__.d(__webpack_exports__, "merge", function() { return merge["a" /* merge */]; }); +/* concated harmony reexport never */__webpack_require__.d(__webpack_exports__, "never", function() { return never; }); +/* concated harmony reexport of */__webpack_require__.d(__webpack_exports__, "of", function() { return of["a" /* of */]; }); +/* concated harmony reexport onErrorResumeNext */__webpack_require__.d(__webpack_exports__, "onErrorResumeNext", function() { return onErrorResumeNext; }); +/* concated harmony reexport pairs */__webpack_require__.d(__webpack_exports__, "pairs", function() { return pairs; }); +/* concated harmony reexport race */__webpack_require__.d(__webpack_exports__, "race", function() { return race["a" /* race */]; }); +/* concated harmony reexport range */__webpack_require__.d(__webpack_exports__, "range", function() { return range; }); +/* concated harmony reexport throwError */__webpack_require__.d(__webpack_exports__, "throwError", function() { return throwError["a" /* throwError */]; }); +/* concated harmony reexport timer */__webpack_require__.d(__webpack_exports__, "timer", function() { return timer["a" /* timer */]; }); +/* concated harmony reexport using */__webpack_require__.d(__webpack_exports__, "using", function() { return using; }); +/* concated harmony reexport zip */__webpack_require__.d(__webpack_exports__, "zip", function() { return zip["b" /* zip */]; }); +/* concated harmony reexport EMPTY */__webpack_require__.d(__webpack_exports__, "EMPTY", function() { return empty["a" /* EMPTY */]; }); +/* concated harmony reexport NEVER */__webpack_require__.d(__webpack_exports__, "NEVER", function() { return NEVER; }); +/* concated harmony reexport config */__webpack_require__.d(__webpack_exports__, "config", function() { return config["a" /* config */]; }); +/** PURE_IMPORTS_START PURE_IMPORTS_END */ -exports.fstatSync = (fd, path) => { - try { - return fs.fstatSync(fd); - } catch (err) { - throw new CpFileError(`fstat \`${path}\` failed: ${err.message}`, err); - } -}; -exports.futimesSync = (fd, atime, mtime, path) => { - try { - return fs.futimesSync(fd, atime, mtime, path); - } catch (err) { - throw new CpFileError(`futimes \`${path}\` failed: ${err.message}`, err); - } -}; -exports.utimesSync = (path, atime, mtime) => { - try { - return fs.utimesSync(path, atime, mtime); - } catch (err) { - throw new CpFileError(`utimes \`${path}\` failed: ${err.message}`, err); - } -}; -exports.chmodSync = (path, mode) => { - try { - return fs.chmodSync(path, mode); - } catch (err) { - throw new CpFileError(`chmod \`${path}\` failed: ${err.message}`, err); - } -}; -exports.chownSync = (path, uid, gid) => { - try { - return fs.chownSync(path, uid, gid); - } catch (err) { - throw new CpFileError(`chown \`${path}\` failed: ${err.message}`, err); - } -}; -exports.makeDir = path => makeDir(path, {fs}).catch(err => { - throw new CpFileError(`Cannot create directory \`${path}\`: ${err.message}`, err); -}); -exports.makeDirSync = path => { - try { - makeDir.sync(path, {fs}); - } catch (err) { - throw new CpFileError(`Cannot create directory \`${path}\`: ${err.message}`, err); - } -}; -if (fs.copyFileSync) { - exports.copyFileSync = (src, dest, flags) => { - try { - fs.copyFileSync(src, dest, flags); - } catch (err) { - throw new CpFileError(`Cannot copy from \`${src}\` to \`${dest}\`: ${err.message}`, err); - } - }; -} -/***/ }), -/* 395 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -const processFn = (fn, opts) => function () { - const P = opts.promiseModule; - const args = new Array(arguments.length); - for (let i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } - return new P((resolve, reject) => { - if (opts.errorFirst) { - args.push(function (err, result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - for (let i = 1; i < arguments.length; i++) { - results[i - 1] = arguments[i]; - } - if (err) { - results.unshift(err); - reject(results); - } else { - resolve(results); - } - } else if (err) { - reject(err); - } else { - resolve(result); - } - }); - } else { - args.push(function (result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - for (let i = 0; i < arguments.length; i++) { - results[i] = arguments[i]; - } - resolve(results); - } else { - resolve(result); - } - }); - } - fn.apply(this, args); - }); -}; -module.exports = (obj, opts) => { - opts = Object.assign({ - exclude: [/.+(Sync|Stream)$/], - errorFirst: true, - promiseModule: Promise - }, opts); - const filter = key => { - const match = pattern => typeof pattern === 'string' ? key === pattern : pattern.test(key); - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; - let ret; - if (typeof obj === 'function') { - ret = function () { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } - return processFn(obj, opts).apply(this, arguments); - }; - } else { - ret = Object.create(Object.getPrototypeOf(obj)); - } - for (const key in obj) { // eslint-disable-line guard-for-in - const x = obj[key]; - ret[key] = typeof x === 'function' && filter(key) ? processFn(x, opts) : x; - } - return ret; -}; -/***/ }), -/* 396 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -const EventEmitter = __webpack_require__(40); -const written = new WeakMap(); -class ProgressEmitter extends EventEmitter { - constructor(src, dest) { - super(); - this.src = src; - this.dest = dest; - } - set written(value) { - written.set(this, value); - this.emitProgress(); - } - get written() { - return written.get(this); - } - emitProgress() { - const size = this.size; - const written = this.written; - this.emit('progress', { - src: this.src, - dest: this.dest, - size, - written, - percent: written === size ? 1 : written / size - }); - } -} -module.exports = ProgressEmitter; -/***/ }), -/* 397 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -const NestedError = __webpack_require__(135); -class CpyError extends NestedError { - constructor(message, nested) { - super(message, nested); - Object.assign(this, nested); - this.name = 'CpyError'; - } -} -module.exports = CpyError; -/***/ }), -/* 398 */ -/***/ (function(module, exports, __webpack_require__) { -"use strict"; -Object.defineProperty(exports, "__esModule", { - value: true -}); -exports.prepareExternalProjectDependencies = undefined; -/** - * This prepares the dependencies for an _external_ project. - */ -let prepareExternalProjectDependencies = exports.prepareExternalProjectDependencies = (() => { - var _ref = _asyncToGenerator(function* (projectPath) { - const project = yield _project.Project.fromPath(projectPath); - if (!project.hasDependencies()) { - return; - } - const deps = project.allDependencies; - for (const depName of Object.keys(deps)) { - const depVersion = deps[depName]; - // Kibana currently only supports `link:` dependencies on Kibana's own - // packages, as these are packaged into the `node_modules` folder when - // Kibana is built, so we don't need to take any action to enable - // `require(...)` to resolve for these packages. - if ((0, _package_json.isLinkDependency)(depVersion) && !isKibanaDep(depVersion)) { - // For non-Kibana packages we need to set up symlinks during the - // installation process, but this is not something we support yet. - throw new Error('This plugin is using `link:` dependencies for non-Kibana packages'); - } - } - }); - return function prepareExternalProjectDependencies(_x) { - return _ref.apply(this, arguments); - }; -})(); -var _package_json = __webpack_require__(41); -var _project = __webpack_require__(86); -function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; } /* - * 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. - */ +//# sourceMappingURL=index.js.map -/** - * All external projects are located within `../kibana-extra/{plugin}` relative - * to Kibana itself. - */ -const isKibanaDep = depVersion => depVersion.includes('../../kibana/'); /***/ }) /******/ ]); \ No newline at end of file diff --git a/packages/kbn-pm/package.json b/packages/kbn-pm/package.json index 0c03bd9238b4f..2a415914fb93a 100644 --- a/packages/kbn-pm/package.json +++ b/packages/kbn-pm/package.json @@ -25,7 +25,7 @@ "@types/log-symbols": "^2.0.0", "@types/mkdirp": "^0.5.2", "@types/ncp": "^2.0.1", - "@types/node": "^8.9.4", + "@types/node": "^8.10.38", "@types/ora": "^1.3.2", "@types/read-pkg": "^3.0.0", "@types/strip-ansi": "^3.0.0", @@ -33,9 +33,9 @@ "@types/tempy": "^0.1.0", "@types/wrap-ansi": "^2.0.14", "@types/write-pkg": "^3.1.0", - "babel-core": "^6.26.0", - "babel-loader": "^7.1.2", - "babel-preset-env": "^1.6.1", + "babel-core": "^6.26.3", + "babel-loader": "^7.1.5", + "babel-preset-env": "^1.7.0", "babel-preset-stage-3": "^6.24.1", "chalk": "^2.4.1", "cmd-shim": "^2.0.2", @@ -57,13 +57,14 @@ "read-pkg": "^3.0.0", "rxjs": "^6.2.1", "spawn-sync": "^1.0.15", - "string-replace-loader": "^1.3.0", + "string-replace-loader": "^2.1.1", "strip-ansi": "^4.0.0", "strong-log-transformer": "^2.0.0", "tempy": "^0.2.1", - "ts-loader": "^3.5.0", + "ts-loader": "^5.2.2", "typescript": "^3.0.3", - "webpack": "^3.11.0", + "webpack": "^4.23.1", + "webpack-cli": "^3.1.2", "wrap-ansi": "^3.0.1", "write-pkg": "^3.1.0" }, diff --git a/packages/kbn-pm/src/config.ts b/packages/kbn-pm/src/config.ts index bc88df7139ef4..d90475b0fae5b 100644 --- a/packages/kbn-pm/src/config.ts +++ b/packages/kbn-pm/src/config.ts @@ -33,6 +33,17 @@ export function getProjectPaths(rootPath: string, options: IProjectPathOptions) const projectPaths = [rootPath, resolve(rootPath, 'packages/*')]; + // This is needed in order to install the dependencies for the declared + // plugin functional used in the selenium functional tests. + // As we are now using the webpack dll for the client vendors dependencies + // when we run the plugin functional tests against the distributable + // dependencies used by such plugins like @eui, react and react-dom can't + // be loaded from the dll as the context is different from the one declared + // into the webpack dll reference plugin. + // In anyway, have a plugin declaring their own dependencies is the + // correct and the expect behavior. + projectPaths.push(resolve(rootPath, 'test/plugin_functional/plugins/*')); + if (!ossOnly) { projectPaths.push(resolve(rootPath, 'x-pack')); projectPaths.push(resolve(rootPath, 'x-pack/plugins/*')); diff --git a/packages/kbn-pm/webpack.config.js b/packages/kbn-pm/webpack.config.js index 4fde5f88159b8..dd103d09a7d1a 100644 --- a/packages/kbn-pm/webpack.config.js +++ b/packages/kbn-pm/webpack.config.js @@ -20,6 +20,7 @@ const path = require('path'); module.exports = { + mode: 'production', entry: { index: './src/index.ts', }, @@ -83,4 +84,8 @@ module.exports = { watchOptions: { ignored: [/node_modules/, /vendor/], }, + + optimization: { + minimize: false, + }, }; diff --git a/packages/kbn-ui-framework/package.json b/packages/kbn-ui-framework/package.json index a2ac3316a380d..8d560e831699a 100644 --- a/packages/kbn-ui-framework/package.json +++ b/packages/kbn-ui-framework/package.json @@ -33,30 +33,30 @@ "@elastic/eui": "0.0.23", "@kbn/babel-preset": "1.0.0", "autoprefixer": "6.5.4", - "babel-core": "6.21.0", - "babel-loader": "7.1.2", - "babel-polyfill": "6.20.0", + "babel-core": "^6.26.3", + "babel-loader": "^7.1.5", + "babel-polyfill": "^6.26.0", "brace": "0.10.0", "chalk": "^2.4.1", "chokidar": "1.6.0", - "css-loader": "0.28.7", - "expose-loader": "0.7.3", - "file-loader": "1.1.4", + "css-loader": "^1.0.0", + "expose-loader": "^0.7.5", + "file-loader": "^2.0.0", "grunt": "1.0.1", "grunt-babel": "^7.0.0", "grunt-contrib-clean": "^1.1.0", "grunt-contrib-copy": "^1.0.0", "highlight.js": "9.0.0", "html": "1.0.0", - "html-loader": "0.5.1", - "imports-loader": "0.7.1", + "html-loader": "^0.5.5", + "imports-loader": "^0.8.0", "jquery": "^3.3.1", "keymirror": "0.1.1", "moment": "^2.20.1", - "node-sass": "4.5.3", - "postcss": "^5.0.10", - "postcss-loader": "2.0.6", - "raw-loader": "0.5.1", + "node-sass": "^4.9.4", + "postcss": "^7.0.5", + "postcss-loader": "^3.0.0", + "raw-loader": "^0.5.1", "react-dom": "^16.2.0", "react-redux": "^5.0.6", "react-router": "^3.2.0", @@ -64,11 +64,11 @@ "react-router-redux": "^4.0.8", "redux": "3.7.2", "redux-thunk": "2.2.0", - "sass-loader": "6.0.6", + "sass-loader": "^7.1.0", "sinon": "^5.0.7", - "style-loader": "0.19.0", - "webpack": "3.6.0", - "webpack-dev-server": "2.9.1", + "style-loader": "^0.23.1", + "webpack": "^4.23.1", + "webpack-dev-server": "^3.1.10", "yeoman-generator": "1.1.1", "yo": "2.0.3" } diff --git a/src/dev/build/README.md b/src/dev/build/README.md index c9bed9e143ab3..af08414f0bf4b 100644 --- a/src/dev/build/README.md +++ b/src/dev/build/README.md @@ -39,3 +39,14 @@ The majority of this logic is extracted from the grunt build that has existed fo [lib/build.js]: ./lib/build.js [build_distributables.js]: ./build_distributables.js [../tooling_log/tooling_log.js]: ../tooling_log/tooling_log.js + +# Client Node Modules Cleaning + +We have introduced in our bundle a webpack dll for the client vendor modules in order to improve +the optimization time both in dev and in production. As for those modules we already have the +code into the vendors.bundle.dll.js we have decided to delete those bundled modules from the +distributable node_modules folder. However, in order to accomplish this, we need to exclude +every node_module used in the server side code. This logic is performed +under `nodejs_modules/clean_client_modules_on_dll_task.js`. In case we need to add any new cli +or any other piece of server code other than `x-pack` or `core_plugins` we'll need +to update the globs present on `clean_client_modules_on_dll_task.js` accordingly. diff --git a/src/dev/build/build_distributables.js b/src/dev/build/build_distributables.js index e7f8efd09c667..0f4336535a078 100644 --- a/src/dev/build/build_distributables.js +++ b/src/dev/build/build_distributables.js @@ -21,6 +21,8 @@ import { getConfig, createRunner } from './lib'; import { BuildPackagesTask, + CleanClientModulesOnDLLTask, + CleanEmptyFoldersTask, CleanExtraBinScriptsTask, CleanExtraBrowsersTask, CleanExtraFilesFromModulesTask, @@ -116,8 +118,10 @@ export async function buildDistributables(options) { await run(UpdateLicenseFileTask); await run(RemovePackageJsonDepsTask); await run(TranspileScssTask); - await run(CleanExtraFilesFromModulesTask); await run(OptimizeBuildTask); + await run(CleanClientModulesOnDLLTask); + await run(CleanExtraFilesFromModulesTask); + await run(CleanEmptyFoldersTask); /** * copy generic build outputs into platform-specific build diff --git a/src/dev/build/lib/exec.js b/src/dev/build/lib/exec.js index fff8dd6006a10..e74f949a803c0 100644 --- a/src/dev/build/lib/exec.js +++ b/src/dev/build/lib/exec.js @@ -26,6 +26,7 @@ export async function exec(log, cmd, args, options = {}) { const { level = 'debug', cwd, + env, exitAfter, } = options; @@ -34,6 +35,7 @@ export async function exec(log, cmd, args, options = {}) { const proc = execa(cmd, args, { stdio: ['ignore', 'pipe', 'pipe'], cwd, + env, }); await watchStdioForLine(proc, line => log[level](line), exitAfter); diff --git a/src/dev/build/lib/fs.js b/src/dev/build/lib/fs.js index 1386cbe4c7da5..f0e70ce9fc837 100644 --- a/src/dev/build/lib/fs.js +++ b/src/dev/build/lib/fs.js @@ -27,6 +27,7 @@ import vfs from 'vinyl-fs'; import { promisify } from 'bluebird'; import mkdirpCb from 'mkdirp'; import del from 'del'; +import deleteEmpty from 'delete-empty'; import { createPromiseFromStreams, createMapStream } from '../../../utils'; import { Extract } from 'tar'; @@ -112,6 +113,28 @@ export async function deleteAll(log, patterns) { log.verbose('Deleted:', longInspect(files)); } +export async function deleteEmptyFolders(log, rootFolderPath, foldersToKeep) { + if (typeof rootFolderPath !== 'string') { + throw new TypeError('Expected root folder to be a string path'); + } + + log.debug('Deleting all empty folders and their children recursively starting on ', rootFolderPath); + assertAbsolute(rootFolderPath.startsWith('!') ? rootFolderPath.slice(1) : rootFolderPath); + + // Delete empty is used to gather all the empty folders and + // then we use del to actually delete them + const emptyFoldersList = await deleteEmpty(rootFolderPath, { dryRun: true }); + const foldersToDelete = emptyFoldersList.filter((folderToDelete) => { + return !foldersToKeep.some(folderToKeep => folderToDelete.includes(folderToKeep)); + }); + const deletedEmptyFolders = await del(foldersToDelete, { + concurrency: 4 + }); + + log.debug('Deleted %d empty folders', deletedEmptyFolders.length); + log.verbose('Deleted:', longInspect(deletedEmptyFolders)); +} + export async function copyAll(sourceDir, destination, options = {}) { const { select = ['**/*'], diff --git a/src/dev/build/lib/index.js b/src/dev/build/lib/index.js index 7e318567316a5..4481a29b360b9 100644 --- a/src/dev/build/lib/index.js +++ b/src/dev/build/lib/index.js @@ -30,6 +30,7 @@ export { getFileHash, untar, deleteAll, + deleteEmptyFolders, } from './fs'; export { scanDelete } from './scan_delete'; export { scanCopy } from './scan_copy'; diff --git a/src/dev/build/tasks/clean_tasks.js b/src/dev/build/tasks/clean_tasks.js index cb6625c003119..0ee189352167b 100644 --- a/src/dev/build/tasks/clean_tasks.js +++ b/src/dev/build/tasks/clean_tasks.js @@ -19,7 +19,7 @@ import minimatch from 'minimatch'; -import { deleteAll, scanDelete } from '../lib'; +import { deleteAll, deleteEmptyFolders, scanDelete } from '../lib'; export const CleanTask = { global: true, @@ -233,3 +233,21 @@ export const CleanExtraBrowsersTask = { } }, }; + +export const CleanEmptyFoldersTask = { + description: 'Cleaning all empty folders recursively', + + async run(config, log, build) { + // Delete every single empty folder from + // the distributable except the plugins + // and data folder. + await deleteEmptyFolders( + log, + build.resolvePath('.'), + [ + build.resolvePath('plugins'), + build.resolvePath('data') + ] + ); + }, +}; diff --git a/src/dev/build/tasks/index.js b/src/dev/build/tasks/index.js index 6fc15a2f92115..7827dd569a4c4 100644 --- a/src/dev/build/tasks/index.js +++ b/src/dev/build/tasks/index.js @@ -28,6 +28,7 @@ export * from './create_readme_task'; export * from './install_dependencies_task'; export * from './license_file_task'; export * from './nodejs'; +export * from './nodejs_modules'; export * from './notice_file_task'; export * from './optimize_task'; export * from './os_packages'; diff --git a/src/dev/build/tasks/nodejs_modules/clean_client_modules_on_dll_task.js b/src/dev/build/tasks/nodejs_modules/clean_client_modules_on_dll_task.js new file mode 100644 index 0000000000000..3793b54913cd1 --- /dev/null +++ b/src/dev/build/tasks/nodejs_modules/clean_client_modules_on_dll_task.js @@ -0,0 +1,83 @@ +/* + * 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 { getDllEntries, cleanDllModuleFromEntryPath, writeEmptyFileForDllEntry } from './webpack_dll'; +import { getDependencies } from './get_dependencies'; +import globby from 'globby'; +import normalizePosixPath from 'normalize-path'; + +export const CleanClientModulesOnDLLTask = { + description: + 'Cleaning client node_modules bundled into the DLL', + + async run(config, log, build) { + const baseDir = normalizePosixPath(build.resolvePath('.')); + const kbnPkg = config.getKibanaPkg(); + const kbnPkgDependencies = (kbnPkg && kbnPkg.dependencies) || {}; + const kbnWebpackLoaders = Object.keys(kbnPkgDependencies).filter(dep => !!dep.includes('-loader')); + + // Define the entry points for the server code in order to + // start here later looking for the server side dependencies + const mainCodeEntries = [ + `${baseDir}/src/cli`, + `${baseDir}/src/cli_keystore`, + `${baseDir}/src/cli_plugin`, + `${baseDir}/node_modules/x-pack`, + ...kbnWebpackLoaders.map(loader => `${baseDir}/node_modules/${loader}`) + ]; + const discoveredLegacyCorePluginEntries = await globby([ + `${baseDir}/src/legacy/core_plugins/*/index.js`, + `!${baseDir}/src/legacy/core_plugins/**/public` + ]); + const discoveredPluginEntries = await globby([ + `${baseDir}/src/plugins/*/index.js`, + `!${baseDir}/src/plugins/**/public` + ]); + + // Compose all the needed entries + const serverEntries = [ ...mainCodeEntries, ...discoveredLegacyCorePluginEntries, ...discoveredPluginEntries]; + + // Get the dependencies found searching through the server + // side code entries that were provided + const serverDependencies = await getDependencies(baseDir, serverEntries); + + // Consider this as our whiteList for the modules we can't delete + const whiteListedModules = [ + ...serverDependencies, + ...kbnWebpackLoaders + ]; + + // Resolve the client vendors dll manifest path + const dllManifestPath = `${baseDir}/dlls/vendors.manifest.dll.json`; + + // Get dll entries filtering out the ones + // from any whitelisted module + const dllEntries = await getDllEntries(dllManifestPath, whiteListedModules); + + for (const relativeEntryPath of dllEntries) { + const entryPath = `${baseDir}/${relativeEntryPath}`; + + // Clean a module included into the dll + // and then write a blank file for each + // entry file present into the dll + await cleanDllModuleFromEntryPath(log, entryPath); + await writeEmptyFileForDllEntry(entryPath); + } + } +}; diff --git a/src/dev/build/tasks/nodejs_modules/get_dependencies.js b/src/dev/build/tasks/nodejs_modules/get_dependencies.js new file mode 100644 index 0000000000000..5a39448f57d14 --- /dev/null +++ b/src/dev/build/tasks/nodejs_modules/get_dependencies.js @@ -0,0 +1,27 @@ +/* + * 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 { parseEntries, dependenciesParseStrategy } from '@kbn/babel-code-parser'; + +export async function getDependencies(cwd, entries) { + // Return the dependencies retrieve from the + // provided code entries (sanitized) and + // parseStrategy (dependencies one) + return Object.keys(await parseEntries(cwd, entries, dependenciesParseStrategy, {})); +} diff --git a/src/dev/build/tasks/nodejs_modules/index.js b/src/dev/build/tasks/nodejs_modules/index.js new file mode 100644 index 0000000000000..1c5392662ad13 --- /dev/null +++ b/src/dev/build/tasks/nodejs_modules/index.js @@ -0,0 +1,20 @@ +/* + * 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 { CleanClientModulesOnDLLTask } from './clean_client_modules_on_dll_task'; diff --git a/src/dev/build/tasks/nodejs_modules/webpack_dll.js b/src/dev/build/tasks/nodejs_modules/webpack_dll.js new file mode 100644 index 0000000000000..367a7e6120e29 --- /dev/null +++ b/src/dev/build/tasks/nodejs_modules/webpack_dll.js @@ -0,0 +1,103 @@ +/* + * 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 { deleteAll, read, write } from '../../lib'; +import { dirname, sep } from 'path'; +import pkgUp from 'pkg-up'; +import globby from 'globby'; + +export async function getDllEntries(manifestPath, whiteListedModules) { + const manifest = JSON.parse(await read(manifestPath)); + + if (!manifest || !manifest.content) { + // It should fails because if we don't have the manifest file + // or it is malformed something wrong is happening and we + // should stop + throw new Error(`The following dll manifest doesn't exists: ${manifestPath}`); + } + + const modules = Object.keys(manifest.content); + if (!modules.length) { + // It should fails because if we don't have any + // module inside the client vendors dll something + // wrong is happening and we should stop too + throw new Error(`The following dll manifest is reporting an empty dll: ${manifestPath}`); + } + + // Only includes modules who are not in the white list of modules + // and that are node_modules + return modules.filter(entry => { + const isWhiteListed = whiteListedModules.some(nonEntry => entry.includes(`node_modules${sep}${nonEntry}${sep}`)); + const isNodeModule = entry.includes('node_modules'); + + return !isWhiteListed && isNodeModule; + }); +} + +export async function cleanDllModuleFromEntryPath(logger, entryPath) { + const modulePkgPath = await pkgUp(entryPath); + const modulePkg = JSON.parse(await read(modulePkgPath)); + const moduleDir = dirname(modulePkgPath); + + // Cancel the cleanup for this module as it + // was already done. + if (modulePkg.cleaned) { + return; + } + + // Clear dependencies from dll module package.json + if (modulePkg.dependencies) { + modulePkg.dependencies = {}; + } + + // Clear devDependencies from dll module package.json + if (modulePkg.devDependencies) { + modulePkg.devDependencies = {}; + } + + // Delete module contents. It will delete everything + // excepts package.json, images and css + // + // NOTE: We can't use cwd option with globby + // until the following issue gets closed + // https://github.com/sindresorhus/globby/issues/87 + const deletePatterns = await globby([ + `${moduleDir}/**`, + `!${moduleDir}/**/*.+(css)`, + `!${moduleDir}/**/*.+(gif|ico|jpeg|jpg|tiff|tif|svg|png|webp)`, + `!${modulePkgPath}`, + ]); + await deleteAll(logger, deletePatterns); + + // Mark this module as cleaned + modulePkg.cleaned = true; + + // Rewrite modified package.json + await write( + modulePkgPath, + JSON.stringify(modulePkg, null, 2) + ); +} + +export async function writeEmptyFileForDllEntry(entryPath) { + await write( + entryPath, + '' + ); +} diff --git a/src/dev/build/tasks/nodejs_modules/webpack_dll.test.js b/src/dev/build/tasks/nodejs_modules/webpack_dll.test.js new file mode 100644 index 0000000000000..8203aa2993d3c --- /dev/null +++ b/src/dev/build/tasks/nodejs_modules/webpack_dll.test.js @@ -0,0 +1,98 @@ +/* + * 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 { read } from '../../lib'; +import { getDllEntries } from './webpack_dll'; + +jest.mock('../../lib', () => ({ + read: jest.fn() +})); + +const manifestContentMock = JSON.stringify({ + 'name': 'vendors', + 'content': { + '/mock/node_modules/dep1': {}, + '/mock/node_modules/dep2': {}, + '/mock/node_modules/dep3': {}, + '/mock/tmp/dep2': {} + } +}); + +const emptyManifestContentMock = JSON.stringify({ + 'name': 'vendors', + 'content': {} +}); + +const noManifestMock = JSON.stringify(null); + +const noContentFieldManifestMock = JSON.stringify({ + 'name': 'vendors', +}); + +describe('Webpack DLL Build Tasks Utils', () => { + it('should get dll entries correctly', async () => { + read.mockImplementationOnce(async () => manifestContentMock); + + const mockManifestPath = '/mock/mock_dll_manifest.json'; + const mockModulesWhitelist = [ 'dep1' ]; + const dllEntries = await getDllEntries(mockManifestPath, mockModulesWhitelist); + + expect(dllEntries).toEqual(expect.arrayContaining(['/mock/node_modules/dep2', '/mock/node_modules/dep3'])); + }); + + it('should throw an error for no manifest file', async () => { + read.mockImplementationOnce(async () => noManifestMock); + + const mockManifestPath = '/mock/mock_dll_manifest.json'; + + try { + await getDllEntries(mockManifestPath, []); + } catch (error) { + expect(error.message).toEqual(`The following dll manifest doesn't exists: /mock/mock_dll_manifest.json`); + } + }); + + it('should throw an error for no manifest content field', async () => { + read.mockImplementation(async () => noContentFieldManifestMock); + + const mockManifestPath = '/mock/mock_dll_manifest.json'; + + try { + await getDllEntries(mockManifestPath, []); + } catch (error) { + expect(error.message).toEqual(`The following dll manifest doesn't exists: /mock/mock_dll_manifest.json`); + } + }); + + it('should throw an error for manifest file without any content', async () => { + read.mockImplementation(async () => emptyManifestContentMock); + + const mockManifestPath = '/mock/mock_dll_manifest.json'; + + try { + await getDllEntries(mockManifestPath, []); + } catch (error) { + expect(error.message).toEqual(`The following dll manifest is reporting an empty dll: /mock/mock_dll_manifest.json`); + } + }); + + afterAll(() => { + jest.clearAllMocks(); + }); +}); diff --git a/src/dev/build/tasks/optimize_task.js b/src/dev/build/tasks/optimize_task.js index d93aef950921f..c71f8cc7d9c8b 100644 --- a/src/dev/build/tasks/optimize_task.js +++ b/src/dev/build/tasks/optimize_task.js @@ -46,6 +46,9 @@ export const OptimizeBuildTask = { await exec(log, kibanaScript, kibanaArgs, { cwd: build.resolvePath('.'), + env: { + FORCE_DLL_CREATION: 'true' + }, }); // clean up temporary node install diff --git a/src/dev/notice/generate_notice_from_source.js b/src/dev/notice/generate_notice_from_source.js index f66df899d04f0..86ebd59553e22 100644 --- a/src/dev/notice/generate_notice_from_source.js +++ b/src/dev/notice/generate_notice_from_source.js @@ -42,7 +42,7 @@ export async function generateNoticeFromSource({ productName, directory, log }) cwd: directory, nodir: true, ignore: [ - '{node_modules,build,target,dist,optimize}/**', + '{node_modules,build,target,dist,optimize,dlls}/**', 'packages/*/{node_modules,build,target,dist}/**', 'x-pack/{node_modules,build,target,dist,optimize}/**', 'x-pack/packages/*/{node_modules,build,target,dist}/**', diff --git a/src/optimize/base_optimizer.js b/src/optimize/base_optimizer.js index b0fe947f56920..108171cd60c49 100644 --- a/src/optimize/base_optimizer.js +++ b/src/optimize/base_optimizer.js @@ -18,13 +18,14 @@ */ import { writeFile } from 'fs'; - +import os from 'os'; import Boom from 'boom'; -import ExtractTextPlugin from 'extract-text-webpack-plugin'; +import MiniCssExtractPlugin from 'mini-css-extract-plugin'; import UglifyJsPlugin from 'uglifyjs-webpack-plugin'; import webpack from 'webpack'; import Stats from 'webpack/lib/Stats'; import webpackMerge from 'webpack-merge'; +import { DynamicDllPlugin } from './dynamic_dll_plugin'; import { defaults } from 'lodash'; @@ -37,9 +38,14 @@ const BABEL_PRESET_PATH = require.resolve('@kbn/babel-preset/webpack_preset'); const BABEL_EXCLUDE_RE = [ /[\/\\](webpackShims|node_modules|bower_components)[\/\\]/, ]; +const STATS_WARNINGS_FILTER = new RegExp([ + '(export .* was not found in)', + '|(chunk .* \\[mini-css-extract-plugin\\]\\\nConflicting order between:)' +].join('')); export default class BaseOptimizer { constructor(opts) { + this.log = opts.log || (() => null); this.uiBundles = opts.uiBundles; this.profile = opts.profile || false; @@ -57,22 +63,36 @@ export default class BaseOptimizer { break; } - this.unsafeCache = opts.unsafeCache || false; - if (typeof this.unsafeCache === 'string') { - this.unsafeCache = [ - new RegExp(this.unsafeCache.slice(1, -1)) - ]; - } } - async initCompiler() { - if (this.compiler) return this.compiler; + async init() { + if (this.compiler) { + return this; + } const compilerConfig = this.getConfig(); this.compiler = webpack(compilerConfig); - this.compiler.plugin('done', stats => { - if (!this.profile) return; + // register the webpack compiler hooks + // for the base optimizer + this.registerCompilerHooks(); + + return this; + } + + registerCompilerHooks() { + this.registerCompilerDoneHook(); + } + + registerCompilerDoneHook() { + this.compiler.hooks.done.tap('base_optimizer-done', stats => { + // We are not done while we have an additional + // compilation pass to run + // We also don't need to emit the stats if we don't have + // the profile option set + if (!this.profile || stats.compilation.needAdditionalPass) { + return; + } const path = this.uiBundles.resolvePath('stats.json'); const content = JSON.stringify(stats.toJson()); @@ -80,42 +100,39 @@ export default class BaseOptimizer { if (err) throw err; }); }); - - return this.compiler; } getConfig() { + function getStyleLoaderExtractor() { + return [ + MiniCssExtractPlugin.loader + ]; + } + function getStyleLoaders(preProcessors = [], postProcessors = []) { - return ExtractTextPlugin.extract({ - fallback: { - loader: 'style-loader' - }, - use: [ - ...postProcessors, - { - loader: 'css-loader', - options: { - // importLoaders needs to know the number of loaders that follow this one, - // so we add 1 (for the postcss-loader) to the length of the preProcessors - // array that we merge into this array - importLoaders: 1 + preProcessors.length, - }, + return [ + ...postProcessors, + { + loader: 'css-loader', + options: { + // importLoaders needs to know the number of loaders that follow this one, + // so we add 1 (for the postcss-loader) to the length of the preProcessors + // array that we merge into this array + importLoaders: 1 + preProcessors.length, }, - { - loader: 'postcss-loader', - options: { - config: { - path: POSTCSS_CONFIG_PATH, - }, + }, + { + loader: 'postcss-loader', + options: { + config: { + path: POSTCSS_CONFIG_PATH, }, }, - ...preProcessors, - ], - }); + }, + ...preProcessors, + ]; } - const nodeModulesPath = fromRoot('node_modules'); - /** * Adds a cache loader if we're running in dev mode. The reason we're not adding * the cache-loader when running in production mode is that it creates cache @@ -157,8 +174,11 @@ export default class BaseOptimizer { }; const commonConfig = { + mode: 'development', node: { fs: 'empty' }, context: fromRoot('.'), + parallelism: os.cpus().length - 1, + cache: true, entry: this.uiBundles.toWebpackEntries(), devtool: this.sourceMaps, @@ -172,26 +192,30 @@ export default class BaseOptimizer { devtoolModuleFilenameTemplate: '[absolute-resource-path]' }, - plugins: [ - new ExtractTextPlugin('[name].style.css', { - allChunks: true - }), + optimization: { + splitChunks: { + cacheGroups: { + commons: { + name: 'commons', + chunks: 'initial', + minChunks: 2, + reuseExistingChunk: true + } + } + }, + noEmitOnErrors: true + }, - new webpack.optimize.CommonsChunkPlugin({ - name: 'commons', - filename: 'commons.bundle.js', - minChunks: 2, + plugins: [ + new DynamicDllPlugin({ + uiBundles: this.uiBundles, + log: this.log }), - new webpack.optimize.CommonsChunkPlugin({ - name: 'vendors', - filename: 'vendors.bundle.js', - // only combine node_modules from Kibana - minChunks: module => module.context && module.context.indexOf(nodeModulesPath) !== -1 + new MiniCssExtractPlugin({ + filename: '[name].style.css', }), - new webpack.NoEmitOnErrorsPlugin(), - // replace imports for `uiExports/*` modules with a synthetic module // created by create_ui_exports_module.js new webpack.NormalModuleReplacementPlugin(/^uiExports\//, (resource) => { @@ -224,14 +248,17 @@ export default class BaseOptimizer { rules: [ { test: /\.less$/, - use: getStyleLoaders( - ['less-loader'], - maybeAddCacheLoader('less', []) - ), + use: [ + ...getStyleLoaderExtractor(), + ...getStyleLoaders(['less-loader'], maybeAddCacheLoader('less', [])) + ], }, { test: /\.css$/, - use: getStyleLoaders(), + use: [ + ...getStyleLoaderExtractor(), + ...getStyleLoaders([], maybeAddCacheLoader('css', [])) + ], }, { test: /\.(html|tmpl)$/, @@ -277,9 +304,15 @@ export default class BaseOptimizer { 'node_modules', fromRoot('node_modules'), ], - alias: this.uiBundles.getAliases(), - unsafeCache: this.unsafeCache, + alias: this.uiBundles.getAliases() }, + + performance: { + // NOTE: we are disabling this as those hints + // are more tailored for the final bundles result + // and not for the webpack compilations performance itself + hints: false + } }; // when running from the distributable define an environment variable we can use @@ -324,16 +357,6 @@ export default class BaseOptimizer { ] }, - stats: { - // when typescript doesn't do a full type check, as we have the ts-loader - // configured here, it does not have enough information to determine - // whether an imported name is a type or not, so when the name is then - // exported, typescript has no choice but to emit the export. Fortunately, - // the extraneous export should not be harmful, so we just suppress these warnings - // https://github.com/TypeStrong/ts-loader#transpileonly-boolean-defaultfalse - warningsFilter: /export .* was not found in/ - }, - resolve: { extensions: ['.ts', '.tsx'], }, @@ -366,48 +389,49 @@ export default class BaseOptimizer { // in production we set the process.env.NODE_ENV and uglify our bundles const productionConfig = { - plugins: [ - new webpack.DefinePlugin({ - 'process.env': { - 'NODE_ENV': '"production"' - } - }), - new UglifyJsPlugin({ - parallel: true, - sourceMap: false, - uglifyOptions: { - compress: { - // the following is required for dead-code the removal - // check in React DevTools - - unused: true, - dead_code: true, - conditionals: true, - evaluate: true, - - comparisons: false, - sequences: false, - properties: false, - drop_debugger: false, - booleans: false, - loops: false, - toplevel: false, - top_retain: false, - hoist_funs: false, - if_return: false, - join_vars: false, - collapse_vars: false, - reduce_vars: false, - warnings: false, - negate_iife: false, - keep_fnames: true, - keep_infinity: true, - side_effects: false - }, - mangle: false - } - }), - ] + mode: 'production', + optimization: { + minimize: true, + minimizer: [ + new UglifyJsPlugin({ + parallel: true, + sourceMap: false, + uglifyOptions: { + compress: { + // The following is required for dead-code the removal + // check in React DevTools + // + // default + unused: true, + dead_code: true, + conditionals: true, + evaluate: true, + + // changed + keep_fnames: true, + keep_infinity: true, + comparisons: false, + sequences: false, + properties: false, + drop_debugger: false, + booleans: false, + loops: false, + toplevel: false, + top_retain: false, + hoist_funs: false, + if_return: false, + join_vars: false, + collapse_vars: false, + reduce_vars: false, + warnings: false, + negate_iife: false, + side_effects: false + }, + mangle: false + } + }), + ] + } }; return webpackMerge( @@ -421,15 +445,43 @@ export default class BaseOptimizer { ); } + isFailure(stats) { + if (stats.hasErrors()) { + return true; + } + + const { warnings } = stats.toJson({ all: false, warnings: true }); + + // 1 - when typescript doesn't do a full type check, as we have the ts-loader + // configured here, it does not have enough information to determine + // whether an imported name is a type or not, so when the name is then + // exported, typescript has no choice but to emit the export. Fortunately, + // the extraneous export should not be harmful, so we just suppress these warnings + // https://github.com/TypeStrong/ts-loader#transpileonly-boolean-defaultfalse + // + // 2 - Mini Css Extract plugin tracks the order for each css import we have + // through the project (and it's successive imports) since version 0.4.2. + // In case we have the same imports more than one time with different + // sequences, this plugin will throw a warning. This should not be harmful, + // but the an issue was opened and can be followed on: + // https://github.com/webpack-contrib/mini-css-extract-plugin/issues/250#issuecomment-415345126 + const filteredWarnings = Stats.filterWarnings(warnings, STATS_WARNINGS_FILTER); + + return filteredWarnings.length > 0; + } + failedStatsToError(stats) { const details = stats.toString(defaults( - { colors: true }, + { colors: true, warningsFilter: STATS_WARNINGS_FILTER }, Stats.presetToOptions('minimal') )); return Boom.internal( `Optimizations failure.\n${details.split('\n').join('\n ')}\n`, - stats.toJson(Stats.presetToOptions('detailed')) + stats.toJson(defaults({ + warningsFilter: STATS_WARNINGS_FILTER, + ...Stats.presetToOptions('detailed') + })) ); } } diff --git a/src/optimize/bundles_route/__tests__/bundles_route.js b/src/optimize/bundles_route/__tests__/bundles_route.js index 305bfb085d81f..bad4789311ef4 100644 --- a/src/optimize/bundles_route/__tests__/bundles_route.js +++ b/src/optimize/bundles_route/__tests__/bundles_route.js @@ -42,7 +42,8 @@ describe('optimizer/bundle route', () => { function createServer(options = {}) { const { - bundlesPath = outputFixture, + regularBundlesPath = outputFixture, + dllBundlesPath = outputFixture, basePublicPath = '' } = options; @@ -50,7 +51,8 @@ describe('optimizer/bundle route', () => { server.register([Inert]); server.route(createBundlesRoute({ - bundlesPath, + regularBundlesPath, + dllBundlesPath, basePublicPath, })); @@ -60,28 +62,32 @@ describe('optimizer/bundle route', () => { afterEach(() => sandbox.restore()); describe('validation', () => { - it('validates that bundlesPath is an absolute path', () => { + it('validates that regularBundlesPath is an absolute path', () => { expect(() => { createBundlesRoute({ - bundlesPath: null, + regularBundlesPath: null, + dllBundlesPath: '/absolute/path', basePublicPath: '' }); }).to.throwError(/absolute path/); expect(() => { createBundlesRoute({ - bundlesPath: './relative', + regularBundlesPath: './relative', + dllBundlesPath: '/absolute/path', basePublicPath: '' }); }).to.throwError(/absolute path/); expect(() => { createBundlesRoute({ - bundlesPath: 1234, + regularBundlesPath: 1234, + dllBundlesPath: '/absolute/path', basePublicPath: '' }); }).to.throwError(/absolute path/); expect(() => { createBundlesRoute({ - bundlesPath: '/absolute/path', + regularBundlesPath: '/absolute/path', + dllBundlesPath: '/absolute/path', basePublicPath: '' }); }).to.not.throwError(); @@ -89,37 +95,43 @@ describe('optimizer/bundle route', () => { it('validates that basePublicPath is valid', () => { expect(() => { createBundlesRoute({ - bundlesPath: '/bundles', + regularBundlesPath: '/bundles', + dllBundlesPath: '/absolute/path', basePublicPath: 123 }); }).to.throwError(/string/); expect(() => { createBundlesRoute({ - bundlesPath: '/bundles', + regularBundlesPath: '/bundles', + dllBundlesPath: '/absolute/path', basePublicPath: {} }); }).to.throwError(/string/); expect(() => { createBundlesRoute({ - bundlesPath: '/bundles', + regularBundlesPath: '/bundles', + dllBundlesPath: '/absolute/path', basePublicPath: '/a/' }); }).to.throwError(/start and not end with a \//); expect(() => { createBundlesRoute({ - bundlesPath: '/bundles', + regularBundlesPath: '/bundles', + dllBundlesPath: '/absolute/path', basePublicPath: 'a/' }); }).to.throwError(/start and not end with a \//); expect(() => { createBundlesRoute({ - bundlesPath: '/bundles', + regularBundlesPath: '/bundles', + dllBundlesPath: '/absolute/path', basePublicPath: '/a' }); }).to.not.throwError(); expect(() => { createBundlesRoute({ - bundlesPath: '/bundles', + regularBundlesPath: '/bundles', + dllBundlesPath: '/absolute/path', basePublicPath: '' }); }).to.not.throwError(); @@ -215,7 +227,7 @@ describe('optimizer/bundle route', () => { }); }); - describe('js file outside bundlesPath', () => { + describe('js file outside regularBundlesPath', () => { it('responds with a 404', async () => { const server = createServer(); @@ -249,10 +261,10 @@ describe('optimizer/bundle route', () => { }); }); - describe('missing bundlesPath', () => { + describe('missing regularBundlesPath', () => { it('responds with 404', async () => { const server = createServer({ - bundlesPath: resolve(__dirname, 'fixtures/not_really_output') + regularBundlesPath: resolve(__dirname, 'fixtures/not_really_output') }); const response = await server.inject({ diff --git a/src/optimize/bundles_route/bundles_route.js b/src/optimize/bundles_route/bundles_route.js index 40b708a9c7b59..d00f4dd3378a2 100644 --- a/src/optimize/bundles_route/bundles_route.js +++ b/src/optimize/bundles_route/bundles_route.js @@ -18,29 +18,35 @@ */ import { isAbsolute, extname } from 'path'; - import LruCache from 'lru-cache'; - import { createDynamicAssetResponse } from './dynamic_asset_response'; /** - * Creates a route that serves files from `bundlesPath`. If the + * Creates the routes that serves files from `bundlesPath` or from + * `dllBundlesPath` (if they are dll bundle's related files). If the * file is js or css then it is searched for instances of * PUBLIC_PATH_PLACEHOLDER and replaces them with `publicPath`. + * * @param {Object} options - * @property {string} options.bundlesPath + * @property {string} options.regularBundlesPath + * @property {string} options.dllBundlesPath * @property {string} options.basePublicPath - * @return {Hapi.RouteConfig} + * + * @return Array.of({Hapi.Route}) */ -export function createBundlesRoute({ bundlesPath, basePublicPath }) { +export function createBundlesRoute({ regularBundlesPath, dllBundlesPath, basePublicPath }) { // rather than calculate the fileHash on every request, we // provide a cache object to `createDynamicAssetResponse()` that // will store the 100 most recently used hashes. const fileHashCache = new LruCache(100); - if (typeof bundlesPath !== 'string' || !isAbsolute(bundlesPath)) { - throw new TypeError('bundlesPath must be an absolute path to the directory containing the bundles'); + if (typeof regularBundlesPath !== 'string' || !isAbsolute(regularBundlesPath)) { + throw new TypeError('regularBundlesPath must be an absolute path to the directory containing the regular bundles'); + } + + if (typeof dllBundlesPath !== 'string' || !isAbsolute(dllBundlesPath)) { + throw new TypeError('dllBundlesPath must be an absolute path to the directory containing the dll bundles'); } if (typeof basePublicPath !== 'string') { @@ -51,15 +57,23 @@ export function createBundlesRoute({ bundlesPath, basePublicPath }) { throw new TypeError('basePublicPath must be empty OR start and not end with a /'); } + return [ + buildRouteForBundles(basePublicPath, '/bundles/', regularBundlesPath, fileHashCache), + buildRouteForBundles(basePublicPath, '/dlls/', dllBundlesPath, fileHashCache), + ]; +} + +function buildRouteForBundles(basePublicPath, routePath, bundlesPath, fileHashCache) { return { method: 'GET', - path: '/bundles/{path*}', + path: `${routePath}{path*}`, config: { auth: false, ext: { onPreHandler: { method(request, h) { const ext = extname(request.params.path); + if (ext !== '.js' && ext !== '.css') { return h.continue; } @@ -69,7 +83,7 @@ export function createBundlesRoute({ bundlesPath, basePublicPath }) { h, bundlesPath, fileHashCache, - publicPath: `${basePublicPath}/bundles/` + publicPath: `${basePublicPath}${routePath}` }); } } diff --git a/src/optimize/bundles_route/index.js b/src/optimize/bundles_route/index.js index 6904a791b6b69..66b4edc465305 100644 --- a/src/optimize/bundles_route/index.js +++ b/src/optimize/bundles_route/index.js @@ -18,3 +18,4 @@ */ export { createBundlesRoute } from './bundles_route'; +export { createProxyBundlesRoute } from './proxy_bundles_route'; diff --git a/src/optimize/bundles_route/proxy_bundles_route.js b/src/optimize/bundles_route/proxy_bundles_route.js new file mode 100644 index 0000000000000..300c6296a8d91 --- /dev/null +++ b/src/optimize/bundles_route/proxy_bundles_route.js @@ -0,0 +1,41 @@ +/* + * 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 createProxyBundlesRoute({ host, port }) { + return [ + buildProxyRouteForBundles('/bundles/', host, port), + buildProxyRouteForBundles('/dlls/', host, port) + ]; +} + +function buildProxyRouteForBundles(routePath, host, port) { + return { + path: `${routePath}{path*}`, + method: 'GET', + handler: { + proxy: { + host, + port, + passThrough: true, + xforward: true + } + }, + config: { auth: false } + }; +} diff --git a/src/optimize/dynamic_dll_plugin/dll_compiler.js b/src/optimize/dynamic_dll_plugin/dll_compiler.js new file mode 100644 index 0000000000000..37170a68688f2 --- /dev/null +++ b/src/optimize/dynamic_dll_plugin/dll_compiler.js @@ -0,0 +1,214 @@ +/* + * 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 { configModel } from './dll_config_model'; +import { fromRoot } from '../../utils'; +import { PUBLIC_PATH_PLACEHOLDER } from '../public_path_placeholder'; +import fs from 'fs'; +import mkdirp from 'mkdirp'; +import webpack from 'webpack'; +import { promisify } from 'util'; +import path from 'path'; + +const readFileAsync = promisify(fs.readFile); +const mkdirpAsync = promisify(mkdirp); +const existsAsync = promisify(fs.exists); +const writeFileAsync = promisify(fs.writeFile); + +export class DllCompiler { + static getRawDllConfig(alias = {}, noParseRules = []) { + return { + alias, + noParseRules, + context: fromRoot('.'), + entryName: 'vendors', + dllName: '[name]', + manifestName: '[name]', + styleName: '[name]', + entryExt: '.entry.dll.js', + dllExt: '.bundle.dll.js', + manifestExt: '.manifest.dll.json', + styleExt: '.style.dll.css', + outputPath: fromRoot('./dlls'), + publicPath: PUBLIC_PATH_PLACEHOLDER + }; + } + + constructor(uiBundles, log) { + this.rawDllConfig = DllCompiler.getRawDllConfig( + uiBundles.getAliases(), + uiBundles.getWebpackNoParseRules() + ); + this.log = log || (() => null); + } + + async init() { + await this.ensureEntryFileExists(); + await this.ensureManifestFileExists(); + await this.ensureOutputPathExists(); + } + + async upsertEntryFile(content) { + await this.upsertFile(this.getEntryPath(), content); + } + + async upsertFile(filePath, content = '') { + await this.ensurePathExists(filePath); + await writeFileAsync(filePath, content, 'utf8'); + } + + getDllPath() { + return this.resolvePath( + `${this.rawDllConfig.entryName}${this.rawDllConfig.dllExt}` + ); + } + + getEntryPath() { + return this.resolvePath( + `${this.rawDllConfig.entryName}${this.rawDllConfig.entryExt}` + ); + } + + getManifestPath() { + return this.resolvePath( + `${this.rawDllConfig.entryName}${this.rawDllConfig.manifestExt}` + ); + } + + getStylePath() { + return this.resolvePath( + `${this.rawDllConfig.entryName}${this.rawDllConfig.styleExt}` + ); + } + + async ensureEntryFileExists() { + await this.ensureFileExists(this.getEntryPath()); + } + + async ensureManifestFileExists() { + await this.ensureFileExists( + this.getManifestPath(), + JSON.stringify({ + name: this.rawDllConfig.entryName, + content: {} + }) + ); + } + + async ensureStyleFileExists() { + await this.ensureFileExists(this.getStylePath()); + } + + async ensureFileExists(filePath, content) { + const exists = await this.ensurePathExists(filePath); + + if (!exists) { + await this.upsertFile(filePath, content); + } + } + + async ensurePathExists(filePath) { + const exists = await existsAsync(filePath); + + if (!exists) { + await mkdirpAsync(path.dirname(filePath)); + } + + return exists; + } + + async ensureOutputPathExists() { + await this.ensurePathExists(this.rawDllConfig.outputPath); + } + + dllExistsSync() { + return this.existsSync(this.getDllPath()); + } + + existsSync(filePath) { + return fs.existsSync(filePath); + } + + resolvePath() { + return path.resolve(this.rawDllConfig.outputPath, ...arguments); + } + + async readEntryFile() { + return await this.readFile(this.getEntryPath()); + } + + async readFile(filePath, content) { + await this.ensureFileExists(filePath, content); + return await readFileAsync(filePath, 'utf8'); + } + + async run(dllEntries) { + const dllConfig = this.dllConfigGenerator(this.rawDllConfig); + await this.upsertEntryFile(dllEntries); + await this.runWebpack(dllConfig()); + + // Style dll file isn't always created but we are + // expecting it to exist always as we are referencing + // it from the bootstrap template + // + // NOTE: We should review the way we deal with the css extraction + // in ours webpack builds. The industry standard is about to + // only extract css for production but we are extracting it + // in every single compilation. + await this.ensureStyleFileExists(); + } + + dllConfigGenerator(dllConfig) { + return configModel.bind(this, dllConfig); + } + + async runWebpack(config) { + return new Promise((resolve, reject) => { + this.log(['info', 'optimize:dynamic_dll_plugin'], 'Client vendors dll compilation started'); + + webpack(config, (err, stats) => { + // If a critical error occurs or we have + // errors in the stats compilation, + // reject the promise and logs the errors + const webpackErrors = err || (stats.hasErrors() && stats.toString({ + all: false, + colors: true, + errors: true, + errorDetails: true, + moduleTrace: true + })); + + if (webpackErrors) { + this.log( + ['fatal', 'optimize:dynamic_dll_plugin'], + `Client vendors dll compilation failed` + ); + return reject(webpackErrors); + } + + // Otherwise let it proceed + this.log( + ['info', 'optimize:dynamic_dll_plugin'], + `Client vendors dll compilation finished with success` + ); + return resolve(stats); + }); + }); + } +} diff --git a/src/optimize/dynamic_dll_plugin/dll_config_model.js b/src/optimize/dynamic_dll_plugin/dll_config_model.js new file mode 100644 index 0000000000000..208a493bdf554 --- /dev/null +++ b/src/optimize/dynamic_dll_plugin/dll_config_model.js @@ -0,0 +1,242 @@ +/* + * 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 { fromRoot, IS_KIBANA_DISTRIBUTABLE } from '../../utils'; +import webpack from 'webpack'; +import webpackMerge from 'webpack-merge'; +import MiniCssExtractPlugin from 'mini-css-extract-plugin'; +import UglifyJsPlugin from 'uglifyjs-webpack-plugin'; + +function generateDLL(config) { + const { + dllAlias, + dllNoParseRules, + dllContext, + dllEntry, + dllOutputPath, + dllPublicPath, + dllBundleName, + dllBundleFilename, + dllStyleFilename, + dllManifestPath + } = config; + + const BABEL_PRESET_PATH = require.resolve('@kbn/babel-preset/webpack_preset'); + const BABEL_EXCLUDE_RE = [ + /[\/\\](webpackShims|node_modules|bower_components)[\/\\]/, + ]; + + return { + entry: dllEntry, + context: dllContext, + output: { + filename: dllBundleFilename, + path: dllOutputPath, + publicPath: dllPublicPath, + library: dllBundleName + }, + node: { fs: 'empty', child_process: 'empty', dns: 'empty', net: 'empty', tls: 'empty' }, + resolve: { + extensions: ['.js', '.json'], + mainFields: ['browser', 'browserify', 'main'], + alias: dllAlias, + modules: [ + 'webpackShims', + fromRoot('webpackShims'), + + 'node_modules', + fromRoot('node_modules'), + ], + }, + module: { + rules: [ + { + resource: [ + { + test: /\.js$/, + exclude: BABEL_EXCLUDE_RE.concat(dllNoParseRules), + }, + { + test: /\.js$/, + include: /[\/\\]node_modules[\/\\]x-pack[\/\\]/, + exclude: /[\/\\]node_modules[\/\\]x-pack[\/\\](.+?[\/\\])*node_modules[\/\\]/, + } + ], + use: { + loader: 'babel-loader', + options: { + babelrc: false, + presets: [ + BABEL_PRESET_PATH, + ], + }, + } + }, + { + test: /\.(html|tmpl)$/, + loader: 'raw-loader' + }, + { + test: /\.css$/, + use: [ + MiniCssExtractPlugin.loader, + 'css-loader' + ], + }, + { + test: /\.png$/, + loader: 'url-loader' + }, + { + test: /\.(woff|woff2|ttf|eot|svg|ico)(\?|$)/, + loader: 'file-loader' + }, + ], + noParse: dllNoParseRules, + }, + plugins: [ + new webpack.DllPlugin({ + context: dllContext, + name: dllBundleName, + path: dllManifestPath + }), + new MiniCssExtractPlugin({ + filename: dllStyleFilename + }), + ], + performance: { + // NOTE: we are disabling this as those hints + // are more tailored for the final bundles result + // and not for the webpack compilations performance itself + hints: false + } + }; +} + +function extendRawConfig(rawConfig) { + // Build all extended configs from raw config + const dllAlias = rawConfig.alias; + const dllNoParseRules = rawConfig.noParseRules; + const dllContext = rawConfig.context; + const dllEntry = {}; + const dllEntryName = rawConfig.entryName; + const dllBundleName = rawConfig.dllName; + const dllManifestName = rawConfig.dllName; + const dllStyleName = rawConfig.styleName; + const dllEntryExt = rawConfig.entryExt; + const dllBundleExt = rawConfig.dllExt; + const dllManifestExt = rawConfig.manifestExt; + const dllStyleExt = rawConfig.styleExt; + const dllOutputPath = rawConfig.outputPath; + const dllPublicPath = rawConfig.publicPath; + const dllBundleFilename = `${dllBundleName}${dllBundleExt}`; + const dllManifestPath = `${dllOutputPath}/${dllManifestName}${dllManifestExt}`; + const dllStyleFilename = `${dllStyleName}${dllStyleExt}`; + + // Create webpack entry object key with the provided dllEntryName + dllEntry[dllEntryName] = [ + `${dllOutputPath}/${dllEntryName}${dllEntryExt}` + ]; + + // Export dll config map + return { + dllAlias, + dllNoParseRules, + dllContext, + dllEntry, + dllOutputPath, + dllPublicPath, + dllBundleName, + dllBundleFilename, + dllStyleFilename, + dllManifestPath + }; +} + +function common(rawConfig) { + return webpackMerge( + generateDLL(extendRawConfig(rawConfig)) + ); +} + +function optimized() { + return webpackMerge( + { + mode: 'production', + optimization: { + minimize: true, + minimizer: [ + new UglifyJsPlugin({ + parallel: true, + sourceMap: false, + uglifyOptions: { + compress: { + // The following is required for dead-code the removal + // check in React DevTools + // + // default + unused: true, + dead_code: true, + conditionals: true, + evaluate: true, + + // changed + keep_fnames: true, + keep_infinity: true, + comparisons: false, + sequences: false, + properties: false, + drop_debugger: false, + booleans: false, + loops: false, + toplevel: false, + top_retain: false, + hoist_funs: false, + if_return: false, + join_vars: false, + collapse_vars: false, + reduce_vars: false, + warnings: false, + negate_iife: false, + side_effects: false + }, + mangle: false + } + }), + ] + } + } + ); +} + +function unoptimized() { + return webpackMerge( + { + mode: 'development' + } + ); +} + +export function configModel(rawConfig = {}) { + if (IS_KIBANA_DISTRIBUTABLE) { + return webpackMerge(common(rawConfig), optimized()); + } + + return webpackMerge(common(rawConfig), unoptimized()); +} diff --git a/src/optimize/dynamic_dll_plugin/dynamic_dll_plugin.js b/src/optimize/dynamic_dll_plugin/dynamic_dll_plugin.js new file mode 100644 index 0000000000000..bb1ded7420411 --- /dev/null +++ b/src/optimize/dynamic_dll_plugin/dynamic_dll_plugin.js @@ -0,0 +1,467 @@ +/* + * 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 { DllCompiler } from './dll_compiler'; +import { IS_KIBANA_DISTRIBUTABLE } from '../../utils'; +import RawModule from 'webpack/lib/RawModule'; +import webpack from 'webpack'; +import path from 'path'; +import normalizePosixPath from 'normalize-path'; +import fs from 'fs'; +import { promisify } from 'util'; +import { parseSingleFileSync, dependenciesVisitorsGenerator } from '@kbn/babel-code-parser'; + +const realPathAsync = promisify(fs.realpath); +const DLL_ENTRY_STUB_MODULE_TYPE = 'javascript/dll-entry-stub'; + +function inNodeModulesOrWebpackShims(checkPath) { + return checkPath.includes(`${path.sep}node_modules${path.sep}`) + || checkPath.includes(`${path.sep}webpackShims${path.sep}`); +} + +function inPluginNodeModules(checkPath) { + return checkPath.match(/[\/\\]plugins.*[\/\\]node_modules/); +} + +export class DynamicDllPlugin { + constructor({ uiBundles, log, maxCompilations = 1 }) { + this.log = log || (() => null); + this.dllCompiler = new DllCompiler(uiBundles, log); + this.entryPaths = ''; + this.afterCompilationEntryPaths = ''; + this.maxCompilations = maxCompilations; + this.performedCompilations = 0; + this.forceDLLCreationFlag = !!(process && process.env && process.env.FORCE_DLL_CREATION); + } + + async init() { + await this.dllCompiler.init(); + this.entryPaths = await this.dllCompiler.readEntryFile(); + } + + apply(compiler) { + // Just register the init basic hooks + // in order to run the init function + this.registerInitBasicHooks(compiler); + // The dll reference should always be bind to the + // main webpack config. + this.bindDllReferencePlugin(compiler); + + // Verify if we must init and run the dynamic dll plugin tasks. + // We must run it every time we are not under a distributable env + if (!this.mustRunDynamicDllPluginTasks()) { + return; + } + + // This call init all the DynamicDllPlugin tasks + // as it attaches the plugin to the main webpack + // lifecycle hooks needed to perform the logic + this.registerTasksHooks(compiler); + } + + bindDllReferencePlugin(compiler) { + const rawDllConfig = this.dllCompiler.rawDllConfig; + const dllContext = rawDllConfig.context; + const dllManifestPath = this.dllCompiler.getManifestPath(); + + new webpack.DllReferencePlugin({ + context: dllContext, + manifest: dllManifestPath, + }).apply(compiler); + } + + registerInitBasicHooks(compiler) { + this.registerRunHook(compiler); + this.registerWatchRunHook(compiler); + } + + registerTasksHooks(compiler) { + this.log(['info', 'optimize:dynamic_dll_plugin'], 'Started dynamic dll plugin tasks'); + this.registerBeforeCompileHook(compiler); + this.registerCompilationHook(compiler); + this.registerDoneHook(compiler); + } + + registerRunHook(compiler) { + compiler.hooks.run.tapPromise('DynamicDllPlugin', async () => { + await this.init(); + }); + } + + registerWatchRunHook(compiler) { + compiler.hooks.watchRun.tapPromise('DynamicDllPlugin', async () => { + await this.init(); + }); + } + + registerBeforeCompileHook(compiler) { + compiler.hooks.beforeCompile.tapPromise('DynamicDllPlugin', async ({ normalModuleFactory }) => { + normalModuleFactory.hooks.factory.tap( + 'DynamicDllPlugin', + (actualFactory) => (params, cb) => { + // This is used in order to avoid the cache for DLL modules + // resolved from other dependencies + normalModuleFactory.cachePredicate = (module) => !(module.stubType === DLL_ENTRY_STUB_MODULE_TYPE); + + // Overrides the normalModuleFactory module creation behaviour + // in order to understand the modules we need to add to the DLL + actualFactory(params, (error, module) => { + if (error || !module) { + cb(error, module); + } else { + this.mapNormalModule(module).then( + (m = module) => cb(undefined, m), + error => cb(error) + ); + } + }); + } + ); + }); + } + + registerCompilationHook(compiler) { + compiler.hooks.compilation.tap('DynamicDllPlugin', compilation => { + compilation.hooks.needAdditionalPass.tap('DynamicDllPlugin', () => { + // Run the procedures in order to execute our dll compilation + // The process is very straightforward in it's conception: + // + // * 1 - loop through every compilation module in order to start building + // the dll entry paths arrays and assume it is the new entry paths + // * 1.1 - start from adding the modules already included into the dll, if any. + // * 1.2 - adding the new discovered stub modules + // * 1.3 - check if the module added to the entry path is from node_modules or + // webpackShims, otherwise throw an error. + // * 1.3.1 - for the entry path modules coming from webpackShims search for every + // require statements inside of them + // * 1.3.2 - discard the ones that are not js dependencies + // * 1.3.3 - add those new discovered dependencies inside the webpackShims to the + // entry paths array + // * 2 - compare the built entry paths and compares it to the old one (if any) + // * 3 - runs a new dll compilation in case there is none old entry paths or if the + // new built one differs from the old one. + // + const rawDllConfig = this.dllCompiler.rawDllConfig; + const dllContext = rawDllConfig.context; + const dllOutputPath = rawDllConfig.outputPath; + const requiresMap = {}; + const resolvedShimsDependenciesMap = {}; + + for (const module of compilation.modules) { + let requiredModulePath = null; + + // re-include requires for modules already handled by the dll + if (module.delegateData) { + const absoluteResource = path.resolve(dllContext, module.userRequest); + if (absoluteResource.includes('node_modules') || absoluteResource.includes('webpackShims')) { + // NOTE: normalizePosixPath is been used as we only want to have posix + // paths inside our final dll entry file + requiresMap[`require('${normalizePosixPath(path.relative(dllOutputPath, absoluteResource))}');`] = true; + requiredModulePath = absoluteResource; + } + } + + // include requires for modules that need to be added to the dll + if (module.stubType === DLL_ENTRY_STUB_MODULE_TYPE) { + requiresMap[`require('${normalizePosixPath(path.relative(dllOutputPath, module.stubResource))}');`] = true; + requiredModulePath = module.stubResource; + } + + // read new requires for modules that reaches the compilation, + // aren't already being handled by dll and were not also + // in the entry paths before. The majority should come + // from webpackShims, otherwise we should throw + if (requiredModulePath && !requiredModulePath.includes('node_modules')) { + if (!requiredModulePath.includes('webpackShims')) { + throw new Error( + `The following module is reaching the compilation and ins\'t either a node_module or webpackShim: + ${requiredModulePath} + ` + ); + } + + // Get dependencies found in each webpack shim entry and just + // adds them to the global map for the resolvedShimsDependencies + Object.assign( + resolvedShimsDependenciesMap, + this.getDependenciesFromShim(requiredModulePath, compilation) + ); + } + } + + // Adds the discovered dep modules in webpackShims + // to the final require results + Object.assign( + requiresMap, + this.getRequireEntriesFromShimsDependencies(resolvedShimsDependenciesMap, dllOutputPath) + ); + + // Sort and join all the discovered require deps + // in order to create a consistent entry file + this.afterCompilationEntryPaths = Object.keys(requiresMap).sort().join('\n'); + // The dll compilation will run if on of the following conditions return true: + // 1 - the new generated entry paths are different from the + // old ones + // 2 - if no dll bundle is yet created + // 3 - if this.forceDLLCreationFlag were set from the node env var FORCE_DLL_CREATION and + // we are not running over the distributable. If we are running under the watch optimizer, + // this.forceDLLCreationFlag will only be applied in the very first execution, + // then will be set to false + compilation.needsDLLCompilation = (this.afterCompilationEntryPaths !== this.entryPaths) + || !this.dllCompiler.dllExistsSync() + || (this.isToForceDLLCreation() && this.performedCompilations === 0); + this.entryPaths = this.afterCompilationEntryPaths; + + // Only run this info log in the first performed dll compilation + // per each execution run + if (this.performedCompilations === 0) { + this.log( + ['info', 'optimize:dynamic_dll_plugin'], + compilation.needsDLLCompilation + ? 'Need to compile the client vendors dll' + : 'No need to compile client vendors dll' + ); + } + + return compilation.needsDLLCompilation; + }); + }); + } + + registerDoneHook(compiler) { + compiler.hooks.done.tapPromise('DynamicDllPlugin', async stats => { + if (stats.compilation.needsDLLCompilation) { + // Logic to run the max compilation requirements. + // Only enable this for CI builds in order to ensure + // we have an healthy dll ecosystem. + if (IS_KIBANA_DISTRIBUTABLE && (this.performedCompilations === this.maxCompilations)) { + throw new Error( + 'All the allowed dll compilations were already performed and one more is needed which is not possible' + ); + } + + // Run the dlls compiler and increment + // the performed compilations + await this.runDLLCompiler(compiler); + this.performedCompilations++; + return; + } + + this.performedCompilations = 0; + // reset this flag var set from the node env FORCE_DLL_CREATION on init, + // has the force_dll_creation is only valid for the very first run + if (this.forceDLLCreationFlag) { + this.forceDLLCreationFlag = false; + } + this.log(['info', 'optimize:dynamic_dll_plugin'], 'Finished all dynamic dll plugin tasks'); + }); + } + + getDependenciesFromShim(requiredModulePath, compilation) { + // NOTE: is possible we are able to do this reading and searching + // through the compilation's webpack modules, however + // for a sake of simplicity, and as the webpackShims + // should be really small files, we are parsing them + // manually and getting the requires + + // Internal map to keep track of the dependencies found for the + // current webpackShim file + const resolvedShimDependencies = {}; + + // Discover the requires inside the webpackShims + const shimsDependencies = parseSingleFileSync(requiredModulePath, dependenciesVisitorsGenerator); + + // Resolve webpackShims dependencies with alias + shimsDependencies.forEach((dep) => { + const isRelative = dep && dep.charAt(0) === '.'; + let absoluteResource = null; + + // check if the dependency value is relative + if (isRelative) { + absoluteResource = path.resolve(path.dirname(requiredModulePath), dep); + } else { + // get the imports and search for alias in the dependency + const alias = compilation.compiler.options.resolve.alias; + const aliasFound = Object.keys(alias).find((aliasKey) => { + return dep.search(`${aliasKey}/`) !== -1; + }); + // search for imports with webpack-loaders + const webpackLoaderFoundIdx = dep.search('!'); + + if (webpackLoaderFoundIdx !== -1) { + // get the loader + const loader = dep.substring(0, webpackLoaderFoundIdx); + // get the rest of the dependency require value + // after the webpack loader char (!) + const restImport = dep.substring(webpackLoaderFoundIdx + 1); + // build the first part with the loader resolved + const absoluteResourceFirstPart = require.resolve(loader); + // check if we have a relative path in the script require + // path being passed to the loader + const isRestImportRelative = restImport && restImport.charAt(0) === '.'; + // resolve the relative script dependency path + // in case we have one + const sanitizedRestImport = isRestImportRelative + ? path.resolve(path.dirname(requiredModulePath), restImport) + : restImport; + // replace the alias in the script dependency require path + // in case we have found the alias + const absoluteResourceSecondPart = aliasFound + ? require.resolve(`${alias[aliasFound]}${sanitizedRestImport.substring(aliasFound.length)}`) + : require.resolve(sanitizedRestImport); + + // finally build our absolute entry path again in the + // original loader format `webpack-loader!script_path` + absoluteResource = `${absoluteResourceFirstPart}!${absoluteResourceSecondPart}`; + } else { + // in case we don't have any webpack loader in the + // dependency require value, just replace the alias + // if we have one and then resolve the result, + // or just resolve the dependency path if we don't + // have any alias + absoluteResource = aliasFound + ? require.resolve(`${alias[aliasFound]}${dep.substring(aliasFound.length)}`) + : require.resolve(dep); + } + } + + // Only consider found js entries + if (!absoluteResource.includes('.js') || absoluteResource.includes('json')) { + return; + } + + // add the absolute built resource to the list of + // entry paths found inside the webpackShims + // to be merged with the general requiresMap + // in the end + resolvedShimDependencies[absoluteResource] = true; + }); + + return resolvedShimDependencies; + } + + getRequireEntriesFromShimsDependencies(resolvedShimsDependenciesMap, dllOutputPath) { + const internalRequiresMap = {}; + const resolvedShimsDependencies = Object.keys(resolvedShimsDependenciesMap); + + resolvedShimsDependencies.forEach((resolvedDep) => { + if (resolvedDep) { + // check if this is a require shim dependency with + // an webpack-loader + const webpackLoaderFoundIdx = resolvedDep.search('!'); + + if (webpackLoaderFoundIdx !== -1) { + // get the webpack-loader + const loader = resolvedDep.substring(0, webpackLoaderFoundIdx); + // get the rest of the dependency require value + // after the webpack-loader char (!) + const restImport = resolvedDep.substring(webpackLoaderFoundIdx + 1); + // resolve the loader and the restImport parts separately + const resolvedDepToRequireFirstPart = normalizePosixPath(path.relative(dllOutputPath, loader)); + const resolvedDepToRequireSecondPart = normalizePosixPath(path.relative(dllOutputPath, restImport)); + + // rebuild our final webpackShim entry path in the original + // webpack loader format `webpack-loader!script_path` + // but right now resolved relatively to the dll output path + internalRequiresMap[`require('${resolvedDepToRequireFirstPart}!${resolvedDepToRequireSecondPart}');`] = true; + } else { + // in case we didn't have any webpack-loader in the require path + // resolve the dependency path relative to the dllOutput path + // to get our final entry path + internalRequiresMap[`require('${normalizePosixPath(path.relative(dllOutputPath, resolvedDep))}');`] = true; + } + } + }); + + return internalRequiresMap; + } + + isToForceDLLCreation() { + return this.forceDLLCreationFlag; + } + + mustRunDynamicDllPluginTasks() { + return !IS_KIBANA_DISTRIBUTABLE || this.isToForceDLLCreation(); + } + + async mapNormalModule(module) { + // ignore anything that doesn't have a resource (ignored) or is already delegating to the DLL + if (!module.resource || module.delegateData) { + return; + } + + // ignore anything that needs special loaders or config + if (module.request.includes('!') || module.request.includes('?')) { + return; + } + + // ignore files that are not in node_modules + if (!inNodeModulesOrWebpackShims(module.resource)) { + return; + } + + // also ignore files that are symlinked into node_modules, but only + // do the `realpath` call after checking the plain resource path + if (!inNodeModulesOrWebpackShims(await realPathAsync(module.resource))) { + return; + } + + const dirs = module.resource.split(path.sep); + const nodeModuleName = dirs[dirs.lastIndexOf('node_modules') + 1]; + + // ignore webpack loader modules + if (nodeModuleName.endsWith('-loader')) { + return; + } + + // ignore modules from plugins + if (inPluginNodeModules(module.resource)) { + return; + } + + // also ignore files that are symlinked into plugins node_modules, but only + // do the `realpath` call after checking the plain resource path + if (inPluginNodeModules(await realPathAsync(module.resource))) { + return; + } + + // This is a StubModule (as a RawModule) in order + // to mimic the missing modules from the DLL and + // also hold useful metadata + const stubModule = new RawModule( + `/* pending dll entry */`, + `dll pending:${module.resource}`, + module.resource + ); + stubModule.stubType = DLL_ENTRY_STUB_MODULE_TYPE; + stubModule.stubResource = module.resource; + stubModule.stubOriginalModule = module; + + return stubModule; + } + + async runDLLCompiler(mainCompiler) { + await this.dllCompiler.run(this.entryPaths); + + // We need to purge the cache into the inputFileSystem + // for every single built in previous compilation + // that we rely in next ones. + mainCompiler.inputFileSystem.purge(this.dllCompiler.getManifestPath()); + } +} diff --git a/src/optimize/dynamic_dll_plugin/index.js b/src/optimize/dynamic_dll_plugin/index.js new file mode 100644 index 0000000000000..347811b5356b7 --- /dev/null +++ b/src/optimize/dynamic_dll_plugin/index.js @@ -0,0 +1,21 @@ +/* + * 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 { DynamicDllPlugin } from './dynamic_dll_plugin'; +export { DllCompiler } from './dll_compiler'; diff --git a/src/optimize/fs_optimizer.js b/src/optimize/fs_optimizer.js index d6a3cd26f553f..efe77cdbd7149 100644 --- a/src/optimize/fs_optimizer.js +++ b/src/optimize/fs_optimizer.js @@ -21,18 +21,16 @@ import BaseOptimizer from './base_optimizer'; import { fromNode } from 'bluebird'; export default class FsOptimizer extends BaseOptimizer { - async init() { - await this.initCompiler(); - } - async run() { - if (!this.compiler) await this.init(); + if (!this.compiler) { + await this.init(); + } await fromNode(cb => { this.compiler.run((err, stats) => { if (err || !stats) return cb(err); - if (stats.hasErrors() || stats.hasWarnings()) { + if (this.isFailure(stats)) { return cb(this.failedStatsToError(stats)); } else { diff --git a/src/optimize/index.js b/src/optimize/index.js index 8675a4fd2e458..f8373eb4e6ae4 100644 --- a/src/optimize/index.js +++ b/src/optimize/index.js @@ -19,6 +19,7 @@ import FsOptimizer from './fs_optimizer'; import { createBundlesRoute } from './bundles_route'; +import { DllCompiler } from './dynamic_dll_plugin'; export default async (kbnServer, server, config) => { if (!config.get('optimize.enabled')) return; @@ -28,9 +29,9 @@ export default async (kbnServer, server, config) => { // bundles in a "middleware" style. // // the server listening on 5601 may be restarted a number of times, depending - // on the watch setup managed by the cli. It proxies all bundles/* requests to - // the other server. The server on 5602 is long running, in order to prevent - // complete rebuilds of the optimize content. + // on the watch setup managed by the cli. It proxies all bundles/* and dlls/* + // requests to the other server. The server on 5602 is long running, in order + // to prevent complete rebuilds of the optimize content. const watch = config.get('optimize.watch'); if (watch) { return await kbnServer.mixin(require('./watch/watch')); @@ -38,7 +39,8 @@ export default async (kbnServer, server, config) => { const { uiBundles } = kbnServer; server.route(createBundlesRoute({ - bundlesPath: uiBundles.getWorkingDir(), + regularBundlesPath: uiBundles.getWorkingDir(), + dllBundlesPath: DllCompiler.getRawDllConfig().outputPath, basePublicPath: config.get('server.basePath') })); @@ -60,10 +62,10 @@ export default async (kbnServer, server, config) => { // only require the FsOptimizer when we need to const optimizer = new FsOptimizer({ + log: (tags, data) => server.log(tags, data), uiBundles, profile: config.get('optimize.profile'), sourceMaps: config.get('optimize.sourceMaps'), - unsafeCache: config.get('optimize.unsafeCache'), }); server.log( diff --git a/src/optimize/watch/optmzr_role.js b/src/optimize/watch/optmzr_role.js index 6d5df5b635086..6c45774f4cdbc 100644 --- a/src/optimize/watch/optmzr_role.js +++ b/src/optimize/watch/optmzr_role.js @@ -21,6 +21,7 @@ import { resolve } from 'path'; import WatchServer from './watch_server'; import WatchOptimizer, { STATUS } from './watch_optimizer'; +import { DllCompiler } from '../dynamic_dll_plugin'; import { WatchCache } from './watch_cache'; export default async (kbnServer, kibanaHapiServer, config) => { @@ -32,10 +33,10 @@ export default async (kbnServer, kibanaHapiServer, config) => { profile: config.get('optimize.profile'), sourceMaps: config.get('optimize.sourceMaps'), prebuild: config.get('optimize.watchPrebuild'), - unsafeCache: config.get('optimize.unsafeCache'), watchCache: new WatchCache({ log, outputPath: config.get('path.data'), + dllsPath: DllCompiler.getRawDllConfig().outputPath, cachePath: resolve(kbnServer.uiBundles.getCacheDirectory(), '../'), }) }); diff --git a/src/optimize/watch/proxy_role.js b/src/optimize/watch/proxy_role.js index 1a5ee97f78ce3..7cf455b94f033 100644 --- a/src/optimize/watch/proxy_role.js +++ b/src/optimize/watch/proxy_role.js @@ -17,24 +17,18 @@ * under the License. */ +import { createProxyBundlesRoute } from '../bundles_route'; import { fromNode } from 'bluebird'; import { get, once } from 'lodash'; export default (kbnServer, server, config) => { - server.route({ - path: '/bundles/{path*}', - method: 'GET', - handler: { - proxy: { - host: config.get('optimize.watchHost'), - port: config.get('optimize.watchPort'), - passThrough: true, - xforward: true - } - }, - config: { auth: false } - }); + server.route( + createProxyBundlesRoute({ + host: config.get('optimize.watchHost'), + port: config.get('optimize.watchPort') + }) + ); return fromNode(cb => { const timeout = setTimeout(() => { diff --git a/src/optimize/watch/watch.js b/src/optimize/watch/watch.js index dc87e190d59f5..7089524b8a468 100644 --- a/src/optimize/watch/watch.js +++ b/src/optimize/watch/watch.js @@ -33,7 +33,7 @@ export default async kbnServer => { * while the optimizer is running * * server: this process runs the entire kibana server and proxies - * all requests for /bundles/* to the optmzr process + * all requests for /bundles/* or /dlls/* to the optmzr process * * @param {string} process.env.kbnWorkerType */ diff --git a/src/optimize/watch/watch_cache.ts b/src/optimize/watch/watch_cache.ts index 9dd23a73418f9..f744900c21e8c 100644 --- a/src/optimize/watch/watch_cache.ts +++ b/src/optimize/watch/watch_cache.ts @@ -33,6 +33,7 @@ const writeAsync = promisify(writeFile); interface Params { log: (tags: string[], data: string) => void; outputPath: string; + dllsPath: string; cachePath: string; } @@ -44,6 +45,7 @@ interface WatchCacheStateContent { export class WatchCache { private readonly log: Params['log']; private readonly outputPath: Params['outputPath']; + private readonly dllsPath: Params['dllsPath']; private readonly cachePath: Params['cachePath']; private readonly cacheState: WatchCacheStateContent; private statePath: string; @@ -53,6 +55,7 @@ export class WatchCache { constructor(params: Params) { this.log = params.log; this.outputPath = params.outputPath; + this.dllsPath = params.dllsPath; this.cachePath = params.cachePath; this.isInitialized = false; @@ -107,6 +110,9 @@ export class WatchCache { // from the previous cache path reset action await deleteEmpty(this.cachePath); + // delete dlls + await del(this.dllsPath); + // re-write new cache state file await this.write(); @@ -118,7 +124,7 @@ export class WatchCache { for (const filePath of filePaths) { try { - shaHash.update(await readAsync(filePath), 'utf8'); + shaHash.update(await readAsync(filePath, 'utf8'), 'utf8'); } catch (e) { /* no-op */ } @@ -135,8 +141,14 @@ export class WatchCache { private async buildOptimizerConfigSha() { const baseOptimizer = resolve(__dirname, '../base_optimizer.js'); - - return await this.buildShaWithMultipleFiles([baseOptimizer]); + const dynamicDllConfigModel = resolve(__dirname, '../dynamic_dll_plugin/dll_config_model.js'); + const dynamicDllPlugin = resolve(__dirname, '../dynamic_dll_plugin/dynamic_dll_plugin.js'); + + return await this.buildShaWithMultipleFiles([ + baseOptimizer, + dynamicDllConfigModel, + dynamicDllPlugin, + ]); } private isResetNeeded() { diff --git a/src/optimize/watch/watch_optimizer.js b/src/optimize/watch/watch_optimizer.js index a4932e4247910..82e77f8bc22d3 100644 --- a/src/optimize/watch/watch_optimizer.js +++ b/src/optimize/watch/watch_optimizer.js @@ -17,12 +17,11 @@ * under the License. */ -import * as Rx from 'rxjs'; -import { mergeMap, take } from 'rxjs/operators'; - import BaseOptimizer from '../base_optimizer'; - import { createBundlesRoute } from '../bundles_route'; +import { DllCompiler } from '../dynamic_dll_plugin'; +import * as Rx from 'rxjs'; +import { mergeMap, take } from 'rxjs/operators'; export const STATUS = { RUNNING: 'optimizer running', @@ -34,7 +33,6 @@ export const STATUS = { export default class WatchOptimizer extends BaseOptimizer { constructor(opts) { super(opts); - this.log = opts.log || (() => null); this.prebuild = opts.prebuild || false; this.watchCache = opts.watchCache; this.status$ = new Rx.ReplaySubject(1); @@ -50,10 +48,8 @@ export default class WatchOptimizer extends BaseOptimizer { // log status changes this.status$.subscribe(this.onStatusChangeHandler); await this.uiBundles.resetBundleDir(); - await this.initCompiler(); + await super.init(); - this.compiler.plugin('watch-run', this.compilerRunStartHandler); - this.compiler.plugin('done', this.compilerDoneHandler); this.compiler.watch({ aggregateTimeout: 200 }, this.compilerWatchErrorHandler); if (this.prebuild) { @@ -63,6 +59,52 @@ export default class WatchOptimizer extends BaseOptimizer { this.initializing = false; } + /** + * + * Extends the base_optimizer registerCompilerHooks function + * calling extended function also adding a new register function + * + * It gets called by super.init() + */ + registerCompilerHooks() { + super.registerCompilerHooks(); + this.registerCompilerWatchRunHook(); + } + + registerCompilerWatchRunHook() { + this.compiler.hooks.watchRun.tap('watch_optimizer-watchRun', () => { + this.status$.next({ + type: STATUS.RUNNING + }); + }); + } + + registerCompilerDoneHook() { + super.registerCompilerDoneHook(); + + this.compiler.hooks.done.tap('watch_optimizer-done', stats => { + if (stats.compilation.needAdditionalPass) { + return; + } + + this.initialBuildComplete = true; + const seconds = parseFloat((stats.endTime - stats.startTime) / 1000).toFixed(2); + + if (this.isFailure(stats)) { + this.status$.next({ + type: STATUS.FAILURE, + seconds, + error: this.failedStatsToError(stats) + }); + } else { + this.status$.next({ + type: STATUS.SUCCESS, + seconds, + }); + } + }); + } + bindToServer(server, basePath) { // pause all requests received while the compiler is running // and continue once an outcome is reached (aborting the request @@ -73,7 +115,8 @@ export default class WatchOptimizer extends BaseOptimizer { }); server.route(createBundlesRoute({ - bundlesPath: this.compiler.outputPath, + regularBundlesPath: this.compiler.outputPath, + dllBundlesPath: DllCompiler.getRawDllConfig().outputPath, basePublicPath: basePath })); } @@ -100,14 +143,6 @@ export default class WatchOptimizer extends BaseOptimizer { } } - compilerRunStartHandler = (watchingCompiler, cb) => { - this.status$.next({ - type: STATUS.RUNNING - }); - - cb(); - } - compilerWatchErrorHandler = (error) => { if (error) { this.status$.next({ @@ -115,25 +150,7 @@ export default class WatchOptimizer extends BaseOptimizer { error }); } - } - - compilerDoneHandler = (stats) => { - this.initialBuildComplete = true; - const seconds = parseFloat((stats.endTime - stats.startTime) / 1000).toFixed(2); - - if (stats.hasErrors() || stats.hasWarnings()) { - this.status$.next({ - type: STATUS.FAILURE, - seconds, - error: this.failedStatsToError(stats) - }); - } else { - this.status$.next({ - type: STATUS.SUCCESS, - seconds, - }); - } - } + }; onStatusChangeHandler = ({ type, seconds, error }) => { switch (type) { diff --git a/src/server/config/schema.js b/src/server/config/schema.js index ae14c03e8cfcd..05c6830bf47bb 100644 --- a/src/server/config/schema.js +++ b/src/server/config/schema.js @@ -220,17 +220,6 @@ export default () => Joi.object({ watchPrebuild: Joi.boolean().default(false), watchProxyTimeout: Joi.number().default(5 * 60000), useBundleCache: Joi.boolean().default(Joi.ref('$prod')), - unsafeCache: Joi.when('$prod', { - is: true, - then: Joi.boolean().valid(false), - otherwise: Joi - .alternatives() - .try( - Joi.boolean(), - Joi.string().regex(/^\/.+\/$/) - ) - .default(true), - }), sourceMaps: Joi.when('$prod', { is: true, then: Joi.boolean().valid(false), diff --git a/src/server/logging/log_format_string.js b/src/server/logging/log_format_string.js index a55e26a7c3c6c..639f42098a689 100644 --- a/src/server/logging/log_format_string.js +++ b/src/server/logging/log_format_string.js @@ -49,6 +49,7 @@ const typeColors = { optmzr: 'white', manager: 'green', optimize: 'magentaBright', + 'optimize:dynamic_dll_plugin': 'magentaBright', 'optimize:watch_cache': 'magentaBright', listening: 'magentaBright', scss: 'magentaBright', diff --git a/src/ui/public/notify/index.d.ts b/src/ui/public/notify/index.d.ts index 829cf131f5a0a..c76924eb25819 100644 --- a/src/ui/public/notify/index.d.ts +++ b/src/ui/public/notify/index.d.ts @@ -18,3 +18,4 @@ */ export { toastNotifications, Toast, ToastInput } from './toasts'; +export { fatalError } from './fatal_error'; diff --git a/src/ui/public/state_management/__tests__/state.js b/src/ui/public/state_management/__tests__/state.js index 12058da104b79..cee21b1dab58b 100644 --- a/src/ui/public/state_management/__tests__/state.js +++ b/src/ui/public/state_management/__tests__/state.js @@ -293,10 +293,18 @@ describe('State Management', () => { expect(toastNotifications.list[0].title).to.match(/use the share functionality/i); }); - it('triggers fatal error linking to github when setting item fails', () => { + it.skip('triggers fatal error linking to github when setting item fails', () => { + // NOTE: this test needs to be written in jest and removed from the browser ones + // More info could be read in the opened issue: + // https://github.com/elastic/kibana/issues/22751 const { state, hashedItemStore } = setup({ storeInHash: true }); - const fatalErrorStub = sandbox.stub(FatalErrorNS, 'fatalError'); - sinon.stub(hashedItemStore, 'setItem').returns(false); + const fatalErrorStub = sandbox.stub(); + Object.defineProperty(FatalErrorNS, 'fatalError', { + writable: true, + value: fatalErrorStub + }); + + sandbox.stub(hashedItemStore, 'setItem').returns(false); state.toQueryParam(); sinon.assert.calledOnce(fatalErrorStub); sinon.assert.calledWith(fatalErrorStub, sinon.match(error => ( diff --git a/src/ui/ui_render/bootstrap/app_bootstrap.test.js b/src/ui/ui_render/bootstrap/app_bootstrap.test.js index a9f6f6a9278cb..b3de0824ae70f 100644 --- a/src/ui/ui_render/bootstrap/app_bootstrap.test.js +++ b/src/ui/ui_render/bootstrap/app_bootstrap.test.js @@ -22,7 +22,7 @@ import { resolve } from 'path'; const mockTemplate = ` {{appId}} -{{bundlePath}} +{{regularBundlePath}} {{i18n 'foo' '{"defaultMessage": "bar"}'}} `; @@ -102,7 +102,7 @@ describe('ui_render/AppBootstrap', () => { ...mockConfig(), templateData: { appId: 'not123', - bundlePath: 'not/foo/bar' + regularBundlePath: 'not/foo/bar' } }; const bootstrap2 = new AppBootstrap(config2); @@ -119,7 +119,7 @@ function mockConfig() { return { templateData: { appId: 123, - bundlePath: '/foo/bar' + regularBundlePath: '/foo/bar' } }; } diff --git a/src/ui/ui_render/bootstrap/template.js.hbs b/src/ui/ui_render/bootstrap/template.js.hbs index 50430e098f210..2090f804fd935 100644 --- a/src/ui/ui_render/bootstrap/template.js.hbs +++ b/src/ui/ui_render/bootstrap/template.js.hbs @@ -1,8 +1,8 @@ window.onload = function () { var files = [ - '{{bundlePath}}/vendors.bundle.js', - '{{bundlePath}}/commons.bundle.js', - '{{bundlePath}}/{{appId}}.bundle.js' + '{{dllBundlePath}}/vendors.bundle.dll.js', + '{{regularBundlePath}}/commons.bundle.js', + '{{regularBundlePath}}/{{appId}}.bundle.js' ]; var failure = function () { diff --git a/src/ui/ui_render/ui_render_mixin.js b/src/ui/ui_render/ui_render_mixin.js index 09e25f01b2fa9..833588a6de53c 100644 --- a/src/ui/ui_render/ui_render_mixin.js +++ b/src/ui/ui_render/ui_render_mixin.js @@ -62,17 +62,19 @@ export function uiRenderMixin(kbnServer, server, config) { } const basePath = config.get('server.basePath'); - const bundlePath = `${basePath}/bundles`; + const regularBundlePath = `${basePath}/bundles`; + const dllBundlePath = `${basePath}/dlls`; const styleSheetPaths = [ - `${bundlePath}/vendors.style.css`, - `${bundlePath}/commons.style.css`, - `${bundlePath}/${app.getId()}.style.css`, + `${dllBundlePath}/vendors.style.dll.css`, + `${regularBundlePath}/commons.style.css`, + `${regularBundlePath}/${app.getId()}.style.css`, ].concat(kbnServer.uiExports.styleSheetPaths.map(path => `${basePath}/${path.publicPath}`).reverse()); const bootstrap = new AppBootstrap({ templateData: { appId: app.getId(), - bundlePath, + regularBundlePath, + dllBundlePath, styleSheetPaths, } }); diff --git a/tasks/config/karma.js b/tasks/config/karma.js index 81e7710b26566..d2ca40cef2b35 100644 --- a/tasks/config/karma.js +++ b/tasks/config/karma.js @@ -85,16 +85,17 @@ module.exports = function (grunt) { // list of files / patterns to load in the browser files: [ - 'http://localhost:5610/bundles/vendors.bundle.js', + 'http://localhost:5610/dlls/vendors.bundle.dll.js', 'http://localhost:5610/bundles/tests.bundle.js', - 'http://localhost:5610/bundles/vendors.style.css', + 'http://localhost:5610/dlls/vendors.style.dll.css', 'http://localhost:5610/bundles/tests.style.css' ], proxies: { '/tests/': 'http://localhost:5610/tests/', - '/bundles/': 'http://localhost:5610/bundles/' + '/bundles/': 'http://localhost:5610/bundles/', + '/dlls/': 'http://localhost:5610/dlls/' }, client: { @@ -175,12 +176,10 @@ module.exports = function (grunt) { singleRun: true, options: { files: [ - 'http://localhost:5610/bundles/vendors.bundle.js', - 'http://localhost:5610/bundles/commons.bundle.js', + 'http://localhost:5610/dlls/vendors.bundle.dll.js', `http://localhost:5610/bundles/tests.bundle.js?shards=${TOTAL_CI_SHARDS}&shard_num=${n}`, - 'http://localhost:5610/bundles/vendors.style.css', - 'http://localhost:5610/bundles/commons.style.css', + 'http://localhost:5610/dlls/vendors.style.dll.css', 'http://localhost:5610/bundles/tests.style.css' ] } diff --git a/test/plugin_functional/plugins/custom_visualizations/package.json b/test/plugin_functional/plugins/custom_visualizations/package.json deleted file mode 100644 index 1b7e6f888e1bf..0000000000000 --- a/test/plugin_functional/plugins/custom_visualizations/package.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "custom_visualziations", - "version": "kibana" -} diff --git a/test/plugin_functional/plugins/custom_visualizations/README.md b/test/plugin_functional/plugins/kbn_tp_custom_visualizations/README.md similarity index 100% rename from test/plugin_functional/plugins/custom_visualizations/README.md rename to test/plugin_functional/plugins/kbn_tp_custom_visualizations/README.md diff --git a/test/plugin_functional/plugins/custom_visualizations/index.js b/test/plugin_functional/plugins/kbn_tp_custom_visualizations/index.js similarity index 91% rename from test/plugin_functional/plugins/custom_visualizations/index.js rename to test/plugin_functional/plugins/kbn_tp_custom_visualizations/index.js index a5854b28777dd..4ac3cbcf53371 100644 --- a/test/plugin_functional/plugins/custom_visualizations/index.js +++ b/test/plugin_functional/plugins/kbn_tp_custom_visualizations/index.js @@ -21,7 +21,7 @@ export default function (kibana) { return new kibana.Plugin({ uiExports: { visTypes: [ - 'plugins/custom_visualziations/self_changing_vis/self_changing_vis', + 'plugins/kbn_tp_custom_visualizations/self_changing_vis/self_changing_vis', ], }, }); diff --git a/test/plugin_functional/plugins/kbn_tp_custom_visualizations/package.json b/test/plugin_functional/plugins/kbn_tp_custom_visualizations/package.json new file mode 100644 index 0000000000000..228ce357f16eb --- /dev/null +++ b/test/plugin_functional/plugins/kbn_tp_custom_visualizations/package.json @@ -0,0 +1,13 @@ +{ + "name": "kbn_tp_custom_visualizations", + "version": "1.0.0", + "kibana": { + "version": "kibana", + "templateVersion": "1.0.0" + }, + "license": "Apache-2.0", + "dependencies": { + "@elastic/eui": "5.0.0", + "react": "^16.3.0" + } +} diff --git a/test/plugin_functional/plugins/custom_visualizations/public/self_changing_vis/self_changing_components.js b/test/plugin_functional/plugins/kbn_tp_custom_visualizations/public/self_changing_vis/self_changing_components.js similarity index 100% rename from test/plugin_functional/plugins/custom_visualizations/public/self_changing_vis/self_changing_components.js rename to test/plugin_functional/plugins/kbn_tp_custom_visualizations/public/self_changing_vis/self_changing_components.js diff --git a/test/plugin_functional/plugins/custom_visualizations/public/self_changing_vis/self_changing_editor.js b/test/plugin_functional/plugins/kbn_tp_custom_visualizations/public/self_changing_vis/self_changing_editor.js similarity index 100% rename from test/plugin_functional/plugins/custom_visualizations/public/self_changing_vis/self_changing_editor.js rename to test/plugin_functional/plugins/kbn_tp_custom_visualizations/public/self_changing_vis/self_changing_editor.js diff --git a/test/plugin_functional/plugins/custom_visualizations/public/self_changing_vis/self_changing_vis.js b/test/plugin_functional/plugins/kbn_tp_custom_visualizations/public/self_changing_vis/self_changing_vis.js similarity index 100% rename from test/plugin_functional/plugins/custom_visualizations/public/self_changing_vis/self_changing_vis.js rename to test/plugin_functional/plugins/kbn_tp_custom_visualizations/public/self_changing_vis/self_changing_vis.js diff --git a/test/plugin_functional/plugins/sample_app_plugin/index.js b/test/plugin_functional/plugins/kbn_tp_sample_app_plugin/index.js similarity index 94% rename from test/plugin_functional/plugins/sample_app_plugin/index.js rename to test/plugin_functional/plugins/kbn_tp_sample_app_plugin/index.js index b52ff7c7d58f0..e633619664736 100644 --- a/test/plugin_functional/plugins/sample_app_plugin/index.js +++ b/test/plugin_functional/plugins/kbn_tp_sample_app_plugin/index.js @@ -23,7 +23,7 @@ export default function (kibana) { app: { title: 'Test Plugin App', description: 'This is a sample plugin for the functional tests.', - main: 'plugins/sample_app_plugin/app', + main: 'plugins/kbn_tp_sample_app_plugin/app', } } }); diff --git a/test/plugin_functional/plugins/kbn_tp_sample_app_plugin/package.json b/test/plugin_functional/plugins/kbn_tp_sample_app_plugin/package.json new file mode 100644 index 0000000000000..2537bb9a7ed5c --- /dev/null +++ b/test/plugin_functional/plugins/kbn_tp_sample_app_plugin/package.json @@ -0,0 +1,9 @@ +{ + "name": "kbn_tp_sample_app_plugin", + "version": "1.0.0", + "kibana": { + "version": "kibana", + "templateVersion": "1.0.0" + }, + "license": "Apache-2.0" +} diff --git a/test/plugin_functional/plugins/sample_app_plugin/public/app.js b/test/plugin_functional/plugins/kbn_tp_sample_app_plugin/public/app.js similarity index 100% rename from test/plugin_functional/plugins/sample_app_plugin/public/app.js rename to test/plugin_functional/plugins/kbn_tp_sample_app_plugin/public/app.js diff --git a/test/plugin_functional/plugins/sample_panel_action/index.js b/test/plugin_functional/plugins/kbn_tp_sample_panel_action/index.js similarity index 88% rename from test/plugin_functional/plugins/sample_panel_action/index.js rename to test/plugin_functional/plugins/kbn_tp_sample_panel_action/index.js index b2bb3fc7c6158..c4aaaa857cecd 100644 --- a/test/plugin_functional/plugins/sample_panel_action/index.js +++ b/test/plugin_functional/plugins/kbn_tp_sample_panel_action/index.js @@ -21,8 +21,8 @@ function samplePanelAction(kibana) { return new kibana.Plugin({ uiExports: { contextMenuActions: [ - 'plugins/sample_panel_action/sample_panel_action', - 'plugins/sample_panel_action/sample_panel_link', + 'plugins/kbn_tp_sample_panel_action/sample_panel_action', + 'plugins/kbn_tp_sample_panel_action/sample_panel_link', ], }, }); diff --git a/test/plugin_functional/plugins/kbn_tp_sample_panel_action/package.json b/test/plugin_functional/plugins/kbn_tp_sample_panel_action/package.json new file mode 100644 index 0000000000000..6f0ce8eaea878 --- /dev/null +++ b/test/plugin_functional/plugins/kbn_tp_sample_panel_action/package.json @@ -0,0 +1,13 @@ +{ + "name": "kbn_tp_sample_panel_action", + "version": "1.0.0", + "kibana": { + "version": "kibana", + "templateVersion": "1.0.0" + }, + "license": "Apache-2.0", + "dependencies": { + "@elastic/eui": "5.0.0", + "react": "^16.3.0" + } +} diff --git a/test/plugin_functional/plugins/sample_panel_action/public/sample_panel_action.js b/test/plugin_functional/plugins/kbn_tp_sample_panel_action/public/sample_panel_action.js similarity index 100% rename from test/plugin_functional/plugins/sample_panel_action/public/sample_panel_action.js rename to test/plugin_functional/plugins/kbn_tp_sample_panel_action/public/sample_panel_action.js diff --git a/test/plugin_functional/plugins/sample_panel_action/public/sample_panel_link.js b/test/plugin_functional/plugins/kbn_tp_sample_panel_action/public/sample_panel_link.js similarity index 100% rename from test/plugin_functional/plugins/sample_panel_action/public/sample_panel_link.js rename to test/plugin_functional/plugins/kbn_tp_sample_panel_action/public/sample_panel_link.js diff --git a/test/plugin_functional/plugins/visualize_embedding/index.js b/test/plugin_functional/plugins/kbn_tp_visualize_embedding/index.js similarity index 91% rename from test/plugin_functional/plugins/visualize_embedding/index.js rename to test/plugin_functional/plugins/kbn_tp_visualize_embedding/index.js index 9674260e919c0..1ec4ea2b9e096 100644 --- a/test/plugin_functional/plugins/visualize_embedding/index.js +++ b/test/plugin_functional/plugins/kbn_tp_visualize_embedding/index.js @@ -23,7 +23,7 @@ export default function (kibana) { app: { title: 'Embedding Vis', description: 'This is a sample plugin to test embedding of visualizations', - main: 'plugins/visualize_embedding/app', + main: 'plugins/kbn_tp_visualize_embedding/app', } }, @@ -31,7 +31,7 @@ export default function (kibana) { // The following lines copy over some configuration variables from Kibana // to this plugin. This will be needed when embedding visualizations, so that e.g. // region map is able to get its configuration. - server.injectUiAppVars('visualize_embedding', async () => { + server.injectUiAppVars('kbn_tp_visualize_embedding', async () => { return await server.getInjectedUiAppVars('kibana'); }); } diff --git a/test/plugin_functional/plugins/kbn_tp_visualize_embedding/package.json b/test/plugin_functional/plugins/kbn_tp_visualize_embedding/package.json new file mode 100644 index 0000000000000..eb67a8a876c5d --- /dev/null +++ b/test/plugin_functional/plugins/kbn_tp_visualize_embedding/package.json @@ -0,0 +1,14 @@ +{ + "name": "kbn_tp_visualize_embedding", + "version": "1.0.0", + "kibana": { + "version": "kibana", + "templateVersion": "1.0.0" + }, + "license": "Apache-2.0", + "dependencies": { + "@elastic/eui": "5.0.0", + "react": "^16.3.0", + "react-dom": "^16.3.0" + } +} diff --git a/test/plugin_functional/plugins/visualize_embedding/public/app.js b/test/plugin_functional/plugins/kbn_tp_visualize_embedding/public/app.js similarity index 100% rename from test/plugin_functional/plugins/visualize_embedding/public/app.js rename to test/plugin_functional/plugins/kbn_tp_visualize_embedding/public/app.js diff --git a/test/plugin_functional/plugins/visualize_embedding/public/components/main.js b/test/plugin_functional/plugins/kbn_tp_visualize_embedding/public/components/main.js similarity index 100% rename from test/plugin_functional/plugins/visualize_embedding/public/components/main.js rename to test/plugin_functional/plugins/kbn_tp_visualize_embedding/public/components/main.js diff --git a/test/plugin_functional/plugins/visualize_embedding/public/embedding.js b/test/plugin_functional/plugins/kbn_tp_visualize_embedding/public/embedding.js similarity index 100% rename from test/plugin_functional/plugins/visualize_embedding/public/embedding.js rename to test/plugin_functional/plugins/kbn_tp_visualize_embedding/public/embedding.js diff --git a/test/plugin_functional/plugins/sample_app_plugin/package.json b/test/plugin_functional/plugins/sample_app_plugin/package.json deleted file mode 100644 index f61a46cb5e09b..0000000000000 --- a/test/plugin_functional/plugins/sample_app_plugin/package.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "sample_app_plugin", - "version": "kibana" -} diff --git a/test/plugin_functional/plugins/sample_panel_action/package.json b/test/plugin_functional/plugins/sample_panel_action/package.json deleted file mode 100644 index 1e9b81be558e4..0000000000000 --- a/test/plugin_functional/plugins/sample_panel_action/package.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "name": "sample_panel_action", - "version": "kibana", - "dependencies": { - "@elastic/eui": "0.0.55", - "react": "^16.4.1" - } -} diff --git a/test/plugin_functional/plugins/visualize_embedding/package.json b/test/plugin_functional/plugins/visualize_embedding/package.json deleted file mode 100644 index d20cf8720c261..0000000000000 --- a/test/plugin_functional/plugins/visualize_embedding/package.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "visualize_embedding", - "version": "kibana" -} diff --git a/x-pack/package.json b/x-pack/package.json index 6e7745a5c9b6b..2c604d702769d 100644 --- a/x-pack/package.json +++ b/x-pack/package.json @@ -21,7 +21,7 @@ } }, "resolutions": { - "**/@types/node": "8.10.21", + "**/@types/node": "8.10.38", "@types/react": "16.3.14" }, "devDependencies": { @@ -29,7 +29,7 @@ "@kbn/es": "1.0.0", "@kbn/plugin-helpers": "9.0.2", "@kbn/test": "1.0.0", - "@types/angular": "^1.6.50", + "@types/angular": "1.6.50", "@types/d3-array": "^1.2.1", "@types/d3-scale": "^2.0.0", "@types/d3-shape": "^1.2.2", @@ -108,7 +108,7 @@ "supertest-as-promised": "^4.0.2", "tmp": "0.0.31", "tree-kill": "^1.1.0", - "ts-loader": "^3.5.0", + "ts-loader": "^5.2.2", "typescript": "^3.0.3", "vinyl-fs": "^3.0.2", "xml-crypto": "^0.10.1", @@ -141,7 +141,7 @@ "apollo-server-errors": "^2.0.2", "apollo-server-hapi": "^1.3.6", "axios": "^0.18.0", - "babel-core": "^6.26.0", + "babel-core": "^6.26.3", "babel-polyfill": "6.20.0", "babel-preset-es2015": "^6.24.1", "babel-register": "^6.26.0", diff --git a/x-pack/plugins/canvas/tasks/helpers/webpack.plugins.js b/x-pack/plugins/canvas/tasks/helpers/webpack.plugins.js index 0968417d5d260..04a3e5a7cc5bd 100644 --- a/x-pack/plugins/canvas/tasks/helpers/webpack.plugins.js +++ b/x-pack/plugins/canvas/tasks/helpers/webpack.plugins.js @@ -15,6 +15,7 @@ export function getWebpackConfig({ devtool, watch } = {}) { watch, devtool, + mode: 'none', entry: { 'elements/all': path.join(sourceDir, 'elements/register.js'), 'renderers/all': path.join(sourceDir, 'renderers/register.js'), @@ -36,6 +37,16 @@ export function getWebpackConfig({ devtool, watch } = {}) { path: buildDir, filename: '[name].js', // Need long paths here. libraryTarget: 'umd', + // Note: this is needed due to a not yet resolved bug on + // webpack 4 with umd modules generation. + // For now we have 2 quick workarounds: one is what is implemented + // below another is to change the libraryTarget to commonjs + // + // The issues can be followed on: + // https://github.com/webpack/webpack/issues/6642 + // https://github.com/webpack/webpack/issues/6525 + // https://github.com/webpack/webpack/issues/6677 + globalObject: `(typeof self !== 'undefined' ? self : this)`, }, resolve: { @@ -44,10 +55,10 @@ export function getWebpackConfig({ devtool, watch } = {}) { }, plugins: [ - function loaderFailHandler() { + function LoaderFailHandlerPlugin() { // bails on error, including loader errors // see https://github.com/webpack/webpack/issues/708, which does not fix loader errors - this.plugin('done', function(stats) { + this.hooks.done.tapPromise('LoaderFailHandlerPlugin', async stats => { if (!stats.hasErrors()) return; const errorMessage = stats.toString('errors-only'); if (watch) console.error(errorMessage); diff --git a/yarn.lock b/yarn.lock index 8e5f3900d122c..41d9c63024277 100644 --- a/yarn.lock +++ b/yarn.lock @@ -66,6 +66,17 @@ source-map "^0.5.0" trim-right "^1.0.1" +"@babel/generator@^7.1.3": + version "7.1.3" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.1.3.tgz#2103ec9c42d9bdad9190a6ad5ff2d456fd7b8673" + integrity sha512-ZoCZGcfIJFJuZBqxcY9OjC1KW2lWK64qrX1o4UYL3yshVhwKFYgzpWZ0vvtGMNJdTlvkw0W+HR1VnYN8q3QPFQ== + dependencies: + "@babel/types" "^7.1.3" + jsesc "^2.5.1" + lodash "^4.17.10" + source-map "^0.5.0" + trim-right "^1.0.1" + "@babel/helper-annotate-as-pure@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.0.0.tgz#323d39dd0b50e10c7c06ca7d7638e6864d8c5c32" @@ -252,6 +263,11 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.1.0.tgz#a7cd42cb3c12aec52e24375189a47b39759b783e" integrity sha512-SmjnXCuPAlai75AFtzv+KCBcJ3sDDWbIn+WytKw1k+wAtEy6phqI2RqKh/zAnw53i1NR8su3Ep/UoqaKcimuLg== +"@babel/parser@^7.1.3": + version "7.1.3" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.1.3.tgz#2c92469bac2b7fbff810b67fca07bd138b48af77" + integrity sha512-gqmspPZOMW3MIRb9HlrnbZHXI1/KHTOroBwN1NcLL6pWxzqzEKGvRTq0W/PxS45OtQGbaFikSQpkS5zbnsQm2w== + "@babel/plugin-proposal-async-generator-functions@^7.1.0": version "7.1.0" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.1.0.tgz#41c1a702e10081456e23a7b74d891922dd1bb6ce" @@ -708,6 +724,21 @@ globals "^11.1.0" lodash "^4.17.10" +"@babel/traverse@^7.1.4": + version "7.1.4" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.1.4.tgz#f4f83b93d649b4b2c91121a9087fa2fa949ec2b4" + integrity sha512-my9mdrAIGdDiSVBuMjpn/oXYpva0/EZwWL3sm3Wcy/AVWO2eXnsoZruOT9jOGNRXU8KbCIu5zsKnXcAJ6PcV6Q== + dependencies: + "@babel/code-frame" "^7.0.0" + "@babel/generator" "^7.1.3" + "@babel/helper-function-name" "^7.1.0" + "@babel/helper-split-export-declaration" "^7.0.0" + "@babel/parser" "^7.1.3" + "@babel/types" "^7.1.3" + debug "^3.1.0" + globals "^11.1.0" + lodash "^4.17.10" + "@babel/types@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.0.0.tgz#6e191793d3c854d19c6749989e3bc55f0e962118" @@ -717,6 +748,15 @@ lodash "^4.17.10" to-fast-properties "^2.0.0" +"@babel/types@^7.1.3": + version "7.1.3" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.1.3.tgz#3a767004567060c2f40fca49a304712c525ee37d" + integrity sha512-RpPOVfK+yatXyn8n4PB1NW6k9qjinrXrRR8ugBN8fD6hCy5RXI6PSbVqpOJBO9oSaY7Nom4ohj35feb0UR9hSA== + dependencies: + esutils "^2.0.2" + lodash "^4.17.10" + to-fast-properties "^2.0.0" + "@elastic/eui@0.0.23": version "0.0.23" resolved "https://registry.yarnpkg.com/@elastic/eui/-/eui-0.0.23.tgz#01a3d88aeaff175da5d42b70d407d08a32783f3d" @@ -739,6 +779,30 @@ tabbable "^1.1.0" uuid "^3.1.0" +"@elastic/eui@5.0.0": + version "5.0.0" + resolved "https://registry.yarnpkg.com/@elastic/eui/-/eui-5.0.0.tgz#e6fe9e1aa8b00c93045178f78a6dd0d457d56fa8" + integrity sha512-WL6sp6u2Rt1O7a2exLU/RuDcRnpluPN6aQ2JexBl+G6mVyF8F5I3RGJKTJp3jOozOaODRY2ev+Nq57EydkjrKg== + dependencies: + classnames "^2.2.5" + core-js "^2.5.1" + focus-trap-react "^3.0.4" + highlight.js "^9.12.0" + html "^1.0.0" + keymirror "^0.1.1" + lodash "npm:@elastic/lodash@3.10.1-kibana1" + numeral "^2.0.6" + prop-types "^15.6.0" + react-ace "^5.5.0" + react-color "^2.13.8" + react-datepicker v1.5.0 + react-input-autosize "^2.2.1" + react-virtualized "^9.18.5" + react-vis "1.10.2" + resize-observer-polyfill "^1.5.0" + tabbable "^1.1.0" + uuid "^3.1.0" + "@elastic/eui@5.3.0": version "5.3.0" resolved "https://registry.yarnpkg.com/@elastic/eui/-/eui-5.3.0.tgz#6a871b209c757141ebe88f5c77393652cb43c24d" @@ -898,10 +962,10 @@ dependencies: "@types/angular" "*" -"@types/angular@*", "@types/angular@^1.6.50": - version "1.6.51" - resolved "https://registry.yarnpkg.com/@types/angular/-/angular-1.6.51.tgz#a67515b0ba6a2ff68894a39405c1343cbf9c36d4" - integrity sha512-wYU+/zlJWih7ZmonWVjGQ18tG7GboI9asMNjRBM5fpIFJWXSioQttCTw9qGL44cP82ghM8sCV9apEqm1zBDq2w== +"@types/angular@*", "@types/angular@1.6.50": + version "1.6.50" + resolved "https://registry.yarnpkg.com/@types/angular/-/angular-1.6.50.tgz#8b6599088d80f68ef0cad7d3a2062248ebe72b3d" + integrity sha512-D3KB0PdaxdwtA44yOpK+NtptTscKWgUzXmf8fiLaaVxnX+b7QQ+dUMsyeVDweCQ6VX4PMwkd6x2hJ0X+ISIsoQ== "@types/async@2.0.49": version "2.0.49" @@ -1398,10 +1462,10 @@ dependencies: "@types/node" "*" -"@types/node@*", "@types/node@8.10.21", "@types/node@^8.10.20", "@types/node@^8.9.4", "@types/node@^9.4.6", "@types/node@^9.4.7": - version "8.10.21" - resolved "https://registry.yarnpkg.com/@types/node/-/node-8.10.21.tgz#12b3f2359b27aa05a45d886c8ba1eb8d1a77e285" - integrity sha512-87XkD9qDXm8fIax+5y7drx84cXsu34ZZqfB7Cial3Q/2lxSoJ/+DRaWckkCbxP41wFSIrrb939VhzaNxj4eY1w== +"@types/node@*", "@types/node@8.10.38", "@types/node@^8.10.38", "@types/node@^9.4.6", "@types/node@^9.4.7": + version "8.10.38" + resolved "https://registry.yarnpkg.com/@types/node/-/node-8.10.38.tgz#e05c201a668492e534b48102aca0294898f449f6" + integrity sha512-EibsnbJerd0hBFaDjJStFrVbVBAtOy4dgL8zZFw0uOvPqzBAX59Ci8cgjg3+RgJIWhsB5A4c+pi+D4P9tQQh/A== "@types/normalize-package-data@*": version "2.4.0" @@ -1669,6 +1733,159 @@ resolved "https://registry.yarnpkg.com/@types/zen-observable/-/zen-observable-0.8.0.tgz#8b63ab7f1aa5321248aad5ac890a485656dcea4d" integrity sha512-te5lMAWii1uEJ4FwLjzdlbw3+n0FZNOvFXHxQDKeT0dilh7HOzdMzV2TrJVUzq8ep7J4Na8OUYPRLSQkJHAlrg== +"@webassemblyjs/ast@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.7.10.tgz#0cfc61d61286240b72fc522cb755613699eea40a" + integrity sha512-wTUeaByYN2EA6qVqhbgavtGc7fLTOx0glG2IBsFlrFG51uXIGlYBTyIZMf4SPLo3v1bgV/7lBN3l7Z0R6Hswew== + dependencies: + "@webassemblyjs/helper-module-context" "1.7.10" + "@webassemblyjs/helper-wasm-bytecode" "1.7.10" + "@webassemblyjs/wast-parser" "1.7.10" + +"@webassemblyjs/floating-point-hex-parser@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.7.10.tgz#ee63d729c6311a85863e369a473f9983f984e4d9" + integrity sha512-gMsGbI6I3p/P1xL2UxqhNh1ga2HCsx5VBB2i5VvJFAaqAjd2PBTRULc3BpTydabUQEGlaZCzEUQhLoLG7TvEYQ== + +"@webassemblyjs/helper-api-error@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-api-error/-/helper-api-error-1.7.10.tgz#bfcb3bbe59775357475790a2ad7b289f09b2f198" + integrity sha512-DoYRlPWtuw3yd5BOr9XhtrmB6X1enYF0/54yNvQWGXZEPDF5PJVNI7zQ7gkcKfTESzp8bIBWailaFXEK/jjCsw== + +"@webassemblyjs/helper-buffer@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-buffer/-/helper-buffer-1.7.10.tgz#0a8c624c67ad0b214d2e003859921a1988cb151b" + integrity sha512-+RMU3dt/dPh4EpVX4u5jxsOlw22tp3zjqE0m3ftU2tsYxnPULb4cyHlgaNd2KoWuwasCQqn8Mhr+TTdbtj3LlA== + +"@webassemblyjs/helper-code-frame@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-code-frame/-/helper-code-frame-1.7.10.tgz#0ab7e22fad0241a173178c73976fc0edf50832ce" + integrity sha512-UiytbpKAULOEab2hUZK2ywXen4gWJVrgxtwY3Kn+eZaaSWaRM8z/7dAXRSoamhKFiBh1uaqxzE/XD9BLlug3gw== + dependencies: + "@webassemblyjs/wast-printer" "1.7.10" + +"@webassemblyjs/helper-fsm@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-fsm/-/helper-fsm-1.7.10.tgz#0915e7713fbbb735620a9d3e4fa3d7951f97ac64" + integrity sha512-w2vDtUK9xeSRtt5+RnnlRCI7wHEvLjF0XdnxJpgx+LJOvklTZPqWkuy/NhwHSLP19sm9H8dWxKeReMR7sCkGZA== + +"@webassemblyjs/helper-module-context@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-module-context/-/helper-module-context-1.7.10.tgz#9beb83f72740f5ac8075313b5cac5e796510f755" + integrity sha512-yE5x/LzZ3XdPdREmJijxzfrf+BDRewvO0zl8kvORgSWmxpRrkqY39KZSq6TSgIWBxkK4SrzlS3BsMCv2s1FpsQ== + +"@webassemblyjs/helper-wasm-bytecode@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.7.10.tgz#797b1e734bbcfdea8399669cdc58308ef1c7ffc0" + integrity sha512-u5qy4SJ/OrxKxZqJ9N3qH4ZQgHaAzsopsYwLvoWJY6Q33r8PhT3VPyNMaJ7ZFoqzBnZlCcS/0f4Sp8WBxylXfg== + +"@webassemblyjs/helper-wasm-section@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.7.10.tgz#c0ea3703c615d7bc3e3507c3b7991c8767b2f20e" + integrity sha512-Ecvww6sCkcjatcyctUrn22neSJHLN/TTzolMGG/N7S9rpbsTZ8c6Bl98GpSpV77EvzNijiNRHBG0+JO99qKz6g== + dependencies: + "@webassemblyjs/ast" "1.7.10" + "@webassemblyjs/helper-buffer" "1.7.10" + "@webassemblyjs/helper-wasm-bytecode" "1.7.10" + "@webassemblyjs/wasm-gen" "1.7.10" + +"@webassemblyjs/ieee754@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/ieee754/-/ieee754-1.7.10.tgz#62c1728b7ef0f66ef8221e2966a0afd75db430df" + integrity sha512-HRcWcY+YWt4+s/CvQn+vnSPfRaD4KkuzQFt5MNaELXXHSjelHlSEA8ZcqT69q0GTIuLWZ6JaoKar4yWHVpZHsQ== + dependencies: + "@xtuc/ieee754" "^1.2.0" + +"@webassemblyjs/leb128@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/leb128/-/leb128-1.7.10.tgz#167e0bb4b06d7701585772a73fba9f4df85439f6" + integrity sha512-og8MciYlA8hvzCLR71hCuZKPbVBfLQeHv7ImKZ4nlyxrYbG7uJHYtHiHu6OV9SqrGuD03H/HtXC4Bgdjfm9FHw== + dependencies: + "@xtuc/long" "4.2.1" + +"@webassemblyjs/utf8@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/utf8/-/utf8-1.7.10.tgz#b6728f5b6f50364abc155be029f9670e6685605a" + integrity sha512-Ng6Pxv6siyZp635xCSnH3mKmIFgqWPCcGdoo0GBYgyGdxu7cUj4agV7Uu1a8REP66UYUFXJLudeGgd4RvuJAnQ== + +"@webassemblyjs/wasm-edit@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-edit/-/wasm-edit-1.7.10.tgz#83fe3140f5a58f5a30b914702be9f0e59a399092" + integrity sha512-e9RZFQlb+ZuYcKRcW9yl+mqX/Ycj9+3/+ppDI8nEE/NCY6FoK8f3dKBcfubYV/HZn44b+ND4hjh+4BYBt+sDnA== + dependencies: + "@webassemblyjs/ast" "1.7.10" + "@webassemblyjs/helper-buffer" "1.7.10" + "@webassemblyjs/helper-wasm-bytecode" "1.7.10" + "@webassemblyjs/helper-wasm-section" "1.7.10" + "@webassemblyjs/wasm-gen" "1.7.10" + "@webassemblyjs/wasm-opt" "1.7.10" + "@webassemblyjs/wasm-parser" "1.7.10" + "@webassemblyjs/wast-printer" "1.7.10" + +"@webassemblyjs/wasm-gen@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-gen/-/wasm-gen-1.7.10.tgz#4de003806ae29c97ab3707782469b53299570174" + integrity sha512-M0lb6cO2Y0PzDye/L39PqwV+jvO+2YxEG5ax+7dgq7EwXdAlpOMx1jxyXJTScQoeTpzOPIb+fLgX/IkLF8h2yw== + dependencies: + "@webassemblyjs/ast" "1.7.10" + "@webassemblyjs/helper-wasm-bytecode" "1.7.10" + "@webassemblyjs/ieee754" "1.7.10" + "@webassemblyjs/leb128" "1.7.10" + "@webassemblyjs/utf8" "1.7.10" + +"@webassemblyjs/wasm-opt@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-opt/-/wasm-opt-1.7.10.tgz#d151e31611934a556c82789fdeec41a814993c2a" + integrity sha512-R66IHGCdicgF5ZliN10yn5HaC7vwYAqrSVJGjtJJQp5+QNPBye6heWdVH/at40uh0uoaDN/UVUfXK0gvuUqtVg== + dependencies: + "@webassemblyjs/ast" "1.7.10" + "@webassemblyjs/helper-buffer" "1.7.10" + "@webassemblyjs/wasm-gen" "1.7.10" + "@webassemblyjs/wasm-parser" "1.7.10" + +"@webassemblyjs/wasm-parser@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-parser/-/wasm-parser-1.7.10.tgz#0367be7bf8f09e3e6abc95f8e483b9206487ec65" + integrity sha512-AEv8mkXVK63n/iDR3T693EzoGPnNAwKwT3iHmKJNBrrALAhhEjuPzo/lTE4U7LquEwyvg5nneSNdTdgrBaGJcA== + dependencies: + "@webassemblyjs/ast" "1.7.10" + "@webassemblyjs/helper-api-error" "1.7.10" + "@webassemblyjs/helper-wasm-bytecode" "1.7.10" + "@webassemblyjs/ieee754" "1.7.10" + "@webassemblyjs/leb128" "1.7.10" + "@webassemblyjs/utf8" "1.7.10" + +"@webassemblyjs/wast-parser@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-parser/-/wast-parser-1.7.10.tgz#058f598b52f730b23fc874d4775b6286b6247264" + integrity sha512-YTPEtOBljkCL0VjDp4sHe22dAYSm3ZwdJ9+2NTGdtC7ayNvuip1wAhaAS8Zt9Q6SW9E5Jf5PX7YE3XWlrzR9cw== + dependencies: + "@webassemblyjs/ast" "1.7.10" + "@webassemblyjs/floating-point-hex-parser" "1.7.10" + "@webassemblyjs/helper-api-error" "1.7.10" + "@webassemblyjs/helper-code-frame" "1.7.10" + "@webassemblyjs/helper-fsm" "1.7.10" + "@xtuc/long" "4.2.1" + +"@webassemblyjs/wast-printer@1.7.10": + version "1.7.10" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-printer/-/wast-printer-1.7.10.tgz#d817909d2450ae96c66b7607624d98a33b84223b" + integrity sha512-mJ3QKWtCchL1vhU/kZlJnLPuQZnlDOdZsyP0bbLWPGdYsQDnSBvyTLhzwBA3QAMlzEL9V4JHygEmK6/OTEyytA== + dependencies: + "@webassemblyjs/ast" "1.7.10" + "@webassemblyjs/wast-parser" "1.7.10" + "@xtuc/long" "4.2.1" + +"@xtuc/ieee754@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@xtuc/ieee754/-/ieee754-1.2.0.tgz#eef014a3145ae477a1cbc00cd1e552336dceb790" + integrity sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA== + +"@xtuc/long@4.2.1": + version "4.2.1" + resolved "https://registry.yarnpkg.com/@xtuc/long/-/long-4.2.1.tgz#5c85d662f76fa1d34575766c5dcd6615abcd30d8" + integrity sha512-FZdkNBDqBRHKQ2MEbSC17xnPFOhZxeJ2YGSfr2BKf3sujG49Qe3bB+rGCwQfIaA7WHnGeGkSijX4FuBCdrzW/g== + "@zeit/check-updates@1.1.0": version "1.1.0" resolved "https://registry.yarnpkg.com/@zeit/check-updates/-/check-updates-1.1.0.tgz#d0f65026a36f27cd1fd54c647d8294447c1d2d8b" @@ -1678,14 +1895,6 @@ ms "2.1.1" update-notifier "2.3.0" -JSONStream@1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/JSONStream/-/JSONStream-1.1.1.tgz#c98bfd88c8f1e1e8694e53c5baa6c8691553e59a" - integrity sha1-yYv9iMjx4ehpTlPFuqbIaRVT5Zo= - dependencies: - jsonparse "^1.1.0" - through ">=2.2.7 <3" - abab@^1.0.3, abab@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/abab/-/abab-1.0.4.tgz#5faad9c2c07f60dd76770f71cf025b62a63cfd4e" @@ -1727,7 +1936,7 @@ accepts@1.3.3: mime-types "~2.1.11" negotiator "0.6.1" -accepts@~1.3.4: +accepts@~1.3.4, accepts@~1.3.5: version "1.3.5" resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.5.tgz#eb777df6011723a3b14e8a72c0805c8e86746bd2" integrity sha1-63d99gEXI6OxTopywIBcjoZ0a9I= @@ -1735,12 +1944,12 @@ accepts@~1.3.4: mime-types "~2.1.18" negotiator "0.6.1" -acorn-dynamic-import@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/acorn-dynamic-import/-/acorn-dynamic-import-2.0.2.tgz#c752bd210bef679501b6c6cb7fc84f8f47158cc4" - integrity sha1-x1K9IQvvZ5UBtsbLf8hPj0cVjMQ= +acorn-dynamic-import@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/acorn-dynamic-import/-/acorn-dynamic-import-3.0.0.tgz#901ceee4c7faaef7e07ad2a47e890675da50a278" + integrity sha512-zVWV8Z8lislJoOKKqdNMOB+s6+XV5WERty8MnKBeFgwA+19XJjJHs2RP5dzM57FftIs+jQnRToLiWazKr6sSWg== dependencies: - acorn "^4.0.3" + acorn "^5.0.0" acorn-globals@^3.0.0: version "3.1.0" @@ -1776,7 +1985,7 @@ acorn-walk@^6.0.1: resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-6.0.1.tgz#c7827bdbb8e21aa97b609adfa225400d9ae348ba" integrity sha512-PqVQ8c6a3kyqdsUZlC7nljp3FFuxipBRHKu+7C1h8QygBFlzTaDX5HD383jej3Peed+1aDG8HwkfB1Z1HMNPkw== -acorn@4.X, acorn@^4.0.3, acorn@^4.0.4, acorn@~4.0.2: +acorn@4.X, acorn@^4.0.4, acorn@~4.0.2: version "4.0.13" resolved "https://registry.yarnpkg.com/acorn/-/acorn-4.0.13.tgz#105495ae5361d697bd195c825192e1ad7f253787" integrity sha1-EFSVrlNh1pe9GVyCUZLhrX8lN4c= @@ -1791,7 +2000,7 @@ acorn@^5.0.0, acorn@^5.1.2: resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.3.0.tgz#7446d39459c54fb49a80e6ee6478149b940ec822" integrity sha512-Yej+zOJ1Dm/IMZzzj78OntP/r3zHEaKcyNoU2lAaxPtrseM6rF0xwqoz5Q5ysAiED9hTjI2hgtvLXitlCN1/Ug== -acorn@^5.0.3, acorn@^5.6.0, acorn@^5.7.1: +acorn@^5.0.3, acorn@^5.6.0, acorn@^5.6.2, acorn@^5.7.1: version "5.7.3" resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279" integrity sha512-T/zvzYRfbVojPWahDsE5evJdHb3oJoQfFbsrKM7w5Zcs++Tr257tia3BmMP8XYVjp1S9RZXQMh7gao96BlqZOw== @@ -1845,10 +2054,10 @@ aggregate-error@^1.0.0: clean-stack "^1.0.0" indent-string "^3.0.0" -ajv-keywords@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" - integrity sha1-YXmX/F9gV2iUxDX5QNgZ4TW4B2I= +ajv-errors@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/ajv-errors/-/ajv-errors-1.0.0.tgz#ecf021fa108fd17dfb5e6b383f2dd233e31ffc59" + integrity sha1-7PAh+hCP0X37Xms4Py3SM+Mf/Fk= ajv-keywords@^3.0.0: version "3.1.0" @@ -1868,7 +2077,7 @@ ajv@^4.9.1: co "^4.6.0" json-stable-stringify "^1.0.1" -ajv@^5.0.0, ajv@^5.1.0, ajv@^5.1.5, ajv@^5.3.0: +ajv@^5.0.0, ajv@^5.1.0, ajv@^5.3.0: version "5.5.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" integrity sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU= @@ -1906,11 +2115,6 @@ align-text@^0.1.1, align-text@^0.1.3: longest "^1.0.1" repeat-string "^1.5.2" -alphanum-sort@^1.0.1, alphanum-sort@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/alphanum-sort/-/alphanum-sort-1.0.2.tgz#97a1119649b211ad33691d9f9f486a8ec9fbe0a3" - integrity sha1-l6ERlkmyEa0zaR2fn0hqjsn74KM= - amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" @@ -1994,6 +2198,11 @@ ansi-colors@^1.0.1: dependencies: ansi-wrap "^0.1.0" +ansi-colors@^3.0.0: + version "3.2.1" + resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-3.2.1.tgz#9638047e4213f3428a11944a7d4b31cba0a3ff95" + integrity sha512-Xt+zb6nqgvV9SWAVp0EG3lRsHcbq5DDgqjPPz6pwgtj6RKz65zGXMNa82oJfOSBA/to6GmRP7Dr+6o+kbApTzQ== + ansi-colors@^3.0.5: version "3.0.5" resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-3.0.5.tgz#cb9dc64993b64fd6945485f797fc3853137d9a7b" @@ -2669,7 +2878,7 @@ async@2.4.0: dependencies: lodash "^4.14.0" -async@^2.0.0, async@^2.1.2, async@^2.1.4, async@^2.1.5, async@^2.3.0, async@^2.4.1: +async@^2.0.0, async@^2.1.4: version "2.6.0" resolved "https://registry.yarnpkg.com/async/-/async-2.6.0.tgz#61a29abb6fcc026fea77e56d1c6ec53a795951f4" integrity sha512-xAfGg1/NTLBBKlHFmnd7PlmUW9KhVQIUuSrYem9xzFUZy13ScvtyGGejaae9iAVRiRq9+Cx7DPFaAAhCpyxyPw== @@ -2747,18 +2956,6 @@ autoprefixer@6.5.4: postcss "^5.2.6" postcss-value-parser "^3.2.3" -autoprefixer@^6.3.1: - version "6.7.7" - resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-6.7.7.tgz#1dbd1c835658e35ce3f9984099db00585c782014" - integrity sha1-Hb0cg1ZY41zj+ZhAmdsAWFx4IBQ= - dependencies: - browserslist "^1.7.6" - caniuse-db "^1.0.30000634" - normalize-range "^0.1.2" - num2fraction "^1.2.2" - postcss "^5.2.16" - postcss-value-parser "^3.2.3" - autoprefixer@^9.1.0: version "9.1.0" resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-9.1.0.tgz#566a70d1148046b96b31efa08090f1999ffb6d8c" @@ -2790,16 +2987,16 @@ aws-sign2@~0.7.0: resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= -aws4@^1.2.1, aws4@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e" - integrity sha1-g+9cqGCysy5KDe7e6MdxudtXRx4= - -aws4@^1.8.0: +aws4@^1.2.1, aws4@^1.8.0: version "1.8.0" resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz#f0e003d9ca9e7f59c7a508945d7b2ef9a04a542f" integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ== +aws4@^1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e" + integrity sha1-g+9cqGCysy5KDe7e6MdxudtXRx4= + axios@^0.18.0: version "0.18.0" resolved "https://registry.yarnpkg.com/axios/-/axios-0.18.0.tgz#32d53e4851efdc0a11993b6cd000789d70c05102" @@ -2842,7 +3039,7 @@ babel-cli@^6.26.0: optionalDependencies: chokidar "^1.6.1" -babel-code-frame@^6.11.0, babel-code-frame@^6.20.0, babel-code-frame@^6.22.0, babel-code-frame@^6.26.0: +babel-code-frame@^6.22.0, babel-code-frame@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" integrity sha1-Y/1D99weO7fONZR9uP42mj9Yx0s= @@ -2851,32 +3048,32 @@ babel-code-frame@^6.11.0, babel-code-frame@^6.20.0, babel-code-frame@^6.22.0, ba esutils "^2.0.2" js-tokens "^3.0.2" -babel-core@6.21.0: - version "6.21.0" - resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.21.0.tgz#75525480c21c803f826ef3867d22c19f080a3724" - integrity sha1-dVJUgMIcgD+CbvOGfSLBnwgKNyQ= +babel-core@6.26.3, babel-core@^6.26.3: + version "6.26.3" + resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.3.tgz#b2e2f09e342d0f0c88e2f02e067794125e75c207" + integrity sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA== dependencies: - babel-code-frame "^6.20.0" - babel-generator "^6.21.0" - babel-helpers "^6.16.0" - babel-messages "^6.8.0" - babel-register "^6.18.0" - babel-runtime "^6.20.0" - babel-template "^6.16.0" - babel-traverse "^6.21.0" - babel-types "^6.21.0" - babylon "^6.11.0" - convert-source-map "^1.1.0" - debug "^2.1.1" - json5 "^0.5.0" - lodash "^4.2.0" - minimatch "^3.0.2" - path-is-absolute "^1.0.0" - private "^0.1.6" + babel-code-frame "^6.26.0" + babel-generator "^6.26.0" + babel-helpers "^6.24.1" + babel-messages "^6.23.0" + babel-register "^6.26.0" + babel-runtime "^6.26.0" + babel-template "^6.26.0" + babel-traverse "^6.26.0" + babel-types "^6.26.0" + babylon "^6.18.0" + convert-source-map "^1.5.1" + debug "^2.6.9" + json5 "^0.5.1" + lodash "^4.17.4" + minimatch "^3.0.4" + path-is-absolute "^1.0.1" + private "^0.1.8" slash "^1.0.0" - source-map "^0.5.0" + source-map "^0.5.7" -babel-core@^6.0.0, babel-core@^6.18.0, babel-core@^6.26.0: +babel-core@^6.0.0, babel-core@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.0.tgz#af32f78b31a6fcef119c87b0fd8d9753f03a0bb8" integrity sha1-rzL3izGm/O8RnIew/Y2XU/A6C7g= @@ -2913,7 +3110,7 @@ babel-eslint@^9.0.0: eslint-scope "3.7.1" eslint-visitor-keys "^1.0.0" -babel-generator@^6.18.0, babel-generator@^6.21.0: +babel-generator@^6.18.0: version "6.26.1" resolved "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.1.tgz#1844408d3b8f0d35a404ea7ac180f087a601bd90" integrity sha512-HyfwY6ApZj7BYTcJURpM5tznulaBvyio7/0d4zFOeMPUmfxkCjHocCuoLa2SAGzBI8AREcH3eP3758F672DppA== @@ -3055,7 +3252,7 @@ babel-helper-replace-supers@^6.24.1: babel-traverse "^6.24.1" babel-types "^6.24.1" -babel-helpers@^6.16.0, babel-helpers@^6.24.1: +babel-helpers@^6.24.1: version "6.24.1" resolved "https://registry.yarnpkg.com/babel-helpers/-/babel-helpers-6.24.1.tgz#3471de9caec388e5c850e597e58a26ddf37602b2" integrity sha1-NHHenK7DiOXIUOWX5Yom3fN2ArI= @@ -3079,16 +3276,16 @@ babel-jest@^23.6.0: babel-plugin-istanbul "^4.1.6" babel-preset-jest "^23.2.0" -babel-loader@7.1.2, babel-loader@^7.1.2: - version "7.1.2" - resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-7.1.2.tgz#f6cbe122710f1aa2af4d881c6d5b54358ca24126" - integrity sha512-jRwlFbINAeyDStqK6Dd5YuY0k5YuzQUvlz2ZamuXrXmxav3pNqe9vfJ402+2G+OmlJSXxCOpB6Uz0INM7RQe2A== +babel-loader@7.1.5, babel-loader@^7.1.5: + version "7.1.5" + resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-7.1.5.tgz#e3ee0cd7394aa557e013b02d3e492bfd07aa6d68" + integrity sha512-iCHfbieL5d1LfOQeeVJEUyD9rTwBcP/fcEbRCfempxTDuqrKpu0AZjLAQHEQa3Yqyj9ORKe2iHfoj4rHLf7xpw== dependencies: find-cache-dir "^1.0.0" loader-utils "^1.0.2" mkdirp "^0.5.1" -babel-messages@^6.23.0, babel-messages@^6.8.0: +babel-messages@^6.23.0: version "6.23.0" resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz#f3cdf4703858035b2a2951c6ec5edf6c62f2630e" integrity sha1-8830cDhYA1sqKVHG7F7fbGLyYw4= @@ -3498,7 +3695,7 @@ babel-polyfill@6.20.0: core-js "^2.4.0" regenerator-runtime "^0.10.0" -babel-polyfill@^6.26.0: +babel-polyfill@6.26.0, babel-polyfill@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-polyfill/-/babel-polyfill-6.26.0.tgz#379937abc67d7895970adc621f284cd966cf2153" integrity sha1-N5k3q8Z9eJWXCtxiHyhM2WbPIVM= @@ -3507,45 +3704,10 @@ babel-polyfill@^6.26.0: core-js "^2.5.0" regenerator-runtime "^0.10.5" -babel-preset-env@1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/babel-preset-env/-/babel-preset-env-1.4.0.tgz#c8e02a3bcc7792f23cded68e0355b9d4c28f0f7a" - integrity sha1-yOAqO8x3kvI83taOA1W51MKPD3o= - dependencies: - babel-plugin-check-es2015-constants "^6.22.0" - babel-plugin-syntax-trailing-function-commas "^6.22.0" - babel-plugin-transform-async-to-generator "^6.22.0" - babel-plugin-transform-es2015-arrow-functions "^6.22.0" - babel-plugin-transform-es2015-block-scoped-functions "^6.22.0" - babel-plugin-transform-es2015-block-scoping "^6.23.0" - babel-plugin-transform-es2015-classes "^6.23.0" - babel-plugin-transform-es2015-computed-properties "^6.22.0" - babel-plugin-transform-es2015-destructuring "^6.23.0" - babel-plugin-transform-es2015-duplicate-keys "^6.22.0" - babel-plugin-transform-es2015-for-of "^6.23.0" - babel-plugin-transform-es2015-function-name "^6.22.0" - babel-plugin-transform-es2015-literals "^6.22.0" - babel-plugin-transform-es2015-modules-amd "^6.22.0" - babel-plugin-transform-es2015-modules-commonjs "^6.23.0" - babel-plugin-transform-es2015-modules-systemjs "^6.23.0" - babel-plugin-transform-es2015-modules-umd "^6.23.0" - babel-plugin-transform-es2015-object-super "^6.22.0" - babel-plugin-transform-es2015-parameters "^6.23.0" - babel-plugin-transform-es2015-shorthand-properties "^6.22.0" - babel-plugin-transform-es2015-spread "^6.22.0" - babel-plugin-transform-es2015-sticky-regex "^6.22.0" - babel-plugin-transform-es2015-template-literals "^6.22.0" - babel-plugin-transform-es2015-typeof-symbol "^6.23.0" - babel-plugin-transform-es2015-unicode-regex "^6.22.0" - babel-plugin-transform-exponentiation-operator "^6.22.0" - babel-plugin-transform-regenerator "^6.22.0" - browserslist "^1.4.0" - invariant "^2.2.2" - -babel-preset-env@^1.6.1: - version "1.6.1" - resolved "https://registry.yarnpkg.com/babel-preset-env/-/babel-preset-env-1.6.1.tgz#a18b564cc9b9afdf4aae57ae3c1b0d99188e6f48" - integrity sha512-W6VIyA6Ch9ePMI7VptNn2wBM6dbG0eSz25HEiL40nQXCsXGTGZSTZu1Iap+cj3Q0S5a7T9+529l/5Bkvd+afNA== +babel-preset-env@^1.7.0: + version "1.7.0" + resolved "https://registry.yarnpkg.com/babel-preset-env/-/babel-preset-env-1.7.0.tgz#dea79fa4ebeb883cd35dab07e260c1c9c04df77a" + integrity sha512-9OR2afuKDneX2/q2EurSftUYM0xGu4O2D9adAhVfADDhrYDaxXV0rBbevVYoY9n6nyX1PmQW/0jtpJvUNr9CHg== dependencies: babel-plugin-check-es2015-constants "^6.22.0" babel-plugin-syntax-trailing-function-commas "^6.22.0" @@ -3574,7 +3736,7 @@ babel-preset-env@^1.6.1: babel-plugin-transform-es2015-unicode-regex "^6.22.0" babel-plugin-transform-exponentiation-operator "^6.22.0" babel-plugin-transform-regenerator "^6.22.0" - browserslist "^2.1.2" + browserslist "^3.2.6" invariant "^2.2.2" semver "^5.3.0" @@ -3646,20 +3808,7 @@ babel-preset-stage-3@^6.24.1: babel-plugin-transform-exponentiation-operator "^6.24.1" babel-plugin-transform-object-rest-spread "^6.22.0" -babel-register@6.18.0: - version "6.18.0" - resolved "https://registry.yarnpkg.com/babel-register/-/babel-register-6.18.0.tgz#892e2e03865078dd90ad2c715111ec4449b32a68" - integrity sha1-iS4uA4ZQeN2QrSxxURHsREmzKmg= - dependencies: - babel-core "^6.18.0" - babel-runtime "^6.11.6" - core-js "^2.4.0" - home-or-tmp "^2.0.0" - lodash "^4.2.0" - mkdirp "^0.5.1" - source-map-support "^0.4.2" - -babel-register@^6.18.0, babel-register@^6.26.0: +babel-register@6.26.0, babel-register@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-register/-/babel-register-6.26.0.tgz#6ed021173e2fcb486d7acb45c6009a856f647071" integrity sha1-btAhFz4vy0htestFxgCahW9kcHE= @@ -3691,7 +3840,7 @@ babel-template@^6.16.0, babel-template@^6.24.1, babel-template@^6.26.0: babylon "^6.18.0" lodash "^4.17.4" -babel-traverse@^6.0.0, babel-traverse@^6.18.0, babel-traverse@^6.21.0, babel-traverse@^6.24.1, babel-traverse@^6.26.0: +babel-traverse@^6.0.0, babel-traverse@^6.18.0, babel-traverse@^6.24.1, babel-traverse@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-6.26.0.tgz#46a9cbd7edcc62c8e5c064e2d2d8d0f4035766ee" integrity sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4= @@ -3715,7 +3864,7 @@ babel-types@7.0.0-beta.3: lodash "^4.2.0" to-fast-properties "^2.0.0" -babel-types@^6.0.0, babel-types@^6.18.0, babel-types@^6.19.0, babel-types@^6.21.0, babel-types@^6.24.1, babel-types@^6.26.0: +babel-types@^6.0.0, babel-types@^6.18.0, babel-types@^6.19.0, babel-types@^6.24.1, babel-types@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-types/-/babel-types-6.26.0.tgz#a3b073f94ab49eb6fa55cd65227a334380632497" integrity sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc= @@ -3730,7 +3879,7 @@ babylon@7.0.0-beta.47: resolved "https://registry.yarnpkg.com/babylon/-/babylon-7.0.0-beta.47.tgz#6d1fa44f0abec41ab7c780481e62fd9aafbdea80" integrity sha512-+rq2cr4GDhtToEzKFD6KZZMDBXhjFAr9JjPw9pAppZACeEWqNM294j+NdBzkSHYXwzzBmVjZ3nEVJlOhbR2gOQ== -babylon@^6.11.0, babylon@^6.18.0: +babylon@^6.18.0: version "6.18.0" resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz#af2f3b88fa6f5c1e4c634d1a0f8eac4f55b395e3" integrity sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ== @@ -3765,11 +3914,6 @@ bail@^1.0.0: resolved "https://registry.yarnpkg.com/bail/-/bail-1.0.2.tgz#f7d6c1731630a9f9f0d4d35ed1f962e2074a1764" integrity sha1-99bBcxYwqfnw1NNe0fli4gdKF2Q= -balanced-match@^0.4.2: - version "0.4.2" - resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-0.4.2.tgz#cb3f3e3c732dc0f01ee70b403f302e61d7709838" - integrity sha1-yz8+PHMtwPAe5wtAPzAuYddwmDg= - balanced-match@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" @@ -3960,7 +4104,23 @@ bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.1.1, bn.js@^4.4.0: resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.8.tgz#2cde09eb5ee341f484746bb0309b3253b1b1442f" integrity sha512-ItfYfPLkWHUjckQCk8xC+LwxgK8NYcXywGigJgSwOP8Y2iyWT4f2vsZnoOXTTbo+o5yXmIUJ4gn5538SO5S3gA== -body-parser@1.18.2, body-parser@^1.16.1: +body-parser@1.18.3: + version "1.18.3" + resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.18.3.tgz#5b292198ffdd553b3a0f20ded0592b956955c8b4" + integrity sha1-WykhmP/dVTs6DyDe0FkrlWlVyLQ= + dependencies: + bytes "3.0.0" + content-type "~1.0.4" + debug "2.6.9" + depd "~1.1.2" + http-errors "~1.6.3" + iconv-lite "0.4.23" + on-finished "~2.3.0" + qs "6.5.2" + raw-body "2.3.3" + type-is "~1.6.16" + +body-parser@^1.16.1: version "1.18.2" resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.18.2.tgz#87678a19d84b47d859b83199bd59bce222b10454" integrity sha1-h2eKGdhLR9hZuDGZvVm84iKxBFQ= @@ -4243,21 +4403,13 @@ browserify-zlib@^0.2.0: dependencies: pako "~1.0.5" -browserslist@^1.3.6, browserslist@^1.4.0, browserslist@^1.5.2, browserslist@^1.7.6: - version "1.7.7" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-1.7.7.tgz#0bd76704258be829b2398bb50e4b62d1a166b0b9" - integrity sha1-C9dnBCWL6CmyOYu1Dkti0aFmsLk= - dependencies: - caniuse-db "^1.0.30000639" - electron-to-chromium "^1.2.7" - -browserslist@^2.1.2: - version "2.11.3" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-2.11.3.tgz#fe36167aed1bbcde4827ebfe71347a2cc70b99b2" - integrity sha512-yWu5cXT7Av6mVwzWc8lMsJMHWn4xyjSuGYi4IozbVTLUOEYPSagUB8kiMDUHA1fS3zjr8nkxkn9jdvug4BBRmA== +browserslist@^3.2.6: + version "3.2.8" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-3.2.8.tgz#b0005361d6471f0f5952797a76fc985f1f978fc6" + integrity sha512-WHVocJYavUwVgVViC0ORikPHQquXwVh939TaelZ4WDqpWgTX/FsGhl/+P4qBUAGcRvtOgDgC+xftNWWp2RUTAQ== dependencies: - caniuse-lite "^1.0.30000792" - electron-to-chromium "^1.3.30" + caniuse-lite "^1.0.30000844" + electron-to-chromium "^1.3.47" browserslist@^4.0.1: version "4.0.1" @@ -4481,14 +4633,15 @@ cache-base@^1.0.1: union-value "^1.0.0" unset-value "^1.0.0" -cache-loader@1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/cache-loader/-/cache-loader-1.0.3.tgz#7717963ec082db068b17a1412deaaa72d21c4e30" - integrity sha1-dxeWPsCC2waLF6FBLeqqctIcTjA= +cache-loader@1.2.2: + version "1.2.2" + resolved "https://registry.yarnpkg.com/cache-loader/-/cache-loader-1.2.2.tgz#6d5c38ded959a09cc5d58190ab5af6f73bd353f5" + integrity sha512-rsGh4SIYyB9glU+d0OcHwiXHXBoUgDhHZaQ1KAbiXqfz1CDPxtTboh1gPbJ0q2qdO8a9lfcjgC5CJ2Ms32y5bw== dependencies: - async "^2.3.0" loader-utils "^1.1.0" mkdirp "^0.5.1" + neo-async "^2.5.0" + schema-utils "^0.4.2" cacheable-request@^2.1.1: version "2.1.4" @@ -4596,25 +4749,15 @@ camelcase@^5.0.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.0.0.tgz#03295527d58bd3cd4aa75363f35b2e8d97be2f42" integrity sha512-faqwZqnWxbxn+F1d399ygeamQNy3lPp/H9H6rNrqYh4FSVCtcY+3cub1MxA8o9mDd55mM8Aghuu/kuyYA6VTsA== -caniuse-api@^1.5.2: - version "1.6.1" - resolved "https://registry.yarnpkg.com/caniuse-api/-/caniuse-api-1.6.1.tgz#b534e7c734c4f81ec5fbe8aca2ad24354b962c6c" - integrity sha1-tTTnxzTE+B7F++isoq0kNUuWLGw= - dependencies: - browserslist "^1.3.6" - caniuse-db "^1.0.30000529" - lodash.memoize "^4.1.2" - lodash.uniq "^4.5.0" - -caniuse-db@^1.0.30000529, caniuse-db@^1.0.30000539, caniuse-db@^1.0.30000597, caniuse-db@^1.0.30000634, caniuse-db@^1.0.30000639: +caniuse-db@^1.0.30000539, caniuse-db@^1.0.30000597: version "1.0.30000813" resolved "https://registry.yarnpkg.com/caniuse-db/-/caniuse-db-1.0.30000813.tgz#e0a1c603f8880ad787b2a35652b2733f32a5e29a" integrity sha1-4KHGA/iICteHsqNWUrJzPzKl4po= -caniuse-lite@^1.0.30000792: - version "1.0.30000810" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000810.tgz#47585fffce0e9f3593a6feea4673b945424351d9" - integrity sha512-/0Q00Oie9C72P8zQHtFvzmkrMC3oOFUnMWjCy5F2+BE8lzICm91hQPhh0+XIsAFPKOe2Dh3pKgbRmU3EKxfldA== +caniuse-lite@^1.0.30000844: + version "1.0.30000899" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000899.tgz#6febdbbc388a7982f620ee0e3d09aab0c061389e" + integrity sha512-enC3zKfUCJxxwvUIsBkbHd54CtJw1KtIWvrK0JZxWD/fEN2knHaai45lndJ4xXAkyRAPyk60J3yagkKDWhfeMA== caniuse-lite@^1.0.30000865, caniuse-lite@^1.0.30000872: version "1.0.30000874" @@ -4631,11 +4774,6 @@ capture-stack-trace@^1.0.0: resolved "https://registry.yarnpkg.com/capture-stack-trace/-/capture-stack-trace-1.0.0.tgz#4a6fa07399c26bba47f0b2496b4d0fb408c5550d" integrity sha1-Sm+gc5nCa7pH8LJJa00PtAjFVQ0= -caseless@~0.11.0: - version "0.11.0" - resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.11.0.tgz#715b96ea9841593cc33067923f5ec60ebda4f7d7" - integrity sha1-cVuW6phBWTzDMGeSP17GDr2k99c= - caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" @@ -4881,7 +5019,7 @@ chokidar@1.6.0: optionalDependencies: fsevents "^1.0.0" -chokidar@^1.4.1, chokidar@^1.6.0, chokidar@^1.6.1: +chokidar@^1.4.1, chokidar@^1.6.1: version "1.7.0" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-1.7.0.tgz#798e689778151c8076b4b360e5edd28cda2bb468" integrity sha1-eY5ol3gVHIB2tLNg5e3SjNortGg= @@ -4897,10 +5035,10 @@ chokidar@^1.4.1, chokidar@^1.6.0, chokidar@^1.6.1: optionalDependencies: fsevents "^1.0.0" -chokidar@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.0.2.tgz#4dc65139eeb2714977735b6a35d06e97b494dfd7" - integrity sha512-l32Hw3wqB0L2kGVmSbK/a+xXLDrUEsc84pSgMkmwygHvD7ubRsP/vxxHa5BtB6oix1XLLVCHyYMsckRXxThmZw== +chokidar@^2.0.0, chokidar@^2.0.3: + version "2.0.4" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.0.4.tgz#356ff4e2b0e8e43e322d18a372460bbcf3accd26" + integrity sha512-z9n7yt9rOvIJrMhvDtDictKrkFHeihkNl6uWMmZlmL6tJtX9Cs+87oK+teBx+JIgzvbX3yZHT3eF8vpbDxHJXQ== dependencies: anymatch "^2.0.0" async-each "^1.0.0" @@ -4909,17 +5047,18 @@ chokidar@^2.0.2: inherits "^2.0.1" is-binary-path "^1.0.0" is-glob "^4.0.0" + lodash.debounce "^4.0.8" normalize-path "^2.1.1" path-is-absolute "^1.0.0" readdirp "^2.0.0" - upath "^1.0.0" + upath "^1.0.5" optionalDependencies: - fsevents "^1.0.0" + fsevents "^1.2.2" -chokidar@^2.0.3: - version "2.0.4" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.0.4.tgz#356ff4e2b0e8e43e322d18a372460bbcf3accd26" - integrity sha512-z9n7yt9rOvIJrMhvDtDictKrkFHeihkNl6uWMmZlmL6tJtX9Cs+87oK+teBx+JIgzvbX3yZHT3eF8vpbDxHJXQ== +chokidar@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.0.2.tgz#4dc65139eeb2714977735b6a35d06e97b494dfd7" + integrity sha512-l32Hw3wqB0L2kGVmSbK/a+xXLDrUEsc84pSgMkmwygHvD7ubRsP/vxxHa5BtB6oix1XLLVCHyYMsckRXxThmZw== dependencies: anymatch "^2.0.0" async-each "^1.0.0" @@ -4928,13 +5067,12 @@ chokidar@^2.0.3: inherits "^2.0.1" is-binary-path "^1.0.0" is-glob "^4.0.0" - lodash.debounce "^4.0.8" normalize-path "^2.1.1" path-is-absolute "^1.0.0" readdirp "^2.0.0" - upath "^1.0.5" + upath "^1.0.0" optionalDependencies: - fsevents "^1.2.2" + fsevents "^1.0.0" chownr@^1.0.1: version "1.0.1" @@ -4946,6 +5084,13 @@ chroma-js@^1.3.6: resolved "https://registry.yarnpkg.com/chroma-js/-/chroma-js-1.3.7.tgz#38db1b46c99b002b77aa5e6b6744589388f28425" integrity sha512-ARq0P94NObL8hdQbgc+E33X9OHiNzdHO7epe3nC/KgxNRxkQcFpzNqnGeFjvOY2GxfVhbia686NXD2jByb1o0g== +chrome-trace-event@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/chrome-trace-event/-/chrome-trace-event-1.0.0.tgz#45a91bd2c20c9411f0963b5aaeb9a1b95e09cc48" + integrity sha512-xDbVgyfDTT2piup/h8dK/y4QZfJRSa73bw1WZ8b4XM1o7fsFubUVGYcE+1ANtOzJJELGpYoG2961z0Z6OAld9A== + dependencies: + tslib "^1.9.0" + chromedriver@2.42.1: version "2.42.1" resolved "https://registry.yarnpkg.com/chromedriver/-/chromedriver-2.42.1.tgz#566964c1221fbd9fd1ce836734dd92735f1ff8fb" @@ -5010,7 +5155,14 @@ classnames@^2.2.3, classnames@^2.2.5: resolved "https://registry.yarnpkg.com/classnames/-/classnames-2.2.6.tgz#43935bffdd291f326dad0a205309b38d00f650ce" integrity sha512-JR/iSQOSt+LQIWwrwEzJ9uk0xfN3mTVYMwt1Ir5mUcSN6pU+V4zQFFaJsclJbPuAUQH+yfWef6tm7l1quW3C8Q== -clean-css@4.1.x, clean-css@^4.1.11: +clean-css@4.2.x: + version "4.2.1" + resolved "https://registry.yarnpkg.com/clean-css/-/clean-css-4.2.1.tgz#2d411ef76b8569b6d0c84068dabe85b0aa5e5c17" + integrity sha512-4ZxI6dy4lrY6FHzfiy1aEOXgu4LIsW2MhwG0VBKdcoGoH/XLFgaHSdLTGr4O8Be6A8r3MOphEiI8Gc1n0ecf3g== + dependencies: + source-map "~0.6.0" + +clean-css@^4.1.11: version "4.1.11" resolved "https://registry.yarnpkg.com/clean-css/-/clean-css-4.1.11.tgz#2ecdf145aba38f54740f26cefd0ff3e03e125d6a" integrity sha1-Ls3xRaujj1R0DybO/Q/z4D4SXWo= @@ -5135,16 +5287,6 @@ clone-buffer@^1.0.0: resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" integrity sha1-4+JbIHrE5wGvch4staFnksrD3Fg= -clone-deep@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/clone-deep/-/clone-deep-0.3.0.tgz#348c61ae9cdbe0edfe053d91ff4cc521d790ede8" - integrity sha1-NIxhrpzb4O3+BT2R/0zFIdeQ7eg= - dependencies: - for-own "^1.0.0" - is-plain-object "^2.0.1" - kind-of "^3.2.2" - shallow-clone "^0.1.2" - clone-deep@^2.0.1: version "2.0.2" resolved "https://registry.yarnpkg.com/clone-deep/-/clone-deep-2.0.2.tgz#00db3a1e173656730d1188c3d6aced6d7ea97713" @@ -5262,7 +5404,7 @@ collection-visit@^1.0.0: map-visit "^1.0.0" object-visit "^1.0.0" -color-convert@^1.3.0, color-convert@^1.8.2, color-convert@^1.9.0: +color-convert@^1.8.2, color-convert@^1.9.0: version "1.9.1" resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.1.tgz#c1261107aeb2f294ebffec9ed9ecad529a6097ed" integrity sha512-mjGanIiwQJskCC18rPR6OmrZ6fm2Lc7PeGFYwCmy5J34wC6F1PzdGL6xeMfmgicfYcNLGuVFA3WzXtIDCQSZxQ== @@ -5274,13 +5416,6 @@ color-name@^1.0.0, color-name@^1.1.1: resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= -color-string@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/color-string/-/color-string-0.3.0.tgz#27d46fb67025c5c2fa25993bfbf579e47841b991" - integrity sha1-J9RvtnAlxcL6JZk7+/V55HhBuZE= - dependencies: - color-name "^1.0.0" - color-string@^1.4.0: version "1.5.2" resolved "https://registry.yarnpkg.com/color-string/-/color-string-1.5.2.tgz#26e45814bc3c9a7cbd6751648a41434514a773a9" @@ -5302,24 +5437,6 @@ color@1.0.3: color-convert "^1.8.2" color-string "^1.4.0" -color@^0.11.0: - version "0.11.4" - resolved "https://registry.yarnpkg.com/color/-/color-0.11.4.tgz#6d7b5c74fb65e841cd48792ad1ed5e07b904d764" - integrity sha1-bXtcdPtl6EHNSHkq0e1eB7kE12Q= - dependencies: - clone "^1.0.2" - color-convert "^1.3.0" - color-string "^0.3.0" - -colormin@^1.0.5: - version "1.1.2" - resolved "https://registry.yarnpkg.com/colormin/-/colormin-1.1.2.tgz#ea2f7420a72b96881a38aae59ec124a6f7298133" - integrity sha1-6i90IKcrlogaOKrlnsEkpvcpgTM= - dependencies: - color "^0.11.0" - css-color-names "0.0.4" - has "^1.0.1" - colors@0.5.x: version "0.5.1" resolved "https://registry.yarnpkg.com/colors/-/colors-0.5.1.tgz#7d0023eaeb154e8ee9fce75dcb923d0ed1667774" @@ -5381,16 +5498,16 @@ commander@2.12.2, commander@^2.9.0: resolved "https://registry.yarnpkg.com/commander/-/commander-2.12.2.tgz#0f5946c427ed9ec0d91a46bb9def53e54650e555" integrity sha512-BFnaq5ZOGcDN7FlrtBT4xxkgIToalIIxwjxLWVJ8bGTpe1LroqMiqQXdA7ygc7CRvaYS+9zfPGFnJqFSayx+AA== -commander@2.14.x, commander@~2.14.1: - version "2.14.1" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.14.1.tgz#2235123e37af8ca3c65df45b026dbd357b01b9aa" - integrity sha512-+YR16o3rK53SmWHU3rEM3tPAh2rwb1yPcQX5irVn7mb0gXbwuCCrnkbV5+PBfETdfg1vui07nM6PCG1zndcjQw== - commander@2.16.0: version "2.16.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.16.0.tgz#f16390593996ceb4f3eeb020b31d78528f7f8a50" integrity sha512-sVXqklSaotK9at437sFlFpyOcJonxe0yST/AG9DkQKUdIE6IqGIMv4SfAQSKaJbSdVEJYItASCrBiVQHq1HQew== +commander@2.17.x, commander@~2.17.1: + version "2.17.1" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.17.1.tgz#bd77ab7de6de94205ceacc72f1716d29f20a77bf" + integrity sha512-wPMUt6FnH2yzG95SA6mzjQOEKUU3aLaDEmzs1ti+1E9h+CsrZghRlqEM/EJ4KscsQVG8uNN4uVreUeT8+drlgg== + commander@2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.3.0.tgz#fd430e889832ec353b9acd1de217c11cb3eef873" @@ -5420,11 +5537,6 @@ commander@~2.13.0: resolved "https://registry.yarnpkg.com/commander/-/commander-2.13.0.tgz#6964bca67685df7c1f1430c584f07d7597885b9c" integrity sha512-MVuS359B+YzaWqjCL/c+22gfryv+mCBPHAv3zyVI2GN8EY6IRP8VwtasXn8jyyhvvq84R4ImN1OKRtcbIasjYA== -commander@~2.17.1: - version "2.17.1" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.17.1.tgz#bd77ab7de6de94205ceacc72f1716d29f20a77bf" - integrity sha512-wPMUt6FnH2yzG95SA6mzjQOEKUU3aLaDEmzs1ti+1E9h+CsrZghRlqEM/EJ4KscsQVG8uNN4uVreUeT8+drlgg== - common-tags@1.8.0: version "1.8.0" resolved "https://registry.yarnpkg.com/common-tags/-/common-tags-1.8.0.tgz#8e3153e542d4a39e9b10554434afaaf98956a937" @@ -5667,7 +5779,7 @@ contra@1.9.1: atoa "1.0.0" ticky "1.0.0" -convert-source-map@1.X, convert-source-map@^1.1.0, convert-source-map@^1.4.0, convert-source-map@^1.5.0: +convert-source-map@1.X, convert-source-map@^1.1.0, convert-source-map@^1.4.0, convert-source-map@^1.5.0, convert-source-map@^1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.1.tgz#b8278097b9bc229365de5c62cf5fcaed8b5599e5" integrity sha1-uCeAl7m8IpNl3lxiz1/K7YtVmeU= @@ -5745,18 +5857,15 @@ core-util-is@1.0.2, core-util-is@~1.0.0: resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= -cosmiconfig@^2.1.0, cosmiconfig@^2.1.1: - version "2.2.2" - resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-2.2.2.tgz#6173cebd56fac042c1f4390edf7af6c07c7cb892" - integrity sha512-GiNXLwAFPYHy25XmTPpafYvn3CLAkJ8FLsscq78MQd1Kh0OU6Yzhn4eV2MVF4G9WEQZoWEGltatdR+ntGPMl5A== +cosmiconfig@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-4.0.0.tgz#760391549580bbd2df1e562bc177b13c290972dc" + integrity sha512-6e5vDdrXZD+t5v0L8CrurPeybg4Fmf+FCSYxXKYVAqLUtyCSbuyqE059d0kDthTNRzKVjL7QMgNpEUlsoYH3iQ== dependencies: is-directory "^0.3.1" - js-yaml "^3.4.3" - minimist "^1.2.0" - object-assign "^4.1.0" - os-homedir "^1.0.1" - parse-json "^2.2.0" - require-from-string "^1.1.0" + js-yaml "^3.9.0" + parse-json "^4.0.0" + require-from-string "^2.0.1" cp-file@^5.0.0: version "5.0.0" @@ -5984,28 +6093,39 @@ css-color-keywords@^1.0.0: resolved "https://registry.yarnpkg.com/css-color-keywords/-/css-color-keywords-1.0.0.tgz#fea2616dc676b2962686b3af8dbdbe180b244e05" integrity sha1-/qJhbcZ2spYmhrOvjb2+GAskTgU= -css-color-names@0.0.4: - version "0.0.4" - resolved "https://registry.yarnpkg.com/css-color-names/-/css-color-names-0.0.4.tgz#808adc2e79cf84738069b646cb20ec27beb629e0" - integrity sha1-gIrcLnnPhHOAabZGyyDsJ762KeA= - -css-loader@0.28.7: - version "0.28.7" - resolved "https://registry.yarnpkg.com/css-loader/-/css-loader-0.28.7.tgz#5f2ee989dd32edd907717f953317656160999c1b" - integrity sha512-GxMpax8a/VgcfRrVy0gXD6yLd5ePYbXX/5zGgTVYp4wXtJklS8Z2VaUArJgc//f6/Dzil7BaJObdSv8eKKCPgg== +css-loader@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/css-loader/-/css-loader-1.0.0.tgz#9f46aaa5ca41dbe31860e3b62b8e23c42916bf56" + integrity sha512-tMXlTYf3mIMt3b0dDCOQFJiVvxbocJ5Ho577WiGPYPZcqVEO218L2iU22pDXzkTZCLDE+9AmGSUkWxeh/nZReA== dependencies: - babel-code-frame "^6.11.0" + babel-code-frame "^6.26.0" css-selector-tokenizer "^0.7.0" - cssnano ">=2.6.1 <4" icss-utils "^2.1.0" loader-utils "^1.0.2" lodash.camelcase "^4.3.0" - object-assign "^4.0.1" - postcss "^5.0.6" - postcss-modules-extract-imports "^1.0.0" - postcss-modules-local-by-default "^1.0.1" - postcss-modules-scope "^1.0.0" - postcss-modules-values "^1.1.0" + postcss "^6.0.23" + postcss-modules-extract-imports "^1.2.0" + postcss-modules-local-by-default "^1.2.0" + postcss-modules-scope "^1.1.0" + postcss-modules-values "^1.3.0" + postcss-value-parser "^3.3.0" + source-list-map "^2.0.0" + +css-loader@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/css-loader/-/css-loader-1.0.1.tgz#6885bb5233b35ec47b006057da01cc640b6b79fe" + integrity sha512-+ZHAZm/yqvJ2kDtPne3uX0C+Vr3Zn5jFn2N4HywtS5ujwvsVkyg0VArEXpl3BgczDA8anieki1FIzhchX4yrDw== + dependencies: + babel-code-frame "^6.26.0" + css-selector-tokenizer "^0.7.0" + icss-utils "^2.1.0" + loader-utils "^1.0.2" + lodash "^4.17.11" + postcss "^6.0.23" + postcss-modules-extract-imports "^1.2.0" + postcss-modules-local-by-default "^1.2.0" + postcss-modules-scope "^1.1.0" + postcss-modules-values "^1.3.0" postcss-value-parser "^3.3.0" source-list-map "^2.0.0" @@ -6067,44 +6187,6 @@ cssesc@^0.1.0: resolved "https://registry.yarnpkg.com/cssesc/-/cssesc-0.1.0.tgz#c814903e45623371a0477b40109aaafbeeaddbb4" integrity sha1-yBSQPkViM3GgR3tAEJqq++6t27Q= -"cssnano@>=2.6.1 <4": - version "3.10.0" - resolved "https://registry.yarnpkg.com/cssnano/-/cssnano-3.10.0.tgz#4f38f6cea2b9b17fa01490f23f1dc68ea65c1c38" - integrity sha1-Tzj2zqK5sX+gFJDyPx3GjqZcHDg= - dependencies: - autoprefixer "^6.3.1" - decamelize "^1.1.2" - defined "^1.0.0" - has "^1.0.1" - object-assign "^4.0.1" - postcss "^5.0.14" - postcss-calc "^5.2.0" - postcss-colormin "^2.1.8" - postcss-convert-values "^2.3.4" - postcss-discard-comments "^2.0.4" - postcss-discard-duplicates "^2.0.1" - postcss-discard-empty "^2.0.1" - postcss-discard-overridden "^0.1.1" - postcss-discard-unused "^2.2.1" - postcss-filter-plugins "^2.0.0" - postcss-merge-idents "^2.1.5" - postcss-merge-longhand "^2.0.1" - postcss-merge-rules "^2.0.3" - postcss-minify-font-values "^1.0.2" - postcss-minify-gradients "^1.0.1" - postcss-minify-params "^1.0.4" - postcss-minify-selectors "^2.0.4" - postcss-normalize-charset "^1.1.0" - postcss-normalize-url "^3.0.7" - postcss-ordered-values "^2.1.0" - postcss-reduce-idents "^2.2.2" - postcss-reduce-initial "^1.0.0" - postcss-reduce-transforms "^1.0.3" - postcss-svgo "^2.1.1" - postcss-unique-selectors "^2.0.2" - postcss-value-parser "^3.2.3" - postcss-zindex "^2.0.1" - csso@~2.3.1: version "2.3.2" resolved "https://registry.yarnpkg.com/csso/-/csso-2.3.2.tgz#ddd52c587033f49e94b71fc55569f252e8ff5f85" @@ -6374,13 +6456,6 @@ d3@3.5.6: resolved "https://registry.yarnpkg.com/d3/-/d3-3.5.6.tgz#9451c651ca733fb9672c81fb7f2655164a73a42d" integrity sha1-lFHGUcpzP7lnLIH7fyZVFkpzpC0= -d@1: - version "1.0.0" - resolved "https://registry.yarnpkg.com/d/-/d-1.0.0.tgz#754bb5bfe55451da69a58b94d45f4c5b0462d58f" - integrity sha1-dUu1v+VUUdpppYuU1F9MWwRi1Y8= - dependencies: - es5-ext "^0.10.9" - damerau-levenshtein@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/damerau-levenshtein/-/damerau-levenshtein-1.0.4.tgz#03191c432cb6eea168bb77f3a55ffdccb8978514" @@ -6475,7 +6550,7 @@ debug@2.6.0: dependencies: ms "0.7.2" -debug@2.6.9, debug@2.X, debug@^2.0.0, debug@^2.1.0, debug@^2.1.1, debug@^2.1.2, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.6, debug@^2.6.8, debug@^2.6.9: +debug@2.6.9, debug@2.X, debug@^2.0.0, debug@^2.1.0, debug@^2.1.2, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.6, debug@^2.6.8, debug@^2.6.9: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== @@ -6489,6 +6564,13 @@ debug@3.1.0, debug@^3.1.0, debug@~3.1.0: dependencies: ms "2.0.0" +debug@^3.2.5: + version "3.2.6" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.6.tgz#e83d17de16d8a7efb7717edbe5fb10135eee629b" + integrity sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ== + dependencies: + ms "^2.1.1" + debuglog@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/debuglog/-/debuglog-1.0.1.tgz#aa24ffb9ac3df9a2351837cfb2d279360cd78492" @@ -6598,6 +6680,14 @@ deep-is@~0.1.3: resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= +default-gateway@^2.6.0: + version "2.7.2" + resolved "https://registry.yarnpkg.com/default-gateway/-/default-gateway-2.7.2.tgz#b7ef339e5e024b045467af403d50348db4642d0f" + integrity sha512-lAc4i9QJR0YHSDFdzeBQKfZ1SRDG3hsJNEkrpcZa8QhBfidLAilT60BDEIVUUGqosFp425KOgB3uYqcnQrWafQ== + dependencies: + execa "^0.10.0" + ip-regex "^2.1.0" + default-require-extensions@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-1.0.0.tgz#f37ea15d3e13ffd9b437d33e1a75b5fb97874cb8" @@ -6647,11 +6737,6 @@ define-property@^2.0.2: is-descriptor "^1.0.2" isobject "^3.0.1" -defined@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/defined/-/defined-1.0.0.tgz#c98d9bcef75674188e110969151199e39b1fa693" - integrity sha1-yY2bzvdWdBiOEQlpFRGZ45sfppM= - del@^2.0.2, del@^2.2.2: version "2.2.2" resolved "https://registry.yarnpkg.com/del/-/del-2.2.2.tgz#c12c981d067846c84bcaf862cff930d907ffd1a8" @@ -7146,15 +7231,10 @@ elasticsearch@^15.2.0: chalk "^1.0.0" lodash "^4.17.10" -electron-to-chromium@^1.2.7: - version "1.3.37" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.37.tgz#4a92734e0044c8cf0b1553be57eae21a4c6e5fab" - integrity sha1-SpJzTgBEyM8LFVO+V+riGkxuX6s= - -electron-to-chromium@^1.3.30: - version "1.3.33" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.33.tgz#bf00703d62a7c65238136578c352d6c5c042a545" - integrity sha1-vwBwPWKnxlI4E2V4w1LWxcBCpUU= +electron-to-chromium@^1.3.47: + version "1.3.82" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.82.tgz#7d13ae4437d2a783de3f4efba96b186c540b67b1" + integrity sha512-NI4nB2IWGcU4JVT1AE8kBb/dFor4zjLHMLsOROPahppeHrR0FG5uslxMmkp/thO1MvPjM2xhlKoY29/I60s0ew== electron-to-chromium@^1.3.52: version "1.3.56" @@ -7314,15 +7394,14 @@ engine.io@~3.2.0: engine.io-parser "~2.1.0" ws "~3.3.1" -enhanced-resolve@^3.0.0, enhanced-resolve@^3.4.0: - version "3.4.1" - resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-3.4.1.tgz#0421e339fd71419b3da13d129b3979040230476e" - integrity sha1-BCHjOf1xQZs9oT0Smzl5BAIwR24= +enhanced-resolve@^4.0.0, enhanced-resolve@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-4.1.0.tgz#41c7e0bfdfe74ac1ffe1e57ad6a5c6c9f3742a7f" + integrity sha512-F/7vkyTtyc/llOIn8oWclcB25KdRaiPBpZYDgJHgh/UHtpgT2p2eldQgtQnLtUvfMKPKxbRaQM/hHkvLHt1Vng== dependencies: graceful-fs "^4.1.2" memory-fs "^0.4.0" - object-assign "^4.0.1" - tapable "^0.2.7" + tapable "^1.0.0" enhanced-resolve@~0.9.0: version "0.9.1" @@ -7441,35 +7520,6 @@ es-to-primitive@^1.1.1: is-date-object "^1.0.1" is-symbol "^1.0.1" -es5-ext@^0.10.14, es5-ext@^0.10.35, es5-ext@^0.10.9, es5-ext@~0.10.14: - version "0.10.40" - resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.40.tgz#ab3d2179b943008c5e9ef241beb25ef41424c774" - integrity sha512-S9Fh3oya5OOvYSNGvPZJ+vyrs6VYpe1IXPowVe3N1OhaiwVaGlwfn3Zf5P5klYcWOA0toIwYQW8XEv/QqhdHvQ== - dependencies: - es6-iterator "~2.0.3" - es6-symbol "~3.1.1" - -es6-iterator@^2.0.1, es6-iterator@~2.0.1, es6-iterator@~2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" - integrity sha1-p96IkUGgWpSwhUQDstCg+/qY87c= - dependencies: - d "1" - es5-ext "^0.10.35" - es6-symbol "^3.1.1" - -es6-map@^0.1.3: - version "0.1.5" - resolved "https://registry.yarnpkg.com/es6-map/-/es6-map-0.1.5.tgz#9136e0503dcc06a301690f0bb14ff4e364e949f0" - integrity sha1-kTbgUD3MBqMBaQ8LsU/042TpSfA= - dependencies: - d "1" - es5-ext "~0.10.14" - es6-iterator "~2.0.1" - es6-set "~0.1.5" - es6-symbol "~3.1.1" - event-emitter "~0.3.5" - es6-promise@^3.0.2: version "3.3.1" resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-3.3.1.tgz#a08cdde84ccdbf34d027a1451bc91d4bcd28a613" @@ -7487,26 +7537,7 @@ es6-promisify@^5.0.0: dependencies: es6-promise "^4.0.3" -es6-set@~0.1.5: - version "0.1.5" - resolved "https://registry.yarnpkg.com/es6-set/-/es6-set-0.1.5.tgz#d2b3ec5d4d800ced818db538d28974db0a73ccb1" - integrity sha1-0rPsXU2ADO2BjbU40ol02wpzzLE= - dependencies: - d "1" - es5-ext "~0.10.14" - es6-iterator "~2.0.1" - es6-symbol "3.1.1" - event-emitter "~0.3.5" - -es6-symbol@3.1.1, es6-symbol@^3.1.1, es6-symbol@~3.1.1: - version "3.1.1" - resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.1.tgz#bf00ef4fdab6ba1b46ecb7b629b4c7ed5715cc77" - integrity sha1-vwDvT9q2uhtG7Le2KbTH7VcVzHc= - dependencies: - d "1" - es5-ext "~0.10.14" - -es6-templates@^0.2.2: +es6-templates@^0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/es6-templates/-/es6-templates-0.2.3.tgz#5cb9ac9fb1ded6eb1239342b81d792bbb4078ee4" integrity sha1-XLmsn7He1usSOTQrgdeSu7QHjuQ= @@ -7514,16 +7545,6 @@ es6-templates@^0.2.2: recast "~0.11.12" through "~2.3.6" -es6-weak-map@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.2.tgz#5e3ab32251ffd1538a1f8e5ffa1357772f92d96f" - integrity sha1-XjqzIlH/0VOKH45f+hNXdy+S2W8= - dependencies: - d "1" - es5-ext "^0.10.14" - es6-iterator "^2.0.1" - es6-symbol "^3.1.1" - escape-html@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/escape-html/-/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988" @@ -7607,16 +7628,6 @@ escodegen@~1.3.2: optionalDependencies: source-map "~0.1.33" -escope@^3.6.0: - version "3.6.0" - resolved "https://registry.yarnpkg.com/escope/-/escope-3.6.0.tgz#e01975e812781a163a6dadfdd80398dc64c889c3" - integrity sha1-4Bl16BJ4GhY6ba392AOY3GTIicM= - dependencies: - es6-map "^0.1.3" - es6-weak-map "^2.0.1" - esrecurse "^4.1.0" - estraverse "^4.1.1" - eslint-config-prettier@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-3.1.0.tgz#2c26d2cdcfa3a05f0642cd7e6e4ef3316cdabfa2" @@ -7904,14 +7915,6 @@ etag@~1.8.1: resolved "https://registry.yarnpkg.com/etag/-/etag-1.8.1.tgz#41ae2eeb65efa62268aebfea83ac7d79299b0887" integrity sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc= -event-emitter@~0.3.5: - version "0.3.5" - resolved "https://registry.yarnpkg.com/event-emitter/-/event-emitter-0.3.5.tgz#df8c69eef1647923c7157b9ce83840610b02cc39" - integrity sha1-34xp7vFkeSPHFXuc6DhAYQsCzDk= - dependencies: - d "1" - es5-ext "~0.10.14" - eventemitter2@~0.4.13: version "0.4.14" resolved "https://registry.yarnpkg.com/eventemitter2/-/eventemitter2-0.4.14.tgz#8f61b75cde012b2e9eb284d4545583b5643b61ab" @@ -7932,12 +7935,12 @@ events@^1.0.0, events@^1.0.2: resolved "https://registry.yarnpkg.com/events/-/events-1.1.1.tgz#9ebdb7635ad099c70dcc4c2a1f5004288e8bd924" integrity sha1-nr23Y1rQmccNzEwqH1AEKI6L2SQ= -eventsource@0.1.6: - version "0.1.6" - resolved "https://registry.yarnpkg.com/eventsource/-/eventsource-0.1.6.tgz#0acede849ed7dd1ccc32c811bb11b944d4f29232" - integrity sha1-Cs7ehJ7X3RzMMsgRuxG5RNTykjI= +eventsource@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/eventsource/-/eventsource-1.0.7.tgz#8fbc72c93fcd34088090bc0a4e64f4b5cee6d8d0" + integrity sha512-4Ln17+vVT0k8aWq+t/bF5arcS3EpT9gYtW66EPacdj/mAFevznsnyoHLPy2BA8gbIQeIHoPsvwmfBftfcG//BQ== dependencies: - original ">=0.0.5" + original "^1.0.0" evp_bytestokey@^1.0.0, evp_bytestokey@^1.0.3: version "1.0.3" @@ -8135,44 +8138,44 @@ expiry-js@0.1.7: resolved "https://registry.yarnpkg.com/expiry-js/-/expiry-js-0.1.7.tgz#76be8c05e572bf936df40c1766448d0b3b2f555f" integrity sha1-dr6MBeVyv5Nt9AwXZkSNCzsvVV8= -expose-loader@0.7.3: - version "0.7.3" - resolved "https://registry.yarnpkg.com/expose-loader/-/expose-loader-0.7.3.tgz#35fbd3659789e4faa81f59de8b7e9fc39e466d51" - integrity sha1-NfvTZZeJ5PqoH1nei36fw55GbVE= +expose-loader@^0.7.5: + version "0.7.5" + resolved "https://registry.yarnpkg.com/expose-loader/-/expose-loader-0.7.5.tgz#e29ea2d9aeeed3254a3faa1b35f502db9f9c3f6f" + integrity sha512-iPowgKUZkTPX5PznYsmifVj9Bob0w2wTHVkt/eYNPSzyebkUgIedmskf/kcfEIWpiWjg3JRjnW+a17XypySMuw== -express@^4.13.3: - version "4.16.2" - resolved "https://registry.yarnpkg.com/express/-/express-4.16.2.tgz#e35c6dfe2d64b7dca0a5cd4f21781be3299e076c" - integrity sha1-41xt/i1kt9ygpc1PIXgb4ymeB2w= +express@^4.16.2: + version "4.16.4" + resolved "https://registry.yarnpkg.com/express/-/express-4.16.4.tgz#fddef61926109e24c515ea97fd2f1bdbf62df12e" + integrity sha512-j12Uuyb4FMrd/qQAm6uCHAkPtO8FDTRJZBDd5D2KOL2eLaz1yUNdUB/NOIyq0iU4q4cFarsUCrnFDPBcnksuOg== dependencies: - accepts "~1.3.4" + accepts "~1.3.5" array-flatten "1.1.1" - body-parser "1.18.2" + body-parser "1.18.3" content-disposition "0.5.2" content-type "~1.0.4" cookie "0.3.1" cookie-signature "1.0.6" debug "2.6.9" - depd "~1.1.1" - encodeurl "~1.0.1" + depd "~1.1.2" + encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" - finalhandler "1.1.0" + finalhandler "1.1.1" fresh "0.5.2" merge-descriptors "1.0.1" methods "~1.1.2" on-finished "~2.3.0" parseurl "~1.3.2" path-to-regexp "0.1.7" - proxy-addr "~2.0.2" - qs "6.5.1" + proxy-addr "~2.0.4" + qs "6.5.2" range-parser "~1.2.0" - safe-buffer "5.1.1" - send "0.16.1" - serve-static "1.13.1" + safe-buffer "5.1.2" + send "0.16.2" + serve-static "1.13.2" setprototypeof "1.1.0" - statuses "~1.3.1" - type-is "~1.6.15" + statuses "~1.4.0" + type-is "~1.6.16" utils-merge "1.0.1" vary "~1.1.2" @@ -8198,12 +8201,12 @@ extend-shallow@^3.0.0, extend-shallow@^3.0.2: assign-symbols "^1.0.0" is-extendable "^1.0.1" -extend@^3.0.0, extend@~3.0.0, extend@~3.0.1: +extend@^3.0.0, extend@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" integrity sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ= -extend@~3.0.2: +extend@~3.0.0, extend@~3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== @@ -8288,16 +8291,6 @@ extract-opts@^3.0.1: editions "^1.1.1" typechecker "^4.3.0" -extract-text-webpack-plugin@3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/extract-text-webpack-plugin/-/extract-text-webpack-plugin-3.0.1.tgz#605a8893faca1dd49bb0d2ca87493f33fd43d102" - integrity sha512-zv0/Cg2mU8uMzeQQ3oyfJvZU4Iv/GbQYUIr/HU+8pZetT/0W3xj6XAbxoG4gsp8SbnYcFd4BOsCAZPl9NvplPw== - dependencies: - async "^2.4.1" - loader-utils "^1.1.0" - schema-utils "^0.3.0" - webpack-sources "^1.0.1" - extract-zip@1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/extract-zip/-/extract-zip-1.5.0.tgz#92ccf6d81ef70a9fa4c1747114ccef6d8688a6c4" @@ -8404,7 +8397,7 @@ faye-websocket@^0.10.0, faye-websocket@~0.10.0: dependencies: websocket-driver ">=0.5.1" -faye-websocket@~0.11.0: +faye-websocket@~0.11.1: version "0.11.1" resolved "https://registry.yarnpkg.com/faye-websocket/-/faye-websocket-0.11.1.tgz#f0efe18c4f56e4f40afc7e06c719fd5ee6188f38" integrity sha1-8O/hjE9W5PQK/H4Gxxn9XuYYjzg= @@ -8490,13 +8483,13 @@ file-entry-cache@^2.0.0: flat-cache "^1.2.1" object-assign "^4.0.1" -file-loader@1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/file-loader/-/file-loader-1.1.4.tgz#5ca9384adfafe008077c3439a435b2781a889ef5" - integrity sha512-E4mCBrAVk8pB6VmuCW/rbHvtQDy2sknh0G4c2c449Q5qC7fCkL1P6sZGxQXWPaAxXBdU8WsTzPEB973Ei8vkxg== +file-loader@2.0.0, file-loader@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/file-loader/-/file-loader-2.0.0.tgz#39749c82f020b9e85901dcff98e8004e6401cfde" + integrity sha512-YCsBfd1ZGCyonOKLxPiKPdu+8ld9HAaMEvJewzz+b2eTF7uL5Zm/HdBF6FjCrpCMRq25Mi0U1gl4pwn2TlH7hQ== dependencies: loader-utils "^1.0.2" - schema-utils "^0.3.0" + schema-utils "^1.0.0" file-saver@^1.3.8: version "1.3.8" @@ -8602,6 +8595,19 @@ finalhandler@1.1.0: statuses "~1.3.1" unpipe "~1.0.0" +finalhandler@1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.1.tgz#eebf4ed840079c83f4249038c9d703008301b105" + integrity sha512-Y1GUDo39ez4aHAw7MysnUD5JzYX+WaIj8I57kO3aEPT1fFRL4sr7mjei97FgnwhAyyzRYmQZaTHb2+9uZ1dPtg== + dependencies: + debug "2.6.9" + encodeurl "~1.0.2" + escape-html "~1.0.3" + on-finished "~2.3.0" + parseurl "~1.3.2" + statuses "~1.4.0" + unpipe "~1.0.0" + find-cache-dir@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-1.0.0.tgz#9288e3e9e3cc3748717d39eade17cf71fc30ee6f" @@ -8711,11 +8717,6 @@ flat-cache@^1.2.1: graceful-fs "^4.1.2" write "^0.2.1" -flatten@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/flatten/-/flatten-1.0.2.tgz#dae46a9d78fbe25292258cc1e780a41d95c03782" - integrity sha1-2uRqnXj74lKSJYzB54CkHZXAN4I= - flush-write-stream@^1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/flush-write-stream/-/flush-write-stream-1.0.3.tgz#c5d586ef38af6097650b49bc41b55fabb19f35bd" @@ -9101,18 +9102,6 @@ geckodriver@1.12.2: https-proxy-agent "2.2.1" tar "4.0.2" -generate-function@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/generate-function/-/generate-function-2.0.0.tgz#6858fe7c0969b7d4e9093337647ac79f60dfbe74" - integrity sha1-aFj+fAlpt9TpCTM3ZHrHn2DfvnQ= - -generate-object-property@^1.1.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/generate-object-property/-/generate-object-property-1.2.0.tgz#9c0e1c40308ce804f4783618b937fa88f99d50d0" - integrity sha1-nA4cQDCM6AT0eDYYuTf6iPmdUNA= - dependencies: - is-property "^1.0.0" - get-caller-file@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.2.tgz#f702e63127e7e231c160a80c1554acb70d5047e5" @@ -9393,6 +9382,11 @@ global-dirs@^0.1.0: dependencies: ini "^1.3.4" +global-modules-path@^2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/global-modules-path/-/global-modules-path-2.3.0.tgz#b0e2bac6beac39745f7db5c59d26a36a0b94f7dc" + integrity sha512-HchvMJNYh9dGSCy8pOQ2O8u/hoXaL+0XhnrwH0RyLiSXMMTl9W3N6KUU73+JFOg5PGjtzl6VZzUQsnrpm7Szag== + global-modules@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/global-modules/-/global-modules-1.0.0.tgz#6d770f0eb523ac78164d72b5e71a8877265cc3ea" @@ -10139,16 +10133,6 @@ har-schema@^2.0.0: resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= -har-validator@~2.0.6: - version "2.0.6" - resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-2.0.6.tgz#cdcbc08188265ad119b6a5a7c8ab70eecfb5d27d" - integrity sha1-zcvAgYgmWtEZtqWnyKtw7s+10n0= - dependencies: - chalk "^1.1.1" - commander "^2.9.0" - is-my-json-valid "^2.12.4" - pinkie-promise "^2.0.0" - har-validator@~4.2.1: version "4.2.1" resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-4.2.1.tgz#33481d0f1bbff600dd203d75812a6a5fba002e2a" @@ -10352,10 +10336,10 @@ hawk@~6.0.2: hoek "4.x.x" sntp "2.x.x" -he@1.1.x: - version "1.1.1" - resolved "https://registry.yarnpkg.com/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" - integrity sha1-k0EP0hsAlzUVH4howvJx80J+I/0= +he@1.2.x: + version "1.2.0" + resolved "https://registry.yarnpkg.com/he/-/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f" + integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw== he@^0.5.0: version "0.5.0" @@ -10504,11 +10488,6 @@ hpack.js@^2.1.6: readable-stream "^2.0.1" wbuf "^1.1.0" -html-comment-regex@^1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/html-comment-regex/-/html-comment-regex-1.1.1.tgz#668b93776eaae55ebde8f3ad464b307a4963625e" - integrity sha1-ZouTd26q5V696POtRkswekljYl4= - html-encoding-sniffer@^1.0.1, html-encoding-sniffer@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-1.0.2.tgz#e70d84b94da53aa375e11fe3a351be6642ca46f8" @@ -10521,30 +10500,29 @@ html-entities@^1.2.0: resolved "https://registry.yarnpkg.com/html-entities/-/html-entities-1.2.1.tgz#0df29351f0721163515dfb9e5543e5f6eed5162f" integrity sha1-DfKTUfByEWNRXfueVUPl9u7VFi8= -html-loader@0.5.1: - version "0.5.1" - resolved "https://registry.yarnpkg.com/html-loader/-/html-loader-0.5.1.tgz#4f1e8396a1ea6ab42bedc987dfac058070861ebe" - integrity sha512-RxokXoxcsRSWcN553Ew+K0TUo68gQfmddTuUIZ4xRD8Ax1xXzX2UYQ3FC3D5MoRPGAdL1erWKeEFihDrrdxHiA== +html-loader@^0.5.5: + version "0.5.5" + resolved "https://registry.yarnpkg.com/html-loader/-/html-loader-0.5.5.tgz#6356dbeb0c49756d8ebd5ca327f16ff06ab5faea" + integrity sha512-7hIW7YinOYUpo//kSYcPB6dCKoceKLmOwjEMmhIobHuWGDVl0Nwe4l68mdG/Ru0wcUxQjVMEoZpkalZ/SE7zog== dependencies: - es6-templates "^0.2.2" + es6-templates "^0.2.3" fastparse "^1.1.1" - html-minifier "^3.0.1" - loader-utils "^1.0.2" - object-assign "^4.1.0" + html-minifier "^3.5.8" + loader-utils "^1.1.0" + object-assign "^4.1.1" -html-minifier@^3.0.1: - version "3.5.10" - resolved "https://registry.yarnpkg.com/html-minifier/-/html-minifier-3.5.10.tgz#8522c772c388db81aa5c26f62033302d906ea1c7" - integrity sha512-5c8iAyeIGAiuFhVjJ0qy1lgvyQxxuZgjeOuMnoK/wjEyy8DF3xKUnE9pO+6H7VMir976K6SGlZV8ZEmIOea/Zg== +html-minifier@^3.5.8: + version "3.5.21" + resolved "https://registry.yarnpkg.com/html-minifier/-/html-minifier-3.5.21.tgz#d0040e054730e354db008463593194015212d20c" + integrity sha512-LKUKwuJDhxNa3uf/LPR/KVjm/l3rBqtYeCOAekvG8F1vItxMUpueGd94i/asDDr8/1u7InxzFA5EeGjhhG5mMA== dependencies: camel-case "3.0.x" - clean-css "4.1.x" - commander "2.14.x" - he "1.1.x" - ncname "1.0.x" + clean-css "4.2.x" + commander "2.17.x" + he "1.2.x" param-case "2.1.x" relateurl "0.2.x" - uglify-js "3.3.x" + uglify-js "3.4.x" html@1.0.0, html@^1.0.0: version "1.0.0" @@ -10585,6 +10563,16 @@ http-errors@1.6.2, http-errors@~1.6.2: setprototypeof "1.0.3" statuses ">= 1.3.1 < 2" +http-errors@1.6.3, http-errors@~1.6.3: + version "1.6.3" + resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.6.3.tgz#8b55680bb4be283a0b5bf4ea2e38580be1d9320d" + integrity sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0= + dependencies: + depd "~1.1.2" + inherits "2.0.3" + setprototypeof "1.1.0" + statuses ">= 1.4.0 < 2" + http-parser-js@>=0.4.0: version "0.4.11" resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.4.11.tgz#5b720849c650903c27e521633d94696ee95f3529" @@ -10598,15 +10586,15 @@ http-proxy-agent@^2.1.0: agent-base "4" debug "3.1.0" -http-proxy-middleware@~0.17.4: - version "0.17.4" - resolved "https://registry.yarnpkg.com/http-proxy-middleware/-/http-proxy-middleware-0.17.4.tgz#642e8848851d66f09d4f124912846dbaeb41b833" - integrity sha1-ZC6ISIUdZvCdTxJJEoRtuutBuDM= +http-proxy-middleware@~0.18.0: + version "0.18.0" + resolved "https://registry.yarnpkg.com/http-proxy-middleware/-/http-proxy-middleware-0.18.0.tgz#0987e6bb5a5606e5a69168d8f967a87f15dd8aab" + integrity sha512-Fs25KVMPAIIcgjMZkVHJoKg9VcXcC1C8yb9JUgeDvVXY0S/zgVIhMb+qVswDIgtJe2DfckMSY2d6TuTEutlk6Q== dependencies: http-proxy "^1.16.2" - is-glob "^3.1.0" - lodash "^4.17.2" - micromatch "^2.3.11" + is-glob "^4.0.0" + lodash "^4.17.5" + micromatch "^3.1.9" http-proxy@^1.13.0, http-proxy@^1.16.2: version "1.16.2" @@ -10753,6 +10741,20 @@ immutability-helper@^2.0.0: dependencies: invariant "^2.2.0" +import-cwd@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/import-cwd/-/import-cwd-2.1.0.tgz#aa6cf36e722761285cb371ec6519f53e2435b0a9" + integrity sha1-qmzzbnInYShcs3HsZRn1PiQ1sKk= + dependencies: + import-from "^2.1.0" + +import-from@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/import-from/-/import-from-2.1.0.tgz#335db7f2a7affd53aaa471d4b8021dee36b7f3b1" + integrity sha1-M1238qev/VOqpHHUuAId7ja387E= + dependencies: + resolve-from "^3.0.0" + import-lazy@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/import-lazy/-/import-lazy-2.1.0.tgz#05698e3d45c88e8d7e9d92cb0584e77f096f3e43" @@ -10766,13 +10768,21 @@ import-local@^1.0.0: pkg-dir "^2.0.0" resolve-cwd "^2.0.0" -imports-loader@0.7.1: - version "0.7.1" - resolved "https://registry.yarnpkg.com/imports-loader/-/imports-loader-0.7.1.tgz#f204b5f34702a32c1db7d48d89d5e867a0441253" - integrity sha1-8gS180cCoywdt9SNidXoZ6BEElM= +import-local@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/import-local/-/import-local-2.0.0.tgz#55070be38a5993cf18ef6db7e961f5bee5c5a09d" + integrity sha512-b6s04m3O+s3CGSbqDIyP4R6aAwAeYlVq9+WUWep6iHa8ETRf9yei1U48C5MmfJmV9AiLYYBKPMq/W+/WRpQmCQ== + dependencies: + pkg-dir "^3.0.0" + resolve-cwd "^2.0.0" + +imports-loader@^0.8.0: + version "0.8.0" + resolved "https://registry.yarnpkg.com/imports-loader/-/imports-loader-0.8.0.tgz#030ea51b8ca05977c40a3abfd9b4088fe0be9a69" + integrity sha512-kXWL7Scp8KQ4552ZcdVTeaQCZSLW+e6nJfp3cwUMB673T7Hr98Xjx5JK+ql7ADlJUvj1JS5O01RLbKoutN5QDQ== dependencies: loader-utils "^1.0.2" - source-map "^0.5.6" + source-map "^0.6.1" imurmurhash@^0.1.4: version "0.1.4" @@ -10796,11 +10806,6 @@ indent-string@^3.0.0, indent-string@^3.2.0: resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-3.2.0.tgz#4a5fd6d27cc332f37e5419a504dbb837105c9289" integrity sha1-Sl/W0nzDMvN+VBmlBNu4NxBckok= -indexes-of@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/indexes-of/-/indexes-of-1.0.1.tgz#f30f716c8e2bd346c7b67d3df3915566a7c05607" - integrity sha1-8w9xbI4r00bHtn0985FVZqfAVgc= - indexof@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/indexof/-/indexof-0.0.1.tgz#82dc336d232b9062179d05ab3293a66059fd435d" @@ -11002,14 +11007,15 @@ insight@^0.10.1: tough-cookie "^2.0.0" uuid "^3.0.0" -internal-ip@1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/internal-ip/-/internal-ip-1.2.0.tgz#ae9fbf93b984878785d50a8de1b356956058cf5c" - integrity sha1-rp+/k7mEh4eF1QqN4bNWlWBYz1w= +internal-ip@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/internal-ip/-/internal-ip-3.0.1.tgz#df5c99876e1d2eb2ea2d74f520e3f669a00ece27" + integrity sha512-NXXgESC2nNVtU+pqmC9e6R8B1GpKxzsAQhffvh5AL79qKnodd+L7tnEQmTiUAVngqLalPbSqRA7XGIEL5nCd0Q== dependencies: - meow "^3.3.0" + default-gateway "^2.6.0" + ipaddr.js "^1.5.2" -interpret@^1.0.0: +interpret@^1.0.0, interpret@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.1.0.tgz#7ed1b1410c6a0e0f78cf95d3b8440c63f78b8614" integrity sha1-ftGxQQxqDg94z5XTuEQMY/eLhhQ= @@ -11070,20 +11076,35 @@ invert-kv@^1.0.0: resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" integrity sha1-EEqOSqym09jNFXqO+L+rLXo//bY= +invert-kv@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-2.0.0.tgz#7393f5afa59ec9ff5f67a27620d11c226e3eec02" + integrity sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA== + ip-regex@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/ip-regex/-/ip-regex-1.0.3.tgz#dc589076f659f419c222039a33316f1c7387effd" integrity sha1-3FiQdvZZ9BnCIgOaMzFvHHOH7/0= +ip-regex@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/ip-regex/-/ip-regex-2.1.0.tgz#fa78bf5d2e6913c911ce9f819ee5146bb6d844e9" + integrity sha1-+ni/XS5pE8kRzp+BnuUUa7bYROk= + ip@1.1.5, ip@^1.1.0, ip@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.5.tgz#bdded70114290828c0a039e72ef25f5aaec4354a" integrity sha1-vd7XARQpCCjAoDnnLvJfWq7ENUo= -ipaddr.js@1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.6.0.tgz#e3fa357b773da619f26e95f049d055c72796f86b" - integrity sha1-4/o1e3c9phnybpXwSdBVxyeW+Gs= +ipaddr.js@1.8.0: + version "1.8.0" + resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.8.0.tgz#eaa33d6ddd7ace8f7f6fe0c9ca0440e706738b1e" + integrity sha1-6qM9bd16zo9/b+DJygRA5wZzix4= + +ipaddr.js@^1.5.2: + version "1.8.1" + resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.8.1.tgz#fa4b79fa47fd3def5e3b159825161c0a519c9427" + integrity sha1-+kt5+kf9Pe9eOxWYJRYcClGclCc= iron@5.x.x: version "5.0.4" @@ -11099,11 +11120,6 @@ irregular-plurals@^1.0.0: resolved "https://registry.yarnpkg.com/irregular-plurals/-/irregular-plurals-1.4.0.tgz#2ca9b033651111855412f16be5d77c62a458a766" integrity sha1-LKmwM2UREYVUEvFr5dd8YqRYp2Y= -is-absolute-url@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/is-absolute-url/-/is-absolute-url-2.1.0.tgz#50530dfb84fcc9aa7dbe7852e83a37b93b9f2aa6" - integrity sha1-UFMN+4T8yap9vnhS6Do3uTufKqY= - is-absolute@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-absolute/-/is-absolute-1.0.0.tgz#395e1ae84b11f26ad1795e73c17378e48a301576" @@ -11163,7 +11179,7 @@ is-binary-path@^2.0.0: dependencies: binary-extensions "^1.0.0" -is-buffer@^1.0.2, is-buffer@^1.1.4, is-buffer@^1.1.5: +is-buffer@^1.1.4, is-buffer@^1.1.5: version "1.1.6" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" integrity sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w== @@ -11351,22 +11367,6 @@ is-lower-case@^1.1.0: dependencies: lower-case "^1.1.0" -is-my-ip-valid@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-my-ip-valid/-/is-my-ip-valid-1.0.0.tgz#7b351b8e8edd4d3995d4d066680e664d94696824" - integrity sha512-gmh/eWXROncUzRnIa1Ubrt5b8ep/MGSnfAUI3aRp+sqTCs1tv1Isl8d8F6JmkN3dXKc3ehZMrtiPN9eL03NuaQ== - -is-my-json-valid@^2.12.4: - version "2.17.2" - resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.17.2.tgz#6b2103a288e94ef3de5cf15d29dd85fc4b78d65c" - integrity sha512-IBhBslgngMQN8DDSppmgDv7RNrlFotuuDsKcrCP3+HbFaVivIBU7u9oiiErw8sH4ynx3+gOGQ3q2otkgiSi6kg== - dependencies: - generate-function "^2.0.0" - generate-object-property "^1.1.0" - is-my-ip-valid "^1.0.0" - jsonpointer "^4.0.0" - xtend "^4.0.0" - is-natural-number@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/is-natural-number/-/is-natural-number-4.0.1.tgz#ab9d76e1db4ced51e35de0c72ebecf09f734cde8" @@ -11483,11 +11483,6 @@ is-promise@^2.0.0, is-promise@^2.1.0: resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" integrity sha1-eaKp7OfwlugPNtKy87wWwf9L8/o= -is-property@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-property/-/is-property-1.0.2.tgz#57fe1c4e48474edd65b09911f26b1cd4095dda84" - integrity sha1-V/4cTkhHTt1lsJkR8msc1Ald2oQ= - is-redirect@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-redirect/-/is-redirect-1.0.0.tgz#1d03dded53bd8db0f30c26e4f95d36fc7c87dc24" @@ -11549,13 +11544,6 @@ is-supported-regexp-flag@^1.0.0: resolved "https://registry.yarnpkg.com/is-supported-regexp-flag/-/is-supported-regexp-flag-1.0.0.tgz#8b520c85fae7a253382d4b02652e045576e13bb8" integrity sha1-i1IMhfrnolM4LUsCZS4EVXbhO7g= -is-svg@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/is-svg/-/is-svg-2.1.0.tgz#cf61090da0d9efbcab8722deba6f032208dbb0e9" - integrity sha1-z2EJDaDZ77yrhyLeum8DIgjbsOk= - dependencies: - html-comment-regex "^1.1.0" - is-symbol@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.1.tgz#3cc59f00025194b6ab2e38dbae6689256b660572" @@ -11689,10 +11677,10 @@ istanbul-api@^1.3.1: mkdirp "^0.5.1" once "^1.4.0" -istanbul-instrumenter-loader@3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/istanbul-instrumenter-loader/-/istanbul-instrumenter-loader-3.0.0.tgz#9f553923b22360bac95e617aaba01add1f7db0b2" - integrity sha512-alLSEFX06ApU75sm5oWcaVNaiss/bgMRiWTct3g0P0ZZTKjR+6QiCcuVOKDI1kWJgwHEnIXsv/dWm783kPpmtw== +istanbul-instrumenter-loader@3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/istanbul-instrumenter-loader/-/istanbul-instrumenter-loader-3.0.1.tgz#9957bd59252b373fae5c52b7b5188e6fde2a0949" + integrity sha512-a5SPObZgS0jB/ixaKSMdn6n/gXSrK2S6q/UfRJBT3e6gQmVjwZROTODQsYW5ZNwOu78hG62Y3fWlebaVOL0C+w== dependencies: convert-source-map "^1.5.0" istanbul-lib-instrument "^1.7.3" @@ -12252,7 +12240,7 @@ js-yaml@3.4.1: argparse "~1.0.2" esprima "~2.2.0" -js-yaml@3.x, js-yaml@^3.4.3: +js-yaml@3.x: version "3.11.0" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.11.0.tgz#597c1a8bd57152f26d622ce4117851a51f5ebaef" integrity sha512-saJstZWv7oNeOyBh3+Dx1qWzhW0+e6/8eDzo7p5rDFqxntSztloLtuKu+Ejhtq82jsilwOIZYsCz+lIjthg1Hw== @@ -12260,7 +12248,7 @@ js-yaml@3.x, js-yaml@^3.4.3: argparse "^1.0.7" esprima "^4.0.0" -js-yaml@^3.12.0: +js-yaml@^3.12.0, js-yaml@^3.9.0: version "3.12.0" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.12.0.tgz#eaed656ec8344f10f527c6bfa1b6e2244de167d1" integrity sha512-PIt2cnwmPfL4hKNwqeiuz4bKfnzHTBv6HyVgjahA6mPLwPDzjDWrplJBMjHUFxku/N3FlmrbyPclad+I+4mJ3A== @@ -12387,16 +12375,16 @@ json-buffer@3.0.0: resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.0.tgz#5b1f397afc75d677bde8bcfc0e47e1f9a3d9a898" integrity sha1-Wx85evx11ne96Lz8Dkfh+aPZqJg= -json-loader@^0.5.4: - version "0.5.7" - resolved "https://registry.yarnpkg.com/json-loader/-/json-loader-0.5.7.tgz#dca14a70235ff82f0ac9a3abeb60d337a365185d" - integrity sha512-QLPs8Dj7lnf3e3QYS1zkCo+4ZwqOiF9d/nZnYozTISxXWCfNs9yuky5rJw4/W34s7POaNlbZmQGaB5NiXCbP4w== - json-parse-better-errors@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.1.tgz#50183cd1b2d25275de069e9e71b467ac9eab973a" integrity sha512-xyQpxeWWMKyJps9CuGJYeng6ssI5bpqS9ltQpdVQ90t4ql6NdnxFKh95JcRt2cun/DjMVNrdjniLPuMA69xmCw== +json-parse-better-errors@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" + integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== + json-schema-traverse@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" @@ -12470,16 +12458,6 @@ jsonify@~0.0.0: resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" integrity sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM= -jsonparse@^1.1.0: - version "1.3.1" - resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280" - integrity sha1-P02uSpH6wxX3EGL4UhzCOfE2YoA= - -jsonpointer@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/jsonpointer/-/jsonpointer-4.0.1.tgz#4fd92cb34e0e9db3c89c8622ecf51f9b978c6cb9" - integrity sha1-T9kss04OnbPInIYi7PUfm5eMbLk= - jsonwebtoken@^8.3.0: version "8.3.0" resolved "https://registry.yarnpkg.com/jsonwebtoken/-/jsonwebtoken-8.3.0.tgz#056c90eee9a65ed6e6c72ddb0a1d325109aaf643" @@ -12669,19 +12647,17 @@ keyv@3.0.0: dependencies: json-buffer "3.0.0" +killable@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/killable/-/killable-1.0.1.tgz#4c8ce441187a061c7474fb87ca08e2a638194892" + integrity sha512-LzqtLKlUwirEUyl/nicirVmNiPvYs7l5n8wOPP7fyJVpUPkvCnW/vuiXGpylGUlnPDnB7311rARzAt3Mhswpjg== + kind-of@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-1.1.0.tgz#140a3d2d41a36d2efcfa9377b62c24f8495a5c44" integrity sha1-FAo9LUGjbS78+pN3tiwk+ElaXEQ= -kind-of@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-2.0.1.tgz#018ec7a4ce7e3a86cb9141be519d24c8faa981b5" - integrity sha1-AY7HpM5+OobLkUG+UZ0kyPqpgbU= - dependencies: - is-buffer "^1.0.2" - -kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.1.0, kind-of@^3.2.0, kind-of@^3.2.2: +kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.1.0, kind-of@^3.2.0: version "3.2.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" integrity sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ= @@ -12738,11 +12714,6 @@ latest-version@^3.0.0, latest-version@^3.1.0: dependencies: package-json "^4.0.0" -lazy-cache@^0.2.3: - version "0.2.7" - resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-0.2.7.tgz#7feddf2dcb6edb77d11ef1d117ab5ffdf0ab1b65" - integrity sha1-f+3fLctu23fRHvHRF6tf/fCrG2U= - lazy-cache@^1.0.3: version "1.0.4" resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-1.0.4.tgz#a1d78fc3a50474cb80845d3b3b6e1da49a446e8e" @@ -12774,6 +12745,13 @@ lcid@^1.0.0: dependencies: invert-kv "^1.0.0" +lcid@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/lcid/-/lcid-2.0.0.tgz#6ef5d2df60e52f82eb228a4c373e8d1f397253cf" + integrity sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA== + dependencies: + invert-kv "^2.0.0" + lead@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lead/-/lead-1.0.0.tgz#6f14f99a37be3a9dd784f5495690e5903466ee42" @@ -12821,14 +12799,14 @@ left-pad@^1.2.0: resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.2.0.tgz#d30a73c6b8201d8f7d8e7956ba9616087a68e0ee" integrity sha1-0wpzxrggHY99jnlWupYWCHpo4O4= -less-loader@4.0.5: - version "4.0.5" - resolved "https://registry.yarnpkg.com/less-loader/-/less-loader-4.0.5.tgz#ae155a7406cac6acd293d785587fcff0f478c4dd" - integrity sha1-rhVadAbKxqzSk9eFWH/P8PR4xN0= +less-loader@4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/less-loader/-/less-loader-4.1.0.tgz#2c1352c5b09a4f84101490274fd51674de41363e" + integrity sha512-KNTsgCE9tMOM70+ddxp9yyt9iHqgmSs0yTZc5XH5Wo+g80RWRIYNqE58QJKm/yMud5wZEvz50ugRDuzVIkyahg== dependencies: clone "^2.1.1" loader-utils "^1.1.0" - pify "^2.3.0" + pify "^3.0.0" less@2.7.1: version "2.7.1" @@ -13364,11 +13342,6 @@ lodash.mean@^4.1.0: resolved "https://registry.yarnpkg.com/lodash.mean/-/lodash.mean-4.1.0.tgz#bb985349628c0b9d7fe0f5fcc0011a2ee2c0dd7a" integrity sha1-u5hTSWKMC51/4PX8wAEaLuLA3Xo= -lodash.memoize@^4.1.2: - version "4.1.2" - resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe" - integrity sha1-vMbEmkKihA7Zl/Mj6tpezRguC/4= - lodash.merge@^4.4.0: version "4.6.1" resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.1.tgz#adc25d9cb99b9391c59624f379fbba60d7111d54" @@ -13524,11 +13497,6 @@ lodash.union@^4.6.0: resolved "https://registry.yarnpkg.com/lodash.union/-/lodash.union-4.6.0.tgz#48bb5088409f16f1821666641c44dd1aaae3cd88" integrity sha1-SLtQiECfFvGCFmZkHETdGqrjzYg= -lodash.uniq@^4.5.0: - version "4.5.0" - resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" - integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M= - lodash.uniqby@^4.7.0: version "4.7.0" resolved "https://registry.yarnpkg.com/lodash.uniqby/-/lodash.uniqby-4.7.0.tgz#d99c07a669e9e6d24e1362dfe266c67616af1302" @@ -13551,17 +13519,17 @@ lodash@^3.10.0, lodash@^3.10.1, lodash@^3.3.1, lodash@^3.8.0, lodash@~3.10.1: resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" integrity sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y= -lodash@^4, lodash@^4.11.1, lodash@^4.17.2, lodash@^4.3.0, lodash@^4.5.0, lodash@^4.6.1, lodash@^4.8.2, lodash@~4.17.5: - version "4.17.5" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.5.tgz#99a92d65c0272debe8c96b6057bc8fbfa3bed511" - integrity sha512-svL3uiZf1RwhH+cWrfZn3A4+U58wbP0tGVTLQPbjplZxZ8ROD9VLuNgsRniTlLe7OlSqR79RUehXgpBW/s0IQw== - lodash@^4.0.0, lodash@^4.17.5, lodash@^4.2.0, lodash@^4.2.1, lodash@~4.17.10: version "4.17.10" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.10.tgz#1b7793cf7259ea38fb3661d4d38b3260af8ae4e7" integrity sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg== -lodash@^4.17.10: +lodash@^4.11.1, lodash@^4.17.2, lodash@^4.3.0, lodash@^4.5.0, lodash@^4.6.1, lodash@^4.8.2, lodash@~4.17.5: + version "4.17.5" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.5.tgz#99a92d65c0272debe8c96b6057bc8fbfa3bed511" + integrity sha512-svL3uiZf1RwhH+cWrfZn3A4+U58wbP0tGVTLQPbjplZxZ8ROD9VLuNgsRniTlLe7OlSqR79RUehXgpBW/s0IQw== + +lodash@^4.17.10, lodash@^4.17.11: version "4.17.11" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== @@ -13703,7 +13671,7 @@ lru-cache@4.1.1, lru-cache@^4.0.1: pseudomap "^1.0.2" yallist "^2.1.2" -lru-cache@4.1.x, lru-cache@^4.0.0, lru-cache@^4.1.2: +lru-cache@4.1.x, lru-cache@^4.0.0: version "4.1.2" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.2.tgz#45234b2e6e2f2b33da125624c4664929a0224c3f" integrity sha512-wgeVXhrDwAWnIF/yZARsFnMBtdFXOg1b8RIrhilp+0iDYN4mdQcNZElDZ0e4B64BhaxeQ5zN7PMyvu7we1kPeQ== @@ -13711,7 +13679,7 @@ lru-cache@4.1.x, lru-cache@^4.0.0, lru-cache@^4.1.2: pseudomap "^1.0.2" yallist "^2.1.2" -lru-cache@^4.1.1: +lru-cache@^4.1.1, lru-cache@^4.1.3: version "4.1.3" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.3.tgz#a1175cf3496dfc8436c156c334b4955992bce69c" integrity sha512-fFEhvcgzuIoJVUF8fYr5KR0YqxD238zgObTps31YdADwPPAp82a4M8TrckkWyx7ekNlf9aBcVn81cFwwXngrJA== @@ -13724,11 +13692,6 @@ lz-string@^1.4.4: resolved "https://registry.yarnpkg.com/lz-string/-/lz-string-1.4.4.tgz#c0d8eaf36059f705796e1e344811cf4c498d3a26" integrity sha1-wNjq82BZ9wV5bh40SBHPTEmNOiY= -macaddress@^0.2.8: - version "0.2.8" - resolved "https://registry.yarnpkg.com/macaddress/-/macaddress-0.2.8.tgz#5904dc537c39ec6dbefeae902327135fa8511f12" - integrity sha1-WQTcU3w57G2+/q6QIycTX6hRHxI= - macos-release@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/macos-release/-/macos-release-1.1.0.tgz#831945e29365b470aa8724b0ab36c8f8959d10fb" @@ -13785,6 +13748,13 @@ makelogs@^4.3.0: through2 "^2.0.0" update-notifier "^0.5.0" +map-age-cleaner@^0.1.1: + version "0.1.2" + resolved "https://registry.yarnpkg.com/map-age-cleaner/-/map-age-cleaner-0.1.2.tgz#098fb15538fd3dbe461f12745b0ca8568d4e3f74" + integrity sha512-UN1dNocxQq44IhJyMI4TU8phc2m9BddacHRPRjKGLYaF0jqd3xLz0jS0skpAU9WgYyoR4gHtUpzytNBS385FWQ== + dependencies: + p-defer "^1.0.0" + map-cache@^0.2.0, map-cache@^0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" @@ -13828,11 +13798,6 @@ material-colors@^1.2.1: resolved "https://registry.yarnpkg.com/material-colors/-/material-colors-1.2.5.tgz#5292593e6754cb1bcc2b98030e4e0d6a3afc9ea1" integrity sha1-UpJZPmdUyxvMK5gDDk4Najr8nqE= -math-expression-evaluator@^1.2.14: - version "1.2.17" - resolved "https://registry.yarnpkg.com/math-expression-evaluator/-/math-expression-evaluator-1.2.17.tgz#de819fdbcd84dccd8fae59c6aeb79615b9d266ac" - integrity sha1-3oGf282E3M2PrlnGrreWFbnSZqw= - md5.js@^1.3.4: version "1.3.4" resolved "https://registry.yarnpkg.com/md5.js/-/md5.js-1.3.4.tgz#e9bdbde94a20a5ac18b04340fc5764d5b09d901d" @@ -13883,6 +13848,15 @@ mem@^1.1.0: dependencies: mimic-fn "^1.0.0" +mem@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/mem/-/mem-4.0.0.tgz#6437690d9471678f6cc83659c00cbafcd6b0cdaf" + integrity sha512-WQxG/5xYc3tMbYLXoXPm81ET2WDULiU5FxbuIoNbJqLOOI8zehXFdZuiUEgfdrU2mVB1pxBZUGlYORSrpuJreA== + dependencies: + map-age-cleaner "^0.1.1" + mimic-fn "^1.0.0" + p-is-promise "^1.1.0" + memoize-one@^4.0.0: version "4.0.2" resolved "https://registry.yarnpkg.com/memoize-one/-/memoize-one-4.0.2.tgz#3fb8db695aa14ab9c0f1644e1585a8806adc1aee" @@ -14018,6 +13992,25 @@ micromatch@^3.1.4: snapdragon "^0.8.1" to-regex "^3.0.1" +micromatch@^3.1.8, micromatch@^3.1.9: + version "3.1.10" + resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" + integrity sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg== + dependencies: + arr-diff "^4.0.0" + array-unique "^0.3.2" + braces "^2.3.1" + define-property "^2.0.2" + extend-shallow "^3.0.2" + extglob "^2.0.4" + fragment-cache "^0.2.1" + kind-of "^6.0.2" + nanomatch "^1.2.9" + object.pick "^1.3.0" + regex-not "^1.0.0" + snapdragon "^0.8.1" + to-regex "^3.0.2" + miller-rabin@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/miller-rabin/-/miller-rabin-4.0.1.tgz#f080351c865b0dc562a8462966daa53543c78a4d" @@ -14067,22 +14060,17 @@ mime-types@~2.1.11, mime-types@~2.1.19: dependencies: mime-db "~1.36.0" -mime@1.3.x: - version "1.3.6" - resolved "https://registry.yarnpkg.com/mime/-/mime-1.3.6.tgz#591d84d3653a6b0b4a3b9df8de5aa8108e72e5e0" - integrity sha1-WR2E02U6awtKO5343lqoEI5y5eA= - mime@1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/mime/-/mime-1.4.1.tgz#121f9ebc49e3766f311a76e1fa1c8003c4b03aa6" integrity sha512-KI1+qOZu5DcW6wayYHSzR/tXKCDC5Om4s1z2QJjDULzLcmf3DvzS7oluY4HCTrc+9FiKmWUgeNLg7W3uIQvxtQ== -mime@^1.2.11, mime@^1.3.4, mime@^1.4.1, mime@^1.5.0: +mime@^1.2.11, mime@^1.3.4, mime@^1.4.1: version "1.6.0" resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" integrity sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg== -mime@^2.0.3, mime@^2.2.2: +mime@^2.0.3, mime@^2.2.2, mime@^2.3.1: version "2.3.1" resolved "https://registry.yarnpkg.com/mime/-/mime-2.3.1.tgz#b1621c54d63b97c47d3cfe7f7215f7d64517c369" integrity sha512-OEUllcVoydBHGN1z84yfQDimn58pZNNNXgZlHXSboxMlFvgI6MXSWpWKpFRra7H1HxpVhHTkrghfRW49k6yjeg== @@ -14112,6 +14100,15 @@ min-document@^2.19.0: dependencies: dom-walk "^0.1.0" +mini-css-extract-plugin@0.4.4: + version "0.4.4" + resolved "https://registry.yarnpkg.com/mini-css-extract-plugin/-/mini-css-extract-plugin-0.4.4.tgz#c10410a004951bd3cedac1da69053940fccb625d" + integrity sha512-o+Jm+ocb0asEngdM6FsZWtZsRzA8koFUudIDwYUfl94M3PejPHG7Vopw5hN9V8WsMkSFpm3tZP3Fesz89EyrfQ== + dependencies: + loader-utils "^1.1.0" + schema-utils "^1.0.0" + webpack-sources "^1.1.0" + minimalistic-assert@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.0.tgz#702be2dda6b37f4836bcb3f5db56641b64a1d3d3" @@ -14433,11 +14430,6 @@ nan@^2.3.0: resolved "https://registry.yarnpkg.com/nan/-/nan-2.8.0.tgz#ed715f3fe9de02b57a5e6252d90a96675e1f085a" integrity sha1-7XFfP+neArV6XmJS2QqWZ14fCFo= -nan@^2.3.2: - version "2.9.2" - resolved "https://registry.yarnpkg.com/nan/-/nan-2.9.2.tgz#f564d75f5f8f36a6d9456cca7a6c4fe488ab7866" - integrity sha512-ltW65co7f3PQWBDbqVvaU1WtFJUsNW7sWWm4HINhbMQIyVyzIeyZ8toX5TC5eeooE6piZoaEh4cZkueSKG3KYw== - nanomatch@^1.2.5: version "1.2.7" resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.7.tgz#53cd4aa109ff68b7f869591fdc9d10daeeea3e79" @@ -14483,13 +14475,6 @@ natural-compare@^1.4.0: resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= -ncname@1.0.x: - version "1.0.0" - resolved "https://registry.yarnpkg.com/ncname/-/ncname-1.0.0.tgz#5b57ad18b1ca092864ef62b0b1ed8194f383b71c" - integrity sha1-W1etGLHKCShk72Kwse2BlPODtxw= - dependencies: - xml-char-classes "^1.0.0" - ncp@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ncp/-/ncp-2.0.0.tgz#195a21d6c46e361d2fb1281ba38b91e9df7bdbb3" @@ -14627,10 +14612,10 @@ node-forge@0.7.1: resolved "https://registry.yarnpkg.com/node-forge/-/node-forge-0.7.1.tgz#9da611ea08982f4b94206b3beb4cc9665f20c300" integrity sha1-naYR6giYL0uUIGs760zJZl8gwwA= -node-gyp@^3.3.1: - version "3.7.0" - resolved "https://registry.yarnpkg.com/node-gyp/-/node-gyp-3.7.0.tgz#789478e8f6c45e277aa014f3e28f958f286f9203" - integrity sha512-qDQE/Ft9xXP6zphwx4sD0t+VhwV7yFaloMpfbL2QnnDZcyaiakWlLdtFGGQfTAwpFHdpbRhRxVhIHN1OKAjgbg== +node-gyp@^3.8.0: + version "3.8.0" + resolved "https://registry.yarnpkg.com/node-gyp/-/node-gyp-3.8.0.tgz#540304261c330e80d0d5edce253a68cb3964218c" + integrity sha512-3g8lYefrRRzvGeSowdJKAKyks8oUpLEd/DyPV4eMhVlhJ0aNaZqIrNUIPuEWWTAoPqyFkfGrM67MC69baqn6vA== dependencies: fstream "^1.0.0" glob "^7.0.3" @@ -14639,7 +14624,7 @@ node-gyp@^3.3.1: nopt "2 || 3" npmlog "0 || 1 || 2 || 3 || 4" osenv "0" - request ">=2.9.0 <2.82.0" + request "^2.87.0" rimraf "2" semver "~5.3.0" tar "^2.0.0" @@ -14736,34 +14721,10 @@ node-releases@^1.0.0-alpha.11: dependencies: semver "^5.3.0" -node-sass@4.5.3: - version "4.5.3" - resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.5.3.tgz#d09c9d1179641239d1b97ffc6231fdcec53e1568" - integrity sha1-0JydEXlkEjnRuX/8YjH9zsU+FWg= - dependencies: - async-foreach "^0.1.3" - chalk "^1.1.1" - cross-spawn "^3.0.0" - gaze "^1.0.0" - get-stdin "^4.0.1" - glob "^7.0.3" - in-publish "^2.0.0" - lodash.assign "^4.2.0" - lodash.clonedeep "^4.3.2" - lodash.mergewith "^4.6.0" - meow "^3.7.0" - mkdirp "^0.5.1" - nan "^2.3.2" - node-gyp "^3.3.1" - npmlog "^4.0.0" - request "^2.79.0" - sass-graph "^2.1.1" - stdout-stream "^1.4.0" - -node-sass@^4.9.0: - version "4.9.0" - resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.9.0.tgz#d1b8aa855d98ed684d6848db929a20771cc2ae52" - integrity sha512-QFHfrZl6lqRU3csypwviz2XLgGNOoWQbo2GOvtsfQqOfL4cy1BtWnhx/XUeAO9LT3ahBzSRXcEO6DdvAH9DzSg== +node-sass@^4.9.4: + version "4.9.4" + resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.9.4.tgz#349bd7f1c89422ffe7e1e4b60f2055a69fbc5512" + integrity sha512-MXyurANsUoE4/6KmfMkwGcBzAnJQ5xJBGW7Ei6ea8KnUKuzHr/SguVBIi3uaUAHtZCPUYkvlJ3Ef5T5VAwVpaA== dependencies: async-foreach "^0.1.3" chalk "^1.1.1" @@ -14778,9 +14739,9 @@ node-sass@^4.9.0: meow "^3.7.0" mkdirp "^0.5.1" nan "^2.10.0" - node-gyp "^3.3.1" + node-gyp "^3.8.0" npmlog "^4.0.0" - request "~2.79.0" + request "^2.88.0" sass-graph "^2.2.4" stdout-stream "^1.4.0" "true-case-path" "^1.0.2" @@ -14866,16 +14827,6 @@ normalize-url@2.0.1: query-string "^5.0.1" sort-keys "^2.0.0" -normalize-url@^1.4.0: - version "1.9.1" - resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-1.9.1.tgz#2cc0d66b31ea23036458436e3620d85954c66c3c" - integrity sha1-LMDWazHqIwNkWENuNiDYWVTGbDw= - dependencies: - object-assign "^4.0.1" - prepend-http "^1.0.0" - query-string "^4.1.0" - sort-keys "^1.0.0" - now-and-later@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/now-and-later/-/now-and-later-2.0.0.tgz#bc61cbb456d79cb32207ce47ca05136ff2e7d6ee" @@ -15288,19 +15239,19 @@ ordered-read-streams@^1.0.0: dependencies: readable-stream "^2.0.1" -original@>=0.0.5: - version "1.0.0" - resolved "https://registry.yarnpkg.com/original/-/original-1.0.0.tgz#9147f93fa1696d04be61e01bd50baeaca656bd3b" - integrity sha1-kUf5P6FpbQS+YeAb1QuurKZWvTs= +original@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/original/-/original-1.0.2.tgz#e442a61cffe1c5fd20a65f3261c26663b303f25f" + integrity sha512-hyBVl6iqqUOJ8FqRe+l/gS8H+kKYjrEndd5Pm1MfBtsEKA038HkkdbAl/72EAXGyonD/PFsvmVG+EvcIpliMBg== dependencies: - url-parse "1.0.x" + url-parse "^1.4.3" os-browserify@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/os-browserify/-/os-browserify-0.3.0.tgz#854373c7f5c2315914fc9bfc6bd8238fdda1ec27" integrity sha1-hUNzx/XCMVkU/Jv8a9gjj92h7Cc= -os-homedir@^1.0.0, os-homedir@^1.0.1: +os-homedir@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" integrity sha1-/7xJiDNuDoM94MFox+8VISGqf7M= @@ -15321,6 +15272,15 @@ os-locale@^2.0.0: lcid "^1.0.0" mem "^1.1.0" +os-locale@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-3.0.1.tgz#3b014fbf01d87f60a1e5348d80fe870dc82c4620" + integrity sha512-7g5e7dmXPtzcP4bgsZ8ixDVqA7oWYuEz4lOSujeWyliPai4gfVDiFIcwBg3aGCPnmSGfzOKTK3ccPn0CKv3DBw== + dependencies: + execa "^0.10.0" + lcid "^2.0.0" + mem "^4.0.0" + os-name@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/os-name/-/os-name-2.0.1.tgz#b9a386361c17ae3a21736ef0599405c9a8c5dc5e" @@ -15958,6 +15918,13 @@ pkg-dir@^2.0.0: dependencies: find-up "^2.1.0" +pkg-dir@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-3.0.0.tgz#2749020f239ed990881b1f71210d51eb6523bea3" + integrity sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw== + dependencies: + find-up "^3.0.0" + pkg-up@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/pkg-up/-/pkg-up-1.0.0.tgz#3e08fb461525c4421624a33b9f7e6d0af5b05a26" @@ -16067,197 +16034,40 @@ posix-character-classes@^0.1.0: resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= -postcss-calc@^5.2.0: - version "5.3.1" - resolved "https://registry.yarnpkg.com/postcss-calc/-/postcss-calc-5.3.1.tgz#77bae7ca928ad85716e2fda42f261bf7c1d65b5e" - integrity sha1-d7rnypKK2FcW4v2kLyYb98HWW14= +postcss-load-config@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/postcss-load-config/-/postcss-load-config-2.0.0.tgz#f1312ddbf5912cd747177083c5ef7a19d62ee484" + integrity sha512-V5JBLzw406BB8UIfsAWSK2KSwIJ5yoEIVFb4gVkXci0QdKgA24jLmHZ/ghe/GgX0lJ0/D1uUK1ejhzEY94MChQ== dependencies: - postcss "^5.0.2" - postcss-message-helpers "^2.0.0" - reduce-css-calc "^1.2.6" + cosmiconfig "^4.0.0" + import-cwd "^2.0.0" -postcss-colormin@^2.1.8: - version "2.2.2" - resolved "https://registry.yarnpkg.com/postcss-colormin/-/postcss-colormin-2.2.2.tgz#6631417d5f0e909a3d7ec26b24c8a8d1e4f96e4b" - integrity sha1-ZjFBfV8OkJo9fsJrJMio0eT5bks= +postcss-loader@3.0.0, postcss-loader@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/postcss-loader/-/postcss-loader-3.0.0.tgz#6b97943e47c72d845fa9e03f273773d4e8dd6c2d" + integrity sha512-cLWoDEY5OwHcAjDnkyRQzAXfs2jrKjXpO/HQFcc5b5u/r7aa471wdmChmwfnv7x2u840iat/wi0lQ5nbRgSkUA== dependencies: - colormin "^1.0.5" - postcss "^5.0.13" - postcss-value-parser "^3.2.3" + loader-utils "^1.1.0" + postcss "^7.0.0" + postcss-load-config "^2.0.0" + schema-utils "^1.0.0" -postcss-convert-values@^2.3.4: - version "2.6.1" - resolved "https://registry.yarnpkg.com/postcss-convert-values/-/postcss-convert-values-2.6.1.tgz#bbd8593c5c1fd2e3d1c322bb925dcae8dae4d62d" - integrity sha1-u9hZPFwf0uPRwyK7kl3K6Nrk1i0= +postcss-modules-extract-imports@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/postcss-modules-extract-imports/-/postcss-modules-extract-imports-1.2.0.tgz#66140ecece38ef06bf0d3e355d69bf59d141ea85" + integrity sha1-ZhQOzs447wa/DT41XWm/WdFB6oU= dependencies: - postcss "^5.0.11" - postcss-value-parser "^3.1.2" + postcss "^6.0.1" -postcss-discard-comments@^2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/postcss-discard-comments/-/postcss-discard-comments-2.0.4.tgz#befe89fafd5b3dace5ccce51b76b81514be00e3d" - integrity sha1-vv6J+v1bPazlzM5Rt2uBUUvgDj0= +postcss-modules-local-by-default@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/postcss-modules-local-by-default/-/postcss-modules-local-by-default-1.2.0.tgz#f7d80c398c5a393fa7964466bd19500a7d61c069" + integrity sha1-99gMOYxaOT+nlkRmvRlQCn1hwGk= dependencies: - postcss "^5.0.14" + css-selector-tokenizer "^0.7.0" + postcss "^6.0.1" -postcss-discard-duplicates@^2.0.1: - version "2.1.0" - resolved "https://registry.yarnpkg.com/postcss-discard-duplicates/-/postcss-discard-duplicates-2.1.0.tgz#b9abf27b88ac188158a5eb12abcae20263b91932" - integrity sha1-uavye4isGIFYpesSq8riAmO5GTI= - dependencies: - postcss "^5.0.4" - -postcss-discard-empty@^2.0.1: - version "2.1.0" - resolved "https://registry.yarnpkg.com/postcss-discard-empty/-/postcss-discard-empty-2.1.0.tgz#d2b4bd9d5ced5ebd8dcade7640c7d7cd7f4f92b5" - integrity sha1-0rS9nVztXr2Nyt52QMfXzX9PkrU= - dependencies: - postcss "^5.0.14" - -postcss-discard-overridden@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/postcss-discard-overridden/-/postcss-discard-overridden-0.1.1.tgz#8b1eaf554f686fb288cd874c55667b0aa3668d58" - integrity sha1-ix6vVU9ob7KIzYdMVWZ7CqNmjVg= - dependencies: - postcss "^5.0.16" - -postcss-discard-unused@^2.2.1: - version "2.2.3" - resolved "https://registry.yarnpkg.com/postcss-discard-unused/-/postcss-discard-unused-2.2.3.tgz#bce30b2cc591ffc634322b5fb3464b6d934f4433" - integrity sha1-vOMLLMWR/8Y0Mitfs0ZLbZNPRDM= - dependencies: - postcss "^5.0.14" - uniqs "^2.0.0" - -postcss-filter-plugins@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/postcss-filter-plugins/-/postcss-filter-plugins-2.0.2.tgz#6d85862534d735ac420e4a85806e1f5d4286d84c" - integrity sha1-bYWGJTTXNaxCDkqFgG4fXUKG2Ew= - dependencies: - postcss "^5.0.4" - uniqid "^4.0.0" - -postcss-load-config@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/postcss-load-config/-/postcss-load-config-1.2.0.tgz#539e9afc9ddc8620121ebf9d8c3673e0ce50d28a" - integrity sha1-U56a/J3chiASHr+djDZz4M5Q0oo= - dependencies: - cosmiconfig "^2.1.0" - object-assign "^4.1.0" - postcss-load-options "^1.2.0" - postcss-load-plugins "^2.3.0" - -postcss-load-options@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/postcss-load-options/-/postcss-load-options-1.2.0.tgz#b098b1559ddac2df04bc0bb375f99a5cfe2b6d8c" - integrity sha1-sJixVZ3awt8EvAuzdfmaXP4rbYw= - dependencies: - cosmiconfig "^2.1.0" - object-assign "^4.1.0" - -postcss-load-plugins@^2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/postcss-load-plugins/-/postcss-load-plugins-2.3.0.tgz#745768116599aca2f009fad426b00175049d8d92" - integrity sha1-dFdoEWWZrKLwCfrUJrABdQSdjZI= - dependencies: - cosmiconfig "^2.1.1" - object-assign "^4.1.0" - -postcss-loader@2.0.6: - version "2.0.6" - resolved "https://registry.yarnpkg.com/postcss-loader/-/postcss-loader-2.0.6.tgz#8c7e0055a3df1889abc6bad52dd45b2f41bbc6fc" - integrity sha512-HIq7yy1hh9KI472Y38iSRV4WupZUNy6zObkxQM/ZuInoaE2+PyX4NcO6jjP5HG5mXL7j5kcNEl0fAG4Kva7O9w== - dependencies: - loader-utils "^1.1.0" - postcss "^6.0.2" - postcss-load-config "^1.2.0" - schema-utils "^0.3.0" - -postcss-merge-idents@^2.1.5: - version "2.1.7" - resolved "https://registry.yarnpkg.com/postcss-merge-idents/-/postcss-merge-idents-2.1.7.tgz#4c5530313c08e1d5b3bbf3d2bbc747e278eea270" - integrity sha1-TFUwMTwI4dWzu/PSu8dH4njuonA= - dependencies: - has "^1.0.1" - postcss "^5.0.10" - postcss-value-parser "^3.1.1" - -postcss-merge-longhand@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/postcss-merge-longhand/-/postcss-merge-longhand-2.0.2.tgz#23d90cd127b0a77994915332739034a1a4f3d658" - integrity sha1-I9kM0Sewp3mUkVMyc5A0oaTz1lg= - dependencies: - postcss "^5.0.4" - -postcss-merge-rules@^2.0.3: - version "2.1.2" - resolved "https://registry.yarnpkg.com/postcss-merge-rules/-/postcss-merge-rules-2.1.2.tgz#d1df5dfaa7b1acc3be553f0e9e10e87c61b5f721" - integrity sha1-0d9d+qexrMO+VT8OnhDofGG19yE= - dependencies: - browserslist "^1.5.2" - caniuse-api "^1.5.2" - postcss "^5.0.4" - postcss-selector-parser "^2.2.2" - vendors "^1.0.0" - -postcss-message-helpers@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/postcss-message-helpers/-/postcss-message-helpers-2.0.0.tgz#a4f2f4fab6e4fe002f0aed000478cdf52f9ba60e" - integrity sha1-pPL0+rbk/gAvCu0ABHjN9S+bpg4= - -postcss-minify-font-values@^1.0.2: - version "1.0.5" - resolved "https://registry.yarnpkg.com/postcss-minify-font-values/-/postcss-minify-font-values-1.0.5.tgz#4b58edb56641eba7c8474ab3526cafd7bbdecb69" - integrity sha1-S1jttWZB66fIR0qzUmyv17vey2k= - dependencies: - object-assign "^4.0.1" - postcss "^5.0.4" - postcss-value-parser "^3.0.2" - -postcss-minify-gradients@^1.0.1: - version "1.0.5" - resolved "https://registry.yarnpkg.com/postcss-minify-gradients/-/postcss-minify-gradients-1.0.5.tgz#5dbda11373703f83cfb4a3ea3881d8d75ff5e6e1" - integrity sha1-Xb2hE3NwP4PPtKPqOIHY11/15uE= - dependencies: - postcss "^5.0.12" - postcss-value-parser "^3.3.0" - -postcss-minify-params@^1.0.4: - version "1.2.2" - resolved "https://registry.yarnpkg.com/postcss-minify-params/-/postcss-minify-params-1.2.2.tgz#ad2ce071373b943b3d930a3fa59a358c28d6f1f3" - integrity sha1-rSzgcTc7lDs9kwo/pZo1jCjW8fM= - dependencies: - alphanum-sort "^1.0.1" - postcss "^5.0.2" - postcss-value-parser "^3.0.2" - uniqs "^2.0.0" - -postcss-minify-selectors@^2.0.4: - version "2.1.1" - resolved "https://registry.yarnpkg.com/postcss-minify-selectors/-/postcss-minify-selectors-2.1.1.tgz#b2c6a98c0072cf91b932d1a496508114311735bf" - integrity sha1-ssapjAByz5G5MtGkllCBFDEXNb8= - dependencies: - alphanum-sort "^1.0.2" - has "^1.0.1" - postcss "^5.0.14" - postcss-selector-parser "^2.0.0" - -postcss-modules-extract-imports@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/postcss-modules-extract-imports/-/postcss-modules-extract-imports-1.1.0.tgz#b614c9720be6816eaee35fb3a5faa1dba6a05ddb" - integrity sha1-thTJcgvmgW6u41+zpfqh26agXds= - dependencies: - postcss "^6.0.1" - -postcss-modules-local-by-default@^1.0.1: - version "1.2.0" - resolved "https://registry.yarnpkg.com/postcss-modules-local-by-default/-/postcss-modules-local-by-default-1.2.0.tgz#f7d80c398c5a393fa7964466bd19500a7d61c069" - integrity sha1-99gMOYxaOT+nlkRmvRlQCn1hwGk= - dependencies: - css-selector-tokenizer "^0.7.0" - postcss "^6.0.1" - -postcss-modules-scope@^1.0.0: +postcss-modules-scope@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/postcss-modules-scope/-/postcss-modules-scope-1.1.0.tgz#d6ea64994c79f97b62a72b426fbe6056a194bb90" integrity sha1-1upkmUx5+XtipytCb75gVqGUu5A= @@ -16265,7 +16075,7 @@ postcss-modules-scope@^1.0.0: css-selector-tokenizer "^0.7.0" postcss "^6.0.1" -postcss-modules-values@^1.1.0: +postcss-modules-values@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/postcss-modules-values/-/postcss-modules-values-1.3.0.tgz#ecffa9d7e192518389f42ad0e83f72aec456ea20" integrity sha1-7P+p1+GSUYOJ9CrQ6D9yrsRW6iA= @@ -16273,98 +16083,12 @@ postcss-modules-values@^1.1.0: icss-replace-symbols "^1.1.0" postcss "^6.0.1" -postcss-normalize-charset@^1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/postcss-normalize-charset/-/postcss-normalize-charset-1.1.1.tgz#ef9ee71212d7fe759c78ed162f61ed62b5cb93f1" - integrity sha1-757nEhLX/nWceO0WL2HtYrXLk/E= - dependencies: - postcss "^5.0.5" - -postcss-normalize-url@^3.0.7: - version "3.0.8" - resolved "https://registry.yarnpkg.com/postcss-normalize-url/-/postcss-normalize-url-3.0.8.tgz#108f74b3f2fcdaf891a2ffa3ea4592279fc78222" - integrity sha1-EI90s/L82viRov+j6kWSJ5/HgiI= - dependencies: - is-absolute-url "^2.0.0" - normalize-url "^1.4.0" - postcss "^5.0.14" - postcss-value-parser "^3.2.3" - -postcss-ordered-values@^2.1.0: - version "2.2.3" - resolved "https://registry.yarnpkg.com/postcss-ordered-values/-/postcss-ordered-values-2.2.3.tgz#eec6c2a67b6c412a8db2042e77fe8da43f95c11d" - integrity sha1-7sbCpntsQSqNsgQud/6NpD+VwR0= - dependencies: - postcss "^5.0.4" - postcss-value-parser "^3.0.1" - -postcss-reduce-idents@^2.2.2: - version "2.4.0" - resolved "https://registry.yarnpkg.com/postcss-reduce-idents/-/postcss-reduce-idents-2.4.0.tgz#c2c6d20cc958284f6abfbe63f7609bf409059ad3" - integrity sha1-wsbSDMlYKE9qv75j92Cb9AkFmtM= - dependencies: - postcss "^5.0.4" - postcss-value-parser "^3.0.2" - -postcss-reduce-initial@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/postcss-reduce-initial/-/postcss-reduce-initial-1.0.1.tgz#68f80695f045d08263a879ad240df8dd64f644ea" - integrity sha1-aPgGlfBF0IJjqHmtJA343WT2ROo= - dependencies: - postcss "^5.0.4" - -postcss-reduce-transforms@^1.0.3: - version "1.0.4" - resolved "https://registry.yarnpkg.com/postcss-reduce-transforms/-/postcss-reduce-transforms-1.0.4.tgz#ff76f4d8212437b31c298a42d2e1444025771ae1" - integrity sha1-/3b02CEkN7McKYpC0uFEQCV3GuE= - dependencies: - has "^1.0.1" - postcss "^5.0.8" - postcss-value-parser "^3.0.1" - -postcss-selector-parser@^2.0.0, postcss-selector-parser@^2.2.2: - version "2.2.3" - resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-2.2.3.tgz#f9437788606c3c9acee16ffe8d8b16297f27bb90" - integrity sha1-+UN3iGBsPJrO4W/+jYsWKX8nu5A= - dependencies: - flatten "^1.0.2" - indexes-of "^1.0.1" - uniq "^1.0.1" - -postcss-svgo@^2.1.1: - version "2.1.6" - resolved "https://registry.yarnpkg.com/postcss-svgo/-/postcss-svgo-2.1.6.tgz#b6df18aa613b666e133f08adb5219c2684ac108d" - integrity sha1-tt8YqmE7Zm4TPwittSGcJoSsEI0= - dependencies: - is-svg "^2.0.0" - postcss "^5.0.14" - postcss-value-parser "^3.2.3" - svgo "^0.7.0" - -postcss-unique-selectors@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/postcss-unique-selectors/-/postcss-unique-selectors-2.0.2.tgz#981d57d29ddcb33e7b1dfe1fd43b8649f933ca1d" - integrity sha1-mB1X0p3csz57Hf4f1DuGSfkzyh0= - dependencies: - alphanum-sort "^1.0.1" - postcss "^5.0.4" - uniqs "^2.0.0" - -postcss-value-parser@^3.0.1, postcss-value-parser@^3.0.2, postcss-value-parser@^3.1.1, postcss-value-parser@^3.1.2, postcss-value-parser@^3.2.3, postcss-value-parser@^3.3.0: +postcss-value-parser@^3.2.3, postcss-value-parser@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-3.3.0.tgz#87f38f9f18f774a4ab4c8a232f5c5ce8872a9d15" integrity sha1-h/OPnxj3dKSrTIojL1xc6IcqnRU= -postcss-zindex@^2.0.1: - version "2.2.0" - resolved "https://registry.yarnpkg.com/postcss-zindex/-/postcss-zindex-2.2.0.tgz#d2109ddc055b91af67fc4cb3b025946639d2af22" - integrity sha1-0hCd3AVbka9n/EyzsCWUZjnSryI= - dependencies: - has "^1.0.1" - postcss "^5.0.4" - uniqs "^2.0.0" - -postcss@^5.0.10, postcss@^5.0.11, postcss@^5.0.12, postcss@^5.0.13, postcss@^5.0.14, postcss@^5.0.16, postcss@^5.0.2, postcss@^5.0.4, postcss@^5.0.5, postcss@^5.0.6, postcss@^5.0.8, postcss@^5.2.16, postcss@^5.2.6: +postcss@^5.2.6: version "5.2.18" resolved "https://registry.yarnpkg.com/postcss/-/postcss-5.2.18.tgz#badfa1497d46244f6390f58b319830d9107853c5" integrity sha512-zrUjRRe1bpXKsX1qAJNJjqZViErVuyEkMTRrwu4ud4sbTtIBRmtaYDrHmcGgmrbsW3MHfmtIf+vJumgQn+PrXg== @@ -16374,7 +16098,7 @@ postcss@^5.0.10, postcss@^5.0.11, postcss@^5.0.12, postcss@^5.0.13, postcss@^5.0 source-map "^0.5.6" supports-color "^3.2.3" -postcss@^6.0.1, postcss@^6.0.2: +postcss@^6.0.1: version "6.0.19" resolved "https://registry.yarnpkg.com/postcss/-/postcss-6.0.19.tgz#76a78386f670b9d9494a655bf23ac012effd1555" integrity sha512-f13HRz0HtVwVaEuW6J6cOUCBLFtymhgyLPV7t4QEk2UD3twRI9IluDcQNdzQdBpiixkXj2OmzejhhTbSbDxNTg== @@ -16383,6 +16107,24 @@ postcss@^6.0.1, postcss@^6.0.2: source-map "^0.6.1" supports-color "^5.2.0" +postcss@^6.0.23: + version "6.0.23" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-6.0.23.tgz#61c82cc328ac60e677645f979054eb98bc0e3324" + integrity sha512-soOk1h6J3VMTZtVeVpv15/Hpdl2cBLX3CAw4TAbkpTJiNPk9YP/zWcD1ND+xEtvyuuvKzbxliTOIyvkSeSJ6ag== + dependencies: + chalk "^2.4.1" + source-map "^0.6.1" + supports-color "^5.4.0" + +postcss@^7.0.0, postcss@^7.0.5: + version "7.0.5" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.5.tgz#70e6443e36a6d520b0fd4e7593fcca3635ee9f55" + integrity sha512-HBNpviAUFCKvEh7NZhw1e8MBPivRszIiUnhrJ+sBFVSYSqubrzwX3KG51mYgcRHX8j/cAgZJedONZcm5jTBdgQ== + dependencies: + chalk "^2.4.1" + source-map "^0.6.1" + supports-color "^5.5.0" + postcss@^7.0.2: version "7.0.2" resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.2.tgz#7b5a109de356804e27f95a960bef0e4d5bc9bb18" @@ -16450,7 +16192,7 @@ prismjs@0.0.1: resolved "https://registry.yarnpkg.com/prismjs/-/prismjs-0.0.1.tgz#0fd50f4baf26e5cd33523b65bac2f0bc90f5503f" integrity sha1-D9UPS68m5c0zUjtlusLwvJD1UD8= -private@^0.1.6, private@^0.1.7, private@~0.1.5: +private@^0.1.6, private@^0.1.7, private@^0.1.8, private@~0.1.5: version "0.1.8" resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff" integrity sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg== @@ -16548,13 +16290,13 @@ proto-list@~1.2.1: resolved "https://registry.yarnpkg.com/proto-list/-/proto-list-1.2.4.tgz#212d5bfe1318306a420f6402b8e26ff39647a849" integrity sha1-IS1b/hMYMGpCD2QCuOJv85ZHqEk= -proxy-addr@~2.0.2: - version "2.0.3" - resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.3.tgz#355f262505a621646b3130a728eb647e22055341" - integrity sha512-jQTChiCJteusULxjBp8+jftSQE5Obdl3k4cnmLA6WXtK6XFuWRnvVL7aCiBqaLPM8c4ph0S4tKna8XvmIwEnXQ== +proxy-addr@~2.0.4: + version "2.0.4" + resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.4.tgz#ecfc733bf22ff8c6f407fa275327b9ab67e48b93" + integrity sha512-5erio2h9jp5CHGwcybmxmVqHmnCBZeewlfJ0pex+UW7Qny7OOZXTtH56TGNyBizkgiOwhJtMKrVzDTeKcySZwA== dependencies: forwarded "~0.1.2" - ipaddr.js "1.6.0" + ipaddr.js "1.8.0" proxy-from-env@1.0.0, proxy-from-env@^1.0.0: version "1.0.0" @@ -16820,22 +16562,17 @@ qs@6.5.1, qs@^6.0.2, qs@^6.5.1, qs@~6.5.1: resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" integrity sha512-eRzhrN1WSINYCDCbrz796z37LOe3m5tmW7RQf6oBntukAG1nmovJvhnwHHRMAfeoItc1m2Hk02WER2aQ/iqs+A== -qs@^6.4.0, qs@~6.5.2: +qs@6.5.2, qs@^6.4.0, qs@~6.5.2: version "6.5.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== -qs@~6.3.0: - version "6.3.2" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.3.2.tgz#e75bd5f6e268122a2a0e0bda630b2550c166502c" - integrity sha1-51vV9uJoEioqDgvaYwslUMFmUCw= - qs@~6.4.0: version "6.4.0" resolved "https://registry.yarnpkg.com/qs/-/qs-6.4.0.tgz#13e26d28ad6b0ffaa91312cd3bf708ed351e7233" integrity sha1-E+JtKK1rD/qpExLNO/cI7TUecjM= -query-string@^4.1.0, query-string@^4.2.2: +query-string@^4.2.2: version "4.3.4" resolved "https://registry.yarnpkg.com/query-string/-/query-string-4.3.4.tgz#bbb693b9ca915c232515b228b1a02b609043dbeb" integrity sha1-u7aTucqRXCMlFbIosaArYJBD2+s= @@ -16867,15 +16604,10 @@ querystring@0.2.0: resolved "https://registry.yarnpkg.com/querystring/-/querystring-0.2.0.tgz#b209849203bb25df820da756e747005878521620" integrity sha1-sgmEkgO7Jd+CDadW50cAWHhSFiA= -querystringify@0.0.x: - version "0.0.4" - resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-0.0.4.tgz#0cf7f84f9463ff0ae51c4c4b142d95be37724d9c" - integrity sha1-DPf4T5Rj/wrlHExLFC2VvjdyTZw= - -querystringify@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-1.0.0.tgz#6286242112c5b712fa654e526652bf6a13ff05cb" - integrity sha1-YoYkIRLFtxL6ZU5SZlK/ahP/Bcs= +querystringify@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.1.0.tgz#7ded8dfbf7879dcc60d0a644ac6754b283ad17ef" + integrity sha512-sluvZZ1YiTLD5jsqZcDmFyV2EwToyXZBfpoVOmktMmW+VEnhgakFHnasVph65fOjGPTWN0Nw3+XQaSeMayr0kg== quick-lru@^1.0.0: version "1.1.0" @@ -16967,6 +16699,16 @@ raw-body@2.3.2: iconv-lite "0.4.19" unpipe "1.0.0" +raw-body@2.3.3: + version "2.3.3" + resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.3.3.tgz#1b324ece6b5706e153855bc1148c65bb7f6ea0c3" + integrity sha512-9esiElv1BrZoI3rCDuOuKCBRbuApGGaDPQfjSflGxdy4oyzqghxu6klEkkVIvBje+FF0BX9coEv8KqW6X/7njw== + dependencies: + bytes "3.0.0" + http-errors "1.6.3" + iconv-lite "0.4.23" + unpipe "1.0.0" + raw-body@~1.1.0: version "1.1.7" resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-1.1.7.tgz#1d027c2bfa116acc6623bca8f00016572a87d425" @@ -16975,7 +16717,7 @@ raw-body@~1.1.0: bytes "1" string_decoder "0.10" -raw-loader@0.5.1, raw-loader@~0.5.1: +raw-loader@0.5.1, raw-loader@^0.5.1, raw-loader@~0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/raw-loader/-/raw-loader-0.5.1.tgz#0c3d0beaed8a01c966d9787bf778281252a979aa" integrity sha1-DD0L6u2KAclm2Xh793goElKpeao= @@ -17734,22 +17476,6 @@ redent@^2.0.0: indent-string "^3.0.0" strip-indent "^2.0.0" -reduce-css-calc@^1.2.6: - version "1.3.0" - resolved "https://registry.yarnpkg.com/reduce-css-calc/-/reduce-css-calc-1.3.0.tgz#747c914e049614a4c9cfbba629871ad1d2927716" - integrity sha1-dHyRTgSWFKTJz7umKYca0dKSdxY= - dependencies: - balanced-match "^0.4.2" - math-expression-evaluator "^1.2.14" - reduce-function-call "^1.0.1" - -reduce-function-call@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/reduce-function-call/-/reduce-function-call-1.0.2.tgz#5a200bf92e0e37751752fe45b0ab330fd4b6be99" - integrity sha1-WiAL+S4ON3UXUv5FsKszD9S2vpk= - dependencies: - balanced-match "^0.4.2" - reduce-reducers@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/reduce-reducers/-/reduce-reducers-0.1.2.tgz#fa1b4718bc5292a71ddd1e5d839c9bea9770f14b" @@ -17875,6 +17601,14 @@ regex-not@^1.0.0: dependencies: extend-shallow "^2.0.1" +regex-not@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" + integrity sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A== + dependencies: + extend-shallow "^3.0.2" + safe-regex "^1.1.0" + regexpp@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-2.0.0.tgz#b2a7534a85ca1b033bcf5ce9ff8e56d4e0755365" @@ -18072,7 +17806,7 @@ request-promise-native@^1.0.3, request-promise-native@^1.0.5: stealthy-require "^1.1.0" tough-cookie ">=2.3.3" -request@2.81.0, "request@>=2.9.0 <2.82.0": +request@2.81.0: version "2.81.0" resolved "https://registry.yarnpkg.com/request/-/request-2.81.0.tgz#c6928946a0e06c5f8d6f8a9333469ffda46298a0" integrity sha1-xpKJRqDgbF+Nb4qTM0af/aRimKA= @@ -18154,7 +17888,7 @@ request@^2.65.0: tunnel-agent "^0.6.0" uuid "^3.1.0" -request@^2.74.0, request@^2.79.0, request@^2.83.0: +request@^2.74.0, request@^2.83.0: version "2.83.0" resolved "https://registry.yarnpkg.com/request/-/request-2.83.0.tgz#ca0b65da02ed62935887808e6f510381034e3356" integrity sha512-lR3gD69osqm6EYLk9wB/G1W/laGWjzH90t1vEa2xuxHD5KUrSzp9pUSfTm+YC5Nxt2T8nMPEvKlhbQayU7bgFw== @@ -18208,41 +17942,15 @@ request@^2.88.0: tunnel-agent "^0.6.0" uuid "^3.3.2" -request@~2.79.0: - version "2.79.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.79.0.tgz#4dfe5bf6be8b8cdc37fcf93e04b65577722710de" - integrity sha1-Tf5b9r6LjNw3/Pk+BLZVd3InEN4= - dependencies: - aws-sign2 "~0.6.0" - aws4 "^1.2.1" - caseless "~0.11.0" - combined-stream "~1.0.5" - extend "~3.0.0" - forever-agent "~0.6.1" - form-data "~2.1.1" - har-validator "~2.0.6" - hawk "~3.1.3" - http-signature "~1.1.0" - is-typedarray "~1.0.0" - isstream "~0.1.2" - json-stringify-safe "~5.0.1" - mime-types "~2.1.7" - oauth-sign "~0.8.1" - qs "~6.3.0" - stringstream "~0.0.4" - tough-cookie "~2.3.0" - tunnel-agent "~0.4.1" - uuid "^3.0.0" - require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= -require-from-string@^1.1.0: - version "1.2.1" - resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-1.2.1.tgz#529c9ccef27380adfec9a2f965b649bbee636418" - integrity sha1-UpyczvJzgK3+yaL5ZbZJu+5jZBg= +require-from-string@^2.0.1: + version "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-main-filename@^1.0.1: version "1.0.1" @@ -18264,7 +17972,7 @@ requirefresh@^2.0.0: dependencies: editions "^1.1.1" -requires-port@1.0.x, requires-port@1.x.x, requires-port@~1.0.0: +requires-port@1.x.x, requires-port@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" integrity sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8= @@ -18540,7 +18248,7 @@ safe-buffer@5.1.1, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, s resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" integrity sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg== -safe-buffer@^5.1.2: +safe-buffer@5.1.2, safe-buffer@^5.1.2: version "5.1.2" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== @@ -18550,6 +18258,13 @@ safe-json-parse@~1.0.1: resolved "https://registry.yarnpkg.com/safe-json-parse/-/safe-json-parse-1.0.1.tgz#3e76723e38dfdda13c9b1d29a1e07ffee4b30b57" integrity sha1-PnZyPjjf3aE8mx0poeB//uSzC1c= +safe-regex@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/safe-regex/-/safe-regex-1.1.0.tgz#40a3669f3b077d1e943d44629e157dd48023bf2e" + integrity sha1-QKNmnzsHfR6UPURinhV91IAjvy4= + dependencies: + ret "~0.1.10" + safefs@^4.0.0: version "4.1.0" resolved "https://registry.yarnpkg.com/safefs/-/safefs-4.1.0.tgz#f82aeb4bdd7ae51f653eb20f6728b3058c8d6445" @@ -18610,7 +18325,7 @@ sao@^0.22.12: user-home "^2.0.0" yarn-install "^0.5.1" -sass-graph@^2.1.1, sass-graph@^2.2.4: +sass-graph@^2.2.4: version "2.2.4" resolved "https://registry.yarnpkg.com/sass-graph/-/sass-graph-2.2.4.tgz#13fbd63cd1caf0908b9fd93476ad43a51d1e0b49" integrity sha1-E/vWPNHK8JCLn9k0dq1DpR0eC0k= @@ -18620,17 +18335,6 @@ sass-graph@^2.1.1, sass-graph@^2.2.4: scss-tokenizer "^0.2.3" yargs "^7.0.0" -sass-loader@6.0.6: - version "6.0.6" - resolved "https://registry.yarnpkg.com/sass-loader/-/sass-loader-6.0.6.tgz#e9d5e6c1f155faa32a4b26d7a9b7107c225e40f9" - integrity sha512-c3/Zc+iW+qqDip6kXPYLEgsAu2lf4xz0EZDplB7EmSUMda12U1sGJPetH55B/j9eu0bTtKzKlNPWWyYC7wFNyQ== - dependencies: - async "^2.1.5" - clone-deep "^0.3.0" - loader-utils "^1.0.1" - lodash.tail "^4.1.1" - pify "^3.0.0" - sass-loader@^7.1.0: version "7.1.0" resolved "https://registry.yarnpkg.com/sass-loader/-/sass-loader-7.1.0.tgz#16fd5138cb8b424bf8a759528a1972d72aad069d" @@ -18665,7 +18369,7 @@ schema-utils@^0.3.0: dependencies: ajv "^5.0.0" -schema-utils@^0.4.0, schema-utils@^0.4.5: +schema-utils@^0.4.0, schema-utils@^0.4.2, schema-utils@^0.4.4, schema-utils@^0.4.5: version "0.4.7" resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-0.4.7.tgz#ba74f597d2be2ea880131746ee17d0a093c68187" integrity sha512-v/iwU6wvwGK8HbU9yi3/nhGzP0yGSuhQMzL6ySiec1FSrZZDkhm4noOSWzrNFo/jEc+SJY6jRTwuwbSXJPDUnQ== @@ -18673,6 +18377,15 @@ schema-utils@^0.4.0, schema-utils@^0.4.5: ajv "^6.1.0" ajv-keywords "^3.1.0" +schema-utils@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-1.0.0.tgz#0b79a93204d7b600d4b2850d1f66c2a34951c770" + integrity sha512-i27Mic4KovM/lnGsy8whRCHhc7VicJajAjTrYg11K9zfZXnYIt4k5F+kZkwjnrhKzLic/HLU4j11mjsz2G/75g== + dependencies: + ajv "^6.1.0" + ajv-errors "^1.0.0" + ajv-keywords "^3.1.0" + scoped-regex@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/scoped-regex/-/scoped-regex-1.0.0.tgz#a346bb1acd4207ae70bd7c0c7ca9e566b6baddb8" @@ -18776,25 +18489,6 @@ semver@~5.3.0: resolved "https://registry.yarnpkg.com/semver/-/semver-5.3.0.tgz#9b2ce5d3de02d17c6012ad326aa6b4d0cf54f94f" integrity sha1-myzl094C0XxgEq0yaqa00M9U+U8= -send@0.16.1: - version "0.16.1" - resolved "https://registry.yarnpkg.com/send/-/send-0.16.1.tgz#a70e1ca21d1382c11d0d9f6231deb281080d7ab3" - integrity sha512-ElCLJdJIKPk6ux/Hocwhk7NFHpI3pVm/IZOYWqUmoxcgeyM+MpxHHKhb8QmlJDX1pU6WrgaHBkVNm73Sv7uc2A== - dependencies: - debug "2.6.9" - depd "~1.1.1" - destroy "~1.0.4" - encodeurl "~1.0.1" - escape-html "~1.0.3" - etag "~1.8.1" - fresh "0.5.2" - http-errors "~1.6.2" - mime "1.4.1" - ms "2.0.0" - on-finished "~2.3.0" - range-parser "~1.2.0" - statuses "~1.3.1" - send@0.16.2: version "0.16.2" resolved "https://registry.yarnpkg.com/send/-/send-0.16.2.tgz#6ecca1e0f8c156d141597559848df64730a6bbc1" @@ -18845,15 +18539,15 @@ serve-index@^1.7.2: mime-types "~2.1.17" parseurl "~1.3.2" -serve-static@1.13.1: - version "1.13.1" - resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.13.1.tgz#4c57d53404a761d8f2e7c1e8a18a47dbf278a719" - integrity sha512-hSMUZrsPa/I09VYFJwa627JJkNs0NrfL1Uzuup+GqHfToR2KcsXFymXSV90hoyw3M+msjFuQly+YzIH/q0MGlQ== +serve-static@1.13.2: + version "1.13.2" + resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.13.2.tgz#095e8472fd5b46237db50ce486a43f4b86c6cec1" + integrity sha512-p/tdJrO4U387R9oMjb1oj7qSMaMfmOyd4j9hOFoxZe2baQszgHcSWjuya/CiT5kgZZKRudHNOA0pYXOl8rQ5nw== dependencies: - encodeurl "~1.0.1" + encodeurl "~1.0.2" escape-html "~1.0.3" parseurl "~1.3.2" - send "0.16.1" + send "0.16.2" serve@^6.3.1: version "6.5.2" @@ -18943,16 +18637,6 @@ sha.js@^2.4.0, sha.js@^2.4.8: inherits "^2.0.1" safe-buffer "^5.0.1" -shallow-clone@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/shallow-clone/-/shallow-clone-0.1.2.tgz#5909e874ba77106d73ac414cfec1ffca87d97060" - integrity sha1-WQnodLp3EG1zrEFM/sH/yofZcGA= - dependencies: - is-extendable "^0.1.1" - kind-of "^2.0.1" - lazy-cache "^0.2.3" - mixin-object "^2.0.1" - shallow-clone@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/shallow-clone/-/shallow-clone-1.0.0.tgz#4480cd06e882ef68b2ad88a3ea54832e2c48b571" @@ -19220,32 +18904,25 @@ socket.io@^2.1.1: socket.io-client "2.1.1" socket.io-parser "~3.2.0" -sockjs-client@1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/sockjs-client/-/sockjs-client-1.1.4.tgz#5babe386b775e4cf14e7520911452654016c8b12" - integrity sha1-W6vjhrd15M8U51IJEUUmVAFsixI= +sockjs-client@1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/sockjs-client/-/sockjs-client-1.3.0.tgz#12fc9d6cb663da5739d3dc5fb6e8687da95cb177" + integrity sha512-R9jxEzhnnrdxLCNln0xg5uGHqMnkhPSTzUZH2eXcR03S/On9Yvoq2wyUZILRUhZCNVu2PmwWVoyuiPz8th8zbg== dependencies: - debug "^2.6.6" - eventsource "0.1.6" - faye-websocket "~0.11.0" - inherits "^2.0.1" + debug "^3.2.5" + eventsource "^1.0.7" + faye-websocket "~0.11.1" + inherits "^2.0.3" json3 "^3.3.2" - url-parse "^1.1.8" + url-parse "^1.4.3" -sockjs@0.3.18: - version "0.3.18" - resolved "https://registry.yarnpkg.com/sockjs/-/sockjs-0.3.18.tgz#d9b289316ca7df77595ef299e075f0f937eb4207" - integrity sha1-2bKJMWyn33dZXvKZ4HXw+TfrQgc= +sockjs@0.3.19: + version "0.3.19" + resolved "https://registry.yarnpkg.com/sockjs/-/sockjs-0.3.19.tgz#d976bbe800af7bd20ae08598d582393508993c0d" + integrity sha512-V48klKZl8T6MzatbLlzzRNhMepEys9Y4oGFpypBFFn1gLI/QQ9HtLLyWJNbPlwGLelOVOEijUbTTJeLLI59jLw== dependencies: faye-websocket "^0.10.0" - uuid "^2.0.2" - -sort-keys@^1.0.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/sort-keys/-/sort-keys-1.1.2.tgz#441b6d4d346798f1b4e49e8920adfba0e543f9ad" - integrity sha1-RBttTTRnmPG05J6JIK37oOVD+a0= - dependencies: - is-plain-obj "^1.0.0" + uuid "^3.0.1" sort-keys@^2.0.0: version "2.0.0" @@ -19299,7 +18976,7 @@ source-map-resolve@^0.5.2: source-map-url "^0.4.0" urix "^0.1.0" -source-map-support@^0.4.15, source-map-support@^0.4.2: +source-map-support@^0.4.15: version "0.4.18" resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.4.18.tgz#0286a6de8be42641338594e97ccea75f0a2c585f" integrity sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA== @@ -19342,7 +19019,7 @@ source-map@0.X: resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.2.tgz#115c3e891aaa9a484869fd2b89391a225feba344" integrity sha512-NDJB/R2BS7YJG0tP9SbE4DKwKj1idLT5RJqfVYZ7dreFX7wulZT3xxVhbYKrQo9n0JkRptl51TrX/5VK3HodMA== -"source-map@>= 0.1.2", source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: +"source-map@>= 0.1.2", source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.0, source-map@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== @@ -19591,6 +19268,11 @@ static-module@^1.1.0: resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.4.0.tgz#bb73d446da2796106efcc1b601a253d6c46bd087" integrity sha512-zhSCtt8v2NDrRlPQpCNtw/heZLtfUDqxBM1udqikb/Hbk52LK4nQSwr10u77iopCW5LsyHpuXS0GnEc48mLeew== +"statuses@>= 1.4.0 < 2": + version "1.5.0" + resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" + integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= + statuses@~1.3.1: version "1.3.1" resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.3.1.tgz#faf51b9eb74aaef3b3acf4ad5f61abf24cb7b93e" @@ -19682,13 +19364,13 @@ string-length@^2.0.0: astral-regex "^1.0.0" strip-ansi "^4.0.0" -string-replace-loader@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/string-replace-loader/-/string-replace-loader-1.3.0.tgz#1d404a7bf5e2ec21b08ffc76d89445fbe49bc01d" - integrity sha512-zj8J2ELc5HWOYFkS3MaRMgaHu+mPTG/EfHHaFesJqXjpaKOAruaONEWt3/Em5Urc6n8qDlvabIN6umiU8lH4QA== +string-replace-loader@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/string-replace-loader/-/string-replace-loader-2.1.1.tgz#b72e7b57b6ef04efe615aff0ad989b5c14ca63d1" + integrity sha512-0Nvw1LDclF45AFNuYPcD2Jvkv0mwb/dQSnJZMvhqGrT+zzmrpG3OJFD600qfQfNUd5aqfp7fCm2mQMfF7zLbyQ== dependencies: loader-utils "^1.1.0" - lodash "^4" + schema-utils "^0.4.5" string-similarity@1.2.0: version "1.2.0" @@ -19738,7 +19420,12 @@ string_decoder@~1.1.1: dependencies: safe-buffer "~5.1.0" -stringstream@~0.0.4, stringstream@~0.0.5: +stringstream@~0.0.4: + version "0.0.6" + resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.6.tgz#7880225b0d4ad10e30927d167a1d6f2fd3b33a72" + integrity sha512-87GEBAkegbBcweToUrdzf3eLhWNg06FJTebl4BVJz/JgWy8CvEr9dRtX5qWphiynMSQlxxi+QqN0z5T32SLlhA== + +stringstream@~0.0.5: version "0.0.5" resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.5.tgz#4e484cd4de5a0bbbee18e46307710a8a81621878" integrity sha1-TkhM1N5aC7vuGORjB3EKioFiGHg= @@ -19845,13 +19532,13 @@ style-it@^1.6.12: dependencies: react-lib-adler32 "^1.0.0" -style-loader@0.19.0: - version "0.19.0" - resolved "https://registry.yarnpkg.com/style-loader/-/style-loader-0.19.0.tgz#7258e788f0fee6a42d710eaf7d6c2412a4c50759" - integrity sha512-9mx9sC9nX1dgP96MZOODpGC6l1RzQBITI2D5WJhu+wnbrSYVKLGuy14XJSLVQih/0GFrPpjelt+s//VcZQ2Evw== +style-loader@0.23.1, style-loader@^0.23.1: + version "0.23.1" + resolved "https://registry.yarnpkg.com/style-loader/-/style-loader-0.23.1.tgz#cb9154606f3e771ab6c4ab637026a1049174d925" + integrity sha512-XK+uv9kWwhZMZ1y7mysB+zoihsEj4wneFWAS5qoiLwzW0WzSqMrrsIy+a3zkQJq0ipFtBpX5W3MqyRIBF/WFGg== dependencies: - loader-utils "^1.0.2" - schema-utils "^0.3.0" + loader-utils "^1.1.0" + schema-utils "^1.0.0" styled-components@3.3.3: version "3.3.3" @@ -19970,7 +19657,7 @@ supports-color@^3.1.0, supports-color@^3.1.2, supports-color@^3.2.3: dependencies: has-flag "^1.0.0" -supports-color@^4.0.0, supports-color@^4.2.1: +supports-color@^4.0.0: version "4.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-4.5.0.tgz#be7a0de484dec5c5cddf8b3d59125044912f635b" integrity sha1-vnoN5ITexcXN34s9WRJQRJEvY1s= @@ -19998,7 +19685,7 @@ supports-color@^5.4.0, supports-color@^5.5.0: dependencies: has-flag "^3.0.0" -svgo@^0.7.0, svgo@^0.7.2: +svgo@^0.7.2: version "0.7.2" resolved "https://registry.yarnpkg.com/svgo/-/svgo-0.7.2.tgz#9f5772413952135c6fefbf40afe6a4faa88b4bb5" integrity sha1-n1dyQTlSE1xv779Ar+ak+qiLS7U= @@ -20086,10 +19773,10 @@ tapable@^0.1.8: resolved "https://registry.npmjs.org/tapable/-/tapable-0.1.10.tgz#29c35707c2b70e50d07482b5d202e8ed446dafd4" integrity sha1-KcNXB8K3DlDQdIK10gLo7URtr9Q= -tapable@^0.2.7: - version "0.2.8" - resolved "https://registry.yarnpkg.com/tapable/-/tapable-0.2.8.tgz#99372a5c999bf2df160afc0d74bed4f47948cd22" - integrity sha1-mTcqXJmb8t8WCvwNdL7U9HlIzSI= +tapable@^1.0.0, tapable@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/tapable/-/tapable-1.1.0.tgz#0d076a172e3d9ba088fd2272b2668fb8d194b78c" + integrity sha512-IlqtmLVaZA2qab8epUXbVWRn3aB1imbDMJtjB3nu4X0NqPkcY/JH9ZtCBWKHWPxs8Svi9tyo8w2dBoi07qZbBA== tar-fs@1.13.0: version "1.13.0" @@ -20308,7 +19995,7 @@ through2@~0.4.1: readable-stream "~1.0.17" xtend "~2.1.1" -"through@>=2.2.7 <3", through@^2.3.4, through@^2.3.6, through@^2.3.8, through@~2.3.4, through@~2.3.6: +through@^2.3.4, through@^2.3.6, through@^2.3.8, through@~2.3.4, through@~2.3.6: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= @@ -20335,11 +20022,6 @@ time-stamp@^1.0.0: resolved "https://registry.yarnpkg.com/time-stamp/-/time-stamp-1.1.0.tgz#764a5a11af50561921b133f3b44e618687e0f5c3" integrity sha1-dkpaEa9QVhkhsTPztE5hhofg9cM= -time-stamp@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/time-stamp/-/time-stamp-2.0.0.tgz#95c6a44530e15ba8d6f4a3ecb8c3a3fac46da357" - integrity sha1-lcakRTDhW6jW9KPsuMOj+sRto1c= - timed-out@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/timed-out/-/timed-out-2.0.0.tgz#f38b0ae81d3747d628001f41dafc652ace671c0a" @@ -20517,6 +20199,16 @@ to-regex@^3.0.1: extend-shallow "^2.0.1" regex-not "^1.0.0" +to-regex@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/to-regex/-/to-regex-3.0.2.tgz#13cfdd9b336552f30b51f33a8ae1b42a7a7599ce" + integrity sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw== + dependencies: + define-property "^2.0.2" + extend-shallow "^3.0.2" + regex-not "^1.0.2" + safe-regex "^1.1.0" + to-through@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/to-through/-/to-through-2.0.0.tgz#fc92adaba072647bc0b67d6b03664aa195093af6" @@ -20667,13 +20359,13 @@ ts-jest@^23.1.4: json5 "^0.5.0" lodash "^4.17.10" -ts-loader@^3.5.0: - version "3.5.0" - resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-3.5.0.tgz#151d004dcddb4cf8e381a3bf9d6b74c2d957a9c0" - integrity sha512-JTia3kObhTk36wPFgy0RnkZReiusYx7Le9IhcUWRrCTcFcr6Dy1zGsFd3x8DG4gevlbN65knI8W50FfoykXcng== +ts-loader@^5.2.2: + version "5.2.2" + resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-5.2.2.tgz#a707849b08ca754cc46f5c7053e79fe1c84caf0e" + integrity sha512-vM/TrEKXBqRYq5yLatsXyKFnYSpv53klmGtrILGlNqcMsxPVi8+e4yr1Agbu9oMZepx/4szDVn5QpFo83IQdQg== dependencies: chalk "^2.3.0" - enhanced-resolve "^3.0.0" + enhanced-resolve "^4.0.0" loader-utils "^1.0.2" micromatch "^3.1.4" semver "^5.0.1" @@ -20757,11 +20449,6 @@ tunnel-agent@^0.6.0: dependencies: safe-buffer "^5.0.1" -tunnel-agent@~0.4.1: - version "0.4.3" - resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.4.3.tgz#6373db76909fe570e08d73583365ed828a74eeeb" - integrity sha1-Y3PbdpCf5XDgjXNYM2Xtgop07us= - tunnel@^0.0.5: version "0.0.5" resolved "https://registry.yarnpkg.com/tunnel/-/tunnel-0.0.5.tgz#d1532254749ed36620fcd1010865495a1fa9d0ae" @@ -20803,7 +20490,7 @@ type-detect@^4.0.5, type-detect@^4.0.8: resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== -type-is@~1.6.15: +type-is@~1.6.15, type-is@~1.6.16: version "1.6.16" resolved "https://registry.yarnpkg.com/type-is/-/type-is-1.6.16.tgz#f89ce341541c672b25ee7ae3c73dee3b2be50194" integrity sha512-HRkVv/5qY2G6I8iab9cI7v1bOIdhm94dVjQCPFElW9W+3GeDOSHmy2EBYe4VTApuzolPcmgFTN3ftVJRKR2J9Q== @@ -20858,15 +20545,15 @@ uglify-es@^3.3.4: commander "~2.13.0" source-map "~0.6.1" -uglify-js@3.3.x: - version "3.3.13" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.3.13.tgz#8a1a89eeb16e2d6a66b0db2b04cb871af3c669cf" - integrity sha512-7rdn/bDOG1ElSTPdh7AI5TCjLv63ZD4k8BBadN3ssIkhlaQL2c0yRxmXCyOYhZK0wZTgGgUSnYQ4CGu+Jos5cA== +uglify-js@3.4.x, uglify-js@^3.1.4: + version "3.4.9" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.4.9.tgz#af02f180c1207d76432e473ed24a28f4a782bae3" + integrity sha512-8CJsbKOtEbnJsTyv6LE6m6ZKniqMiFWmm9sRbopbkGs3gMPPfd3Fh8iIA4Ykv5MgaTbqHr4BaoGLJLZNhsrW1Q== dependencies: - commander "~2.14.1" + commander "~2.17.1" source-map "~0.6.1" -uglify-js@^2.6, uglify-js@^2.6.1, uglify-js@^2.8.29: +uglify-js@^2.6, uglify-js@^2.6.1: version "2.8.29" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.29.tgz#29c5733148057bb4e1f75df35b7a9cb72e6a59dd" integrity sha1-KcVzMUgFe7Th913zW3qcty5qWd0= @@ -20876,27 +20563,24 @@ uglify-js@^2.6, uglify-js@^2.6.1, uglify-js@^2.8.29: optionalDependencies: uglify-to-browserify "~1.0.0" -uglify-js@^3.1.4: - version "3.4.9" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.4.9.tgz#af02f180c1207d76432e473ed24a28f4a782bae3" - integrity sha512-8CJsbKOtEbnJsTyv6LE6m6ZKniqMiFWmm9sRbopbkGs3gMPPfd3Fh8iIA4Ykv5MgaTbqHr4BaoGLJLZNhsrW1Q== - dependencies: - commander "~2.17.1" - source-map "~0.6.1" - uglify-to-browserify@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz#6e0924d6bda6b5afe349e39a6d632850a0f882b7" integrity sha1-bgkk1r2mta/jSeOabWMoUKD4grc= -uglifyjs-webpack-plugin@^0.4.6: - version "0.4.6" - resolved "https://registry.yarnpkg.com/uglifyjs-webpack-plugin/-/uglifyjs-webpack-plugin-0.4.6.tgz#b951f4abb6bd617e66f63eb891498e391763e309" - integrity sha1-uVH0q7a9YX5m9j64kUmOORdj4wk= +uglifyjs-webpack-plugin@^1.2.4: + version "1.3.0" + resolved "https://registry.yarnpkg.com/uglifyjs-webpack-plugin/-/uglifyjs-webpack-plugin-1.3.0.tgz#75f548160858163a08643e086d5fefe18a5d67de" + integrity sha512-ovHIch0AMlxjD/97j9AYovZxG5wnHOPkL7T1GKochBADp/Zwc44pEWNqpKl1Loupp1WhFg7SlYmHZRUfdAacgw== dependencies: - source-map "^0.5.6" - uglify-js "^2.8.29" - webpack-sources "^1.0.1" + cacache "^10.0.4" + find-cache-dir "^1.0.0" + schema-utils "^0.4.5" + serialize-javascript "^1.4.0" + source-map "^0.6.1" + uglify-es "^3.3.4" + webpack-sources "^1.1.0" + worker-farm "^1.5.2" uglifyjs-webpack-plugin@^1.2.7: version "1.2.7" @@ -21056,23 +20740,6 @@ union-value@^1.0.0: is-extendable "^0.1.1" set-value "^0.4.3" -uniq@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/uniq/-/uniq-1.0.1.tgz#b31c5ae8254844a3a8281541ce2b04b865a734ff" - integrity sha1-sxxa6CVIRKOoKBVBzisEuGWnNP8= - -uniqid@^4.0.0: - version "4.1.1" - resolved "https://registry.yarnpkg.com/uniqid/-/uniqid-4.1.1.tgz#89220ddf6b751ae52b5f72484863528596bb84c1" - integrity sha1-iSIN32t1GuUrX3JISGNShZa7hME= - dependencies: - macaddress "^0.2.8" - -uniqs@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/uniqs/-/uniqs-2.0.0.tgz#ffede4b36b25290696e6e165d4a59edb998e6b02" - integrity sha1-/+3ks2slKQaW5uFl1KWe25mOawI= - unique-filename@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/unique-filename/-/unique-filename-1.1.1.tgz#1d69769369ada0583103a1e6ae87681b56573230" @@ -21238,13 +20905,14 @@ url-join@^4.0.0: resolved "https://registry.yarnpkg.com/url-join/-/url-join-4.0.0.tgz#4d3340e807d3773bda9991f8305acdcc2a665d2a" integrity sha1-TTNA6AfTdzvamZH4MFrNzCpmXSo= -url-loader@0.5.9: - version "0.5.9" - resolved "https://registry.yarnpkg.com/url-loader/-/url-loader-0.5.9.tgz#cc8fea82c7b906e7777019250869e569e995c295" - integrity sha512-B7QYFyvv+fOBqBVeefsxv6koWWtjmHaMFT6KZWti4KRw8YUD/hOU+3AECvXuzyVawIBx3z7zQRejXCDSO5kk1Q== +url-loader@1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/url-loader/-/url-loader-1.1.2.tgz#b971d191b83af693c5e3fea4064be9e1f2d7f8d8" + integrity sha512-dXHkKmw8FhPqu8asTc1puBfe3TehOCo2+RmOOev5suNCIYBcT626kxiWg1NBVkwc4rO8BGa7gP70W7VXuqHrjg== dependencies: - loader-utils "^1.0.2" - mime "1.3.x" + loader-utils "^1.1.0" + mime "^2.0.3" + schema-utils "^1.0.0" url-parse-lax@^1.0.0: version "1.0.0" @@ -21260,21 +20928,13 @@ url-parse-lax@^3.0.0: dependencies: prepend-http "^2.0.0" -url-parse@1.0.x: - version "1.0.5" - resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.0.5.tgz#0854860422afdcfefeb6c965c662d4800169927b" - integrity sha1-CFSGBCKv3P7+tsllxmLUgAFpkns= - dependencies: - querystringify "0.0.x" - requires-port "1.0.x" - -url-parse@^1.1.8: - version "1.2.0" - resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.2.0.tgz#3a19e8aaa6d023ddd27dcc44cb4fc8f7fec23986" - integrity sha512-DT1XbYAfmQP65M/mE6OALxmXzZ/z1+e5zk2TcSKe/KiYbNGZxgtttzC0mR/sjopbpOXcbniq7eIKmocJnUWlEw== +url-parse@^1.4.3: + version "1.4.4" + resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.4.4.tgz#cac1556e95faa0303691fec5cf9d5a1bc34648f8" + integrity sha512-/92DTTorg4JjktLNLe6GPS2/RvAd/RGr6LuktmWSMLEOa6rjnlrFXNgSbSmkNvCoL2T028A0a1JaJLzRMlFoHg== dependencies: - querystringify "~1.0.0" - requires-port "~1.0.0" + querystringify "^2.0.0" + requires-port "^1.0.0" url-pattern@^1.0.3: version "1.0.3" @@ -21370,7 +21030,7 @@ uuid@3.0.1: resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.0.1.tgz#6544bba2dfda8c1cf17e629a3a305e2bb1fee6c1" integrity sha1-ZUS7ot/ajBzxfmKaOjBeK7H+5sE= -uuid@^2.0.1, uuid@^2.0.2: +uuid@^2.0.1: version "2.0.3" resolved "https://registry.yarnpkg.com/uuid/-/uuid-2.0.3.tgz#67e2e863797215530dff318e5bf9dcebfd47b21a" integrity sha1-Z+LoY3lyFVMN/zGOW/nc6/1Hsho= @@ -21380,11 +21040,16 @@ uuid@^3.0.0: resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04" integrity sha512-DIWtzUkw04M4k3bf1IcpS2tngXEL26YUD2M0tMDUpnUrz2hgzUBlD55a4FjdLGPvfHxS6uluGWvaVEqgBcVa+g== -uuid@^3.1.0, uuid@^3.3.2: +uuid@^3.0.1, uuid@^3.1.0, uuid@^3.3.2: version "3.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== +v8-compile-cache@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.0.2.tgz#a428b28bb26790734c4fc8bc9fa106fccebf6a6c" + integrity sha512-1wFuMUIM16MDJRCrpbpuEPTUGmM5QMUg0cr3KFwra2XgOgFcPGDQHDh3CszSCD2Zewc/dh/pamNEW8CbfDebUw== + v8flags@^2.0.2, v8flags@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-2.1.1.tgz#aab1a1fa30d45f88dd321148875ac02c0b55e5b4" @@ -21392,12 +21057,13 @@ v8flags@^2.0.2, v8flags@^2.1.1: dependencies: user-home "^1.1.1" -val-loader@^1.1.0: - version "1.1.0" - resolved "https://registry.npmjs.org/val-loader/-/val-loader-1.1.0.tgz#ed91537424d62a4ded98e846ccf07367756bf506" - integrity sha512-8m62XF42FcfrBBl02rtDY9hQhDcDczrEcr60/aSMxlzJiXAcbAimRPvsDoDa5QcGAusOgOmVTpFtK5EbfZdDwA== +val-loader@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/val-loader/-/val-loader-1.1.1.tgz#32ba8ed5c3607504134977251db2966499e15ef7" + integrity sha512-JLqLXJWCVLXTxbUeHhLpWkgl3+X3U8Bl0vY7rTFZgFSbLJaEtAxuD2ixy/cM8w/gzC7sS3NE5IDSzClDt332sw== dependencies: loader-utils "^1.0.0" + schema-utils "^0.4.5" valid-url@1.0.9: version "1.0.9" @@ -21704,11 +21370,6 @@ vega-wordcloud@^2.1: vega-statistics "^1.2" vega-util "1" -vendors@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/vendors/-/vendors-1.0.1.tgz#37ad73c8ee417fb3d580e785312307d274847f22" - integrity sha1-N61zyO5Bf7PVgOeFMSMH0nSEfyI= - venn.js@0.2.9: version "0.2.9" resolved "https://registry.yarnpkg.com/venn.js/-/venn.js-0.2.9.tgz#33c29075efa484731d59d884752900cc33033656" @@ -21966,10 +21627,10 @@ watch@~0.18.0: exec-sh "^0.2.0" minimist "^1.2.0" -watchpack@^1.4.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-1.5.0.tgz#231e783af830a22f8966f65c4c4bacc814072eed" - integrity sha512-RSlipNQB1u48cq0wH/BNfCu1tD/cJ8ydFIkNYhp9o+3d+8unClkIovpW5qpFPgmL9OE48wfAnlZydXByWP82AA== +watchpack@^1.5.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-1.6.0.tgz#4bc12c2ebe8aa277a71f1d3f14d685c7b446cd00" + integrity sha512-i6dHe3EyLjMmDlU1/bGQpEw25XSjkJULPuAVKCbNRefQVq48yXKUpwg538F7AZTf9kyr57zj++pQFltUa5H7yA== dependencies: chokidar "^2.0.2" graceful-fs "^4.1.2" @@ -21994,55 +21655,82 @@ webidl-conversions@^4.0.1, webidl-conversions@^4.0.2: resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" integrity sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg== -webpack-dev-middleware@^1.11.0: - version "1.12.2" - resolved "https://registry.yarnpkg.com/webpack-dev-middleware/-/webpack-dev-middleware-1.12.2.tgz#f8fc1120ce3b4fc5680ceecb43d777966b21105e" - integrity sha512-FCrqPy1yy/sN6U/SaEZcHKRXGlqU0DUaEBL45jkUYoB8foVb6wCnbIJ1HKIx+qUFTW+3JpVcCJCxZ8VATL4e+A== +webpack-cli@^3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/webpack-cli/-/webpack-cli-3.1.2.tgz#17d7e01b77f89f884a2bbf9db545f0f6a648e746" + integrity sha512-Cnqo7CeqeSvC6PTdts+dywNi5CRlIPbLx1AoUPK2T6vC1YAugMG3IOoO9DmEscd+Dghw7uRlnzV1KwOe5IrtgQ== + dependencies: + chalk "^2.4.1" + cross-spawn "^6.0.5" + enhanced-resolve "^4.1.0" + global-modules-path "^2.3.0" + import-local "^2.0.0" + interpret "^1.1.0" + loader-utils "^1.1.0" + supports-color "^5.5.0" + v8-compile-cache "^2.0.2" + yargs "^12.0.2" + +webpack-dev-middleware@3.4.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/webpack-dev-middleware/-/webpack-dev-middleware-3.4.0.tgz#1132fecc9026fd90f0ecedac5cbff75d1fb45890" + integrity sha512-Q9Iyc0X9dP9bAsYskAVJ/hmIZZQwf/3Sy4xCAZgL5cUkjZmUZLt4l5HpbST/Pdgjn3u6pE7u5OdGd1apgzRujA== dependencies: memory-fs "~0.4.1" - mime "^1.5.0" - path-is-absolute "^1.0.0" + mime "^2.3.1" range-parser "^1.0.3" - time-stamp "^2.0.0" + webpack-log "^2.0.0" -webpack-dev-server@2.9.1: - version "2.9.1" - resolved "https://registry.yarnpkg.com/webpack-dev-server/-/webpack-dev-server-2.9.1.tgz#7ac9320b61b00eb65b2109f15c82747fc5b93585" - integrity sha512-qFKs4Wg6JI6FkAQ6WFqeDCCxXEBLsDHkqJB3f9tmlqx8C68Y9vQWwcaMT4Q9H8WF32Q6QUNmgK4qQkdHfXvj/g== +webpack-dev-server@^3.1.10: + version "3.1.10" + resolved "https://registry.yarnpkg.com/webpack-dev-server/-/webpack-dev-server-3.1.10.tgz#507411bee727ee8d2fdffdc621b66a64ab3dea2b" + integrity sha512-RqOAVjfqZJtQcB0LmrzJ5y4Jp78lv9CK0MZ1YJDTaTmedMZ9PU9FLMQNrMCfVu8hHzaVLVOJKBlGEHMN10z+ww== dependencies: ansi-html "0.0.7" - array-includes "^3.0.3" bonjour "^3.5.0" - chokidar "^1.6.0" + chokidar "^2.0.0" compression "^1.5.2" connect-history-api-fallback "^1.3.0" + debug "^3.1.0" del "^3.0.0" - express "^4.13.3" + express "^4.16.2" html-entities "^1.2.0" - http-proxy-middleware "~0.17.4" - internal-ip "1.2.0" + http-proxy-middleware "~0.18.0" + import-local "^2.0.0" + internal-ip "^3.0.1" ip "^1.1.5" + killable "^1.0.0" loglevel "^1.4.1" opn "^5.1.0" portfinder "^1.0.9" + schema-utils "^1.0.0" selfsigned "^1.9.1" serve-index "^1.7.2" - sockjs "0.3.18" - sockjs-client "1.1.4" + sockjs "0.3.19" + sockjs-client "1.3.0" spdy "^3.4.1" - strip-ansi "^3.0.1" - supports-color "^4.2.1" - webpack-dev-middleware "^1.11.0" - yargs "^6.6.0" + strip-ansi "^3.0.0" + supports-color "^5.1.0" + webpack-dev-middleware "3.4.0" + webpack-log "^2.0.0" + yargs "12.0.2" -webpack-merge@4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/webpack-merge/-/webpack-merge-4.1.0.tgz#6ad72223b3e0b837e531e4597c199f909361511e" - integrity sha1-atciI7PguDflMeRZfBmfkJNhUR4= +webpack-log@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/webpack-log/-/webpack-log-2.0.0.tgz#5b7928e0637593f119d32f6227c1e0ac31e1b47f" + integrity sha512-cX8G2vR/85UYG59FgkoMamwHUIkSSlV3bBMRsbxVXVUk2j6NleCKjQ/WE9eYg9WY4w25O9w8wKP4rzNZFmUcUg== dependencies: - lodash "^4.17.4" + ansi-colors "^3.0.0" + uuid "^3.3.2" + +webpack-merge@4.1.4: + version "4.1.4" + resolved "https://registry.yarnpkg.com/webpack-merge/-/webpack-merge-4.1.4.tgz#0fde38eabf2d5fd85251c24a5a8c48f8a3f4eb7b" + integrity sha512-TmSe1HZKeOPey3oy1Ov2iS3guIZjWvMT2BBJDzzT5jScHTjVC3mpjJofgueEzaEd6ibhxRDD6MIblDr8tzh8iQ== + dependencies: + lodash "^4.17.5" -webpack-sources@^1.0.1, webpack-sources@^1.1.0: +webpack-sources@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-1.1.0.tgz#a101ebae59d6507354d71d8013950a3a8b7a5a54" integrity sha512-aqYp18kPphgoO5c/+NaUvEeACtZjMESmDChuD3NBciVpah3XpMEU9VAAtIaB1BsfJWWTSdv8Vv1m3T0aRk2dUw== @@ -22050,61 +21738,43 @@ webpack-sources@^1.0.1, webpack-sources@^1.1.0: source-list-map "^2.0.0" source-map "~0.6.1" -webpack@3.6.0: - version "3.6.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-3.6.0.tgz#a89a929fbee205d35a4fa2cc487be9cbec8898bc" - integrity sha512-OsHT3D0W0KmPPh60tC7asNnOmST6bKTiR90UyEdT9QYoaJ4OYN4Gg7WK1k3VxHK07ZoiYWPsKvlS/gAjwL/vRA== - dependencies: - acorn "^5.0.0" - acorn-dynamic-import "^2.0.0" - ajv "^5.1.5" - ajv-keywords "^2.0.0" - async "^2.1.2" - enhanced-resolve "^3.4.0" - escope "^3.6.0" - interpret "^1.0.0" - json-loader "^0.5.4" - json5 "^0.5.1" - loader-runner "^2.3.0" - loader-utils "^1.1.0" - memory-fs "~0.4.1" - mkdirp "~0.5.0" - node-libs-browser "^2.0.0" - source-map "^0.5.3" - supports-color "^4.2.1" - tapable "^0.2.7" - uglifyjs-webpack-plugin "^0.4.6" - watchpack "^1.4.0" - webpack-sources "^1.0.1" - yargs "^8.0.2" - -webpack@^3.11.0: - version "3.11.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-3.11.0.tgz#77da451b1d7b4b117adaf41a1a93b5742f24d894" - integrity sha512-3kOFejWqj5ISpJk4Qj/V7w98h9Vl52wak3CLiw/cDOfbVTq7FeoZ0SdoHHY9PYlHr50ZS42OfvzE2vB4nncKQg== +webpack-sources@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-1.3.0.tgz#2a28dcb9f1f45fe960d8f1493252b5ee6530fa85" + integrity sha512-OiVgSrbGu7NEnEvQJJgdSFPl2qWKkWq5lHMhgiToIiN9w34EBnjYzSYs+VbL5KoYiLNtFFa7BZIKxRED3I32pA== dependencies: - acorn "^5.0.0" - acorn-dynamic-import "^2.0.0" + source-list-map "^2.0.0" + source-map "~0.6.1" + +webpack@4.23.1, webpack@^4.23.1: + version "4.23.1" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.23.1.tgz#db7467b116771ae020c58bdfe2a0822785bb8239" + integrity sha512-iE5Cu4rGEDk7ONRjisTOjVHv3dDtcFfwitSxT7evtYj/rANJpt1OuC/Kozh1pBa99AUBr1L/LsaNB+D9Xz3CEg== + dependencies: + "@webassemblyjs/ast" "1.7.10" + "@webassemblyjs/helper-module-context" "1.7.10" + "@webassemblyjs/wasm-edit" "1.7.10" + "@webassemblyjs/wasm-parser" "1.7.10" + acorn "^5.6.2" + acorn-dynamic-import "^3.0.0" ajv "^6.1.0" ajv-keywords "^3.1.0" - async "^2.1.2" - enhanced-resolve "^3.4.0" - escope "^3.6.0" - interpret "^1.0.0" - json-loader "^0.5.4" - json5 "^0.5.1" + chrome-trace-event "^1.0.0" + enhanced-resolve "^4.1.0" + eslint-scope "^4.0.0" + json-parse-better-errors "^1.0.2" loader-runner "^2.3.0" loader-utils "^1.1.0" memory-fs "~0.4.1" + micromatch "^3.1.8" mkdirp "~0.5.0" + neo-async "^2.5.0" node-libs-browser "^2.0.0" - source-map "^0.5.3" - supports-color "^4.2.1" - tapable "^0.2.7" - uglifyjs-webpack-plugin "^0.4.6" - watchpack "^1.4.0" - webpack-sources "^1.0.1" - yargs "^8.0.2" + schema-utils "^0.4.4" + tapable "^1.1.0" + uglifyjs-webpack-plugin "^1.2.4" + watchpack "^1.5.0" + webpack-sources "^1.3.0" websocket-driver@>=0.5.1: version "0.7.0" @@ -22440,11 +22110,6 @@ xhr@^2.0.1: parse-headers "^2.0.0" xtend "^4.0.0" -xml-char-classes@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/xml-char-classes/-/xml-char-classes-1.0.0.tgz#64657848a20ffc5df583a42ad8a277b4512bbc4d" - integrity sha1-ZGV4SKIP/F31g6Qq2KJ3tFErvE0= - xml-crypto@^0.10.1: version "0.10.1" resolved "https://registry.yarnpkg.com/xml-crypto/-/xml-crypto-0.10.1.tgz#f832f74ccf56f24afcae1163a1fcab44d96774a8" @@ -22580,13 +22245,6 @@ yargs-parser@^2.4.1: camelcase "^3.0.0" lodash.assign "^4.0.6" -yargs-parser@^4.2.0: - version "4.2.1" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-4.2.1.tgz#29cceac0dc4f03c6c87b4a9f217dd18c9f74871c" - integrity sha1-KczqwNxPA8bIe0qfIX3RjJ90hxw= - dependencies: - camelcase "^3.0.0" - yargs-parser@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-5.0.0.tgz#275ecf0d7ffe05c77e64e7c86e4cd94bf0e1228a" @@ -22594,13 +22252,6 @@ yargs-parser@^5.0.0: dependencies: camelcase "^3.0.0" -yargs-parser@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-7.0.0.tgz#8d0ac42f16ea55debd332caf4c4038b3e3f5dfd9" - integrity sha1-jQrELxbqVd69MyyvTEA4s+P139k= - dependencies: - camelcase "^4.1.0" - yargs-parser@^9.0.2: version "9.0.2" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-9.0.2.tgz#9ccf6a43460fe4ed40a9bb68f48d43b8a68cc077" @@ -22608,6 +22259,24 @@ yargs-parser@^9.0.2: dependencies: camelcase "^4.1.0" +yargs@12.0.2, yargs@^12.0.2: + version "12.0.2" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-12.0.2.tgz#fe58234369392af33ecbef53819171eff0f5aadc" + integrity sha512-e7SkEx6N6SIZ5c5H22RTZae61qtn3PYUE8JYbBFlK9sYmh3DMQ6E5ygtaG/2BW0JZi4WGgTR2IV5ChqlqrDGVQ== + dependencies: + cliui "^4.0.0" + decamelize "^2.0.0" + find-up "^3.0.0" + get-caller-file "^1.0.1" + os-locale "^3.0.0" + require-directory "^2.1.1" + require-main-filename "^1.0.1" + set-blocking "^2.0.0" + string-width "^2.0.0" + which-module "^2.0.0" + y18n "^3.2.1 || ^4.0.0" + yargs-parser "^10.1.0" + yargs@4.8.1: version "4.8.1" resolved "https://registry.yarnpkg.com/yargs/-/yargs-4.8.1.tgz#c0c42924ca4aaa6b0e6da1739dfb216439f9ddc0" @@ -22664,25 +22333,6 @@ yargs@^12.0.1: y18n "^3.2.1 || ^4.0.0" yargs-parser "^10.1.0" -yargs@^6.6.0: - version "6.6.0" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-6.6.0.tgz#782ec21ef403345f830a808ca3d513af56065208" - integrity sha1-eC7CHvQDNF+DCoCMo9UTr1YGUgg= - dependencies: - camelcase "^3.0.0" - cliui "^3.2.0" - decamelize "^1.1.1" - get-caller-file "^1.0.1" - os-locale "^1.4.0" - read-pkg-up "^1.0.1" - require-directory "^2.1.1" - require-main-filename "^1.0.1" - set-blocking "^2.0.0" - string-width "^1.0.2" - which-module "^1.0.0" - y18n "^3.2.1" - yargs-parser "^4.2.0" - yargs@^7.0.0: version "7.1.0" resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.0.tgz#6ba318eb16961727f5d284f8ea003e8d6154d0c8" @@ -22702,25 +22352,6 @@ yargs@^7.0.0: y18n "^3.2.1" yargs-parser "^5.0.0" -yargs@^8.0.2: - version "8.0.2" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-8.0.2.tgz#6299a9055b1cefc969ff7e79c1d918dceb22c360" - integrity sha1-YpmpBVsc78lp/355wdkY3Osiw2A= - dependencies: - camelcase "^4.1.0" - cliui "^3.2.0" - decamelize "^1.1.1" - get-caller-file "^1.0.1" - os-locale "^2.0.0" - read-pkg-up "^2.0.0" - require-directory "^2.1.1" - require-main-filename "^1.0.1" - set-blocking "^2.0.0" - string-width "^2.0.0" - which-module "^2.0.0" - y18n "^3.2.1" - yargs-parser "^7.0.0" - yargs@~1.2.6: version "1.2.6" resolved "https://registry.yarnpkg.com/yargs/-/yargs-1.2.6.tgz#9c7b4a82fd5d595b2bf17ab6dcc43135432fe34b"