Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/elastic/kibana into boreali…
Browse files Browse the repository at this point in the history
…s/controls/replace-euiThemeVars-usage
  • Loading branch information
cqliu1 committed Dec 18, 2024
2 parents 32472f4 + 07c85dc commit 37197bf
Show file tree
Hide file tree
Showing 15 changed files with 89 additions and 164 deletions.
123 changes: 40 additions & 83 deletions packages/kbn-search-connectors/types/native_connectors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ const PERSONAL_ACCESS_TOKEN = 'personal_access_token';

const GITHUB_APP = 'github_app';

const BOX_FREE = 'box_free';
const BOX_ENTERPRISE = 'box_enterprise';

export const NATIVE_CONNECTOR_DEFINITIONS: Record<string, NativeConnector | undefined> = {
azure_blob_storage: {
configuration: {
Expand Down Expand Up @@ -246,31 +249,42 @@ export const NATIVE_CONNECTOR_DEFINITIONS: Record<string, NativeConnector | unde
},
box: {
configuration: {
path: {
default_value: null,
is_enterprise: {
default_value: BOX_FREE,
depends_on: [],
display: TEXTBOX,
label: translate('searchConnectors.nativeConnectors.box.pathLabel', {
defaultMessage: 'Path to fetch files/folders',
display: DROPDOWN,
label: translate('searchConnectors.nativeConnectors.box.accountType', {
defaultMessage: 'Box Account',
}),
options: [],
order: 1,
required: false,
options: [
{
label: translate('searchConnectors.nativeConnectors.box.boxFreeAccount', {
defaultMessage: 'Box Free Account',
}),
value: BOX_FREE,
},
{
label: translate('searchConnectors.nativeConnectors.box.boxEnterpriseAccount', {
defaultMessage: 'Box Enterprise Account',
}),
value: BOX_ENTERPRISE,
},
],
required: true,
sensitive: false,
tooltip: translate('searchConnectors.nativeConnectors.box.pathTooltip', {
defaultMessage: 'Path is ignored when Advanced Sync Rules are used. ',
}),
tooltip: null,
order: 1,
type: STRING,
ui_restrictions: [],
validations: [],
value: '',
value: BOX_FREE,
},
app_key: {
client_id: {
default_value: null,
depends_on: [],
display: TEXTBOX,
label: translate('searchConnectors.nativeConnectors.box.appKeyLabel', {
defaultMessage: 'App Key',
label: translate('searchConnectors.nativeConnectors.box.clientIdLabel', {
defaultMessage: 'Client ID',
}),
options: [],
order: 2,
Expand All @@ -282,12 +296,12 @@ export const NATIVE_CONNECTOR_DEFINITIONS: Record<string, NativeConnector | unde
validations: [],
value: '',
},
app_secret: {
client_secret: {
default_value: null,
depends_on: [],
display: TEXTBOX,
label: translate('searchConnectors.nativeConnectors.box.appSecretLabel', {
defaultMessage: 'App secret',
label: translate('searchConnectors.nativeConnectors.box.clientSecretLabel', {
defaultMessage: 'Client Secret',
}),
options: [],
order: 3,
Expand Down Expand Up @@ -316,18 +330,20 @@ export const NATIVE_CONNECTOR_DEFINITIONS: Record<string, NativeConnector | unde
validations: [],
value: '',
},
retry_count: {
default_value: 3,
depends_on: [],
display: NUMERIC,
label: RETRIES_PER_REQUEST_LABEL,
enterprise_id: {
default_value: null,
depends_on: [{ field: 'is_enterprise', value: BOX_ENTERPRISE }],
display: TEXTBOX,
label: translate('searchConnectors.nativeConnectors.box.enterpriseIdLabel', {
defaultMessage: 'Enterprise ID',
}),
options: [],
order: 5,
required: false,
sensitive: false,
tooltip: null,
type: INTEGER,
ui_restrictions: ['advanced'],
ui_restrictions: [],
validations: [],
value: '',
},
Expand All @@ -346,65 +362,6 @@ export const NATIVE_CONNECTOR_DEFINITIONS: Record<string, NativeConnector | unde
validations: [],
value: '',
},
use_text_extraction_service: {
default_value: null,
depends_on: [],
display: TOGGLE,
label: USE_TEXT_EXTRACTION_SERVICE_LABEL,
options: [],
order: 7,
required: true,
sensitive: false,
tooltip: USE_TEXT_EXTRACTION_SERVICE_TOOLTIP,
type: BOOLEAN,
ui_restrictions: ['advanced'],
validations: [],
value: false,
},
use_document_level_security: {
default_value: null,
depends_on: [],
display: TOGGLE,
label: ENABLE_DOCUMENT_LEVEL_SECURITY_LABEL,
options: [],
order: 8,
required: true,
sensitive: false,
tooltip: getEnableDocumentLevelSecurityTooltip(
translate('searchConnectors.nativeConnectors.boxTooltip.name', {
defaultMessage: 'Box',
})
),
type: BOOLEAN,
ui_restrictions: [],
validations: [],
value: false,
},
include_inherited_users_and_groups: {
default_value: null,
depends_on: [
{
field: 'use_document_level_security',
value: true,
},
],
display: TOGGLE,
label: translate('searchConnectors.nativeConnectors.box.includeInheritedUsersLabel', {
defaultMessage: 'Include groups and inherited users',
}),
options: [],
order: 9,
required: true,
sensitive: false,
tooltip: translate('searchConnectors.nativeConnectors.box.includeInheritedUsersTooltip', {
defaultMessage:
'Include groups and inherited users when indexing permissions. Enabling this configurable field will cause a significant performance degradation.',
}),
type: BOOLEAN,
ui_restrictions: [],
validations: [],
value: false,
},
},
features: {},
name: translate('searchConnectors.nativeConnectors.box.name', {
Expand Down
1 change: 0 additions & 1 deletion src/plugins/embeddable/public/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ export {
withEmbeddableSubscription,
} from './lib';
export type {
Adapters,
CellValueContext,
ChartActionContext,
EmbeddableContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import * as Rx from 'rxjs';
import { merge } from 'rxjs';
import { debounceTime, distinctUntilChanged, map, skip } from 'rxjs';
import { RenderCompleteDispatcher } from '@kbn/kibana-utils-plugin/public';
import { Adapters } from '../types';
import { Adapters } from '@kbn/inspector-plugin/public';
import { EmbeddableError, EmbeddableOutput, IEmbeddable } from './i_embeddable';
import { EmbeddableInput, ViewMode } from '../../../common/types';
import { genericEmbeddableInputIsEqual, omitGenericEmbeddableInput } from './diff_embeddable_input';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
*/

import { ErrorLike } from '@kbn/expressions-plugin/common';
import { Adapters } from '@kbn/inspector-plugin/public';
import { Observable } from 'rxjs';
import { EmbeddableInput } from '../../../common/types';
import { Adapters } from '../types';

export type EmbeddableError = ErrorLike;
export type { EmbeddableInput };
Expand Down
10 changes: 0 additions & 10 deletions src/plugins/embeddable/public/lib/inspector.ts

This file was deleted.

3 changes: 0 additions & 3 deletions src/plugins/embeddable/public/lib/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@
* License v3.0 only", or the "Server Side Public License, v 1".
*/

import { Adapters } from './inspector';

export interface Trigger {
id: string;
title?: string;
Expand All @@ -23,7 +21,6 @@ export interface PropertySpec {
value?: string;
}
export { ViewMode } from '../../common/types';
export type { Adapters };

export interface CommonlyUsedRange {
from: string;
Expand Down
Loading

0 comments on commit 37197bf

Please sign in to comment.