diff --git a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js index f74e145865475d..0489de0e8e1ead 100644 --- a/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js +++ b/src/legacy/core_plugins/kibana/public/discover/__tests__/directives/field_chooser.js @@ -138,7 +138,7 @@ describe('discover field chooser directives', function() { describe('Field listing', function() { it('should have Selected Fields, Fields and Popular Fields sections', function() { - const headers = $elem.find('.sidebar-list-header'); + const headers = $elem.find('[data-test-subj="discover-sidebar-list-header"]'); expect(headers.length).to.be(3); }); @@ -168,7 +168,9 @@ describe('discover field chooser directives', function() { it('should show the popular fields header if there are popular fields', function() { const section = getSections($elem); expect(section.popular.hasClass('ng-hide')).to.be(false); - expect(section.popular.find('li:not(.sidebar-list-header)').length).to.be.above(0); + expect( + section.popular.find('li:not([data-test-subj="discover-sidebar-list-header"])').length + ).to.be.above(0); }); it('should not show the popular fields if there are not any', function() { @@ -190,7 +192,9 @@ describe('discover field chooser directives', function() { $scope.$digest(); expect(section.popular.hasClass('ng-hide')).to.be(true); - expect(section.popular.find('li:not(.sidebar-list-header)').length).to.be(0); + expect( + section.popular.find('li:not([data-test-subj="discover-sidebar-list-header"])').length + ).to.be(0); }); it('should move the field into selected when it is added to the columns array', function() { diff --git a/src/legacy/core_plugins/kibana/public/discover/np_ready/_discover.scss b/src/legacy/core_plugins/kibana/public/discover/np_ready/_discover.scss index 764dd4d2280d62..07f598dce377d0 100644 --- a/src/legacy/core_plugins/kibana/public/discover/np_ready/_discover.scss +++ b/src/legacy/core_plugins/kibana/public/discover/np_ready/_discover.scss @@ -8,10 +8,6 @@ flex-direction: column; height: 100%; overflow: hidden; - - .sidebar-container { - background-color: transparent; - } } .dscApp__header { diff --git a/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/_index.scss b/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/_index.scss index 2bfc74ffa02790..d4b365547b40c5 100644 --- a/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/_index.scss +++ b/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/_index.scss @@ -1,3 +1,2 @@ @import 'no_results'; @import 'histogram'; -@import './collapsible_sidebar/index'; diff --git a/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/collapsible_sidebar/_collapsible_sidebar.scss b/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/collapsible_sidebar/_collapsible_sidebar.scss deleted file mode 100644 index 5840ebc92578c7..00000000000000 --- a/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/collapsible_sidebar/_collapsible_sidebar.scss +++ /dev/null @@ -1,45 +0,0 @@ -// SASSTODO: Can't rename main class -// because it's also the name of the angular directive -.collapsible-sidebar { - .kbnCollapsibleSidebar__collapseButton { - position: absolute; - top: 0; - right: -21px; - cursor: pointer; - z-index: 1; - } - - &.closed { - width: 0 !important; - border-right-width: 0; - border-left-width: 0; - - > * { - visibility: hidden; - } - - .kbnCollapsibleSidebar__collapseButton { - visibility: visible; - - .chevron-cont:before { - content: '\F138'; - } - } - } -} - -.visEditor__content .collapsible-sidebar { - position: relative; -} - -@include euiBreakpoint('xs', 's', 'm') { - .collapsible-sidebar { - &.closed { - display: none; - } - - .kbnCollapsibleSidebar__collapseButton { - display: none; - } - } -} diff --git a/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/collapsible_sidebar/_index.scss b/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/collapsible_sidebar/_index.scss index 1409920d11aa7f..c408c87501117f 100644 --- a/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/collapsible_sidebar/_index.scss +++ b/src/legacy/core_plugins/kibana/public/discover/np_ready/angular/directives/collapsible_sidebar/_index.scss @@ -1,2 +1 @@ @import 'depth'; -@import 'collapsible_sidebar'; diff --git a/src/legacy/core_plugins/kibana/public/discover/np_ready/components/discover_grid/discover_grid.tsx b/src/legacy/core_plugins/kibana/public/discover/np_ready/components/discover_grid/discover_grid.tsx index f1210cc2382f43..cb2b9c0e441bec 100644 --- a/src/legacy/core_plugins/kibana/public/discover/np_ready/components/discover_grid/discover_grid.tsx +++ b/src/legacy/core_plugins/kibana/public/discover/np_ready/components/discover_grid/discover_grid.tsx @@ -137,7 +137,7 @@ export const DiscoverGrid = React.memo(function DiscoverGridInner({ onAddColumn, }: Props) { const actionColumnId = 'uniqueString'; // TODO should be guaranteed unique... - const lowestPageSize = 50; + const lowestPageSize = 500; const timeString = i18n.translate('kbn.discover.timeLabel', { defaultMessage: 'Time', }); @@ -338,7 +338,7 @@ export const DiscoverGrid = React.memo(function DiscoverGridInner({ ...pagination, onChangeItemsPerPage, onChangePage, - pageSizeOptions: [lowestPageSize, 100, 500], + pageSizeOptions: [lowestPageSize], }} toolbarVisibility={{ showColumnSelector: false, diff --git a/src/legacy/core_plugins/kibana/public/discover/np_ready/components/field_chooser/field_chooser.html b/src/legacy/core_plugins/kibana/public/discover/np_ready/components/field_chooser/field_chooser.html index 1c7435ad794a39..e406f17d682e9d 100644 --- a/src/legacy/core_plugins/kibana/public/discover/np_ready/components/field_chooser/field_chooser.html +++ b/src/legacy/core_plugins/kibana/public/discover/np_ready/components/field_chooser/field_chooser.html @@ -1,6 +1,8 @@ -
+
-
- +
@@ -25,6 +23,7 @@ tabindex="0" i18n-id="kbn.discover.fieldChooser.filter.selectedFieldsTitle" i18n-default-message="Selected fields" + data-test-subj="discover-sidebar-list-header" > -
diff --git a/test/functional/page_objects/discover_page.js b/test/functional/page_objects/discover_page.js index 5ccc5625849d27..9724395e57d47e 100644 --- a/test/functional/page_objects/discover_page.js +++ b/test/functional/page_objects/discover_page.js @@ -247,12 +247,12 @@ export function DiscoverPageProvider({ getService, getPageObjects }) { } async getAllFieldNames() { - const items = await find.allByCssSelector('.sidebar-item'); + const items = await find.allByCssSelector('.dscSidebarItem'); return await Promise.all(items.map(item => item.getVisibleText())); } async getSidebarWidth() { - const sidebar = await find.byCssSelector('.sidebar-list'); + const sidebar = await find.byCssSelector('.dscFieldChooser__section'); return await sidebar.getAttribute('clientWidth'); } diff --git a/x-pack/legacy/plugins/reporting/export_types/common/layouts/preserve_layout.css b/x-pack/legacy/plugins/reporting/export_types/common/layouts/preserve_layout.css index 2c203e507260fa..fce2f7fd6a0558 100644 --- a/x-pack/legacy/plugins/reporting/export_types/common/layouts/preserve_layout.css +++ b/x-pack/legacy/plugins/reporting/export_types/common/layouts/preserve_layout.css @@ -34,7 +34,6 @@ filter-bar, /* hide unusable controls */ discover-app .dscTimechart, -discover-app .sidebar-container, discover-app .kbnCollapsibleSidebar__collapseButton, discover-app navbar[name=discover-search], discover-app .discover-table-footer { diff --git a/x-pack/legacy/plugins/reporting/export_types/common/layouts/print.css b/x-pack/legacy/plugins/reporting/export_types/common/layouts/print.css index b5c9861208b7bd..813c6eeae0b503 100644 --- a/x-pack/legacy/plugins/reporting/export_types/common/layouts/print.css +++ b/x-pack/legacy/plugins/reporting/export_types/common/layouts/print.css @@ -33,7 +33,6 @@ filter-bar, /* hide unusable controls */ discover-app .dscTimechart, -discover-app .sidebar-container, discover-app .kbnCollapsibleSidebar__collapseButton, discover-app navbar[name="discover-search"], discover-app .discover-table-footer {