parent
81e1ebe7c1
commit
856838ba55
@ -0,0 +1,23 @@ |
||||
import React, { useState } from 'react' |
||||
|
||||
interface ButtonProps { |
||||
profileName: string |
||||
deactivatePlugin?: (name: string) => {} |
||||
activatePlugin?: (name: string) => {} |
||||
buttonText?: string |
||||
} |
||||
|
||||
function Button ({ profileName, deactivatePlugin, buttonText }: ButtonProps) { |
||||
const [isActive, toggleIsActive] = useState(false) |
||||
const dataId = `pluginManagerComponentDeactivateButton${profileName}` |
||||
|
||||
return ( |
||||
<button |
||||
onClick={() => deactivatePlugin(profileName)} |
||||
className="btn btn-secondary btn-sm" |
||||
data-id={dataId} |
||||
> |
||||
{buttonText} |
||||
</button> |
||||
) |
||||
} |
Loading…
Reference in new issue