storj.io/minio@v0.0.0-20230509071714-0cbc90f649b1/browser/app/less/inc/mixin.less (about)

     1  /*--------------------------
     2      User Select
     3  ----------------------------*/
     4  .user-select(@value) {
     5      -webkit-user-select: @value;
     6      -moz-user-select: @value;
     7      -ms-user-select: @value;
     8      user-select: @value; 
     9  }
    10  
    11  
    12  /*----------------------------------------
    13      CSS Animations based on animate.css
    14  -----------------------------------------*/
    15  .animated(@name, @duration) {
    16      -webkit-animation-name: @name;
    17      animation-name: @name;
    18      -webkit-animation-duration: @duration;
    19      animation-duration: @duration;
    20      -webkit-animation-fill-mode: both;
    21      animation-fill-mode: both;
    22  }
    23  
    24  /*-------------------------------------------------
    25      For loop mixin for generate custom classes
    26  --------------------------------------------------*/
    27  .for(@i, @n) {.-each(@i)}
    28  .for(@n)     when (isnumber(@n)) {.for(1, @n)}
    29  .for(@i, @n) when not (@i = @n)  {
    30      .for((@i + (@n - @i) / abs(@n - @i)), @n);
    31  }
    32  
    33  .for(@array)   when (default()) {.for-impl_(length(@array))}
    34  .for-impl_(@i) when (@i > 1)    {.for-impl_((@i - 1))}
    35  .for-impl_(@i) when (@i > 0)    {.-each(extract(@array, @i))}
    36  
    37  /*----------------------------------------
    38      List Loader
    39  -----------------------------------------*/
    40  .list-loader(@width, @height, @borderColor, @borderColorBottom) {
    41      content: '';
    42      width: @width;
    43      height: @height;
    44      border-radius: 50%;
    45      .animated(zoomIn, 500ms);
    46      border: 2px solid @borderColor;
    47      border-bottom-color: @borderColorBottom;
    48      position: absolute;
    49      z-index: 1;
    50      -webkit-animation: zoomIn 250ms, spin 700ms 250ms infinite linear;
    51      animation: zoomIn 250ms, spin 700ms 250ms infinite linear;
    52  }
    53  
    54  /*----------------------------------------
    55      Placeholder
    56  -----------------------------------------*/
    57  .placeholder(@color) {
    58      ::-webkit-input-placeholder { color: @color }
    59      ::-moz-placeholder { color: @color }
    60      :-ms-input-placeholder { color: @color }
    61  }