Skip to content

Commit 17ba2c6

Browse files
Rody-Kirwanshockey
authored andcommitted
housekeeping: refactor color variable names and values (via #5420)
* housekeeping: update color variable names and values (via #5337) * Update operation colors, abstracted colors from element specific variables * Removed colors.scss * Typo ⚾ * Undefined var fix * revert operation color changes (for now) * fix whitespace
1 parent daf680c commit 17ba2c6

File tree

3 files changed

+79
-74
lines changed

3 files changed

+79
-74
lines changed

src/style/_colors.scss

Lines changed: 0 additions & 11 deletions
This file was deleted.

src/style/_variables.scss

Lines changed: 79 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,47 @@
1-
$gray-base: #000 !default;
2-
$white: #fff !default;
3-
$gray-50: #ebebeb !default;
4-
$gray-100: #d8dde7 !default;
5-
$gray-200: lighten($gray-base, 62.75%) !default; // #aaa
6-
$gray-300: lighten($gray-base, 56.5%) !default; // #999
7-
$gray-400: lighten($gray-base, 50%) !default; // #888
8-
$gray-500: lighten($gray-base, 43.75%) !default; // #777
9-
$gray-600: lighten($gray-base, 37.5%) !default; // #666
10-
$gray-650: lighten($gray-base, 33.3%) !default; // ##555555
11-
$gray-700: lighten($gray-base, 31.25%) !default; // #555
12-
$gray-800: lighten($gray-base, 25%) !default; // #444
13-
$gray-900: lighten($gray-base, 18.75%) !default; // #333
14-
15-
$gray-custom-1: #41444e !default;
16-
$gray-custom-2: #3b4151 !default;
1+
// Base Colours
2+
$black: #000;
3+
$white: #fff;
4+
$gray-50: lighten($black, 92%); //ebebeb
5+
$gray-200: lighten($black, 62.75%); // #a0a0a0
6+
$gray-300: lighten($black, 56.5%); // #909090
7+
$gray-400: lighten($black, 50%); // #808080
8+
$gray-500: lighten($black, 43.75%); // #707070
9+
$gray-600: lighten($black, 37.5%); // #606060
10+
$gray-650: lighten($black, 33.3%); // #555555
11+
$gray-700: lighten($black, 31.25%); // #505050
12+
$gray-800: lighten($black, 25%); // #404040
13+
$gray-900: lighten($black, 18.75%); // #303030
14+
15+
$cod-gray: #1b1b1b;
16+
$bright-gray: #3b4151;
17+
$mako-gray: #41444e;
18+
$waterloo-gray: #7d8492;
19+
$alto-gray: #d9d9d9;
20+
$mercury-gray: #e4e4e4;
21+
$concrete-gray: #e8e8e8;
22+
$alabaster: #f7f7f7;
23+
$apple-green: #62a03f;
24+
$green-haze: #009d77;
25+
$japanese-laurel: #008000;
26+
$persian-green: #00a0a7;
27+
$geyser-blue: #d8dde7;
28+
$dodger-blue: #1391ff;
29+
$endeavour-blue: #005dae;
30+
$scampi-purple: #55a;
31+
$electric-violet: #7300e5;
32+
$persian-red: #cf3030;
33+
$mango-tango: #e97500;
34+
35+
// Theme
1736

1837
$color-primary: #89bf04 !default;
1938
$color-secondary: #9012fe !default;
2039
$color-info: #4990e2 !default;
2140
$color-warning: #ff6060 !default;
2241
$color-danger: #f00 !default;
2342

43+
$color-primary-hover: lighten($color-primary, .5%) !default;
44+
2445
$_color-post: #49cc90 !default;
2546
$_color-get: #61affe !default;
2647
$_color-put: #fca130 !default;
@@ -30,10 +51,6 @@ $_color-patch: #50e3c2 !default;
3051
$_color-disabled: #ebebeb !default;
3152
$_color-options: #0d5aa7 !default;
3253

33-
$color-green: #008000 !default;
34-
35-
$color-primary-hover: #81b10c !default;
36-
3754
// Authorize
3855

3956
$auth-container-border-color: $gray-50 !default;
@@ -43,7 +60,7 @@ $auth-container-border-color: $gray-50 !default;
4360
$btn-background-color: transparent !default;
4461
$btn-border-color: $gray-400 !default;
4562
$btn-font-color: inherit !default;
46-
$btn-box-shadow-color: $gray-base !default;
63+
$btn-box-shadow-color: $black !default;
4764

4865
$btn-authorize-background-color: transparent !default;
4966
$btn-authorize-border-color: $_color-post !default;
@@ -71,89 +88,89 @@ $errors-wrapper-errors-small-font-color: $gray-600 !default;
7188

7289
// Form
7390

74-
$form-select-background-color: #f7f7f7 !default;
75-
$form-select-border-color: $gray-custom-1 !default;
76-
$form-select-box-shadow-color: $gray-base !default;
91+
$form-select-background-color: $alabaster !default;
92+
$form-select-border-color: $mako-gray !default;
93+
$form-select-box-shadow-color: $black !default;
7794

78-
$form-input-border-color: #d9d9d9 !default;
95+
$form-input-border-color: $alto-gray !default;
7996
$form-input-background-color: $white !default;
8097

8198
$form-textarea-background-color: $white !default;
8299
$form-textarea-focus-border-color: $_color-get !default;
83100

84-
$form-textarea-curl-background-color: $gray-custom-1 !default;
101+
$form-textarea-curl-background-color: $mako-gray !default;
85102
$form-textarea-curl-font-color: $white !default;
86103

87104
$form-checkbox-label-font-color: $gray-900 !default;
88-
$form-checkbox-background-color: #e8e8e8 !default;
89-
$form-checkbox-box-shadow-color: #e8e8e8 !default;
105+
$form-checkbox-background-color: $concrete-gray !default;
106+
$form-checkbox-box-shadow-color: $concrete-gray !default;
90107

91108
// Information
92109

93-
$info-code-background-color: $gray-base !default;
110+
$info-code-background-color: $black !default;
94111
$info-code-font-color: $_color-head !default;
95112

96113
$info-link-font-color: $color-info !default;
97114
$info-link-font-color-hover: $info-link-font-color !default;
98115

99-
$info-title-small-background-color: #7d8492 !default;
116+
$info-title-small-background-color: $waterloo-gray !default;
100117

101118
$info-title-small-pre-font-color: $white !default;
102119

103120
// Layout
104121

105-
$opblock-border-color: $gray-base !default;
106-
$opblock-box-shadow-color: $gray-base !default;
122+
$opblock-border-color: $black !default;
123+
$opblock-box-shadow-color: $black !default;
107124

108-
$opblock-tag-border-bottom-color: $gray-custom-2 !default;
109-
$opblock-tag-background-color-hover: $gray-base !default;
125+
$opblock-tag-border-bottom-color: $bright-gray !default;
126+
$opblock-tag-background-color-hover: $black !default;
110127

111128
$opblock-tab-header-tab-item-active-h4-span-after-background-color: $gray-400 !default;
112129

113-
$opblock-isopen-summary-border-bottom-color: $gray-base !default;
130+
$opblock-isopen-summary-border-bottom-color: $black !default;
114131

115132
$opblock-isopen-section-header-background-color: $white !default;
116-
$opblock-isopen-section-header-box-shadow-color: $gray-base !default;
133+
$opblock-isopen-section-header-box-shadow-color: $black !default;
117134

118-
$opblock-summary-method-background-color: $gray-base !default;
135+
$opblock-summary-method-background-color: $black !default;
119136
$opblock-summary-method-font-color: $white !default;
120-
$opblock-summary-method-text-shadow-color: $gray-base !default;
137+
$opblock-summary-method-text-shadow-color: $black !default;
121138

122-
$operational-filter-input-border-color: #d8dde7 !default;
139+
$operational-filter-input-border-color: $geyser-blue !default;
123140

124-
$tab-list-item-first-background-color: $gray-base !default;
141+
$tab-list-item-first-background-color: $black !default;
125142

126143
$response-col-status-undocumented-font-color: $gray-300 !default;
127144

128145
$response-col-links-font-color: $gray-300 !default;
129146

130-
$opblock-body-background-color: $gray-custom-1 !default;
147+
$opblock-body-background-color: $mako-gray !default;
131148
$opblock-body-font-color: $white !default;
132149

133150
$scheme-container-background-color: $white !default;
134-
$scheme-container-box-shadow-color: $gray-base !default;
151+
$scheme-container-box-shadow-color: $black !default;
135152

136153
$server-container-background-color: $white !default;
137-
$server-container-box-shadow-color: $gray-base !default;
154+
$server-container-box-shadow-color: $black !default;
138155

139156
$server-container-computed-url-code-font-color: $gray-400 !default;
140157

141158
$loading-container-before-border-color: $gray-650 !default;
142-
$loading-container-before-border-top-color: $gray-base !default;
159+
$loading-container-before-border-top-color: $black !default;
143160

144-
$response-content-type-controls-accept-header-select-border-color: $color-green !default;
145-
$response-content-type-controls-accept-header-small-font-color: $color-green !default;
161+
$response-content-type-controls-accept-header-select-border-color: $japanese-laurel !default;
162+
$response-content-type-controls-accept-header-small-font-color: $japanese-laurel !default;
146163

147164
// Modal
148165

149-
$dialog-ux-backdrop-background-color: $gray-base !default;
166+
$dialog-ux-backdrop-background-color: $black !default;
150167

151168

152169
$dialog-ux-modal-background-color: $white !default;
153170
$dialog-ux-modal-border-color: $gray-50 !default;
154-
$dialog-ux-modal-box-shadow-color: $gray-base !default;
171+
$dialog-ux-modal-box-shadow-color: $black !default;
155172

156-
$dialog-ux-modal-content-font-color: $gray-custom-1 !default;
173+
$dialog-ux-modal-content-font-color: $mako-gray !default;
157174

158175
$dialog-ux-modal-header-border-bottom-color: $gray-50 !default;
159176

@@ -162,30 +179,30 @@ $dialog-ux-modal-header-border-bottom-color: $gray-50 !default;
162179
$model-deprecated-font-color: $gray-200 !default;
163180

164181
$model-hint-font-color: $gray-50 !default;
165-
$model-hint-background-color: $gray-base !default;
182+
$model-hint-background-color: $black !default;
166183

167-
$section-models-border-color: $gray-custom-2 !default;
184+
$section-models-border-color: $bright-gray !default;
168185

169186
$section-models-isopen-h4-border-bottom-color: $section-models-border-color !default;
170187

171188
$section-models-h4-font-color: $gray-600 !default;
172-
$section-models-h4-background-color-hover: $gray-base !default;
189+
$section-models-h4-background-color-hover: $black !default;
173190

174191
$section-models-h5-font-color: $gray-500 !default;
175192

176-
$section-models-model-container-background-color: $gray-base !default;
193+
$section-models-model-container-background-color: $black !default;
177194

178-
$section-models-model-box-background-color: $gray-base !default;
195+
$section-models-model-box-background-color: $black !default;
179196

180197
$section-models-model-title-font-color: $gray-700 !default;
181198

182-
$prop-type-font-color: #55a !default;
199+
$prop-type-font-color: $scampi-purple !default;
183200

184201
$prop-format-font-color: $gray-600 !default;
185202

186203
// Tables
187204

188-
$table-thead-td-border-bottom-color: $gray-custom-2 !default;
205+
$table-thead-td-border-bottom-color: $bright-gray !default;
189206

190207
$table-parameter-name-required-font-color: $color-danger !default;
191208

@@ -195,17 +212,17 @@ $table-parameter-deprecated-font-color: $color-danger !default;
195212

196213
// Topbar
197214

198-
$topbar-background-color: #1b1b1b !default;
215+
$topbar-background-color: $cod-gray !default;
199216

200217
$topbar-link-font-color: $white !default;
201218

202-
$topbar-download-url-wrapper-element-border-color: #62A03F !default;
219+
$topbar-download-url-wrapper-element-border-color: $apple-green !default;
203220

204-
$topbar-download-url-button-background-color: #62A03F !default;
221+
$topbar-download-url-button-background-color: $apple-green !default;
205222
$topbar-download-url-button-font-color: $white !default;
206223

207224
// Type
208225

209-
$text-body-default-font-color: $gray-custom-2 !default;
210-
$text-code-default-font-color: $gray-custom-2 !default;
211-
$text-headline-default-font-color: $gray-custom-2 !default;
226+
$text-body-default-font-color: $bright-gray !default;
227+
$text-code-default-font-color: $bright-gray !default;
228+
$text-headline-default-font-color: $bright-gray !default;

src/style/main.scss

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
@import '~tachyons-sass/tachyons.scss';
44
@import 'mixins';
55
@import 'variables';
6-
@import 'colors';
76
@import 'type';
87
@import 'layout';
98
@import 'buttons';

0 commit comments

Comments
 (0)