2021-10-26 03:21:27 +08:00
|
|
|
import styled from 'styled-components';
|
|
|
|
import { smallOnly } from '/imports/ui/stylesheets/styled-components/breakpoints';
|
|
|
|
import { ScrollboxVertical } from '/imports/ui/stylesheets/styled-components/scrollable';
|
|
|
|
import HoldButton from '/imports/ui/components/presentation/presentation-toolbar/zoom-tool/holdButton/component';
|
2022-02-15 04:20:50 +08:00
|
|
|
import Button from '/imports/ui/components/common/button/component';
|
2021-10-26 03:21:27 +08:00
|
|
|
import { FlexRow, FlexColumn } from '/imports/ui/stylesheets/styled-components/placeholders';
|
2021-10-26 20:37:26 +08:00
|
|
|
import {
|
|
|
|
colorDanger,
|
|
|
|
colorGray,
|
|
|
|
colorGrayLight,
|
|
|
|
colorGrayLighter,
|
|
|
|
colorWhite,
|
|
|
|
colorPrimary,
|
|
|
|
colorBlueLight,
|
|
|
|
} from '/imports/ui/stylesheets/styled-components/palette';
|
|
|
|
import { fontSizeSmall, fontSizeBase } from '/imports/ui/stylesheets/styled-components/typography';
|
|
|
|
import {
|
|
|
|
borderRadius,
|
|
|
|
borderSize,
|
|
|
|
lgPaddingX,
|
|
|
|
} from '/imports/ui/stylesheets/styled-components/general';
|
2021-10-26 03:21:27 +08:00
|
|
|
|
|
|
|
const BoxContainer = styled.div`
|
|
|
|
display: grid;
|
2022-02-11 22:15:50 +08:00
|
|
|
grid-template-columns: repeat(3, 1fr);
|
2021-10-26 03:21:27 +08:00
|
|
|
grid-gap: 1.6rem 1rem;
|
|
|
|
box-sizing: border-box;
|
|
|
|
padding-bottom: 1rem;
|
|
|
|
`;
|
|
|
|
|
|
|
|
const Alert = styled.div`
|
|
|
|
${({ valid }) => !valid && `
|
|
|
|
position: relative;
|
|
|
|
|
|
|
|
& > * {
|
2021-10-26 20:37:26 +08:00
|
|
|
border-color: ${colorDanger} !important;
|
|
|
|
color: ${colorDanger};
|
2021-10-26 03:21:27 +08:00
|
|
|
}
|
|
|
|
`}
|
2022-02-11 22:15:50 +08:00
|
|
|
|
|
|
|
grid-row: span 3;
|
|
|
|
|
|
|
|
& > div {
|
|
|
|
height: 25.2rem;
|
|
|
|
max-height: 25.2rem;
|
|
|
|
}
|
2021-10-26 03:21:27 +08:00
|
|
|
`;
|
|
|
|
|
|
|
|
const FreeJoinLabel = styled.label`
|
2021-10-26 20:37:26 +08:00
|
|
|
font-size: ${fontSizeSmall};
|
2021-10-26 03:21:27 +08:00
|
|
|
font-weight: bolder;
|
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
2021-10-26 20:37:26 +08:00
|
|
|
font-size: ${fontSizeSmall};
|
2021-10-26 03:21:27 +08:00
|
|
|
margin-bottom: 0;
|
|
|
|
|
|
|
|
& > * {
|
|
|
|
margin: 0 .5rem 0 0;
|
|
|
|
|
|
|
|
[dir="rtl"] & {
|
|
|
|
margin: 0 0 0 .5rem;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const BreakoutNameInput = styled.input`
|
|
|
|
width: 100%;
|
|
|
|
text-align: left;
|
|
|
|
font-weight: normal;
|
|
|
|
padding: .25rem;
|
|
|
|
margin: 0;
|
|
|
|
&::placeholder {
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorGray};
|
2021-10-26 03:21:27 +08:00
|
|
|
opacity: 1;
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const BreakoutBox = styled(ScrollboxVertical)`
|
|
|
|
width: 100%;
|
2022-02-11 22:15:50 +08:00
|
|
|
min-height: 6rem;
|
2021-10-26 03:21:27 +08:00
|
|
|
max-height: 8rem;
|
2021-10-26 20:37:26 +08:00
|
|
|
border: 1px solid ${colorGrayLighter};
|
|
|
|
border-radius: ${borderRadius};
|
2021-10-26 03:21:27 +08:00
|
|
|
`;
|
|
|
|
|
|
|
|
const SpanWarn = styled.span`
|
|
|
|
${({ valid }) => valid && `
|
|
|
|
display: none;
|
|
|
|
`}
|
|
|
|
|
|
|
|
${({ valid }) => !valid && `
|
|
|
|
margin: .25rem;
|
|
|
|
position: absolute;
|
2021-10-26 20:37:26 +08:00
|
|
|
font-size: ${fontSizeSmall};
|
|
|
|
color: ${colorDanger};
|
2021-10-26 03:21:27 +08:00
|
|
|
font-weight: 200;
|
|
|
|
white-space: nowrap;
|
|
|
|
`}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const RoomName = styled(BreakoutNameInput)`
|
|
|
|
${({ value }) => value.length === 0 && `
|
2021-10-26 20:37:26 +08:00
|
|
|
border-color: ${colorDanger} !important;
|
2021-10-26 03:21:27 +08:00
|
|
|
`}
|
|
|
|
|
|
|
|
${({ duplicated }) => duplicated === 0 && `
|
2021-10-26 20:37:26 +08:00
|
|
|
border-color: ${colorDanger} !important;
|
2021-10-26 03:21:27 +08:00
|
|
|
`}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const BreakoutSettings = styled.div`
|
|
|
|
display: grid;
|
|
|
|
grid-template-columns: 2fr 2fr 1fr;
|
|
|
|
grid-template-rows: 1fr;
|
|
|
|
grid-gap: 1rem;
|
|
|
|
|
|
|
|
@media ${smallOnly} {
|
|
|
|
grid-template-columns: 1fr ;
|
|
|
|
grid-template-rows: 1fr 1fr 1fr;
|
|
|
|
flex-direction: column;
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const FormLabel = styled.p`
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorGray};
|
2021-10-26 03:21:27 +08:00
|
|
|
white-space: nowrap;
|
|
|
|
margin-bottom: .5rem;
|
|
|
|
|
|
|
|
${({ valid }) => !valid && `
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorDanger};
|
2021-10-26 03:21:27 +08:00
|
|
|
`}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const InputRooms = styled.select`
|
2021-10-26 20:37:26 +08:00
|
|
|
background-color: ${colorWhite};
|
|
|
|
color: ${colorGray};
|
|
|
|
border: 1px solid ${colorGrayLighter};
|
|
|
|
border-radius: ${borderRadius};
|
2021-10-26 03:21:27 +08:00
|
|
|
width: 100%;
|
|
|
|
padding-top: .25rem;
|
|
|
|
padding-bottom: .25rem;
|
|
|
|
padding: .25rem 0 .25rem .25rem;
|
|
|
|
|
|
|
|
${({ valid }) => !valid && `
|
2021-10-26 20:37:26 +08:00
|
|
|
border-color: ${colorDanger} !important;
|
2021-10-26 03:21:27 +08:00
|
|
|
`}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const DurationLabel = styled.label`
|
|
|
|
${({ valid }) => !valid && `
|
|
|
|
& > * {
|
2021-10-26 20:37:26 +08:00
|
|
|
border-color: ${colorDanger} !important;
|
|
|
|
color: ${colorDanger};
|
2021-10-26 03:21:27 +08:00
|
|
|
}
|
|
|
|
`}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const LabelText = styled.p`
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorGray};
|
2021-10-26 03:21:27 +08:00
|
|
|
white-space: nowrap;
|
|
|
|
margin-bottom: .5rem;
|
|
|
|
`;
|
|
|
|
|
|
|
|
const DurationArea = styled.div`
|
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
justify-content: space-between;
|
|
|
|
`;
|
|
|
|
|
|
|
|
const DurationInput = styled.input`
|
2021-10-26 20:37:26 +08:00
|
|
|
background-color: ${colorWhite};
|
|
|
|
color: ${colorGray};
|
|
|
|
border: 1px solid ${colorGrayLighter};
|
|
|
|
border-radius: ${borderRadius};
|
2021-10-26 03:21:27 +08:00
|
|
|
width: 50%;
|
|
|
|
text-align: center;
|
|
|
|
padding: .25rem;
|
|
|
|
|
|
|
|
&::placeholder {
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorGray};
|
2021-10-26 03:21:27 +08:00
|
|
|
opacity: 1;
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const HoldButtonWrapper = styled(HoldButton)`
|
|
|
|
& > button > span {
|
2021-10-26 20:37:26 +08:00
|
|
|
padding-bottom: ${borderSize};
|
2021-10-26 03:21:27 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
& > button > span > i {
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorGray};
|
|
|
|
width: ${lgPaddingX};
|
|
|
|
height: ${lgPaddingX};
|
2021-10-26 03:21:27 +08:00
|
|
|
font-size: 170% !important;
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
2021-11-12 01:02:03 +08:00
|
|
|
const AssignBtnsContainer = styled.div`
|
|
|
|
margin-top: auto;
|
|
|
|
`;
|
|
|
|
|
|
|
|
const AssignBtns = styled(Button)`
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorPrimary};
|
|
|
|
font-size: ${fontSizeSmall};
|
2021-10-26 03:21:27 +08:00
|
|
|
white-space: nowrap;
|
|
|
|
margin: 0 auto 0 0;
|
|
|
|
align-self: flex-end;
|
|
|
|
|
|
|
|
[dir="rtl"] & {
|
|
|
|
margin: 0 0 0 auto;
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const CheckBoxesContainer = styled(FlexRow)`
|
|
|
|
margin-top: 2rem;
|
2022-02-09 23:52:42 +08:00
|
|
|
margin-bottom: 0.25rem;
|
2021-10-26 03:21:27 +08:00
|
|
|
`;
|
|
|
|
|
|
|
|
const FreeJoinCheckbox = styled.input`
|
|
|
|
width: 1rem;
|
|
|
|
height: 1rem;
|
|
|
|
`;
|
|
|
|
|
|
|
|
const RoomUserItem = styled.p`
|
|
|
|
margin: 0;
|
|
|
|
padding: .25rem 0 .25rem .25rem;
|
|
|
|
overflow: hidden;
|
|
|
|
text-overflow: ellipsis;
|
|
|
|
white-space: nowrap;
|
|
|
|
cursor: pointer;
|
2021-10-26 20:37:26 +08:00
|
|
|
border-bottom: solid .5px ${colorGrayLighter};
|
2021-10-26 03:21:27 +08:00
|
|
|
|
|
|
|
[dir="rtl"] & {
|
|
|
|
padding: .25rem .25rem .25rem 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
${({ selected }) => selected && `
|
2021-10-26 20:37:26 +08:00
|
|
|
background-color: ${colorPrimary};
|
|
|
|
color: ${colorWhite};
|
2021-10-26 03:21:27 +08:00
|
|
|
`}
|
|
|
|
|
|
|
|
${({ disabled }) => disabled && `
|
|
|
|
cursor: not-allowed;
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorGrayLighter};
|
2021-10-26 03:21:27 +08:00
|
|
|
`}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const LockIcon = styled.span`
|
|
|
|
float: right;
|
|
|
|
margin-right: 1rem;
|
|
|
|
|
|
|
|
@media ${smallOnly} {
|
|
|
|
margin-left: .5rem;
|
|
|
|
margin-right: auto;
|
|
|
|
float: left;
|
|
|
|
}
|
|
|
|
|
|
|
|
&:after {
|
|
|
|
font-family: 'bbb-icons' !important;
|
2021-10-26 03:58:37 +08:00
|
|
|
content: '\\e926';
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorGrayLight};
|
2021-10-26 03:21:27 +08:00
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const ListContainer = styled(FlexColumn)`
|
|
|
|
justify-content: flex-start;
|
|
|
|
`;
|
|
|
|
|
|
|
|
const RoomItem = styled.div`
|
|
|
|
margin: 1rem 0 1rem 0;
|
|
|
|
`;
|
|
|
|
|
|
|
|
const ItemTitle = styled.h2`
|
|
|
|
margin: 0;
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorBlueLight};
|
2021-10-26 03:21:27 +08:00
|
|
|
`;
|
|
|
|
|
|
|
|
const ItemButton = styled(Button)`
|
|
|
|
padding: 0;
|
|
|
|
outline: none !important;
|
|
|
|
|
|
|
|
& > span {
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorBlueLight};
|
2021-10-26 03:21:27 +08:00
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const WithError = styled.span`
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorDanger};
|
2021-10-26 03:21:27 +08:00
|
|
|
`;
|
|
|
|
|
|
|
|
const SubTitle = styled.p`
|
2021-10-26 20:37:26 +08:00
|
|
|
font-size: ${fontSizeBase};
|
2021-10-26 03:21:27 +08:00
|
|
|
text-align: justify;
|
2021-10-26 20:37:26 +08:00
|
|
|
color: ${colorGray};
|
2021-10-26 03:21:27 +08:00
|
|
|
`;
|
|
|
|
|
|
|
|
const Content = styled(FlexColumn)``;
|
|
|
|
|
|
|
|
export default {
|
|
|
|
BoxContainer,
|
|
|
|
Alert,
|
|
|
|
FreeJoinLabel,
|
|
|
|
BreakoutNameInput,
|
|
|
|
BreakoutBox,
|
|
|
|
SpanWarn,
|
|
|
|
RoomName,
|
|
|
|
BreakoutSettings,
|
|
|
|
FormLabel,
|
|
|
|
InputRooms,
|
|
|
|
DurationLabel,
|
|
|
|
LabelText,
|
|
|
|
DurationArea,
|
|
|
|
DurationInput,
|
|
|
|
HoldButtonWrapper,
|
2021-11-12 01:02:03 +08:00
|
|
|
AssignBtnsContainer,
|
|
|
|
AssignBtns,
|
2021-10-26 03:21:27 +08:00
|
|
|
CheckBoxesContainer,
|
|
|
|
FreeJoinCheckbox,
|
|
|
|
RoomUserItem,
|
|
|
|
LockIcon,
|
|
|
|
ListContainer,
|
|
|
|
RoomItem,
|
|
|
|
ItemTitle,
|
|
|
|
ItemButton,
|
|
|
|
WithError,
|
|
|
|
SubTitle,
|
|
|
|
Content,
|
|
|
|
};
|