UNPKG

2.13 kBSCSSView Raw
1/**Variable**/
2
3.vxe-textarea {
4 position: relative;
5 display: inline-block;
6 &:not(.def--cols) {
7 width: 100%;
8 .vxe-textarea--inner {
9 width: 100%;
10 }
11 }
12}
13
14.vxe-textarea--inner {
15 border-radius: $vxe-border-radius;
16 outline: 0;
17 font-size: inherit;
18 padding: 0 0.6em;
19 color: $vxe-font-color;
20 line-height: inherit;
21 border: 1px solid $vxe-input-border-color;
22 background-color: $vxe-textarea-background-color;
23 display: block;
24 padding: 0.3em 0.6em;
25 &::placeholder {
26 color: $vxe-input-placeholder-color;
27 }
28 &:focus {
29 border: 1px solid $vxe-primary-color;
30 }
31 &[disabled] {
32 cursor: not-allowed;
33 background-color: $vxe-input-disabled-background-color;
34 }
35}
36
37.vxe-textarea--inner,
38.vxe-textarea--autosize {
39 line-height: $vxe-textarea-line-height;
40 color: $vxe-font-color;
41 font-family: $vxe-font-family;
42}
43
44.vxe-textarea--autosize {
45 display: block;
46 position: fixed;
47 top: 0;
48 left: 0;
49 width: 100%;
50 margin: 0;
51 padding: 0.3em 0.6em;
52 word-wrap: break-word;
53 white-space: pre-wrap;
54 z-index: -1;
55 visibility: hidden;
56}
57
58.vxe-textarea--count {
59 position: absolute;
60 bottom: 0.2em;
61 right: 1.4em;
62 padding-left: 0.2em;
63 color: $vxe-textarea-count-color;
64 background-color: $vxe-textarea-count-background-color;
65 &.is--error {
66 color: $vxe-textarea-count-error-color;
67 }
68}
69
70.vxe-textarea,
71.vxe-textarea--autosize {
72 font-size: $vxe-font-size;
73 &.size--medium {
74 font-size: $vxe-font-size-medium;
75 }
76 &.size--small {
77 font-size: $vxe-font-size-small;
78 }
79 &.size--mini {
80 font-size: $vxe-font-size-mini;
81 }
82}
83
84.vxe-textarea {
85 &:not(.is--autosize) {
86 min-height: $vxe-input-height-default;
87 }
88 &.size--medium {
89 font-size: $vxe-font-size-medium;
90 &:not(.is--autosize) {
91 min-height: $vxe-input-height-medium;
92 }
93 }
94 &.size--small {
95 &:not(.is--autosize) {
96 min-height: $vxe-input-height-small;
97 }
98 }
99 &.size--mini {
100 &:not(.is--autosize) {
101 min-height: $vxe-input-height-mini;
102 }
103 }
104}
\No newline at end of file