feat: staged attachments rail stying updated
updated StyledStagedPlaceholderAttachment to be a styled functional componentpull/2757/head
parent
d7200abfab
commit
ad38b15809
@ -1,17 +1,32 @@
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
|
||||
interface Props {
|
||||
onClick: () => void;
|
||||
}
|
||||
|
||||
export class StagedPlaceholderAttachment extends React.Component<Props> {
|
||||
public render() {
|
||||
const { onClick } = this.props;
|
||||
const StyledStagedPlaceholderAttachment = styled.div`
|
||||
margin: 1px var(--margins-sm);
|
||||
border-radius: var(--border-radius-message-box);
|
||||
border: 1px solid var(--border-color);
|
||||
height: 120px;
|
||||
width: 120px;
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
|
||||
return (
|
||||
<div className="module-staged-placeholder-attachment" role="button" onClick={onClick}>
|
||||
<div className="module-staged-placeholder-attachment__plus-icon" />
|
||||
</div>
|
||||
);
|
||||
&:hover {
|
||||
background-color: var(--background-secondary-color);
|
||||
}
|
||||
`;
|
||||
|
||||
export function StagedPlaceholderAttachment(props: Props) {
|
||||
const { onClick } = props;
|
||||
|
||||
return (
|
||||
<StyledStagedPlaceholderAttachment role="button" onClick={onClick}>
|
||||
<div className="module-staged-placeholder-attachment__plus-icon" />
|
||||
</StyledStagedPlaceholderAttachment>
|
||||
);
|
||||
}
|
||||
|
Loading…
Reference in New Issue