| /* |
| * Licensed to the Apache Software Foundation (ASF) under one |
| * or more contributor license agreements. See the NOTICE file |
| * distributed with this work for additional information |
| * regarding copyright ownership. The ASF licenses this file |
| * to you under the Apache License, Version 2.0 (the |
| * "License"); you may not use this file except in compliance |
| * with the License. You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, |
| * software distributed under the License is distributed on an |
| * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| * KIND, either express or implied. See the License for the |
| * specific language governing permissions and limitations |
| * under the License. |
| */ |
| .palette(@primary, @accent) { |
| @primary-5: mix(white, @primary, 95%); |
| @primary-10: mix(white, @primary, 90%); |
| @primary-20: mix(white, @primary, 80%); |
| @primary-30: mix(white, @primary, 70%); |
| @primary-40: mix(white, @primary, 60%); |
| @primary-50: mix(white, @primary, 50%); |
| @primary-100: mix(white, @primary, 40%); |
| @primary-200: mix(white, @primary, 30%); |
| @primary-300: mix(white, @primary, 20%); |
| @primary-400: mix(white, @primary, 10%); |
| @primary-500: @primary; |
| @primary-600: mix(black, @primary, 10%); |
| @primary-700: mix(black, @primary, 20%); |
| @primary-800: mix(black, @primary, 30%); |
| @primary-900: mix(black, @primary, 40%); |
| |
| @accent-5: mix(white, @accent, 95%); |
| @accent-10: mix(white, @accent, 90%); |
| @accent-20: mix(white, @accent, 80%); |
| @accent-30: mix(white, @accent, 70%); |
| @accent-40: mix(white, @accent, 60%); |
| @accent-50: mix(white, @accent, 50%); |
| @accent-100: mix(white, @accent, 40%); |
| @accent-200: mix(white, @accent, 30%); |
| @accent-300: mix(white, @accent, 20%); |
| @accent-400: mix(white, @accent, 10%); |
| @accent-500: @accent; |
| @accent-600: mix(black, @accent, 10%); |
| @accent-700: mix(black, @accent, 20%); |
| @accent-800: mix(black, @accent, 30%); |
| @accent-900: mix(black, @accent, 40%); |
| } |
| |
| .monospace() { |
| font-family: Courier, monospace; |
| font-size: 95%; |
| } |
| |
| .make-icon(@size) { |
| // this won't _increase_ size, that's more complicated. but it will cap both sizes while |
| // keeping aspect ratio. if width or height are set they can interfere with the maxes to screw up aspect ratio. |
| // https://stackoverflow.com/questions/12912048/how-to-maintain-aspect-ratio-using-html-img-tag |
| width: auto; |
| height: auto; |
| max-width: @size; |
| max-height: @size; |
| // and center |
| margin: auto; |
| } |
| |