My guess is that it would be a code violation. In most places there is a minimum distance between a fireplace and any wood. My guess is that your home is built with wood studs, so the distance would be only a few inches at most. I'd ask your builder about it.
_________________________
Bitt Faulk