Commit Graph

52 Commits

Author SHA1 Message Date
Tom Alexander 43d65b4fe3
Disable spellcheck to remove red squiggles. 2024-01-28 19:11:07 -05:00
Tom Alexander ff3618b67d
Add dark mode support for the editor. 2024-01-28 19:09:41 -05:00
Tom Alexander 8c2c48a719
Add dark mode support for the AST tree. 2024-01-28 19:04:26 -05:00
Tom Alexander 43de54039b
Move the shadow to the left.
This is to make indentation depth easier to see.
2024-01-28 18:31:33 -05:00
Tom Alexander 1cc5dd7911
Move flexbox handling up to the explorer component. 2024-01-28 18:21:38 -05:00
Tom Alexander 083b0aa376
Move explorer styles into local styles. 2024-01-28 18:20:22 -05:00
Tom Alexander d158fafd77
Move the highlightable textarea into its own component. 2024-01-28 18:14:57 -05:00
Tom Alexander 33ed9c4f56
Add types to Explorer props. 2024-01-28 17:32:27 -05:00
Tom Alexander a11201363e
Rename Editor to Explorer.
This component was both the editor and the AST view so it doesn't make sense to call it Editor. Instead the highlightable textarea is going to be moved into a new Editor component.
2024-01-28 17:28:43 -05:00
Tom Alexander 3b3ef70d3b
Put a headline in the starting text.
This is because headlines have a lot of properties which will be more interesting to users. Since the org is not rendered, it barely takes up any additional space.
2024-01-28 14:39:25 -05:00
Tom Alexander 6129bdad3e
Remove highlight when deselecting node despite hover status. 2024-01-28 02:04:00 -05:00
Tom Alexander f89e62b9e1
Allow de-selecting of nodes. 2024-01-28 01:11:21 -05:00
Tom Alexander 5d31d50863
Fix cursor for ast node bar. 2024-01-28 01:06:41 -05:00
Tom Alexander c2850fa879
Make sure the text box starts out in sync. 2024-01-28 00:39:01 -05:00
Tom Alexander e881102ade
Rename from organic wasm demo to organic ast explorer. 2024-01-27 22:55:16 -05:00
Tom Alexander f60725b341
Use monospace font for source. 2024-01-27 22:15:31 -05:00
Tom Alexander d73f344dd0
Compact form for plain text nodes. 2024-01-27 22:04:22 -05:00
Tom Alexander 04b79631d7
Get rid of flexbox. 2024-01-27 21:51:06 -05:00
Tom Alexander 8f360fda4b
Show the portion of the original source for the AST node in the AST tree. 2024-01-27 21:46:44 -05:00
Tom Alexander bb15dbcbaf
Add support for optional pairs. 2024-01-27 20:49:43 -05:00
Tom Alexander 49905f1273
Lock the scroll of the div and textarea to keep the highlighting accurate. 2024-01-27 20:16:59 -05:00
Tom Alexander cc48040f11
Only re-parse the ast when value changes. 2024-01-27 19:31:29 -05:00
Tom Alexander 8627181480
Fix creation of shadow div.
If two highlights started at the same index, it would sometimes not render both of them.
2024-01-27 19:22:31 -05:00
Tom Alexander 5feac8e4d7
Fix a missing key. 2024-01-27 18:57:01 -05:00
Tom Alexander 0e02e09018
Add support for highlighting when hovering over a node. 2024-01-27 18:52:18 -05:00
Tom Alexander e89be0feff
Render object trees. 2024-01-27 18:12:51 -05:00
Tom Alexander 3f0ac05513
Moving the rendering of property values out to their own component.
There is going to be a bunch of logic associated with it to detect what type the value is, so I am moving it out to its own component.
2024-01-27 17:19:37 -05:00
Tom Alexander f435e73ec1
Remove noop entries.
The noop entries are not actually implemented in organic so it wouldn't make sense for them to be rendered in the UI.
2024-01-27 17:07:17 -05:00
Tom Alexander c03bf7458f
Fix line breaks in property list keys. 2024-01-27 17:01:09 -05:00
Tom Alexander 1507050128
Switch to using tables for properties. 2024-01-27 16:38:34 -05:00
Tom Alexander b8eacd9c79
Clear highlights when changing the text.
I'm not a big fan of this behavior but we need some form of clearing and this is the simplest right now.
2024-01-27 15:29:37 -05:00
Tom Alexander 1c8f84ab4c
Very basic org properties rendering. 2024-01-27 15:27:23 -05:00
Tom Alexander c397688a4a
Pass uid down from parent.
This fixes an issue where lists of nodes did not have the key attribute.
2024-01-27 15:01:37 -05:00
Tom Alexander aac0ebe619
Move parsing up into the Editor. 2024-01-27 14:56:12 -05:00
Tom Alexander 3fa5ba1546
Update to using createRoot. 2024-01-27 14:38:34 -05:00
Tom Alexander 8be7f3c290
Switch to using unique id for node selection.
This lets us pass the selected node down from the top instead of propagating calls to set/clear the selected boolean in each node.
2024-01-27 14:27:23 -05:00
Tom Alexander 6e791d119a
Setting highlight based on clicks. 2024-01-27 14:27:22 -05:00
Tom Alexander 41d4129cce
Improve the starting text for the editor. 2024-01-27 14:27:22 -05:00
Tom Alexander 87406ee0fd
Render the children. 2024-01-23 23:08:20 -05:00
Tom Alexander 6ede136e61
Show the standard properties. 2024-01-23 22:27:31 -05:00
Tom Alexander d1ce90ac42
Format the code. 2024-01-23 22:06:47 -05:00
Tom Alexander 4847ec07d8
Render if the node has children. 2024-01-23 22:06:22 -05:00
Tom Alexander 6901541fe4
Start rendering the Org Ast. 2024-01-23 21:44:49 -05:00
Tom Alexander c419a41998
Fix text alignment with shadow. 2024-01-22 22:52:00 -05:00
Tom Alexander ba2c646a6a
Remove style from textarea. 2024-01-22 22:39:52 -05:00
Tom Alexander bbf8ab0966
Highlighting text. 2024-01-22 22:20:14 -05:00
Tom Alexander 7390132d02
Add CSS reset sheet. 2024-01-22 20:01:30 -05:00
Tom Alexander f777e4a856
Add an App component. 2024-01-22 19:41:07 -05:00
Tom Alexander 0d0a99c73b
Run format. 2024-01-21 21:13:03 -05:00
Tom Alexander c644845d61
Integrate the editor from the old attempt into the new build. 2024-01-21 19:46:23 -05:00