(api: TuiPluginApi, item: TuiPluginStatus)
| 9 | const id = "internal:plugin-manager" |
| 10 | |
| 11 | function state(api: TuiPluginApi, item: TuiPluginStatus) { |
| 12 | if (!item.enabled) { |
| 13 | return <span style={{ fg: api.theme.current.textMuted }}>disabled</span> |
| 14 | } |
| 15 | |
| 16 | return ( |
| 17 | <span style={{ fg: item.active ? api.theme.current.success : api.theme.current.error }}> |
| 18 | {item.active ? "active" : "inactive"} |
| 19 | </span> |
| 20 | ) |
| 21 | } |
| 22 | |
| 23 | function source(spec: string) { |
| 24 | if (!spec.startsWith("file://")) return |