Skip to content

Commit 0a19f7a

Browse files
Marinich MaximMarinich Maxim
Marinich Maxim
authored and
Marinich Maxim
committed
fix resize event
1 parent a21b5a0 commit 0a19f7a

14 files changed

+455
-20
lines changed

.eslintrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"indent": ["warn", "tab", { "SwitchCase": 1 }],
3636
"no-debugger": 0,
3737
"no-console": [
38-
"error",
38+
"warn",
3939
{
4040
"allow": ["debug"]
4141
}

package-lock.json

+64-8
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+3
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@
7676
"@babel/preset-react": "7.18.6",
7777
"@babel/preset-typescript": "7.18.6",
7878
"@babel/runtime": "7.20.1",
79+
"@types/d3-ease": "^3.0.2",
7980
"@types/jest": "29.2.3",
8081
"@types/react": "18.0.25",
8182
"@types/react-dom": "18.0.9",
@@ -87,6 +88,7 @@
8788
"copy-webpack-plugin": "11.0.0",
8889
"core-js": "3.26.1",
8990
"css-loader": "6.7.2",
91+
"d3-ease": "^3.0.1",
9092
"eslint": "8.27.0",
9193
"eslint-plugin-react": "7.31.10",
9294
"eslint-webpack-plugin": "^3.2.0",
@@ -105,6 +107,7 @@
105107
"markdown-loader": "8.0.0",
106108
"marked": "4.2.2",
107109
"mini-css-extract-plugin": "2.7.0",
110+
"nanoid": "^5.0.6",
108111
"react": "18.2.0",
109112
"react-dom": "18.2.0",
110113
"rimraf": "3.0.2",

src/common.scss

+21-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
$color-light: #fff;
2-
$color-bg: #C7CDDE;
2+
$color-bg: #c7cdde;
33
$color-accent: darkred;
44
$color-dark: #435794;
55
$color-dark-lighten: #3f51b5;
@@ -8,6 +8,25 @@ $color-base-lighten: #b1e9ea;
88
$content-max-width: 1200px;
99
$content-min-width: 320px;
1010

11+
$color-roulette-6: rgba(18, 4, 28, 1);
12+
$color-roulette-5: rgba(58, 8, 95, 1);
13+
$color-roulette-4: rgba(75, 30, 121, 1);
14+
$color-roulette-3: rgb(92, 49, 151);
15+
$color-roulette-2: rgb(131, 110, 179);
16+
$color-roulette-1: rgb(186, 175, 213);
17+
18+
//$color-roulette-5: rgba(10, 28, 102, 0.9);
19+
//$color-roulette-4: rgba(10, 28, 102, 0.7);
20+
//$color-roulette-3: rgba(10, 28, 102, 0.6);
21+
//$color-roulette-2: rgba(10, 28, 102, 0.5);
22+
//$color-roulette-1: rgba(10, 28, 102, 0.3);
23+
//
24+
//$color-roulette-5: rgba(63, 81, 181, 1);
25+
//$color-roulette-4: rgba(63, 81, 181, 0.8);
26+
//$color-roulette-3: rgba(63, 81, 181, 0.6);
27+
//$color-roulette-2: rgba(63, 81, 181, 0.5);
28+
//$color-roulette-1: rgba(63, 81, 181, 0.4);
29+
1130
@mixin container {
1231
width: 100%;
1332
height: 100%;
@@ -16,5 +35,5 @@ $content-min-width: 320px;
1635
box-sizing: border-box;
1736
margin: auto;
1837
overflow-x: hidden;
19-
padding: 20px;
38+
padding: 20px;
2039
}

src/components/pages/index.tsx

+4
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import StagePaddingPage from './stage-padding';
88
import Events from './events';
99
import CustomComponents from './custom-components';
1010
import LazyLoadingPage from './lazy-loading';
11+
import SandboxPage from './sandbox';
1112
import './styles.scss';
1213

1314
export default function getPageComponent(pageID = '') {
@@ -38,5 +39,8 @@ export default function getPageComponent(pageID = '') {
3839
if (pageID === 'lazy-loading') {
3940
return <LazyLoadingPage />;
4041
}
42+
if (pageID === 'sandbox') {
43+
return <SandboxPage />;
44+
}
4145
return null;
4246
}
+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
import React from 'react';
2+
import RouletteExample from './roulette/Roulette';
3+
import Anchor, { genAnchorProps } from '../../the-anchor';
4+
5+
export default function SandboxPage() {
6+
return (
7+
<section className="p-basic p-sandbox">
8+
<h2 className="title">
9+
<Anchor {...genAnchorProps('sandbox-roulette')} />
10+
&nbsp; Roulette Animation
11+
</h2>
12+
<RouletteExample />
13+
<br />
14+
<br />
15+
<br />
16+
</section>
17+
);
18+
}

0 commit comments

Comments
 (0)