matcha-components 19.56.0 → 19.58.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/fesm2022/matcha-components.mjs +588 -415
- package/fesm2022/matcha-components.mjs.map +1 -1
- package/lib/matcha-button/button/button.component.d.ts +1 -0
- package/lib/matcha-modal/modal/modal.component.d.ts +16 -1
- package/lib/matcha-modal/modal.service.d.ts +22 -0
- package/lib/matcha-modal/overlay.service.d.ts +81 -0
- package/lib/matcha-slide-toggle/slide-toggle.directive.d.ts +9 -0
- package/lib/matcha-slide-toggle/slide-toggle.module.d.ts +2 -3
- package/package.json +1 -1
- package/public-api.d.ts +1 -1
- package/lib/matcha-slide-toggle/slide-toggle/slide-toggle.component.d.ts +0 -28
|
@@ -10,6 +10,7 @@ export declare class MatchaButtonComponent implements OnChanges, OnInit {
|
|
|
10
10
|
sizeLg: string | null;
|
|
11
11
|
sizeXl: string | null;
|
|
12
12
|
color: string | null;
|
|
13
|
+
get colorAttr(): string | null;
|
|
13
14
|
private _basic;
|
|
14
15
|
get basic(): boolean | string;
|
|
15
16
|
set basic(v: boolean | string);
|
|
@@ -1,7 +1,22 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class MatchaModalComponent {
|
|
3
|
+
size: string | null;
|
|
4
|
+
sizeXs: string | null;
|
|
5
|
+
sizeSm: string | null;
|
|
6
|
+
sizeMd: string | null;
|
|
7
|
+
sizeLg: string | null;
|
|
8
|
+
sizeXl: string | null;
|
|
3
9
|
class: string;
|
|
10
|
+
hasBackdrop: boolean;
|
|
11
|
+
backdropClass: string;
|
|
12
|
+
get sizeAttr(): string | null;
|
|
13
|
+
get sizeAttrXs(): string | null;
|
|
14
|
+
get sizeAttrSm(): string | null;
|
|
15
|
+
get sizeAttrMd(): string | null;
|
|
16
|
+
get sizeAttrLg(): string | null;
|
|
17
|
+
get sizeAttrXl(): string | null;
|
|
4
18
|
get classes(): string;
|
|
19
|
+
constructor();
|
|
5
20
|
static ɵfac: i0.ɵɵFactoryDeclaration<MatchaModalComponent, never>;
|
|
6
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<MatchaModalComponent, "matcha-modal", never, { "class": { "alias": "class"; "required": false; }; }, {}, never, ["*"], false, never>;
|
|
21
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MatchaModalComponent, "matcha-modal", never, { "size": { "alias": "size"; "required": false; }; "sizeXs": { "alias": "size-xs"; "required": false; }; "sizeSm": { "alias": "size-sm"; "required": false; }; "sizeMd": { "alias": "size-md"; "required": false; }; "sizeLg": { "alias": "size-lg"; "required": false; }; "sizeXl": { "alias": "size-xl"; "required": false; }; "class": { "alias": "class"; "required": false; }; "hasBackdrop": { "alias": "hasBackdrop"; "required": false; }; "backdropClass": { "alias": "backdropClass"; "required": false; }; }, {}, never, ["*"], false, never>;
|
|
7
22
|
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Type } from '@angular/core';
|
|
2
|
+
import { MatchaOverlayService } from './overlay.service';
|
|
3
|
+
import { Observable } from 'rxjs';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export interface ModalComponent {
|
|
6
|
+
afterClose?: Observable<any>;
|
|
7
|
+
data?: any;
|
|
8
|
+
}
|
|
9
|
+
export declare class MatchaModalService {
|
|
10
|
+
private overlayService;
|
|
11
|
+
private afterCloseSubject;
|
|
12
|
+
private currentData;
|
|
13
|
+
constructor(overlayService: MatchaOverlayService);
|
|
14
|
+
open<T extends ModalComponent>(component: Type<T>, data?: any): {
|
|
15
|
+
componentRef: import("@angular/core").ComponentRef<T>;
|
|
16
|
+
afterClose: Observable<any>;
|
|
17
|
+
};
|
|
18
|
+
close(result?: any): void;
|
|
19
|
+
getData(): any;
|
|
20
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MatchaModalService, never>;
|
|
21
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<MatchaModalService>;
|
|
22
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { ComponentRef, ApplicationRef, Injector, Type, RendererFactory2 } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* Serviço responsável pela implementação técnica do overlay e backdrop dos modais.
|
|
5
|
+
*
|
|
6
|
+
* Este serviço lida com a criação e gerenciamento do container do overlay,
|
|
7
|
+
* criação do backdrop e manipulação do DOM. É um serviço de baixo nível
|
|
8
|
+
* utilizado internamente pelo MatchaModalService.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```typescript
|
|
12
|
+
* constructor(private overlayService: MatchaOverlayService) {}
|
|
13
|
+
*
|
|
14
|
+
* createOverlay() {
|
|
15
|
+
* this.overlayService.open(MyComponent);
|
|
16
|
+
* }
|
|
17
|
+
* ```
|
|
18
|
+
*/
|
|
19
|
+
export declare class MatchaOverlayService {
|
|
20
|
+
private appRef;
|
|
21
|
+
private injector;
|
|
22
|
+
private rendererFactory;
|
|
23
|
+
private overlayContainer;
|
|
24
|
+
private activeModal;
|
|
25
|
+
private backdrop;
|
|
26
|
+
private renderer;
|
|
27
|
+
constructor(appRef: ApplicationRef, injector: Injector, rendererFactory: RendererFactory2);
|
|
28
|
+
/**
|
|
29
|
+
* Cria o container do overlay se ainda não existir.
|
|
30
|
+
* O container é um elemento div que será usado para hospedar os modais.
|
|
31
|
+
*
|
|
32
|
+
* @private
|
|
33
|
+
*/
|
|
34
|
+
private createOverlayContainer;
|
|
35
|
+
/**
|
|
36
|
+
* Remove o container do overlay do DOM.
|
|
37
|
+
*
|
|
38
|
+
* @private
|
|
39
|
+
*/
|
|
40
|
+
private removeOverlayContainer;
|
|
41
|
+
/**
|
|
42
|
+
* Cria o backdrop do modal se ainda não existir.
|
|
43
|
+
* O backdrop é um elemento div que cria o efeito de escurecimento
|
|
44
|
+
* por trás do modal.
|
|
45
|
+
*
|
|
46
|
+
* @private
|
|
47
|
+
*/
|
|
48
|
+
private createBackdrop;
|
|
49
|
+
/**
|
|
50
|
+
* Remove o backdrop do modal do DOM.
|
|
51
|
+
*
|
|
52
|
+
* @private
|
|
53
|
+
*/
|
|
54
|
+
private removeBackdrop;
|
|
55
|
+
/**
|
|
56
|
+
* Abre um componente dentro de um modal.
|
|
57
|
+
*
|
|
58
|
+
* @param component - O componente que será exibido dentro do modal
|
|
59
|
+
* @param config - Configurações opcionais para o modal
|
|
60
|
+
* @returns Uma referência ao componente criado
|
|
61
|
+
*
|
|
62
|
+
* @example
|
|
63
|
+
* ```typescript
|
|
64
|
+
* const componentRef = this.overlayService.open(MyComponent, {
|
|
65
|
+
* data: { id: 1 }
|
|
66
|
+
* });
|
|
67
|
+
* ```
|
|
68
|
+
*/
|
|
69
|
+
open<T>(component: Type<T>, config?: any): ComponentRef<T>;
|
|
70
|
+
/**
|
|
71
|
+
* Fecha o modal atualmente aberto e remove o backdrop e o container.
|
|
72
|
+
*
|
|
73
|
+
* @example
|
|
74
|
+
* ```typescript
|
|
75
|
+
* this.overlayService.close();
|
|
76
|
+
* ```
|
|
77
|
+
*/
|
|
78
|
+
close(): void;
|
|
79
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MatchaOverlayService, never>;
|
|
80
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<MatchaOverlayService>;
|
|
81
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ElementRef, Renderer2 } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare class MatchaSlideToggleDirective {
|
|
4
|
+
private _elementRef;
|
|
5
|
+
private _renderer;
|
|
6
|
+
constructor(_elementRef: ElementRef, _renderer: Renderer2);
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MatchaSlideToggleDirective, never>;
|
|
8
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<MatchaSlideToggleDirective, "[slide-toggle]", never, {}, {}, never, never, false, never>;
|
|
9
|
+
}
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
|
-
import * as i1 from "./slide-toggle
|
|
2
|
+
import * as i1 from "./slide-toggle.directive";
|
|
3
3
|
import * as i2 from "@angular/common";
|
|
4
|
-
import * as i3 from "@angular/forms";
|
|
5
4
|
export declare class MatchaSlideToggleModule {
|
|
6
5
|
static ɵfac: i0.ɵɵFactoryDeclaration<MatchaSlideToggleModule, never>;
|
|
7
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<MatchaSlideToggleModule, [typeof i1.
|
|
6
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<MatchaSlideToggleModule, [typeof i1.MatchaSlideToggleDirective], [typeof i2.CommonModule], [typeof i1.MatchaSlideToggleDirective]>;
|
|
8
7
|
static ɵinj: i0.ɵɵInjectorDeclaration<MatchaSlideToggleModule>;
|
|
9
8
|
}
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -27,7 +27,6 @@ export * from './lib/matcha-form-field/matcha-error/matcha-error.component';
|
|
|
27
27
|
export * from './lib/matcha-checkbox/checkbox/checkbox.component';
|
|
28
28
|
export * from './lib/matcha-spin/spin/spin.component';
|
|
29
29
|
export * from './lib/matcha-hint-text/hint/hint-text.component';
|
|
30
|
-
export * from './lib/matcha-slide-toggle/slide-toggle/slide-toggle.component';
|
|
31
30
|
export * from './lib/matcha-button-toggle/button-toggle/button-toggle.component';
|
|
32
31
|
export * from './lib/matcha-tabs/tabs/tabs.component';
|
|
33
32
|
export * from './lib/matcha-tabs/tab-item/tab-item.component';
|
|
@@ -77,6 +76,7 @@ export * from './lib/matcha-table/table.directive';
|
|
|
77
76
|
export * from './lib/matcha-sort-header/sort-header.directive';
|
|
78
77
|
export * from './lib/matcha-snackbar/snack-bar.directive';
|
|
79
78
|
export * from './lib/matcha-slider/matcha-slider.directive';
|
|
79
|
+
export * from './lib/matcha-slide-toggle/slide-toggle.directive';
|
|
80
80
|
export * from './lib/matcha-select/select.directive';
|
|
81
81
|
export * from './lib/matcha-radio-button/matcha-radio-button.directive';
|
|
82
82
|
export * from './lib/matcha-progress-bar/progress-bar.directive';
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import { EventEmitter, ElementRef, OnChanges, SimpleChanges, AfterViewInit } from '@angular/core';
|
|
2
|
-
import { ControlValueAccessor } from '@angular/forms';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
export declare class MatchaSlideToggleComponent implements ControlValueAccessor, OnChanges, AfterViewInit {
|
|
5
|
-
private elementRef;
|
|
6
|
-
color: string;
|
|
7
|
-
private _checked;
|
|
8
|
-
set checked(value: boolean | string);
|
|
9
|
-
get checked(): boolean;
|
|
10
|
-
private _disabled;
|
|
11
|
-
set disabled(value: boolean | string);
|
|
12
|
-
get disabled(): boolean;
|
|
13
|
-
change: EventEmitter<{
|
|
14
|
-
checked: boolean;
|
|
15
|
-
}>;
|
|
16
|
-
onChange: (value: boolean) => void;
|
|
17
|
-
onTouched: () => void;
|
|
18
|
-
writeValue(value: any): void;
|
|
19
|
-
registerOnChange(fn: any): void;
|
|
20
|
-
registerOnTouched(fn: any): void;
|
|
21
|
-
setDisabledState(isDisabled: boolean): void;
|
|
22
|
-
constructor(elementRef: ElementRef<HTMLElement>);
|
|
23
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
24
|
-
ngAfterViewInit(): void;
|
|
25
|
-
onInputChange(event: Event): void;
|
|
26
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<MatchaSlideToggleComponent, never>;
|
|
27
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<MatchaSlideToggleComponent, "matcha-slide-toggle", never, { "color": { "alias": "color"; "required": false; }; "checked": { "alias": "checked"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, { "change": "change"; }, never, ["*"], false, never>;
|
|
28
|
-
}
|