An HTML input field can give your password generator a hint, right? Never looked at it closely but had the impression e.g. Safari's generator could adapt to certain rules and that they were somehow described in the HTML.
I've created a CodeSandbox example of it being used.[2] 1Password does honour it.
[1] https://developer.apple.com/password-rules/ [2] https://codesandbox.io/s/password-rules-demo-029h5