online-go / goban

A JavaScript library for exploring and playing the game of Go
Apache License 2.0
47 stars 39 forks source link

Support a scale parameter for the font size for stone markings. #177

Closed GreenAsJade closed 1 month ago

anoek commented 1 month ago

Hmm something with this messed up the top/sub positioning:

image

Should look more like this:

image

GreenAsJade commented 1 month ago

Screenshot 2024-09-17 at 11 00 03 AM (2)

Note: I found another parameter sub_triangle, which doesn't seem to be tested in this board. It's such a teeny tweak in the maths, I'm kinda hoping it just does the right thing if/when needed 😝

If we know the "right context" for this to be tested in (how to actually set it in main.tsx testcase), I'm happy to add it: it's a parameter of the MoveTree interface, and it's also a valid `MARK_TYPE".

GreenAsJade commented 1 month ago

Oh wait, I just saw that for some reason the original "sub" is actually centered in the square. Is that intended?

I imagined a sub would be positioned in a subscript position, so I didn't notice that I'd "broken" that!

GreenAsJade commented 1 month ago

Latest (note that my Mac gives me bold font on stone lettering!)

Screenshot 2024-09-17 at 11 39 08 AM (2)

anoek commented 1 month ago

Awesome, thanks!