code-dot-org/code-dot-org — pull request #95 by Bjvanminnen (2014-10-02 21:49:57+00:00)
Title: fix row with single value input

This fixes the bug revealed by the unit tests. The issue was that previously when we had a block where we'd called setInputsInLine(true), a row with a single value input in it would be marked as type INLINE. This would result in us thickening it vertically to make space for the value input. My change caused us to treat that row as type INPUT_VALUE and not thicken. Fix in block_svg is simple.

There were a couple other little changes in the paths from before I started touching block_svg until now. Some of these were provably inconsequential (i.e. H 20 H 40, which means move to horizontal position 20 then move to horizontal position 40, is exactly the same as H 30 H 40). Some of them were less provably inconsequential, but I looked at them side by side very carefully and couldn't spot differences. In both cases, I've updated the validator to have the paths from the current state of affairs (meaning it will catch future changes).

I also added a validator for ar_sa, an RTL language. There do appear to be some differences in paths, though looking at the blocks side by side they seem identical. I'm going to look into this a little more. (Right now you can only test the ar_sa by manually copying the contents of blockValidation.js into your browser console and calling validate with the ar_sa key).