Improve fileActions Buttons style on mobile view

- Move label to bottom instead of to the side
- Decrease font, sizes and spacings
- Make sure all fit in a single line even on smallest screen size
This commit is contained in:
Rafael 2022-02-01 17:21:28 -03:00 committed by Thomas Zarebczan
parent 416238db29
commit fc30a74cd1
4 changed files with 34 additions and 6 deletions

View file

@ -171,7 +171,7 @@ export default function FileActions(props: Props) {
{(!isLivestreamClaim || !claimIsMine || isMobile) && ( {(!isLivestreamClaim || !claimIsMine || isMobile) && (
<Menu> <Menu>
<MenuButton <MenuButton
className="button--file-action" className="button--file-action--menu"
onClick={(e) => { onClick={(e) => {
e.stopPropagation(); e.stopPropagation();
e.preventDefault(); e.preventDefault();

View file

@ -314,6 +314,10 @@
} }
} }
.button--file-action--menu {
@extend .button--file-action;
}
.button--fire { .button--fire {
color: var(--color-fire); color: var(--color-fire);
position: relative; position: relative;

View file

@ -312,7 +312,7 @@
} }
@media (max-width: $breakpoint-small) { @media (max-width: $breakpoint-small) {
padding: var(--spacing-l); padding: 0 !important;
} }
} }

View file

@ -118,11 +118,35 @@
} }
@media (max-width: $breakpoint-small) { @media (max-width: $breakpoint-small) {
padding-top: var(--spacing-s); justify-content: space-around !important;
margin: 0;
padding: 0;
> * { div {
margin-right: var(--spacing-s); margin: 0 !important;
margin-bottom: var(--spacing-s); }
.button--file-action {
margin: 0 !important;
padding: var(--spacing-xxs);
width: 3.1rem;
height: 3.1rem;
.button__content {
flex-direction: column;
justify-content: space-between;
.button__label {
margin: 0;
margin-top: var(--spacing-xxs);
font-size: var(--font-xxsmall);
}
}
}
.button--file-action--menu {
width: unset;
height: 2rem;
} }
} }
} }