diff --git a/src/plugins/vis_type_table/public/paginated_table/paginated_table.test.ts b/src/plugins/vis_type_table/public/paginated_table/paginated_table.test.ts
index de253f26ff9e..ec61a0a4efca 100644
--- a/src/plugins/vis_type_table/public/paginated_table/paginated_table.test.ts
+++ b/src/plugins/vis_type_table/public/paginated_table/paginated_table.test.ts
@@ -27,7 +27,7 @@ import { getAngularModule } from '../get_inner_angular';
import { initTableVisLegacyModule } from '../table_vis_legacy_module';
import { coreMock } from '../../../../core/public/mocks';
-jest.mock('../../../kibana_legacy/public/angular/angular_config', () => ({
+jest.mock('../../../opensearch_dashboards_legacy/public/angular/angular_config', () => ({
configureAppAngularModule: () => {},
}));
@@ -73,7 +73,7 @@ describe('Table Vis - Paginated table', () => {
const initLocalAngular = () => {
const tableVisModule = getAngularModule(
- 'kibana/table_vis',
+ 'opensearch-dashboards/table_vis',
coreMock.createStart(),
coreMock.createPluginInitializerContext()
);
@@ -81,7 +81,7 @@ describe('Table Vis - Paginated table', () => {
};
beforeEach(initLocalAngular);
- beforeEach(angular.mock.module('kibana/table_vis'));
+ beforeEach(angular.mock.module('opensearch-dashboards/table_vis'));
beforeEach(
angular.mock.inject((_$rootScope_: IRootScopeService, _$compile_: ICompileService) => {
diff --git a/src/plugins/vis_type_table/public/paginated_table/rows.js b/src/plugins/vis_type_table/public/paginated_table/rows.js
index d8f01a10c63f..c4da812fbf87 100644
--- a/src/plugins/vis_type_table/public/paginated_table/rows.js
+++ b/src/plugins/vis_type_table/public/paginated_table/rows.js
@@ -22,7 +22,7 @@ import _ from 'lodash';
import angular from 'angular';
import tableCellFilterHtml from './table_cell_filter.html';
-export function KbnRows($compile) {
+export function OsdRows($compile) {
return {
restrict: 'A',
link: function ($scope, $el, attr) {
@@ -33,7 +33,7 @@ export function KbnRows($compile) {
function createFilterableCell(value) {
const $template = $(tableCellFilterHtml);
- $template.addClass('kbnTableCellFilter__hover');
+ $template.addClass('osdTableCellFilter__hover');
const scope = $scope.$new();
@@ -106,7 +106,7 @@ export function KbnRows($compile) {
$tr.append($cell);
}
- $scope.$watchMulti([attr.kbnRows, attr.kbnRowsMin], function (vals) {
+ $scope.$watchMulti([attr.osdRows, attr.osdRowsMin], function (vals) {
let rows = vals[0];
const min = vals[1];
diff --git a/src/plugins/vis_type_table/public/paginated_table/table_cell_filter.html b/src/plugins/vis_type_table/public/paginated_table/table_cell_filter.html
index 57ecb9b22161..a9185884dae5 100644
--- a/src/plugins/vis_type_table/public/paginated_table/table_cell_filter.html
+++ b/src/plugins/vis_type_table/public/paginated_table/table_cell_filter.html
@@ -1,9 +1,9 @@
-
+
, void> {
);
}
- public start(core: CoreStart, { data, kibanaLegacy }: TablePluginStartDependencies) {
+ public start(core: CoreStart, { data, opensearchDashboardsLegacy }: TablePluginStartDependencies) {
setFormatService(data.fieldFormats);
- setKibanaLegacy(kibanaLegacy);
+ setOpenSearchDashboardsLegacy(opensearchDashboardsLegacy);
}
}
diff --git a/src/plugins/vis_type_table/public/services.ts b/src/plugins/vis_type_table/public/services.ts
index b4f996f078f6..ec2cbd862d6d 100644
--- a/src/plugins/vis_type_table/public/services.ts
+++ b/src/plugins/vis_type_table/public/services.ts
@@ -17,14 +17,14 @@
* under the License.
*/
-import { createGetterSetter } from '../../kibana_utils/public';
+import { createGetterSetter } from '../../opensearch_dashboards_utils/public';
import { DataPublicPluginStart } from '../../data/public';
-import { KibanaLegacyStart } from '../../kibana_legacy/public';
+import { OpenSearchDashboardsLegacyStart } from '../../opensearch_dashboards_legacy/public';
export const [getFormatService, setFormatService] = createGetterSetter<
DataPublicPluginStart['fieldFormats']
>('table data.fieldFormats');
-export const [getKibanaLegacy, setKibanaLegacy] = createGetterSetter(
- 'table kibanaLegacy'
+export const [getOpenSearchDashboardsLegacy, setOpenSearchDashboardsLegacy] = createGetterSetter(
+ 'table opensearchDashboardsLegacy'
);
diff --git a/src/plugins/vis_type_table/public/table_vis.html b/src/plugins/vis_type_table/public/table_vis.html
index f721b670400d..169b53390fe3 100644
--- a/src/plugins/vis_type_table/public/table_vis.html
+++ b/src/plugins/vis_type_table/public/table_vis.html
@@ -1,4 +1,4 @@
-
+
diff --git a/src/plugins/vis_type_table/public/table_vis_controller.js b/src/plugins/vis_type_table/public/table_vis_controller.js
index 8a620df98609..ea73a8728362 100644
--- a/src/plugins/vis_type_table/public/table_vis_controller.js
+++ b/src/plugins/vis_type_table/public/table_vis_controller.js
@@ -29,15 +29,15 @@ export function TableVisController($scope) {
/**
* Recreate the entire table when:
- * - the underlying data changes (esResponse)
+ * - the underlying data changes (opensearchResponse)
* - one of the view options changes (vis.params)
*/
$scope.$watch('renderComplete', function () {
let tableGroups = ($scope.tableGroups = null);
let hasSomeRows = ($scope.hasSomeRows = null);
- if ($scope.esResponse) {
- tableGroups = $scope.esResponse;
+ if ($scope.opensearchResponse) {
+ tableGroups = $scope.opensearchResponse;
hasSomeRows = tableGroups.tables.some(function haveRows(table) {
if (table.tables) return table.tables.some(haveRows);
diff --git a/src/plugins/vis_type_table/public/table_vis_controller.test.ts b/src/plugins/vis_type_table/public/table_vis_controller.test.ts
index 035ca044137e..47260e33d1d5 100644
--- a/src/plugins/vis_type_table/public/table_vis_controller.test.ts
+++ b/src/plugins/vis_type_table/public/table_vis_controller.test.ts
@@ -38,7 +38,7 @@ const { createAggConfigs } = searchServiceMock.createStartContract().aggs;
const { tabifyAggResponse } = search;
-jest.mock('../../kibana_legacy/public/angular/angular_config', () => ({
+jest.mock('../../opensearch_dashboards_legacy/public/angular/angular_config', () => ({
configureAppAngularModule: () => {},
}));
@@ -85,7 +85,7 @@ describe('Table Vis - Controller', () => {
const initLocalAngular = () => {
const tableVisModule = getAngularModule(
- 'kibana/table_vis',
+ 'opensearch-dashboards/table_vis',
coreMock.createStart(),
coreMock.createPluginInitializerContext()
);
@@ -93,7 +93,7 @@ describe('Table Vis - Controller', () => {
};
beforeEach(initLocalAngular);
- beforeEach(angular.mock.module('kibana/table_vis'));
+ beforeEach(angular.mock.module('opensearch-dashboards/table_vis'));
beforeEach(
angular.mock.inject((_$rootScope_: IRootScopeService, _$compile_: ICompileService) => {
@@ -173,7 +173,7 @@ describe('Table Vis - Controller', () => {
};
$el = $(' ')
- .attr('ng-controller', 'KbnTableVisController')
+ .attr('ng-controller', 'OsdTableVisController')
.attr('ng-init', 'newScope(this)');
$compile($el)($rootScope);
@@ -181,13 +181,13 @@ describe('Table Vis - Controller', () => {
// put a response into the controller
function attachEsResponseToScope(resp: object) {
- $rootScope.esResponse = resp;
+ $rootScope.opensearchResponse = resp;
$rootScope.$apply();
}
// remove the response from the controller
function removeEsResponseFromScope() {
- delete $rootScope.esResponse;
+ delete $rootScope.opensearchResponse;
$rootScope.renderComplete = () => {};
$rootScope.$apply();
}
diff --git a/src/plugins/vis_type_table/public/table_vis_fn.test.ts b/src/plugins/vis_type_table/public/table_vis_fn.test.ts
index 2471522544fd..4a6dceb837d4 100644
--- a/src/plugins/vis_type_table/public/table_vis_fn.test.ts
+++ b/src/plugins/vis_type_table/public/table_vis_fn.test.ts
@@ -31,7 +31,7 @@ jest.mock('./table_vis_response_handler', () => ({
describe('interpreter/functions#table', () => {
const fn = functionWrapper(createTableVisFn());
const context = {
- type: 'kibana_datatable',
+ type: 'opensearch_dashboards_datatable',
rows: [{ 'col-0-1': 0 }],
columns: [{ id: 'col-0-1', name: 'Count' }],
};
diff --git a/src/plugins/vis_type_table/public/table_vis_fn.ts b/src/plugins/vis_type_table/public/table_vis_fn.ts
index 9739a7a284e6..faa86650dd42 100644
--- a/src/plugins/vis_type_table/public/table_vis_fn.ts
+++ b/src/plugins/vis_type_table/public/table_vis_fn.ts
@@ -17,11 +17,11 @@
* under the License.
*/
-import { i18n } from '@kbn/i18n';
+import { i18n } from '@osd/i18n';
import { tableVisResponseHandler, TableContext } from './table_vis_response_handler';
-import { ExpressionFunctionDefinition, KibanaDatatable, Render } from '../../expressions/public';
+import { ExpressionFunctionDefinition, OpenSearchDashboardsDatatable, Render } from '../../expressions/public';
-export type Input = KibanaDatatable;
+export type Input = OpenSearchDashboardsDatatable;
interface Arguments {
visConfig: string | null;
@@ -39,14 +39,14 @@ interface RenderValue {
}
export const createTableVisFn = (): ExpressionFunctionDefinition<
- 'kibana_table',
+ 'opensearch_dashboards_table',
Input,
Arguments,
Render
> => ({
- name: 'kibana_table',
+ name: 'opensearch_dashboards_table',
type: 'render',
- inputTypes: ['kibana_datatable'],
+ inputTypes: ['opensearch_dashboards_datatable'],
help: i18n.translate('visTypeTable.function.help', {
defaultMessage: 'Table visualization',
}),
diff --git a/src/plugins/vis_type_table/public/table_vis_legacy_module.ts b/src/plugins/vis_type_table/public/table_vis_legacy_module.ts
index 57d8b7c448b4..a9e4792cdf89 100644
--- a/src/plugins/vis_type_table/public/table_vis_legacy_module.ts
+++ b/src/plugins/vis_type_table/public/table_vis_legacy_module.ts
@@ -22,20 +22,20 @@ import { IModule } from 'angular';
// @ts-ignore
import { TableVisController } from './table_vis_controller.js';
// @ts-ignore
-import { KbnAggTable } from './agg_table/agg_table';
+import { OsdAggTable } from './agg_table/agg_table';
// @ts-ignore
-import { KbnAggTableGroup } from './agg_table/agg_table_group';
+import { OsdAggTableGroup } from './agg_table/agg_table_group';
// @ts-ignore
-import { KbnRows } from './paginated_table/rows';
+import { OsdRows } from './paginated_table/rows';
// @ts-ignore
import { PaginatedTable } from './paginated_table/paginated_table';
/** @internal */
export const initTableVisLegacyModule = (angularIns: IModule): void => {
angularIns
- .controller('KbnTableVisController', TableVisController)
- .directive('kbnAggTable', KbnAggTable)
- .directive('kbnAggTableGroup', KbnAggTableGroup)
- .directive('kbnRows', KbnRows)
+ .controller('OsdTableVisController', TableVisController)
+ .directive('osdAggTable', OsdAggTable)
+ .directive('osdAggTableGroup', OsdAggTableGroup)
+ .directive('osdRows', OsdRows)
.directive('paginatedTable', PaginatedTable);
};
diff --git a/src/plugins/vis_type_table/public/table_vis_response_handler.ts b/src/plugins/vis_type_table/public/table_vis_response_handler.ts
index 4bf33c876dff..b4b3040ae6c7 100644
--- a/src/plugins/vis_type_table/public/table_vis_response_handler.ts
+++ b/src/plugins/vis_type_table/public/table_vis_response_handler.ts
@@ -17,7 +17,7 @@
* under the License.
*/
-import { Required } from '@kbn/utility-types';
+import { Required } from '@osd/utility-types';
import { getFormatService } from './services';
import { Input } from './table_vis_fn';
diff --git a/src/plugins/vis_type_table/public/table_vis_type.ts b/src/plugins/vis_type_table/public/table_vis_type.ts
index 95f4f06ee611..8425440b5764 100644
--- a/src/plugins/vis_type_table/public/table_vis_type.ts
+++ b/src/plugins/vis_type_table/public/table_vis_type.ts
@@ -16,8 +16,8 @@
* specific language governing permissions and limitations
* under the License.
*/
-import { CoreSetup, PluginInitializerContext } from 'kibana/public';
-import { i18n } from '@kbn/i18n';
+import { CoreSetup, PluginInitializerContext } from 'opensearch-dashboards/public';
+import { i18n } from '@osd/i18n';
import { AggGroupNames } from '../../data/public';
import { Schemas } from '../../vis_default_editor/public';
import { BaseVisTypeOptions } from '../../visualizations/public';
diff --git a/src/plugins/vis_type_table/public/vis_controller.ts b/src/plugins/vis_type_table/public/vis_controller.ts
index 178180866026..27aec9e8b779 100644
--- a/src/plugins/vis_type_table/public/vis_controller.ts
+++ b/src/plugins/vis_type_table/public/vis_controller.ts
@@ -16,16 +16,16 @@
* specific language governing permissions and limitations
* under the License.
*/
-import { CoreSetup, PluginInitializerContext } from 'kibana/public';
+import { CoreSetup, PluginInitializerContext } from 'opensearch-dashboards/public';
import angular, { IModule, auto, IRootScopeService, IScope, ICompileService } from 'angular';
import $ from 'jquery';
import { VisParams, ExprVis } from '../../visualizations/public';
import { getAngularModule } from './get_inner_angular';
-import { getKibanaLegacy } from './services';
+import { getOpenSearchDashboardsLegacy } from './services';
import { initTableVisLegacyModule } from './table_vis_legacy_module';
-const innerAngularName = 'kibana/table_vis';
+const innerAngularName = 'opensearch-dashboards/table_vis';
export function getTableVisualizationControllerClass(
core: CoreSetup,
@@ -64,8 +64,8 @@ export function getTableVisualizationControllerClass(
}
}
- async render(esResponse: object, visParams: VisParams): Promise {
- getKibanaLegacy().loadFontAwesome();
+ async render(opensearchResponse: object, visParams: VisParams): Promise {
+ getOpenSearchDashboardsLegacy().loadFontAwesome();
await this.initLocalAngular();
return new Promise(async (resolve, reject) => {
@@ -90,7 +90,7 @@ export function getTableVisualizationControllerClass(
// the list above that it is passing through
this.$scope.vis = this.vis;
this.$scope.visState = { params: visParams, title: visParams.title };
- this.$scope.esResponse = esResponse;
+ this.$scope.opensearchResponse = opensearchResponse;
this.$scope.visParams = visParams;
this.$scope.renderComplete = resolve;
diff --git a/src/plugins/vis_type_table/server/index.ts b/src/plugins/vis_type_table/server/index.ts
index 882958a28777..677c72d950c7 100644
--- a/src/plugins/vis_type_table/server/index.ts
+++ b/src/plugins/vis_type_table/server/index.ts
@@ -17,7 +17,7 @@
* under the License.
*/
-import { PluginConfigDescriptor } from 'kibana/server';
+import { PluginConfigDescriptor } from 'opensearch-dashboards/server';
import { configSchema, ConfigSchema } from '../config';
|