Skip to content

Commit

Permalink
Restore styles to original location
Browse files Browse the repository at this point in the history
  • Loading branch information
Tostti committed Nov 14, 2024
1 parent 9454f79 commit 3cbedb2
Show file tree
Hide file tree
Showing 3 changed files with 95 additions and 97 deletions.
94 changes: 94 additions & 0 deletions plugins/main/public/components/common/doc-viewer/doc-viewer.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
.wzDocViewerTable {
pre,
.wzDocViewer__value {
display: inline-block;
word-break: break-all;
word-wrap: break-word;
white-space: pre-wrap;
color: $euiColorFullShade;
vertical-align: top;
padding-top: 2px;
}

.wzDocViewer__field {
padding-top: 8px;
}

.dscFieldName {
color: $euiColorDarkShade;
}

td,
pre {
font-family: $euiCodeFontFamily;
}

tr {
position: relative;
}

tr:first-child td {
border-top-color: transparent;
}

tr:hover {
.wzDocViewer__buttons {
display: flex;
gap: 2px;
position: absolute;
right: 0;
top: 0;
transform: translateY(calc(50% - 8px));

> span {
z-index: 2;
}

.wzDocViewer__actionButton {
opacity: 1;
}

&::before {
content: '';
position: absolute;
display: block;
right: 0;
top: 0;
height: 100%;
width: 100%;
background-image: linear-gradient(
to right,
transparent 0,
aliceblue 4px
);
z-index: 1;
}
}
}
}

.wzDocViewer__buttons,
.wzDocViewer__field {
white-space: nowrap;
}

.wzDocViewer__buttons {
display: none;
}

.wzDocViewer__field {
width: 160px;
white-space: break-spaces;
}

.wzDocViewer__actionButton {
opacity: 0;

&:hover {
opacity: 1;
}
}

.wzDocViewer__warning {
margin-right: $euiSizeS;
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { FILTER_OPERATOR } from '../data-source';
import { DocViewTableRowBtnFilterAdd } from './table-row-btn-filter-add';
import { DocViewTableRowBtnFilterRemove } from './table-row-btn-filter-remove';
import { DocViewTableRowBtnFilterExists } from './table-row-btn-filter-exists';
import './doc-viewer.scss';
import { onFilterCellActions } from '../data-grid/filter-cell-actions';
import { Filter } from '../../../../../../src/plugins/data/common';

Expand Down
97 changes: 0 additions & 97 deletions plugins/main/public/styles/component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -108,100 +108,3 @@ kbn-dis doc-table .kbnDocViewer__warning {
display: flex;
flex-direction: row;
}

/* Custom docViewer styles */

.wzDocViewerTable {
pre,
.wzDocViewer__value {
display: inline-block;
word-break: break-all;
word-wrap: break-word;
white-space: pre-wrap;
color: $euiColorFullShade;
vertical-align: top;
padding-top: 2px;
}

.wzDocViewer__field {
padding-top: 8px;
}

.dscFieldName {
color: $euiColorDarkShade;
}

td,
pre {
font-family: $euiCodeFontFamily;
}

tr {
position: relative;
}

tr:first-child td {
border-top-color: transparent;
}

tr:hover {
.wzDocViewer__buttons {
display: flex;
gap: 2px;
position: absolute;
right: 0;
top: 0;
transform: translateY(calc(50% - 8px));

> span {
z-index: 2;
}

.wzDocViewer__actionButton {
opacity: 1;
}

&::before {
content: '';
position: absolute;
display: block;
right: 0;
top: 0;
height: 100%;
width: 100%;
background-image: linear-gradient(
to right,
transparent 0,
aliceblue 4px
);
z-index: 1;
}
}
}
}

.wzDocViewer__buttons,
.wzDocViewer__field {
white-space: nowrap;
}

.wzDocViewer__buttons {
display: none;
}

.wzDocViewer__field {
width: 160px;
white-space: break-spaces;
}

.wzDocViewer__actionButton {
opacity: 0;

&:hover {
opacity: 1;
}
}

.wzDocViewer__warning {
margin-right: $euiSizeS;
}

0 comments on commit 3cbedb2

Please sign in to comment.