@onepercentio/one-ui 0.29.2 → 0.29.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Switch/Switch.d.ts +1 -1
- package/dist/components/Switch/Switch.js +1 -1
- package/dist/hooks/useHero.js +3 -2
- package/dist-ts/components/Switch/Switch.d.ts +1 -1
- package/dist-ts/hooks/useHero.js +5 -4
- package/dist-ts/hooks/useHero.js.map +1 -1
- package/package.json +5 -1
- package/src/assets/img/svg/checkbox.svg +0 -3
- package/src/assets/styles/index.scss +0 -2
- package/src/assets/styles/mixins.scss +0 -12
- package/src/assets/styles/variables.scss +0 -49
- package/src/components/AdaptiveButton/AdaptiveButton.module.scss +0 -7
- package/src/components/AdaptiveButton/AdaptiveButton.tsx +0 -26
- package/src/components/AdaptiveButton/index.tsx +0 -2
- package/src/components/AdaptiveContainer/AdaptiveContainer.module.scss +0 -53
- package/src/components/AdaptiveContainer/AdaptiveContainer.tsx +0 -200
- package/src/components/AdaptiveContainer/index.tsx +0 -2
- package/src/components/AdaptiveDialog/AdaptiveDialog.module.scss +0 -147
- package/src/components/AdaptiveDialog/AdaptiveDialog.tsx +0 -97
- package/src/components/AdaptiveDialog/index.tsx +0 -2
- package/src/components/AdaptiveSidebar/AdaptiveSidebar.module.scss +0 -49
- package/src/components/AdaptiveSidebar/AdaptiveSidebar.sample.tsx +0 -10
- package/src/components/AdaptiveSidebar/AdaptiveSidebar.tsx +0 -123
- package/src/components/AdaptiveSidebar/index.tsx +0 -2
- package/src/components/AnchoredTooltip/AnchoredTooltip.module.scss +0 -64
- package/src/components/AnchoredTooltip/AnchoredTooltip.tsx +0 -250
- package/src/components/AnchoredTooltip/index.tsx +0 -2
- package/src/components/AnimatedEntrance/AnimatedEntrance.module.scss +0 -108
- package/src/components/AnimatedEntrance/AnimatedEntrance.tsx +0 -227
- package/src/components/AnimatedEntrance/index.tsx +0 -2
- package/src/components/AsyncWrapper/AsyncWrapper.tsx +0 -38
- package/src/components/AsyncWrapper/index.tsx +0 -2
- package/src/components/Avatar/Avatar.module.scss +0 -22
- package/src/components/Avatar/Avatar.tsx +0 -31
- package/src/components/Avatar/index.tsx +0 -2
- package/src/components/BucketFill/BucketFill.module.scss +0 -36
- package/src/components/BucketFill/BucketFill.tsx +0 -65
- package/src/components/BucketFill/index.tsx +0 -2
- package/src/components/Button/Button.module.scss +0 -45
- package/src/components/Button/Button.tsx +0 -40
- package/src/components/Button/index.tsx +0 -2
- package/src/components/Card/Card.module.scss +0 -12
- package/src/components/Card/Card.tsx +0 -9
- package/src/components/Card/index.tsx +0 -2
- package/src/components/Chart/Chart.e2e.ts +0 -4
- package/src/components/Chart/Chart.logic.tsx +0 -8
- package/src/components/Chart/Chart.module.scss +0 -58
- package/src/components/Chart/Chart.tsx +0 -2
- package/src/components/Chart/Chart.types.ts +0 -35
- package/src/components/Chart/Chart.view.tsx +0 -241
- package/src/components/Chart/index.tsx +0 -2
- package/src/components/CheckBox/CheckBox.module.scss +0 -36
- package/src/components/CheckBox/CheckBox.tsx +0 -63
- package/src/components/CheckBox/index.tsx +0 -2
- package/src/components/CodeInput/CodeInput.module.scss +0 -5
- package/src/components/CodeInput/CodeInput.tsx +0 -84
- package/src/components/CodeInput/index.tsx +0 -2
- package/src/components/Collapsable/Collapsable.module.scss +0 -42
- package/src/components/Collapsable/Collapsable.tsx +0 -253
- package/src/components/Collapsable/index.tsx +0 -2
- package/src/components/Countdown/Countdown.tsx +0 -130
- package/src/components/Countdown/index.tsx +0 -2
- package/src/components/CurrencyInput/CurrencyInput.hook.ts +0 -37
- package/src/components/CurrencyInput/CurrencyInput.tsx +0 -25
- package/src/components/CurrencyInput/index.tsx +0 -2
- package/src/components/Divider/Divider.module.scss +0 -7
- package/src/components/Divider/Divider.tsx +0 -13
- package/src/components/Divider/index.tsx +0 -2
- package/src/components/EmailInput/EmailInput.module.scss +0 -0
- package/src/components/EmailInput/EmailInput.tsx +0 -51
- package/src/components/EmailInput/index.tsx +0 -2
- package/src/components/FadeIn/FadeIn.module.scss +0 -9
- package/src/components/FadeIn/FadeIn.tsx +0 -77
- package/src/components/FadeIn/index.tsx +0 -2
- package/src/components/FileInput/FileInput.module.scss +0 -6
- package/src/components/FileInput/FileInput.tsx +0 -75
- package/src/components/FileInput/View/BigFactory/BigFactory.module.scss +0 -20
- package/src/components/FileInput/View/BigFactory/BigFactory.tsx +0 -48
- package/src/components/FileInput/View/BigFactory/index.tsx +0 -2
- package/src/components/FileInput/View/Compact/Compact.module.scss +0 -68
- package/src/components/FileInput/View/Compact/Compact.tsx +0 -151
- package/src/components/FileInput/View/Compact/index.tsx +0 -2
- package/src/components/FileInput/View/View.types.ts +0 -12
- package/src/components/FileInput/index.tsx +0 -2
- package/src/components/FlowController/FlowController.module.scss +0 -47
- package/src/components/FlowController/FlowController.tsx +0 -93
- package/src/components/FlowController/index.tsx +0 -2
- package/src/components/Form/Form.tsx +0 -243
- package/src/components/Form/index.ts +0 -2
- package/src/components/Form/v2/Form.hook.ts +0 -341
- package/src/components/Form/v2/Form.module.scss +0 -0
- package/src/components/Form/v2/Form.tsx +0 -78
- package/src/components/Form/v2/Form.types.ts +0 -118
- package/src/components/Form/v2/FormField/Extensions/DateField/DateField.module.scss +0 -0
- package/src/components/Form/v2/FormField/Extensions/DateField/DateField.tsx +0 -73
- package/src/components/Form/v2/FormField/Extensions/DateField/index.tsx +0 -2
- package/src/components/Form/v2/FormField/Extensions/PhoneField/PhoneField.module.scss +0 -0
- package/src/components/Form/v2/FormField/Extensions/PhoneField/PhoneField.tsx +0 -91
- package/src/components/Form/v2/FormField/Extensions/PhoneField/index.tsx +0 -2
- package/src/components/Form/v2/FormField/FormField.module.scss +0 -0
- package/src/components/Form/v2/FormField/FormField.tsx +0 -378
- package/src/components/Form/v2/FormField/FormField.types.ts +0 -129
- package/src/components/Form/v2/FormField/index.tsx +0 -2
- package/src/components/Form/v2/index.tsx +0 -2
- package/src/components/Freeze/Freeze.tsx +0 -9
- package/src/components/Freeze/index.tsx +0 -2
- package/src/components/HSForms/HSForms.tsx +0 -57
- package/src/components/HSForms/index.tsx +0 -2
- package/src/components/Header/Header.module.scss +0 -119
- package/src/components/Header/Header.tsx +0 -138
- package/src/components/Header/index.tsx +0 -2
- package/src/components/HeaderCloseBtn/HeaderCloseBtn.module.scss +0 -44
- package/src/components/HeaderCloseBtn/HeaderCloseBtn.tsx +0 -28
- package/src/components/HeaderCloseBtn/index.tsx +0 -2
- package/src/components/InfinityScroll/InfinityScroll.module.scss +0 -30
- package/src/components/InfinityScroll/InfinityScroll.tsx +0 -187
- package/src/components/InfinityScroll/index.tsx +0 -2
- package/src/components/Input/Input.module.scss +0 -71
- package/src/components/Input/Input.tsx +0 -134
- package/src/components/Input/index.tsx +0 -2
- package/src/components/InstantCounter/InstantCounter.tsx +0 -77
- package/src/components/InstantCounter/index.tsx +0 -2
- package/src/components/LavaLamp/LavaLamp.data.tsx +0 -114
- package/src/components/LavaLamp/LavaLamp.module.scss +0 -26
- package/src/components/LavaLamp/LavaLamp.tsx +0 -131
- package/src/components/LavaLamp/index.tsx +0 -2
- package/src/components/LavaLamp/v2/LavaLamp.module.scss +0 -23
- package/src/components/LavaLamp/v2/LavaLamp.tsx +0 -197
- package/src/components/LinkToId/LinkToId.module.scss +0 -4
- package/src/components/LinkToId/LinkToId.tsx +0 -51
- package/src/components/LinkToId/index.tsx +0 -2
- package/src/components/Loader/Loader.module.scss +0 -40
- package/src/components/Loader/Loader.tsx +0 -18
- package/src/components/Loader/index.tsx +0 -2
- package/src/components/LoaderDotsIndicator/LoaderDotsIndicator.tsx +0 -34
- package/src/components/LoaderDotsIndicator/index.tsx +0 -2
- package/src/components/LoopableVideo/LoopableVideo.tsx +0 -37
- package/src/components/LoopableVideo/index.tsx +0 -2
- package/src/components/MainGrid/MainGrid.module.scss +0 -28
- package/src/components/MainGrid/MainGrid.tsx +0 -68
- package/src/components/MainGrid/index.tsx +0 -2
- package/src/components/MutableHamburgerButton/MutableHamburgerButton.module.scss +0 -220
- package/src/components/MutableHamburgerButton/MutableHamburgerButton.tsx +0 -38
- package/src/components/MutableHamburgerButton/index.tsx +0 -2
- package/src/components/Notification/Notification.module.scss +0 -25
- package/src/components/Notification/Notification.tsx +0 -13
- package/src/components/Notification/index.tsx +0 -2
- package/src/components/OrderableList/OrderableList.module.scss +0 -98
- package/src/components/OrderableList/OrderableList.tsx +0 -564
- package/src/components/OrderableList/index.tsx +0 -2
- package/src/components/PaginationIndicator/PaginationIndicator.tsx +0 -365
- package/src/components/PaginationIndicator/index.tsx +0 -2
- package/src/components/Parallax/Parallax.module.scss +0 -28
- package/src/components/Parallax/Parallax.tsx +0 -225
- package/src/components/Parallax/index.tsx +0 -2
- package/src/components/Parallax/math/helpers.ts +0 -289
- package/src/components/PasswordInput/PasswordInput.module.scss +0 -17
- package/src/components/PasswordInput/PasswordInput.tsx +0 -154
- package/src/components/PasswordInput/index.tsx +0 -2
- package/src/components/PingPongText/PingPongText.module.scss +0 -4
- package/src/components/PingPongText/PingPongText.tsx +0 -83
- package/src/components/PingPongText/index.tsx +0 -2
- package/src/components/PixelatedScan/PixelatedScan.module.scss +0 -86
- package/src/components/PixelatedScan/PixelatedScan.tsx +0 -175
- package/src/components/PixelatedScan/index.tsx +0 -2
- package/src/components/Portal/Portal.module.scss +0 -3
- package/src/components/Portal/Portal.tsx +0 -68
- package/src/components/Portal/index.tsx +0 -2
- package/src/components/ProgressBar/ProgressBar.module.scss +0 -44
- package/src/components/ProgressBar/ProgressBar.tsx +0 -124
- package/src/components/ProgressBar/index.tsx +0 -2
- package/src/components/ProgressTexts/ProgressTexts.module.scss +0 -37
- package/src/components/ProgressTexts/ProgressTexts.tsx +0 -85
- package/src/components/ProgressTexts/index.tsx +0 -2
- package/src/components/Radio/Radio.module.scss +0 -36
- package/src/components/Radio/Radio.tsx +0 -53
- package/src/components/Radio/index.tsx +0 -2
- package/src/components/SectionContainer/SectionContainer.module.scss +0 -30
- package/src/components/SectionContainer/SectionContainer.tsx +0 -49
- package/src/components/SectionContainer/index.tsx +0 -2
- package/src/components/Select/Select.module.scss +0 -58
- package/src/components/Select/Select.tsx +0 -192
- package/src/components/Select/index.tsx +0 -2
- package/src/components/Skeleton/Skeleton.module.scss +0 -21
- package/src/components/Skeleton/Skeleton.tsx +0 -29
- package/src/components/Skeleton/index.tsx +0 -2
- package/src/components/Spacing/Spacing.module.scss +0 -13
- package/src/components/Spacing/Spacing.tsx +0 -24
- package/src/components/Spacing/index.tsx +0 -2
- package/src/components/StaticScroller/StaticScroller.module.scss +0 -14
- package/src/components/StaticScroller/StaticScroller.tsx +0 -83
- package/src/components/StaticScroller/index.tsx +0 -2
- package/src/components/Switch/Switch.module.scss +0 -43
- package/src/components/Switch/Switch.tsx +0 -41
- package/src/components/Switch/index.tsx +0 -2
- package/src/components/Table/Table.module.scss +0 -76
- package/src/components/Table/Table.tsx +0 -152
- package/src/components/Table/index.tsx +0 -2
- package/src/components/Tabs/Tabs.module.scss +0 -40
- package/src/components/Tabs/Tabs.tsx +0 -104
- package/src/components/Tabs/index.tsx +0 -2
- package/src/components/Text/Text.module.scss +0 -81
- package/src/components/Text/Text.tsx +0 -42
- package/src/components/Text/index.tsx +0 -2
- package/src/components/Transition/MasksFactory/DiagonalReveal.tsx +0 -47
- package/src/components/Transition/MasksFactory/DiagonalSquareToBalls.tsx +0 -78
- package/src/components/Transition/MasksFactory/PhysicsSquares.tsx +0 -106
- package/src/components/Transition/MasksFactory/SquareToBalls.tsx +0 -66
- package/src/components/Transition/MasksFactory/utils.ts +0 -35
- package/src/components/Transition/Transition.module.scss +0 -211
- package/src/components/Transition/Transition.tsx +0 -495
- package/src/components/Transition/index.tsx +0 -2
- package/src/components/UncontrolledTransition/UncontrolledTransition.ai.md +0 -9
- package/src/components/UncontrolledTransition/UncontrolledTransition.sample.tsx +0 -34
- package/src/components/UncontrolledTransition/UncontrolledTransition.tsx +0 -143
- package/src/components/UncontrolledTransition/index.tsx +0 -2
- package/src/components/WalletConnectionWrapper/WalletConnectionWrapper.tsx +0 -212
- package/src/components/WalletConnectionWrapper/index.tsx +0 -2
- package/src/components/utilitary/ScrollAndFocusLock/ScrollAndFocusLock.module.scss +0 -5
- package/src/components/utilitary/ScrollAndFocusLock/ScrollAndFocusLock.tsx +0 -52
- package/src/components/utilitary/ScrollAndFocusLock/index.tsx +0 -2
- package/src/context/AsyncProcess.tsx +0 -107
- package/src/context/ContextAsyncControl.tsx +0 -89
- package/src/context/CustomBrowserRouter.tsx +0 -55
- package/src/context/OneUIProvider.tsx +0 -308
- package/src/hooks/logs/useDependencyChangeDetection.ts +0 -25
- package/src/hooks/logs/useIsMounting.ts +0 -7
- package/src/hooks/persistence/useLocalStorage.ts +0 -45
- package/src/hooks/shims/ObjectWatchShim.ts +0 -56
- package/src/hooks/ui/useAdaptiveImage.tsx +0 -36
- package/src/hooks/ui/useAlternating.tsx +0 -22
- package/src/hooks/ui/useBreakpoint.tsx +0 -21
- package/src/hooks/ui/useCustomScrollbar.module.scss +0 -20
- package/src/hooks/ui/useCustomScrollbar.tsx +0 -22
- package/src/hooks/ui/useEffectIf.ts +0 -11
- package/src/hooks/ui/useMouseHover.tsx +0 -26
- package/src/hooks/ui/usePaginationControls.module.scss +0 -16
- package/src/hooks/ui/usePaginationControls.tsx +0 -176
- package/src/hooks/ui/useSnapToViewport.module.scss +0 -6
- package/src/hooks/ui/useSnapToViewport.ts +0 -28
- package/src/hooks/ui/useTilt.tsx +0 -219
- package/src/hooks/ui/useZoomable.module.scss +0 -34
- package/src/hooks/ui/useZoomable.tsx +0 -144
- package/src/hooks/useAsyncControl.ai.md +0 -25
- package/src/hooks/useAsyncControl.ts +0 -101
- package/src/hooks/useContainedRepositioning.ts +0 -110
- package/src/hooks/useCustomHistory.ts +0 -14
- package/src/hooks/useElementFit.ts +0 -82
- package/src/hooks/useFirestoreWatch.ts +0 -54
- package/src/hooks/useForm.ts +0 -49
- package/src/hooks/useFreeze.ts +0 -12
- package/src/hooks/useHero.module.scss +0 -41
- package/src/hooks/useHero.ts +0 -512
- package/src/hooks/useIntersection.ts +0 -32
- package/src/hooks/useMergeRefs.ts +0 -29
- package/src/hooks/useObserve.ts +0 -24
- package/src/hooks/usePagination.ts +0 -228
- package/src/hooks/usePooledOperation.ts +0 -54
- package/src/hooks/usePooling.ts +0 -46
- package/src/hooks/useRebound.ts +0 -23
- package/src/hooks/useShortIntl.ai.md +0 -5
- package/src/hooks/useShortIntl.ts +0 -97
- package/src/hooks/utility/useAsyncMemo.ts +0 -43
- package/src/hooks/utility/useDepChange.ts +0 -11
- package/src/hooks/utility/useEvents.ts +0 -33
- package/src/hooks/utility/useImmediate.ts +0 -8
- package/src/hooks/utility/useManualInit.ts +0 -24
- package/src/hooks/utility/useModule.ts +0 -15
- package/src/hooks/utility/useQuery.ts +0 -15
- package/src/hooks/utility/useUniqueEffect.ts +0 -22
- package/src/index.preprocess.ts +0 -82
- package/src/index.ts +0 -229
- package/src/models/DebugLogger.ts +0 -7
- package/src/models/GenericContract.ts +0 -169
- package/src/models/Orbs.ts +0 -97
- package/src/reac-app-env.d.ts +0 -6
- package/src/storybook/assets/video/txt-reversed.mp4 +0 -0
- package/src/storybookUtils/index.tsx +0 -53
- package/src/test.tsx +0 -0
- package/src/type-utils.ts +0 -49
- package/src/types.ts +0 -199
- package/src/utility.d.ts +0 -70
- package/src/utils/blockchain.ts +0 -43
- package/src/utils/e2e.ts +0 -55
- package/src/utils/flatten.ts +0 -17
- package/src/utils/formatters.ts +0 -36
- package/src/utils/html.utils.ts +0 -3
- package/src/utils/ownEvent.ts +0 -8
- package/src/utils/test.ts +0 -20
|
@@ -1,289 +0,0 @@
|
|
|
1
|
-
export type Matrix3D = [
|
|
2
|
-
[number, number, number, number],
|
|
3
|
-
[number, number, number, number],
|
|
4
|
-
[number, number, number, number],
|
|
5
|
-
[number, number, number, number]
|
|
6
|
-
];
|
|
7
|
-
export type OperationData =
|
|
8
|
-
| {
|
|
9
|
-
type: "rotateX" | "rotateY" | "rotateZ";
|
|
10
|
-
angle: number;
|
|
11
|
-
}
|
|
12
|
-
| {
|
|
13
|
-
type: "translate";
|
|
14
|
-
x: number;
|
|
15
|
-
y: number;
|
|
16
|
-
z: number;
|
|
17
|
-
}
|
|
18
|
-
| {
|
|
19
|
-
type: "scale";
|
|
20
|
-
factorX: number;
|
|
21
|
-
factorY: number;
|
|
22
|
-
factorZ: number;
|
|
23
|
-
}
|
|
24
|
-
| {
|
|
25
|
-
type: "perspective";
|
|
26
|
-
fieldOfViewInRadians: number;
|
|
27
|
-
aspect: number;
|
|
28
|
-
near: number;
|
|
29
|
-
far: number;
|
|
30
|
-
}
|
|
31
|
-
| {
|
|
32
|
-
type: "matrix";
|
|
33
|
-
matrix: Matrix3D;
|
|
34
|
-
};
|
|
35
|
-
export function IDENTITY_MATRIX() {
|
|
36
|
-
return [
|
|
37
|
-
[1, 0, 0, 0], // cos, -sin, ?
|
|
38
|
-
[0, 1, 0, 0], // sin, cos, ?
|
|
39
|
-
[0, 0, 1, 0], // TranslationX, TranslationY, ?
|
|
40
|
-
[0, 0, 0, 1],
|
|
41
|
-
] as Matrix3D;
|
|
42
|
-
}
|
|
43
|
-
export function generateMatrixFromOperations(
|
|
44
|
-
...operations: OperationData[]
|
|
45
|
-
): Matrix3D {
|
|
46
|
-
let resultingMatrix: Matrix3D | undefined = undefined;
|
|
47
|
-
for (let operation of operations) {
|
|
48
|
-
const matrix =
|
|
49
|
-
operation.type === "matrix" ? operation.matrix : IDENTITY_MATRIX();
|
|
50
|
-
switch (operation.type) {
|
|
51
|
-
case "perspective":
|
|
52
|
-
const f = Math.tan(
|
|
53
|
-
Math.PI * 0.5 - 0.5 * operation.fieldOfViewInRadians
|
|
54
|
-
);
|
|
55
|
-
const rangeInv = 1.0 / (operation.near - operation.far);
|
|
56
|
-
|
|
57
|
-
matrix[0][0] = f / operation.aspect;
|
|
58
|
-
matrix[1][1] = f;
|
|
59
|
-
matrix[2][2] = (operation.near + operation.far) * rangeInv;
|
|
60
|
-
matrix[2][3] = -1;
|
|
61
|
-
matrix[3][2] = operation.near * operation.far * rangeInv * 2;
|
|
62
|
-
matrix[3][3] = 0;
|
|
63
|
-
break;
|
|
64
|
-
case "translate":
|
|
65
|
-
matrix[3][0] = operation.x;
|
|
66
|
-
matrix[3][1] = operation.y;
|
|
67
|
-
matrix[3][2] = operation.z;
|
|
68
|
-
break;
|
|
69
|
-
case "rotateX":
|
|
70
|
-
case "rotateY":
|
|
71
|
-
case "rotateZ":
|
|
72
|
-
const angleToRadians = (operation.angle * Math.PI) / 180;
|
|
73
|
-
const sinAngle = Math.sin(angleToRadians);
|
|
74
|
-
const cosAngle = Math.cos(angleToRadians);
|
|
75
|
-
switch (operation.type) {
|
|
76
|
-
case "rotateZ":
|
|
77
|
-
matrix[0][0] = cosAngle;
|
|
78
|
-
matrix[1][1] = cosAngle;
|
|
79
|
-
matrix[1][0] = -sinAngle;
|
|
80
|
-
matrix[0][1] = sinAngle;
|
|
81
|
-
break;
|
|
82
|
-
case "rotateY":
|
|
83
|
-
matrix[0][0] = cosAngle;
|
|
84
|
-
matrix[2][2] = cosAngle;
|
|
85
|
-
matrix[0][2] = -sinAngle;
|
|
86
|
-
matrix[2][0] = sinAngle;
|
|
87
|
-
break;
|
|
88
|
-
case "rotateX":
|
|
89
|
-
matrix[1][1] = cosAngle;
|
|
90
|
-
matrix[2][2] = cosAngle;
|
|
91
|
-
matrix[2][1] = -sinAngle;
|
|
92
|
-
matrix[1][2] = sinAngle;
|
|
93
|
-
break;
|
|
94
|
-
}
|
|
95
|
-
break;
|
|
96
|
-
case "scale":
|
|
97
|
-
matrix[0][0] = operation.factorX;
|
|
98
|
-
matrix[1][1] = operation.factorY;
|
|
99
|
-
matrix[2][2] = operation.factorZ;
|
|
100
|
-
break;
|
|
101
|
-
}
|
|
102
|
-
if (resultingMatrix) {
|
|
103
|
-
resultingMatrix = multiplyMatrixes(resultingMatrix, matrix) as Matrix3D;
|
|
104
|
-
} else {
|
|
105
|
-
resultingMatrix = matrix;
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
return resultingMatrix || IDENTITY_MATRIX();
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
type NumberMatrix = readonly (readonly number[])[];
|
|
113
|
-
export function multiplyMatrixes<X extends NumberMatrix>(
|
|
114
|
-
matrix1: X,
|
|
115
|
-
matrix2: NumberMatrix & { length: X[number]["length"] }
|
|
116
|
-
) {
|
|
117
|
-
const resultingMatrix: number[][] = [];
|
|
118
|
-
if (
|
|
119
|
-
process.env.NODE_ENV === "development" &&
|
|
120
|
-
matrix2.length !== matrix1[0].length
|
|
121
|
-
) {
|
|
122
|
-
throw new Error(`For the multiplication of matrixes to work you need to provide the matrix1 containing the amount of columns as the same amount of rows from matrix 2.
|
|
123
|
-
You provided ${matrix1[0].length} columns and ${matrix2.length} rows`);
|
|
124
|
-
}
|
|
125
|
-
for (let i0 in matrix1) {
|
|
126
|
-
for (let i in matrix2[0]) {
|
|
127
|
-
let dimensionResult = 0;
|
|
128
|
-
for (let i2 in matrix1[0]) {
|
|
129
|
-
dimensionResult += matrix1[i0][i2] * matrix2[i2][i];
|
|
130
|
-
}
|
|
131
|
-
if (!resultingMatrix[i0]) resultingMatrix[i0] = [];
|
|
132
|
-
resultingMatrix[i0][i] = dimensionResult;
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
return resultingMatrix;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
export function invertMatrix(matrix: Matrix3D) {
|
|
139
|
-
const m = flattenMatrix(matrix);
|
|
140
|
-
let det: number = 0;
|
|
141
|
-
const inv = [];
|
|
142
|
-
|
|
143
|
-
inv[0] =
|
|
144
|
-
m[5] * m[10] * m[15] -
|
|
145
|
-
m[5] * m[11] * m[14] -
|
|
146
|
-
m[9] * m[6] * m[15] +
|
|
147
|
-
m[9] * m[7] * m[14] +
|
|
148
|
-
m[13] * m[6] * m[11] -
|
|
149
|
-
m[13] * m[7] * m[10];
|
|
150
|
-
|
|
151
|
-
inv[4] =
|
|
152
|
-
-m[4] * m[10] * m[15] +
|
|
153
|
-
m[4] * m[11] * m[14] +
|
|
154
|
-
m[8] * m[6] * m[15] -
|
|
155
|
-
m[8] * m[7] * m[14] -
|
|
156
|
-
m[12] * m[6] * m[11] +
|
|
157
|
-
m[12] * m[7] * m[10];
|
|
158
|
-
|
|
159
|
-
inv[8] =
|
|
160
|
-
m[4] * m[9] * m[15] -
|
|
161
|
-
m[4] * m[11] * m[13] -
|
|
162
|
-
m[8] * m[5] * m[15] +
|
|
163
|
-
m[8] * m[7] * m[13] +
|
|
164
|
-
m[12] * m[5] * m[11] -
|
|
165
|
-
m[12] * m[7] * m[9];
|
|
166
|
-
|
|
167
|
-
inv[12] =
|
|
168
|
-
-m[4] * m[9] * m[14] +
|
|
169
|
-
m[4] * m[10] * m[13] +
|
|
170
|
-
m[8] * m[5] * m[14] -
|
|
171
|
-
m[8] * m[6] * m[13] -
|
|
172
|
-
m[12] * m[5] * m[10] +
|
|
173
|
-
m[12] * m[6] * m[9];
|
|
174
|
-
|
|
175
|
-
inv[1] =
|
|
176
|
-
-m[1] * m[10] * m[15] +
|
|
177
|
-
m[1] * m[11] * m[14] +
|
|
178
|
-
m[9] * m[2] * m[15] -
|
|
179
|
-
m[9] * m[3] * m[14] -
|
|
180
|
-
m[13] * m[2] * m[11] +
|
|
181
|
-
m[13] * m[3] * m[10];
|
|
182
|
-
|
|
183
|
-
inv[5] =
|
|
184
|
-
m[0] * m[10] * m[15] -
|
|
185
|
-
m[0] * m[11] * m[14] -
|
|
186
|
-
m[8] * m[2] * m[15] +
|
|
187
|
-
m[8] * m[3] * m[14] +
|
|
188
|
-
m[12] * m[2] * m[11] -
|
|
189
|
-
m[12] * m[3] * m[10];
|
|
190
|
-
|
|
191
|
-
inv[9] =
|
|
192
|
-
-m[0] * m[9] * m[15] +
|
|
193
|
-
m[0] * m[11] * m[13] +
|
|
194
|
-
m[8] * m[1] * m[15] -
|
|
195
|
-
m[8] * m[3] * m[13] -
|
|
196
|
-
m[12] * m[1] * m[11] +
|
|
197
|
-
m[12] * m[3] * m[9];
|
|
198
|
-
|
|
199
|
-
inv[13] =
|
|
200
|
-
m[0] * m[9] * m[14] -
|
|
201
|
-
m[0] * m[10] * m[13] -
|
|
202
|
-
m[8] * m[1] * m[14] +
|
|
203
|
-
m[8] * m[2] * m[13] +
|
|
204
|
-
m[12] * m[1] * m[10] -
|
|
205
|
-
m[12] * m[2] * m[9];
|
|
206
|
-
|
|
207
|
-
inv[2] =
|
|
208
|
-
m[1] * m[6] * m[15] -
|
|
209
|
-
m[1] * m[7] * m[14] -
|
|
210
|
-
m[5] * m[2] * m[15] +
|
|
211
|
-
m[5] * m[3] * m[14] +
|
|
212
|
-
m[13] * m[2] * m[7] -
|
|
213
|
-
m[13] * m[3] * m[6];
|
|
214
|
-
|
|
215
|
-
inv[6] =
|
|
216
|
-
-m[0] * m[6] * m[15] +
|
|
217
|
-
m[0] * m[7] * m[14] +
|
|
218
|
-
m[4] * m[2] * m[15] -
|
|
219
|
-
m[4] * m[3] * m[14] -
|
|
220
|
-
m[12] * m[2] * m[7] +
|
|
221
|
-
m[12] * m[3] * m[6];
|
|
222
|
-
|
|
223
|
-
inv[10] =
|
|
224
|
-
m[0] * m[5] * m[15] -
|
|
225
|
-
m[0] * m[7] * m[13] -
|
|
226
|
-
m[4] * m[1] * m[15] +
|
|
227
|
-
m[4] * m[3] * m[13] +
|
|
228
|
-
m[12] * m[1] * m[7] -
|
|
229
|
-
m[12] * m[3] * m[5];
|
|
230
|
-
|
|
231
|
-
inv[14] =
|
|
232
|
-
-m[0] * m[5] * m[14] +
|
|
233
|
-
m[0] * m[6] * m[13] +
|
|
234
|
-
m[4] * m[1] * m[14] -
|
|
235
|
-
m[4] * m[2] * m[13] -
|
|
236
|
-
m[12] * m[1] * m[6] +
|
|
237
|
-
m[12] * m[2] * m[5];
|
|
238
|
-
|
|
239
|
-
inv[3] =
|
|
240
|
-
-m[1] * m[6] * m[11] +
|
|
241
|
-
m[1] * m[7] * m[10] +
|
|
242
|
-
m[5] * m[2] * m[11] -
|
|
243
|
-
m[5] * m[3] * m[10] -
|
|
244
|
-
m[9] * m[2] * m[7] +
|
|
245
|
-
m[9] * m[3] * m[6];
|
|
246
|
-
|
|
247
|
-
inv[7] =
|
|
248
|
-
m[0] * m[6] * m[11] -
|
|
249
|
-
m[0] * m[7] * m[10] -
|
|
250
|
-
m[4] * m[2] * m[11] +
|
|
251
|
-
m[4] * m[3] * m[10] +
|
|
252
|
-
m[8] * m[2] * m[7] -
|
|
253
|
-
m[8] * m[3] * m[6];
|
|
254
|
-
|
|
255
|
-
inv[11] =
|
|
256
|
-
-m[0] * m[5] * m[11] +
|
|
257
|
-
m[0] * m[7] * m[9] +
|
|
258
|
-
m[4] * m[1] * m[11] -
|
|
259
|
-
m[4] * m[3] * m[9] -
|
|
260
|
-
m[8] * m[1] * m[7] +
|
|
261
|
-
m[8] * m[3] * m[5];
|
|
262
|
-
|
|
263
|
-
inv[15] =
|
|
264
|
-
m[0] * m[5] * m[10] -
|
|
265
|
-
m[0] * m[6] * m[9] -
|
|
266
|
-
m[4] * m[1] * m[10] +
|
|
267
|
-
m[4] * m[2] * m[9] +
|
|
268
|
-
m[8] * m[1] * m[6] -
|
|
269
|
-
m[8] * m[2] * m[5];
|
|
270
|
-
|
|
271
|
-
det = m[0] * inv[0] + m[1] * inv[4] + m[2] * inv[8] + m[3] * inv[12];
|
|
272
|
-
|
|
273
|
-
if (det === 0)
|
|
274
|
-
throw new Error(
|
|
275
|
-
"Determinator is equal to 0. This matrix cannot be inverted"
|
|
276
|
-
);
|
|
277
|
-
|
|
278
|
-
det = 1.0 / det;
|
|
279
|
-
|
|
280
|
-
return inv.reduce((r, val, i) => {
|
|
281
|
-
const row = Math.floor(i / 4);
|
|
282
|
-
if (!r[row]) r[row] = [];
|
|
283
|
-
r[row][i % 4] = val * det;
|
|
284
|
-
return r;
|
|
285
|
-
}, [] as number[][]) as Matrix3D;
|
|
286
|
-
}
|
|
287
|
-
export function flattenMatrix(matrix: number[][]) {
|
|
288
|
-
return matrix.reduce((f, dimension) => [...f, ...dimension], [] as number[]);
|
|
289
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
.inputContainer {
|
|
2
|
-
&.creation {
|
|
3
|
-
padding-bottom: 54px;
|
|
4
|
-
}
|
|
5
|
-
position: relative;
|
|
6
|
-
|
|
7
|
-
.rules {
|
|
8
|
-
position: absolute;
|
|
9
|
-
bottom: 0px;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
&.icon > :first-child > :last-child {
|
|
13
|
-
top: initial;
|
|
14
|
-
align-self: center;
|
|
15
|
-
margin-top: -18px;
|
|
16
|
-
}
|
|
17
|
-
}
|
|
@@ -1,154 +0,0 @@
|
|
|
1
|
-
import React, {
|
|
2
|
-
ChangeEvent,
|
|
3
|
-
ForwardedRef,
|
|
4
|
-
forwardRef,
|
|
5
|
-
useImperativeHandle,
|
|
6
|
-
useState,
|
|
7
|
-
} from "react";
|
|
8
|
-
import { useOneUIConfig } from "../../context/OneUIProvider";
|
|
9
|
-
import Input from "../Input";
|
|
10
|
-
import Text from "../Text";
|
|
11
|
-
import Styles from "./PasswordInput.module.scss";
|
|
12
|
-
|
|
13
|
-
export type AVAILABLE_PASSWORD_VALIDATION_RULES = "size" | "duplication";
|
|
14
|
-
|
|
15
|
-
const BASE_VALIDATION = [
|
|
16
|
-
{ code: "size", validate: (pass: string) => pass.length >= 8 },
|
|
17
|
-
] as const;
|
|
18
|
-
const RULES = [
|
|
19
|
-
{
|
|
20
|
-
code: "duplication",
|
|
21
|
-
validate: (pass: string) => {
|
|
22
|
-
for (let i = 0; i < pass.length; i++) {
|
|
23
|
-
const charCode = pass.charCodeAt(i);
|
|
24
|
-
const [firstNext, secondNext] = [
|
|
25
|
-
pass.charCodeAt(i + 1) || 0,
|
|
26
|
-
pass.charCodeAt(i + 2) || 0,
|
|
27
|
-
];
|
|
28
|
-
|
|
29
|
-
if (firstNext - charCode === 1 && secondNext - firstNext === 1) {
|
|
30
|
-
return false;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
return true;
|
|
34
|
-
},
|
|
35
|
-
},
|
|
36
|
-
...BASE_VALIDATION,
|
|
37
|
-
] as const;
|
|
38
|
-
|
|
39
|
-
function _PasswordInput(
|
|
40
|
-
props: ({
|
|
41
|
-
value: string;
|
|
42
|
-
error?: string;
|
|
43
|
-
} & (
|
|
44
|
-
| {
|
|
45
|
-
mode: "input";
|
|
46
|
-
onChange: (password: string) => void;
|
|
47
|
-
}
|
|
48
|
-
| {
|
|
49
|
-
mode: "creation";
|
|
50
|
-
onChange: (password: string, isValid: boolean) => void;
|
|
51
|
-
messages: {
|
|
52
|
-
invalidRules: { [r in AVAILABLE_PASSWORD_VALIDATION_RULES]: string };
|
|
53
|
-
rulesTitle: string;
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
| {
|
|
57
|
-
mode: "comparision";
|
|
58
|
-
otherPassword: string;
|
|
59
|
-
onChange: (password: string, isEqual: boolean) => void;
|
|
60
|
-
messages: {
|
|
61
|
-
passwordsAreDifferent: string;
|
|
62
|
-
};
|
|
63
|
-
}
|
|
64
|
-
)) &
|
|
65
|
-
Omit<React.ComponentProps<typeof Input>, "value" | "onChange" | "ref">,
|
|
66
|
-
ref: ForwardedRef<{ validatePassword: (pass: string) => boolean }>
|
|
67
|
-
) {
|
|
68
|
-
const [isPasswordVisibile, setIPV] = useState(false);
|
|
69
|
-
const { passwordHidden, passwordVisible } = useOneUIConfig(
|
|
70
|
-
"component.passwordInput.iconSrc"
|
|
71
|
-
);
|
|
72
|
-
function _validatePassword(password: string) {
|
|
73
|
-
switch (props.mode) {
|
|
74
|
-
case "creation":
|
|
75
|
-
return RULES.reduce(
|
|
76
|
-
(isValid, R) => isValid && R.validate(password),
|
|
77
|
-
true as boolean
|
|
78
|
-
);
|
|
79
|
-
case "comparision":
|
|
80
|
-
return password === props.otherPassword;
|
|
81
|
-
case "input":
|
|
82
|
-
return BASE_VALIDATION.reduce(
|
|
83
|
-
(isValid, R) => isValid && R.validate(password),
|
|
84
|
-
true as boolean
|
|
85
|
-
);
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
useImperativeHandle(ref, () => ({
|
|
90
|
-
validatePassword: (pass) => _validatePassword(pass),
|
|
91
|
-
}));
|
|
92
|
-
|
|
93
|
-
function _onChange(e: ChangeEvent<HTMLInputElement>) {
|
|
94
|
-
const password = e.target.value;
|
|
95
|
-
switch (props.mode) {
|
|
96
|
-
case "comparision":
|
|
97
|
-
case "creation":
|
|
98
|
-
props.onChange(password, _validatePassword(password));
|
|
99
|
-
break;
|
|
100
|
-
case "input":
|
|
101
|
-
props.onChange(password);
|
|
102
|
-
break;
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
return (
|
|
107
|
-
<div
|
|
108
|
-
className={`${Styles.inputContainer} ${Styles[props.mode]} ${
|
|
109
|
-
Styles.icon
|
|
110
|
-
}`}
|
|
111
|
-
>
|
|
112
|
-
<Input
|
|
113
|
-
value={props.value}
|
|
114
|
-
onChange={_onChange}
|
|
115
|
-
type={!isPasswordVisibile ? "password" : ""}
|
|
116
|
-
icon={{
|
|
117
|
-
src: isPasswordVisibile ? passwordHidden : passwordVisible,
|
|
118
|
-
onMouseLeave: () => setIPV(false),
|
|
119
|
-
onMouseDown: () => setIPV(true),
|
|
120
|
-
onMouseUp: () => setIPV(false),
|
|
121
|
-
onTouchMove: () => setIPV(false),
|
|
122
|
-
onTouchStart: () => setIPV(true),
|
|
123
|
-
onTouchEnd: () => setIPV(false),
|
|
124
|
-
}}
|
|
125
|
-
error={
|
|
126
|
-
props.mode === "comparision" && !_validatePassword(props.value)
|
|
127
|
-
? props.messages.passwordsAreDifferent
|
|
128
|
-
: props.error
|
|
129
|
-
}
|
|
130
|
-
disabled={props.disabled}
|
|
131
|
-
placeholder={props.placeholder}
|
|
132
|
-
/>
|
|
133
|
-
{props.mode === "creation" && (
|
|
134
|
-
<div className={Styles.rules} data-testid="password-rules">
|
|
135
|
-
<Text type="caption">{props.messages.rulesTitle}</Text>
|
|
136
|
-
{RULES.map((R) => (
|
|
137
|
-
<Text
|
|
138
|
-
key={R.code}
|
|
139
|
-
type={R.validate(props.value) ? "caption" : "error"}
|
|
140
|
-
>
|
|
141
|
-
- {props.messages.invalidRules[R.code]}
|
|
142
|
-
</Text>
|
|
143
|
-
))}
|
|
144
|
-
</div>
|
|
145
|
-
)}
|
|
146
|
-
</div>
|
|
147
|
-
);
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
/**
|
|
151
|
-
* A Input based wrapper to handle inputing of password
|
|
152
|
-
**/
|
|
153
|
-
const PasswordInput = forwardRef(_PasswordInput);
|
|
154
|
-
export default PasswordInput;
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
import React, {
|
|
2
|
-
ComponentProps,
|
|
3
|
-
PropsWithChildren,
|
|
4
|
-
useEffect,
|
|
5
|
-
useRef,
|
|
6
|
-
} from "react";
|
|
7
|
-
import Text from "../Text/Text";
|
|
8
|
-
import Styles from "./PingPongText.module.scss";
|
|
9
|
-
import useMouseHover from "../../hooks/ui/useMouseHover";
|
|
10
|
-
|
|
11
|
-
const HOW_MUCH_PIXELS_TO_SCROLL_PER_SECOND = 50;
|
|
12
|
-
const RIGHT_TEXT_MULTIPLIER = 5;
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* A component that keeps an overflow piece of text visible by continously scrolling it back and forward
|
|
16
|
-
**/
|
|
17
|
-
export default function PingPongText({
|
|
18
|
-
...props
|
|
19
|
-
}: ComponentProps<typeof Text>) {
|
|
20
|
-
const textRef = useRef<HTMLParagraphElement>(null);
|
|
21
|
-
const { uiEvents, hovering } = useMouseHover();
|
|
22
|
-
|
|
23
|
-
useEffect(() => {
|
|
24
|
-
if (!hovering) {
|
|
25
|
-
let scrollingInterval: NodeJS.Timeout;
|
|
26
|
-
let scrollStartTimeout: NodeJS.Timeout;
|
|
27
|
-
scrollStartTimeout = setTimeout(() => {
|
|
28
|
-
const textEl = textRef.current;
|
|
29
|
-
if (!textEl) return;
|
|
30
|
-
const overflowWidth = textEl.scrollWidth;
|
|
31
|
-
const viewWidth = textEl.clientWidth;
|
|
32
|
-
const secondsPerFrame = 1000 / 60;
|
|
33
|
-
const howMuchToMove =
|
|
34
|
-
(secondsPerFrame * HOW_MUCH_PIXELS_TO_SCROLL_PER_SECOND) / 1000;
|
|
35
|
-
|
|
36
|
-
if (overflowWidth > viewWidth) {
|
|
37
|
-
scrollingInterval = scrollText();
|
|
38
|
-
function scrollText(direction: "l" | "r" = "r") {
|
|
39
|
-
return setInterval(() => {
|
|
40
|
-
const reachedEnd =
|
|
41
|
-
direction === "r"
|
|
42
|
-
? textEl!.scrollLeft >= overflowWidth - viewWidth
|
|
43
|
-
: textEl!.scrollLeft === 0;
|
|
44
|
-
if (reachedEnd) {
|
|
45
|
-
clearInterval(scrollingInterval);
|
|
46
|
-
scrollStartTimeout = setTimeout(
|
|
47
|
-
() => {
|
|
48
|
-
scrollingInterval = scrollText(
|
|
49
|
-
direction === "r" ? "l" : "r"
|
|
50
|
-
);
|
|
51
|
-
},
|
|
52
|
-
direction === "r" ? 2000 : 1000
|
|
53
|
-
);
|
|
54
|
-
} else {
|
|
55
|
-
if (direction === "r")
|
|
56
|
-
textEl!.scrollTo(textEl!.scrollLeft + howMuchToMove, 0);
|
|
57
|
-
else {
|
|
58
|
-
textEl!.scrollTo(
|
|
59
|
-
textEl!.scrollLeft - howMuchToMove * RIGHT_TEXT_MULTIPLIER,
|
|
60
|
-
0
|
|
61
|
-
);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
}, secondsPerFrame);
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
}, 1000);
|
|
68
|
-
return () => {
|
|
69
|
-
clearTimeout(scrollStartTimeout);
|
|
70
|
-
clearInterval(scrollingInterval);
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
}, [hovering]);
|
|
74
|
-
|
|
75
|
-
return (
|
|
76
|
-
<Text
|
|
77
|
-
ref={textRef}
|
|
78
|
-
{...(uiEvents as any)}
|
|
79
|
-
{...props}
|
|
80
|
-
className={`${Styles.pingPong} ${props.className || ""}`}
|
|
81
|
-
/>
|
|
82
|
-
);
|
|
83
|
-
}
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
@import "../../assets/styles/index.scss";
|
|
2
|
-
|
|
3
|
-
$animationDurationMs: 2000;
|
|
4
|
-
|
|
5
|
-
@value animationDuration #{$animationDurationMs};
|
|
6
|
-
|
|
7
|
-
$animationDuration: #{$animationDurationMs}ms;
|
|
8
|
-
|
|
9
|
-
.guide {
|
|
10
|
-
width: 100%;
|
|
11
|
-
position: absolute;
|
|
12
|
-
animation-duration: $animationDuration;
|
|
13
|
-
display: flex;
|
|
14
|
-
flex-direction: column;
|
|
15
|
-
justify-content: flex-end;
|
|
16
|
-
animation-fill-mode: forwards;
|
|
17
|
-
animation-timing-function: linear;
|
|
18
|
-
min-height: 10px;
|
|
19
|
-
top: 0;
|
|
20
|
-
&::after {
|
|
21
|
-
content: " ";
|
|
22
|
-
width: 100%;
|
|
23
|
-
height: 10px;
|
|
24
|
-
background: $pixelatedGuideBackground;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.grid {
|
|
29
|
-
position: absolute;
|
|
30
|
-
top: 0px;
|
|
31
|
-
right: 0px;
|
|
32
|
-
left: 0px;
|
|
33
|
-
bottom: 0px;
|
|
34
|
-
overflow: hidden;
|
|
35
|
-
> * {
|
|
36
|
-
display: flex;
|
|
37
|
-
opacity: 0;
|
|
38
|
-
&.guide {
|
|
39
|
-
opacity: 1;
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
&.inverse {
|
|
43
|
-
transform: rotateX(180deg);
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
.gridItem {
|
|
48
|
-
background-color: var(--pixel-color);
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
.gridAnimate {
|
|
52
|
-
animation-duration: #{$animationDurationMs}ms;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
.iterate {
|
|
56
|
-
.guide {
|
|
57
|
-
animation-name: upAndDown;
|
|
58
|
-
}
|
|
59
|
-
.gridAnimate {
|
|
60
|
-
animation-name: onAndOff;
|
|
61
|
-
will-change: opacity;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
@keyframes onAndOff {
|
|
66
|
-
0% {
|
|
67
|
-
opacity: 0;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
10% {
|
|
71
|
-
opacity: 1;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
100% {
|
|
75
|
-
opacity: 0;
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
@keyframes upAndDown {
|
|
80
|
-
0% {
|
|
81
|
-
height: 0%;
|
|
82
|
-
}
|
|
83
|
-
100% {
|
|
84
|
-
height: 100%;
|
|
85
|
-
}
|
|
86
|
-
}
|