a tool for shared writing and social publishing

don't nest buttons

+7 -4
+7 -4
components/Mention.tsx
··· 133 133 134 134 if (!mentionCoords || suggestions.length === 0) return null; 135 135 136 - 137 136 const getHeader = (type: Mention["type"]) => { 138 137 switch (type) { 139 138 case "did": ··· 277 276 children: React.ReactNode; 278 277 }) => { 279 278 return ( 280 - <button 281 - className="flex flex-row shrink-0 text-xs font-normal text-tertiary hover:text-accent-contrast" 279 + <span 280 + className="flex flex-row shrink-0 text-xs font-normal text-tertiary hover:text-accent-contrast cursor-pointer" 282 281 onClick={(e) => { 283 282 e.preventDefault(); 284 283 e.stopPropagation(); 285 284 props.onClick(); 286 285 }} 286 + onMouseDown={(e) => { 287 + e.preventDefault(); 288 + e.stopPropagation(); 289 + }} 287 290 > 288 291 {props.children} <ArrowRightTiny className="scale-80" /> 289 - </button> 292 + </span> 290 293 ); 291 294 }; 292 295