chore: rename functions to make more sense
This commit is contained in:
@@ -87,7 +87,7 @@ export default function DigitalTeamMemberCardContent({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function renderShimmer(): CSSProperties {
|
function getShimmerStyle(): CSSProperties {
|
||||||
const { x, y } = coords
|
const { x, y } = coords
|
||||||
const oppositeX = 100 - (x / rect.width) * 100
|
const oppositeX = 100 - (x / rect.width) * 100
|
||||||
const oppositeY = 100 - (y / rect.height) * 100
|
const oppositeY = 100 - (y / rect.height) * 100
|
||||||
@@ -97,7 +97,7 @@ export default function DigitalTeamMemberCardContent({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function renderSkew(): CSSProperties {
|
function getSkewStyle(): CSSProperties {
|
||||||
const { x, y } = coords
|
const { x, y } = coords
|
||||||
const centerX = rect.width / 2
|
const centerX = rect.width / 2
|
||||||
const centerY = rect.height / 2
|
const centerY = rect.height / 2
|
||||||
@@ -130,8 +130,8 @@ export default function DigitalTeamMemberCardContent({
|
|||||||
onTouchMove={onInteractionMove}
|
onTouchMove={onInteractionMove}
|
||||||
onTouchEnd={handleInteractionEnd}
|
onTouchEnd={handleInteractionEnd}
|
||||||
>
|
>
|
||||||
<div className={styles.card} ref={cardRef} style={renderSkew()}>
|
<div className={styles.card} ref={cardRef} style={getSkewStyle()}>
|
||||||
<div className={styles.shimmer} style={renderShimmer()} />
|
<div className={styles.shimmer} style={getShimmerStyle()} />
|
||||||
<div className={styles.content}>
|
<div className={styles.content}>
|
||||||
<Typography variant="Tag/sm">
|
<Typography variant="Tag/sm">
|
||||||
<div className={styles.top}>
|
<div className={styles.top}>
|
||||||
|
|||||||
Reference in New Issue
Block a user