Created
February 1, 2017 18:04
-
-
Save nesbtesh/4b949127e9ac899531a2692782b0433d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import {parseUri} from "../../../utils"; | |
const AutocompleteItem = (props) => { | |
const {props} = this; | |
const selectedClass = props.selected === true ? "selected" : ""; | |
var path = parseUri(props.url).path; | |
path = path.length <= 0 ? props.url : "..." + path; | |
return ( | |
<li | |
onMouseLeave={props.onMouseLeave} | |
className={selectedClass}> | |
<i className="ion-ios-eye" | |
data-image={props.image} | |
data-url={props.url} | |
data-title={props.title} | |
onClick={props.handlePlanetViewClick} /> | |
<span | |
onMouseEnter={props.onMouseEnter} | |
> | |
<div className="dot bg-mint" /> | |
{path} | |
</span> | |
</li> | |
); | |
} | |
export default AutocompleteItem |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment