@miljodirektoratet/md-css 0.0.8 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/accordionitem.css +91 -0
- package/src/colors.css +4 -0
- package/src/formElements/multiselect.css +20 -3
- package/src/index.css +1 -0
package/package.json
CHANGED
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
.md-accordion-item {
|
|
2
|
+
padding: 1em;
|
|
3
|
+
background-color: var(--primaryColor20);
|
|
4
|
+
color: var(--greyColor);
|
|
5
|
+
font-family: 'Open sans';
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.md-accordion-item:focus-within {
|
|
9
|
+
outline: 2px solid var(--primaryColor80);
|
|
10
|
+
outline-offset: -2px;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.md-accordion-item.md-accordion-item--secondary {
|
|
14
|
+
background-color: var(--secondaryColor60);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/* Header */
|
|
18
|
+
.md-accordion-item__header {
|
|
19
|
+
display: flex;
|
|
20
|
+
justify-content: space-between;
|
|
21
|
+
align-items: center;
|
|
22
|
+
background: none;
|
|
23
|
+
border: 0;
|
|
24
|
+
width: 100%;
|
|
25
|
+
margin: 0;
|
|
26
|
+
padding: 1em;
|
|
27
|
+
cursor: pointer;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.md-accordion-item__header:focus {
|
|
31
|
+
outline: none;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.md-accordion-item__header-left {
|
|
35
|
+
display: flex;
|
|
36
|
+
align-items: center;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.md-accordion-item__header .md-accordion-item__header-icon {
|
|
40
|
+
position: relative;
|
|
41
|
+
width: 12px;
|
|
42
|
+
height: 12px;
|
|
43
|
+
}
|
|
44
|
+
.md-accordion-item__header .md-accordion-item__header-icon:before,
|
|
45
|
+
.md-accordion-item__header .md-accordion-item__header-icon:after {
|
|
46
|
+
content: "";
|
|
47
|
+
position: absolute;
|
|
48
|
+
background-color: transparent;
|
|
49
|
+
background-color: var(--greyColor);
|
|
50
|
+
transition: transform 0.25s ease-out;
|
|
51
|
+
}
|
|
52
|
+
/* Vertical line */
|
|
53
|
+
.md-accordion-item__header .md-accordion-item__header-icon:before {
|
|
54
|
+
top: 0;
|
|
55
|
+
left: 50%;
|
|
56
|
+
width: 2px;
|
|
57
|
+
height: 100%;
|
|
58
|
+
margin-left: -1px;
|
|
59
|
+
}
|
|
60
|
+
/* horizontal line */
|
|
61
|
+
.md-accordion-item__header .md-accordion-item__header-icon:after{
|
|
62
|
+
top: 50%;
|
|
63
|
+
left: 0;
|
|
64
|
+
width: 100%;
|
|
65
|
+
height: 2px;
|
|
66
|
+
margin-top: -1px;
|
|
67
|
+
}
|
|
68
|
+
.md-accordion-item__header--expanded .md-accordion-item__header-icon:before {
|
|
69
|
+
transform: rotate(90deg);
|
|
70
|
+
}
|
|
71
|
+
.md-accordion-item__header--expanded .md-accordion-item__header-icon:after {
|
|
72
|
+
transform: rotate(180deg);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.md-accordion-item__header-label {
|
|
76
|
+
font-size: 1.25em;
|
|
77
|
+
margin-left: 1em;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/* CONTENT */
|
|
81
|
+
.md-accordion-item__content {
|
|
82
|
+
padding: 0 1em;
|
|
83
|
+
max-height: 0;
|
|
84
|
+
overflow: hidden;
|
|
85
|
+
transition: all .2s linear;
|
|
86
|
+
}
|
|
87
|
+
.md-accordion-item__content--expanded {
|
|
88
|
+
max-height: 5000px;
|
|
89
|
+
padding: 1em;
|
|
90
|
+
transition: all .2s linear;
|
|
91
|
+
}
|
package/src/colors.css
CHANGED
|
@@ -107,20 +107,37 @@
|
|
|
107
107
|
font-family: 'Open sans';
|
|
108
108
|
border: 0;
|
|
109
109
|
background-color: #fff;
|
|
110
|
-
width: 100%;
|
|
111
110
|
text-align: left;
|
|
112
|
-
padding: .9em;
|
|
113
111
|
transition: background-color .15s ease-in-out;
|
|
114
112
|
cursor: pointer;
|
|
115
113
|
}
|
|
116
114
|
|
|
115
|
+
.md-multiselect__dropdown-item .md-checkbox {
|
|
116
|
+
display: flex;
|
|
117
|
+
width: 100%;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.md-multiselect__dropdown-item .md-checkbox .md-checkbox__label {
|
|
121
|
+
display: flex;
|
|
122
|
+
flex-shrink: 0;
|
|
123
|
+
flex-grow: 1;
|
|
124
|
+
padding: .9em;
|
|
125
|
+
}
|
|
126
|
+
|
|
117
127
|
.md-multiselect__dropdown-item:hover,
|
|
118
|
-
.md-multiselect__dropdown-item:focus
|
|
128
|
+
.md-multiselect__dropdown-item:focus,
|
|
129
|
+
.md-multiselect__dropdown-item:focus-within {
|
|
119
130
|
outline: none;
|
|
120
131
|
background-color: var(--primaryColor20);
|
|
121
132
|
transition: background-color .15s ease-in-out;
|
|
122
133
|
}
|
|
123
134
|
|
|
135
|
+
.md-multiselect__dropdown-item:hover .md-checkbox .md-checkbox__label::before,
|
|
136
|
+
.md-multiselect__dropdown-item:focus .md-checkbox .md-checkbox__label::before,
|
|
137
|
+
.md-multiselect__dropdown-item:focus-within .md-checkbox .md-checkbox__label::before {
|
|
138
|
+
background-color: #fff;
|
|
139
|
+
}
|
|
140
|
+
|
|
124
141
|
.md-multiselect__dropdown-item-text {
|
|
125
142
|
display: flex;
|
|
126
143
|
flex-grow: 1;
|
package/src/index.css
CHANGED