Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Add ease helpers to the Twig extension #195

Merged
merged 2 commits into from
Apr 4, 2024

Conversation

titouanmathis
Copy link
Contributor

πŸ”— Linked issue

No issue.

❓ Type of change

  • πŸ“– Documentation (updates to the documentation, readme or JSdoc annotations)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

Add global variables to the Twig extension, with an ui.ease object containing cubic-bezier definitions for common easing.

<div data-component="ScrollAnimation"
  data-option-easing="{{ ui.ease.in_out_expo }}">
  <div data-ref="target">...</div>
</div>

The following easing definitions are available:

  • ui.ease.linear
  • ui.ease.in_back
  • ui.ease.in_circ
  • ui.ease.in_cubic
  • ui.ease.in_expo
  • ui.ease.in_quad
  • ui.ease.in_quart
  • ui.ease.in_quint
  • ui.ease.in_sine
  • ui.ease.out_back
  • ui.ease.out_circ
  • ui.ease.out_cubic
  • ui.ease.out_expo
  • ui.ease.out_quad
  • ui.ease.out_quart
  • ui.ease.out_quint
  • ui.ease.out_sine
  • ui.ease.in_out_back
  • ui.ease.in_out_circ
  • ui.ease.in_out_cubic
  • ui.ease.in_out_expo
  • ui.ease.in_out_quad
  • ui.ease.in_out_quart
  • ui.ease.in_out_quint
  • ui.ease.in_out_sine

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have added tests (if possible).
  • I have updated the documentation accordingly.
  • I have updated the changelog.

Copy link

codecov bot commented Apr 4, 2024

Codecov Report

All modified and coverable lines are covered by tests βœ…

Project coverage is 28.33%. Comparing base (7e6c2f0) to head (e94a64c).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop     #195   +/-   ##
========================================
  Coverage    28.33%   28.33%           
========================================
  Files           49       49           
  Lines         1246     1246           
  Branches       239      239           
========================================
  Hits           353      353           
+ Misses         893      826   -67     
- Partials         0       67   +67     
Flag Coverage Ξ”
unittests 28.33% <ΓΈ> (ΓΈ)

Flags with carried forward coverage won't be shown. Click here to find out more.

β˜” View full report in Codecov by Sentry.
πŸ“’ Have feedback on the report? Share it here.

Copy link

github-actions bot commented Apr 4, 2024

Export Size

Unchanged

@studiometa/ui

Name Size Diff
AbstractPrefetch 411 B -
AbstractScrollAnimation 461 B -
AbstractSliderChild 2.46 kB -
Accordion 1.06 kB -
AccordionItem 1.02 kB -
Action 508 B -
ALL 11.18 kB -
AnchorScrollTo 243 B -
animationScrollWithEase 272 B -
ATOMS 3.77 kB -
CircularMarquee 339 B -
Cursor 665 B -
Draggable 327 B -
Figure 694 B -
FigureTwicpics 1.15 kB -
Frame 1.62 kB -
FrameAnchor 201 B -
FrameForm 198 B -
FrameTarget 777 B -
LargeText 492 B -
LazyInclude 418 B -
loadImage 694 B -
Menu 1.38 kB -
MenuBtn 230 B -
MenuList 943 B -
Modal 908 B -
ModalWithTransition 1.02 kB -
MOLECULES 6.94 kB -
ORGANISMS 1.68 kB -
Panel 1.26 kB -
PrefetchWhenOver 468 B -
PrefetchWhenVisible 480 B -
PRIMITIVES 632 B -
ScrollAnimation 513 B -
ScrollAnimationChild 650 B -
ScrollAnimationChildWithEase 851 B -
ScrollAnimationParent 712 B -
ScrollAnimationWithEase 711 B -
ScrollReveal 622 B -
Sentinel 217 B -
Slider 2.26 kB -
SliderBtn 2.62 kB -
SliderCount 2.49 kB -
SliderDots 2.7 kB -
SliderDrag 353 B -
SliderItem 733 B -
SliderProgress 2.54 kB -
Sticky 859 B -
TableOfContent 742 B -
TableOfContentAnchor 550 B -
Tabs 625 B -
Transition 387 B -

@titouanmathis titouanmathis merged commit fa7f698 into develop Apr 4, 2024
8 checks passed
@titouanmathis titouanmathis deleted the feature/twig-globals branch April 4, 2024 08:50
@titouanmathis titouanmathis mentioned this pull request Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant