This commit is contained in:
Alexander Heldt
2025-12-04 20:47:23 +01:00
parent 15cda58760
commit 6a4486c407
3 changed files with 26 additions and 42 deletions

View File

@@ -5,7 +5,7 @@ import gleeunit
import gleeunit/should
import musicplayer/ui/virtual_ansi
import musicplayer/ui/layout.{Layout, Node, Section}
import musicplayer/ui/layout.{Layout, Node, Section, Style}
pub fn main() -> Nil {
gleeunit.main()
@@ -22,8 +22,7 @@ pub fn foo_test() {
Node(
t: layout.Container,
content: "container",
width_percent: 100,
height_percent: 100,
style: Style(width_percent: 100, height_percent: 100),
children: [
Section("Row1"),
Section("Row2"),
@@ -35,8 +34,7 @@ pub fn foo_test() {
Node(
t: layout.Row,
content: "row 1",
width_percent: 100,
height_percent: 50,
style: Style(width_percent: 100, height_percent: 50),
children: [
Section("A"),
Section("B"),
@@ -48,8 +46,7 @@ pub fn foo_test() {
Node(
t: layout.Cell,
content: "cell 1",
width_percent: 50,
height_percent: 100,
style: Style(width_percent: 50, height_percent: 100),
children: [],
),
),
@@ -58,8 +55,7 @@ pub fn foo_test() {
Node(
t: layout.Cell,
content: "cell 2",
width_percent: 50,
height_percent: 100,
style: Style(width_percent: 50, height_percent: 100),
children: [],
),
),
@@ -68,8 +64,7 @@ pub fn foo_test() {
Node(
t: layout.Row,
content: "row 1",
width_percent: 100,
height_percent: 50,
style: Style(width_percent: 100, height_percent: 50),
children: [],
),
),