I'd like to use the current open/closed status of a webform in a conditional on the webform-submission-information.html.twig. There is a "webform" variable available to use in the
template_preprocess_webform_submission_information function, but all that seems to do is print a link to the webform. When I try to use the usual methods that I'd usually use on a webform object, I just get WSOD. Something tells me that variable isn't actually an object.
For example, perhaps I could get the webform id and use that to figure out the status of the webform...
$form = $vars['webform']['details']['nid']['#value'];
Also, is there a resource for figuring out the pathing to the API is for the Webform? The documentation exists on the Drupal site certainly, but it'd be a lot easier if there was some kind of resource that gave us the path to all these data endpoints. As it stands, even if I figured out the correct function for extracting the webform's ID, I wouldn't have any clue how to find the status (open/closed) endpoint. There are some old d7 articles and issues out there, but it'd be nice if we didn't have to rely on issues and, instead, if there was intuitive documentation.