The USD and oil/ gold work in different directions
If the dollar drops in value, the price of goods denominated in dollars increases.
e.g. when $1 gave you 2 units of gold, it now only gives 1.5 units of gold
This is because gold or oil is a store of value. This doesn’t mean that the dollar is any less valuable than the gold, but merely that the unit of account of gold is more valuable ie. you used to give me more gold for my dollar, but now because your gold is more valuable you give me less gold for the same dollar.
Stocks in energy companies e.g. drilling, pipeline and retail distribution of energy stocks rise as the dollar weakens because their exports become more expensive and generate higher revenues.
Conversely normal US stocks in other sectors can weaken when the dollar weakens because when oil is on the rise, it signals that inflation is starting to become apparent. If the price of oil has been steadily increasing, it could cause investors to be fearful that inflating energy prices will slow company profits.
Dollar devaluation is not all that bad however because although imports become more expensive after a dollar devaluation, foreign companies can acquire American goods at lower prices. This helps to drive up exports. As exports increase, profits rise and stocks in U.S. companies rise in value.
Investors attempting to profit from rising stock prices may shift their cash from bonds to stocks. The increased competition for stocks drives prices up even further.