cssText property

String get cssText

Compiled CSS @keyframes text.

Implementation

String get cssText {
  final body = steps
      .map((step) {
        final stepBody = rootStyleToCss(step.style.toMap());
        if (stepBody.isEmpty) return '';
        return '  ${step.selector} { $stepBody; }';
      })
      .where((chunk) => chunk.isNotEmpty)
      .join('\n');
  if (body.isEmpty) return '';
  return '@keyframes $name {\n$body\n}';
}