diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.publisher.ui/src/main/resources/publisher/public/themes/default/chip.css b/components/application-mgt/org.wso2.carbon.device.application.mgt.publisher.ui/src/main/resources/publisher/public/themes/default/chip.css deleted file mode 100644 index d52e34b9f2e..00000000000 --- a/components/application-mgt/org.wso2.carbon.device.application.mgt.publisher.ui/src/main/resources/publisher/public/themes/default/chip.css +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (c) 2017, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. - * - * WSO2 Inc. licenses this file to you under the Apache License, - * Version 2.0 (the "License"); you may not use this file except - * in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ - -.chip { - display: inline-block; - padding: 0 25px; - height: 50px; - font-size: 16px; - line-height: 50px; - border-radius: 25px; - background-color: #f1f1f1; -} - -.chip img { - float: left; - margin: 0 10px 0 -25px; - height: 50px; - width: 50px; - border-radius: 50%; -} - -.close-btn { - padding-left: 10px; - color: #888; - font-weight: bold; - float: right; - font-size: 20px; - cursor: pointer; -} - -.close-btn:hover { - color: #000; -} \ No newline at end of file diff --git a/components/application-mgt/org.wso2.carbon.device.application.mgt.publisher.ui/src/main/resources/publisher/src/components/UIComponents/Chip/Chip.jsx b/components/application-mgt/org.wso2.carbon.device.application.mgt.publisher.ui/src/main/resources/publisher/src/components/UIComponents/Chip/Chip.jsx index d614564b614..957686b4c3a 100644 --- a/components/application-mgt/org.wso2.carbon.device.application.mgt.publisher.ui/src/main/resources/publisher/src/components/UIComponents/Chip/Chip.jsx +++ b/components/application-mgt/org.wso2.carbon.device.application.mgt.publisher.ui/src/main/resources/publisher/src/components/UIComponents/Chip/Chip.jsx @@ -16,20 +16,36 @@ * under the License. */ +import PropTypes from 'prop-types'; import React, {Component} from 'react'; import './chip.css'; class Chip extends Component { + constructor() { + super(); + this.onDeleteClick = this.onDeleteClick.bind(this); + } + + onDeleteClick() { + this.props.onDelete(this.props.content.key); + } + render() { return (