mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2026-02-03 14:21:38 -08:00
Fix various filtering/sorting bugs
This commit is contained in:
parent
42e61d5d90
commit
7c2446c73c
5 changed files with 81 additions and 66 deletions
|
|
@ -198,16 +198,8 @@ class Clusterize {
|
|||
this.#max_items = max_items;
|
||||
return this.#max_items !== max_items;
|
||||
}
|
||||
if (this.#max_items === max_items) {
|
||||
// No change. do nothing.
|
||||
return false;
|
||||
}
|
||||
// If the number of items changed, we need to update the cluster.
|
||||
|
||||
this.#max_items = max_items;
|
||||
await this.refresh();
|
||||
// Apply sort to the updated data.
|
||||
await this.sortData();
|
||||
return true;
|
||||
}
|
||||
|
||||
// ==== PRIVATE FUNCTIONS ====
|
||||
|
|
@ -266,6 +258,8 @@ class Clusterize {
|
|||
// Filter is applied to entire dataset.
|
||||
const max_items = await this.options.callbacks.filterData();
|
||||
await this.setMaxItems(max_items);
|
||||
await this.refresh(true);
|
||||
await this.sortData();
|
||||
}
|
||||
|
||||
#exploreEnvironment(rows, cache) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue