- Status changed to Closed: outdated
over 1 year ago 9:11pm 29 June 2023 - πΊπΈUnited States mark_fullmer Tucson
Since the changes proposed are present in the 2.x version of this module, I'm going to close this as "outdated."
I have a page with Boostrap Horizontal Tabs.
In one tab I have a custom token, for example [my:custom:token]
The content renders OK, but none of the assets are attached (such as library). It looks like the render array ['#attached'] that is in custom hook_tokens function is not being included.
It appears that it is being lost in BootstrapHorizontalTabs.php so I changed the below...
<?php
foreach ($items as $delta => $item) {
$elements['#items'][$delta] = [
'header' => $item->header,
'body' => check_markup($item->body_value, $item->body_format),
'id' => preg_replace('/[^a-z0-9_]+/', '_', strtolower($item->header)),
];
}
?>
and removed the 'check_markup' to...
<?php
foreach ($items as $delta => $item) {
$elements['#items'][$delta] = [
'header' => $item->header,
'body' => [
'#type' => 'processed_text',
'#text' => $item->body_value,
'#format' => $item->body_format,
],
'id' => preg_replace('/[^a-z0-9_]+/', '_', strtolower($item->header)),
];
}
?>
And library assets now load with the page. Can someone please advise?
Closed: outdated
2.0
Code
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
Since the changes proposed are present in the 2.x version of this module, I'm going to close this as "outdated."