Use static domain for assets

From #6233.
then you can just ``return strpos($path, 'styles/') !== FALSE;``