Add Heater to Circuit - 14 AWG to 10 AWG on 30A breaker?
Code doesn't apply to the wiring within appliances

The NEC does not deal with wiring within appliances -- UL (or CSA, or Intertek, or MET, or TUV) is the one responsible for ensuring that's safe, and they work off a different set of wiring specs (Appliance Wiring Material or AWM for short) than the wiring used for building wire.  This is codified in NEC 300.1(B):


  (B) Integral Parts of Equipment. The provisions of this
  article are not intended to apply to the conductors that form
  an integral part of equipment, such as motors, controllers,
  motor control centers, or factory assembled control equipment or listed utilization equipment.