@vnejs/plugins.views.scenario.interface.fastforward 0.1.2 → 0.1.3

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vnejs/plugins.views.scenario.interface.fastforward",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1",
package/view/index.jsx CHANGED
@@ -1,13 +1,9 @@
1
1
  import { useCallback, useEffect, useMemo, useState } from "react";
2
2
  import { createRoot } from "react-dom/client";
3
3
 
4
- import { cn } from "@bem-react/classname";
5
-
6
4
  import { Icon, useIsForceHook, View } from "@vnejs/uis.react";
7
5
 
8
- import "./index.styl";
9
-
10
- const b = cn("InterfaceFastForward");
6
+ import { b } from "./index.styles.js";
11
7
 
12
8
  const InterfaceFastForward = ({ store, onMount, ...props } = {}) => {
13
9
  const [state, setState] = useState({});
@@ -0,0 +1,28 @@
1
+ import { cn, injectStyles, sel } from "@vnejs/uis.utils";
2
+
3
+ export const b = cn("InterfaceFastForward");
4
+
5
+ const CSS = `
6
+ @keyframes fastforward {
7
+ from {
8
+ transform: scale(1.1);
9
+ }
10
+
11
+ 50% {
12
+ transform: scale(0.9);
13
+ }
14
+
15
+ to {
16
+ transform: scale(1.1);
17
+ }
18
+ }
19
+
20
+ ${sel(b({ isAnimated: true }))} {
21
+ animation-duration: 500ms;
22
+ animation-name: fastforward;
23
+ animation-iteration-count: infinite;
24
+ animation-timing-function: ease-in-out;
25
+ }
26
+ `;
27
+
28
+ injectStyles(CSS);
package/view/index.styl DELETED
@@ -1,19 +0,0 @@
1
- @keyframes fastforward
2
- from
3
- transform: scale(1.1)
4
-
5
- 50%
6
- transform: scale(0.9)
7
-
8
- to
9
- transform: scale(1.1)
10
-
11
- .InterfaceFastForward
12
- &_isAnimated
13
- animation-duration: 500ms
14
- animation-name: fastforward
15
- animation-iteration-count: infinite
16
- animation-timing-function: ease-in-out
17
-
18
-
19
-