Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ESSIF-Lab
eSSIF-Lab framework
Commits
e6e5b14e
Commit
e6e5b14e
authored
Oct 06, 2020
by
fmerg
Browse files
Factor out styles
parent
f3092038
Pipeline
#15391
passed with stage
in 1 minute and 29 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/components/index.js
View file @
e6e5b14e
...
...
@@ -6,15 +6,22 @@ const React = require('react');
const
{
Link
}
=
require
(
'
react-router-dom
'
);
const
{
Tooltip
}
=
require
(
'
@material-ui/core
'
)
const
popupStyle
=
{
fontSize
:
'
14px
'
,
};
const
textStyle
=
{
fontWeight
:
'
bold
'
,
};
function
get_pathname
(
reference
)
{
return
{
pathname
:
TERMS_DIR
+
reference
};
}
const
Term
=
({
children
,
reference
,
popup
})
=>
{
return
(
<
Tooltip
title
=
{
<
span
style
=
{
{
fontSize
:
'
14px
'
}
}
>
{
popup
}
<
/span>} arrow={true}
>
<
Tooltip
title
=
{
<
span
style
=
{
popupStyle
}
>
{
popup
}
<
/span>} arrow={true}
>
<
Link
to
=
{
get_pathname
(
reference
)
}
>
<
span
style
=
{
{
fontWeight
:
'
bold
'
}}
>
{
children
}
<
/span
>
<
span
style
=
{
textStyle
}
>
{
children
}
<
/span
>
<
/Link
>
<
/Tooltip
>
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment