@ptsecurity/mosaic 17.0.0 → 17.2.0
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/autocomplete/_autocomplete-theme.scss +2 -1
- package/autocomplete/autocomplete-trigger.directive.d.ts +7 -1
- package/autocomplete/autocomplete.scss +7 -11
- package/button/_button-base.scss +10 -10
- package/button/_button-theme.scss +32 -32
- package/button/button.scss +9 -15
- package/button-toggle/_button-toggle-theme.scss +32 -24
- package/button-toggle/button-toggle.scss +18 -57
- package/card/_card-theme.scss +23 -20
- package/card/card.component.scss +2 -1
- package/checkbox/_checkbox-theme.scss +33 -29
- package/checkbox/checkbox.scss +7 -6
- package/code-block/_code-block-theme.scss +201 -113
- package/code-block/actionbar.component.scss +5 -7
- package/code-block/code-block.scss +5 -6
- package/core/forms/_forms-theme.scss +17 -46
- package/core/option/_optgroup-theme.scss +5 -5
- package/core/option/_option-action-theme.scss +1 -4
- package/core/option/_option-theme.scss +8 -10
- package/core/option/option.scss +5 -4
- package/core/pop-up/pop-up-trigger.d.ts +3 -1
- package/core/styles/_mosaic-theme.scss +3 -3
- package/core/styles/common/_popup.scss +4 -3
- package/core/styles/common/_tokens.scss +39 -0
- package/core/styles/theming/_alerts.scss +16 -24
- package/core/styles/theming/_badges.scss +7 -8
- package/core/styles/theming/_components-theming.scss +4 -2
- package/core/styles/theming/_scrollbars.scss +17 -2
- package/datepicker/_datepicker-theme.scss +18 -19
- package/datepicker/calendar-body.scss +6 -9
- package/datepicker/calendar-header.scss +9 -26
- package/datepicker/calendar.scss +5 -16
- package/datepicker/datepicker-content.scss +2 -4
- package/datepicker/datepicker-input.scss +2 -1
- package/datepicker/datepicker-toggle.scss +3 -2
- package/divider/_divider-theme.scss +4 -2
- package/divider/divider.scss +5 -4
- package/dl/_dl-theme.scss +12 -36
- package/dl/dl.scss +13 -46
- package/dropdown/_dropdown-theme.scss +19 -17
- package/dropdown/dropdown-item.scss +7 -6
- package/dropdown/dropdown.scss +11 -26
- package/ellipsis-center/ellipsis-center.directive.d.ts +3 -2
- package/esm2022/autocomplete/autocomplete-trigger.directive.mjs +14 -2
- package/esm2022/button/button.component.mjs +2 -2
- package/esm2022/code-block/actionbar.component.mjs +2 -2
- package/esm2022/code-block/code-block.component.mjs +2 -2
- package/esm2022/core/pop-up/pop-up-trigger.mjs +19 -11
- package/esm2022/core/version.mjs +2 -2
- package/esm2022/dropdown/dropdown-item.component.mjs +2 -2
- package/esm2022/dropdown/dropdown.component.mjs +3 -3
- package/esm2022/ellipsis-center/ellipsis-center.directive.mjs +7 -5
- package/esm2022/file-upload/file-upload.module.mjs +8 -4
- package/esm2022/file-upload/multiple-file-upload.component.mjs +15 -34
- package/esm2022/file-upload/single-file-upload.component.mjs +15 -34
- package/esm2022/form-field/form-field.mjs +2 -2
- package/esm2022/input/input-password.mjs +2 -3
- package/esm2022/loader-overlay/loader-overlay.component.mjs +2 -2
- package/esm2022/markdown/markdown.component.mjs +2 -2
- package/esm2022/modal/modal.component.mjs +6 -6
- package/esm2022/navbar/navbar-item.component.mjs +9 -9
- package/esm2022/progress-spinner/progress-spinner.component.mjs +2 -2
- package/esm2022/radio/radio.component.mjs +2 -2
- package/esm2022/select/select-option.directive.mjs +7 -5
- package/esm2022/select/select.component.mjs +16 -9
- package/esm2022/tabs/tab-header.component.mjs +2 -2
- package/esm2022/tabs/tab-nav-bar/tab-nav-bar.mjs +2 -2
- package/esm2022/tags/tag-input.mjs +28 -8
- package/esm2022/timezone/timezone-option.directive.mjs +7 -5
- package/esm2022/timezone/timezone-select.component.mjs +2 -2
- package/esm2022/title/title.directive.mjs +2 -3
- package/esm2022/tooltip/tooltip.component.mjs +27 -12
- package/esm2022/tree-select/tree-select.component.mjs +21 -8
- package/fesm2022/ptsecurity-mosaic-autocomplete.mjs +13 -1
- package/fesm2022/ptsecurity-mosaic-autocomplete.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-button.mjs +2 -2
- package/fesm2022/ptsecurity-mosaic-button.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-code-block.mjs +4 -4
- package/fesm2022/ptsecurity-mosaic-code-block.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-core.mjs +19 -11
- package/fesm2022/ptsecurity-mosaic-core.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-dropdown.mjs +4 -4
- package/fesm2022/ptsecurity-mosaic-dropdown.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-ellipsis-center.mjs +5 -4
- package/fesm2022/ptsecurity-mosaic-ellipsis-center.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-file-upload.mjs +26 -58
- package/fesm2022/ptsecurity-mosaic-file-upload.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-form-field.mjs +2 -2
- package/fesm2022/ptsecurity-mosaic-form-field.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-input.mjs +1 -2
- package/fesm2022/ptsecurity-mosaic-input.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-loader-overlay.mjs +2 -2
- package/fesm2022/ptsecurity-mosaic-loader-overlay.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-markdown.mjs +2 -2
- package/fesm2022/ptsecurity-mosaic-markdown.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-modal.mjs +5 -5
- package/fesm2022/ptsecurity-mosaic-modal.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-navbar.mjs +8 -8
- package/fesm2022/ptsecurity-mosaic-navbar.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-progress-spinner.mjs +1 -1
- package/fesm2022/ptsecurity-mosaic-progress-spinner.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-radio.mjs +2 -2
- package/fesm2022/ptsecurity-mosaic-radio.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-select.mjs +25 -17
- package/fesm2022/ptsecurity-mosaic-select.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-tabs.mjs +4 -4
- package/fesm2022/ptsecurity-mosaic-tabs.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-tags.mjs +26 -7
- package/fesm2022/ptsecurity-mosaic-tags.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-timezone.mjs +7 -6
- package/fesm2022/ptsecurity-mosaic-timezone.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-title.mjs +1 -2
- package/fesm2022/ptsecurity-mosaic-title.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-tooltip.mjs +25 -11
- package/fesm2022/ptsecurity-mosaic-tooltip.mjs.map +1 -1
- package/fesm2022/ptsecurity-mosaic-tree-select.mjs +20 -7
- package/fesm2022/ptsecurity-mosaic-tree-select.mjs.map +1 -1
- package/file-upload/_file-upload-theme.scss +87 -54
- package/file-upload/file-upload.module.d.ts +2 -1
- package/file-upload/file-upload.scss +0 -15
- package/file-upload/multiple-file-upload.component.d.ts +4 -12
- package/file-upload/multiple-file-upload.component.scss +58 -54
- package/file-upload/single-file-upload.component.d.ts +4 -12
- package/file-upload/single-file-upload.component.scss +15 -24
- package/form-field/_form-field-theme.scss +43 -34
- package/form-field/form-field.scss +14 -13
- package/icon/_icon-theme.scss +26 -25
- package/input/_input-base.scss +3 -2
- package/input/_input-theme.scss +14 -14
- package/input/input-password.d.ts +0 -1
- package/input/input.scss +3 -4
- package/link/_link-theme.scss +36 -32
- package/list/_list-base.scss +4 -3
- package/list/_list-theme.scss +8 -8
- package/list/list.scss +2 -1
- package/loader-overlay/_loader-overlay-theme.scss +8 -8
- package/loader-overlay/loader-overlay.scss +7 -12
- package/markdown/_markdown-theme.scss +61 -43
- package/markdown/markdown.scss +39 -80
- package/modal/_modal-confirm.scss +3 -2
- package/modal/_modal-theme.scss +20 -21
- package/modal/modal.scss +18 -15
- package/navbar/_navbar-theme.scss +19 -18
- package/navbar/navbar-brand.scss +7 -9
- package/navbar/navbar-item.component.d.ts +4 -4
- package/navbar/navbar-item.scss +8 -7
- package/navbar/vertical-navbar.scss +4 -12
- package/package.json +25 -25
- package/popover/_popover-theme.scss +35 -35
- package/popover/popover.scss +15 -14
- package/prebuilt-themes/dark-theme.css +1 -1
- package/prebuilt-themes/default-theme.css +1 -1
- package/progress-bar/_progress-bar-theme.scss +6 -5
- package/progress-bar/progress-bar.scss +2 -1
- package/progress-spinner/_progress-spinner-theme.scss +4 -3
- package/progress-spinner/progress-spinner.scss +7 -12
- package/radio/_radio-theme.scss +32 -24
- package/radio/radio.scss +8 -11
- package/select/_select-theme.scss +13 -13
- package/select/select-option.directive.d.ts +3 -2
- package/select/select.component.d.ts +1 -0
- package/select/select.scss +19 -42
- package/sidepanel/_sidepanel-theme.scss +9 -9
- package/sidepanel/sidepanel.scss +11 -10
- package/splitter/_splitter-theme.scss +5 -3
- package/table/_table-theme.scss +9 -9
- package/table/table.scss +11 -14
- package/tabs/_tabs-common.scss +15 -14
- package/tabs/_tabs-theme.scss +67 -55
- package/tabs/tab-group.scss +2 -1
- package/tabs/tab-header.scss +16 -3
- package/tabs/tab-nav-bar/tab-nav-bar.scss +15 -2
- package/tags/_tag-theme.scss +30 -27
- package/tags/tag-input.d.ts +9 -4
- package/tags/tag-list.scss +4 -3
- package/tags/tag.scss +9 -8
- package/textarea/_textarea-base.scss +2 -4
- package/textarea/_textarea-theme.scss +8 -8
- package/textarea/textarea.scss +2 -4
- package/timepicker/timepicker.scss +2 -7
- package/timezone/_timezone-option-theme.scss +7 -7
- package/timezone/timezone-option.component.scss +5 -4
- package/timezone/timezone-option.directive.d.ts +3 -2
- package/title/title.directive.d.ts +0 -1
- package/toast/_toast-theme.scss +13 -16
- package/toast/toast-container.component.scss +2 -5
- package/toast/toast.component.scss +15 -17
- package/toggle/_toggle-theme.scss +22 -21
- package/toggle/toggle.scss +19 -21
- package/tooltip/_tooltip-theme.scss +26 -31
- package/tooltip/tooltip.component.d.ts +12 -8
- package/tooltip/tooltip.scss +13 -17
- package/tree/_tree-theme.scss +8 -8
- package/tree/toggle.scss +3 -5
- package/tree/tree-option.scss +5 -4
- package/tree-select/_tree-select-theme.scss +9 -9
- package/tree-select/tree-select.component.d.ts +1 -0
- package/tree-select/tree-select.scss +17 -35
- package/_theming.scss +0 -10827
- package/_visual.scss +0 -3541
- package/prebuilt-visual/default-visual.css +0 -1
@@ -2,98 +2,141 @@
|
|
2
2
|
@use 'sass:map';
|
3
3
|
|
4
4
|
@use '../core/styles/typography/typography-utils' as *;
|
5
|
+
@use '../core/styles/common/tokens' as *;
|
5
6
|
|
6
|
-
@mixin mc-file-upload-text-color($states) {
|
7
|
-
&, .mc-icon, .mc-link {
|
8
|
-
color: map.get($states, border);
|
9
|
-
}
|
10
|
-
}
|
11
|
-
|
12
|
-
@mixin mc-file-upload-color($states) {
|
13
|
-
background-color: map.get($states, background);
|
14
|
-
border-color: map.get($states, border) !important;
|
15
|
-
}
|
16
7
|
|
17
8
|
@mixin mc-file-upload-theme($theme) {
|
18
|
-
$
|
19
|
-
|
20
|
-
$
|
21
|
-
|
22
|
-
$
|
23
|
-
$
|
9
|
+
$foreground: map-get($theme, foreground);
|
10
|
+
|
11
|
+
$file-upload: map-get($theme, components, file-upload);
|
12
|
+
|
13
|
+
$single: map-get($file-upload, single);
|
14
|
+
$single-states: map-get($single, states);
|
15
|
+
|
16
|
+
$multiple: map-get($file-upload, multiple);
|
17
|
+
$multiple-states: map-get($multiple, states);
|
24
18
|
|
25
19
|
.mc-file-upload {
|
26
20
|
.mc-focused, .mc-link.mc-focused {
|
27
|
-
border: 2px solid
|
21
|
+
border: 2px solid mc-css-variable(states-focused-color, map-get($theme, states, focused-color));
|
28
22
|
}
|
29
23
|
}
|
30
24
|
|
31
25
|
.mc-single-file-upload {
|
32
26
|
.mc-file-upload {
|
33
|
-
|
27
|
+
background-color: mc-css-variable(
|
28
|
+
file-upload-single-default-background, map-get($single, default, background));
|
29
|
+
border-color: mc-css-variable(
|
30
|
+
file-upload-single-default-border, map-get($single, default, border)) !important;
|
34
31
|
|
35
32
|
&.dragover {
|
36
|
-
|
33
|
+
background-color: mc-css-variable(
|
34
|
+
file-upload-single-states-drag-n-drop-background, map-get($single-states, drag-n-drop, background));
|
35
|
+
border-color: mc-css-variable(
|
36
|
+
file-upload-single-states-drag-n-drop-border, map-get($single-states, drag-n-drop, border)
|
37
|
+
) !important;
|
37
38
|
}
|
38
39
|
|
39
40
|
&.mc-error:not(.disabled) {
|
40
41
|
&:not(.dragover) {
|
41
|
-
|
42
|
+
background-color: mc-css-variable(
|
43
|
+
file-upload-single-states-error-background, map-get($single-states, error, background));
|
44
|
+
border-color: mc-css-variable(
|
45
|
+
file-upload-single-states-error-border, map-get($single-states, error, border)) !important;
|
42
46
|
}
|
43
47
|
|
44
48
|
*, .mc-icon {
|
45
|
-
color: map
|
49
|
+
color: mc-css-variable(foreground-text-error, map-get($foreground, text-error));
|
46
50
|
}
|
47
51
|
}
|
48
52
|
|
49
53
|
&.disabled {
|
50
|
-
|
51
|
-
|
52
|
-
|
54
|
+
background-color: mc-css-variable(
|
55
|
+
file-upload-single-states-disabled-background, map-get($single-states, disabled, background));
|
56
|
+
border-color: mc-css-variable(
|
57
|
+
file-upload-single-states-disabled-border, map-get($single-states, disabled, border)) !important;
|
58
|
+
|
59
|
+
/* stylelint-disable no-descending-specificity */
|
60
|
+
&,
|
61
|
+
.mc-icon,
|
62
|
+
.mc-link {
|
63
|
+
color: mc-css-variable(
|
64
|
+
file-upload-single-states-disabled-text, map-get($single-states, disabled, text));
|
65
|
+
}
|
66
|
+
/* stylelint-enable no-descending-specificity */
|
53
67
|
}
|
54
68
|
}
|
55
69
|
}
|
56
70
|
|
57
71
|
.mc-multiple-file-upload {
|
58
72
|
.mc-file-upload {
|
59
|
-
|
73
|
+
background-color: mc-css-variable(
|
74
|
+
file-upload-multiple-default-background, map-get($multiple, default, background));
|
75
|
+
border-color: mc-css-variable(
|
76
|
+
file-upload-multiple-default-border, map-get($multiple, default, border)) !important;
|
60
77
|
|
61
78
|
.btn-upload {
|
62
79
|
.dropzone {
|
63
|
-
border-top-color:
|
80
|
+
border-top-color: mc-css-variable(
|
81
|
+
file-upload-multiple-default-border, map-get($multiple, default, border));
|
64
82
|
}
|
65
83
|
}
|
66
84
|
|
67
85
|
.mc-file-multiple-uploaded__header {
|
68
|
-
border-bottom-color:
|
86
|
+
border-bottom-color: mc-css-variable(
|
87
|
+
file-upload-multiple-default-border, map-get($multiple, default, border));
|
69
88
|
|
70
89
|
&-inner {
|
71
|
-
color: map
|
90
|
+
color: mc-css-variable(foreground-text-less-contrast, map-get($foreground, text-less-contrast));
|
72
91
|
}
|
73
92
|
}
|
74
93
|
|
75
94
|
&.dragover {
|
76
|
-
|
95
|
+
background-color: mc-css-variable(
|
96
|
+
file-upload-multiple-states-drag-n-drop-background,
|
97
|
+
map-get($multiple-states, drag-n-drop, background)
|
98
|
+
);
|
99
|
+
border-color: mc-css-variable(
|
100
|
+
file-upload-multiple-states-drag-n-drop-border, map-get($multiple-states, drag-n-drop, border)
|
101
|
+
) !important;
|
77
102
|
|
78
103
|
.mc-file-multiple-uploaded__header {
|
79
|
-
border-bottom-color:
|
104
|
+
border-bottom-color: mc-css-variable(
|
105
|
+
file-upload-multiple-states-drag-n-drop-background,
|
106
|
+
map-get($multiple-states, drag-n-drop, background)
|
107
|
+
) !important;
|
80
108
|
}
|
81
109
|
|
82
110
|
&.selected {
|
83
111
|
.dropzone {
|
84
|
-
border-top-color:
|
112
|
+
border-top-color: mc-css-variable(
|
113
|
+
file-upload-multiple-states-drag-n-drop-border,
|
114
|
+
map-get($multiple-states, drag-n-drop, border)
|
115
|
+
);
|
85
116
|
}
|
86
117
|
}
|
87
118
|
}
|
88
119
|
|
89
120
|
&.disabled {
|
90
|
-
|
91
|
-
|
92
|
-
|
121
|
+
background-color: mc-css-variable(
|
122
|
+
file-upload-multiple-states-disabled-background, map-get($multiple-states, disabled, background));
|
123
|
+
border-color: mc-css-variable(
|
124
|
+
file-upload-multiple-states-disabled-border, map-get($multiple-states, disabled, border)
|
125
|
+
) !important;
|
126
|
+
|
127
|
+
/* stylelint-disable no-descending-specificity */
|
128
|
+
&,
|
129
|
+
.mc-icon,
|
130
|
+
.mc-link {
|
131
|
+
color: mc-css-variable(
|
132
|
+
file-upload-multiple-states-disabled-text, map-get($multiple-states, disabled, text));
|
133
|
+
}
|
134
|
+
/* stylelint-enable no-descending-specificity */
|
93
135
|
|
94
136
|
&.selected {
|
95
137
|
.dropzone {
|
96
|
-
border-top-color:
|
138
|
+
border-top-color: mc-css-variable(
|
139
|
+
file-upload-multiple-states-disabled-border, map-get($multiple-states, disabled, border));
|
97
140
|
}
|
98
141
|
}
|
99
142
|
}
|
@@ -101,7 +144,7 @@
|
|
101
144
|
&:not(.disabled) {
|
102
145
|
.mc-file-upload__row.error {
|
103
146
|
*, .mc-icon {
|
104
|
-
color: map
|
147
|
+
color: mc-css-variable(foreground-text-error, map-get($foreground, text-error));
|
105
148
|
}
|
106
149
|
}
|
107
150
|
}
|
@@ -116,57 +159,47 @@
|
|
116
159
|
|
117
160
|
.mc-single-file-upload, .mc-multiple-file-upload {
|
118
161
|
.mc-file-upload__hint:not(.mc-error) {
|
119
|
-
color: map-get($foreground, text-less-contrast);
|
162
|
+
color: mc-css-variable(foreground-text-less-contrast, map-get($foreground, text-less-contrast));
|
120
163
|
}
|
121
164
|
}
|
122
165
|
}
|
123
166
|
|
124
167
|
|
125
168
|
@mixin mc-file-upload-typography($config) {
|
126
|
-
$tokens: map.get($config, tokens);
|
127
|
-
|
128
169
|
.mc-single-file-upload {
|
129
|
-
@include mc-typography-
|
170
|
+
@include mc-typography-css-variables(file-upload, single);
|
130
171
|
}
|
131
172
|
|
132
173
|
.mc-multiple-file-upload {
|
133
174
|
.multiple__header {
|
134
|
-
@include mc-typography-
|
175
|
+
@include mc-typography-css-variables(file-upload, multiple-header);
|
135
176
|
}
|
136
177
|
|
137
178
|
.multiple__caption {
|
138
179
|
&, .mc-link {
|
139
|
-
@include mc-typography-
|
140
|
-
$config, map.get($tokens, file-upload-font-multiple-caption)
|
141
|
-
);
|
180
|
+
@include mc-typography-css-variables(file-upload, multiple-caption);
|
142
181
|
}
|
143
182
|
}
|
144
183
|
|
145
184
|
.mc-file-multiple-uploaded__header {
|
146
|
-
@include mc-typography-
|
147
|
-
$config,
|
148
|
-
map.get($tokens, file-upload-font-multiple-uploaded-header)
|
149
|
-
);
|
185
|
+
@include mc-typography-css-variables(file-upload, multiple-uploaded-header);
|
150
186
|
}
|
151
187
|
|
152
188
|
.multiple__uploaded-item {
|
153
|
-
@include mc-typography-
|
189
|
+
@include mc-typography-css-variables(file-upload, multiple-uploaded-item);
|
154
190
|
}
|
155
191
|
|
156
192
|
.mc-file-upload {
|
157
193
|
.mc-list-item,
|
158
194
|
.mc-list-option {
|
159
|
-
@include mc-typography-
|
160
|
-
$config,
|
161
|
-
map.get($tokens, file-upload-font-multiple-uploaded-item)
|
162
|
-
);
|
195
|
+
@include mc-typography-css-variables(file-upload, multiple-uploaded-item);
|
163
196
|
}
|
164
197
|
}
|
165
198
|
}
|
166
199
|
|
167
200
|
.mc-single-file-upload, .mc-multiple-file-upload {
|
168
201
|
.mc-file-upload__hint {
|
169
|
-
@include mc-typography-
|
202
|
+
@include mc-typography-css-variables(form-field-hint, default);
|
170
203
|
}
|
171
204
|
}
|
172
205
|
}
|
@@ -11,8 +11,9 @@ import * as i9 from "@ptsecurity/mosaic/list";
|
|
11
11
|
import * as i10 from "@ptsecurity/mosaic/form-field";
|
12
12
|
import * as i11 from "@ptsecurity/mosaic/ellipsis-center";
|
13
13
|
import * as i12 from "@ptsecurity/mosaic/core";
|
14
|
+
import * as i13 from "@ptsecurity/mosaic/link";
|
14
15
|
export declare class McFileUploadModule {
|
15
16
|
static ɵfac: i0.ɵɵFactoryDeclaration<McFileUploadModule, never>;
|
16
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<McFileUploadModule, [typeof i1.McFileDropDirective, typeof i2.McSingleFileUploadComponent, typeof i3.McMultipleFileUploadComponent], [typeof i4.CommonModule, typeof i5.McToolTipModule, typeof i6.McProgressSpinnerModule, typeof i7.McIconModule, typeof i8.McButtonModule, typeof i9.McListModule, typeof i10.McFormFieldModule, typeof i11.McEllipsisCenterModule, typeof i12.McDataSizeModule], [typeof i2.McSingleFileUploadComponent, typeof i3.McMultipleFileUploadComponent, typeof i1.McFileDropDirective]>;
|
17
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<McFileUploadModule, [typeof i1.McFileDropDirective, typeof i2.McSingleFileUploadComponent, typeof i3.McMultipleFileUploadComponent], [typeof i4.CommonModule, typeof i5.McToolTipModule, typeof i6.McProgressSpinnerModule, typeof i7.McIconModule, typeof i8.McButtonModule, typeof i9.McListModule, typeof i10.McFormFieldModule, typeof i11.McEllipsisCenterModule, typeof i12.McDataSizeModule, typeof i13.McLinkModule], [typeof i2.McSingleFileUploadComponent, typeof i3.McMultipleFileUploadComponent, typeof i1.McFileDropDirective]>;
|
17
18
|
static ɵinj: i0.ɵɵInjectorDeclaration<McFileUploadModule>;
|
18
19
|
}
|
@@ -1,31 +1,16 @@
|
|
1
|
-
@use 'sass:meta';
|
2
|
-
@use 'sass:map';
|
3
1
|
|
4
|
-
@use '../core/styles/tokens';
|
5
|
-
|
6
|
-
@use '../core/styles/common';
|
7
|
-
|
8
|
-
$tokens: meta.module-variables(tokens) !default;
|
9
|
-
$dropzone-text-margin-left: map.get($tokens, size-xs);
|
10
2
|
|
11
3
|
.mc-file-upload {
|
12
4
|
box-sizing: border-box;
|
13
5
|
display: flex;
|
14
6
|
align-items: center;
|
15
7
|
position: relative;
|
16
|
-
cursor: pointer;
|
17
8
|
|
18
9
|
.dropzone, .file-item {
|
19
10
|
display: flex;
|
20
11
|
align-items: center;
|
21
12
|
}
|
22
13
|
|
23
|
-
.dropzone {
|
24
|
-
.dropzone__text {
|
25
|
-
margin-left: $dropzone-text-margin-left;
|
26
|
-
}
|
27
|
-
}
|
28
|
-
|
29
14
|
.mc-ellipsis-center {
|
30
15
|
position: relative;
|
31
16
|
display: flex;
|
@@ -1,5 +1,4 @@
|
|
1
|
-
import {
|
2
|
-
import { AfterViewInit, ChangeDetectorRef, ElementRef, EventEmitter, OnDestroy, Renderer2, TemplateRef } from '@angular/core';
|
1
|
+
import { ElementRef, EventEmitter, Renderer2, TemplateRef } from '@angular/core';
|
3
2
|
import { CanDisable } from '@ptsecurity/mosaic/core';
|
4
3
|
import { McFile, McFileItem, McFileValidatorFn, McInputFile, McInputFileLabel } from './file-upload';
|
5
4
|
import * as i0 from "@angular/core";
|
@@ -13,9 +12,7 @@ export interface McInputFileMultipleLabel extends McInputFileLabel {
|
|
13
12
|
[k: string | number | symbol]: unknown;
|
14
13
|
}
|
15
14
|
export declare const MC_MULTIPLE_FILE_UPLOAD_DEFAULT_CONFIGURATION: McInputFileMultipleLabel;
|
16
|
-
export declare class McMultipleFileUploadComponent implements
|
17
|
-
private focusMonitor;
|
18
|
-
private cdr;
|
15
|
+
export declare class McMultipleFileUploadComponent implements McInputFile, CanDisable {
|
19
16
|
private renderer;
|
20
17
|
config: McInputFileMultipleLabel;
|
21
18
|
accept?: string[];
|
@@ -28,25 +25,20 @@ export declare class McMultipleFileUploadComponent implements AfterViewInit, OnD
|
|
28
25
|
fileQueueChanged: EventEmitter<McFileItem[]>;
|
29
26
|
customFileIcon: TemplateRef<HTMLElement>;
|
30
27
|
input: ElementRef<HTMLInputElement>;
|
31
|
-
hasFocus: boolean;
|
32
28
|
columnDefs: {
|
33
29
|
header: string;
|
34
30
|
cssClass: string;
|
35
31
|
}[];
|
36
|
-
private focusMonitorSubscription;
|
37
32
|
get acceptedFiles(): string;
|
38
33
|
get hasErrors(): boolean;
|
39
|
-
constructor(
|
40
|
-
ngAfterViewInit(): void;
|
41
|
-
ngOnDestroy(): void;
|
34
|
+
constructor(renderer: Renderer2, config: McInputFileMultipleLabel);
|
42
35
|
onFileSelectedViaClick({ target }: Event): void;
|
43
36
|
onFileDropped(files: FileList | McFile[]): void;
|
44
37
|
deleteFile(index: number, event?: MouseEvent): void;
|
45
38
|
onFileListChange(): void;
|
46
|
-
onFocus(focusState: boolean): void;
|
47
39
|
private mapToFileItem;
|
48
40
|
private validateFile;
|
49
41
|
private isCorrectExtension;
|
50
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<McMultipleFileUploadComponent, [null,
|
42
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<McMultipleFileUploadComponent, [null, { optional: true; }]>;
|
51
43
|
static ɵcmp: i0.ɵɵComponentDeclaration<McMultipleFileUploadComponent, "mc-multiple-file-upload", never, { "accept": { "alias": "accept"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "errors": { "alias": "errors"; "required": false; }; "files": { "alias": "files"; "required": false; }; "size": { "alias": "size"; "required": false; }; "inputId": { "alias": "inputId"; "required": false; }; "customValidation": { "alias": "customValidation"; "required": false; }; }, { "fileQueueChanged": "fileQueueChanged"; }, ["customFileIcon"], ["[hint]"], false, never>;
|
52
44
|
}
|
@@ -4,59 +4,25 @@
|
|
4
4
|
@use '../core/styles/tokens';
|
5
5
|
|
6
6
|
@use '../core/styles/common';
|
7
|
+
@use '../core/styles/common/tokens' as *;
|
8
|
+
|
7
9
|
|
8
10
|
$tokens: meta.module-variables(tokens) !default;
|
9
11
|
|
10
|
-
$dropzone-text-margin-left: map.get($tokens, size-xs);
|
11
12
|
$multiple-default-height: 176px;
|
12
13
|
$border-type-header: solid;
|
13
14
|
|
14
|
-
$horizontal-padding-item:
|
15
|
-
|
16
|
-
map.get($tokens, file-upload-size-multiple-uploaded-item-horizontal-padding)
|
17
|
-
);
|
18
|
-
$vertical-padding-item: var(
|
19
|
-
--mc-file-upload-size-multiple-uploaded-item-vertical-padding,
|
20
|
-
map.get($tokens, file-upload-size-multiple-uploaded-item-vertical-padding)
|
21
|
-
);
|
15
|
+
$horizontal-padding-item: mc-css-variable(file-upload-size-multiple-uploaded-item-horizontal-padding);
|
16
|
+
$vertical-padding-item: mc-css-variable(file-upload-size-multiple-uploaded-item-vertical-padding);
|
22
17
|
|
23
18
|
.mc-file-upload {
|
24
|
-
border-radius:
|
25
|
-
|
26
|
-
|
27
|
-
);
|
28
|
-
border-width: var(
|
29
|
-
--mc-file-upload-size-multiple-border-width,
|
30
|
-
map.get($tokens, file-upload-size-multiple-border-width)
|
31
|
-
);
|
32
|
-
border-style: var(
|
33
|
-
--mc-file-upload-size-multiple-border-style,
|
34
|
-
map.get($tokens, file-upload-size-multiple-border-style)
|
35
|
-
);
|
36
|
-
|
37
|
-
&.default {
|
38
|
-
min-height: $multiple-default-height;
|
39
|
-
justify-content: center;
|
40
|
-
}
|
41
|
-
|
42
|
-
&.compact:not(.selected) {
|
43
|
-
height: var(
|
44
|
-
--mc-file-upload-size-single-height,
|
45
|
-
map.get($tokens, file-upload-size-single-height)
|
46
|
-
);
|
47
|
-
padding-top: var(
|
48
|
-
--mc-file-upload-size-single-vertical-padding,
|
49
|
-
map.get($tokens, file-upload-size-single-vertical-padding)
|
50
|
-
);
|
51
|
-
padding-bottom: var(
|
52
|
-
--mc-file-upload-size-single-vertical-padding,
|
53
|
-
map.get($tokens, file-upload-size-single-vertical-padding)
|
54
|
-
);
|
55
|
-
padding-left: map.get($tokens, size-m);
|
56
|
-
}
|
19
|
+
border-radius: mc-css-variable(file-upload-size-multiple-border-radius);
|
20
|
+
border-width: mc-css-variable(file-upload-size-multiple-border-width);
|
21
|
+
border-style: mc-css-variable(file-upload-size-multiple-border-style);
|
57
22
|
|
58
23
|
.mc-list-option {
|
59
24
|
padding: $horizontal-padding-item $vertical-padding-item;
|
25
|
+
height: 36px;
|
60
26
|
|
61
27
|
.mc-icon {
|
62
28
|
margin-right: 0;
|
@@ -64,7 +30,7 @@ $vertical-padding-item: var(
|
|
64
30
|
}
|
65
31
|
|
66
32
|
.mc-file-upload__grid {
|
67
|
-
min-height:
|
33
|
+
min-height: 142px;
|
68
34
|
}
|
69
35
|
|
70
36
|
.mc-file-multiple-uploaded__header-inner,
|
@@ -90,6 +56,11 @@ $vertical-padding-item: var(
|
|
90
56
|
padding-left: $horizontal-padding-item;
|
91
57
|
padding-right: $horizontal-padding-item;
|
92
58
|
}
|
59
|
+
|
60
|
+
.mc-file-upload__action {
|
61
|
+
display: flex;
|
62
|
+
align-items: center;
|
63
|
+
}
|
93
64
|
}
|
94
65
|
|
95
66
|
.mc-file-upload__row {
|
@@ -113,26 +84,59 @@ $vertical-padding-item: var(
|
|
113
84
|
border: 2px solid transparent;
|
114
85
|
border-bottom: unset;
|
115
86
|
box-sizing: border-box;
|
116
|
-
height:
|
87
|
+
height: mc-css-variable(size-3xl);
|
117
88
|
}
|
118
89
|
|
119
90
|
}
|
120
91
|
|
121
92
|
.btn-upload {
|
122
93
|
.dropzone {
|
94
|
+
$padding-top: map.get($tokens, size-xxs);
|
123
95
|
margin: 0;
|
124
|
-
border-top-width:
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
96
|
+
border-top-width: mc-css-variable(file-upload-size-multiple-border-width);
|
97
|
+
border-top-style: mc-css-variable(file-upload-size-multiple-border-style);
|
98
|
+
padding: calc($padding-top - 1px)
|
99
|
+
map.get($tokens, size-m)
|
100
|
+
map.get($tokens, size-xxs)
|
101
|
+
map.get($tokens, size-m);
|
102
|
+
}
|
103
|
+
}
|
104
|
+
|
105
|
+
&.compact {
|
106
|
+
&:not(.selected) {
|
107
|
+
height: mc-css-variable(file-upload-size-single-height);
|
108
|
+
padding-top: mc-css-variable(file-upload-size-single-vertical-padding);
|
109
|
+
padding-bottom: mc-css-variable(file-upload-size-single-vertical-padding);
|
110
|
+
padding-left: map.get($tokens, size-m);
|
111
|
+
}
|
112
|
+
|
113
|
+
.dropzone {
|
114
|
+
.dropzone__text {
|
115
|
+
margin-left: map.get($tokens, size-xs);
|
116
|
+
}
|
117
|
+
}
|
118
|
+
}
|
119
|
+
|
120
|
+
&.default {
|
121
|
+
min-height: $multiple-default-height;
|
122
|
+
justify-content: center;
|
123
|
+
|
124
|
+
.dropzone {
|
125
|
+
.dropzone__text {
|
126
|
+
margin-left: map.get($tokens, size-l);
|
127
|
+
}
|
128
|
+
}
|
129
|
+
|
130
|
+
.btn-upload {
|
131
|
+
.dropzone {
|
132
|
+
.dropzone__text {
|
133
|
+
margin-left: map.get($tokens, size-xs);
|
134
|
+
}
|
135
|
+
}
|
133
136
|
}
|
134
137
|
}
|
135
138
|
|
139
|
+
|
136
140
|
.file-upload__dropzone {
|
137
141
|
width: 100%;
|
138
142
|
height: 100%;
|
@@ -144,5 +148,5 @@ $vertical-padding-item: var(
|
|
144
148
|
}
|
145
149
|
|
146
150
|
.mc-file-upload__hint {
|
147
|
-
margin-top:
|
151
|
+
margin-top: mc-css-variable(form-field-hint-size-margin-top);
|
148
152
|
}
|
@@ -1,12 +1,9 @@
|
|
1
|
-
import {
|
2
|
-
import { AfterViewInit, ChangeDetectorRef, ElementRef, EventEmitter, OnDestroy, Renderer2 } from '@angular/core';
|
1
|
+
import { ElementRef, EventEmitter, Renderer2 } from '@angular/core';
|
3
2
|
import { CanDisable } from '@ptsecurity/mosaic/core';
|
4
3
|
import { McFile, McFileItem, McFileValidatorFn, McInputFile, McInputFileLabel } from './file-upload';
|
5
4
|
import * as i0 from "@angular/core";
|
6
5
|
export declare const MC_SINGLE_FILE_UPLOAD_DEFAULT_CONFIGURATION: McInputFileLabel;
|
7
|
-
export declare class McSingleFileUploadComponent implements
|
8
|
-
private focusMonitor;
|
9
|
-
private cdr;
|
6
|
+
export declare class McSingleFileUploadComponent implements McInputFile, CanDisable {
|
10
7
|
private renderer;
|
11
8
|
config: McInputFileLabel;
|
12
9
|
accept: string[];
|
@@ -17,19 +14,14 @@ export declare class McSingleFileUploadComponent implements AfterViewInit, OnDes
|
|
17
14
|
customValidation?: McFileValidatorFn[];
|
18
15
|
fileQueueChanged: EventEmitter<McFileItem | null>;
|
19
16
|
input: ElementRef<HTMLInputElement>;
|
20
|
-
hasFocus: boolean;
|
21
|
-
private focusMonitorSubscription;
|
22
17
|
get acceptedFiles(): string;
|
23
|
-
constructor(
|
24
|
-
ngAfterViewInit(): void;
|
25
|
-
ngOnDestroy(): void;
|
18
|
+
constructor(renderer: Renderer2, config: McInputFileLabel);
|
26
19
|
onFileSelectedViaClick({ target }: Event): void;
|
27
20
|
deleteItem(event?: MouseEvent): void;
|
28
21
|
onFileDropped(files: FileList | McFile[]): void;
|
29
|
-
onFocus(focusState: boolean): void;
|
30
22
|
private mapToFileItem;
|
31
23
|
private validateFile;
|
32
24
|
private isCorrectExtension;
|
33
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<McSingleFileUploadComponent, [null,
|
25
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<McSingleFileUploadComponent, [null, { optional: true; }]>;
|
34
26
|
static ɵcmp: i0.ɵɵComponentDeclaration<McSingleFileUploadComponent, "mc-single-file-upload", never, { "accept": { "alias": "accept"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "errors": { "alias": "errors"; "required": false; }; "files": { "alias": "files"; "required": false; }; "inputId": { "alias": "inputId"; "required": false; }; "customValidation": { "alias": "customValidation"; "required": false; }; }, { "fileQueueChanged": "fileQueueChanged"; }, never, ["[hint]", "[mc-icon]"], false, never>;
|
35
27
|
}
|
@@ -4,35 +4,26 @@
|
|
4
4
|
@use '../core/styles/tokens';
|
5
5
|
|
6
6
|
@use '../core/styles/common';
|
7
|
+
@use '../core/styles/common/tokens' as *;
|
8
|
+
|
7
9
|
|
8
10
|
$tokens: meta.module-variables(tokens) !default;
|
9
11
|
|
10
12
|
.mc-file-upload {
|
11
|
-
height:
|
12
|
-
|
13
|
-
|
14
|
-
);
|
15
|
-
padding-top: var(
|
16
|
-
--mc-file-upload-size-single-vertical-padding,
|
17
|
-
map.get($tokens, file-upload-size-single-vertical-padding)
|
18
|
-
);
|
19
|
-
padding-bottom: var(
|
20
|
-
--mc-file-upload-size-single-vertical-padding,
|
21
|
-
map.get($tokens, file-upload-size-single-vertical-padding)
|
22
|
-
);
|
13
|
+
height: mc-css-variable(file-upload-size-single-height);
|
14
|
+
padding-top: mc-css-variable(file-upload-size-single-vertical-padding);
|
15
|
+
padding-bottom: mc-css-variable(file-upload-size-single-vertical-padding);
|
23
16
|
padding-left: map.get($tokens, size-m);
|
24
17
|
|
25
|
-
border-radius:
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
map.get($tokens, file-upload-size-single-border-style)
|
35
|
-
);
|
18
|
+
border-radius: mc-css-variable(file-upload-size-single-border-radius);
|
19
|
+
border-width: mc-css-variable(file-upload-size-single-border-width);
|
20
|
+
border-style: mc-css-variable(file-upload-size-single-border-style);
|
21
|
+
|
22
|
+
.dropzone {
|
23
|
+
.dropzone__text {
|
24
|
+
margin-left: map.get($tokens, size-xs);
|
25
|
+
}
|
26
|
+
}
|
36
27
|
|
37
28
|
.file-item {
|
38
29
|
width: 100%;
|
@@ -56,5 +47,5 @@ $tokens: meta.module-variables(tokens) !default;
|
|
56
47
|
}
|
57
48
|
|
58
49
|
.mc-file-upload__hint {
|
59
|
-
margin-top:
|
50
|
+
margin-top: mc-css-variable(form-field-hint-size-margin-top);
|
60
51
|
}
|