@enigmatry/entry-components 1.15.1-preview.10 → 1.15.1-preview.12
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/styles/_generator.scss +2 -0
- package/styles/modules/_angular-material-generator.scss +34 -0
- package/styles/modules/_default-theme.scss +5 -3
- package/styles/modules/_palette-generator.scss +32 -0
- package/styles/modules/components/tables/_rows.scss +6 -31
- package/styles/partials/core/components/tables/_action-cells.scss +6 -16
- package/styles/partials/core/components/tables/_cells.scss +9 -1
- package/styles/partials/core/components/tables/_layout.scss +0 -4
- package/styles/partials/core/components/tables/_rows.scss +5 -3
- /package/styles/partials/{test.scss → generator-test.scss} +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@enigmatry/entry-components",
|
|
3
|
-
"version": "1.15.1-preview.
|
|
3
|
+
"version": "1.15.1-preview.12",
|
|
4
4
|
"author": "Enigmatry",
|
|
5
5
|
"description": "Enigmatry entry angular material components",
|
|
6
6
|
"homepage": "https://github.com/enigmatry/entry-angular-building-blocks/tree/master/libs/entry-components#readme",
|
package/styles/_generator.scss
CHANGED
|
@@ -4,11 +4,13 @@
|
|
|
4
4
|
@use 'modules/components/forms/generator' as form;
|
|
5
5
|
@use 'modules/elements/generator' as elements;
|
|
6
6
|
@use 'modules/default-theme' as default;
|
|
7
|
+
@use 'modules/angular-material-generator' as material-theme;
|
|
7
8
|
@use 'sass:map';
|
|
8
9
|
|
|
9
10
|
@mixin generate-from($custom-theme: ()) {
|
|
10
11
|
$merged-theme: map.deep-merge(default.$theme, $custom-theme);
|
|
11
12
|
|
|
13
|
+
@include material-theme.generate-from($merged-theme);
|
|
12
14
|
@include elements.generate-from($merged-theme);
|
|
13
15
|
@include table.generate-from($merged-theme);
|
|
14
16
|
@include form.generate-from($merged-theme);
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
@use '@angular/material' as theming;
|
|
2
|
+
@use 'palette-generator';
|
|
3
|
+
@use 'sass:map';
|
|
4
|
+
|
|
5
|
+
/* stylelint-disable scss/function-no-unknown */
|
|
6
|
+
@mixin generate-from($theme) {
|
|
7
|
+
@include theming.core();
|
|
8
|
+
|
|
9
|
+
$primary-palette: theming.define-palette(-get-material-palette-for('primary', $theme));
|
|
10
|
+
$accent-palette: theming.define-palette(-get-material-palette-for('accent', $theme));
|
|
11
|
+
$warn-palette: theming.define-palette(theming.$red-palette);
|
|
12
|
+
|
|
13
|
+
$default-theme: theming.define-light-theme((
|
|
14
|
+
color: (
|
|
15
|
+
primary: $primary-palette,
|
|
16
|
+
accent: $accent-palette,
|
|
17
|
+
warn: $warn-palette
|
|
18
|
+
),
|
|
19
|
+
typography: theming.define-typography-config()
|
|
20
|
+
));
|
|
21
|
+
|
|
22
|
+
@include theming.all-component-themes($default-theme);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
@function -get-material-palette-for($key, $theme) {
|
|
26
|
+
$palette: map.get($theme, 'general', 'colors', $key + '-theme');
|
|
27
|
+
|
|
28
|
+
@if $palette {
|
|
29
|
+
@return $palette;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
$color: map.get($theme, 'general', 'colors', $key);
|
|
33
|
+
@return palette-generator.generate-from($color);
|
|
34
|
+
}
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
$theme: (
|
|
3
3
|
general: (
|
|
4
4
|
colors: (
|
|
5
|
+
primary-theme: null,
|
|
6
|
+
accent-theme: null,
|
|
5
7
|
primary: #2581C4,
|
|
6
8
|
accent: #EA518D,
|
|
7
9
|
dark: #323232,
|
|
@@ -31,7 +33,7 @@ $theme: (
|
|
|
31
33
|
border-right: none,
|
|
32
34
|
border-left: none,
|
|
33
35
|
disabled-background: #F5F5F5,
|
|
34
|
-
disabled-hover: 2px solid #EBEBEB
|
|
36
|
+
disabled-hover: 2px solid #EBEBEB
|
|
35
37
|
)
|
|
36
38
|
),
|
|
37
39
|
checkboxes: (
|
|
@@ -44,11 +46,11 @@ $theme: (
|
|
|
44
46
|
border: 2px solid #0000008A,
|
|
45
47
|
border-hover: 2px solid #0000008A,
|
|
46
48
|
border-radius: 0,
|
|
47
|
-
label-breaking: nowrap
|
|
49
|
+
label-breaking: nowrap
|
|
48
50
|
),
|
|
49
51
|
radio-buttons: (
|
|
50
52
|
align: flex-start,
|
|
51
|
-
white-space: nowrap
|
|
53
|
+
white-space: nowrap
|
|
52
54
|
),
|
|
53
55
|
),
|
|
54
56
|
tables: (
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
@use 'sass:color';
|
|
2
|
+
@use 'sass:map';
|
|
3
|
+
|
|
4
|
+
@function generate-from($color) {
|
|
5
|
+
$result: (
|
|
6
|
+
50: color.adjust($color, $lightness: -30%),
|
|
7
|
+
contrast: (
|
|
8
|
+
50: #212121,
|
|
9
|
+
100: #212121,
|
|
10
|
+
200: #212121,
|
|
11
|
+
300: #212121,
|
|
12
|
+
400: #212121,
|
|
13
|
+
500: #FFF,
|
|
14
|
+
600: #FFF,
|
|
15
|
+
700: #FFF,
|
|
16
|
+
800: #FFF,
|
|
17
|
+
900: #FFF,
|
|
18
|
+
a100: #212121,
|
|
19
|
+
a200: #212121,
|
|
20
|
+
a400: #FFF,
|
|
21
|
+
a700: #FFF
|
|
22
|
+
)
|
|
23
|
+
);
|
|
24
|
+
|
|
25
|
+
@for $counter from 1 through 9 {
|
|
26
|
+
$blended-color: color.adjust($color, $lightness: -27 + $counter * 5%);
|
|
27
|
+
/* stylelint-disable-next-line scss/no-duplicate-dollar-variables */
|
|
28
|
+
$result: map.set($result, $counter * 100, $blended-color);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
@return $result;
|
|
32
|
+
}
|
|
@@ -4,40 +4,20 @@
|
|
|
4
4
|
@mixin generate-from($theme) {
|
|
5
5
|
.mat-mdc-row {
|
|
6
6
|
$edge-selected-color: map.get($theme, 'forms', 'checkboxes', 'selected-border-color');
|
|
7
|
-
|
|
7
|
+
|
|
8
8
|
@include list.row-coloring(map.get($theme, 'tables', 'rows', 'odd-even-background'),
|
|
9
9
|
map.get($theme, 'tables', 'rows', 'odd-even-row'));
|
|
10
10
|
|
|
11
|
-
/* TODO(mdc-migration): The following rule targets internal classes of checkbox that may no longer apply for the MDC version. */
|
|
12
|
-
.mat-checkbox-inner-container {
|
|
13
|
-
background-color: map.get($theme, 'forms', 'checkboxes', 'background-color');
|
|
14
|
-
}
|
|
15
|
-
|
|
16
11
|
&.selected {
|
|
17
12
|
background-color: map.get($theme, 'tables', 'rows', 'selected-background-color');
|
|
18
|
-
|
|
19
|
-
|
|
13
|
+
|
|
14
|
+
&:hover {
|
|
15
|
+
background-color: map.get($theme, 'tables', 'rows', 'selected-background-color');
|
|
20
16
|
color: map.get($theme, 'tables', 'rows', 'selected-color');
|
|
21
17
|
}
|
|
22
18
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
/* TODO(mdc-migration): The following rule targets internal classes of checkbox that may no longer apply for the MDC version. */
|
|
26
|
-
.mat-checkbox-background {
|
|
27
|
-
background-color: map.get($theme, 'forms', 'checkboxes', 'selected-background-color');
|
|
28
|
-
|
|
29
|
-
/* TODO(mdc-migration): The following rule targets internal classes of checkbox that may no longer apply for the MDC version. */
|
|
30
|
-
/* stylelint-disable-next-line max-nesting-depth, selector-max-combinators, selector-max-compound-selectors */
|
|
31
|
-
.mat-checkbox-checkmark-path {
|
|
32
|
-
/* stylelint-disable-next-line declaration-no-important */
|
|
33
|
-
stroke: $edge-selected-color !important;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
/* TODO(mdc-migration): The following rule targets internal classes of checkbox that may no longer apply for the MDC version. */
|
|
38
|
-
.mat-checkbox-frame {
|
|
39
|
-
border-color: $edge-selected-color;
|
|
40
|
-
}
|
|
19
|
+
.mat-mdc-cell {
|
|
20
|
+
color: map.get($theme, 'tables', 'rows', 'selected-color');
|
|
41
21
|
}
|
|
42
22
|
}
|
|
43
23
|
}
|
|
@@ -45,9 +25,4 @@
|
|
|
45
25
|
.mat-row-disabled {
|
|
46
26
|
background-color: map.get($theme, 'general', 'colors', 'disabled-light');
|
|
47
27
|
}
|
|
48
|
-
|
|
49
|
-
.entry-table-menu .context-menu-item:hover {
|
|
50
|
-
background-color: map.get($theme, 'general', 'colors', 'accent');
|
|
51
|
-
color: map.get($theme, 'general', 'colors', 'dark');
|
|
52
|
-
}
|
|
53
28
|
}
|
|
@@ -1,26 +1,16 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
.entry-table .mat-icon-button {
|
|
2
|
+
padding-top: 8px;
|
|
3
|
+
border: none;
|
|
4
|
+
background-color: transparent;
|
|
5
|
+
cursor: pointer;
|
|
6
6
|
}
|
|
7
7
|
|
|
8
|
-
.entry-table-checkbox-cell
|
|
8
|
+
.entry-table-checkbox-cell {
|
|
9
9
|
flex: none;
|
|
10
10
|
width: 56px;
|
|
11
11
|
max-width: 40px;
|
|
12
12
|
|
|
13
13
|
.mat-mdc-checkbox {
|
|
14
14
|
display: flex;
|
|
15
|
-
margin: 0 10px;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
/* TODO(mdc-migration): The following rule targets internal classes of checkbox that may no longer apply for the MDC version. */
|
|
19
|
-
.mat-checkbox-inner-container {
|
|
20
|
-
margin-left: 0;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.mat-mdc-icon-button {
|
|
24
|
-
padding-top: 2px;
|
|
25
15
|
}
|
|
26
16
|
}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
@use '@enigmatry/scss-foundation/src/modules/display/items';
|
|
2
|
+
|
|
1
3
|
.entry-table {
|
|
2
4
|
.mat-mdc-cell, .mat-mdc-header-cell {
|
|
3
5
|
padding: 0 10px;
|
|
@@ -14,6 +16,12 @@
|
|
|
14
16
|
left: 10px;
|
|
15
17
|
}
|
|
16
18
|
}
|
|
19
|
+
|
|
20
|
+
&.entry-table-context-menu-cell {
|
|
21
|
+
@include items.fully-align(center, flex-end);
|
|
22
|
+
/* stylelint-disable-next-line declaration-no-important */
|
|
23
|
+
min-width: unset !important;
|
|
24
|
+
}
|
|
17
25
|
}
|
|
18
26
|
|
|
19
27
|
.mat-mdc-table {
|
|
@@ -36,4 +44,4 @@
|
|
|
36
44
|
justify-content: right;
|
|
37
45
|
}
|
|
38
46
|
}
|
|
39
|
-
}
|
|
47
|
+
}
|
|
@@ -18,10 +18,6 @@
|
|
|
18
18
|
min-width: 100%;
|
|
19
19
|
border-collapse: separate;
|
|
20
20
|
}
|
|
21
|
-
/* TODO(mdc-migration): The following rule targets internal classes of paginator that may no longer apply for the MDC version. */
|
|
22
|
-
.mat-paginator-hidden {
|
|
23
|
-
display: none;
|
|
24
|
-
}
|
|
25
21
|
}
|
|
26
22
|
|
|
27
23
|
.entry-table-layout {
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
.entry-table {
|
|
2
|
-
.mat-
|
|
3
|
-
|
|
2
|
+
.mat-mdc-table {
|
|
3
|
+
.mdc-data-table__header-row, .mdc-data-table__row {
|
|
4
|
+
height: 36px;
|
|
5
|
+
}
|
|
4
6
|
}
|
|
5
7
|
}
|
|
6
8
|
|
|
7
9
|
.entry-table-menu {
|
|
8
10
|
min-height: 40px;
|
|
9
11
|
|
|
10
|
-
.mat-menu-content:not(:empty) {
|
|
12
|
+
.mat-mdc-menu-content:not(:empty) {
|
|
11
13
|
padding: 0;
|
|
12
14
|
}
|
|
13
15
|
}
|
|
File without changes
|