A metamorphic inorganic framework that can be switched between eight single-crystalline states