Question: When did Transylvania become part of the Habsburg's Austrian empire?
About the article "Romania", section "Middle Ages".

Candidate passages:
The Principality of Transylvania, from 1765 Grand Principality of Transylvania, was a crown land of the Habsburg Monarchy and a constituent land of the Austrian Empire. 
Principality of Transylvania can refer to:  Principality of Transylvania (1570–1711), a semi-independent state  Principality of Transylvania (1711–1867) (from 1765 "Grand Principality of Transylvania"), a province of the Habsburg Monarchy and later of the Austrian Empire  
"Gesta Hungarorum" mentioned the existence of three voivodeships in Transylvania in the 9th century: the Voivodeship of Gelou, the Voivodeship of Glad and the Voivodeship of Menumorut.
The anonymous author describes the first as Vlach.
Another voivodeship, ruled by Gyula, was mentioned in the 11th century.
A Russian chronicle writes of a plundering raid in 1059 against Transylvania by Cumans and Vlachs.
An Old Bulgarian inscription from 1176 attests the existence of a župan Dimitri who ruled over Dobruja in 943.
In the Middle Ages, Romanians lived in three distinct principalities: Wallachia ( – "The Romanian Land"), Moldavia () and Transylvania ().
By the 11th century, Transylvania had become a largely autonomous part of the Kingdom of Hungary.
It was independent as the Principality of Transylvania from the 16th century until 1711.
In Wallachia and Moldavia, many small local states with varying degrees of independence developed.
Only in the 14th century did the larger principalities of Wallachia (1310) and Moldavia (around 1352) emerge to fight the threat of the Ottoman Empire.
Both territories inhabited by Romanians achieved their independence from the Hungarian Crown after military conflicts (Battle of Posada, 1330) or social conflicts (Moldavian boyars' revolt against Hungary, 1364) — these historic events being initiated by Basarab I of Wallachia (1310–1352) and Bogdan I of Moldavia (1359–1365).
By 1541, the entire Balkan peninsula and most of Hungary had become Ottoman provinces.
Moldavia, Wallachia, and Transylvania were under Ottoman suzerainty, preserving partial or full internal autonomy until the mid-19th century (Transylvania until 1699).
During this period, in the Romanian lands the feudal system slowly disappeared.
A few rulers of territories in what is now Romania distinguished themselves: these rulers include Stephen the Great, Vasile Lupu, and Dimitrie Cantemir in Moldavia; Matei Basarab, Vlad the Impaler, and Constantin Brâncoveanu in Wallachia; and John Hunyadi ("Ioannes Corvinus") and Gabriel Bethlen in Transylvania.
In 1600, the principalities of Wallachia, Moldavia and Transylvania were simultaneously headed by the Wallachian prince Michael the Brave ("Mihai Viteazul"), but the chance for a lasting unification was lost after Mihai was assassinated only one year later.
After his death, as vassal tributary states, Moldavia and Wallachia had complete internal autonomy and external independence, which they finally lost in the 18th century.
In 1699, Transylvania became a territory of the Habsburgs' Austrian empire following the Austrian victory over the Turks in the Great Turkish War.
The Habsburgs in turn expanded their empire in 1718 to include an important part of Wallachia called Oltenia (which was returned only in 1739), and in 1775 to include the northwestern part of Moldavia, later called Bukovina.
The eastern half of the Moldavian principality (called Bessarabia) was occupied in 1812 by Russia.
Slavici was born in the village of Șiria, near Arad, in 1848, the revolutionary year throughout Europe, with ramifications in Transylvania (then part of the Austrian Empire).
Until 1868, Slavici studied at the local Orthodox school and various other institutions in Transylvania, being taught in either Hungarian or German.
When he finished his studies, Slavici left Transylvania for Budapest, where he intended to study law.
The following year, however, financial difficulties forced him to return home and take a job as a notary public.
Throughout his employment, Ioan Slavici saved the money that would help him continue his studies. 
By 1541, the entire Balkan peninsula and most of Hungary became Ottoman provinces.
In contrast, Moldavia, Wallachia, and Transylvania, came under Ottoman suzerainty, but conserved fully internal autonomy and, until the 18th century, some external independence.
During this period, also called the Phanariot Epoch, the Romanian lands were characterised by the slow disappearance of the feudal system and the distinguishment of some rulers like Vasile Lupu and Dimitrie Cantemir in Moldavia, Matei Basarab and Constantin Brâncoveanu in Wallachia, and Gabriel Bethlen in Transylvania.
At that time the Russian Empire appeared to become the political and military power which threatened the Romanian principalities.
John II, the non-Habsburg king of Hungary, moved his royal court to Alba Iulia in Transylvania, and after his abdication from the Hungarian throne, he became the first "Prince of Transylvania".
His Edict of Turda was the first decree of religious freedom in the modern European history (1568).
In the aftermath Transylvania was ruled by mostly Calvinist Hungarian princes (until the end of the 17th century), and Protestantism flourished in the region.
Michael the Brave (Romanian: Mihai Viteazul) was the Prince of Wallachia (1593–1601), of Transylvania (1599–1600), and of Moldavia (1600).
For a short time during his reign Transylvania was ruled together with Moldavia and Wallachia in a personal union.
After his death the union dissolved and as vassal tributary states Moldova and Wallachia still had an internal autonomy and some external independence, which was finally lost in the 18th century.
The Principality of Transylvania reached its golden age under the absolutist rule of Gabor Bethlen (1613–1629).
In 1699, Transylvania became a part of the Habsburgs' Austrian Empire, following the Austrian victory over the Turks.
The Austrians, in their turn, rapidly expanded their empire: in 1718 a major part of Wallachia, Oltenia, was annexed to the Austrian monarchy and was only returned in 1739.
In 1775, the Austrian empire occupied the north-western part of Moldavia, later on called Bukovina, while the eastern half of the principality (by the name of Bessarabia) was occupied in 1812 by Russia.
During the Austro-Hungarian rule in Transylvania, and the Ottoman suzerainty over Wallachia and Moldavia, most Romanians were actually second-class citizens (or even non-citizens) in a territory where in fact they constituted the majority of the population.
In some Transylvanian cities like Brașov (at that time the Transylvanian Saxon citadel of Kronstadt), Romanians were not even allowed to reside within the city walls.