Sfoglia il codice sorgente

fix: click tool item in app debug page would show detail (#2644)

tags/0.5.8
Joel 1 anno fa
parent
commit
3f640b1037
Nessun account collegato all'indirizzo email del committer
1 ha cambiato i file con 2 aggiunte e 1 eliminazioni
  1. 2
    1
      web/app/components/tools/tool-list/item.tsx

+ 2
- 1
web/app/components/tools/tool-list/item.tsx Vedi File

const language = getLanguage(locale) const language = getLanguage(locale)


const isBuiltIn = collection.type === CollectionType.builtIn const isBuiltIn = collection.type === CollectionType.builtIn
const canShowDetail = !isBuiltIn || (isBuiltIn && isInToolsPage)
const canShowDetail = isInToolsPage
const [showDetail, setShowDetail] = useState(false) const [showDetail, setShowDetail] = useState(false)
const addBtn = <Button className='shrink-0 flex items-center h-7 !px-3 !text-xs !font-medium !text-gray-700' disabled={added || !collection.is_team_authorization} onClick={() => onAdd?.(payload)}>{t(`common.operation.${added ? 'added' : 'add'}`)}</Button> const addBtn = <Button className='shrink-0 flex items-center h-7 !px-3 !text-xs !font-medium !text-gray-700' disabled={added || !collection.is_team_authorization} onClick={() => onAdd?.(payload)}>{t(`common.operation.${added ? 'added' : 'add'}`)}</Button>

return ( return (
<> <>
<div <div

Loading…
Annulla
Salva