DesertCookie
DesertCookie
Explore posts from servers
NNuxt
Created by DesertCookie on 5/10/2024 in #❓・help
Append to UTable header template slot
Alright, here's my current, bad implementation: Add a special row to the data: rows.push({filterRow: true})
React to that row with a v-if in every data template slot:
<div v-if="row.filterRow">
<UInput type="text" v-model="costumesStore.filters.title" placeholder="Filter title"/>
</div>
<div v-else> render regular data </div>
<div v-if="row.filterRow">
<UInput type="text" v-model="costumesStore.filters.title" placeholder="Filter title"/>
</div>
<div v-else> render regular data </div>
This works, however, it makes the filter row move around when sorting.
2 replies