tree-sitter-d2/test/corpus/attributes.txt

39 lines
1.1 KiB
Plaintext
Raw Normal View History

2022-12-06 00:34:41 +03:00
================================================================================
2022-12-04 23:45:53 +03:00
Root attribute
2022-12-06 00:34:41 +03:00
================================================================================
2022-12-04 18:35:50 +03:00
direction: value
2022-12-06 00:34:41 +03:00
--------------------------------------------------------------------------------
2022-12-04 18:35:50 +03:00
(source_file
2022-12-04 23:45:53 +03:00
(attr_key) (attr_value)
2022-12-04 18:35:50 +03:00
)
2022-12-06 00:34:41 +03:00
================================================================================
2022-12-04 23:45:53 +03:00
Inline shape attribute
2022-12-06 00:34:41 +03:00
================================================================================
2022-12-04 23:45:53 +03:00
foo.shape: oval
2022-12-05 00:26:24 +03:00
foo.bar.baz.shape: oval
2022-12-04 23:45:53 +03:00
2022-12-06 00:34:41 +03:00
--------------------------------------------------------------------------------
2022-12-04 23:45:53 +03:00
(source_file
2022-12-05 00:26:24 +03:00
(shape (identifier) (dot) (attr_key) (attr_value))
(shape (identifier) (dot) (identifier) (dot) (identifier) (dot) (attr_key) (attr_value))
2022-12-04 23:45:53 +03:00
)
2022-12-06 00:34:41 +03:00
================================================================================
2022-12-04 23:45:53 +03:00
Inline style attribute
2022-12-06 00:34:41 +03:00
================================================================================
2022-12-04 23:45:53 +03:00
foo.style.opacity: 5
2022-12-06 00:34:41 +03:00
--------------------------------------------------------------------------------
2022-12-04 23:45:53 +03:00
(source_file
2022-12-05 00:26:24 +03:00
(shape (identifier) (dot) (attr_key) (dot) (attr_key) (attr_value))
2022-12-04 23:45:53 +03:00
)