Move WindowMode next to the layout types to prevent cyclic import

This commit is contained in:
Johannes Marbach
2026-09-28 17:26:11 +02:00
parent addc1b10a0
commit 29742006df
3 changed files with 9 additions and 8 deletions
+1 -7
View File
@@ -102,6 +102,7 @@ import {
type SpotlightExpandedLayoutMedia,
type SpotlightLandscapeLayoutMedia,
type SpotlightPortraitLayoutMedia,
type WindowMode,
} from "../layout-types.ts";
import { ElementCallError, UnknownCallError } from "../../utils/errors.ts";
import { type Epoch, type ObservableScope } from "../ObservableScope.ts";
@@ -271,13 +272,6 @@ const smallMobileCallThreshold = 3;
// with the interface
const showFooterMs = 4000;
/**
* The general shape of the space the call is drawn in. Called a window because
* that is what it is in the standalone app; for a component it is the container
* the host gave us, which may be a small corner of a large window.
*/
export type WindowMode = "normal" | "narrow" | "flat" | "pip";
interface LayoutScanState {
layout: Layout | null;
overflowing: boolean;
+1 -1
View File
@@ -14,7 +14,7 @@ import {
switchAll,
} from "rxjs";
import { type WindowMode } from "./CallViewModel/CallViewModel.ts";
import { type WindowMode } from "./layout-types.ts";
import { constant, type Behavior } from "./Behavior.ts";
import { type ObservableScope } from "./ObservableScope.ts";
+7
View File
@@ -18,6 +18,13 @@ import {
import { type Behavior } from "./Behavior.ts";
import { shallowEquals as arrayShallowEquals } from "../utils/array.ts";
/**
* The general shape of the space the call is drawn in. Called a window because
* that is what it is in the standalone app; for a component it is the container
* the host gave us, which may be a small corner of a large window.
*/
export type WindowMode = "normal" | "narrow" | "flat" | "pip";
export interface GridLayoutMedia {
type: "grid";
edgeToEdge: false;