aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/views/collections/collectionSchema/CollectionSchemaView.tsx')
-rw-r--r--src/client/views/collections/collectionSchema/CollectionSchemaView.tsx7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx b/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx
index 92cc58f54..f5422bce1 100644
--- a/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx
+++ b/src/client/views/collections/collectionSchema/CollectionSchemaView.tsx
@@ -791,9 +791,8 @@ export class CollectionSchemaView extends CollectionSubView() {
};
@action
- updateKeySearch = (e: React.ChangeEvent<HTMLInputElement>) => {
- this._menuValue = e.target.value;
- this._menuKeys = this.documentKeys.filter(value => value.toLowerCase().includes(this._menuValue.toLowerCase()));
+ updateKeySearch = (val: string) => {
+ this._menuKeys = this.documentKeys.filter(value => value.toLowerCase().includes(val.toLowerCase()));
};
getFieldFilters = (field: string) => StrListCast(this.Document._childFilters).filter(filter => filter.split(Doc.FilterSep)[0] === field);
@@ -920,7 +919,6 @@ export class CollectionSchemaView extends CollectionSubView() {
const x = this._columnMenuIndex! === -1 ? 0 : this.displayColumnWidths.reduce((total, curr, index) => total + (index < this._columnMenuIndex! ? curr : 0), CollectionSchemaView._rowMenuWidth);
return (
<div className="schema-column-menu" style={{ left: x, minWidth: CollectionSchemaView._minColWidth }}>
- <input className="schema-key-search-input" type="text" onKeyDown={this.onSearchKeyDown} onChange={this.updateKeySearch} onPointerDown={e => e.stopPropagation()} />
{this._makeNewField ? this.newFieldMenu : this.keysDropdown}
</div>
);
@@ -929,7 +927,6 @@ export class CollectionSchemaView extends CollectionSubView() {
get renderKeysMenu() {
return (
<div className="schema-column-menu" style={{ left: 0, minWidth: CollectionSchemaView._minColWidth }}>
- <input className="schema-key-search-input" type="text" onKeyDown={this.onSearchKeyDown} onChange={this.updateKeySearch} onPointerDown={e => e.stopPropagation()} />
{this._makeNewField ? this.newFieldMenu : this.keysDropdown}
</div>
);