Ruth Bader Ginsburg worked through her fifth bout of cancer to help shape a blockbuster Supreme Court term