Skip to content

Commit

Permalink
templates: grants_table_scripts: Use the existing property for if widget
Browse files Browse the repository at this point in the history
The template is loaded with "with widget=true/false" when it is in
widget mode so we can use this value as the SSOT.
  • Loading branch information
michaelwood committed Feb 13, 2025
1 parent 74a217b commit 8549601
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<style scoped>
.remove-order-button:after {
content: unset !important;
cursor: auto !important;
}
</style>

Expand Down Expand Up @@ -33,7 +34,7 @@
const params = new URLSearchParams(window.location.search);
const inputRows = params.get('rows');
const inputColumns = params.getAll('widgetColumn');
const isWidget = window.location.pathname.includes('widget');
const isWidget = {% if widget %}true{% else %}false{% endif %}; // eslint-disable-line

// We always want amount and date shown in the datatable
inputColumns.push('amount');
Expand Down

0 comments on commit 8549601

Please sign in to comment.