]>
Commit | Line | Data |
---|---|---|
1 | @use 'sass:math'; | |
2 | @use 'sass:color'; | |
3 | ||
4 | @use '_variables' as *; | |
5 | @use '_mixins' as *; | |
6 | ||
7 | $ng-select-highlight: pvar(--mainColor); | |
8 | $ng-select-primary-text: pvar(--mainForegroundColor); | |
9 | // $ng-select-disabled-text: #f9f9f9 !default; | |
10 | $ng-select-border: $input-border-color; | |
11 | // $ng-select-border-radius: 4px !default; | |
12 | $ng-select-bg: pvar(--mainBackgroundColor); | |
13 | ||
14 | // Cannot use a CSS variable as the default them use darken on this variable | |
15 | $ng-select-selected: color.adjust($main-color, $lightness: 40%); | |
16 | // $ng-select-selected-text: $ng-select-primary-text !default; | |
17 | ||
18 | $ng-select-marked: pvar(--mainColorLightest); | |
19 | // $ng-select-marked-text: $ng-select-primary-text !default; | |
20 | ||
21 | $ng-select-box-shadow: #{$focus-box-shadow-form} pvar(--mainColorLightest); | |
22 | $ng-select-placeholder: pvar(--greyForegroundColor); | |
23 | $ng-select-height: 30px; | |
24 | $ng-select-value-padding-left: 15px; | |
25 | $ng-select-value-font-size: $form-input-font-size; | |
26 | // $ng-select-value-text: $ng-select-primary-text !default; | |
27 | ||
28 | // $ng-select-dropdown-bg: $ng-select-bg !default; | |
29 | // $ng-select-dropdown-border: $ng-select-border !default; | |
30 | // $ng-select-dropdown-optgroup-text: rgba(0, 0, 0, 0.54) !default; | |
31 | // $ng-select-dropdown-optgroup-marked: $ng-select-dropdown-optgroup-text !default; | |
32 | // $ng-select-dropdown-option-bg: $ng-select-dropdown-bg !default; | |
33 | // $ng-select-dropdown-option-text: rgba(0, 0, 0, 0.87) !default; | |
34 | $ng-select-dropdown-option-disabled: pvar(--greyForegroundColor); | |
35 | ||
36 | $ng-select-input-text: pvar(--mainForegroundColor); | |
37 | ||
38 | @import '@ng-select/ng-select/scss/default.theme'; | |
39 | ||
40 | .ng-select { | |
41 | @include rounded-line-height-1-5($ng-select-value-font-size); | |
42 | ||
43 | font-size: $ng-select-value-font-size; | |
44 | ||
45 | &.ng-select-focused { | |
46 | &:not(.ng-select-opened) > .ng-select-container { | |
47 | border-color: $ng-select-border !important; | |
48 | } | |
49 | } | |
50 | ||
51 | .ng-input > input { | |
52 | color: pvar(--inputForegroundColor) !important; | |
53 | } | |
54 | ||
55 | .ng-dropdown-panel .ng-dropdown-panel-items .ng-option { | |
56 | &:not(.ng-option-marked, .ng-option-selected) { | |
57 | color: pvar(--mainForegroundColor); | |
58 | background-color: pvar(--mainBackgroundColor); | |
59 | } | |
60 | } | |
61 | ||
62 | .ng-select-container { | |
63 | background-color: pvar(--inputBackgroundColor); | |
64 | } | |
65 | ||
66 | .ng-arrow-wrapper { | |
67 | @include padding-right(12px); | |
68 | } | |
69 | ||
70 | .ng-arrow { | |
71 | border-color: #000 transparent transparent !important; | |
72 | } | |
73 | ||
74 | &.ng-select-opened .ng-arrow { | |
75 | border-color: transparent transparent #000 !important; | |
76 | } | |
77 | ||
78 | &.ng-select-single .ng-value-container .ng-value { | |
79 | color: pvar(--inputForegroundColor); | |
80 | ||
81 | .ng-value-label { | |
82 | display: flex; | |
83 | align-items: center; | |
84 | } | |
85 | } | |
86 | ||
87 | &.ng-select-multiple .ng-select-container .ng-value-container { | |
88 | @include padding-left(12px); | |
89 | ||
90 | .ng-value { | |
91 | @include margin-left(12px); | |
92 | ||
93 | background-color: pvar(--mainColorLightest); | |
94 | ||
95 | .ng-value-icon { | |
96 | border: 0 !important; | |
97 | } | |
98 | } | |
99 | } | |
100 | } |