diff options
| author | Andy Rickert <andrew_rickert@brown.edu> | 2020-08-04 12:18:16 -0400 |
|---|---|---|
| committer | Andy Rickert <andrew_rickert@brown.edu> | 2020-08-04 12:18:16 -0400 |
| commit | a59bcec29efb9b5ea0ba8ddfb4b9977b904c10b8 (patch) | |
| tree | 33941af37b41bd7dbe2579d1e705608dbb53e368 /src/client/views/search/SearchBox.tsx | |
| parent | d4c41208367775ccfb530418137a4de7c8d62472 (diff) | |
cleaning up
Diffstat (limited to 'src/client/views/search/SearchBox.tsx')
| -rw-r--r-- | src/client/views/search/SearchBox.tsx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/client/views/search/SearchBox.tsx b/src/client/views/search/SearchBox.tsx index b7f7af244..b76955815 100644 --- a/src/client/views/search/SearchBox.tsx +++ b/src/client/views/search/SearchBox.tsx @@ -54,7 +54,7 @@ const SearchBoxDocument = makeInterface(documentSchema, searchSchema); @observer export class SearchBox extends ViewBoxBaseComponent<FieldViewProps, SearchBoxDocument>(SearchBoxDocument) { - @computed get _searchString() { return this.layoutDoc.searchQuery; } + get _searchString() { return this.layoutDoc.searchQuery; } @computed set _searchString(value) { this.layoutDoc.searchQuery = (value); } @observable private _resultsOpen: boolean = false; @observable _searchbarOpen: boolean = false; @@ -691,7 +691,7 @@ export class SearchBox extends ViewBoxBaseComponent<FieldViewProps, SearchBoxDoc const startIndex = Math.floor(Math.max(0, scrollY / itemHght)); //const endIndex = Math.ceil(Math.min(this._numTotalResults - 1, startIndex + (this._resultsRef.current.getBoundingClientRect().height / itemHght))); const endIndex = 30; - this._endIndex = endIndex === -1 ? 12 : endIndex; + //this._endIndex = endIndex === -1 ? 12 : endIndex; this._endIndex = 30; let headers = new Set<string>(["title", "author", "text", "lastModified"]); if ((this._numTotalResults === 0 || this._results.length === 0) && this._openNoResults) { @@ -1039,7 +1039,7 @@ export class SearchBox extends ViewBoxBaseComponent<FieldViewProps, SearchBoxDoc style={{ color: "black", padding: 1, left: 35, position: "relative" }} /> <FontAwesomeIcon icon={"filter"} size="lg" - style={{ cursor:"default", right: 20, padding: 1, left: 250, position: "relative", backgroundColor: this.filter ? "white" : "lightgray", color: this.filter ? "black" : "white" }} + style={{ cursor: "default", right: 20, padding: 1, left: 250, position: "relative", backgroundColor: this.filter ? "white" : "lightgray", color: this.filter ? "black" : "white" }} onPointerDown={e => { e.stopPropagation(); SetupDrag(this.collectionRef, () => StrCast(this.layoutDoc._searchString) ? this.startDragCollection() : undefined); }} onClick={action(() => { this.filter = !this.filter && !this.scale; |
