robot
robot copied to clipboard
invalid xref check is too strict
The invalid xref check uses this regex: "^[a-z|A-Z|_|\\-|0-9]*:(?!$)\\S*$"
It should allow . in the prefix part: https://www.w3.org/TR/1999/REC-xml-names-19990114/#NT-NCName
tbh the checks is also missing some cases.
^[a-z|A-Z|_|\\-|0-9]*:(?!$)\\S*$(OLD)^[a-z|A-Z][a-z|A-Z|_|\\-|0-9|\\.]*[a-z|A-Z|0-9]:(?!$)\\S*$(Proposed new)
So basically:
- first character of prefix must be an upper or lower case alphabetical character.
- last character of prefix must be an upper or lower case alphabetical character or number.
- prefix may contain period anywhere in between first and last character
What do you think @balhoff?
Seems good to me.