I created a custom keyboard layout with the app Ukelele, based on a built-in layout and thus using the original icon.
However, the icon is not loaded as a template image in the Menu Bar. The result is that when a darker background image is used (or a dynamic background turns darker), the black part of the icon does not switch to white and all I see is a black square with the letters of the keyboard layout not readable:
This was fine until 12.3 when flags were used as icons instead.
Is this a bug and is there a way to workaround this?