bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/presentation/presentation-toolbar/styles.js

287 lines
5.6 KiB
JavaScript
Raw Normal View History

2021-11-08 21:09:56 +08:00
import styled from 'styled-components';
import QuickPollDropdownContainer from '/imports/ui/components/actions-bar/quick-poll-dropdown/container';
import {
colorOffWhite,
colorBlueLightest,
toolbarButtonColor,
colorDanger,
colorWhite,
colorGrayDark,
2021-11-08 21:09:56 +08:00
} from '/imports/ui/stylesheets/styled-components/palette';
import {
whiteboardToolbarMargin,
whiteboardToolbarPaddingSm,
whiteboardToolbarPadding,
borderSize,
smPaddingY,
borderSizeLarge,
smPaddingX,
2021-11-08 21:09:56 +08:00
} from '/imports/ui/stylesheets/styled-components/general';
2022-02-15 04:20:50 +08:00
import Button from '/imports/ui/components/common/button/component';
2021-11-08 21:09:56 +08:00
const PresentationToolbarWrapper = styled.div`
position: absolute;
2021-11-08 21:09:56 +08:00
align-self: center;
z-index: 1;
background-color: ${colorOffWhite};
border-top: 1px solid ${colorBlueLightest};
min-width: fit-content;
width: 100%;
bottom: 0px;
2021-11-08 21:09:56 +08:00
display: grid;
grid-template-columns: 1fr 1fr 1fr;
padding: 2px;
2021-11-08 21:09:56 +08:00
select {
&:-moz-focusring {
outline: none;
}
border: 0;
background-color: ${colorOffWhite};
cursor: pointer;
margin: 0 ${whiteboardToolbarMargin} 0 0;
padding: ${whiteboardToolbarPadding};
padding-left: ${whiteboardToolbarPaddingSm};
[dir="rtl"] & {
margin: 0 0 0 ${whiteboardToolbarMargin};
padding: ${whiteboardToolbarPadding};
padding-right: ${whiteboardToolbarPaddingSm};
}
& > option {
color: ${toolbarButtonColor};
background-color: ${colorOffWhite};
}
}
i {
color: ${toolbarButtonColor};
display: flex;
justify-content: center;
align-items: center;
}
`;
const QuickPollButton = styled(QuickPollDropdownContainer)`
position: relative;
color: ${toolbarButtonColor};
background-color: ${colorOffWhite};
border-radius: 0;
box-shadow: none !important;
border: 0;
&:focus {
background-color: ${colorOffWhite};
}
`;
const PresentationSlideControls = styled.div`
justify-content: center;
padding-left: ${whiteboardToolbarPadding};
padding-right: ${whiteboardToolbarPadding};
display: flex;
flex-direction: row;
align-items: center;
& > button {
padding: ${whiteboardToolbarPadding};
}
`;
const PrevSlideButton = styled(Button)`
2022-07-05 20:05:46 +08:00
i {
2021-11-08 21:09:56 +08:00
font-size: 1rem;
2022-08-16 01:56:10 +08:00
padding-left: 20%;
2021-11-08 21:09:56 +08:00
[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);
}
}
`;
const NextSlideButton = styled(Button)`
2022-07-05 20:05:46 +08:00
i {
2021-11-08 21:09:56 +08:00
font-size: 1rem;
2022-08-16 01:56:10 +08:00
padding-left: 60%;
2022-07-05 20:05:46 +08:00
2021-11-08 21:09:56 +08:00
[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);
}
}
`;
const SkipSlideSelect = styled.select`
padding: 0 ${smPaddingY};
margin: ${borderSize};
margin-left: ${whiteboardToolbarMargin};
[dir="rtl"] & {
margin: ${borderSize};
margin-right: ${whiteboardToolbarMargin};
}
&:-moz-focusring {
outline: none;
}
&:hover {
outline: transparent;
outline-style: dotted;
outline-width: ${borderSize};
}
&:focus {
outline: transparent;
outline-width: ${borderSize};
outline-style: solid;
}
`;
const PresentationZoomControls = styled.div`
justify-content: flex-end;
padding: 0 ${whiteboardToolbarPadding} 0 0;
[dir="rtl"] & {
padding: 0 0 0 ${whiteboardToolbarPadding};
}
display: flex;
flex-direction: row;
align-items: center;
button {
padding: ${whiteboardToolbarPadding};
}
i {
font-size: 1.2rem;
}
`;
const FitToWidthButton = styled(Button)`
border: none !important;
& > i {
font-size: 1.2rem;
[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);
}
}
margin-left: ${whiteboardToolbarMargin};
margin-right: ${whiteboardToolbarMargin};
position: relative;
color: ${toolbarButtonColor};
background-color: ${colorOffWhite};
border-radius: 0;
box-shadow: none !important;
border: 0;
&:focus {
background-color: ${colorOffWhite};
border: 0;
}
2022-08-15 06:49:39 +08:00
${({ panning }) => panning && `
> span {
background-color: #DCE4EC;
}
`}
2021-11-08 21:09:56 +08:00
`;
const MultiUserTool = styled.span`
background-color: ${colorDanger};
border-radius: 50%;
width: 1rem;
height: 1rem;
position: relative;
z-index: 2;
bottom: 0.5rem;
color: ${colorWhite};
display: flex;
justify-content: center;
align-items: center;
box-shadow: 1px 1px ${borderSizeLarge} ${colorGrayDark};
font-size: ${smPaddingX};
2022-08-16 01:56:10 +08:00
[dir="ltr"] & {
right: 1rem;
}
[dir="rtl"] & {
left: 1rem;
}
`;
const MUTPlaceholder = styled.div`
width: 1rem;
height: 1rem;
position: relative;
bottom: 0.5rem;
2022-08-16 01:56:10 +08:00
[dir="ltr"] & {
right: 1rem;
}
[dir="rtl"] & {
left: 1rem;
}
`;
const WBAccessButton = styled(Button)`
border: none !important;
2022-08-16 01:56:10 +08:00
i {
font-size: 1.2rem;
[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);
}
}
position: relative;
color: ${toolbarButtonColor};
background-color: ${colorOffWhite};
border-radius: 0;
box-shadow: none !important;
border: 0;
&:focus {
background-color: ${colorOffWhite};
border: 0;
}
`;
2021-11-08 21:09:56 +08:00
export default {
PresentationToolbarWrapper,
QuickPollButton,
PresentationSlideControls,
PrevSlideButton,
NextSlideButton,
SkipSlideSelect,
PresentationZoomControls,
FitToWidthButton,
MultiUserTool,
WBAccessButton,
MUTPlaceholder,
2021-11-08 21:09:56 +08:00
};