Skip to content

Commit

Permalink
Merge branch 'master' into ml-fix-swim-lane-exporer-filter
Browse files Browse the repository at this point in the history
  • Loading branch information
kibanamachine committed Jul 12, 2021
2 parents c6d11e8 + 42c743b commit 2d7a103
Show file tree
Hide file tree
Showing 100 changed files with 809 additions and 725 deletions.
21 changes: 21 additions & 0 deletions docs/user/dashboard/tsvb.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,27 @@ The *Markdown* visualization supports Markdown with Handlebar (mustache) syntax

For answers to frequently asked *TSVB* question, review the following.

[float]
===== How do I create dashboard drilldowns for Top N and Table visualizations?

You can create dashboard drilldowns that include the specified time range for *Top N* and *Table* visualizations.

. Open the dashboard that you want to link to, then copy the URL.

. Open the dashboard with the *Top N* and *Table* visualization panel, then click *Edit* in the toolbar.

. Open the *Top N* or *Table* panel menu, then select *Edit visualization*.

. Click *Panel options*.

. In the *Item URL* field, enter the URL.
+
For example `dashboards#/view/f193ca90-c9f4-11eb-b038-dd3270053a27`.

. Click *Save and return*.

. In the toolbar, cick *Save as*, then make sure *Store time with dashboard* is deselected.

[float]
===== Why is my TSVB visualization missing data?

Expand Down
12 changes: 6 additions & 6 deletions src/core/public/chrome/ui/header/header_help_menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ export class HeaderHelpMenu extends Component<Props, State> {

return (
<Fragment>
<EuiButtonEmpty href={kibanaDocLink} target="_blank" size="xs" flush="left">
<EuiButtonEmpty href={kibanaDocLink} target="_blank" size="s" flush="left">
<FormattedMessage
id="core.ui.chrome.headerGlobalNav.helpMenuKibanaDocumentationTitle"
defaultMessage="Kibana documentation"
Expand All @@ -220,7 +220,7 @@ export class HeaderHelpMenu extends Component<Props, State> {

<EuiSpacer size="xs" />

<EuiButtonEmpty href={helpSupportUrl} target="_blank" size="xs" flush="left">
<EuiButtonEmpty href={helpSupportUrl} target="_blank" size="s" flush="left">
<FormattedMessage
id="core.ui.chrome.headerGlobalNav.helpMenuAskElasticTitle"
defaultMessage="Ask Elastic"
Expand All @@ -229,7 +229,7 @@ export class HeaderHelpMenu extends Component<Props, State> {

<EuiSpacer size="xs" />

<EuiButtonEmpty href={KIBANA_FEEDBACK_LINK} target="_blank" size="xs" flush="left">
<EuiButtonEmpty href={KIBANA_FEEDBACK_LINK} target="_blank" size="s" flush="left">
<FormattedMessage
id="core.ui.chrome.headerGlobalNav.helpMenuGiveFeedbackTitle"
defaultMessage="Give feedback"
Expand All @@ -241,7 +241,7 @@ export class HeaderHelpMenu extends Component<Props, State> {
<EuiButtonEmpty
href={GITHUB_CREATE_ISSUE_LINK}
target="_blank"
size="xs"
size="s"
iconType="logoGithub"
flush="left"
>
Expand Down Expand Up @@ -330,7 +330,7 @@ export class HeaderHelpMenu extends Component<Props, State> {
{customLinks}
{content && (
<>
{customLinks && <EuiSpacer size="s" />}
{customLinks && <EuiSpacer size="xs" />}
<HeaderExtension extension={content} />
</>
)}
Expand Down Expand Up @@ -383,7 +383,7 @@ const createCustomLink = (
) => {
return (
<Fragment key={`helpButton${index}`}>
<EuiButtonEmpty {...buttonProps} size="xs" flush="left">
<EuiButtonEmpty {...buttonProps} size="s" flush="left">
{text}
</EuiButtonEmpty>
{addSpacer && <EuiSpacer size="xs" />}
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/data/public/ui/filter_bar/filter_bar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ function FilterBarUI(props: Props) {

const button = (
<EuiButtonEmpty
size="xs"
size="s"
onClick={() => setIsAddFilterPopoverOpen(true)}
data-test-subj="addFilter"
className="globalFilterBar__addButton"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import { setScopedHistory, setServices, setDocViewsRegistry } from '../../../../
import { coreMock } from '../../../../../../../core/public/mocks';
import { dataPluginMock } from '../../../../../../data/public/mocks';
import { navigationPluginMock } from '../../../../../../navigation/public/mocks';
import { initAngularBootstrap } from '../../../../../../kibana_legacy/public/angular_bootstrap';
import { getInnerAngularModule } from '../../get_inner_angular';
import { createBrowserHistory } from 'history';

Expand All @@ -41,6 +42,9 @@ describe('Doc Table', () => {
// Stub out a minimal mapping of 4 fields
let mapping;

beforeAll(async () => {
await initAngularBootstrap();
});
beforeAll(() => setScopedHistory(createBrowserHistory()));
beforeEach(() => {
angular.element.prototype.slice = jest.fn(function (index) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import hits from '../../../__fixtures__/real_hits';
import { coreMock } from '../../../../../../core/public/mocks';
import { dataPluginMock } from '../../../../../data/public/mocks';
import { navigationPluginMock } from '../../../../../navigation/public/mocks';
import { initAngularBootstrap } from '../../../../../kibana_legacy/public/angular_bootstrap';
import { setScopedHistory, setServices } from '../../../kibana_services';
import { getInnerAngularModule } from '../get_inner_angular';

Expand Down Expand Up @@ -54,6 +55,9 @@ describe('docTable', () => {
const core = coreMock.createStart();
let $elem;

beforeAll(async () => {
await initAngularBootstrap();
});
beforeAll(() => setScopedHistory(createBrowserHistory()));
beforeEach(() => {
angular.element.prototype.slice = jest.fn(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,12 @@ import { createDocViewerDirective } from './doc_viewer';
import { createDiscoverGridDirective } from './create_discover_grid_directive';
import { createRenderCompleteDirective } from './directives/render_complete';
import {
initAngularBootstrap,
configureAppAngularModule,
PrivateProvider,
PromiseServiceCreator,
registerListenEventListener,
watchMultiDecorator,
} from '../../../../kibana_legacy/public';
import { PromiseServiceCreator } from './helpers';
import { DiscoverStartPlugins } from '../../plugin';
import { getScopedHistory } from '../../kibana_services';
import { createDiscoverDirective } from './create_discover_directive';
Expand All @@ -54,7 +53,6 @@ export function getInnerAngularModule(
deps: DiscoverStartPlugins,
context: PluginInitializerContext
) {
initAngularBootstrap();
const module = initializeInnerAngularModule(name, core, deps.navigation, deps.data);
configureAppAngularModule(module, { core, env: context.env }, true, getScopedHistory);
return module;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@

export { formatRow, formatTopLevelObject } from './row_formatter';
export { handleSourceColumnState } from './state_helpers';
export { PromiseServiceCreator } from './promises';
2 changes: 2 additions & 0 deletions src/plugins/discover/public/plugin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -403,6 +403,7 @@ export class DiscoverPlugin
}
// this is used by application mount and tests
const { getInnerAngularModule } = await import('./application/angular/get_inner_angular');
await plugins.kibanaLegacy.loadAngularBootstrap();
const module = getInnerAngularModule(
innerAngularName,
core,
Expand Down Expand Up @@ -473,6 +474,7 @@ export class DiscoverPlugin
throw Error('Discover plugin getEmbeddableInjector: initializeServices is undefined');
}
const { core, plugins } = await this.initializeServices();
await getServices().kibanaLegacy.loadAngularBootstrap();
getServices().kibanaLegacy.loadFontAwesome();
const { getInnerAngularModuleEmbeddable } = await import(
'./application/angular/get_inner_angular'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ export const IndexPatternTable = ({ canSave, history }: Props) => {
}
) => (
<>
<EuiButtonEmpty size="xs" {...reactRouterNavigate(history, `patterns/${index.id}`)}>
<EuiButtonEmpty size="s" {...reactRouterNavigate(history, `patterns/${index.id}`)}>
{name}
</EuiButtonEmpty>
&emsp;
Expand Down
7 changes: 6 additions & 1 deletion src/plugins/kibana_legacy/public/angular/angular_config.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import {
ILocationProvider,
IModule,
IRootScopeService,
IRequestConfig,
} from 'angular';
import $ from 'jquery';
import { set } from '@elastic/safer-lodash-set';
Expand All @@ -22,7 +23,6 @@ import { ChromeBreadcrumb, EnvironmentMode, PackageInfo } from 'kibana/public';
import { History } from 'history';

import { CoreStart } from 'kibana/public';
import { isSystemApiRequest } from '../utils';
import { formatAngularHttpError, isAngularHttpError } from '../notify/lib';

export interface RouteConfiguration {
Expand All @@ -38,6 +38,11 @@ export interface RouteConfiguration {
requireUICapability?: string;
}

function isSystemApiRequest(request: IRequestConfig) {
const { headers } = request;
return headers && !!headers['kbn-system-request'];
}

/**
* Detects whether a given angular route is a dummy route that doesn't
* require any action. There are two ways this can happen:
Expand Down
2 changes: 0 additions & 2 deletions src/plugins/kibana_legacy/public/angular/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
* Side Public License, v 1.
*/

// @ts-ignore
export { PromiseServiceCreator } from './promises';
// @ts-ignore
export { watchMultiDecorator } from './watch_multi';
export * from './angular_config';
Expand Down
1 change: 0 additions & 1 deletion src/plugins/kibana_legacy/public/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ export const plugin = (initializerContext: PluginInitializerContext) =>

export * from './plugin';

export { initAngularBootstrap } from './angular_bootstrap';
export { PaginateDirectiveProvider, PaginateControlsDirectiveProvider } from './paginate/paginate';
export * from './angular';
export * from './notify';
Expand Down
1 change: 1 addition & 0 deletions src/plugins/kibana_legacy/public/mocks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ const createStartContract = (): Start => ({
getHideWriteControls: jest.fn(),
},
loadFontAwesome: jest.fn(),
loadAngularBootstrap: jest.fn(),
});

export const kibanaLegacyPluginMock = {
Expand Down
1 change: 0 additions & 1 deletion src/plugins/kibana_legacy/public/notify/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,4 @@
* Side Public License, v 1.
*/

export * from './toasts';
export * from './lib';
100 changes: 0 additions & 100 deletions src/plugins/kibana_legacy/public/notify/toasts/TOAST_NOTIFICATIONS.md

This file was deleted.

9 changes: 0 additions & 9 deletions src/plugins/kibana_legacy/public/notify/toasts/index.ts

This file was deleted.

Loading

0 comments on commit 2d7a103

Please sign in to comment.