d2-mode icon indicating copy to clipboard operation
d2-mode copied to clipboard

New keywords are not recognized

Open the42 opened this issue 2 years ago • 2 comments

d2 on it's way to 1.0 underwent some significant overhauls which are not reflected in the package. Globs come to mind.

the42 avatar Dec 20 '23 09:12 the42

got it. thanks for bringing to my attention. Agreed this needs to be updated. Will see when I can get around to it

andorsk avatar Dec 27 '23 18:12 andorsk

Looking at this, probably the best way to handle this is to compile a list of unsupported keywords. Is there a list of changes that can be easily diffed?

I see globs, https://d2lang.com/tour/globs/. It would be great to draw more explicit differences between current behavior and what should be expected. Syntax highlighting is done here: https://github.com/andorsk/d2-mode/blob/main/d2-mode.el#L92.

Here's a start with glob. I'm sure there are others, probably makes sense to batch them into a single effort

*.mini.height: 300 <- height and * should be both one color face, mini should be another. 300 another. Will need to play around with types, it's been a while since I've looked into this.

Can we please this ticket to document the deltas between the old and newer version of keywords, and then we can create an actual PR to address the changes?

andorsk avatar Jan 07 '24 22:01 andorsk