Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renaming advanced_settings plugin folder to kebab-case #394

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .i18nrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
],
"maps_legacy": "src/plugins/maps_legacy",
"indexPatternManagement": "src/plugins/index_pattern_management",
"advancedSettings": "src/plugins/advanced_settings",
"advancedSettings": "src/plugins/advanced-settings",
"opensearch_dashboards_legacy": "src/plugins/opensearch_dashboards_legacy",
"opensearchDashboardsOverview": "src/plugins/opensearch_dashboards_overview",
"opensearch_dashboards_react": "src/legacy/core_plugins/opensearch_dashboards_react",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@
*/

import { ComponentType } from 'react';
import { PageTitle } from './page_title';
import { PageSubtitle } from './page_subtitle';
import { PageFooter } from './page_footer';
import { PageTitle } from './page-title';
import { PageSubtitle } from './page-subtitle';
import { PageFooter } from './page-footer';

type Id =
| 'advanced_settings_page_title'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@ import React from 'react';
import { PluginInitializerContext } from 'opensearch-dashboards/public';
import { AdvancedSettingsPlugin } from './plugin';
export { AdvancedSettingsSetup, AdvancedSettingsStart } from './types';
export { ComponentRegistry } from './component_registry';
export { ComponentRegistry } from './component-registry';

/**
* Exports the field component as a React.lazy component. We're explicitly naming it lazy here
* so any plugin that would import that can clearly see it's lazy loaded and can only be used
* inside a suspense context.
*/
const LazyField = React.lazy(() => import('./management_app/components/field'));
const LazyField = React.lazy(() => import('./management-app/components/field'));
export { LazyField };

export function plugin(initializerContext: PluginInitializerContext) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,15 @@ import {
import { FieldSetting } from './types';
import { AdvancedSettingsComponent } from './advanced_settings';
import { notificationServiceMock, docLinksServiceMock } from '../../../../core/public/mocks';
import { ComponentRegistry } from '../component_registry';
import { ComponentRegistry } from '../component-registry';

jest.mock('./components/field', () => ({
Field: () => {
return 'field';
},
}));

jest.mock('./components/call_outs', () => ({
jest.mock('./components/call-outs', () => ({
CallOuts: () => {
return 'callOuts';
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ import { Subscription } from 'rxjs';
import { Comparators, EuiFlexGroup, EuiFlexItem, EuiSpacer, Query } from '@elastic/eui';

import { useParams } from 'react-router-dom';
import { CallOuts } from './components/call_outs';
import { CallOuts } from './components/call-outs';
import { Search } from './components/search';
import { Form } from './components/form';
import { AdvancedSettingsVoiceAnnouncement } from './components/advanced_settings_voice_announcement';
import { AdvancedSettingsVoiceAnnouncement } from './components/advanced-settings-voice-announcement';
import { IUiSettingsClient, DocLinksStart, ToastsStart } from '../../../../core/public/';
import { ComponentRegistry } from '../';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
* GitHub history for details.
*/

import { ComponentRegistry } from './component_registry';
import { ComponentRegistry } from './component-registry';

const register = jest.fn();
const get = jest.fn();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
import { i18n } from '@osd/i18n';
import { CoreSetup, Plugin } from 'opensearch-dashboards/public';
import { FeatureCatalogueCategory } from '../../home/public';
import { ComponentRegistry } from './component_registry';
import { ComponentRegistry } from './component-registry';
import { AdvancedSettingsSetup, AdvancedSettingsStart, AdvancedSettingsPluginSetup } from './types';

const component = new ComponentRegistry();
Expand All @@ -52,7 +52,7 @@ export class AdvancedSettingsPlugin
order: 3,
async mount(params) {
const { mountManagementSection } = await import(
'./management_app/mount_management_section'
'./management-app/mount_management_section'
);
return mountManagementSection(core.getStartServices, params, component.start);
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
* GitHub history for details.
*/

import { ComponentRegistry } from './component_registry';
import { ComponentRegistry } from './component-registry';
import { HomePublicPluginSetup } from '../../home/public';

import { ManagementSetup } from '../../management/public';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ import { TelemetryPluginSetup } from 'src/plugins/telemetry/public';
import { PRIVACY_STATEMENT_URL } from '../../../telemetry/common/constants';
import { OptInExampleFlyout } from './opt_in_example_flyout';
import { OptInSecurityExampleFlyout } from './opt_in_security_example_flyout';
import { LazyField } from '../../../advanced_settings/public';
import { LazyField } from '../../../advanced-settings/public';
import { ToastsStart } from '../../../../core/public';

type TelemetryService = TelemetryPluginSetup['telemetryService'];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
* Modifications Copyright OpenSearch Contributors. See
* GitHub history for details.
*/
import { AdvancedSettingsSetup } from 'src/plugins/advanced_settings/public';
import { AdvancedSettingsSetup } from 'src/plugins/advanced-settings/public';
import { TelemetryPluginSetup } from 'src/plugins/telemetry/public';
import { Plugin, CoreStart, CoreSetup } from '../../../core/public';

Expand Down