From 10aab49686760ad7b883246921a5a4882ef8ca40 Mon Sep 17 00:00:00 2001 From: Graeme Yeates Date: Fri, 28 Apr 2017 15:24:45 -0400 Subject: [PATCH] Add some basic documentation for some of the confusing less variables --- components/style/themes/default.less | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/components/style/themes/default.less b/components/style/themes/default.less index f11659d2fe..d17a852e49 100644 --- a/components/style/themes/default.less +++ b/components/style/themes/default.less @@ -7,10 +7,10 @@ unicode-range: U+30-39; } -// Prefix +// The prefix to use on all css classes from ant. @ant-prefix : ant; -// Color +// -------- Colors ----------- @primary-color : @blue-6; @info-color : @blue-6; @success-color : @green-6; @@ -19,19 +19,31 @@ @warning-color : @yellow-6; @normal-color : #d9d9d9; +// Color used by default to control hover and active backgrounds and for +// alert info backgrounds. @primary-1: color(~`colorPalette("@{primary-color}", 1)`); // replace tint(@primary-color, 90%) @primary-2: color(~`colorPalette("@{primary-color}", 2)`); // replace tint(@primary-color, 80%) +// unused @primary-3: color(~`colorPalette("@{primary-color}", 3)`); @primary-4: color(~`colorPalette("@{primary-color}", 4)`); +// Color used to control the text color in many active and hover states. @primary-5: color(~`colorPalette("@{primary-color}", 5)`); // replace tint(@primary-color, 20%) @primary-6: @primary-color; // don't use, use @primary-color +// Color used to control the text color of active buttons. @primary-7: color(~`colorPalette("@{primary-color}", 7)`); // replace shade(@primary-color, 5%) +// unused @primary-8: color(~`colorPalette("@{primary-color}", 8)`); +// unused @primary-9: color(~`colorPalette("@{primary-color}", 9)`); +// unused @primary-10: color(~`colorPalette("@{primary-color}", 10)`); -// ------ Base & Require ------ +// Base Scaffolding Variables +// --- + +// Background color for `` @body-background : #fff; +// Base background color for most components @component-background : #fff; @font-family : "Helvetica Neue For Number", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif; @code-family : Consolas, Menlo, Courier, monospace; @@ -84,8 +96,9 @@ @outline-width : 2px; @outline-color : @primary-color; -// Background color -@background-color-base : #f7f7f7; // basic gray background +// Default background color for disabled states, Collapse wrappers, +// and several active and hover states. +@background-color-base : #f7f7f7; // Shadow @shadow-color : rgba(0, 0, 0, .2);