diff options
author | madelinegr <monika_hedman@brown.edu> | 2019-06-18 15:29:22 -0400 |
---|---|---|
committer | madelinegr <monika_hedman@brown.edu> | 2019-06-18 15:29:22 -0400 |
commit | 5469707d07254b5895c2188846c0e35b6d776ab0 (patch) | |
tree | 41c741f915424407bf6c15913d01f28353b82fa7 /src | |
parent | edd13df1072307b20c3e1a07fa9c5d4f928c62bc (diff) |
almost there
Diffstat (limited to 'src')
-rw-r--r-- | src/client/views/search/IconBar.tsx | 31 |
1 files changed, 3 insertions, 28 deletions
diff --git a/src/client/views/search/IconBar.tsx b/src/client/views/search/IconBar.tsx index b4656f4c5..f343ec13f 100644 --- a/src/client/views/search/IconBar.tsx +++ b/src/client/views/search/IconBar.tsx @@ -40,12 +40,10 @@ export class IconBar extends React.Component<IconBarProps> { allIcons: string[] = [DocTypes.AUDIO, DocTypes.COL, DocTypes.HIST, DocTypes.IMG, DocTypes.LINK, DocTypes.PDF, DocTypes.TEXT, DocTypes.VID, DocTypes.WEB]; @observable typesToFind: string[]; - // @observable selectedItems: string[] = []; @observable public ResetClicked: boolean = false; @observable public SelectAllClicked: boolean = false; public Reset: number = 0; public Select: number = 0; - // @observable activeType = "none"; constructor(props: IconBarProps) { super(props); @@ -61,44 +59,21 @@ export class IconBar extends React.Component<IconBarProps> { @action.bound updateList(newList: string[]) { this.typesToFind = newList; + console.log(newList) } @action.bound resetSelf = () => { this.ResetClicked = true; - this.typesToFind = []; - // this.selectedItems = []; - // this.activeType = "none"; - // console.log("resetting") + this.updateList([]); } @action.bound selectAll = () => { this.SelectAllClicked = true; - this.typesToFind = this.allIcons; + this.updateList(this.allIcons); } - // @action.bound - // getActiveType() { - // return this.activeType; - // } - - // @action.bound - // updateActiveType(type: string) { - // this.resetSelf(); - // this.activeType = type; - // } - - // @action.bound - // updateSelectedList(type: string){ - // if(this.selectedItems.indexOf(type) === -1){ - // this.selectedItems.push(type); - // } - // else{ - // _.pull(this.selectedItems, type); - // } - // } - render() { return ( <div> |