Add structure for container and shapes #1

Merged
pleshevskiy merged 12 commits from rewrite-structure into main 2022-12-09 12:36:32 +03:00
2 changed files with 83 additions and 34 deletions
Showing only changes of commit 6032250d6d - Show all commits

View File

@ -21,7 +21,7 @@ foo.bar.biz
)
================================================================================
Use quoted string as a shape key
Use quoted string as keys
================================================================================
'foo'.'baz'
@ -67,39 +67,6 @@ foo: {
)
)
================================================================================
Declare a container with complex keys
================================================================================
Foo biz bar: {
bar biz baz: {
-biz-baz-Baz-: {
Helo world
}
}
}
--------------------------------------------------------------------------------
(source_file
(container
(container_key)
(block
(container
(container_key)
(block
(container
(container_key)
(block
(shape (shape_key))
)
)
)
)
)
)
)
================================================================================
Declare labeled container inside a labeled container using block
================================================================================
@ -159,3 +126,74 @@ foo: {
)
)
================================================================================
Declare a container with complex keys
================================================================================
Foo biz bar: {
bar biz baz: {
-biz-baz-Baz-: {
Helo world
}
}
}
--------------------------------------------------------------------------------
(source_file
(container
(container_key)
(block
(container
(container_key)
(block
(container
(container_key)
(block
(shape (shape_key))
)
)
)
)
)
)
)
================================================================================
Declare a container with complex keys and labels
================================================================================
Foo biz bar: Biz biz Bar {
bar biz baz: baz baz biz {
-biz-baz-Baz-: Biz buz Baz {
Helo world
}
}
}
--------------------------------------------------------------------------------
(source_file
(container
(container_key)
(label)
(block
(container
(container_key)
(label)
(block
(container
(container_key)
(label)
(block
(shape (shape_key))
)
)
)
)
)
)
)

View File

@ -104,3 +104,14 @@ foo: Foo {}
(shape (shape_key) (label) (block))
)
================================================================================
Use quoted string as shape key and label
================================================================================
'foo': "Label"
--------------------------------------------------------------------------------
(source_file
(shape (shape_key (string)) (label (string)))
)