@miljodirektoratet/md-css 0.0.5 → 0.0.6

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@miljodirektoratet/md-css",
3
- "version": "0.0.5",
3
+ "version": "0.0.6",
4
4
  "description": "CSS for Miljødirektoratet",
5
5
  "author": "Miljødirektoratet",
6
6
  "main": "./src/index.css",
package/src/button.css CHANGED
@@ -8,7 +8,7 @@
8
8
  font-family: 'Open sans';
9
9
  font-size: 1rem;
10
10
  outline: 2px solid var(--primaryColor);
11
- padding: .75rem 1.5rem;
11
+ padding: .65rem 1.5rem;
12
12
  }
13
13
 
14
14
  .md-button--small {
@@ -0,0 +1,72 @@
1
+ .md-filelist {
2
+ display: flex;
3
+ flex-direction: column;
4
+ gap: .5em;
5
+ }
6
+
7
+ .md-filelist__file {
8
+ display: flex;
9
+ justify-content: space-between;
10
+ border: 1px solid var(--primaryColor);
11
+ padding: .8em 1.1em;
12
+ font-family: 'Open sans';
13
+ background-color: #fff;
14
+ transition: background .2s linear;
15
+ }
16
+
17
+ .md-filelist__file:hover {
18
+ background-color: var(--primaryColor20);
19
+ transition: background .2s linear;
20
+ }
21
+
22
+ .md-filelist__file-label {
23
+ display: flex;
24
+ gap: 1.5em;
25
+ font-size: 16px;
26
+ }
27
+
28
+ .md-filelist__file-icon {
29
+ height: 24px;
30
+ width: 19px;
31
+ }
32
+
33
+ .md-filelist__file-size {
34
+ font-size: 14px;
35
+ margin-top: .3em;
36
+ }
37
+
38
+ /* File actions */
39
+ .md-filelist__file-actions {
40
+ display: flex;
41
+ align-items: center;
42
+ gap: 1em;
43
+ }
44
+
45
+ .md-filelist__file-actions-button {
46
+ display: flex;
47
+ align-items: center;
48
+ justify-content: center;
49
+ width: 40px;
50
+ height: 40px;
51
+ background-color: transparent;
52
+ border-radius: 100px;
53
+ border: 0;
54
+ padding: .2em;
55
+ cursor: pointer;
56
+ transition: background .1s linear;
57
+ }
58
+
59
+ .md-filelist__file-actions-button:hover {
60
+ background-color: #fff;
61
+ transition: background .1s linear;
62
+ }
63
+
64
+ .md-filelist__file-delete-icon {
65
+ height: 18px;
66
+ width: 15px;
67
+ }
68
+
69
+ .md-filelist__file-download-icon {
70
+ height: 20px;
71
+ width: 20px;
72
+ }
@@ -0,0 +1,66 @@
1
+ .md-fileupload {
2
+ background-color: #fff;
3
+ }
4
+
5
+ .md-fileupload__droparea {
6
+ display: flex;
7
+ flex-direction: column;
8
+ align-items: center;
9
+ padding: 2em;
10
+ border: 1px dashed var(--greyColor80);
11
+ margin-bottom: 4em;
12
+ background-color: #fff;
13
+ transition: background .2s linear;
14
+ }
15
+
16
+ .md-fileupload__droparea.md-fileupload__droparea--active {
17
+ background-color: var(--greyColor20);
18
+ transition: background .2s linear;
19
+ }
20
+
21
+ .md-fileupload__droparea.md-fileupload__droparea--active * {
22
+ pointer-events: none;
23
+ }
24
+
25
+ .md-fileupload__droparea-icon {
26
+ width: 32px;
27
+ height: 32px;
28
+ color: #000;
29
+ margin-bottom: 1.5em;
30
+ }
31
+
32
+ .md-fileupload__droparea-content {
33
+ font-family: 'Open sans';
34
+ font-size: 16px;
35
+ }
36
+
37
+ .md-fileupload__droparea-content button {
38
+ background: none;
39
+ border: 0;
40
+ font-size: 16px;
41
+ color: var(--primaryColor);
42
+ text-decoration: underline;
43
+ padding: 0;
44
+ margin: 0;
45
+ cursor: pointer;
46
+ }
47
+
48
+ .md-fileupload__input {
49
+ display: none;
50
+ }
51
+
52
+ .md-fileupload__files-wrapper {
53
+ width: 100%;
54
+ margin: 1.5em 0 0 0;
55
+ padding: 1.5em 0 0 0;
56
+ border-top: 1px solid #000;
57
+ }
58
+
59
+ .md-fileupload__actions {
60
+ display: flex;
61
+ justify-content: flex-end;
62
+ }
63
+
64
+ .md-fileupload__actions > * + * {
65
+ margin-left: 1em;
66
+ }
package/src/index.css CHANGED
@@ -7,10 +7,12 @@
7
7
  @import './help.css';
8
8
  @import './toggle.css';
9
9
  @import './chips.css';
10
+ @import './filelist.css';
10
11
  @import './formElements/input.css';
11
12
  @import './formElements/checkbox.css';
12
13
  @import './formElements/textarea.css';
13
14
  @import './formElements/select.css';
14
15
  @import './formElements/radiogroup.css';
15
16
  @import './formElements/multiselect.css';
17
+ @import './formElements/fileupload.css';
16
18
  @import './utils.css';