From 8f2f30af7771a04e6b78ab35dc7e71877ab6014c Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:01:20 +0300 Subject: [PATCH 01/12] rm parallax style --- src/style/components/parallax.scss | 22 ---------------------- src/style/style.scss | 1 - 2 files changed, 23 deletions(-) delete mode 100644 src/style/components/parallax.scss diff --git a/src/style/components/parallax.scss b/src/style/components/parallax.scss deleted file mode 100644 index 05bf781d..00000000 --- a/src/style/components/parallax.scss +++ /dev/null @@ -1,22 +0,0 @@ -.parallax { - min-width: 1280px; - width: 1280px; - height: 1000px; - overflow: hidden; - position: relative; - - //&__container { - // - //} - - &__layer { - position: absolute; - } - - &__end { - position: absolute; - width: 100%; - background-color: white; - bottom: 0; - } -} \ No newline at end of file diff --git a/src/style/style.scss b/src/style/style.scss index 0d734ccd..46c5db58 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -13,7 +13,6 @@ @import "components/Article"; @import "components/Paginator"; @import "components/album"; -@import "components/parallax"; @import "components/ArticleTags"; From 71585c1d75ae4552e0bdee6732399983ac1876ef Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:01:31 +0300 Subject: [PATCH 02/12] rm page-animation style --- src/style/page-animation.scss | 56 ----------------------------------- src/style/style.scss | 1 - 2 files changed, 57 deletions(-) delete mode 100644 src/style/page-animation.scss diff --git a/src/style/page-animation.scss b/src/style/page-animation.scss deleted file mode 100644 index 29496bad..00000000 --- a/src/style/page-animation.scss +++ /dev/null @@ -1,56 +0,0 @@ -@keyframes rotateFall { - 0% { - transform: rotateZ(0deg); - } - 20% { - transform: rotateZ(10deg); - animation-timing-function: ease-out; - } - 40% { - transform: rotateZ(17deg); - } - 60% { - transform: rotateZ(16deg); - } - 100% { - transform: translateY(100%) rotateZ(17deg); - } -} - -@keyframes scaleUp { - from { - opacity: 0.0; - transform: scale(0.5); - } -} - -@keyframes slideInRight { - from { - transform: translateX(100%); - } - to { - transform: translateX(0); - } -} - -@keyframes slideInUp { - from { - transform: translateY(100%); - } - to { - transform: translateY(0); - } -} - -@keyframes slideOutLeft { - to { - transform: translateX(-100%); - } -} - -@keyframes rotateOutNewspaper { - to { - transform: translateZ(-3000px) rotateZ(360deg); - opacity: 0; - } -} \ No newline at end of file diff --git a/src/style/style.scss b/src/style/style.scss index 46c5db58..e42aea43 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -17,7 +17,6 @@ @import "components/ArticleTags"; @import "content"; -@import "page-animation"; @import "main-image"; //@import "vertical-image"; From e146c5e0a49e3c95b1b81f7e5af877e59d2e7081 Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:01:43 +0300 Subject: [PATCH 03/12] rm timeline style --- .../components/timeline-record-instagram.scss | 51 ------------------- src/style/components/timeline-record.scss | 7 --- src/style/components/timeline.scss | 34 ------------- src/style/style.scss | 3 -- 4 files changed, 95 deletions(-) delete mode 100644 src/style/components/timeline-record-instagram.scss delete mode 100644 src/style/components/timeline-record.scss delete mode 100644 src/style/components/timeline.scss diff --git a/src/style/components/timeline-record-instagram.scss b/src/style/components/timeline-record-instagram.scss deleted file mode 100644 index 51959a37..00000000 --- a/src/style/components/timeline-record-instagram.scss +++ /dev/null @@ -1,51 +0,0 @@ -$user-size: 40px; -$half-margin: $single-margin/2; -$image-border-radius: .35em; -$image-border-thickness: $half-margin; - -.timeline-record-instagram { -} - -.timeline-record-instagram__head { - margin-bottom: 1.25em; - //margin-bottom: $single-margin; - - .date { - text-align: center; - color: #aaa; - } -} - -.timeline-record-instagram__body { - img { - max-width: 640px; - width: 100%; - height: auto; - box-sizing: border-box; - border: $image-border-thickness solid white; - box-shadow: $white-shadow; - border-radius: $image-border-radius; - margin: 0 auto $single-margin; - display: block; - } -} - -.timeline-record-instagram__user { - padding-top: $half-margin; - - span { - margin-left: $half-margin; - - line-height: $user-size; - vertical-align: top; - } - - img { - display: inline; - width: $user-size; - height: $user-size; - border-radius: 50%; - border: none; - box-shadow: none; - } -} \ No newline at end of file diff --git a/src/style/components/timeline-record.scss b/src/style/components/timeline-record.scss deleted file mode 100644 index 55f9402a..00000000 --- a/src/style/components/timeline-record.scss +++ /dev/null @@ -1,7 +0,0 @@ -.timeline__record { - margin: 0 0 var(--post-margin); - - .date { - color: var(--light-color); - } -} diff --git a/src/style/components/timeline.scss b/src/style/components/timeline.scss deleted file mode 100644 index 327e6fda..00000000 --- a/src/style/components/timeline.scss +++ /dev/null @@ -1,34 +0,0 @@ -.timeline{ - display: flex; - flex-direction: column; - margin: var(--double-margin) auto; -} - -.timeline__footer{ - display: flex; - justify-content: center; - - button.more { - cursor: hand; - - position: relative; - top: -2px; - - width: 100px; - height: 40px; - border: 2px solid var(--dark-color); - padding: 0 10px; - color: var(--dark-color); - background: var(--lighter-color); - - font-size: var(--normal-font-size); - - &:hover { - background: gainsboro; - } - - &:active { - top: 0; - } - } -} diff --git a/src/style/style.scss b/src/style/style.scss index e42aea43..86240c5d 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -5,9 +5,6 @@ @import "components/documents-container"; @import "components/navigation"; @import "components/breadcrumbs"; -@import "components/timeline"; -@import "components/timeline-record"; -//@import "components/timeline-record-instagram"; @import "components/schedule-table"; @import "components/footer-links"; @import "components/Article"; From 13781b3bbb1e2bb696dccb2f3e44507a6e678df3 Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:02:00 +0300 Subject: [PATCH 04/12] disable importing tape-viewer --- src/style/style.scss | 1 - 1 file changed, 1 deletion(-) diff --git a/src/style/style.scss b/src/style/style.scss index 86240c5d..fe0b62b3 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -20,7 +20,6 @@ @import "schedule-selector"; @import "schedule-mobile"; -@import "tape-viewer"; @import "footer"; // THEMES From dce69339046894982e60b99b0c746867f3527001 Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:05:57 +0300 Subject: [PATCH 05/12] rm main-image --- src/style/main-image.scss | 25 ------------------------- src/style/style.scss | 1 - 2 files changed, 26 deletions(-) delete mode 100644 src/style/main-image.scss diff --git a/src/style/main-image.scss b/src/style/main-image.scss deleted file mode 100644 index 8825a6dd..00000000 --- a/src/style/main-image.scss +++ /dev/null @@ -1,25 +0,0 @@ -.main-image{ - display: none; - - width: 100%; - - //display: flex; - //justify-content: center; - //overflow: hidden; - - img { - width: 100%; - max-width: 1280px; - } - - //&__content { - // min-width: 1280px; - // width: 1280px; - //} -} - -@media (max-width: var(--mobile-width)) { - .main-image { - display: none; - } -} diff --git a/src/style/style.scss b/src/style/style.scss index fe0b62b3..8a405aac 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -14,7 +14,6 @@ @import "components/ArticleTags"; @import "content"; -@import "main-image"; //@import "vertical-image"; @import "schedule-selector"; From 877e33c004ce87feeecf922fbaef8c48bda424f7 Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:07:45 +0300 Subject: [PATCH 06/12] rm album.scss --- src/style/album.scss | 132 ------------------------------------------- 1 file changed, 132 deletions(-) delete mode 100644 src/style/album.scss diff --git a/src/style/album.scss b/src/style/album.scss deleted file mode 100644 index b9880301..00000000 --- a/src/style/album.scss +++ /dev/null @@ -1,132 +0,0 @@ -.album-block { - //margin: 1em auto 2em; - - h3 { - text-align: center; - margin: 1.5em 0 1em; - } - - .album { - display: flex; - flex-direction: row; - flex-wrap: wrap; - justify-content: center; - } - - .album-info { - width: 80%; - margin: 0 0 3em; - } - - .album-info p { - margin: 0 0 .5em; - } - - .album-item { - width: 80%; - box-sizing: border-box; - margin: 0 0 4em; - position: relative; - background-color: white; - padding: 6em; - box-shadow: 0 4px 14px -10px rgba(0,0,0, .85); - - &.vertical { - width: 47%; - min-width: 30em; - max-width: 35em; - } - - img{ - width: 100%; - box-sizing: border-box; - border: .25em solid #eee; - border-top-color: #bbb; - border-left-color: #ddd; - } - } - - .product-info{ - text-align: center; - position: absolute; - width: 100%; - left: 0; - bottom: 1em; - - & > div { - display: inline-block; - padding: .5em 1em; - background-color: white; - border: 1px solid #f5f5f5; - border-radius: .25em; - box-shadow: 0 5p/x 4px -4px rgba(0,0,0, .5); - } - - p { - font-size: 0.75em; - } - - .title { - font-weight: bold; - } - } -} - -@media screen and (max-width: $mobile-width) { - .album-block { - width: 100%; - margin: 1em auto 2em; - - h3 { - text-align: left; - margin: 1em 0 0.5em; - } - - .album-info{ - width: 100%; - margin: 0 0 2em; - } - - .album-item { - width: 100%; - padding: 1em 1em 5em; - margin: 0 0 2em; - - img{ - border: .1em solid #eee; - border-top-color: #bbb; - border-left-color: #ddd; - } - } - - .product-info { - bottom: .5em; - } - } -} - -@media screen and (min-width: $mobile-width) and (max-width: $desktop-width){ - .album-block { - .album-info{ - width: 100%; - margin: 0 0 2em; - font-size: 0.75em; - } - - .album-item { - width: 100%; - padding: 2em 2em 5em; - margin: 0 0 2em; - - img{ - border: .15em solid #eee; - border-top-color: #bbb; - border-left-color: #ddd; - } - } - - .product-info { - bottom: .5em; - } - } -} \ No newline at end of file From 7b6fd8e892ca8dec2183f9f46fe224c1964b38ac Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:07:55 +0300 Subject: [PATCH 07/12] clean style scss --- src/style/style.scss | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/style/style.scss b/src/style/style.scss index 8a405aac..62529682 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -10,11 +10,9 @@ @import "components/Article"; @import "components/Paginator"; @import "components/album"; - @import "components/ArticleTags"; @import "content"; -//@import "vertical-image"; @import "schedule-selector"; @import "schedule-mobile"; From e1778ba083f7ae4b9e5f87ecaad9e6ad4b5510fe Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:14:56 +0300 Subject: [PATCH 08/12] rm schedule-mobile style --- src/style/schedule-mobile.scss | 61 ---------------------------------- src/style/style.scss | 1 - 2 files changed, 62 deletions(-) delete mode 100644 src/style/schedule-mobile.scss diff --git a/src/style/schedule-mobile.scss b/src/style/schedule-mobile.scss deleted file mode 100644 index 3c18a57f..00000000 --- a/src/style/schedule-mobile.scss +++ /dev/null @@ -1,61 +0,0 @@ -.schedule-slider { - width: 100%; - max-width: 30em; - //width: 90%; - //margin: 0 auto; -} - -.schedule-slider__slide { - height: 100%; - overflow-y: auto; - - &.current { - border-left: .3em solid #4b8ff3; - border-right: .3em solid #4b8ff3; - } -} - -.schedule-slider__body { -} - -.schedule-slider__head { - text-align: center; - font-size: 2em; - margin: 0 0 .5em; -} - -.schedule-record { - min-height: 10em; - text-align: center; - - &.even{ - background-color: #f3f3fd; - } - - &.empty { - .schedule-record__head{ - color: #bbb; - } - } - - p { - margin: .2em 0; - } -} - -.schedule-record__head { - padding: .25em 0; - font-size: 1.2em; -} - -.schedule-record__main { -} - -.schedule-record__name { - font-weight: bold; - font-size: 1.2em; -} - -.schedule-record__group { - position: absolute; -} \ No newline at end of file diff --git a/src/style/style.scss b/src/style/style.scss index 62529682..b2e139e9 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -15,7 +15,6 @@ @import "content"; @import "schedule-selector"; -@import "schedule-mobile"; @import "footer"; From 2287e59b710940696e1795ef4a7e4089d01458f9 Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:15:28 +0300 Subject: [PATCH 09/12] rm ScheduleList component --- pages/schedule.tsx | 2 -- src/components/ScheduleList.js | 20 -------------------- src/style/schedule-selector.scss | 8 -------- src/style/style.scss | 3 --- 4 files changed, 33 deletions(-) delete mode 100644 src/components/ScheduleList.js delete mode 100644 src/style/schedule-selector.scss diff --git a/pages/schedule.tsx b/pages/schedule.tsx index ed2700ce..ce371cc8 100644 --- a/pages/schedule.tsx +++ b/pages/schedule.tsx @@ -24,8 +24,6 @@ const Page: NextPage = props => ( {props.title} - {/**/} - diff --git a/src/components/ScheduleList.js b/src/components/ScheduleList.js deleted file mode 100644 index 36f953e3..00000000 --- a/src/components/ScheduleList.js +++ /dev/null @@ -1,20 +0,0 @@ -const React = require('react') -const text = require('../server/schedule').text - -const ScheduleList = ({schedules}) => ( -
-
    - {schedules.map((s, index) => ( - - ))} -
-
-) - -const Schedule = ({url, semester, period}) => ( -
  • - {text({semester, period})} -
  • -) - -module.exports = ScheduleList diff --git a/src/style/schedule-selector.scss b/src/style/schedule-selector.scss deleted file mode 100644 index d8ffe12a..00000000 --- a/src/style/schedule-selector.scss +++ /dev/null @@ -1,8 +0,0 @@ -.schedule-selector { - text-align: center; - margin-bottom: var(--single-margin); - - label{ - margin: 0 .5em; - } -} \ No newline at end of file diff --git a/src/style/style.scss b/src/style/style.scss index b2e139e9..7a7dd59d 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -13,9 +13,6 @@ @import "components/ArticleTags"; @import "content"; - -@import "schedule-selector"; - @import "footer"; // THEMES From 71738eab2a8e1a95425c2400a4d0054f84dbde4e Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:16:14 +0300 Subject: [PATCH 10/12] rm breadcrumbs style --- src/style/components/breadcrumbs.scss | 43 --------------------------- src/style/style.scss | 1 - 2 files changed, 44 deletions(-) delete mode 100644 src/style/components/breadcrumbs.scss diff --git a/src/style/components/breadcrumbs.scss b/src/style/components/breadcrumbs.scss deleted file mode 100644 index 79e2c412..00000000 --- a/src/style/components/breadcrumbs.scss +++ /dev/null @@ -1,43 +0,0 @@ -breadcrumbs{ - --font-size: 0.75em; - --item-active-color: var(--link-color); - --item-inactive-color: var(--inactive-link-color); - --separator: '⟶'; - --mobile-separator: '>'; - - padding: .35em 0 0; - color: var(--item-inactive-color); - - a { - color: var(--item-active-color); - } - - ul{ - list-style: none; - - li { - display: inline-block; - - &:not(:first-child):before{ - content: var(--separator); - margin-left: .4em; - } - } - } -} - -@media screen and (max-width: var(--mobile-width)) { - breadcrumbs{ - margin: 0; - font-size: var(--font-size); - - ul{ - li { - &:not(:first-child):before{ - content: var(--mobile-separator); - margin-left: .2em; - } - } - } - } -} diff --git a/src/style/style.scss b/src/style/style.scss index 7a7dd59d..199258b8 100644 --- a/src/style/style.scss +++ b/src/style/style.scss @@ -4,7 +4,6 @@ @import "components/document-row"; @import "components/documents-container"; @import "components/navigation"; -@import "components/breadcrumbs"; @import "components/schedule-table"; @import "components/footer-links"; @import "components/Article"; From 2511f431c4410ffe6cc334339315a65b82df95ff Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:18:59 +0300 Subject: [PATCH 11/12] navigation style cleanup --- src/style/components/navigation.scss | 34 ++++------------------------ 1 file changed, 4 insertions(+), 30 deletions(-) diff --git a/src/style/components/navigation.scss b/src/style/components/navigation.scss index d5d4bf6e..89fca208 100644 --- a/src/style/components/navigation.scss +++ b/src/style/components/navigation.scss @@ -1,36 +1,10 @@ .navigation { - width: 100%; - background-color: white; + width: 100%; + background-color: white; +} - &__body { +.navigation__body { display: flex; justify-content: space-between; align-items: center; - } -} - -.navigation__right { - color: var(--dark-color); - font-size: var(--normal-font-size); - margin-right: 1em; - - z-index: 1000; -} - -@media (max-width: var(--mobile-width)) { - .navigation { - background-color: white; - } - - .navigation__right { - display: none; - } -} - -@media screen and (min-width: var(--tablet-min-width)) and (max-width: var(--tablet-max-width)) { - @media screen and (orientation: portrait) { - .navigation__right { - display: none; - } - } } From de63b5e778d6533e088da64f37c3a2600f7a69cf Mon Sep 17 00:00:00 2001 From: Roman Timashev Date: Tue, 18 Feb 2020 12:29:21 +0300 Subject: [PATCH 12/12] App.Header refactoring --- src/components/App/Header.tsx | 26 ++++++++++++++++++++------ src/components/App/index.tsx | 18 +++++++----------- src/style/components/navigation.scss | 10 ---------- src/style/style.scss | 1 - 4 files changed, 27 insertions(+), 28 deletions(-) delete mode 100644 src/style/components/navigation.scss diff --git a/src/components/App/Header.tsx b/src/components/App/Header.tsx index 3dc82dc7..db9ce493 100644 --- a/src/components/App/Header.tsx +++ b/src/components/App/Header.tsx @@ -1,8 +1,22 @@ -import * as React from 'react' -import { Navigation } from '../Navigation' +export const Header: React.FC = props => ( +
    + + +
    +
    + {props.children} +
    +
    +
    ) - -export default Header diff --git a/src/components/App/index.tsx b/src/components/App/index.tsx index 3bcf5c8b..ba10f674 100644 --- a/src/components/App/index.tsx +++ b/src/components/App/index.tsx @@ -4,8 +4,8 @@ import { Footer } from '../Footer' import Comments from '../Comments' import { useReducedMotion } from 'src/hooks/useReducedMotion' import { Wrapper } from '../Wrapper' - -const Header = dynamic(() => import('./Header'), { +import { Header } from './Header' +const Navigation = dynamic(() => import('../Navigation').then(mod => mod.Navigation), { ssr: false, }) @@ -22,15 +22,11 @@ export const App: React.FC = props => { return ( -
    -
    -
    -
    -
    - +
    + +
    )} footer={(