There is legit scientific prototypes of solar panels made from non-mined biodegradable materials... if they will become viable and when is another question. But there is no fundemental limits in physics that would make it out of the realm of possiblity.
I think I even remember solar panels made with microorganisms that reproduce.
I haven't researched the specifics. Though I'd be interested to talk to a materials scientist regarding non-metal conductors.
There is also the point that we have vast amounts of metal in circulation. If we considered metal as a precious resource within a circular economy, we could minimize mining practices.
At the moment, mining is unsustainable because of its scale. The current economy is a resource and power "hungry" system. For example, whilst renewable energy is a way to reduce greenhouse gases, for it to be sustainable, we have to power down some aspects of the economy. But, rather than use what metal is already in circulation, the mining industries are planning on mining metals from the sea bed (more habitat destruction). That evidently can't go on without their being serious consequences.