mirror of
https://github.com/tcsenpai/obsidiangarden_netlify.git
synced 2025-06-03 19:40:03 +00:00
Add null checks for empty dataview queries (#157)
This commit is contained in:
parent
aa1473d8fa
commit
c0f07cb5f3
@ -400,12 +400,12 @@ module.exports = function (eleventyConfig) {
|
|||||||
)) {
|
)) {
|
||||||
t.classList.add("dataview");
|
t.classList.add("dataview");
|
||||||
t.classList.add("table-view-table");
|
t.classList.add("table-view-table");
|
||||||
t.querySelector("thead").classList.add("table-view-thead");
|
t.querySelector("thead")?.classList.add("table-view-thead");
|
||||||
t.querySelector("tbody").classList.add("table-view-tbody");
|
t.querySelector("tbody")?.classList.add("table-view-tbody");
|
||||||
t.querySelectorAll("thead > tr").forEach((tr) => {
|
t.querySelectorAll("thead > tr")?.forEach((tr) => {
|
||||||
tr.classList.add("table-view-tr-header");
|
tr.classList.add("table-view-tr-header");
|
||||||
});
|
});
|
||||||
t.querySelectorAll("thead > tr > th").forEach((th) => {
|
t.querySelectorAll("thead > tr > th")?.forEach((th) => {
|
||||||
th.classList.add("table-view-th");
|
th.classList.add("table-view-th");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
2
.gitignore
vendored
2
.gitignore
vendored
@ -9,5 +9,5 @@ src/site/styles/_theme.*.css
|
|||||||
.idea/
|
.idea/
|
||||||
.vercel
|
.vercel
|
||||||
.cache
|
.cache
|
||||||
_site
|
_site/
|
||||||
**/.DS_Store
|
**/.DS_Store
|
||||||
|
Loading…
x
Reference in New Issue
Block a user