Merge pull request #230 from jedmund/fix-mobile-visual-bugs
Fix mobile visual bugs
This commit is contained in:
commit
63b0009ffc
10 changed files with 188 additions and 126 deletions
|
|
@ -10,6 +10,10 @@
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: $unit-2x;
|
gap: $unit-2x;
|
||||||
padding: 0 $unit-4x;
|
padding: 0 $unit-4x;
|
||||||
|
|
||||||
|
@include breakpoint(phone) {
|
||||||
|
gap: $unit-4x;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.DialogDescription {
|
.DialogDescription {
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,11 @@
|
||||||
.Dialog {
|
.Dialog {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
|
box-sizing: border-box;
|
||||||
background: none;
|
background: none;
|
||||||
border: 0;
|
border: 0;
|
||||||
inset: 0;
|
inset: 0;
|
||||||
display: grid;
|
display: grid;
|
||||||
|
padding: 0;
|
||||||
place-items: center;
|
place-items: center;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
min-width: 100vw;
|
min-width: 100vw;
|
||||||
|
|
@ -14,8 +16,8 @@
|
||||||
.DialogContent {
|
.DialogContent {
|
||||||
$multiplier: 4;
|
$multiplier: 4;
|
||||||
|
|
||||||
animation: $duration-modal-open cubic-bezier(0.16, 1, 0.3, 1) 0s 1 normal
|
// animation: $duration-modal-open cubic-bezier(0.16, 1, 0.3, 1) 0s 1 normal
|
||||||
none running openModalDesktop;
|
// none running openModalDesktop;
|
||||||
background: var(--dialog-bg);
|
background: var(--dialog-bg);
|
||||||
border-radius: $card-corner;
|
border-radius: $card-corner;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
|
@ -40,14 +42,19 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
@include breakpoint(phone) {
|
@include breakpoint(phone) {
|
||||||
animation: 0.5s cubic-bezier(0.16, 1, 0.3, 1) 0s 1 normal forwards running
|
// animation: slideUp;
|
||||||
openModalMobile;
|
// animation-duration: 3s;
|
||||||
|
// animation-fill-mode: forwards;
|
||||||
|
// animation-play-state: running;
|
||||||
|
// animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
||||||
|
border-bottom-left-radius: 0;
|
||||||
|
border-bottom-right-radius: 0;
|
||||||
min-width: inherit;
|
min-width: inherit;
|
||||||
min-height: 80vh;
|
min-height: 90vh;
|
||||||
transform: initial;
|
transform: initial;
|
||||||
left: 0;
|
left: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
top: 0;
|
top: 5vh;
|
||||||
height: auto;
|
height: auto;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -18,8 +18,9 @@
|
||||||
max-width: $width;
|
max-width: $width;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
position: relative;
|
position: relative;
|
||||||
width: $width;
|
|
||||||
transition: box-shadow 0.15s ease-in-out;
|
transition: box-shadow 0.15s ease-in-out;
|
||||||
|
width: $width;
|
||||||
|
z-index: 1;
|
||||||
|
|
||||||
// prettier-ignore
|
// prettier-ignore
|
||||||
@media only screen
|
@media only screen
|
||||||
|
|
@ -45,7 +46,7 @@
|
||||||
left: 50%;
|
left: 50%;
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
z-index: 2;
|
z-index: 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
.JobAccessory.Button {
|
.JobAccessory.Button {
|
||||||
|
|
@ -74,6 +75,6 @@
|
||||||
.Overlay {
|
.Overlay {
|
||||||
background: none;
|
background: none;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
z-index: 1;
|
z-index: 2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
.Login.DialogContent {
|
.Login.DialogContent {
|
||||||
gap: $unit;
|
gap: $unit;
|
||||||
min-width: $unit * 52;
|
// min-width: $unit * 52;
|
||||||
|
|
||||||
.Fields {
|
.Fields {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
|
||||||
|
|
@ -1,17 +1,47 @@
|
||||||
.TableField {
|
.TableField {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
display: grid;
|
display: grid;
|
||||||
gap: $unit * 2;
|
gap: $unit-2x;
|
||||||
grid-template-columns: 1fr auto;
|
grid-template-columns: 1fr auto;
|
||||||
|
|
||||||
&.Image {
|
@include breakpoint(phone) {
|
||||||
grid-template-columns: 1fr auto 1fr;
|
align-items: flex-start;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
}
|
}
|
||||||
|
|
||||||
.Left {
|
.Left {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: row;
|
||||||
gap: calc($unit / 2);
|
gap: $unit;
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
|
.Info {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
flex-grow: 1;
|
||||||
|
justify-content: center;
|
||||||
|
gap: $unit-half;
|
||||||
|
}
|
||||||
|
|
||||||
|
.Image {
|
||||||
|
display: none;
|
||||||
|
|
||||||
|
.preview {
|
||||||
|
$diameter: $unit-5x;
|
||||||
|
width: $diameter;
|
||||||
|
height: $diameter;
|
||||||
|
|
||||||
|
img {
|
||||||
|
width: $diameter;
|
||||||
|
height: $diameter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@include breakpoint(phone) {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
label {
|
label {
|
||||||
color: var(--text-tertiary);
|
color: var(--text-tertiary);
|
||||||
|
|
@ -30,6 +60,23 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.Right {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
gap: $unit-2x;
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
|
@include breakpoint(phone) {
|
||||||
|
.Image {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.SelectTrigger {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.preview {
|
.preview {
|
||||||
$diameter: $unit * 6;
|
$diameter: $unit * 6;
|
||||||
background-color: $grey-90;
|
background-color: $grey-90;
|
||||||
|
|
|
||||||
|
|
@ -44,13 +44,15 @@ const SelectTableField = (props: Props) => {
|
||||||
return (
|
return (
|
||||||
<div className={classNames({ TableField: true }, props.className)}>
|
<div className={classNames({ TableField: true }, props.className)}>
|
||||||
<div className="Left">
|
<div className="Left">
|
||||||
<h3>{props.label}</h3>
|
<div className="Info">
|
||||||
<p>{props.description}</p>
|
<h3>{props.label}</h3>
|
||||||
|
<p>{props.description}</p>
|
||||||
|
</div>
|
||||||
|
<div className="Image">{image()}</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{image()}
|
|
||||||
|
|
||||||
<div className="Right">
|
<div className="Right">
|
||||||
|
<div className="Image">{image()}</div>
|
||||||
<Select
|
<Select
|
||||||
name={props.name}
|
name={props.name}
|
||||||
open={props.open}
|
open={props.open}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
.Signup.DialogContent {
|
.Signup.DialogContent {
|
||||||
gap: $unit;
|
gap: $unit;
|
||||||
min-width: $unit * 52;
|
// min-width: $unit * 52;
|
||||||
|
|
||||||
.Fields {
|
.Fields {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,8 @@
|
||||||
background: $grey-70;
|
background: $grey-70;
|
||||||
border-radius: calc($height / 2);
|
border-radius: calc($height / 2);
|
||||||
border: none;
|
border: none;
|
||||||
|
padding-left: $unit-half;
|
||||||
|
padding-right: $unit-half;
|
||||||
position: relative;
|
position: relative;
|
||||||
width: 58px;
|
width: 58px;
|
||||||
height: $height;
|
height: $height;
|
||||||
|
|
@ -36,7 +38,7 @@
|
||||||
height: 26px;
|
height: 26px;
|
||||||
width: 26px;
|
width: 26px;
|
||||||
transition: transform 100ms;
|
transition: transform 100ms;
|
||||||
transform: translateX(-1px);
|
transform: translateX(0px);
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
@ -44,6 +46,6 @@
|
||||||
|
|
||||||
&[data-state='checked'] {
|
&[data-state='checked'] {
|
||||||
background: $grey-100;
|
background: $grey-100;
|
||||||
transform: translateX(21px);
|
transform: translateX(24px);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
@import '~meyer-reset-scss';
|
@import '~meyer-reset-scss';
|
||||||
|
@import 'keyframes.scss';
|
||||||
@import 'themes.scss';
|
@import 'themes.scss';
|
||||||
|
|
||||||
html {
|
html {
|
||||||
|
|
@ -299,107 +300,3 @@ i.tag {
|
||||||
grid-template-columns: 1fr 1fr;
|
grid-template-columns: 1fr 1fr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes fadeOut {
|
|
||||||
from {
|
|
||||||
opacity: 1;
|
|
||||||
}
|
|
||||||
to {
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes openModalDesktop {
|
|
||||||
0% {
|
|
||||||
opacity: 0;
|
|
||||||
transform: scale(0.96);
|
|
||||||
}
|
|
||||||
|
|
||||||
100% {
|
|
||||||
// opacity: 1;
|
|
||||||
transform: scale(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes openModalMobile {
|
|
||||||
0% {
|
|
||||||
opacity: 0;
|
|
||||||
transform: translate(0%, 100%);
|
|
||||||
}
|
|
||||||
|
|
||||||
100% {
|
|
||||||
// opacity: 1;
|
|
||||||
transform: translate(0, 30%);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes slideLeft {
|
|
||||||
from {
|
|
||||||
transform: translateX(100%);
|
|
||||||
}
|
|
||||||
to {
|
|
||||||
transform: translateX(0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes slideRight {
|
|
||||||
from {
|
|
||||||
transform: translateX(var(--radix-toast-swipe-end-x));
|
|
||||||
}
|
|
||||||
to {
|
|
||||||
transform: translateX(100%);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes fadeInFilter {
|
|
||||||
from {
|
|
||||||
backdrop-filter: blur(5px) saturate(100%) brightness(80%) opacity(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
to {
|
|
||||||
backdrop-filter: blur(5px) saturate(100%) brightness(80%) opacity(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes scaleIn {
|
|
||||||
0% {
|
|
||||||
opacity: 0;
|
|
||||||
transform: scale(0);
|
|
||||||
}
|
|
||||||
20% {
|
|
||||||
opacity: 0.2;
|
|
||||||
transform: scale(0.4);
|
|
||||||
}
|
|
||||||
40% {
|
|
||||||
opacity: 0.4;
|
|
||||||
transform: scale(0.8);
|
|
||||||
}
|
|
||||||
60% {
|
|
||||||
opacity: 0.6;
|
|
||||||
transform: scale(1);
|
|
||||||
}
|
|
||||||
65% {
|
|
||||||
opacity: 0.65;
|
|
||||||
transform: scale(1.1);
|
|
||||||
}
|
|
||||||
70% {
|
|
||||||
opacity: 0.7;
|
|
||||||
transform: scale(1);
|
|
||||||
}
|
|
||||||
75% {
|
|
||||||
opacity: 0.75;
|
|
||||||
transform: scale(0.98);
|
|
||||||
}
|
|
||||||
80% {
|
|
||||||
opacity: 0.8;
|
|
||||||
transform: scale(1.02);
|
|
||||||
}
|
|
||||||
90% {
|
|
||||||
opacity: 0.9;
|
|
||||||
transform: scale(0.96);
|
|
||||||
}
|
|
||||||
100% {
|
|
||||||
opacity: 1;
|
|
||||||
transform: scale(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
|
||||||
102
styles/keyframes.scss
Normal file
102
styles/keyframes.scss
Normal file
|
|
@ -0,0 +1,102 @@
|
||||||
|
@keyframes fadeOut {
|
||||||
|
from {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes openModalDesktop {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
transform: scale(0.96);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
// opacity: 1;
|
||||||
|
transform: scale(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes slideUp {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
transform: translate(0%, 100%);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
transform: translate(0, 5%);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes slideLeft {
|
||||||
|
from {
|
||||||
|
transform: translateX(100%);
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
transform: translateX(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes slideRight {
|
||||||
|
from {
|
||||||
|
transform: translateX(var(--radix-toast-swipe-end-x));
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
transform: translateX(100%);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeInFilter {
|
||||||
|
from {
|
||||||
|
backdrop-filter: blur(5px) saturate(100%) brightness(80%) opacity(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
to {
|
||||||
|
backdrop-filter: blur(5px) saturate(100%) brightness(80%) opacity(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes scaleIn {
|
||||||
|
0% {
|
||||||
|
opacity: 0;
|
||||||
|
transform: scale(0);
|
||||||
|
}
|
||||||
|
20% {
|
||||||
|
opacity: 0.2;
|
||||||
|
transform: scale(0.4);
|
||||||
|
}
|
||||||
|
40% {
|
||||||
|
opacity: 0.4;
|
||||||
|
transform: scale(0.8);
|
||||||
|
}
|
||||||
|
60% {
|
||||||
|
opacity: 0.6;
|
||||||
|
transform: scale(1);
|
||||||
|
}
|
||||||
|
65% {
|
||||||
|
opacity: 0.65;
|
||||||
|
transform: scale(1.1);
|
||||||
|
}
|
||||||
|
70% {
|
||||||
|
opacity: 0.7;
|
||||||
|
transform: scale(1);
|
||||||
|
}
|
||||||
|
75% {
|
||||||
|
opacity: 0.75;
|
||||||
|
transform: scale(0.98);
|
||||||
|
}
|
||||||
|
80% {
|
||||||
|
opacity: 0.8;
|
||||||
|
transform: scale(1.02);
|
||||||
|
}
|
||||||
|
90% {
|
||||||
|
opacity: 0.9;
|
||||||
|
transform: scale(0.96);
|
||||||
|
}
|
||||||
|
100% {
|
||||||
|
opacity: 1;
|
||||||
|
transform: scale(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Reference in a new issue