angular-matecu 2.0.6 → 2.0.9
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/README.md +29 -0
- package/angular-matecu.code-workspace +10 -0
- package/karma.conf.js +44 -0
- package/ng-package.json +13 -0
- package/package.json +7 -15
- package/src/lib/modules/matecu-alert-box/components/matecu-alert-box/matecu-alert-box.component.html +11 -0
- package/src/lib/modules/matecu-alert-box/components/matecu-alert-box/matecu-alert-box.component.scss +39 -0
- package/src/lib/modules/matecu-alert-box/components/matecu-alert-box/matecu-alert-box.component.spec.ts +25 -0
- package/src/lib/modules/matecu-alert-box/components/matecu-alert-box/matecu-alert-box.component.ts +56 -0
- package/src/lib/modules/matecu-alert-box/components/matecu-alert-dialog/matecu-alert-dialog.component.html +14 -0
- package/src/lib/modules/matecu-alert-box/components/matecu-alert-dialog/matecu-alert-dialog.component.scss +5 -0
- package/src/lib/modules/matecu-alert-box/components/matecu-alert-dialog/matecu-alert-dialog.component.spec.ts +25 -0
- package/src/lib/modules/matecu-alert-box/components/matecu-alert-dialog/matecu-alert-dialog.component.ts +47 -0
- package/src/lib/modules/matecu-alert-box/matecu-alert-box.module.ts +17 -0
- package/src/lib/modules/matecu-alert-box/matecu-alert-snack-bar/matecu-alert-snack-bar.component.css +0 -0
- package/src/lib/modules/matecu-alert-box/matecu-alert-snack-bar/matecu-alert-snack-bar.component.html +1 -0
- package/src/lib/modules/matecu-alert-box/matecu-alert-snack-bar/matecu-alert-snack-bar.component.spec.ts +25 -0
- package/src/lib/modules/matecu-alert-box/matecu-alert-snack-bar/matecu-alert-snack-bar.component.ts +15 -0
- package/src/lib/modules/matecu-alert-box/matecu-snack-bar-alert/matecu-snack-bar-alert.component.html +8 -0
- package/src/lib/modules/matecu-alert-box/matecu-snack-bar-alert/matecu-snack-bar-alert.component.scss +34 -0
- package/src/lib/modules/matecu-alert-box/matecu-snack-bar-alert/matecu-snack-bar-alert.component.spec.ts +25 -0
- package/src/lib/modules/matecu-alert-box/matecu-snack-bar-alert/matecu-snack-bar-alert.component.ts +41 -0
- package/src/lib/modules/matecu-alert-box/services/matecu-snack-bar.service.spec.ts +16 -0
- package/src/lib/modules/matecu-alert-box/services/matecu-snack-bar.service.ts +66 -0
- package/src/lib/modules/matecu-alert-box/types/matecu-alert-dialog.ts +10 -0
- package/src/lib/modules/matecu-alert-box/types/matecu-alert-snackbar.ts +8 -0
- package/src/lib/modules/matecu-alert-box/types/matecu-altert-box-type.ts +6 -0
- package/src/lib/modules/matecu-spinner/components/matecu-spinner/matecu-spinner.component.css +15 -0
- package/src/lib/modules/matecu-spinner/components/matecu-spinner/matecu-spinner.component.html +35 -0
- package/src/lib/modules/matecu-spinner/components/matecu-spinner/matecu-spinner.component.spec.ts +25 -0
- package/src/lib/modules/matecu-spinner/components/matecu-spinner/matecu-spinner.component.ts +47 -0
- package/src/lib/modules/matecu-spinner/components/matecu-spinner/spinner-loader.component.scss +13 -0
- package/src/lib/modules/matecu-spinner/matecu-spinner.module.ts +17 -0
- package/src/lib/modules/matecu-spinner/services/matecu-spinner.service.spec.ts +16 -0
- package/src/lib/modules/matecu-spinner/services/matecu-spinner.service.ts +40 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-actions/matecu-topbar-actions.component.html +1 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-actions/matecu-topbar-actions.component.scss +8 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-actions/matecu-topbar-actions.component.spec.ts +25 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-actions/matecu-topbar-actions.component.ts +12 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-body/matecu-topbar-body.component.html +1 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-body/matecu-topbar-body.component.scss +9 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-body/matecu-topbar-body.component.spec.ts +25 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-body/matecu-topbar-body.component.ts +23 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-fab/matecu-topbar-fab.component.html +3 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-fab/matecu-topbar-fab.component.scss +26 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-fab/matecu-topbar-fab.component.spec.ts +25 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-fab/matecu-topbar-fab.component.ts +27 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-layout/matecu-topbar-layout.component.html +23 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-layout/matecu-topbar-layout.component.scss +48 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-layout/matecu-topbar-layout.component.spec.ts +25 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-layout/matecu-topbar-layout.component.ts +93 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-search/matecu-topbar-search.component.html +12 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-search/matecu-topbar-search.component.scss +101 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-search/matecu-topbar-search.component.spec.ts +25 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-search/matecu-topbar-search.component.ts +79 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-title/matecu-topbar-title.component.html +1 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-title/matecu-topbar-title.component.scss +13 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-title/matecu-topbar-title.component.spec.ts +25 -0
- package/src/lib/modules/matecu-topbar-layout/components/matecu-topbar-title/matecu-topbar-title.component.ts +16 -0
- package/src/lib/modules/matecu-topbar-layout/matecu-topbar-layout.module.ts +40 -0
- package/src/lib/modules/matecu-topbar-layout/scss/variables.scss +2 -0
- package/{public-api.d.ts → src/public-api.ts} +8 -0
- package/src/test.ts +28 -0
- package/tsconfig.lib.json +25 -0
- package/tsconfig.lib.prod.json +10 -0
- package/tsconfig.spec.json +17 -0
- package/tslint.json +17 -0
- package/angular-matecu.d.ts +0 -5
- package/bundles/angular-matecu.umd.js +0 -681
- package/bundles/angular-matecu.umd.js.map +0 -1
- package/esm2015/angular-matecu.js +0 -5
- package/esm2015/lib/modules/matecu-alert-box/components/matecu-alert-box/matecu-alert-box.component.js +0 -69
- package/esm2015/lib/modules/matecu-alert-box/components/matecu-alert-dialog/matecu-alert-dialog.component.js +0 -55
- package/esm2015/lib/modules/matecu-alert-box/matecu-alert-box.module.js +0 -23
- package/esm2015/lib/modules/matecu-alert-box/types/matecu-alert-dialog.js +0 -2
- package/esm2015/lib/modules/matecu-alert-box/types/matecu-altert-box-type.js +0 -8
- package/esm2015/lib/modules/matecu-spinner/components/matecu-spinner/matecu-spinner.component.js +0 -61
- package/esm2015/lib/modules/matecu-spinner/matecu-spinner.module.js +0 -24
- package/esm2015/lib/modules/matecu-spinner/services/matecu-spinner.service.js +0 -44
- package/esm2015/lib/modules/matecu-topbar-layout/components/matecu-topbar-actions/matecu-topbar-actions.component.js +0 -17
- package/esm2015/lib/modules/matecu-topbar-layout/components/matecu-topbar-body/matecu-topbar-body.component.js +0 -32
- package/esm2015/lib/modules/matecu-topbar-layout/components/matecu-topbar-fab/matecu-topbar-fab.component.js +0 -36
- package/esm2015/lib/modules/matecu-topbar-layout/components/matecu-topbar-layout/matecu-topbar-layout.component.js +0 -103
- package/esm2015/lib/modules/matecu-topbar-layout/components/matecu-topbar-search/matecu-topbar-search.component.js +0 -85
- package/esm2015/lib/modules/matecu-topbar-layout/components/matecu-topbar-title/matecu-topbar-title.component.js +0 -23
- package/esm2015/lib/modules/matecu-topbar-layout/matecu-topbar-layout.module.js +0 -70
- package/esm2015/public-api.js +0 -28
- package/fesm2015/angular-matecu.js +0 -603
- package/fesm2015/angular-matecu.js.map +0 -1
- package/lib/modules/matecu-alert-box/components/matecu-alert-box/matecu-alert-box.component.d.ts +0 -19
- package/lib/modules/matecu-alert-box/components/matecu-alert-dialog/matecu-alert-dialog.component.d.ts +0 -22
- package/lib/modules/matecu-alert-box/matecu-alert-box.module.d.ts +0 -12
- package/lib/modules/matecu-alert-box/types/matecu-alert-dialog.d.ts +0 -9
- package/lib/modules/matecu-alert-box/types/matecu-altert-box-type.d.ts +0 -6
- package/lib/modules/matecu-spinner/components/matecu-spinner/matecu-spinner.component.d.ts +0 -20
- package/lib/modules/matecu-spinner/matecu-spinner.module.d.ts +0 -8
- package/lib/modules/matecu-spinner/services/matecu-spinner.service.d.ts +0 -15
- package/lib/modules/matecu-topbar-layout/components/matecu-topbar-actions/matecu-topbar-actions.component.d.ts +0 -8
- package/lib/modules/matecu-topbar-layout/components/matecu-topbar-body/matecu-topbar-body.component.d.ts +0 -11
- package/lib/modules/matecu-topbar-layout/components/matecu-topbar-fab/matecu-topbar-fab.component.d.ts +0 -13
- package/lib/modules/matecu-topbar-layout/components/matecu-topbar-layout/matecu-topbar-layout.component.d.ts +0 -30
- package/lib/modules/matecu-topbar-layout/components/matecu-topbar-search/matecu-topbar-search.component.d.ts +0 -26
- package/lib/modules/matecu-topbar-layout/components/matecu-topbar-title/matecu-topbar-title.component.d.ts +0 -9
- package/lib/modules/matecu-topbar-layout/matecu-topbar-layout.module.d.ts +0 -17
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
@import '../../scss/variables.scss';
|
|
2
|
+
:host {
|
|
3
|
+
display: flex;
|
|
4
|
+
align-items: center;
|
|
5
|
+
position: relative;
|
|
6
|
+
padding: 7px;
|
|
7
|
+
min-height: $toolbar-height;
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
.matecu-topbar-search {
|
|
10
|
+
&__input {
|
|
11
|
+
display: block;
|
|
12
|
+
position: relative;
|
|
13
|
+
z-index: 2;
|
|
14
|
+
input {
|
|
15
|
+
border: transparent;
|
|
16
|
+
border-radius: 4px;
|
|
17
|
+
padding: 5px 35px 5px 40px;
|
|
18
|
+
background-color: rgba($color: #ffffff, $alpha: 0.3);
|
|
19
|
+
min-width: 200px;
|
|
20
|
+
width: 200px;
|
|
21
|
+
transition: all 300ms ease-in-out;
|
|
22
|
+
height: 39px;
|
|
23
|
+
color: currentColor;
|
|
24
|
+
&:focus {
|
|
25
|
+
min-width: 290px;
|
|
26
|
+
}
|
|
27
|
+
&::placeholder {
|
|
28
|
+
color: currentColor;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
input[type='search']::-webkit-search-decoration,
|
|
32
|
+
input[type='search']::-webkit-search-cancel-button,
|
|
33
|
+
input[type='search']::-webkit-search-results-button,
|
|
34
|
+
input[type='search']::-webkit-search-results-decoration {
|
|
35
|
+
-webkit-appearance: none;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
> mat-icon {
|
|
39
|
+
position: absolute;
|
|
40
|
+
left: 12px;
|
|
41
|
+
top: 10px;
|
|
42
|
+
}
|
|
43
|
+
button {
|
|
44
|
+
position: absolute;
|
|
45
|
+
right: 0px;
|
|
46
|
+
top: 0;
|
|
47
|
+
mat-icon {
|
|
48
|
+
font-size: 20px;
|
|
49
|
+
}
|
|
50
|
+
transform: scale(0);
|
|
51
|
+
transition: transform 300ms ease-in-out;
|
|
52
|
+
&.show-btn {
|
|
53
|
+
transform: scale(100%);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
@media screen and (max-width: 768px) {
|
|
57
|
+
position: fixed;
|
|
58
|
+
top: 0;
|
|
59
|
+
left: 0;
|
|
60
|
+
right: 0;
|
|
61
|
+
height: $toolbar-height;
|
|
62
|
+
color: #333;
|
|
63
|
+
transform: translateY(-110%);
|
|
64
|
+
transition: all 300ms ease-in-out;
|
|
65
|
+
input {
|
|
66
|
+
width: 100%;
|
|
67
|
+
height: 100%;
|
|
68
|
+
background-color: #ffffff;
|
|
69
|
+
border-radius: 0;
|
|
70
|
+
padding-right: 30px;
|
|
71
|
+
|
|
72
|
+
&:focus {
|
|
73
|
+
min-width: 100%;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
> mat-icon {
|
|
77
|
+
top: 20px;
|
|
78
|
+
}
|
|
79
|
+
button {
|
|
80
|
+
position: absolute;
|
|
81
|
+
right: 5px;
|
|
82
|
+
top: 10px;
|
|
83
|
+
transform: scale(100%);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
&.mobile-input-active {
|
|
87
|
+
transform: translateY(0%);
|
|
88
|
+
@media screen and (max-width: 768px) {
|
|
89
|
+
display: block;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.only-mobile {
|
|
96
|
+
display: none;
|
|
97
|
+
@media screen and (max-width: 768px) {
|
|
98
|
+
display: block;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
+
|
|
3
|
+
import { MatecuTopbarSearchComponent } from './matecu-topbar-search.component';
|
|
4
|
+
|
|
5
|
+
describe('MatecuTopbarSearchComponent', () => {
|
|
6
|
+
let component: MatecuTopbarSearchComponent;
|
|
7
|
+
let fixture: ComponentFixture<MatecuTopbarSearchComponent>;
|
|
8
|
+
|
|
9
|
+
beforeEach(async () => {
|
|
10
|
+
await TestBed.configureTestingModule({
|
|
11
|
+
declarations: [ MatecuTopbarSearchComponent ]
|
|
12
|
+
})
|
|
13
|
+
.compileComponents();
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
beforeEach(() => {
|
|
17
|
+
fixture = TestBed.createComponent(MatecuTopbarSearchComponent);
|
|
18
|
+
component = fixture.componentInstance;
|
|
19
|
+
fixture.detectChanges();
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
it('should create', () => {
|
|
23
|
+
expect(component).toBeTruthy();
|
|
24
|
+
});
|
|
25
|
+
});
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Component,
|
|
3
|
+
EventEmitter,
|
|
4
|
+
HostBinding,
|
|
5
|
+
Input,
|
|
6
|
+
OnInit,
|
|
7
|
+
Output,
|
|
8
|
+
ViewEncapsulation,
|
|
9
|
+
} from '@angular/core';
|
|
10
|
+
import { FormControl } from '@angular/forms';
|
|
11
|
+
import { Subject } from 'rxjs';
|
|
12
|
+
import {
|
|
13
|
+
debounceTime,
|
|
14
|
+
distinctUntilChanged,
|
|
15
|
+
takeUntil,
|
|
16
|
+
tap,
|
|
17
|
+
} from 'rxjs/operators';
|
|
18
|
+
|
|
19
|
+
@Component({
|
|
20
|
+
selector: 'matecu-topbar-search',
|
|
21
|
+
templateUrl: './matecu-topbar-search.component.html',
|
|
22
|
+
styleUrls: ['./matecu-topbar-search.component.scss'],
|
|
23
|
+
})
|
|
24
|
+
export class MatecuTopbarSearchComponent implements OnInit {
|
|
25
|
+
showMobileInput = false;
|
|
26
|
+
searchInput = new FormControl();
|
|
27
|
+
showDescktopCleanBtn = false;
|
|
28
|
+
private destroy = new Subject();
|
|
29
|
+
@Input() searchPlaceholder = 'Buscar';
|
|
30
|
+
@Input() debounceTime = 500;
|
|
31
|
+
@Input() inputType: 'text' | 'search' = 'text';
|
|
32
|
+
@Input() cleanWhenClose = true;
|
|
33
|
+
@Input() set value(val: string | null | undefined) {
|
|
34
|
+
if (typeof val === 'string') {
|
|
35
|
+
this.searchInput.setValue(val);
|
|
36
|
+
} else {
|
|
37
|
+
this.searchInput.reset();
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
@Output() valueChange = new EventEmitter<string>();
|
|
41
|
+
@Output() whenSearchChanges = new EventEmitter<string>();
|
|
42
|
+
@HostBinding('class') className = 'matecu-topbar-search';
|
|
43
|
+
constructor() {}
|
|
44
|
+
|
|
45
|
+
ngOnInit(): void {
|
|
46
|
+
this.watchSearch();
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
toogleSearch(): void {
|
|
50
|
+
this.showMobileInput = !this.showMobileInput;
|
|
51
|
+
}
|
|
52
|
+
closeMobile(): void {
|
|
53
|
+
if (this.cleanWhenClose) {
|
|
54
|
+
this.searchInput.reset();
|
|
55
|
+
}
|
|
56
|
+
this.showMobileInput = false;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
private watchSearch(): void {
|
|
60
|
+
this.searchInput.valueChanges
|
|
61
|
+
.pipe(
|
|
62
|
+
tap((value) => this.setShowDescktopCleanBtn(value)),
|
|
63
|
+
debounceTime(this.debounceTime),
|
|
64
|
+
distinctUntilChanged(),
|
|
65
|
+
tap((value) => this.searchChanges(value)),
|
|
66
|
+
takeUntil(this.destroy)
|
|
67
|
+
)
|
|
68
|
+
.subscribe();
|
|
69
|
+
}
|
|
70
|
+
private searchChanges(searchVal?: string | null): void {
|
|
71
|
+
const value =
|
|
72
|
+
typeof searchVal === 'string' && searchVal.length > 0 ? searchVal : '';
|
|
73
|
+
this.whenSearchChanges.emit(value);
|
|
74
|
+
this.valueChange.emit(value);
|
|
75
|
+
}
|
|
76
|
+
private setShowDescktopCleanBtn(value: string | null | undefined): void {
|
|
77
|
+
this.showDescktopCleanBtn = typeof value === 'string' && value.length > 0;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<ng-content></ng-content>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
@import '../../scss/variables.scss';
|
|
2
|
+
:host {
|
|
3
|
+
display: flex;
|
|
4
|
+
align-items: center;
|
|
5
|
+
margin-right: auto;
|
|
6
|
+
padding: 7px 1rem;
|
|
7
|
+
min-height: $toolbar-height;
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
align-self: center;
|
|
10
|
+
@media screen and (max-width: 425px) {
|
|
11
|
+
display: none;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
+
|
|
3
|
+
import { MatecuTopbarTitleComponent } from './matecu-topbar-title.component';
|
|
4
|
+
|
|
5
|
+
describe('MatecuTopbarTitleComponent', () => {
|
|
6
|
+
let component: MatecuTopbarTitleComponent;
|
|
7
|
+
let fixture: ComponentFixture<MatecuTopbarTitleComponent>;
|
|
8
|
+
|
|
9
|
+
beforeEach(async () => {
|
|
10
|
+
await TestBed.configureTestingModule({
|
|
11
|
+
declarations: [ MatecuTopbarTitleComponent ]
|
|
12
|
+
})
|
|
13
|
+
.compileComponents();
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
beforeEach(() => {
|
|
17
|
+
fixture = TestBed.createComponent(MatecuTopbarTitleComponent);
|
|
18
|
+
component = fixture.componentInstance;
|
|
19
|
+
fixture.detectChanges();
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
it('should create', () => {
|
|
23
|
+
expect(component).toBeTruthy();
|
|
24
|
+
});
|
|
25
|
+
});
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Component, HostBinding, OnInit } from '@angular/core';
|
|
2
|
+
|
|
3
|
+
@Component({
|
|
4
|
+
selector: 'matecu-topbar-title',
|
|
5
|
+
templateUrl: './matecu-topbar-title.component.html',
|
|
6
|
+
styleUrls: ['./matecu-topbar-title.component.scss']
|
|
7
|
+
})
|
|
8
|
+
export class MatecuTopbarTitleComponent implements OnInit {
|
|
9
|
+
|
|
10
|
+
@HostBinding('class') className = 'title';
|
|
11
|
+
constructor() { }
|
|
12
|
+
|
|
13
|
+
ngOnInit(): void {
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { NgModule } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
3
|
+
import { MatecuTopbarLayoutComponent } from './components/matecu-topbar-layout/matecu-topbar-layout.component';
|
|
4
|
+
import { MatecuTopbarTitleComponent } from './components/matecu-topbar-title/matecu-topbar-title.component';
|
|
5
|
+
import { MatecuTopbarBodyComponent } from './components/matecu-topbar-body/matecu-topbar-body.component';
|
|
6
|
+
import { MatToolbarModule } from '@angular/material/toolbar';
|
|
7
|
+
import { MatIconModule } from '@angular/material/icon';
|
|
8
|
+
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
9
|
+
import { MatButtonModule } from '@angular/material/button';
|
|
10
|
+
import { MatecuTopbarFabComponent } from './components/matecu-topbar-fab/matecu-topbar-fab.component';
|
|
11
|
+
import { MatecuTopbarSearchComponent } from './components/matecu-topbar-search/matecu-topbar-search.component';
|
|
12
|
+
import { MatecuTopbarActionsComponent } from './components/matecu-topbar-actions/matecu-topbar-actions.component';
|
|
13
|
+
|
|
14
|
+
@NgModule({
|
|
15
|
+
declarations: [
|
|
16
|
+
MatecuTopbarLayoutComponent,
|
|
17
|
+
MatecuTopbarTitleComponent,
|
|
18
|
+
MatecuTopbarBodyComponent,
|
|
19
|
+
MatecuTopbarFabComponent,
|
|
20
|
+
MatecuTopbarSearchComponent,
|
|
21
|
+
MatecuTopbarActionsComponent,
|
|
22
|
+
],
|
|
23
|
+
imports: [
|
|
24
|
+
CommonModule,
|
|
25
|
+
MatToolbarModule,
|
|
26
|
+
MatIconModule,
|
|
27
|
+
FormsModule,
|
|
28
|
+
ReactiveFormsModule,
|
|
29
|
+
MatButtonModule,
|
|
30
|
+
],
|
|
31
|
+
exports: [
|
|
32
|
+
MatecuTopbarLayoutComponent,
|
|
33
|
+
MatecuTopbarTitleComponent,
|
|
34
|
+
MatecuTopbarBodyComponent,
|
|
35
|
+
MatecuTopbarFabComponent,
|
|
36
|
+
MatecuTopbarSearchComponent,
|
|
37
|
+
MatecuTopbarActionsComponent,
|
|
38
|
+
],
|
|
39
|
+
})
|
|
40
|
+
export class MatecuTopbarLayoutModule {}
|
|
@@ -1,12 +1,18 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Public API Surface of angular-matecu
|
|
3
|
+
*/
|
|
4
|
+
|
|
1
5
|
/**
|
|
2
6
|
* Modulo spinner
|
|
3
7
|
*/
|
|
4
8
|
export * from './lib/modules/matecu-spinner/matecu-spinner.module';
|
|
5
9
|
export * from './lib/modules/matecu-spinner/components/matecu-spinner/matecu-spinner.component';
|
|
6
10
|
export * from './lib/modules/matecu-spinner/services/matecu-spinner.service';
|
|
11
|
+
|
|
7
12
|
/**
|
|
8
13
|
* Módulo topbar-layout
|
|
9
14
|
*/
|
|
15
|
+
|
|
10
16
|
export * from './lib/modules/matecu-topbar-layout/matecu-topbar-layout.module';
|
|
11
17
|
export * from './lib/modules/matecu-topbar-layout/components/matecu-topbar-body/matecu-topbar-body.component';
|
|
12
18
|
export * from './lib/modules/matecu-topbar-layout/components/matecu-topbar-fab/matecu-topbar-fab.component';
|
|
@@ -14,9 +20,11 @@ export * from './lib/modules/matecu-topbar-layout/components/matecu-topbar-layou
|
|
|
14
20
|
export * from './lib/modules/matecu-topbar-layout/components/matecu-topbar-title/matecu-topbar-title.component';
|
|
15
21
|
export * from './lib/modules/matecu-topbar-layout/components/matecu-topbar-search/matecu-topbar-search.component';
|
|
16
22
|
export * from './lib/modules/matecu-topbar-layout/components/matecu-topbar-actions/matecu-topbar-actions.component';
|
|
23
|
+
|
|
17
24
|
/**
|
|
18
25
|
* Módulo alert-box
|
|
19
26
|
*/
|
|
27
|
+
|
|
20
28
|
export * from './lib/modules/matecu-alert-box/matecu-alert-box.module';
|
|
21
29
|
export * from './lib/modules/matecu-alert-box/components/matecu-alert-box/matecu-alert-box.component';
|
|
22
30
|
export * from './lib/modules/matecu-alert-box/components/matecu-alert-dialog/matecu-alert-dialog.component';
|
package/src/test.ts
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
|
|
2
|
+
|
|
3
|
+
import 'zone.js';
|
|
4
|
+
import 'zone.js/testing';
|
|
5
|
+
import { getTestBed } from '@angular/core/testing';
|
|
6
|
+
import {
|
|
7
|
+
BrowserDynamicTestingModule,
|
|
8
|
+
platformBrowserDynamicTesting
|
|
9
|
+
} from '@angular/platform-browser-dynamic/testing';
|
|
10
|
+
|
|
11
|
+
declare const require: {
|
|
12
|
+
context(path: string, deep?: boolean, filter?: RegExp): {
|
|
13
|
+
keys(): string[];
|
|
14
|
+
<T>(id: string): T;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
// First, initialize the Angular testing environment.
|
|
19
|
+
getTestBed().initTestEnvironment(
|
|
20
|
+
BrowserDynamicTestingModule,
|
|
21
|
+
platformBrowserDynamicTesting(), {
|
|
22
|
+
teardown: { destroyAfterEach: false }
|
|
23
|
+
}
|
|
24
|
+
);
|
|
25
|
+
// Then we find all the tests.
|
|
26
|
+
const context = require.context('./', true, /\.spec\.ts$/);
|
|
27
|
+
// And load the modules.
|
|
28
|
+
context.keys().map(context);
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/* To learn more about this file see: https://angular.io/config/tsconfig. */
|
|
2
|
+
{
|
|
3
|
+
"extends": "../../tsconfig.json",
|
|
4
|
+
"compilerOptions": {
|
|
5
|
+
"outDir": "../../out-tsc/lib",
|
|
6
|
+
"target": "es2015",
|
|
7
|
+
"declaration": true,
|
|
8
|
+
"declarationMap": true,
|
|
9
|
+
"inlineSources": true,
|
|
10
|
+
"types": [],
|
|
11
|
+
"lib": [
|
|
12
|
+
"dom",
|
|
13
|
+
"es2018"
|
|
14
|
+
]
|
|
15
|
+
},
|
|
16
|
+
"angularCompilerOptions": {
|
|
17
|
+
"skipTemplateCodegen": true,
|
|
18
|
+
"strictMetadataEmit": true,
|
|
19
|
+
"enableResourceInlining": true
|
|
20
|
+
},
|
|
21
|
+
"exclude": [
|
|
22
|
+
"src/test.ts",
|
|
23
|
+
"**/*.spec.ts"
|
|
24
|
+
]
|
|
25
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/* To learn more about this file see: https://angular.io/config/tsconfig. */
|
|
2
|
+
{
|
|
3
|
+
"extends": "../../tsconfig.json",
|
|
4
|
+
"compilerOptions": {
|
|
5
|
+
"outDir": "../../out-tsc/spec",
|
|
6
|
+
"types": [
|
|
7
|
+
"jasmine"
|
|
8
|
+
]
|
|
9
|
+
},
|
|
10
|
+
"files": [
|
|
11
|
+
"src/test.ts"
|
|
12
|
+
],
|
|
13
|
+
"include": [
|
|
14
|
+
"**/*.spec.ts",
|
|
15
|
+
"**/*.d.ts"
|
|
16
|
+
]
|
|
17
|
+
}
|
package/tslint.json
ADDED