Remove disabled clear button from tag panel + dead code
This commit is contained in:
parent
bbd343f414
commit
3c176f762e
2 changed files with 0 additions and 40 deletions
|
@ -30,25 +30,6 @@ limitations under the License.
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
.mx_TagPanel .mx_TagPanel_clearButton_container {
|
|
||||||
/* Constant height within flex mx_TagPanel */
|
|
||||||
height: 70px;
|
|
||||||
width: 56px;
|
|
||||||
|
|
||||||
flex: none;
|
|
||||||
|
|
||||||
justify-content: center;
|
|
||||||
align-items: flex-start;
|
|
||||||
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.mx_TagPanel .mx_TagPanel_clearButton object {
|
|
||||||
/* Same as .mx_SearchBox padding-top */
|
|
||||||
margin-top: 24px;
|
|
||||||
pointer-events: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.mx_TagPanel .mx_TagPanel_divider {
|
.mx_TagPanel .mx_TagPanel_divider {
|
||||||
height: 0px;
|
height: 0px;
|
||||||
width: 90%;
|
width: 90%;
|
||||||
|
|
|
@ -95,11 +95,6 @@ const TagPanel = createReactClass({
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onCreateGroupClick(ev) {
|
|
||||||
ev.stopPropagation();
|
|
||||||
dis.dispatch({action: 'view_create_group'});
|
|
||||||
},
|
|
||||||
|
|
||||||
onClearFilterClick(ev) {
|
onClearFilterClick(ev) {
|
||||||
dis.dispatch({action: 'deselect_tags'});
|
dis.dispatch({action: 'deselect_tags'});
|
||||||
},
|
},
|
||||||
|
@ -117,9 +112,7 @@ const TagPanel = createReactClass({
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const DNDTagTile = sdk.getComponent('elements.DNDTagTile');
|
const DNDTagTile = sdk.getComponent('elements.DNDTagTile');
|
||||||
const AccessibleButton = sdk.getComponent('elements.AccessibleButton');
|
|
||||||
const ActionButton = sdk.getComponent('elements.ActionButton');
|
const ActionButton = sdk.getComponent('elements.ActionButton');
|
||||||
const TintableSvg = sdk.getComponent('elements.TintableSvg');
|
|
||||||
|
|
||||||
const tags = this.state.orderedTags.map((tag, index) => {
|
const tags = this.state.orderedTags.map((tag, index) => {
|
||||||
return <DNDTagTile
|
return <DNDTagTile
|
||||||
|
@ -131,17 +124,6 @@ const TagPanel = createReactClass({
|
||||||
});
|
});
|
||||||
|
|
||||||
const itemsSelected = this.state.selectedTags.length > 0;
|
const itemsSelected = this.state.selectedTags.length > 0;
|
||||||
|
|
||||||
let clearButton;
|
|
||||||
if (itemsSelected) {
|
|
||||||
clearButton = <AccessibleButton className="mx_TagPanel_clearButton" onClick={this.onClearFilterClick}>
|
|
||||||
<TintableSvg src={require("../../../res/img/icons-close.svg")} width="24" height="24"
|
|
||||||
alt={_t("Clear filter")}
|
|
||||||
title={_t("Clear filter")}
|
|
||||||
/>
|
|
||||||
</AccessibleButton>;
|
|
||||||
}
|
|
||||||
|
|
||||||
const classes = classNames('mx_TagPanel', {
|
const classes = classNames('mx_TagPanel', {
|
||||||
mx_TagPanel_items_selected: itemsSelected,
|
mx_TagPanel_items_selected: itemsSelected,
|
||||||
});
|
});
|
||||||
|
@ -165,9 +147,6 @@ const TagPanel = createReactClass({
|
||||||
}
|
}
|
||||||
|
|
||||||
return <div className={classes} onClick={this.onClearFilterClick}>
|
return <div className={classes} onClick={this.onClearFilterClick}>
|
||||||
<div className="mx_TagPanel_clearButton_container">
|
|
||||||
{ clearButton }
|
|
||||||
</div>
|
|
||||||
<AutoHideScrollbar
|
<AutoHideScrollbar
|
||||||
className="mx_TagPanel_scroller"
|
className="mx_TagPanel_scroller"
|
||||||
// XXX: Use onMouseDown as a workaround for https://github.com/atlassian/react-beautiful-dnd/issues/273
|
// XXX: Use onMouseDown as a workaround for https://github.com/atlassian/react-beautiful-dnd/issues/273
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue