Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Responsive design SCSS #115

Merged
merged 35 commits into from
Jun 12, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
9bdbd31
style: made layouts responsive
noctera Apr 22, 2022
40d579c
style: stylelint scss formatting
noctera Apr 23, 2022
c7151dd
refactor: basic responsive nav layout
noctera May 24, 2022
445899c
refactor: responsive dashboard
noctera May 25, 2022
44d9439
refactor: made some components responsive
noctera May 25, 2022
43f9deb
refactor: mobile width frame
noctera May 26, 2022
5931817
refactor: responsive library
noctera May 27, 2022
c0c7826
refactor: responsive vocabForm
noctera May 27, 2022
3293231
refactor: responsive vocab query
noctera May 27, 2022
318609f
refactor: imported last code from tailwind branch
noctera May 29, 2022
9537df9
fix: mobile top nav colors
noctera May 30, 2022
c0358e9
fix: made some components more usable on mobile
noctera May 30, 2022
d6ed59f
fix: logout button
noctera Jun 1, 2022
6aea6cf
style: temp guide responsiveness
noctera Jun 1, 2022
401652c
fix: flex direction in forms
noctera Jun 1, 2022
4ce6bde
fix: fix mobile-top-nav not closing on item click
Tracer1337 Jun 3, 2022
8b0f9ef
feat: add animation to mobile-top-nav
Tracer1337 Jun 3, 2022
a8fe183
style: change active button color
noctera Jun 3, 2022
980ee03
feat: integrate swiper library into selection screen
Tracer1337 Jun 3, 2022
49a244b
Merge branch 'responsive-design-new' of github.com:vocascan/vocascan-…
Tracer1337 Jun 3, 2022
605e501
Merge branch 'experimental' into responsive-design-new
Jun 7, 2022
bf22d74
fix: use theme-agnostic styling
Tracer1337 Jun 10, 2022
39656d0
chore: fix linter errors
Tracer1337 Jun 10, 2022
a15209d
fix: fix login / register page responsive styling
Tracer1337 Jun 10, 2022
1ef74bd
fix: code review
noctera Jun 11, 2022
0b835b0
refactor: imports and jsx return layout
noctera Jun 11, 2022
6c63ab0
refactor: unauthenticated layout
noctera Jun 11, 2022
3e3170d
Merge branch
noctera Jun 11, 2022
47a6cfd
fix: Dashboard centering
noctera Jun 11, 2022
3dbef69
style: EmailVerify responsive
noctera Jun 11, 2022
8500c86
fix: json parse error
noctera Jun 12, 2022
992ced3
fix: max-width for modal
noctera Jun 12, 2022
a20173e
fix: linting
noctera Jun 12, 2022
8e05f86
Improved desktop TopNav to fit to the mobile TopNav
luwol03 Jun 12, 2022
817217e
Merge branch 'experimental' into responsive-design-new
luwol03 Jun 12, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "stylelint-config-sass-guidelines",
"extends": ["stylelint-config-sass-guidelines", "stylelint-config-recess-order"],
"rules": {
"order/properties-alphabetical-order": null,
"max-nesting-depth": 4,
Expand Down
12,082 changes: 9,286 additions & 2,796 deletions package-lock.json

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@
"sass": "^1.29.0",
"sass-loader": "^10.1.0",
"semver": "^6.3.0",
"swiper": "^8.2.2",
"uniqid": "^5.3.0",
"web-vitals": "^1.1.0"
},
Expand All @@ -71,8 +72,10 @@
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-prettier": "^3.4.0",
"prettier": "^2.5.1",
"stylelint": "^14.2.0",
"stylelint-config-sass-guidelines": "^9.0.1"
"stylelint": "^14.7.1",
"stylelint-config-recess-order": "^3.0.0",
"stylelint-config-sass-guidelines": "^9.0.1",
"stylelint-order": "^5.0.0"
},
"metadata": {}
}
2 changes: 1 addition & 1 deletion public/config.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
window.VOCASCAN_CONFIG = JSON.parse(``);
window.VOCASCAN_CONFIG = JSON.parse("{}");
1 change: 1 addition & 0 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<meta charset="UTF-8" />
<title>Vocascan Web</title>
<link rel="icon" href="%PUBLIC_URL%/logo.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#2a2e36" />
<meta name="description" content="A highly configurable vocabulary trainer" />
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
Expand Down
38 changes: 19 additions & 19 deletions src/Components/Button/Button.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,60 +2,60 @@

.btn {
display: flex;
align-items: center;
justify-content: center;
padding: 10px 14px;
font-size: 16px;
text-transform: none;
color: $color-white;
justify-content: center;
align-items: center;
border-radius: 15px;
text-transform: none;
border: unset;
border-radius: 15px;
transition: all 0.3s ease-in;

&.btn-default {
&.btn-primary {
background-color: $color-primary;

&:hover {
background-color: $color-primary-dark;
cursor: pointer;
background-color: $color-primary-dark;
}
}

&.btn-primary-light {
background-color: $color-primary-light;

&:hover {
background-color: $color-primary;
color: $color-white;
cursor: pointer;
background-color: $color-primary;
}
}

&.btn-red {
background-color: $color-red;

&:hover {
background-color: $color-red-dark;
cursor: pointer;
background-color: $color-red-dark;
}
}

&.btn-green {
background-color: $color-green;

&:hover {
background-color: $color-green-dark;
cursor: pointer;
background-color: $color-green-dark;
}
}

&.btn-dark {
background-color: $color-background-inverse;

&:hover {
background-color: $color-alternative;
cursor: pointer;
background-color: $color-alternative;
}
}
}
Expand All @@ -68,9 +68,9 @@
border: 1px solid $color-primary;

&:hover {
background-color: $color-primary;
color: $color-white;
cursor: pointer;
background-color: $color-primary;
}
}

Expand All @@ -79,9 +79,9 @@
border: 1px solid $color-primary-light;

&:hover {
background-color: $color-primary-light;
color: $color-white;
cursor: pointer;
background-color: $color-primary-light;
}
}

Expand All @@ -90,9 +90,9 @@
border: 1px solid $color-red;

&:hover {
background-color: $color-red;
color: $color-white;
cursor: pointer;
background-color: $color-red;
}
}

Expand All @@ -101,9 +101,9 @@
border: 1px solid $color-green;

&:hover {
background-color: $color-green;
color: $color-white;
cursor: pointer;
background-color: $color-green;
}
}
}
Expand All @@ -116,18 +116,18 @@

&:hover {
color: $color-primary-dark;
background-color: $color-background-muted;
cursor: pointer;
background-color: $color-background-muted;
}
}

&.btn-primary-light {
color: $color-primary-light;

&:hover {
background-color: $color-background-muted;
color: $color-primary;
cursor: pointer;
background-color: $color-background-muted;
}
}

Expand All @@ -136,8 +136,8 @@

&:hover {
color: $color-red-dark;
background-color: $color-background-muted;
cursor: pointer;
background-color: $color-background-muted;
}
}

Expand All @@ -146,15 +146,15 @@

&:hover {
color: $color-green-dark;
background-color: $color-background-muted;
cursor: pointer;
background-color: $color-background-muted;
}
}
}

&.btn-link {
background-color: transparent;
padding: 0;
background-color: transparent;

&.btn-primary {
color: $color-primary;
Expand Down Expand Up @@ -202,8 +202,8 @@
}

&.btn-disabled {
opacity: 0.5;
pointer-events: none;
opacity: 0.5;
}

&.btn-round {
Expand Down
22 changes: 11 additions & 11 deletions src/Components/Charts/ProgressBar/ProgressBar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,39 +2,39 @@

.progress-bar {
position: relative;
height: 20px;
width: 100%;
max-width: 500px;
background-color: $color-background-muted;
height: 20px;
margin: 50px 0;
background-color: $color-background-muted;

.wrapper {
height: 100%;
display: flex;
width: 0%;
max-width: 500px;
height: 100%;
background-color: $color-green;
transition: width 1s ease-in-out;
display: flex;
width: 0%;

.percentage {
position: absolute;
left: 50%;
align-self: center;
font-size: 13px;
font-weight: bold;
line-height: 13px;
color: $color-main-text;
font-weight: bold;
left: 50%;
transform: translateX(-50%);
align-self: center;
}
}

.bottom-text {
font-size: 13px;
line-height: 13px;
color: $color-main-text;
display: flex;
justify-content: flex-end;
padding: 5px 0;
font-size: 13px;
line-height: 13px;
color: $color-main-text;
letter-spacing: 1px;
}
}
6 changes: 3 additions & 3 deletions src/Components/ConfirmDialog/ConfirmDialog.scss
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
@import "../../colors";

.submit-dialog {
width: 80%;
max-width: 400px;
display: flex;
flex-direction: column;
width: 80%;
max-width: 400px;

.description {
padding: 20px 0;
}

.actions {
display: flex;
justify-content: space-between;
align-items: center;
justify-content: space-between;
}
}
22 changes: 11 additions & 11 deletions src/Components/ContributorCard/ContributorCard.scss
Original file line number Diff line number Diff line change
@@ -1,40 +1,40 @@
@import "../../colors";

.card {
position: relative;
display: inline-block;
width: 130px;
height: 170px;
margin: 8px;
position: relative;
border-radius: 8px;
overflow: hidden;
border-radius: 8px;

img {
width: 130px;
}

.backdrop {
transition: border-radius 0.125s ease-in-out, top 0.125s ease-in-out;
position: absolute;
bottom: 0;
width: 100%;
top: 130px;
background-color: $color-background-inverse;
color: #fff;
bottom: 0;
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
align-items: center;
justify-content: center;
width: 100%;
color: #fff;
background-color: $color-background-inverse;
transition: border-radius 0.125s ease-in-out, top 0.125s ease-in-out;

.name {
font-size: 14px;
}

.description {
display: none;
color: #bbb;
font-size: 12px;
margin-top: 5px;
font-size: 12px;
color: #bbb;
}
}

Expand Down
26 changes: 13 additions & 13 deletions src/Components/CookieConsentBanner/CookieConsentBanner.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,34 @@

/* stylelint-disable selector-class-pattern */
.CookieConsent {
width: 40%;
background: $color-background-inverse;
position: absolute;
right: 0;
left: 0;
z-index: 999;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
color: $color-main-text-inverse;
position: absolute;
z-index: 999;
width: 40%;
padding: 15px;
left: 0;
right: 0;
margin-left: auto;
margin-right: auto;
margin-left: auto;
color: $color-main-text-inverse;
background: $color-background-inverse;

div {
margin: auto 0;
}

button {
flex: 0 0 auto;
padding: 5px 10px;
margin-left: 15px;
color: $color-main-text-inverse;
cursor: pointer;
background: $color-primary;
border: 0;
border-radius: 0;
box-shadow: none;
color: $color-main-text-inverse;
cursor: pointer;
flex: 0 0 auto;
padding: 5px 10px;
margin-left: 15px;
}

.cookie-consent-link {
Expand Down
2 changes: 1 addition & 1 deletion src/Components/Counter/Counter.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

.counter {
display: inline-block;
color: #fff;
min-width: 7px;
height: 18px;
padding: 0 6px;
font-size: 12px;
line-height: 18px;
color: #fff;
text-align: center;
vertical-align: middle;
border-radius: 9px;
Expand Down
Loading