See here: https://github.com/fullstackio/cq/pull/24/files#diff-fe2febbc5f58b33b58b6d9d892131548R390
The query let query = '.SubmitButton.onSubmit' seems to be parsed as if the identifiers are split by a space.
In CSS the nospace would mean the element that has both of those classes and in CSS the space means 'child-somewhere'. I'm not sure what the no-space version would mean to cq.
The todo here is to investigate this bug and fix it.