Optimize code

This commit is contained in:
2024-01-14 00:51:03 +08:00
parent 97c23334f7
commit b0be3bc4a7
63 changed files with 217 additions and 275 deletions

View File

@@ -1,4 +1,3 @@
import React from 'react'
import _ from 'lodash'
import '@/assets/css/components/common/indicator.scss'
@@ -8,7 +7,7 @@ interface IndicatorProps {
onSwitch?: (index: number) => void
}
const Indicator: React.FC<IndicatorProps> = ({ total, current, onSwitch }) => {
const Indicator = ({ total, current, onSwitch }: IndicatorProps) => {
const handleClick = (index: number) => {
return () => {
onSwitch?.(index)