Add support for open and close operations

Allow programatically opening and closing the details. Should work even before the `.details()` plugin has run.