Convert Figma logo to code with AI

h5bp logoEffeckt.css

This repo is archived. Thanks!

10,877
1,394
10,877
0

Top Related Projects

🍿 A cross-browser library of CSS animations. As easy to use as an easy thing.

8,433

CSS3 Animations with special effects

29,203

A collection of CSS3 powered hover effects to be applied to links, buttons, logos, SVG, featured images and so on. Easily apply to your own elements, modify or just use for inspiration. Available in CSS, Sass, and LESS.

Tasty CSS-animated Hamburgers

A simple library to take care of complicated animations.

Quick Overview

Effeckt.css is a CSS library that provides performant off-canvas navigation effects, modals, page transitions, and other UI animations. It aims to deliver smooth, hardware-accelerated CSS animations and transitions that work across various devices and browsers.

Pros

  • Focuses on performance and smooth animations
  • Provides a wide range of UI effects and transitions
  • Compatible with multiple browsers and devices
  • Lightweight and easy to integrate into existing projects

Cons

  • No longer actively maintained (last commit in 2017)
  • Some effects may not work perfectly on older browsers
  • Limited documentation and examples
  • Requires JavaScript for some effects, which may not be ideal for all projects

Code Examples

  1. Adding a modal effect:
<div class="effeckt-modal-wrap" data-effeckt-type="slide-up-big">
  <div class="effeckt-modal">
    <h3>Modal Dialog</h3>
    <p>This is a modal dialog with a slide-up-big effect.</p>
    <button class="effeckt-modal-close">Close</button>
  </div>
</div>
  1. Implementing a page transition:
<div class="effeckt-page-transition" data-effeckt-type="slide-from-right">
  <div class="effeckt-page-transition-content">
    <h2>New Page Content</h2>
    <p>This content will slide in from the right.</p>
  </div>
</div>
  1. Creating an off-canvas navigation:
<nav class="effeckt-off-screen-nav" data-effeckt-type="push">
  <ul>
    <li><a href="#">Home</a></li>
    <li><a href="#">About</a></li>
    <li><a href="#">Contact</a></li>
  </ul>
</nav>

Getting Started

  1. Include the Effeckt.css file in your HTML:
<link rel="stylesheet" href="path/to/effeckt.css">
  1. Include the Effeckt.js file before the closing </body> tag:
<script src="path/to/effeckt.js"></script>
  1. Add the necessary HTML markup for the desired effect (see code examples above).

  2. Initialize the effects in your JavaScript:

document.addEventListener('DOMContentLoaded', function() {
  Effeckt.init();
});

Competitor Comparisons

🍿 A cross-browser library of CSS animations. As easy to use as an easy thing.

Pros of Animate.css

  • Larger community and more frequent updates
  • Easier to use with pre-defined classes for animations
  • More extensive collection of animations out-of-the-box

Cons of Animate.css

  • Less focus on performance optimization
  • Limited customization options without modifying source code
  • Larger file size due to comprehensive animation set

Code Comparison

Animate.css usage:

<div class="animate__animated animate__bounce">
  An animated element
</div>

Effeckt.css usage:

<div class="effeckt-list-item" data-effeckt-type="expand-down">
  An animated element
</div>

Key Differences

  • Animate.css uses simple class-based approach, while Effeckt.css relies on data attributes for animation types
  • Effeckt.css focuses on UI-specific animations, whereas Animate.css provides general-purpose animations
  • Animate.css has better browser support and documentation
  • Effeckt.css emphasizes performance and minimal CSS usage

Conclusion

Animate.css is better suited for quick implementation of common animations, while Effeckt.css is ideal for developers prioritizing performance and customization in UI animations. The choice between the two depends on project requirements, performance needs, and desired level of control over animations.

8,433

CSS3 Animations with special effects

Pros of Magic

  • Simpler implementation with pure CSS animations
  • Larger variety of pre-built animations (over 60)
  • Easier to use with minimal setup required

Cons of Magic

  • Less customizable than Effeckt.css
  • May have larger file size due to more pre-built animations
  • Lacks some advanced features like scroll-based animations

Code Comparison

Magic:

.magictime {
  -webkit-animation-duration: 1s;
  animation-duration: 1s;
}

.puffIn {
  -webkit-animation-name: puffIn;
  animation-name: puffIn;
}

Effeckt.css:

.effeckt-list-item {
  position: relative;
  transition: 0.5s;
}

.effeckt-list-item.hide-me {
  opacity: 0;
  transform: translateX(100%);
}

Magic focuses on simple, pre-defined animations that can be easily applied using classes. Effeckt.css provides more flexibility for custom animations and transitions, often utilizing JavaScript for enhanced control.

Both libraries offer valuable solutions for adding animations to web projects, with Magic being more suitable for quick implementation of common effects, while Effeckt.css caters to developers seeking greater customization and performance optimization.

29,203

A collection of CSS3 powered hover effects to be applied to links, buttons, logos, SVG, featured images and so on. Easily apply to your own elements, modify or just use for inspiration. Available in CSS, Sass, and LESS.

Pros of Hover

  • More extensive collection of hover effects (100+)
  • Easier to implement with simple CSS classes
  • Actively maintained with regular updates

Cons of Hover

  • Focused solely on hover effects, less versatile
  • Larger file size due to the number of effects
  • May require more manual customization for specific needs

Code Comparison

Hover:

.hvr-grow {
  display: inline-block;
  vertical-align: middle;
  transform: translateZ(0);
  box-shadow: 0 0 1px rgba(0, 0, 0, 0);
  backface-visibility: hidden;
  -moz-osx-font-smoothing: grayscale;
  transition-duration: 0.3s;
  transition-property: transform;
}

Effeckt.css:

.effeckt-caption {
  position: relative;
  overflow: hidden;
}
.effeckt-caption img {
  transition: 0.5s;
}
.effeckt-caption figcaption {
  position: absolute;
}

Hover provides a more specific and ready-to-use approach for hover effects, while Effeckt.css offers a broader range of CSS transitions and animations. Hover is better suited for quick implementation of hover effects, whereas Effeckt.css provides more flexibility for various UI interactions. The code comparison shows Hover's focus on specific effects versus Effeckt.css's more general-purpose approach to animations.

Tasty CSS-animated Hamburgers

Pros of hamburgers

  • Focused specifically on hamburger menu animations, providing a wide variety of styles
  • Lightweight and modular, allowing developers to use only the animations they need
  • Includes SCSS source files for easy customization

Cons of hamburgers

  • Limited to hamburger menu animations, while Effeckt.css covers a broader range of UI effects
  • Less actively maintained, with fewer recent updates compared to Effeckt.css
  • Lacks the community support and contributions seen in the Effeckt.css project

Code Comparison

hamburgers:

.hamburger {
  padding: 15px 15px;
  display: inline-block;
  cursor: pointer;
  transition-property: opacity, filter;
  transition-duration: 0.15s;
  transition-timing-function: linear;
  // ...
}

Effeckt.css:

.effeckt-list-item {
  position: relative;
  transition: 0.3s;
}
.effeckt-list-item.hide {
  opacity: 0;
}

The code snippets demonstrate the different focus areas of each project. hamburgers provides specific styles for hamburger menu buttons, while Effeckt.css offers more general-purpose animation classes for various UI elements.

A simple library to take care of complicated animations.

Pros of Choreographer-js

  • Lightweight and focused on scroll-based animations
  • Provides a simple API for creating complex scroll-triggered animations
  • Allows for precise control over animation timing and easing

Cons of Choreographer-js

  • Limited to scroll-based animations, less versatile than Effeckt.css
  • Requires JavaScript knowledge to implement, whereas Effeckt.css is primarily CSS-based
  • Smaller community and fewer examples compared to Effeckt.css

Code Comparison

Choreographer-js:

var choreographer = new Choreographer({
  animations: [
    {
      range: [-1, 1000],
      selector: '#myElement',
      type: 'scale',
      style: 'opacity',
      from: 0,
      to: 1
    }
  ]
});

Effeckt.css:

<div class="effeckt-list-wrap" data-effeckt-type="expand-in">
  <ul class="effeckt-list">
    <li>List Item</li>
    <li>List Item</li>
  </ul>
</div>

The code comparison shows that Choreographer-js requires JavaScript to set up animations, while Effeckt.css relies on HTML classes and data attributes for its effects. Effeckt.css offers a wider range of pre-built animations, while Choreographer-js provides more granular control over scroll-based animations.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

This repo is archived

Effeckt.css

A Performant Transitions and Animations Library : http://h5bp.github.io/Effeckt.css

Ever notice how small flourishes and subtle transitions dramatically increases the value of the experience you enjoy with an app or site?

Designing and developing UIs for the mobile web is tricky, but it's extremely difficult to do that while delivering something that performs at 60fps. The best opportunities to getting jank-free transitions on phones/tablets are CSS transition and keyframe animation based, especially tapping into hardware-accelerated transforms and opacity changes.

@daneden did really nice work with Animate.css but I think the web would benefit if we could take that work to the next level. There's already been fantastic experiments and demos exploring CSS-based transitions, but it's distributed all over.

Originally started at h5bp/lazyweb-requests#122

Effeckt Trailer

image

Examples To Add

Because there are so many, I expect we could group things by role:

  • button/touch effects
  • state transition
  • modal/notification transition
  • attention attractors

Goals

  1. Provide a minimal UI. Only use style hooks for transitions and animations.
  2. Designer-curated set of classy and reasonable effects. (no easeInBounce)
  3. Establish browser support guidelines (e.g. Android 2.3 would gracefully degrade)
  4. CSS performance regression testing (a la bench.topcoat.io)
  5. Deliver jank-free 60fps performance on target browsers/devices
  6. If a particular effect cannot deliver target performance (hey blur() css filter), it cannot be included.
  7. Guidelines on what to avoid when styling these affected elements (avoid expensive CSS)
  8. Deliver a builder so users can pull only the CSS they need.
  9. There is no hover on the mobile web, so any hover-based effects would be excluded or have a tap-based equivalent.

Action

  • If you know other transition/animation based demos/experiments that make sense to include here, file a ticket.
  • If you're interested in helping to define the API, let's hear it! File a ticket.
  • A web-based builder is a must. A command-line builder isn't important for this.

Getting Started

Code Style Guide

General Inquiries & Support

Bug Reports & Feature Requests

NPM DownloadsLast 30 Days