@elderbyte/ngx-starter 14.4.0-beta.24 → 14.4.0-beta.25

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.
Files changed (26) hide show
  1. package/_index.scss +3 -0
  2. package/esm2020/lib/common/forms/elder-form-field-control-base.directive.mjs +9 -4
  3. package/esm2020/lib/common/forms/elder-from-field-base.mjs +1 -2
  4. package/esm2020/lib/common/forms/elder-from-field-multi-entity-base.mjs +3 -4
  5. package/esm2020/lib/components/data-view/base/elder-data-view-base.mjs +3 -3
  6. package/esm2020/lib/components/data-view/grid/elder-grid/elder-grid.component.mjs +2 -2
  7. package/esm2020/lib/components/forms/search/search-box/elder-search-box.component.mjs +4 -4
  8. package/esm2020/lib/components/panels/card-panel/elder-card-panel.component.mjs +1 -3
  9. package/esm2020/lib/components/panels/elder-dialog-panel/elder-dialog-panel.component.mjs +13 -0
  10. package/esm2020/lib/components/panels/elder-panel.module.mjs +11 -5
  11. package/esm2020/lib/components/select/multi/elder-multi-select-base.mjs +2 -2
  12. package/fesm2015/elderbyte-ngx-starter.mjs +36 -21
  13. package/fesm2015/elderbyte-ngx-starter.mjs.map +1 -1
  14. package/fesm2020/elderbyte-ngx-starter.mjs +36 -21
  15. package/fesm2020/elderbyte-ngx-starter.mjs.map +1 -1
  16. package/lib/components/panels/card-panel/elder-card-panel.component.d.ts +1 -3
  17. package/lib/components/panels/elder-dialog-panel/elder-dialog-panel.component.d.ts +6 -0
  18. package/lib/components/panels/elder-panel.module.d.ts +6 -4
  19. package/package.json +1 -1
  20. package/src/lib/components/data-view/grid/elder-grid/elder-grid.component.scss +13 -23
  21. package/src/lib/components/forms/search/search-box/elder-search-box.component.scss +1 -1
  22. package/src/lib/components/panels/elder-dialog-panel/elder-dialog-panel.component.scss +22 -0
  23. package/theming/_elder-palettes.scss +59 -0
  24. package/theming/_elder-scrollbar-theme.scss +1 -1
  25. package/theming/_elder-theme.scss +46 -0
  26. package/theming/_elder-toast-theme.scss +5 -5
@@ -1,8 +1,6 @@
1
- import { OnInit } from '@angular/core';
2
1
  import * as i0 from "@angular/core";
3
- export declare class ElderCardPanelComponent implements OnInit {
2
+ export declare class ElderCardPanelComponent {
4
3
  constructor();
5
- ngOnInit(): void;
6
4
  static ɵfac: i0.ɵɵFactoryDeclaration<ElderCardPanelComponent, never>;
7
5
  static ɵcmp: i0.ɵɵComponentDeclaration<ElderCardPanelComponent, "elder-card-panel", never, {}, {}, never, ["*"], false>;
8
6
  }
@@ -0,0 +1,6 @@
1
+ import * as i0 from "@angular/core";
2
+ export declare class ElderDialogPanelComponent {
3
+ constructor();
4
+ static ɵfac: i0.ɵɵFactoryDeclaration<ElderDialogPanelComponent, never>;
5
+ static ɵcmp: i0.ɵɵComponentDeclaration<ElderDialogPanelComponent, "elder-dialog-panel", never, {}, {}, never, ["*"], false>;
6
+ }
@@ -1,13 +1,15 @@
1
1
  import * as i0 from "@angular/core";
2
2
  import * as i1 from "./flat/elder-panel.component";
3
3
  import * as i2 from "./card-panel/elder-card-panel.component";
4
- import * as i3 from "@angular/common";
5
- import * as i4 from "@angular/material/core";
6
- import * as i5 from "@angular/flex-layout";
4
+ import * as i3 from "./elder-dialog-panel/elder-dialog-panel.component";
5
+ import * as i4 from "@angular/common";
6
+ import * as i5 from "@angular/material/core";
7
+ import * as i6 from "@angular/flex-layout";
7
8
  export { ElderPanelComponent } from './flat/elder-panel.component';
8
9
  export { ElderCardPanelComponent } from './card-panel/elder-card-panel.component';
10
+ export { ElderDialogPanelComponent } from './elder-dialog-panel/elder-dialog-panel.component';
9
11
  export declare class ElderPanelModule {
10
12
  static ɵfac: i0.ɵɵFactoryDeclaration<ElderPanelModule, never>;
11
- static ɵmod: i0.ɵɵNgModuleDeclaration<ElderPanelModule, [typeof i1.ElderPanelComponent, typeof i2.ElderCardPanelComponent], [typeof i3.CommonModule, typeof i4.MatCommonModule, typeof i5.FlexLayoutModule], [typeof i1.ElderPanelComponent, typeof i2.ElderCardPanelComponent]>;
13
+ static ɵmod: i0.ɵɵNgModuleDeclaration<ElderPanelModule, [typeof i1.ElderPanelComponent, typeof i2.ElderCardPanelComponent, typeof i3.ElderDialogPanelComponent], [typeof i4.CommonModule, typeof i5.MatCommonModule, typeof i6.FlexLayoutModule], [typeof i1.ElderPanelComponent, typeof i2.ElderCardPanelComponent, typeof i3.ElderDialogPanelComponent]>;
12
14
  static ɵinj: i0.ɵɵInjectorDeclaration<ElderPanelModule>;
13
15
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elderbyte/ngx-starter",
3
- "version": "14.4.0-beta.24",
3
+ "version": "14.4.0-beta.25",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^14.0.0",
6
6
  "@angular/core": "^14.0.0",
@@ -1,5 +1,7 @@
1
1
  @use '@angular/material' as mat;
2
2
 
3
+ $elder-tile-padding: 2px;
4
+
3
5
  @mixin theme($theme) {
4
6
  $primary: map-get($theme, primary);
5
7
  $accent: map-get($theme, accent);
@@ -12,10 +14,7 @@
12
14
  background-color: mat.get-color-from-palette($background, card);
13
15
  }
14
16
 
15
- .elder-grid-browser {
16
- // background-color: mat.get-color-from-palette($background, card); // Maybe not card background?
17
- //overflow: hidden;
18
- }
17
+ .elder-grid-browser { }
19
18
 
20
19
  .elder-grid-flat {
21
20
  border: 1px solid mat.get-color-from-palette($foreground, divider);
@@ -33,22 +32,20 @@
33
32
  .elder-grid-tile {
34
33
  flex: 0 1 100%;
35
34
  flex-grow: 1;
36
- margin: 0 5px;
35
+ margin: 0 $elder-tile-padding;
37
36
  width: 100%;
38
37
  height: 100%;
39
38
  cursor: pointer;
40
- border-radius: 5px;
41
- background-color: mat.get-color-from-palette($background, card);
39
+ background-color: rgba(mat.get-color-from-palette($primary), 0.24); // app-bar
42
40
  text-align: left;
43
- border: 2px solid mat.get-color-from-palette($foreground, divider);
44
- box-sizing: border-box;
45
41
  transition:
46
42
  box-shadow 200ms cubic-bezier(0, 0, 0.2, 1),
47
43
  border .25s linear;
48
44
  }
49
45
 
50
- .elder-grid-tile:hover {
51
- border: 2px solid mat.get-color-from-palette($primary);
46
+ .elder-grid-tile-content:hover .elder-grid-tile-overlay{
47
+ opacity: 1;
48
+ background-color: rgba(white, 0.08);
52
49
  }
53
50
 
54
51
  .elder-grid-tile:active {
@@ -93,13 +90,13 @@
93
90
  .elder-grid-tile-row {
94
91
  display: flex;
95
92
  flex-direction: row;
96
- padding: 5px;
97
- margin: 0 -5px;
93
+ padding: $elder-tile-padding;
94
+ margin: 0 ($elder-tile-padding * -1);
98
95
  }
99
96
 
100
97
  .elder-grid-tile-hidden {
101
98
  flex: 0 1 100%;
102
- margin: 5px;
99
+ margin: $elder-tile-padding;
103
100
  width: 100%;
104
101
  height: 100%;
105
102
  }
@@ -119,7 +116,6 @@
119
116
  0 3px 14px 2px rgba(0, 0, 0, 0.12);
120
117
  }
121
118
 
122
-
123
119
  .cdk-drag-placeholder {
124
120
  flex: 0 1 100%;
125
121
  background: #ccc;
@@ -131,8 +127,8 @@
131
127
  .elder-grid-tile-overlay {
132
128
  position: absolute;
133
129
  left: 0; top: 0; right: 0; bottom: 0;
134
- -webkit-transition: background-color 0.2s ease-in, opacity 0.2s ease-in;
135
- transition: background-color 0.2s ease-in, opacity 0.2s ease-in;
130
+ -webkit-transition: background-color 0.1s ease-in, opacity 0.1s ease-in;
131
+ transition: background-color 0.1s ease-in, opacity 0.1s ease-in;
136
132
  }
137
133
 
138
134
  .elder-grid-tile-overlay-visible {
@@ -143,12 +139,6 @@
143
139
  opacity: 0;
144
140
  }
145
141
 
146
- .elder-grid-tile-content:hover .elder-grid-tile-overlay{
147
- opacity: 1;
148
- -webkit-transition: background-color 0.2s ease-in, opacity 0.2s ease-in;
149
- transition: background-color 0.2s ease-in, opacity 0.2s ease-in;
150
- }
151
-
152
142
  .elder-click-through {
153
143
  pointer-events:none;
154
144
  }
@@ -1,6 +1,6 @@
1
1
 
2
2
 
3
- .elder-search-panel {
3
+ .elder-search-panel-container {
4
4
  min-width: 250px;
5
5
  }
6
6
 
@@ -0,0 +1,22 @@
1
+ @use '@angular/material' as mat;
2
+
3
+ @mixin theme($theme) {
4
+ $primary: map-get($theme, primary);
5
+ $accent: map-get($theme, accent);
6
+ $warn: map-get($theme, warn);
7
+ $background: map-get($theme, background);
8
+ $foreground: map-get($theme, foreground);
9
+
10
+ .elder-dialog-panel {
11
+ color: mat.get-color-from-palette($foreground, text);
12
+ background-color: mat.get-color-from-palette($background, dialog);
13
+
14
+ padding: 10px;
15
+ border-radius: 4px;
16
+ box-shadow:
17
+ 0 5px 5px -3px rgba(0, 0, 0, 0.2),
18
+ 0 8px 10px 1px rgba(0, 0, 0, 0.14),
19
+ 0 3px 14px 2px rgba(0, 0, 0, 0.12);
20
+ }
21
+ }
22
+
@@ -84,3 +84,62 @@ $elder-gold: (
84
84
  A700: $dark-primary-text,
85
85
  )
86
86
  );
87
+
88
+ /***************************************************************************
89
+ * *
90
+ * Dark Theme Palettes *
91
+ * *
92
+ **************************************************************************/
93
+
94
+ $grey-palette: mat.$grey-palette;
95
+ $light-primary-text: rgba(white, 0.87);
96
+ $light-secondary-text: rgba(white, 0.40);
97
+ $light-disabled-text: rgba(white, 0.38);
98
+ $light-dividers: rgba(white, 0.12);
99
+ $light-focused: rgba(white, 0.12);
100
+
101
+ $dark-background-dp-01: #1f1f1f; // 5%
102
+ $dark-background-dp-02: #222222; // 7%
103
+ $dark-background-dp-03: #262626; // 8%
104
+ $dark-background-dp-04: #272727; // 9%
105
+ $dark-background-dp-06: #2c2c2c; // 11%
106
+ $dark-background-dp-08: #2d2d2d; // 12%
107
+ $dark-background-dp-12: #333333; // 14%
108
+
109
+ // Background palette for dark themes.
110
+ $elder-dark-theme-background: (
111
+ status-bar: black,
112
+ app-bar: $dark-background-dp-01,
113
+ background: #121212, // #121212
114
+ hover: rgba(white, 0.04),
115
+ card: $dark-background-dp-03,
116
+ dialog: $dark-background-dp-12, // $my-dark-dp-06
117
+ disabled-button: rgba(white, 0.12),
118
+ raised-button: map.get($grey-palette, 800),
119
+ focused-button: $light-focused,
120
+ selected-button: map.get($grey-palette, 900),
121
+ selected-disabled-button: map.get($grey-palette, 800),
122
+ disabled-button-toggle: black,
123
+ unselected-chip: map.get($grey-palette, 800),
124
+ disabled-list-option: rgba(white, 0.12),
125
+ tooltip: map.get($grey-palette, 800),
126
+ );
127
+
128
+ // Foreground palette for dark themes.
129
+ $elder-dark-theme-foreground: (
130
+ base: rgba(white, 0.87),
131
+ divider: $light-dividers,
132
+ dividers: $light-dividers,
133
+ disabled: $light-disabled-text,
134
+ disabled-button: rgba(white, 0.38),
135
+ disabled-text: $light-disabled-text,
136
+ elevation: black,
137
+ hint-text: $light-disabled-text,
138
+ secondary-text: $light-secondary-text,
139
+ icon: rgba(white, 0.87),
140
+ icons: rgba(white, 0.87),
141
+ text: rgba(white, 0.87),
142
+ slider-min: rgba(white, 0.87),
143
+ slider-off: rgba(white, 0.38),
144
+ slider-off-active: rgba(white, 0.38),
145
+ );
@@ -15,7 +15,7 @@
15
15
 
16
16
  /* Track */
17
17
  ::-webkit-scrollbar-track {
18
- background: mat.get-color-from-palette($background, background);
18
+ // background: mat.get-color-from-palette($background, background);
19
19
  }
20
20
 
21
21
  /* Handle */
@@ -0,0 +1,46 @@
1
+ @use '@angular/material' as mat;
2
+ @use 'sass:map';
3
+ @use 'elder-palettes' as palettes;
4
+
5
+ /***************************************************************************
6
+ * *
7
+ * Public API *
8
+ * *
9
+ **************************************************************************/
10
+
11
+ @function define-dark-elder-theme($config) {
12
+ $result: $config;
13
+ @if map.get($config, color) {
14
+ $color-settings: map.get($config, color);
15
+ $primary: map.get($color-settings, primary);
16
+ $accent: map.get($color-settings, accent);
17
+ $warn: map.get($color-settings, warn);
18
+ $result: map.merge($config, (color: _mat-create-dark-color-config($primary, $accent, $warn)));
19
+ }
20
+ @return _create-backwards-compatibility-theme($result);
21
+ }
22
+
23
+ /***************************************************************************
24
+ * *
25
+ * Private functions *
26
+ * *
27
+ **************************************************************************/
28
+
29
+ @function _mat-create-dark-color-config($primary, $accent, $warn: null) {
30
+ @return (
31
+ primary: $primary,
32
+ accent: $accent,
33
+ warn: if($warn != null, $warn, mat.define-palette(mat.$red-palette)),
34
+ is-dark: true,
35
+ foreground: palettes.$elder-dark-theme-foreground,
36
+ background: palettes.$elder-dark-theme-background
37
+ );
38
+ }
39
+
40
+ @function _create-backwards-compatibility-theme($theme) {
41
+ @if not map.get($theme, color) {
42
+ @return $theme;
43
+ }
44
+ $color: map.get($theme, color);
45
+ @return map.merge($theme, $color);
46
+ }
@@ -9,22 +9,22 @@
9
9
  $foreground: map-get($theme, foreground);
10
10
 
11
11
  .elder-primary-toast {
12
- background: mat.get-color-from-palette($background, background);
12
+ background: mat.get-color-from-palette($background, dialog);
13
13
  color: mat.get-color-from-palette($primary);
14
14
  }
15
15
 
16
16
  .elder-accent-toast {
17
- background: mat.get-color-from-palette($background, background);
17
+ background: mat.get-color-from-palette($background, dialog);
18
18
  color: mat.get-color-from-palette($accent);
19
19
  }
20
20
 
21
21
  .elder-success-toast {
22
- background: mat.get-color-from-palette($background, background);
22
+ background: mat.get-color-from-palette($background, dialog);
23
23
  color: mat.get-color-from-palette($primary);
24
24
  }
25
25
 
26
26
  .elder-warning-toast {
27
- background: mat.get-color-from-palette($background, background);
27
+ background: mat.get-color-from-palette($background, dialog);
28
28
  color: mat.get-color-from-palette($accent);
29
29
  }
30
30
 
@@ -41,7 +41,7 @@
41
41
  }
42
42
 
43
43
  .elder-warn-text {
44
- color: mat.get-color-from-palette($warn, );
44
+ color: mat.get-color-from-palette($warn);
45
45
  }
46
46
 
47
47
  }