Skip to content

Commit

Permalink
Fix module links (#3855)
Browse files Browse the repository at this point in the history
  • Loading branch information
npentrel authored Jan 15, 2025
1 parent 3fa12bd commit 455a60e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions assets/js/models.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ const { TypesenseInstantSearchAdapter, instantsearch } = window;
let api = "";
if (document.getElementsByClassName("mr-component").length){
api = document.getElementsByClassName("mr-component")[0].id;
console.log(api);
}
let baseURL = params.baseURL.substr(-1) === '/' ? params.baseURL.slice(0, -1) : params.baseURL;

Expand Down Expand Up @@ -46,7 +45,7 @@ if (api == "") {
};
itemtemplate = `
<div class="type"><p><code>{{#helpers.highlight}}{ "attribute": "api" }{{/helpers.highlight}}</code></p></div>
<div class="name"><p><a href="${baseURL}{{url}}"><code>{{#helpers.highlight}}{ "attribute": "model" }{{/helpers.highlight}}</code></a></p></div>
<div class="name"><p><a href="{{url}}"><code>{{#helpers.highlight}}{ "attribute": "model" }{{/helpers.highlight}}</code></a></p></div>
<div class="description">{{#helpers.highlight}}{ "attribute": "description" }{{/helpers.highlight}}</div>
`;
} else {
Expand All @@ -55,7 +54,7 @@ if (api == "") {
hitsPerPage: 5,
};
itemtemplate = `
<div class="name"><p><a href="${baseURL}{{url}}"><code>{{#helpers.highlight}}{ "attribute": "model" }{{/helpers.highlight}}</code></a></p></div>
<div class="name"><p><a href="{{url}}"><code>{{#helpers.highlight}}{ "attribute": "model" }{{/helpers.highlight}}</code></a></p></div>
<div class="description">{{#helpers.highlight}}{ "attribute": "description" }{{/helpers.highlight}}</div>
`;
}
Expand Down

0 comments on commit 455a60e

Please sign in to comment.