/**
 * Copyright (c) 2015 Bosch Software Innovations GmbH and others.
 *
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 */
// scss-lint:disable ImportantRule, PropertySortOrder

$generic-text-font-size: $generic-text-font-scale * $v-font-size;

@mixin button-icon-size {
  height: 15px !important;
  width: 15px !important;
}

@mixin space-btwn-tag-buttons {
  .v-spacing {
    width: 12px;
    height: 6px;
  }
}

@mixin generic-styles {

  //Generic text style used in table details,search text style ,combo text style etc
  .text-style {
    font: 300 $generic-text-font-size $app-font-family !important;
  }

  .text-bold {
    font-weight: bold !important;
  }

  .text-cut {
    white-space: nowrap;
    text-overflow: ellipsis;
    -o-text-overflow: ellipsis;
    -icab-text-overflow: ellipsis;
    -khtml-text-overflow: ellipsis;
    -moz-text-overflow: ellipsis;
    -webkit-text-overflow: ellipsis;
    overflow: hidden;
  }

  .icon-only {
    height: 15px !important;
    width: 15px !important;
    color: $button-icon-color;
    margin-bottom: 6px !important;
    margin-right: 6px !important;
  }

  .icon-only:focus:after {
    border-color: none !important;
    box-shadow: none !important;
  }

  //Buttons with no border
  .button-no-border:focus:after {
    border-color: none !important;
    box-shadow: none !important;
  }

  //Custom text are height
  .text-area-style {
    height: 75px !important;
  }

  //Style to highlight the textfield on any validation error
  .textfield-error {
    color: $red-color;
  }

  //Style to highlight the combobox on any validation error
  .v-filterselect-combobox-error .v-filterselect-input {
    border-color: $red-color !important;
  }

  .v-table-row-drag-top td:first-child:before,
  .v-table-row-drag-bottom td:first-child:after {
    display: none !important;
  }

  .v-table-drag .v-table-body {
    box-shadow: none;
    border: 1px solid $widget-border-color;
  }

  .v-Notification .v-icon {
    margin-right: 10px;
    vertical-align: middle;
  }

  .v-Notification-error .v-icon {
    color: white;
  }

  .v-Notification-warning .v-icon {
	color: orange;
  }

  .v-Notification-success .v-icon {
	color: green;
  }

  .avoid-tooltip {
    pointer-events: none !important;
  }

  //This was needed to make the split of prefix "Artifact details of" / "Metadata of"
  //and the actual value "entityName:entityVersion" in context of the XSS vulnerabilities
  //possible after changing ContentMode from HTML to TEXT. As no Labels are allowed
  //at the windows caption field, decision was made to use the methods
  //Window.setAssistivePrefix() and Window.setAssistivePostfix() to solve the XSS-problem.
  //Both, assistive postfix and prefix are usually not visible on the page and only for
  //assistive purpose, but with overwriting this third party html class it's a possible
  //workaround for the XSS vulnerability.
  .v-assistive-device-only {
    position: static;
    top: auto;
    left: auto;
    width: auto;
    overflow: visible;
  }

  .v-panel,
  .v-textfield {
    background: $widget-bg;
  }

  .v-table,
  .v-table-table {
    background: transparent;
  }
}