< Summary

Class:EventCardAnimator
Assembly:ExploreV2
File(s):/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/ExploreV2/Scripts/Sections/PlacesAndEventsSection/SubSections/EventsSubSection/EventCard/EventCardAnimator.cs
Covered lines:6
Uncovered lines:0
Coverable lines:6
Total lines:29
Line coverage:100% (6 of 6)
Covered branches:0
Total branches:0

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
Focus()0%110100%
Idle()0%110100%

File(s)

/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/ExploreV2/Scripts/Sections/PlacesAndEventsSection/SubSections/EventsSubSection/EventCard/EventCardAnimator.cs

#LineLine coverage
 1using DG.Tweening;
 2using UnityEngine;
 3
 4public class EventCardAnimator : MonoBehaviour
 5{
 6    private const float DURATION = 0.167f;
 7    [SerializeField] private CanvasGroup cardShadow;
 8    [SerializeField] private RectTransform infoTransform;
 9
 10    public void Focus()
 11    {
 2912        cardShadow.DOFade(1, DURATION)
 13                  .SetEase(Ease.Linear)
 14                  .SetLink(cardShadow.gameObject, LinkBehaviour.KillOnDestroy);
 2915        infoTransform.DOAnchorPosY(5, DURATION)
 16                     .SetEase(Ease.InOutQuad)
 17                     .SetLink(infoTransform.gameObject, LinkBehaviour.KillOnDestroy);
 2918    }
 19
 20    public void Idle()
 21    {
 36822        cardShadow.DOFade(0, DURATION)
 23                  .SetEase(Ease.Linear)
 24                  .SetLink(cardShadow.gameObject, LinkBehaviour.KillOnDestroy);
 36825        infoTransform.DOAnchorPosY(0, DURATION)
 26                     .SetEase(Ease.InOutQuad)
 27                     .SetLink(infoTransform.gameObject, LinkBehaviour.KillOnDestroy);
 36828    }
 29}

Methods/Properties

Focus()
Idle()