mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
[Lens/SCSS] Delete and migrate reference_lines.scss
file (#209982)
## Summary Part of https://github.com/elastic/kibana/issues/208908 Replaces scss to css-in-js. ### Checklist - [x] The PR description includes the appropriate Release Notes section, and the correct `release_note:*` label is applied per the [guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process) --------- Co-authored-by: Marta Bondyra <4283304+mbondyra@users.noreply.github.com>
This commit is contained in:
parent
8cb484cb8d
commit
3b3bbb1a85
5 changed files with 27 additions and 24 deletions
|
@ -8,7 +8,6 @@
|
|||
*/
|
||||
|
||||
import './annotations.scss';
|
||||
import './reference_lines/reference_lines.scss';
|
||||
|
||||
import React, { Fragment } from 'react';
|
||||
import { snakeCase } from 'lodash';
|
||||
|
|
|
@ -1,18 +0,0 @@
|
|||
.xyDecorationRotatedWrapper {
|
||||
display: inline-block;
|
||||
overflow: hidden;
|
||||
line-height: 1.5;
|
||||
|
||||
.xyDecorationRotatedWrapper__label {
|
||||
display: inline-block;
|
||||
white-space: nowrap;
|
||||
transform: translate(0, 100%) rotate(-90deg);
|
||||
transform-origin: 0 0;
|
||||
|
||||
&::after {
|
||||
content: '';
|
||||
float: left;
|
||||
margin-top: 100%;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -7,8 +7,6 @@
|
|||
* License v3.0 only", or the "Server Side Public License, v 1".
|
||||
*/
|
||||
|
||||
import './reference_lines.scss';
|
||||
|
||||
import React from 'react';
|
||||
import { Position } from '@elastic/charts';
|
||||
import type { FieldFormat } from '@kbn/field-formats-plugin/common';
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
import React from 'react';
|
||||
import { Position } from '@elastic/charts';
|
||||
import { EuiFlexGroup, EuiIcon, EuiIconProps, EuiText } from '@elastic/eui';
|
||||
import { css } from '@emotion/react';
|
||||
import type {
|
||||
IconPosition,
|
||||
ReferenceLineDecorationConfig,
|
||||
|
@ -123,9 +124,12 @@ export function MarkerBody({
|
|||
<div
|
||||
className="xyDecorationRotatedWrapper"
|
||||
data-test-subj="xyVisAnnotationText"
|
||||
css={{
|
||||
width: LINES_MARKER_SIZE,
|
||||
}}
|
||||
css={[
|
||||
xyDecorationRotatedWrapperStyles,
|
||||
{
|
||||
maxWidth: LINES_MARKER_SIZE,
|
||||
},
|
||||
]}
|
||||
>
|
||||
<div
|
||||
className="eui-textTruncate xyDecorationRotatedWrapper__label"
|
||||
|
@ -221,3 +225,22 @@ export function Marker({
|
|||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
const xyDecorationRotatedWrapperStyles = css({
|
||||
display: 'inline-block',
|
||||
overflow: 'hidden',
|
||||
lineHeight: 1.5,
|
||||
|
||||
'& .xyDecorationRotatedWrapper__label': {
|
||||
display: 'inline-block',
|
||||
whiteSpace: 'nowrap',
|
||||
transform: 'translate(0, 100%) rotate(-90deg)',
|
||||
transformOrigin: '0 0',
|
||||
|
||||
'&::after': {
|
||||
content: '""',
|
||||
float: 'left',
|
||||
marginTop: '100%',
|
||||
},
|
||||
},
|
||||
});
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
"common/**/*",
|
||||
"public/**/*",
|
||||
"server/**/*",
|
||||
"../../../../../../typings/emotion.d.ts"
|
||||
],
|
||||
"kbn_references": [
|
||||
{ "path": "../tsconfig.json" },
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue