Skip to content

Commit

Permalink
Merge branch 'master' into reporting/new-platform-shim-part-ii
Browse files Browse the repository at this point in the history
  • Loading branch information
tsullivan committed Oct 30, 2019
2 parents 887b587 + e61ee75 commit 361f6d3
Show file tree
Hide file tree
Showing 650 changed files with 12,248 additions and 6,460 deletions.
195 changes: 195 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,201 @@ module.exports = {
extends: ['@elastic/eslint-config-kibana', 'plugin:@elastic/eui/recommended'],

overrides: [
/**
* Temporarily disable some react rules for specific plugins, remove in separate PRs
*/
{
files: ['packages/kbn-ui-framework/**/*.{js,ts,tsx}'],
rules: {
'jsx-a11y/no-onchange': 'off',
},
},
{
files: ['src/core/public/application/**/*.{js,ts,tsx}'],
rules: {
'react/no-danger': 'off',
},
},
{
files: ['src/legacy/core_plugins/console/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/data/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/expressions/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/kbn_vislib_vis_types/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/kibana/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/tile_map/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/vis_type_markdown/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/vis_type_metric/**/*.{js,ts,tsx}'],
rules: {
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['src/legacy/core_plugins/vis_type_table/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/core_plugins/vis_type_vega/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/legacy/ui/public/vis/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/plugins/es_ui_shared/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/plugins/eui_utils/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/plugins/kibana_react/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['src/plugins/kibana_utils/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['x-pack/legacy/plugins/canvas/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['x-pack/legacy/plugins/cross_cluster_replication/**/*.{js,ts,tsx}'],
rules: {
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['x-pack/legacy/plugins/graph/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['x-pack/legacy/plugins/index_management/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/infra/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/lens/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/ml/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['x-pack/legacy/plugins/monitoring/**/*.{js,ts,tsx}'],
rules: {
'jsx-a11y/click-events-have-key-events': 'off',
},
},
{
files: ['x-pack/legacy/plugins/siem/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/snapshot_restore/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['x-pack/legacy/plugins/transform/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: ['x-pack/legacy/plugins/uptime/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/exhaustive-deps': 'off',
'react-hooks/rules-of-hooks': 'off',
},
},
{
files: ['x-pack/legacy/plugins/watcher/**/*.{js,ts,tsx}'],
rules: {
'react-hooks/rules-of-hooks': 'off',
'react-hooks/exhaustive-deps': 'off',
},
},

/**
* Prettier
*/
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ _Note: The version numbers below are only examples, meant to illustrate the rela

## Questions? Problems? Suggestions?

- If you've found a bug or want to request a feature, please create a [GitHub Issue](https://github.com/elastic/kibana/issues/new).
Please check to make sure someone else hasn't already created an issue for the same topic.
- If you've found a bug or want to request a feature, please create a [GitHub Issue](https://github.com/elastic/kibana/issues/new/choose).
Please check to make sure someone else hasn't already created an issue for the same topic.
- Need help using Kibana? Ask away on our [Kibana Discuss Forum](https://discuss.elastic.co/c/kibana) and a fellow community member or
Elastic engineer will be glad to help you out.
9 changes: 0 additions & 9 deletions docs/developer/core/development-modules.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,6 @@ To prevent this from being an issue the ui module provides "autoloading"
modules. The sole purpose of these modules is to extend the environment with
certain components. Here is a breakdown of those modules:

- *`import 'ui/autoload/styles'`*
Imports all styles at the root of `src/legacy/ui/public/styles`

- *`import 'ui/autoload/directives'`*
Imports all directives in `src/legacy/ui/public/directives`

- *`import 'ui/autoload/filters'`*
Imports all filters in `src/legacy/ui/public/filters`

- *`import 'ui/autoload/modules'`*
Imports angular and several ui services and "components" which Kibana
depends on without importing. The full list of imports is hard coded in the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

## IAnonymousPaths.isAnonymous() method

Determines whether the provided path doesn't require authentication
Determines whether the provided path doesn't require authentication. `path` should include the current basePath.

<b>Signature:</b>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@ export interface IAnonymousPaths

| Method | Description |
| --- | --- |
| [isAnonymous(path)](./kibana-plugin-public.ianonymouspaths.isanonymous.md) | Determines whether the provided path doesn't require authentication |
| [register(path)](./kibana-plugin-public.ianonymouspaths.register.md) | Register <code>path</code> as not requiring authentication |
| [isAnonymous(path)](./kibana-plugin-public.ianonymouspaths.isanonymous.md) | Determines whether the provided path doesn't require authentication. <code>path</code> should include the current basePath. |
| [register(path)](./kibana-plugin-public.ianonymouspaths.register.md) | Register <code>path</code> as not requiring authentication. <code>path</code> should not include the current basePath. |

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

## IAnonymousPaths.register() method

Register `path` as not requiring authentication
Register `path` as not requiring authentication. `path` should not include the current basePath.

<b>Signature:</b>

Expand Down
2 changes: 1 addition & 1 deletion docs/development/core/public/kibana-plugin-public.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,5 +121,5 @@ The plugin integrates with the core system via lifecycle events: `setup`<!-- -->
| [ToastInputFields](./kibana-plugin-public.toastinputfields.md) | Allowed fields for [ToastInput](./kibana-plugin-public.toastinput.md)<!-- -->. |
| [ToastsSetup](./kibana-plugin-public.toastssetup.md) | [IToasts](./kibana-plugin-public.itoasts.md) |
| [ToastsStart](./kibana-plugin-public.toastsstart.md) | [IToasts](./kibana-plugin-public.itoasts.md) |
| [UiSettingsClientContract](./kibana-plugin-public.uisettingsclientcontract.md) | [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md) |
| [UiSettingsClientContract](./kibana-plugin-public.uisettingsclientcontract.md) | Client-side client that provides access to the advanced settings stored in elasticsearch. The settings provide control over the behavior of the Kibana application. For example, a user can specify how to display numeric or date fields. Users can adjust the settings via Management UI. [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md) |

Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ Gets the metadata about all uiSettings, including the type, default value, and u
<b>Signature:</b>

```typescript
getAll(): UiSettingsState;
getAll(): Record<string, UiSettingsParams & UserProvidedValues<any>>;
```
<b>Returns:</b>

`UiSettingsState`
`Record<string, UiSettingsParams & UserProvidedValues<any>>`

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

## UiSettingsClientContract type

[UiSettingsClient](./kibana-plugin-public.uisettingsclient.md)
Client-side client that provides access to the advanced settings stored in elasticsearch. The settings provide control over the behavior of the Kibana application. For example, a user can specify how to display numeric or date fields. Users can adjust the settings via Management UI. [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md)

<b>Signature:</b>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,5 @@ export interface CoreSetup
| [context](./kibana-plugin-server.coresetup.context.md) | <code>ContextSetup</code> | [ContextSetup](./kibana-plugin-server.contextsetup.md) |
| [elasticsearch](./kibana-plugin-server.coresetup.elasticsearch.md) | <code>ElasticsearchServiceSetup</code> | [ElasticsearchServiceSetup](./kibana-plugin-server.elasticsearchservicesetup.md) |
| [http](./kibana-plugin-server.coresetup.http.md) | <code>HttpServiceSetup</code> | [HttpServiceSetup](./kibana-plugin-server.httpservicesetup.md) |
| [uiSettings](./kibana-plugin-server.coresetup.uisettings.md) | <code>UiSettingsServiceSetup</code> | [UiSettingsServiceSetup](./kibana-plugin-server.uisettingsservicesetup.md) |

Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-server](./kibana-plugin-server.md) &gt; [CoreSetup](./kibana-plugin-server.coresetup.md) &gt; [uiSettings](./kibana-plugin-server.coresetup.uisettings.md)

## CoreSetup.uiSettings property

[UiSettingsServiceSetup](./kibana-plugin-server.uisettingsservicesetup.md)

<b>Signature:</b>

```typescript
uiSettings: UiSettingsServiceSetup;
```

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-server](./kibana-plugin-server.md) &gt; [IUiSettingsClient](./kibana-plugin-server.iuisettingsclient.md) &gt; [getRegistered](./kibana-plugin-server.iuisettingsclient.getregistered.md)

## IUiSettingsClient.getRegistered property

Returns registered uiSettings values [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md)

<b>Signature:</b>

```typescript
getRegistered: () => Readonly<Record<string, UiSettingsParams>>;
```
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,5 @@ Retrieves a set of all uiSettings values set by the user.
<b>Signature:</b>

```typescript
getUserProvided: <T extends SavedObjectAttribute = any>() => Promise<Record<string, {
userValue?: T;
isOverridden?: boolean;
}>>;
getUserProvided: <T extends SavedObjectAttribute = any>() => Promise<Record<string, UserProvidedValues<T>>>;
```
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

## IUiSettingsClient interface

Service that provides access to the UiSettings stored in elasticsearch.
Server-side client that provides access to the advanced settings stored in elasticsearch. The settings provide control over the behavior of the Kibana application. For example, a user can specify how to display numeric or date fields. Users can adjust the settings via Management UI.

<b>Signature:</b>

Expand All @@ -18,8 +18,8 @@ export interface IUiSettingsClient
| --- | --- | --- |
| [get](./kibana-plugin-server.iuisettingsclient.get.md) | <code>&lt;T extends SavedObjectAttribute = any&gt;(key: string) =&gt; Promise&lt;T&gt;</code> | Retrieves uiSettings values set by the user with fallbacks to default values if not specified. |
| [getAll](./kibana-plugin-server.iuisettingsclient.getall.md) | <code>&lt;T extends SavedObjectAttribute = any&gt;() =&gt; Promise&lt;Record&lt;string, T&gt;&gt;</code> | Retrieves a set of all uiSettings values set by the user with fallbacks to default values if not specified. |
| [getDefaults](./kibana-plugin-server.iuisettingsclient.getdefaults.md) | <code>() =&gt; Record&lt;string, UiSettingsParams&gt;</code> | Returns uiSettings default values [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md) |
| [getUserProvided](./kibana-plugin-server.iuisettingsclient.getuserprovided.md) | <code>&lt;T extends SavedObjectAttribute = any&gt;() =&gt; Promise&lt;Record&lt;string, {</code><br/><code> userValue?: T;</code><br/><code> isOverridden?: boolean;</code><br/><code> }&gt;&gt;</code> | Retrieves a set of all uiSettings values set by the user. |
| [getRegistered](./kibana-plugin-server.iuisettingsclient.getregistered.md) | <code>() =&gt; Readonly&lt;Record&lt;string, UiSettingsParams&gt;&gt;</code> | Returns registered uiSettings values [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md) |
| [getUserProvided](./kibana-plugin-server.iuisettingsclient.getuserprovided.md) | <code>&lt;T extends SavedObjectAttribute = any&gt;() =&gt; Promise&lt;Record&lt;string, UserProvidedValues&lt;T&gt;&gt;&gt;</code> | Retrieves a set of all uiSettings values set by the user. |
| [isOverridden](./kibana-plugin-server.iuisettingsclient.isoverridden.md) | <code>(key: string) =&gt; boolean</code> | Shows whether the uiSettings value set by the user. |
| [remove](./kibana-plugin-server.iuisettingsclient.remove.md) | <code>(key: string) =&gt; Promise&lt;void&gt;</code> | Removes uiSettings value by key. |
| [removeMany](./kibana-plugin-server.iuisettingsclient.removemany.md) | <code>(keys: string[]) =&gt; Promise&lt;void&gt;</code> | Removes multiple uiSettings values by keys. |
Expand Down
4 changes: 3 additions & 1 deletion docs/development/core/server/kibana-plugin-server.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ The plugin integrates with the core system via lifecycle events: `setup`<!-- -->
| [IKibanaSocket](./kibana-plugin-server.ikibanasocket.md) | A tiny abstraction for TCP socket. |
| [IndexSettingsDeprecationInfo](./kibana-plugin-server.indexsettingsdeprecationinfo.md) | |
| [IRouter](./kibana-plugin-server.irouter.md) | Registers route handlers for specified resource path and method. See [RouteConfig](./kibana-plugin-server.routeconfig.md) and [RequestHandler](./kibana-plugin-server.requesthandler.md) for more information about arguments to route registrations. |
| [IUiSettingsClient](./kibana-plugin-server.iuisettingsclient.md) | Service that provides access to the UiSettings stored in elasticsearch. |
| [IUiSettingsClient](./kibana-plugin-server.iuisettingsclient.md) | Server-side client that provides access to the advanced settings stored in elasticsearch. The settings provide control over the behavior of the Kibana application. For example, a user can specify how to display numeric or date fields. Users can adjust the settings via Management UI. |
| [KibanaRequestRoute](./kibana-plugin-server.kibanarequestroute.md) | Request specific route information exposed to a handler. |
| [LegacyRequest](./kibana-plugin-server.legacyrequest.md) | |
| [LegacyServiceSetupDeps](./kibana-plugin-server.legacyservicesetupdeps.md) | |
Expand Down Expand Up @@ -118,6 +118,8 @@ The plugin integrates with the core system via lifecycle events: `setup`<!-- -->
| [SessionStorageCookieOptions](./kibana-plugin-server.sessionstoragecookieoptions.md) | Configuration used to create HTTP session storage based on top of cookie mechanism. |
| [SessionStorageFactory](./kibana-plugin-server.sessionstoragefactory.md) | SessionStorage factory to bind one to an incoming request |
| [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md) | UiSettings parameters defined by the plugins. |
| [UiSettingsServiceSetup](./kibana-plugin-server.uisettingsservicesetup.md) | |
| [UserProvidedValues](./kibana-plugin-server.userprovidedvalues.md) | Describes the values explicitly set by user. |

## Variables

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,8 @@ core: {
dataClient: IScopedClusterClient;
adminClient: IScopedClusterClient;
};
uiSettings: {
client: IUiSettingsClient;
};
};
```
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@ export interface RequestHandlerContext

| Property | Type | Description |
| --- | --- | --- |
| [core](./kibana-plugin-server.requesthandlercontext.core.md) | <code>{</code><br/><code> savedObjects: {</code><br/><code> client: SavedObjectsClientContract;</code><br/><code> };</code><br/><code> elasticsearch: {</code><br/><code> dataClient: IScopedClusterClient;</code><br/><code> adminClient: IScopedClusterClient;</code><br/><code> };</code><br/><code> }</code> | |
| [core](./kibana-plugin-server.requesthandlercontext.core.md) | <code>{</code><br/><code> savedObjects: {</code><br/><code> client: SavedObjectsClientContract;</code><br/><code> };</code><br/><code> elasticsearch: {</code><br/><code> dataClient: IScopedClusterClient;</code><br/><code> adminClient: IScopedClusterClient;</code><br/><code> };</code><br/><code> uiSettings: {</code><br/><code> client: IUiSettingsClient;</code><br/><code> };</code><br/><code> }</code> | |

Loading

0 comments on commit 361f6d3

Please sign in to comment.