fix bug with remove button in search

This commit is contained in:
Matt Dunn-Rankin 2020-04-25 20:21:51 -07:00
parent 8866b6bca6
commit ce8142cdbe
3 changed files with 1 additions and 5 deletions

View file

@ -45,8 +45,8 @@ export function Item({ item, itemNameId, outfitState, dispatchToOutfit }) {
variant="ghost"
color="gray.400"
onClick={(e) => {
e.stopPropagation();
dispatchToOutfit({ type: "removeItem", itemId: item.id });
e.preventDefault();
}}
opacity="0"
transitionProperty="opacity color"

View file

@ -196,7 +196,6 @@ function SearchResults({
}
};
console.log(firstSearchResultRef);
return (
<ScrollTracker threshold={300} onScrolledToBottom={onScrolledToBottom}>
<ItemListContainer>
@ -211,7 +210,6 @@ function SearchResults({
ref={index === 0 ? firstSearchResultRef : null}
onChange={onChange}
onKeyDown={(e) => {
console.log(e.key);
if (e.key === "ArrowUp") {
goToPrevItem(e);
} else if (e.key === "ArrowDown") {

View file

@ -74,7 +74,6 @@ function SpeciesColorPicker({
if (allValidSpeciesColorPairs.has(pair)) {
dispatchToOutfit({ type: "changeColor", colorId: e.target.value });
} else {
console.log(pair, Array.from(allValidSpeciesColorPairs));
const species = allSpecies.find((s) => s.id === speciesId);
const color = allColors.find((c) => c.id === colorId);
toast({
@ -91,7 +90,6 @@ function SpeciesColorPicker({
if (allValidSpeciesColorPairs.has(pair)) {
dispatchToOutfit({ type: "changeSpecies", speciesId: e.target.value });
} else {
console.log(pair, Array.from(allValidSpeciesColorPairs));
const species = allSpecies.find((s) => s.id === speciesId);
const color = allColors.find((c) => c.id === colorId);
toast({