hux 0.0.0 → 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (73) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +8 -0
  3. data/.hound.yml +5 -0
  4. data/.ruby-version +1 -0
  5. data/.scss-lint.yml +249 -0
  6. data/CHANGELOG.md +4 -0
  7. data/CODE_OF_CONDUCT.md +6 -0
  8. data/Gemfile +3 -0
  9. data/Gulpfile.js +34 -0
  10. data/LICENSE.md +21 -0
  11. data/README.md +1 -0
  12. data/RELEASING.md +21 -0
  13. data/Rakefile +8 -0
  14. data/bin/hux +5 -0
  15. data/circle.yml +7 -0
  16. data/contrib/index.html +1 -0
  17. data/contrib/styles.scss +19 -0
  18. data/core/_base.scss +9 -0
  19. data/core/_generic.scss +152 -0
  20. data/core/_helpers.scss +349 -0
  21. data/core/_minireset.scss +92 -0
  22. data/core/components/_all.scss +15 -0
  23. data/core/components/_breadcrumb.scss +116 -0
  24. data/core/components/_card.scss +77 -0
  25. data/core/components/_dropdown.scss +84 -0
  26. data/core/components/_level.scss +119 -0
  27. data/core/components/_media.scss +64 -0
  28. data/core/components/_menu.scss +72 -0
  29. data/core/components/_message.scss +118 -0
  30. data/core/components/_modal.scss +132 -0
  31. data/core/components/_nav.scss +173 -0
  32. data/core/components/_navbar.scss +441 -0
  33. data/core/components/_pagination.scss +188 -0
  34. data/core/components/_panel.scss +135 -0
  35. data/core/components/_tabs.scss +206 -0
  36. data/core/elements/_all.scss +14 -0
  37. data/core/elements/_box.scss +30 -0
  38. data/core/elements/_button.scss +290 -0
  39. data/core/elements/_container.scss +44 -0
  40. data/core/elements/_content.scss +224 -0
  41. data/core/elements/_form.scss +935 -0
  42. data/core/elements/_icon.scss +28 -0
  43. data/core/elements/_image.scss +56 -0
  44. data/core/elements/_notification.scss +53 -0
  45. data/core/elements/_other.scss +48 -0
  46. data/core/elements/_progress.scss +56 -0
  47. data/core/elements/_table.scss +148 -0
  48. data/core/elements/_tag.scss +132 -0
  49. data/core/elements/_title.scss +81 -0
  50. data/core/grid/_all.scss +2 -0
  51. data/core/grid/_columns.scss +577 -0
  52. data/core/grid/_tiles.scss +53 -0
  53. data/core/layout/_all.scss +3 -0
  54. data/core/layout/_footer.scss +6 -0
  55. data/core/layout/_hero.scss +257 -0
  56. data/core/layout/_section.scss +19 -0
  57. data/core/utilities/_all.scss +6 -0
  58. data/core/utilities/_animations.scss +9 -0
  59. data/core/utilities/_controls.scss +51 -0
  60. data/core/utilities/_derived-variables.scss +81 -0
  61. data/core/utilities/_functions.scss +46 -0
  62. data/core/utilities/_initial-variables.scss +68 -0
  63. data/core/utilities/_mixins.scss +301 -0
  64. data/core/utilities/_variables.scss +153 -0
  65. data/hux.gemspec +31 -0
  66. data/lib/hux/generator.rb +80 -0
  67. data/lib/hux/version.rb +3 -0
  68. data/lib/hux.rb +1 -1
  69. data/package.json +33 -0
  70. data/spec/bitters_spec.rb +17 -0
  71. data/spec/fixtures/application.scss +2 -0
  72. data/spec/spec_helper.rb +3 -0
  73. metadata +183 -12
@@ -0,0 +1,935 @@
1
+ $input-color: $grey-darker !default;
2
+ $input-background-color: $white !default;
3
+ $input-border-color: $grey-lighter !default;
4
+ $input-shadow: inset 0 1px 2px rgba($black, 0.1) !default;
5
+
6
+ $input-hover-color: $grey-darker !default;
7
+ $input-hover-border-color: $grey-light !default;
8
+
9
+ $input-focus-color: $grey-darker !default;
10
+ $input-focus-border-color: $link !default;
11
+ $input-focus-box-shadow-size: 0 0 0 0.125em !default;
12
+ $input-focus-box-shadow-color: rgba($link, 0.25) !default;
13
+
14
+ $input-disabled-color: $text-light !default;
15
+ $input-disabled-background-color: $background !default;
16
+ $input-disabled-border-color: $background !default;
17
+
18
+ $input-arrow: $link !default;
19
+
20
+ $input-icon-color: $grey-lighter !default;
21
+ $input-icon-active-color: $grey !default;
22
+
23
+ $input-radius: $radius !default;
24
+
25
+ $file-border-color: $border !default;
26
+ $file-radius: $radius !default;
27
+
28
+ $file-cta-background-color: $white-ter !default;
29
+ $file-cta-color: $grey-dark !default;
30
+ $file-cta-hover-color: $grey-darker !default;
31
+ $file-cta-active-color: $grey-darker !default;
32
+
33
+ $file-name-border-color: $border !default;
34
+ $file-name-border-style: solid !default;
35
+ $file-name-border-width: 1px 1px 1px 0 !default;
36
+ $file-name-max-width: 16em !default;
37
+
38
+ $label-color: $grey-darker !default;
39
+ $label-weight: $weight-bold !default;
40
+
41
+ $help-size: $size-small !default;
42
+
43
+ @mixin input {
44
+ @include control;
45
+
46
+ background-color: $input-background-color;
47
+ border-color: $input-border-color;
48
+ color: $input-color;
49
+
50
+ &:hover,
51
+ &.is-hovered {
52
+ border-color: $input-hover-border-color;
53
+ }
54
+
55
+ &:focus,
56
+ &.is-focused,
57
+ &:active,
58
+ &.is-active {
59
+ border-color: $input-focus-border-color;
60
+ box-shadow: $input-focus-box-shadow-size $input-focus-box-shadow-color;
61
+ }
62
+
63
+ &[disabled] {
64
+ background-color: $input-disabled-background-color;
65
+ border-color: $input-disabled-border-color;
66
+ box-shadow: none;
67
+ color: $input-disabled-color;
68
+
69
+ @include placeholder {
70
+ color: rgba($input-disabled-color, 0.3);
71
+ }
72
+ }
73
+ }
74
+
75
+ .input,
76
+ .textarea {
77
+ @include input;
78
+
79
+ box-shadow: $input-shadow;
80
+ max-width: 100%;
81
+ width: 100%;
82
+
83
+ &[type="search"] {
84
+ border-radius: 290486px;
85
+ }
86
+
87
+ // Colors
88
+ @each $name, $pair in $colors {
89
+ $color: nth($pair, 1);
90
+
91
+ &.is-#{$name} {
92
+ border-color: $color;
93
+
94
+ &:focus,
95
+ &.is-focused,
96
+ &:active,
97
+ &.is-active {
98
+ box-shadow: $input-focus-box-shadow-size rgba($color, 0.25);
99
+ }
100
+ }
101
+ }
102
+
103
+ // Sizes
104
+ &.is-small {
105
+ @include control-small;
106
+ }
107
+
108
+ &.is-medium {
109
+ @include control-medium;
110
+ }
111
+
112
+ &.is-large {
113
+ @include control-large;
114
+ }
115
+
116
+ // Modifiers
117
+ &.is-fullwidth {
118
+ display: block;
119
+ width: 100%;
120
+ }
121
+
122
+ &.is-inline {
123
+ display: inline;
124
+ width: auto;
125
+ }
126
+ }
127
+
128
+ .textarea {
129
+ display: block;
130
+ max-width: 100%;
131
+ min-width: 100%;
132
+ padding: 0.625em;
133
+ resize: vertical;
134
+
135
+ &:not([rows]) {
136
+ max-height: 600px;
137
+ min-height: 120px;
138
+ }
139
+
140
+ &[rows] {
141
+ height: unset;
142
+ }
143
+
144
+ // Modifiers
145
+ &.has-fixed-size {
146
+ resize: none;
147
+ }
148
+ }
149
+
150
+ .checkbox,
151
+ .radio {
152
+ cursor: pointer;
153
+ display: inline-block;
154
+ line-height: 1.25;
155
+ position: relative;
156
+
157
+ input {
158
+ cursor: pointer;
159
+ }
160
+
161
+ &:hover {
162
+ color: $input-hover-color;
163
+ }
164
+
165
+ &[disabled] {
166
+ color: $input-disabled-color;
167
+ cursor: not-allowed;
168
+ }
169
+ }
170
+
171
+ .radio {
172
+ & + .radio {
173
+ margin-left: 0.5em;
174
+ }
175
+ }
176
+
177
+ .select {
178
+ display: inline-block;
179
+ max-width: 100%;
180
+ position: relative;
181
+ vertical-align: top;
182
+
183
+ &:not(.is-multiple) {
184
+ height: 2.25em;
185
+
186
+ &::after {
187
+ @include arrow($input-arrow);
188
+
189
+ margin-top: -0.375em;
190
+ right: 1.125em;
191
+ top: 50%;
192
+ z-index: 4;
193
+ }
194
+ }
195
+
196
+ select {
197
+ @include input;
198
+
199
+ cursor: pointer;
200
+ display: block;
201
+ font-size: 1em;
202
+ max-width: 100%;
203
+ outline: none;
204
+
205
+ &::-ms-expand {
206
+ display: none;
207
+ }
208
+
209
+ &[disabled]:hover {
210
+ border-color: $input-disabled-border-color;
211
+ }
212
+
213
+ &:not([multiple]) {
214
+ padding-right: 2.5em;
215
+ }
216
+
217
+ &[multiple] {
218
+ height: unset;
219
+ padding: 0;
220
+
221
+ option {
222
+ padding: 0.5em 1em;
223
+ }
224
+ }
225
+ }
226
+
227
+ // States
228
+ &:hover {
229
+ &::after {
230
+ border-color: $input-hover-color;
231
+ }
232
+ }
233
+
234
+ // Colors
235
+ @each $name, $pair in $colors {
236
+ $color: nth($pair, 1);
237
+
238
+ &.is-#{$name} select {
239
+ border-color: $color;
240
+
241
+ &:focus,
242
+ &.is-focused,
243
+ &:active,
244
+ &.is-active {
245
+ box-shadow: $input-focus-box-shadow-size rgba($color, 0.25);
246
+ }
247
+ }
248
+ }
249
+
250
+ // Sizes
251
+ &.is-small {
252
+ @include control-small;
253
+ }
254
+
255
+ &.is-medium {
256
+ @include control-medium;
257
+ }
258
+
259
+ &.is-large {
260
+ @include control-large;
261
+ }
262
+
263
+ // Modifiers
264
+ &.is-disabled {
265
+ &::after {
266
+ border-color: $input-disabled-color;
267
+ }
268
+ }
269
+
270
+ &.is-fullwidth {
271
+ width: 100%;
272
+
273
+ select {
274
+ width: 100%;
275
+ }
276
+ }
277
+
278
+ &.is-loading {
279
+ &::after {
280
+ @include loader;
281
+
282
+ margin-top: 0;
283
+ position: absolute;
284
+ right: 0.625em;
285
+ top: 0.625em;
286
+ transform: none;
287
+ }
288
+
289
+ &.is-small:after {
290
+ font-size: $size-small;
291
+ }
292
+
293
+ &.is-medium:after {
294
+ font-size: $size-medium;
295
+ }
296
+
297
+ &.is-large:after {
298
+ font-size: $size-large;
299
+ }
300
+ }
301
+ }
302
+
303
+ .file {
304
+ @include unselectable;
305
+
306
+ align-items: stretch;
307
+ display: flex;
308
+ justify-content: flex-start;
309
+ position: relative;
310
+
311
+ // Colors
312
+ @each $name, $pair in $colors {
313
+ $color: nth($pair, 1);
314
+ $color-invert: nth($pair, 2);
315
+
316
+ &.is-#{$name} {
317
+ .file-cta {
318
+ background-color: $color;
319
+ border-color: transparent;
320
+ color: $color-invert;
321
+ }
322
+
323
+ &:hover,
324
+ &.is-hovered {
325
+ .file-cta {
326
+ background-color: darken($color, 2.5%);
327
+ border-color: transparent;
328
+ color: $color-invert;
329
+ }
330
+ }
331
+
332
+ &:focus,
333
+ &.is-focused {
334
+ .file-cta {
335
+ border-color: transparent;
336
+ box-shadow: 0 0 0.5em rgba($color, 0.25);
337
+ color: $color-invert;
338
+ }
339
+ }
340
+
341
+ &:active,
342
+ &.is-active {
343
+ .file-cta {
344
+ background-color: darken($color, 5%);
345
+ border-color: transparent;
346
+ color: $color-invert;
347
+ }
348
+ }
349
+ }
350
+ }
351
+
352
+ // Sizes
353
+ &.is-small {
354
+ font-size: $size-small;
355
+ }
356
+
357
+ &.is-medium {
358
+ font-size: $size-medium;
359
+
360
+ .file-icon {
361
+ .fa {
362
+ font-size: 21px;
363
+ }
364
+ }
365
+ }
366
+
367
+ &.is-large {
368
+ font-size: $size-large;
369
+
370
+ .file-icon {
371
+ .fa {
372
+ font-size: 28px;
373
+ }
374
+ }
375
+ }
376
+
377
+ // Modifiers
378
+ &.has-name {
379
+ .file-cta {
380
+ border-bottom-right-radius: 0;
381
+ border-top-right-radius: 0;
382
+ }
383
+
384
+ .file-name {
385
+ border-bottom-left-radius: 0;
386
+ border-top-left-radius: 0;
387
+ }
388
+ }
389
+
390
+ &.is-centered {
391
+ justify-content: center;
392
+ }
393
+
394
+ &.is-right {
395
+ justify-content: flex-end;
396
+ }
397
+
398
+ &.is-boxed {
399
+ .file-label {
400
+ flex-direction: column;
401
+ }
402
+
403
+ .file-cta {
404
+ flex-direction: column;
405
+ height: auto;
406
+ padding: 1em 3em;
407
+ }
408
+
409
+ .file-name {
410
+ border-width: 0 1px 1px;
411
+ }
412
+
413
+ .file-icon {
414
+ height: 1.5em;
415
+ width: 1.5em;
416
+
417
+ .fa {
418
+ font-size: 21px;
419
+ }
420
+ }
421
+
422
+ &.is-small {
423
+ .file-icon .fa {
424
+ font-size: 14px;
425
+ }
426
+ }
427
+
428
+ &.is-medium {
429
+ .file-icon .fa {
430
+ font-size: 28px;
431
+ }
432
+ }
433
+
434
+ &.is-large {
435
+ .file-icon .fa {
436
+ font-size: 35px;
437
+ }
438
+ }
439
+
440
+ &.has-name {
441
+ .file-cta {
442
+ border-radius: $file-radius $file-radius 0 0;
443
+ }
444
+
445
+ .file-name {
446
+ border-radius: 0 0 $file-radius $file-radius;
447
+ border-width: 0 1px 1px;
448
+ }
449
+ }
450
+ }
451
+
452
+ &.is-right {
453
+ .file-cta {
454
+ border-radius: 0 $file-radius $file-radius 0;
455
+ }
456
+
457
+ .file-name {
458
+ border-radius: $file-radius 0 0 $file-radius;
459
+ border-width: 1px 0 1px 1px;
460
+ order: -1;
461
+ }
462
+ }
463
+
464
+ &.is-fullwidth {
465
+ .file-label {
466
+ width: 100%;
467
+ }
468
+
469
+ .file-name {
470
+ flex-grow: 1;
471
+ max-width: none;
472
+ }
473
+ }
474
+ }
475
+
476
+ .file-label {
477
+ align-items: stretch;
478
+ display: flex;
479
+ cursor: pointer;
480
+ justify-content: flex-start;
481
+ overflow: hidden;
482
+ position: relative;
483
+
484
+ &:hover {
485
+ .file-cta {
486
+ background-color: darken($file-cta-background-color, 2.5%);
487
+ color: $file-cta-hover-color;
488
+ }
489
+
490
+ .file-name {
491
+ border-color: darken($file-name-border-color, 2.5%);
492
+ }
493
+ }
494
+
495
+ &:active {
496
+ .file-cta {
497
+ background-color: darken($file-cta-background-color, 5%);
498
+ color: $file-cta-active-color;
499
+ }
500
+
501
+ .file-name {
502
+ border-color: darken($file-name-border-color, 5%);
503
+ }
504
+ }
505
+ }
506
+
507
+ .file-input {
508
+ height: 0.01em;
509
+ left: 0;
510
+ outline: none;
511
+ position: absolute;
512
+ top: 0;
513
+ width: 0.01em;
514
+ }
515
+
516
+ .file-cta,
517
+ .file-name {
518
+ @include control;
519
+
520
+ border-color: $file-border-color;
521
+ border-radius: $file-radius;
522
+ font-size: 1em;
523
+ padding-left: 1em;
524
+ padding-right: 1em;
525
+ white-space: nowrap;
526
+ }
527
+
528
+ .file-cta {
529
+ background-color: $file-cta-background-color;
530
+ color: $file-cta-color;
531
+ }
532
+
533
+ .file-name {
534
+ border-color: $file-name-border-color;
535
+ border-style: $file-name-border-style;
536
+ border-width: $file-name-border-width;
537
+ display: block;
538
+ max-width: $file-name-max-width;
539
+ overflow: hidden;
540
+ text-align: left;
541
+ text-overflow: ellipsis;
542
+ }
543
+
544
+ .file-icon {
545
+ align-items: center;
546
+ display: flex;
547
+ height: 1em;
548
+ justify-content: center;
549
+ margin-right: 0.5em;
550
+ width: 1em;
551
+
552
+ .fa {
553
+ font-size: 14px;
554
+ }
555
+ }
556
+
557
+ .label {
558
+ color: $label-color;
559
+ display: block;
560
+ font-size: $size-normal;
561
+ font-weight: $label-weight;
562
+
563
+ &:not(:last-child) {
564
+ margin-bottom: 0.5em;
565
+ }
566
+
567
+ // Sizes
568
+ &.is-small {
569
+ font-size: $size-small;
570
+ }
571
+
572
+ &.is-medium {
573
+ font-size: $size-medium;
574
+ }
575
+
576
+ &.is-large {
577
+ font-size: $size-large;
578
+ }
579
+ }
580
+
581
+ .help {
582
+ display: block;
583
+ font-size: $help-size;
584
+ margin-top: 0.25rem;
585
+
586
+ @each $name, $pair in $colors {
587
+ $color: nth($pair, 1);
588
+
589
+ &.is-#{$name} {
590
+ color: $color;
591
+ }
592
+ }
593
+ }
594
+
595
+ // Containers
596
+
597
+ .field {
598
+ &:not(:last-child) {
599
+ margin-bottom: 0.75rem;
600
+ }
601
+
602
+ // Modifiers
603
+ &.has-addons {
604
+ display: flex;
605
+ justify-content: flex-start;
606
+
607
+ .control {
608
+ &:not(:last-child) {
609
+ margin-right: -1px;
610
+ }
611
+
612
+ &:first-child {
613
+ .button,
614
+ .input,
615
+ .select select {
616
+ border-bottom-left-radius: $input-radius;
617
+ border-top-left-radius: $input-radius;
618
+ }
619
+ }
620
+
621
+ &:last-child {
622
+ .button,
623
+ .input,
624
+ .select select {
625
+ border-bottom-right-radius: $input-radius;
626
+ border-top-right-radius: $input-radius;
627
+ }
628
+ }
629
+
630
+ .button,
631
+ .input,
632
+ .select select {
633
+ border-radius: 0;
634
+
635
+ &:hover,
636
+ &.is-hovered {
637
+ z-index: 2;
638
+ }
639
+
640
+ &:focus,
641
+ &.is-focused,
642
+ &:active,
643
+ &.is-active {
644
+ z-index: 3;
645
+
646
+ &:hover {
647
+ z-index: 4;
648
+ }
649
+ }
650
+ }
651
+
652
+ &.is-expanded {
653
+ flex-grow: 1;
654
+ }
655
+ }
656
+
657
+ &.has-addons-centered {
658
+ justify-content: center;
659
+ }
660
+
661
+ &.has-addons-right {
662
+ justify-content: flex-end;
663
+ }
664
+
665
+ &.has-addons-fullwidth {
666
+ .control {
667
+ flex-grow: 1;
668
+ flex-shrink: 0;
669
+ }
670
+ }
671
+ }
672
+
673
+ &.is-grouped {
674
+ display: flex;
675
+ justify-content: flex-start;
676
+
677
+ & > .control {
678
+ flex-shrink: 0;
679
+
680
+ &:not(:last-child) {
681
+ margin-bottom: 0;
682
+ margin-right: 0.75rem;
683
+ }
684
+
685
+ &.is-expanded {
686
+ flex-grow: 1;
687
+ flex-shrink: 1;
688
+ }
689
+ }
690
+
691
+ &.is-grouped-centered {
692
+ justify-content: center;
693
+ }
694
+
695
+ &.is-grouped-right {
696
+ justify-content: flex-end;
697
+ }
698
+
699
+ &.is-grouped-multiline {
700
+ flex-wrap: wrap;
701
+
702
+ & > .control {
703
+ &:last-child,
704
+ &:not(:last-child) {
705
+ margin-bottom: 0.75rem;
706
+ }
707
+ }
708
+
709
+ &:last-child {
710
+ margin-bottom: -0.75rem;
711
+ }
712
+
713
+ &:not(:last-child) {
714
+ margin-bottom: 0;
715
+ }
716
+ }
717
+ }
718
+
719
+ &.is-horizontal {
720
+ @include tablet {
721
+ display: flex;
722
+ }
723
+ }
724
+ }
725
+
726
+ .field-label {
727
+ .label {
728
+ font-size: inherit;
729
+ }
730
+
731
+ @include mobile {
732
+ margin-bottom: 0.5rem;
733
+ }
734
+
735
+
736
+ @include tablet {
737
+ flex-basis: 0;
738
+ flex-grow: 1;
739
+ flex-shrink: 0;
740
+ margin-right: 1.5rem;
741
+ text-align: right;
742
+
743
+ &.is-small {
744
+ font-size: $size-small;
745
+ padding-top: 0.375em;
746
+ }
747
+
748
+ &.is-normal {
749
+ padding-top: 0.375em;
750
+ }
751
+
752
+ &.is-medium {
753
+ font-size: $size-medium;
754
+ padding-top: 0.375em;
755
+ }
756
+
757
+ &.is-large {
758
+ font-size: $size-large;
759
+ padding-top: 0.375em;
760
+ }
761
+ }
762
+ }
763
+
764
+ .field-body {
765
+ .field .field {
766
+ margin-bottom: 0;
767
+ }
768
+
769
+ @include tablet {
770
+ display: flex;
771
+ flex-basis: 0;
772
+ flex-grow: 5;
773
+ flex-shrink: 1;
774
+
775
+ .field {
776
+ margin-bottom: 0;
777
+ }
778
+
779
+ & > .field {
780
+ flex-shrink: 1;
781
+
782
+ &:not(.is-narrow) {
783
+ flex-grow: 1;
784
+ }
785
+
786
+ &:not(:last-child) {
787
+ margin-right: 0.75rem;
788
+ }
789
+ }
790
+ }
791
+ }
792
+
793
+ .control {
794
+ font-size: $size-normal;
795
+ position: relative;
796
+ text-align: left;
797
+
798
+ // Modifiers
799
+ // DEPRECATED
800
+ &.has-icon {
801
+ .icon {
802
+ color: $input-icon-color;
803
+ height: 2.25em;
804
+ pointer-events: none;
805
+ position: absolute;
806
+ top: 0;
807
+ width: 2.25em;
808
+ z-index: 4;
809
+ }
810
+
811
+ .input {
812
+ &:focus {
813
+ & + .icon {
814
+ color: $input-icon-active-color;
815
+ }
816
+ }
817
+
818
+ &.is-small {
819
+ & + .icon {
820
+ font-size: $size-small;
821
+ }
822
+ }
823
+
824
+ &.is-medium {
825
+ & + .icon {
826
+ font-size: $size-medium;
827
+ }
828
+ }
829
+
830
+ &.is-large {
831
+ & + .icon {
832
+ font-size: $size-large;
833
+ }
834
+ }
835
+ }
836
+
837
+ &:not(.has-icon-right) {
838
+ .icon {
839
+ left: 0;
840
+ }
841
+
842
+ .input {
843
+ padding-left: 2.25em;
844
+ }
845
+ }
846
+
847
+ &.has-icon-right {
848
+ .icon {
849
+ right: 0;
850
+ }
851
+
852
+ .input {
853
+ padding-right: 2.25em;
854
+ }
855
+ }
856
+ }
857
+
858
+ &.has-icons-left,
859
+ &.has-icons-right {
860
+ .input,
861
+ .select {
862
+ &:focus {
863
+ & ~ .icon {
864
+ color: $input-icon-active-color;
865
+ }
866
+ }
867
+
868
+ &.is-small ~ .icon {
869
+ font-size: $size-small;
870
+ }
871
+
872
+ &.is-medium ~ .icon {
873
+ font-size: $size-medium;
874
+ }
875
+
876
+ &.is-large ~ .icon {
877
+ font-size: $size-large;
878
+ }
879
+ }
880
+
881
+ .icon {
882
+ color: $input-icon-color;
883
+ height: 2.25em;
884
+ pointer-events: none;
885
+ position: absolute;
886
+ top: 0;
887
+ width: 2.25em;
888
+ z-index: 4;
889
+ }
890
+ }
891
+
892
+ &.has-icons-left {
893
+ .input,
894
+ .select select {
895
+ padding-left: 2.25em;
896
+ }
897
+
898
+ .icon.is-left {
899
+ left: 0;
900
+ }
901
+ }
902
+
903
+ &.has-icons-right {
904
+ .input,
905
+ .select select {
906
+ padding-right: 2.25em;
907
+ }
908
+
909
+ .icon.is-right {
910
+ right: 0;
911
+ }
912
+ }
913
+
914
+ &.is-loading {
915
+ &::after {
916
+ @include loader;
917
+
918
+ position: absolute !important;
919
+ right: 0.625em;
920
+ top: 0.625em;
921
+ }
922
+
923
+ &.is-small:after {
924
+ font-size: $size-small;
925
+ }
926
+
927
+ &.is-medium:after {
928
+ font-size: $size-medium;
929
+ }
930
+
931
+ &.is-large:after {
932
+ font-size: $size-large;
933
+ }
934
+ }
935
+ }