This week, retired justice Sandra Day O’Connor, the first woman on the Supreme Court, announced that her dementia is so advanced that she can no longer continue in public life. O’Connor’s was a heroic story, complete with cowboys and horses. But the heroine flinched as the clock touched high noon. In 2000, she cast the critical fifth vote to stop the recount and ensure a GOP presidency in Bush v. Gore. Her legacy is forever tainted by the consequences of that decision.

Like so many Republican women, including the current six U.S. senators and many of the 47 to 53 percent of white women (the polling numbers are disputed) who supported Donald Trump in 2016, O’Connor was a moderately conservative, married, middle-class person who believed that all doors would be opened to those who worked and didn’t let anything bother them. In her very first vote on the court, she broke a 4-4 tie to hold that public universities could not discriminate on the grounds of sex. The Mississippi University for Women would just have to admit men.

In 1986, she cast another crucial tie-breaking vote, this time to let employers off the hook if supervisors harassed their female underlings for sex. All employers had to do was provide women employees with a process for complaining. If they had a human resources department, she thought, women like her were going to be all right. Women were entitled to abortion rights, she ruled, but states could place any burden on the exercise of that right, as long as it was not “undue.” Only the sensible O’Connor knew exactly where the right balance of burdens should be drawn. Strong, determined women like her could bear almost any burden en route to getting their abortion rights.

As one decision followed another, a pattern emerged. If they were strong and determined enough, conventional, unthreatening women would gradually get whatever they deserved in the workplace or in politics. O’Connor just kept cooking lunches for all her clerks and leading 1970s ladies’ aerobics classes in the early morning hours.

But by 2000, she was already a dinosaur. As the country hurtled toward a collision with the clear, unbridgeable, ideological partisan divide over every meaningful issue in American politics, including the rights of women, she (like some of the Republican women in the Senate today) still thought she could reconcile her lifelong adherence to the Republican Party with a benign and sensible commitment to moderate, civil politics. Like many of them, O’Connor had spent her life in the GOP. She was a volunteer co-chair of the local Maricopa County Republican Committee when she asked party honchos to get the Republican state attorney general to hire her. In 1988, she wrote to her mentor Barry Goldwater that she worried that Republican presidential nominee George H.W. Bush might lose, posing dangers “to the Court and to the country.”

Bush won, but if his nomination of Clarence Thomas to the court didn’t warn her that her world was changing, the ever more aggressive burdens on abortion rights should have warned her. In 1992, the state of Pennsylvania had passed a law requiring women seeking abortions to wait 24 hours, minors to get parental or judicial consent, extensive records to be kept about the women seeking help and wives to notify their husbands first. O’Connor, along with Justices Anthony M. Kennedy and David Souter, provided the crucial votes to preserve the shell of Roe v. Wade and approve the Pennsylvania law, except for the requirement that married women check in with hubby first. (In the saga of that lawsuit, only one judge who encountered it thought that having to tell your husband was not a big burden: Justice Samuel A. Alito Jr., then on the Court of Appeals.) So even after 1992, married women like O’Connor were still okay, too.

When, in 2000, the networks began calling the election for Al Gore, O’Connor, at a party held by friends, blurted out, “it’s over,” and rose from her seat before the television in disgust. Her husband, John O’Connor, explained to the other guests that she wanted to retire and of course did not want to turn over her seat to a Democratic president. Six weeks later, she cast the critical fifth vote to stop the recount of the Florida ballots and guarantee the White House for the Republican.

In the few remaining years before she retired, O’Connor exercised her critical swing vote in favor of campaign finance restrictions and to protect affirmative action and voting rights. Pundits speculated that her swing to the left might have been out of guilt for Bush v. Gore. Four years after his inauguration, she handed Bush her seat. To replace her, Bush appointed Alito.

O’Connor took her ailing husband home to Arizona and devoted herself to the good-government project of educating children about civics. In the five years after Alito’s appointment, the Supreme Court held that banning abortions without regard for the woman’s health was not burdensome, the Constitution protected private individuals' right to carry guns, that campaign finance restrictions violated the right to free speech, and that there was no further need for most of the Voting Rights Act. Education about civics wasn’t all that helpful to the hundreds of thousands of people not voting because of increasingly onerous restrictions enacted almost entirely by Republicans elected in 2010 and 2014.

Some people began asking O’Connor whether she had regrets. No, she said. But the new court began overturning her rulings, and she admitted: “I’d be a little bit disappointed. If you think you’ve been helpful, and then it’s dismantled, you think, ‘Oh, dear.’ But life goes on. It’s not always positive.”

She called the 2010 Citizens United ruling allowing corporations to spend freely on elections for Congress and the presidency an example of how those bad boys behave when she turns her back on them for just a couple of years.

Still, she clearly hated being asked about Bush v. Gore. At public appearances, she would shake her head and turn her trademark frown on the uppity questioner; she consistently refused to confront what she had done. The questions became more frequent and more exigent. Finally, in 2013, she admitted to the editorial board of the Chicago Tribune that maybe the court should have left that one alone. Not for the damage to the country, but because it might have hurt the court.

Turns out, the person on the court most hurt by her vote was O’Connor herself. She was a great first. Gave no one any trouble, as Justice John Paul Stevens once told me in an interview. Had exquisite manners that made the institution a more agreeable place, even for Thomas, whom she invited to lunch upon his arrival, rejecting his efforts to sulk in his chambers. Many of her decisions (integrating the Mississippi college, saving the skeleton of Roe v. Wade, defending affirmative action) made the world a better place for American women. But at the end of the day — and with her dementia, it nearly is the end of her day — O’Connor’s legacy will always be fixed by the night in December 2000 when she cast the critical vote and put George W. Bush in the White House.