tabs: add clearURL method, loading tabs clears previous qps

Navigatable has clearURL, which for Search clears "search" qp, and
invites clears "invite" qp. Tab interfaces optionally include
"contentObject: AsTab", and show/hide funcs are passed the contentObject
of the previously loaded tab if one is available, so that they can call
it's clearURL method. This means searches you typed for the accounts tab
won't pop up when switching to activity.
This commit is contained in:
Harvey Tindall
2026-01-05 10:39:20 +00:00
parent 721b209e1f
commit ee96bb9f1b
7 changed files with 50 additions and 11 deletions
+4
View File
@@ -731,6 +731,10 @@ export class Search implements Navigatable {
this.setQueryParam("");
};
clearURL() {
this.clearQueryParam();
}
// setQueryParam sets the ?search query param to the current searchbox content,
// or value if given. If everything is set up correctly, this should trigger a search when it is
// set to a new value.