Hi,
It looks like this is a bug that was fixed in
b3b3b11960962e9c08c709df77b3197d8cf72ee3
(
https://gerrit.wikimedia.org/r/#/c/163636/ /
https://phabricator.wikimedia.org/T73418).
Unfortunately the older branches of VisualEditor are not really
maintained; it is still beta software. But it seems like the patch
cherry-picks cleanly on REL1_24 (although I haven't tested it):
(assuming you're in mediawiki/extensions/VisualEditor repository root)
git checkout REL1_24
git submodule update
cd lib/ve
git cherry-pick b3b3b11960962e9c08c709df77b3197d8cf72ee3
cd ../..
git commit -am "LOCAL HACK: Cherry-pick fix for T73418"
--
Bartosz Dziewoński