@lottiefiles/relottie-extract-features
Version:
relottie plugin to extract Lottie features
34 lines (30 loc) • 812 B
TypeScript
import { Root, AnyTitle } from '@lottiefiles/last';
import { Plugin } from 'unified';
import { Data } from 'vfile';
import { Options } from './options.js';
/**
* Copyright 2022 Design Barn Inc.
*/
declare type UsedCount = number;
declare type Used = Map<AnyTitle, {
/**
* Total unused count
*/
n: UsedCount;
/**
* Map of parent titles to whether how many nodes is used or not_used in the parent
*/
parents: Map<AnyTitle, {
n: UsedCount;
y: UsedCount;
}>;
/**
* Total used count
*/
y: UsedCount;
}>;
interface ExtractFeaturesFileData extends Data {
'extract-features': Used;
}
declare const extractFeatures: Plugin<[Options?], Root>;
export { type ExtractFeaturesFileData, type Used, type UsedCount, extractFeatures as default };