In answering this, it should be noted that different schools and different school districts have different policies. Prior to any exploration online, I would check with your Human Resources department. If you are a member of your Teacher's Union, or if you have some type of collective bargaining association, I would be in immediate contact with them, as well, to gain their insight. Reaching out to both of these domains will provide a more focused and relevant answer because it is in your immediate realm. At the very least, in reaching out, your voice is heard.
Speaking with this in mind and from a theoretical perspective, the short and awful answer is that your principal does have every right to go back on her word. It's not pleasant, but from a professional standpoint, she has her ground. My guess is that upon the completion of your exit interview, the understanding you had with her was verbal. Even if you were able to sign something, it would be a letter of intent that speaks to you having a position for the upcoming school year. Wherever that position is becomes her discretion and she is able to do that as an administrator. It is not guaranteed. Administrators are always able to invoke the idea that they are acting "within the building's interest" and that staffing concerns are always fluid. Nothing definite in terms of placement can be assured as these situations can always be depicted as ones in constant change. This is where their authority can always be wielded. In short, she does have the right to do what she did.
I don't think it would be a bad idea to try to find some time and speak with her about how the move might not be in the best interests of the education of children. Teachers work best when they feel the most comfortable with the curriculum and the age group. It might be in the best interests of all parties possible if you remained where you were because it is such new terrain for you. It might not hurt to emphasize this, but if the principal has her mind made up, I think that the issue might be regrettably solidified.
It is a very difficult condition to find yourself. It is terrible to say, but if it is already decided, I see no other choice but to use the summer to really focus in on the skills you will need in the new position. In the final analysis, the principal's decision is not going to stop you from being a quality educator. It is regrettable that your voice has not been validated in this process. I would suggest that your craft is where your voice can be validated. Using the time in the summer to ensure that you are ready to take this one last challenge in your career will help in both the process of providing a capstone to your time in education and help your incoming students be stronger after a year of your instruction.