2023-07-08 04:46:36 +08:00
|
|
|
import styled from 'styled-components';
|
|
|
|
import { colorWhite, colorPrimary } from '/imports/ui/stylesheets/styled-components/palette';
|
|
|
|
import { smallOnly } from '/imports/ui/stylesheets/styled-components/breakpoints';
|
2024-02-17 00:32:27 +08:00
|
|
|
import { smPaddingX } from '/imports/ui/stylesheets/styled-components/general';
|
2023-07-08 04:46:36 +08:00
|
|
|
|
2023-09-06 22:24:42 +08:00
|
|
|
interface ChatProps {
|
|
|
|
isChrome: boolean;
|
2024-02-23 03:19:50 +08:00
|
|
|
isRTL: boolean;
|
2023-09-06 22:24:42 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
export const Chat = styled.div<ChatProps>`
|
2023-07-08 04:46:36 +08:00
|
|
|
background-color: ${colorWhite};
|
2024-02-17 00:32:27 +08:00
|
|
|
padding: ${smPaddingX};
|
2023-07-08 04:46:36 +08:00
|
|
|
padding-bottom: 0;
|
|
|
|
display: flex;
|
|
|
|
flex-grow: 1;
|
|
|
|
flex-direction: column;
|
|
|
|
justify-content: space-around;
|
|
|
|
overflow: hidden;
|
|
|
|
height: 100%;
|
2024-08-01 01:02:43 +08:00
|
|
|
user-select: none;
|
2023-07-08 04:46:36 +08:00
|
|
|
|
2024-02-23 03:19:50 +08:00
|
|
|
${({ isRTL }) => isRTL && `
|
|
|
|
padding-left: 0.1rem;
|
|
|
|
`}
|
|
|
|
|
|
|
|
${({ isRTL }) => !isRTL && `
|
|
|
|
padding-right: 0.1rem;
|
|
|
|
`}
|
|
|
|
|
2023-07-08 04:46:36 +08:00
|
|
|
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;
|
|
|
|
}
|
|
|
|
|
2023-09-06 22:24:42 +08:00
|
|
|
${({ isChrome }) => isChrome && `
|
2023-07-08 04:46:36 +08:00
|
|
|
transform: translateZ(0);
|
|
|
|
`}
|
|
|
|
|
|
|
|
@media ${smallOnly} {
|
|
|
|
transform: none !important;
|
|
|
|
}
|
|
|
|
`;
|
|
|
|
|
|
|
|
const ChatContent = styled.div`
|
|
|
|
height: 100%;
|
|
|
|
display: contents;
|
|
|
|
`;
|
|
|
|
|
2024-08-01 01:02:43 +08:00
|
|
|
const ChatMessages = styled.div`
|
|
|
|
user-select: text;
|
|
|
|
`;
|
2023-07-08 04:46:36 +08:00
|
|
|
|
|
|
|
export default { Chat, ChatMessages, ChatContent };
|