From 1138 to 1228, part of the Duchy of Kraków and Sandomierz, belonging to the high-dukes of Poland.