mirror of
https://github.com/toeverything/AFFiNE.git
synced 2024-11-26 15:53:53 +03:00
fix: lottie import logic (#1526)
This commit is contained in:
parent
9043081b8d
commit
1239957446
@ -1,8 +1,6 @@
|
||||
import React, { cloneElement, HTMLAttributes, useState } from 'react';
|
||||
import Lottie from 'react-lottie';
|
||||
|
||||
import * as edgelessHoverAnimationData from './animation-data/edgeless-hover.json';
|
||||
import * as pageHoverAnimationData from './animation-data/page-hover.json';
|
||||
import { StyledSwitchItem } from './style';
|
||||
|
||||
type HoverAnimateControllerProps = {
|
||||
@ -49,7 +47,7 @@ export const PageSwitchItem = (
|
||||
options={{
|
||||
loop: false,
|
||||
autoplay: false,
|
||||
animationData: pageHoverAnimationData,
|
||||
animationData: require('./animation-data/page-hover.json'),
|
||||
rendererSettings: {
|
||||
preserveAspectRatio: 'xMidYMid slice',
|
||||
},
|
||||
@ -68,7 +66,7 @@ export const EdgelessSwitchItem = (
|
||||
options={{
|
||||
loop: false,
|
||||
autoplay: false,
|
||||
animationData: edgelessHoverAnimationData,
|
||||
animationData: require('./animation-data/edgeless-hover.json'),
|
||||
rendererSettings: {
|
||||
preserveAspectRatio: 'xMidYMid slice',
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user