Skip to content

Commit

Permalink
updated filter base from url to category type
Browse files Browse the repository at this point in the history
  • Loading branch information
bluedeepart committed Nov 7, 2024
1 parent 5035c81 commit 7a55e00
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 12 deletions.
4 changes: 2 additions & 2 deletions blocks/breadcrumbs/breadcrumbs.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
}

.news main .breadcrumbs,
.publication main .breadcrumbs,
.events main .breadcrumbs {
.events main .breadcrumbs,
.publication:not(.full-article) main .breadcrumbs {
padding-top: 70px;
}

Expand Down
11 changes: 1 addition & 10 deletions blocks/card-list/card-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -272,16 +272,7 @@ const VARIANTS = {
},

getCategories(item) {
const category = item.path
.split('/')[2];

if (!category || category === 'blog') return null;

const filterableCategory = category.split('-')
.map((s) => s.charAt(0).toUpperCase() + s.slice(1).toLowerCase())
.join('-');

return [filterableCategory];
return [item.category || item.Category];
},
},

Expand Down

0 comments on commit 7a55e00

Please sign in to comment.