Skip to content

v6.11.0 - JSON Animation Manifest Generator Added

Choose a tag to compare

@yesiamrocks yesiamrocks released this 27 Jul 16:52
· 17 commits to master since this release

JSON Animation Manifest Generator Added

This release introduces a robust animation manifest generator script for cssanimation.css.

What’s Included

  • Tool: tools/generate-Json.js
  • Output: dist/cssanimation.json

Features

  • Extracts all .ca__fx-* class names with animation-name
  • Parses full @keyframes blocks (from, to, 0%-100%)
  • Supports:
    • animation, animation-name, duration, easing, fill-mode
    • Inferred to properties for *In animations (e.g. blurIn)
    • Inferred from properties for *Out animations (e.g. fadeOut)
    • Edge properties like clip-path, filter, transform

Smart Handling

  • Auto-fills missing frames when possible (blurIn gets inferred to)
  • Correctly parses animation shorthand using flexible regex logic
  • Optional support for animation-metadata.json to inject:
    • Tags
    • Categories
    • Duration overrides

Output Sample

{
  "blurIn": {
    "class": "ca__fx-blurIn",
    "animation": {
      "name": "blurIn",
      "duration": "1s",
      "timingFunction": "ease-out",
      "fillMode": "both",
      "iterationCount": "1"
    },
    "keyframes": {
      "from": {
        "filter": "blur(20px)",
        "opacity": "0"
      },
      "to": {
        "filter": "none",
        "opacity": "1"
      }
    },
    "tags": [],
    "category": "uncategorized"
  }
}