I'm an international economics nerd who loves
The Economist hardcore so I love this question!
Globalization, INCLUDING increased product influx from abroad, benefits everyone. It increases supply in the market and lowers prices. Buying non-American items sends market signals to American-made products to lower prices. If they can't compete they shut down and and the economy continues to move away from manufacturing/production towards services. This is good thing- moving away from lower-paying jobs towards higher paying jobs- as long as there are appropriate retraining and skills development programs that can help move factory and other production workers into more skilled, higher paying jobs.
Some government schemes to buy American, such as the Fly America Act, which requires government-sponsored programs to always fly on an American carrier, are great politically and terrible economically. American carriers are notoriously more expensive than international airlines, and taxpayers end up footing the bill for millions of dollars a year more in travel because the organization/company/government agency is required to go with an American carrier, regardless of cost. It is de facto a subsidy to American carriers, keeping prices artificially high, and costing Americans even more in prices. Ridiculous.
Sweatshops overseas sound awful, but I used to work in microfinance in Cambodia and getting a job in a factory like that is a step UP from selling potato chips on the side of the road. They are stable jobs with steady income. Don't get me wrong, there are lots of labor laws in third world countries that need to be implemented (and protections for organized labor and unions) but there are a LOT of people out there for whom companies opening a sweatshop in their village would mean the difference between sending their kid to school and having them work on a farm.
Rambling answer that didn't really answer your question. Bottom line is globalization and influx of foreign goods in any country drives competition, lowers prices, promotes productivity/innovation, and moves economies away from manufacturing towards service industries, which increases wages.
So I don't buy American to be patriotic, I buy the best quality item for the lowest price. And I support removing trade barriers because I think that is the MOST patriotic thing you can do for your country in the long run