decord/alpha/source/modules/search/SelectedSearchContextStore.tsx

40 lines
1.3 KiB
TypeScript
Raw Normal View History

2026-10-09 10:00:15 +00:00
// Module ID: 12000
// Function ID: 12001
2026-10-06 11:16:32 +00:00
// Name: SelectedSearchContextStore
2026-10-09 10:00:15 +00:00
// Dependencies: [5201, 504, 584, 2]
2026-10-06 11:16:32 +00:00
2026-10-09 10:00:15 +00:00
// Module 12000 (SelectedSearchContextStore)
2026-10-06 11:16:32 +00:00
import get_initializedDefault from "get initialized" /* 504 */;
import DispatcherDefault from "Dispatcher" /* 584 */;
2026-10-09 10:00:15 +00:00
import isEqualDefault from "isEqual" /* 5201 */;
2026-10-06 11:16:32 +00:00
import size from "module_2" /* 2 */;
function handleSearchContextUpdate(searchContext) {
searchContext = searchContext.searchContext;
if (isEqualDefault(c2, searchContext)) {
return false;
} else {
c2 = searchContext;
}
}
let c2 = null;
const Store = get_initializedDefault.Store;
class SelectedSearchContextStore extends Store {
getSelectedSearchContext() {
return c2;
}
}
const prototype = SelectedSearchContextStore.prototype;
SelectedSearchContextStore.displayName = "SelectedSearchContextStore";
const obj = {
SEARCH_AUTOCOMPLETE_INITIALIZE: handleSearchContextUpdate,
SEARCH_AUTOCOMPLETE_QUERY_UPDATE: handleSearchContextUpdate,
SEARCH_QUERY_TEXT_CLEAR: function handleSearchQueryTextClear() {
c2 = null;
}
};
const selectedSearchContextStore = new SelectedSearchContextStore(DispatcherDefault, obj);
const result = size.fileFinishedImporting("modules/search/SelectedSearchContextStore.tsx");
export default selectedSearchContextStore;