Skip to content

Commit be61507

Browse files
authored
Move kuery_autocomplete ⇒ NP (#56607)
* Move kuery_autocomplete ⇒ NP Closes: #51277 * fix i18n keys * update translations * data_xpack -> data_enhanced * data -> data_enhanced * fix i18nrc * fix PR comments
1 parent 4f26741 commit be61507

File tree

27 files changed

+152
-183
lines changed

27 files changed

+152
-183
lines changed

x-pack/.i18nrc.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"xpack.idxMgmt": "legacy/plugins/index_management",
1919
"xpack.indexLifecycleMgmt": "legacy/plugins/index_lifecycle_management",
2020
"xpack.infra": "legacy/plugins/infra",
21-
"xpack.kueryAutocomplete": "legacy/plugins/kuery_autocomplete",
21+
"xpack.data": "plugins/data_enhanced",
2222
"xpack.lens": "legacy/plugins/lens",
2323
"xpack.licenseMgmt": "legacy/plugins/license_management",
2424
"xpack.licensing": "plugins/licensing",

x-pack/index.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ import { licenseManagement } from './legacy/plugins/license_management';
2323
import { indexManagement } from './legacy/plugins/index_management';
2424
import { indexLifecycleManagement } from './legacy/plugins/index_lifecycle_management';
2525
import { spaces } from './legacy/plugins/spaces';
26-
import { kueryAutocompleteInitializer } from './legacy/plugins/kuery_autocomplete';
2726
import { canvas } from './legacy/plugins/canvas';
2827
import { infra } from './legacy/plugins/infra';
2928
import { taskManager } from './legacy/plugins/task_manager';
@@ -65,7 +64,6 @@ module.exports = function(kibana) {
6564
licenseManagement(kibana),
6665
indexManagement(kibana),
6766
indexLifecycleManagement(kibana),
68-
kueryAutocompleteInitializer(kibana),
6967
infra(kibana),
7068
taskManager(kibana),
7169
rollup(kibana),

x-pack/legacy/plugins/kuery_autocomplete/index.ts

Lines changed: 0 additions & 22 deletions
This file was deleted.

x-pack/legacy/plugins/kuery_autocomplete/public/legacy.ts

Lines changed: 0 additions & 27 deletions
This file was deleted.

x-pack/legacy/plugins/kuery_autocomplete/public/plugin.ts

Lines changed: 0 additions & 41 deletions
This file was deleted.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"id": "data_enhanced",
3+
"version": "8.0.0",
4+
"kibanaVersion": "kibana",
5+
"configPath": [
6+
"xpack"
7+
],
8+
"requiredPlugins": [
9+
"data"
10+
],
11+
"server": false,
12+
"ui": true
13+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
/*
2+
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
3+
* or more contributor license agreements. Licensed under the Elastic License;
4+
* you may not use this file except in compliance with the Elastic License.
5+
*/
6+
7+
export {
8+
setupKqlQuerySuggestionProvider,
9+
KUERY_LANGUAGE_NAME,
10+
} from './providers/kql_query_suggestion';

x-pack/legacy/plugins/kuery_autocomplete/public/kql_query_suggestion/conjunction.test.ts renamed to x-pack/plugins/data_enhanced/public/autocomplete/providers/kql_query_suggestion/conjunction.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
*/
66

77
import { setupGetConjunctionSuggestions } from './conjunction';
8-
import { autocomplete, esKuery } from '../../../../../../src/plugins/data/public';
9-
import { coreMock } from '../../../../../../src/core/public/mocks';
8+
import { autocomplete, esKuery } from '../../../../../../../src/plugins/data/public';
9+
import { coreMock } from '../../../../../../../src/core/public/mocks';
1010

1111
const mockKueryNode = (kueryNode: Partial<esKuery.KueryNode>) =>
1212
(kueryNode as unknown) as esKuery.KueryNode;

x-pack/legacy/plugins/kuery_autocomplete/public/kql_query_suggestion/conjunction.tsx renamed to x-pack/plugins/data_enhanced/public/autocomplete/providers/kql_query_suggestion/conjunction.tsx

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,50 +7,50 @@ import React from 'react';
77
import { $Keys } from 'utility-types';
88
import { FormattedMessage } from '@kbn/i18n/react';
99
import { KqlQuerySuggestionProvider } from './types';
10-
import { autocomplete } from '../../../../../../src/plugins/data/public';
10+
import { autocomplete } from '../../../../../../../src/plugins/data/public';
1111

1212
const bothArgumentsText = (
1313
<FormattedMessage
14-
id="xpack.kueryAutocomplete.andOperatorDescription.bothArgumentsText"
14+
id="xpack.data.kueryAutocomplete.andOperatorDescription.bothArgumentsText"
1515
defaultMessage="both arguments"
16-
description="Part of xpack.kueryAutocomplete.andOperatorDescription. Full text: 'Requires both arguments to be true'"
16+
description="Part of xpack.data.kueryAutocomplete.andOperatorDescription. Full text: 'Requires both arguments to be true'"
1717
/>
1818
);
1919

2020
const oneOrMoreArgumentsText = (
2121
<FormattedMessage
22-
id="xpack.kueryAutocomplete.orOperatorDescription.oneOrMoreArgumentsText"
22+
id="xpack.data.kueryAutocomplete.orOperatorDescription.oneOrMoreArgumentsText"
2323
defaultMessage="one or more arguments"
24-
description="Part of xpack.kueryAutocomplete.orOperatorDescription. Full text: 'Requires one or more arguments to be true'"
24+
description="Part of xpack.data.kueryAutocomplete.orOperatorDescription. Full text: 'Requires one or more arguments to be true'"
2525
/>
2626
);
2727

2828
const conjunctions: Record<string, JSX.Element> = {
2929
and: (
3030
<p>
3131
<FormattedMessage
32-
id="xpack.kueryAutocomplete.andOperatorDescription"
32+
id="xpack.data.kueryAutocomplete.andOperatorDescription"
3333
defaultMessage="Requires {bothArguments} to be true"
3434
values={{
3535
bothArguments: <span className="kbnSuggestionItem__callout">{bothArgumentsText}</span>,
3636
}}
3737
description="Full text: ' Requires both arguments to be true'. See
38-
'xpack.kueryAutocomplete.andOperatorDescription.bothArgumentsText' for 'both arguments' part."
38+
'xpack.data.kueryAutocomplete.andOperatorDescription.bothArgumentsText' for 'both arguments' part."
3939
/>
4040
</p>
4141
),
4242
or: (
4343
<p>
4444
<FormattedMessage
45-
id="xpack.kueryAutocomplete.orOperatorDescription"
45+
id="xpack.data.kueryAutocomplete.orOperatorDescription"
4646
defaultMessage="Requires {oneOrMoreArguments} to be true"
4747
values={{
4848
oneOrMoreArguments: (
4949
<span className="kbnSuggestionItem__callout">{oneOrMoreArgumentsText}</span>
5050
),
5151
}}
5252
description="Full text: 'Requires one or more arguments to be true'. See
53-
'xpack.kueryAutocomplete.orOperatorDescription.oneOrMoreArgumentsText' for 'one or more arguments' part."
53+
'xpack.data.kueryAutocomplete.orOperatorDescription.oneOrMoreArgumentsText' for 'one or more arguments' part."
5454
/>
5555
</p>
5656
),

0 commit comments

Comments
 (0)