-
Notifications
You must be signed in to change notification settings - Fork 362
/
Copy pathkeyframe_block.dart
30 lines (23 loc) · 1.03 KB
/
keyframe_block.dart
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// Copyright 2019 Google Inc. Use of this source code is governed by an
// MIT-style license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
import 'package:source_span/source_span.dart';
import '../../../utils.dart';
import '../../../visitor/interface/modifiable_css.dart';
import '../keyframe_block.dart';
import '../value.dart';
import 'node.dart';
/// A modifiable version of [CssKeyframeBlock] for use in the evaluation step.
final class ModifiableCssKeyframeBlock extends ModifiableCssParentNode
implements CssKeyframeBlock {
final CssValue<List<String>> selector;
final FileSpan span;
ModifiableCssKeyframeBlock(this.selector, this.span);
T accept<T>(ModifiableCssVisitor<T> visitor) =>
visitor.visitCssKeyframeBlock(this);
bool equalsIgnoringChildren(ModifiableCssNode other) =>
other is ModifiableCssKeyframeBlock &&
listEquals(selector.value, other.selector.value);
ModifiableCssKeyframeBlock copyWithoutChildren() =>
ModifiableCssKeyframeBlock(selector, span);
}