Spin the Dawn by Elizabeth Lim

Maia Tamarin dreams of becoming the greatest tailor in the land, but as a girl, the best she can hope for is to marry well. When a royal messenger summons her ailing father, once a tailor of renown, to court, Maia poses as a boy and takes his place.