/**
* DevExtreme (widgets/generic/numberBox.generic.less)
* Version: 19.2.6
* Build date: Thu Jan 30 2020
*
* Copyright (c) 2012 - 2020 Developer Express Inc. ALL RIGHTS RESERVED
* Read about DevExtreme licensing here: https://js.devexpress.com/Licensing/
*/
@import (once) "./textEditor.generic.less";

.dx-size-default() {
    @GENERIC_NUMBERBOX_SPIN_CONTAINER_WIDTH: 34px;
    @GENERIC_NUMBERBOX_SPIN_PADDING: 1px;
    @GENERIC_NUMBERBOX_TOUCH_FRIENDLY_SPIN_CONTAINER_WIDTH: 74px;
    @GENERIC_NUMBERBOX_CLEAR_BUTTON_AREA_WIDTH: 32px;
}
.dx-size-compact() {
    @GENERIC_NUMBERBOX_SPIN_CONTAINER_WIDTH: 20px;
    @GENERIC_NUMBERBOX_SPIN_PADDING: 1px;
    @GENERIC_NUMBERBOX_TOUCH_FRIENDLY_SPIN_CONTAINER_WIDTH: 60px;
    @GENERIC_NUMBERBOX_CLEAR_BUTTON_AREA_WIDTH: 20px;
}


.dx-numberbox-spin-container {
    overflow: hidden;
    width: @GENERIC_NUMBERBOX_SPIN_CONTAINER_WIDTH;
    border-radius: @numberbox-spin-container-border-radius;
}

.dx-numberbox-spin-up-icon {
    .dx-icon-spinup;

    color: @numberbox-spin-icon-color;
}

.dx-numberbox-spin-down-icon {
    .dx-icon-spindown;

    color: @numberbox-spin-icon-color;
}

.dx-numberbox-spin-up-icon,
.dx-numberbox-spin-down-icon {
    .dx-icon-font-centered-sizing(@GENERIC_BASE_ICON_SIZE);

    border-radius: @numberbox-spin-icon-border-radius;
}

.dx-numberbox-spin-button {
    padding: @GENERIC_NUMBERBOX_SPIN_PADDING;

    .dx-editor-underlined & {
        background: @texteditor-underlined-bg;
    }
}

.dx-state-hover {
    &.dx-numberbox-spin-button {
        .dx-numberbox-spin-down-icon,
        .dx-numberbox-spin-up-icon {
            box-shadow: 0 0 0 1px @numberbox-spin-hover-border-color inset;
            background-color: @numberbox-spin-hover-bg;
        }
    }
}

.dx-state-active {
    &.dx-numberbox-spin-button {
        .dx-numberbox-spin-down-icon,
        .dx-numberbox-spin-up-icon {
            background-color: @numberbox-spin-active-bg;
            color: @numberbox-spin-active-color;
        }
    }
}

.dx-numberbox-spin-touch-friendly {
    .dx-numberbox-spin-container {
        width: @GENERIC_NUMBERBOX_TOUCH_FRIENDLY_SPIN_CONTAINER_WIDTH;
        border-left: none;
    }

    .dx-numberbox-spin-up-icon,
    .dx-numberbox-spin-down-icon {
        background-position: center;
    }
}


.dx-rtl .dx-numberbox,
.dx-numberbox.dx-rtl {
    &.dx-numberbox-spin-touch-friendly {
        .dx-numberbox-spin-container {
            border-right: none;
        }
    }

    &.dx-numberbox-spin {
        .dx-texteditor-input {
            padding-right: @GENERIC_BASE_INLINE_BORDEREDWIDGET_HORIZONTAL_PADDING;
        }
    }
}
