bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/chat/styles.js
gabriellpr a4bf69aeba adding url styles
...

styling external links inside the banner

Refactoring code

adding underline on hover and focus

removing hasLiink
2022-05-26 15:10:20 -03:00

123 lines
2.4 KiB
JavaScript

import styled from 'styled-components';
import {
colorWhite,
colorGrayDark,
colorPrimary
} from '/imports/ui/stylesheets/styled-components/palette';
import { smallOnly } from '/imports/ui/stylesheets/styled-components/breakpoints';
import Button from '/imports/ui/components/common/button/component';
import {
mdPaddingX,
mdPaddingY,
pollHeaderOffset,
borderSizeLarge,
borderSize,
} from '/imports/ui/stylesheets/styled-components/general';
import { DivElipsis } from '/imports/ui/stylesheets/styled-components/placeholders';
const Chat = styled.div`
background-color: ${colorWhite};
padding: ${mdPaddingX} ${mdPaddingY} ${mdPaddingX} ${mdPaddingX};
display: flex;
flex-grow: 1;
flex-direction: column;
justify-content: space-around;
overflow: hidden;
height: 100%;
a {
color: ${colorPrimary};
text-decoration: none;
&:focus {
color: ${colorPrimary};
text-decoration: underline;
}
&:hover {
filter: brightness(90%);
text-decoration: underline;
}
&:active {
filter: brightness(85%);
text-decoration: underline;
}
&:hover:focus{
filter: brightness(90%);
text-decoration: underline;
}
&:focus:active {
filter: brightness(85%);
text-decoration: underline;
}
}
u {
text-decoration-line: none;
}
${({ isChrome }) => isChrome && `
transform: translateZ(0);
`}
@media ${smallOnly} {
transform: none !important;
}
`;
const Header = styled.header`
position: relative;
top: ${pollHeaderOffset};
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
`;
const Title = styled(DivElipsis)`
flex: 1;
& > button, button:hover {
max-width: 98%;
}
`;
const HideChatButton = styled(Button)`
position: relative;
background-color: ${colorWhite};
display: block;
margin: ${borderSizeLarge};
margin-bottom: ${borderSize};
padding-left: 0;
padding-right: inherit;
z-index: 3;
[dir="rtl"] & {
padding-left: inherit;
padding-right: 0;
}
& > i {
color: ${colorGrayDark};
font-size: smaller;
[dir="rtl"] & {
-webkit-transform: scale(-1, 1);
-moz-transform: scale(-1, 1);
-ms-transform: scale(-1, 1);
-o-transform: scale(-1, 1);
transform: scale(-1, 1);
}
}
&:hover {
background-color: ${colorWhite};
}
`;
export default {
Chat,
Header,
Title,
HideChatButton,
};