The -Sort By- filter function only works on custom folders in the FOLDER column of the Media Library (the middle-column). It will always be greyed out when you're viewing a gallery in the WEBSITE MENU column on the far left.
That is because the WEBSITE MENU column(left-column) allows for custom placement and ordering for media (TEXT, IMAGE, VIDEO media) to be set with a drag-and-drop method.
If you're trying to upload numbered/numerical files into a gallery in an order, please upload them in the middle FOLDER column first.
Then your numbered files will appear in-order, numerically, as you may want them to appear on a gallery.
Once they have finished uploading, you can use the -Sort By- filter function to re-order them however you want.
Now you can use (SHIFT + SELECT) or (COMMAND + SELECT) to select a group of the images and drag them to the gallery in the left WEBSITE MENU column to assign them to a gallery and the order will be retained.