Adds data-tainacan-item-id attribute to all items on theme view modes.
This commit is contained in:
parent
9889dddf69
commit
86cceb8d2e
|
@ -35,6 +35,7 @@
|
||||||
<a
|
<a
|
||||||
role="listitem"
|
role="listitem"
|
||||||
:key="index"
|
:key="index"
|
||||||
|
:data-tainacan-item-id="item.id"
|
||||||
v-for="(item, index) of items"
|
v-for="(item, index) of items"
|
||||||
class="tainacan-card"
|
class="tainacan-card"
|
||||||
:href="getItemLink(item.url, index)">
|
:href="getItemLink(item.url, index)">
|
||||||
|
|
|
@ -34,6 +34,7 @@
|
||||||
class="tainacan-list-container">
|
class="tainacan-list-container">
|
||||||
<a
|
<a
|
||||||
role="listitem"
|
role="listitem"
|
||||||
|
:data-tainacan-item-id="item.id"
|
||||||
:href="getItemLink(item.url, index)"
|
:href="getItemLink(item.url, index)"
|
||||||
:key="index"
|
:key="index"
|
||||||
v-for="(item, index) of items"
|
v-for="(item, index) of items"
|
||||||
|
|
|
@ -40,6 +40,7 @@
|
||||||
class="tainacan-masonry-container">
|
class="tainacan-masonry-container">
|
||||||
<a
|
<a
|
||||||
role="listitem"
|
role="listitem"
|
||||||
|
:data-tainacan-item-id="item.id"
|
||||||
:key="index"
|
:key="index"
|
||||||
v-for="(item, index) of items"
|
v-for="(item, index) of items"
|
||||||
class="tainacan-masonry-item"
|
class="tainacan-masonry-item"
|
||||||
|
|
|
@ -40,6 +40,7 @@
|
||||||
class="tainacan-records-container">
|
class="tainacan-records-container">
|
||||||
<a
|
<a
|
||||||
role="listitem"
|
role="listitem"
|
||||||
|
:data-tainacan-item-id="item.id"
|
||||||
:href="getItemLink(item.url, index)"
|
:href="getItemLink(item.url, index)"
|
||||||
:key="index"
|
:key="index"
|
||||||
v-for="(item, index) of items"
|
v-for="(item, index) of items"
|
||||||
|
|
|
@ -448,7 +448,7 @@ export default {
|
||||||
virtual: {
|
virtual: {
|
||||||
slides: self.slideItems,
|
slides: self.slideItems,
|
||||||
renderSlide(slideItem) {
|
renderSlide(slideItem) {
|
||||||
return `<div role="listitem" class="swiper-slide tainacan-slide-item">
|
return `<div data-tainacan-item-id="`+ slideItem.id + `" role="listitem" class="swiper-slide tainacan-slide-item">
|
||||||
<img
|
<img
|
||||||
alt="` + (slideItem['thumbnail_alt'] ? slideItem['thumbnail_alt'] : (self.$i18n.get('label_thumbnail') + ': ' + slideItem.title) ) + `"
|
alt="` + (slideItem['thumbnail_alt'] ? slideItem['thumbnail_alt'] : (self.$i18n.get('label_thumbnail') + ': ' + slideItem.title) ) + `"
|
||||||
class="thumbnail"
|
class="thumbnail"
|
||||||
|
|
|
@ -90,6 +90,7 @@
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr
|
<tr
|
||||||
|
:data-tainacan-item-id="item.id"
|
||||||
:key="index"
|
:key="index"
|
||||||
v-for="(item, index) of items">
|
v-for="(item, index) of items">
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue