Skip to content

Commit

Permalink
Merge branch 'master' into design/update-loading-spinner
Browse files Browse the repository at this point in the history
  • Loading branch information
elasticmachine authored Dec 19, 2019
2 parents 5132e1b + ba7589d commit 026ec32
Show file tree
Hide file tree
Showing 409 changed files with 8,111 additions and 4,377 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/pr-project-assigner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ jobs:
uses: elastic/github-actions/project-assigner@v1.0.0
id: project_assigner
with:
issue-mappings: '[{"label": "Team:AppAch", "projectName": "kibana-app-arch", "columnId": 6173897}]'
ghToken: ${{ secrets.GITHUB_TOKEN }}
issue-mappings: '[{"label": "Team:AppArch", "projectName": "kibana-app-arch", "columnId": 6173897}, {"label": "Feature:Lens", "projectName": "Lens", "columnId": 6219362}]'
ghToken: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/project-assigner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
uses: elastic/github-actions/project-assigner@v1.0.0
id: project_assigner
with:
issue-mappings: '[{"label": "Team:AppArch", "projectName": "kibana-app-arch", "columnId": 6173895}]'
issue-mappings: '[{"label": "Team:AppArch", "projectName": "kibana-app-arch", "columnId": 6173895}, {"label": "Feature:Lens", "projectName": "Lens", "columnId": 6219363}]'
ghToken: ${{ secrets.GITHUB_TOKEN }}


2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@
"@elastic/charts": "^14.0.0",
"@elastic/datemath": "5.0.2",
"@elastic/ems-client": "1.0.5",
"@elastic/eui": "17.0.0",
"@elastic/eui": "17.1.2",
"@elastic/filesaver": "1.1.2",
"@elastic/good": "8.1.1-kibana2",
"@elastic/numeral": "2.3.3",
Expand Down
4 changes: 3 additions & 1 deletion packages/kbn-analytics/scripts/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@ run(
'--extensions',
'.ts,.js,.tsx',
...(flags.watch ? ['--watch'] : ['--quiet']),
...(flags['source-maps'] ? ['--source-maps', 'inline'] : []),
...(!flags['source-maps'] || !!process.env.CODE_COVERAGE
? []
: ['--source-maps', 'inline']),
],
wait: true,
env: {
Expand Down
4 changes: 3 additions & 1 deletion packages/kbn-i18n/scripts/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@ run(
'--extensions',
'.ts,.js,.tsx',
...(flags.watch ? ['--watch'] : ['--quiet']),
...(flags['source-maps'] ? ['--source-maps', 'inline'] : []),
...(!flags['source-maps'] || !!process.env.CODE_COVERAGE
? []
: ['--source-maps', 'inline']),
],
wait: true,
env: {
Expand Down
1 change: 1 addition & 0 deletions packages/kbn-utility-types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
*/

import { PromiseType } from 'utility-types';
export { $Values, Required, Optional, Class } from 'utility-types';

/**
* Returns wrapped type of a promise.
Expand Down
2 changes: 1 addition & 1 deletion packages/kbn-utility-types/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"clean": "del target"
},
"dependencies": {
"utility-types": "^3.7.0"
"utility-types": "^3.10.0"
},
"devDependencies": {
"del-cli": "^3.0.0",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ export function ScriptHighlightRules() {
},
{
token: 'script.keyword.operator',

regex:
'\\?\\.|\\*\\.|=~|==~|!|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|->|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|typeof|void)',
},
Expand Down
44 changes: 44 additions & 0 deletions src/legacy/core_plugins/input_control_vis/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
/*
* 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 { resolve } from 'path';
import { Legacy } from 'kibana';

import { LegacyPluginApi, LegacyPluginInitializer } from '../../../../src/legacy/types';

const inputControlVisPluginInitializer: LegacyPluginInitializer = ({ Plugin }: LegacyPluginApi) =>
new Plugin({
id: 'input_control_vis',
require: ['kibana', 'elasticsearch', 'visualizations', 'interpreter', 'data'],
publicDir: resolve(__dirname, 'public'),
uiExports: {
styleSheetPaths: resolve(__dirname, 'public/index.scss'),
hacks: [resolve(__dirname, 'public/legacy')],
injectDefaultVars: server => ({}),
},
init: (server: Legacy.Server) => ({}),
config(Joi: any) {
return Joi.object({
enabled: Joi.boolean().default(true),
}).default();
},
} as Legacy.PluginSpecOptions);

// eslint-disable-next-line import/no-default-export
export default inputControlVisPluginInitializer;

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
/*
* Licensed to Elasticsearch B.V. under one or more contributor
* license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright
* ownership. Elasticsearch B.V. licenses this file to you under
* the Apache License, Version 2.0 (the "License"); you may
* not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/

import React from 'react';
import { FieldList } from 'src/plugins/data/public';
import { InputControlVisDependencies } from '../../../plugin';

const fields: FieldList = [] as any;
fields.push({ name: 'myField' } as any);
fields.getByName = (name: any) => {
return fields.find(({ name: n }) => n === name);
};

export const getDepsMock = (): InputControlVisDependencies =>
({
core: {
getStartServices: jest.fn().mockReturnValue([
null,
{
data: {
ui: {
IndexPatternSelect: () => (<div />) as any,
},
indexPatterns: {
get: () => ({
fields,
}),
},
},
},
]),
injectedMetadata: {
getInjectedVar: jest.fn().mockImplementation(key => {
switch (key) {
case 'autocompleteTimeout':
return 1000;
case 'autocompleteTerminateAfter':
return 100000;
default:
return '';
}
}),
},
},
data: {
query: {
filterManager: {
fieldName: 'myField',
getIndexPattern: () => ({
fields,
}),
getAppFilters: jest.fn().mockImplementation(() => []),
getGlobalFilters: jest.fn().mockImplementation(() => []),
},
timefilter: {
timefilter: {},
},
},
},
} as any);
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@
* under the License.
*/

export const getIndexPatternMock = () => {
import { IIndexPattern } from '../../../../../../../plugins/data/public';

/**
* Returns forced **Partial** IndexPattern for use in tests
*/
export const getIndexPatternMock = (): Promise<IIndexPattern> => {
return Promise.resolve({
id: 'mockIndexPattern',
title: 'mockIndexPattern',
Expand All @@ -26,5 +31,5 @@ export const getIndexPatternMock = () => {
{ name: 'textField', type: 'string', aggregatable: false },
{ name: 'numberField', type: 'number', aggregatable: true },
],
});
} as IIndexPattern);
};
Loading

0 comments on commit 026ec32

Please sign in to comment.