Skip to content

Commit 0e8b789

Browse files
committed
Add button to reset filters in compare page
1 parent e8a20e2 commit 0e8b789

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

site/static/compare.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -274,6 +274,7 @@ <h2>Comparing <span id="stat-header">{{stat}}</span> between <span id="before">{
274274
</div>
275275
<input type="checkbox" v-model="showRawData" style="margin-left: 20px;" />
276276
</div>
277+
<button @click="resetFilter">Reset filters</button>
277278
</div>
278279
</fieldset>
279280
<p v-if="dataLoading && !data">Loading ...</p>

site/static/compare/script.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,9 @@ const app = Vue.createApp({
282282

283283
return createUrlFromParams(createSearchParamsForMetric(metric, start, end));
284284
},
285+
resetFilter() {
286+
this.filter = createDefaultFilter();
287+
}
285288
},
286289
});
287290

0 commit comments

Comments
 (0)