There is no quick automatic way in Photoshop. The closest you can get is to record one Replace Color edit using the Actions panel, then use File > Automate > Batch to apply that Action to all open documents.
Another approach is to do it in Camera Raw instead, if the files are in a format Camera Raw can open, and if the feature you need is in Camera Raw. I don’t mean Filter > Camera Raw Filter, I mean selecting multiple files to load into a Camera Raw filmstrip. In Camera Raw, select all images, set up a Color Range mask to target a specific color, then apply a Hue adjustment to replace that color. When multiple images are selected in a Camera Raw filmstrip, an edit applies to all selected images immediately, much faster than Photoshop.
If you like to use Lightroom Classic, it works like Camera Raw and has the same advantage if AutoSync is enabled: An edit can affect a large number of selected images at the same time.