diff options
Diffstat (limited to 'src/client/views/KeywordBox.tsx')
-rw-r--r-- | src/client/views/KeywordBox.tsx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/client/views/KeywordBox.tsx b/src/client/views/KeywordBox.tsx index 8c69f446d..d94f011f4 100644 --- a/src/client/views/KeywordBox.tsx +++ b/src/client/views/KeywordBox.tsx @@ -39,6 +39,7 @@ export class KeywordItem extends ObservableReactComponent<KeywordItemProps> { removeLabel = () => { if (this._props.doc[DocData].data_labels) { this._props.doc[DocData].data_labels = (this._props.doc[DocData].data_labels as List<string>).filter(label => label !== this._props.label) as List<string>; + this._props.doc![DocData][`${this._props.label}`] = false; } }; @@ -103,6 +104,7 @@ export class KeywordBox extends ObservableReactComponent<KeywordBoxProps> { } (this._props.doc![DocData].data_labels! as List<string>).push(this._currentInput.trim()); + this._props.doc![DocData][`${this._currentInput}`] = true; this._currentInput = ''; // Clear the input box } }; |