Hello,
I have added a attribute (data-link) to the kirby link-tag in the file kirby > extensions > tags.php
.
// link tag
kirbytext::$tags['link'] = array(
'attr' => array(
'text',
'class',
'role',
'title',
'rel',
'lang',
'target',
'popup',
'data-link'
),
'html' => function($tag) {
$link = url($tag->attr('link'), $tag->attr('lang'));
$text = $tag->attr('text');
if(empty($text)) {
$text = $link;
}
if(str::isURL($text)) {
$text = url::short($text);
}
return html::a($link, $text, array(
'rel' => $tag->attr('rel'),
'class' => $tag->attr('class'),
'role' => $tag->attr('role'),
'title' => $tag->attr('title'),
'data-link' => $tag->attr('data-link'),
'target' => $tag->target()
));
}
);
But if I write this attribute in a markdown textfield it will not getting grey like the other attributes.
What have I to do that it will recognize as a attribute in the markdownfield?
Cheers