HEX
Server: LiteSpeed
System: Linux premium212.web-hosting.com 4.18.0-553.124.4.lve.el8.x86_64 #1 SMP Fri May 15 13:02:13 UTC 2026 x86_64
User: vitanhod (1367)
PHP: 8.2.31
Disabled: NONE
Upload Files
File: //home/vitanhod/barnabites.es/wp-content/plugins/rishi-companion/src/admin/ui-components/Button.js
import styled from "@emotion/styled"

const ButtonItem = styled.button`
    @keyframes spin{to {transform: rotate(360deg)}}
    font-size: 14px;
    font-weight: 600;
    color: #637279;
    padding: 10px 24px;
    border: 1px solid #D0D5DD;
    transition: all .2s ease;
    cursor: pointer;
    background: none;
    border-radius: 8px;
    text-align: center;
    &:hover{
        background-color: #307AC9;
        color: #ffffff;
    }
    ${props => props.isLoading && (
        `
        pointer-events: none;
        opacity: .5;
        &::after{
            display: inline-block;
            vertical-align: middle;
            content: "";
            width: 1em;
            height: 1em;
            border-radius: 50%;
            border: 2px solid rgba(0, 0, 0, .2);
            border-top-color: currentColor;
            margin-left: 4px;
            animation: spin infinite .5s linear;
        }`
    )
    }
`

const Button = ({ children, ...rest }) => {
    return (
        <ButtonItem {...rest}>
            {children}
        </ButtonItem>
    )
}

export default Button