From 31aaf461758ff9747cdc6eeed472f18c9e52fed0 Mon Sep 17 00:00:00 2001 From: Dylan Hunn Date: Mon, 30 Oct 2023 17:37:26 -0700 Subject: [PATCH] refactor(compiler): Move an enum to `enums.ts` for Template Pipeline This enum belongs in the main enums file. --- .../compiler/src/template/pipeline/ir/src/enums.ts | 10 ++++++++++ .../src/template/pipeline/ir/src/expression.ts | 7 ------- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/packages/compiler/src/template/pipeline/ir/src/enums.ts b/packages/compiler/src/template/pipeline/ir/src/enums.ts index 776e9c25d598b8..9d2e9ecd4221d2 100644 --- a/packages/compiler/src/template/pipeline/ir/src/enums.ts +++ b/packages/compiler/src/template/pipeline/ir/src/enums.ts @@ -528,3 +528,13 @@ export enum DeferTriggerKind { Interaction, Viewport, } + +/** + * Repeaters implicitly define these derived variables, and child nodes may read them. + */ +export enum DerivedRepeaterVarIdentity { + First, + Last, + Even, + Odd, +} diff --git a/packages/compiler/src/template/pipeline/ir/src/expression.ts b/packages/compiler/src/template/pipeline/ir/src/expression.ts index 6b750b87c99365..bfbe9c102848e7 100644 --- a/packages/compiler/src/template/pipeline/ir/src/expression.ts +++ b/packages/compiler/src/template/pipeline/ir/src/expression.ts @@ -820,13 +820,6 @@ export class ConditionalCaseExpr extends ExpressionBase { } } -export enum DerivedRepeaterVarIdentity { - First, - Last, - Even, - Odd, -} - export class DerivedRepeaterVarExpr extends ExpressionBase { override readonly kind = ExpressionKind.DerivedRepeaterVar;