How can I filter products by vendor on a collection page?

The above should produce a URL with a query string which filters products for a specific vendor in that specific collection. Each URL should look something like this:

https://yourstorename.com/collections/yourselectedcollection/?vendor=VendorName

If not, then there’s something wrong with the output.