Bug 1751851 - [devtools] Migrate all file-search selectors to a selector module. r=bomsy

Differential Revision: https://phabricator.services.mozilla.com/D136857
This commit is contained in:
Alexandre Poirot 2022-01-27 08:31:40 +00:00
Родитель 1801acf3d0
Коммит 05a36f0d48
4 изменённых файлов: 17 добавлений и 16 удалений

Просмотреть файл

@ -67,19 +67,4 @@ function update(state = initialFileSearchState(), action) {
}
}
// NOTE: we'd like to have the app state fully typed
// https://github.com/firefox-devtools/debugger/blob/master/src/reducers/sources.js#L179-L185
export function getFileSearchQuery(state) {
return state.fileSearch.query;
}
export function getFileSearchModifiers(state) {
return state.fileSearch.modifiers;
}
export function getFileSearchResults(state) {
return state.fileSearch.searchResults;
}
export default update;

Просмотреть файл

@ -0,0 +1,15 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at <http://mozilla.org/MPL/2.0/>. */
export function getFileSearchQuery(state) {
return state.fileSearch.query;
}
export function getFileSearchModifiers(state) {
return state.fileSearch.modifiers;
}
export function getFileSearchResults(state) {
return state.fileSearch.searchResults;
}

Просмотреть файл

@ -10,7 +10,6 @@ export * from "../reducers/threads";
export * from "../reducers/breakpoints";
export * from "../reducers/pending-breakpoints";
export * from "../reducers/ui";
export * from "../reducers/file-search";
export * from "../reducers/project-text-search";
export * from "../reducers/source-tree";
export * from "../reducers/preview";
@ -39,6 +38,7 @@ export {
export { getBreakpointSources } from "./breakpointSources";
export * from "./event-listeners";
export * from "./exceptions";
export * from "./file-search";
export { getCallStackFrames } from "./getCallStackFrames";
export { isLineInScope } from "./isLineInScope";
export { isSelectedFrameVisible } from "./isSelectedFrameVisible";

Просмотреть файл

@ -12,6 +12,7 @@ CompiledModules(
"breakpointSources.js",
"event-listeners.js",
"exceptions.js",
"file-search.js",
"getCallStackFrames.js",
"index.js",
"isLineInScope.js",