-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
add task solution #3651
base: master
Are you sure you want to change the base?
add task solution #3651
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: Test | ||
|
||
on: | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [20.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- run: npm install | ||
- run: npm test | ||
- name: Upload HTML report(backstop data) | ||
if: ${{ always() }} | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: report | ||
path: backstop_data |
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
$stopwatch-size: 80vmin; | ||
$minute-height: 20vmin; | ||
$minute-width: 3vmin; | ||
$second-height: 38vmin; | ||
$second-width: 1.5vmin; | ||
$center-size: 5vmin; | ||
|
||
.stopwatch { | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
height: 100vh; | ||
|
||
&__face { | ||
width: $stopwatch-size; | ||
height: $stopwatch-size; | ||
border: 1vmin dotted $border-color; | ||
border-radius: 50%; | ||
|
||
position: relative; | ||
} | ||
|
||
&__center { | ||
width: $center-size; | ||
height: $center-size; | ||
background-color: $center-color; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The variable |
||
border-radius: 50%; | ||
|
||
position: absolute; | ||
left: 50%; | ||
top: 50%; | ||
transform: translate(-50%, -50%); | ||
z-index: 2; | ||
} | ||
|
||
&__hand { | ||
position: absolute; | ||
bottom: 50%; | ||
left: 50%; | ||
transform-origin: bottom center; | ||
|
||
&--minutes { | ||
width: $minute-width; | ||
height: $minute-height; | ||
background-color: $minute-color; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The variable |
||
|
||
transform: translateX(-50%); | ||
z-index: 0; | ||
|
||
animation: rotate-minutes 3600s steps(60) infinite; | ||
} | ||
|
||
&--seconds { | ||
width: $second-width; | ||
height: $second-height; | ||
background-color: $second-color; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The variable |
||
|
||
transform: translateX(-50%); | ||
z-index: 1; | ||
|
||
animation: rotate-seconds 60s linear infinite; | ||
} | ||
} | ||
|
||
&--speed-up { | ||
.stopwatch__hand--seconds { | ||
animation-duration: 10s; | ||
} | ||
|
||
.stopwatch__hand--minutes { | ||
animation-duration: 600s; | ||
} | ||
} | ||
} | ||
|
||
@keyframes rotate-seconds { | ||
from { | ||
transform: translateX(-50%) rotate(0deg); | ||
} | ||
to { | ||
transform: translateX(-50%) rotate(360deg); | ||
} | ||
} | ||
|
||
@keyframes rotate-minutes { | ||
from { | ||
transform: translateX(-50%) rotate(0deg); | ||
} | ||
to { | ||
transform: translateX(-50%) rotate(360deg); | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
@import './utils/variables'; | ||
@import './blocks/stopwatch'; | ||
@import './index'; |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
$minute-color: #0700ff; | ||
$second-color: #2c8000; | ||
$center-color: #f6a603; | ||
$border-color: #000; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The variable
$border-color
is used here but is not defined in this file. Make sure to define it or import it from another file where it is defined.