I have yet to perform any repairs on these. Is this something that your warranty would cover? Here is the procedure from service information.
It is only necessary to lower the headliner. Only do those step in headliner replacement that will lower the headliner enough to gain access to the part. Refer to Headlining Trim Panel Replacement.
Sunshade Fastener (Qty: 3)
Caution: Refer to Fastener Caution in the Preface section.
The closeout snaps into place, remove the closeout to access the screws.
3 N m (27 lb in)
Squeeze the tabs at the base of the sunshade assembly to remove from the headliner.
Disconnect the electrical connector.