AFAIK they’re used to denote just sex, because gender identity is rarely possible to deduce from an image, and users mainly care about the physicality of characters when they’re looking to search or filter.
If a character is transgender and has no permanent changes to their male/female/intersex body, I don’t see any reason why they shouldn’t be tagged both $trans_theirgender and $their_sex. Single characters should never have multiple sex tags.
As for permanent changes to bodies, I’ll say nothing because it’s a more complicated thing and I have next to no experience about that. I don’t think we have too many examples of, say, cisgender-and-female characters who’ve had full bilateral mastectomy. (Personally I think such a case should be tagged “female” and “amputee” and probably something specific to the acquired lack of breasts.)