@cauca-911/material 18.0.1-beta2 → 18.0.1-beta4
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/esm2022/lib/buttons/base-button.mjs +17 -9
- package/esm2022/lib/buttons/icon-button/icon-button.component.mjs +3 -3
- package/fesm2022/cauca-911-material.mjs +17 -9
- package/fesm2022/cauca-911-material.mjs.map +1 -1
- package/lib/buttons/base-button.d.ts +14 -5
- package/lib/buttons/icon-button/icon-button.component.d.ts +2 -2
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { input, computed, output, Directive } from "@angular/core";
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
|
-
export class
|
|
3
|
+
export class BaseButtonWithoutLabel {
|
|
4
4
|
constructor() {
|
|
5
5
|
this.color = input(undefined);
|
|
6
6
|
this.icon = input();
|
|
@@ -12,22 +12,30 @@ export class BaseButton {
|
|
|
12
12
|
this.buttonDisabled = computed(() => this.isDisabled() || this.isInProgress());
|
|
13
13
|
this.buttonClick = output();
|
|
14
14
|
}
|
|
15
|
-
static { this.ɵfac = function
|
|
16
|
-
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type:
|
|
15
|
+
static { this.ɵfac = function BaseButtonWithoutLabel_Factory(t) { return new (t || BaseButtonWithoutLabel)(); }; }
|
|
16
|
+
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: BaseButtonWithoutLabel, inputs: { color: [1, "color"], icon: [1, "icon"], iconAlignment: [1, "iconAlignment"], isDisabled: [1, "isDisabled"], isInProgress: [1, "isInProgress"] }, outputs: { buttonClick: "buttonClick" } }); }
|
|
17
17
|
}
|
|
18
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(
|
|
18
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(BaseButtonWithoutLabel, [{
|
|
19
19
|
type: Directive
|
|
20
20
|
}], null, null); })();
|
|
21
|
-
export class BaseButtonWithLabel
|
|
21
|
+
export class BaseButtonWithLabel {
|
|
22
22
|
constructor() {
|
|
23
|
-
super(...arguments);
|
|
24
23
|
this.translateLabel = input(true);
|
|
25
24
|
this.label = input();
|
|
25
|
+
this.color = input(undefined);
|
|
26
|
+
this.icon = input();
|
|
27
|
+
this.iconAlignment = input('left');
|
|
28
|
+
this.isDisabled = input(false);
|
|
29
|
+
this.isInProgress = input(false);
|
|
30
|
+
this.showIcon = computed(() => !!this.icon() || this.isInProgress());
|
|
31
|
+
this.iconToShow = computed(() => this.isInProgress() ? 'update' : this.icon());
|
|
32
|
+
this.buttonDisabled = computed(() => this.isDisabled() || this.isInProgress());
|
|
33
|
+
this.buttonClick = output();
|
|
26
34
|
}
|
|
27
|
-
static { this.ɵfac =
|
|
28
|
-
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: BaseButtonWithLabel, inputs: { translateLabel: [1, "translateLabel"], label: [1, "label"]
|
|
35
|
+
static { this.ɵfac = function BaseButtonWithLabel_Factory(t) { return new (t || BaseButtonWithLabel)(); }; }
|
|
36
|
+
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: BaseButtonWithLabel, inputs: { translateLabel: [1, "translateLabel"], label: [1, "label"], color: [1, "color"], icon: [1, "icon"], iconAlignment: [1, "iconAlignment"], isDisabled: [1, "isDisabled"], isInProgress: [1, "isInProgress"] }, outputs: { buttonClick: "buttonClick" } }); }
|
|
29
37
|
}
|
|
30
38
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(BaseButtonWithLabel, [{
|
|
31
39
|
type: Directive
|
|
32
40
|
}], null, null); })();
|
|
33
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
41
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmFzZS1idXR0b24uanMiLCJzb3VyY2VSb290IjoiIiwic291c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2xpY2s6IE91dHB1dEVtaXR0ZXJSZWY8dm9pZD4gPSBvdXRwdXQoKTtcclxufSJdfQ==
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
2
|
import { MatIconButton } from '@angular/material/button';
|
|
3
3
|
import { MatIcon } from '@angular/material/icon';
|
|
4
|
-
import {
|
|
4
|
+
import { BaseButtonWithoutLabel } from '../base-button';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
|
-
export class IconButtonComponent extends
|
|
6
|
+
export class IconButtonComponent extends BaseButtonWithoutLabel {
|
|
7
7
|
static { this.ɵfac = /*@__PURE__*/ (() => { let ɵIconButtonComponent_BaseFactory; return function IconButtonComponent_Factory(t) { return (ɵIconButtonComponent_BaseFactory || (ɵIconButtonComponent_BaseFactory = i0.ɵɵgetInheritedFactory(IconButtonComponent)))(t || IconButtonComponent); }; })(); }
|
|
8
8
|
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: IconButtonComponent, selectors: [["app-icon-button"]], standalone: true, features: [i0.ɵɵInheritDefinitionFeature, i0.ɵɵStandaloneFeature], decls: 3, vars: 6, consts: [["mat-icon-button", "", "onclick", "this.blur()", 3, "click", "disabled"]], template: function IconButtonComponent_Template(rf, ctx) { if (rf & 1) {
|
|
9
9
|
i0.ɵɵelementStart(0, "button", 0);
|
|
@@ -25,4 +25,4 @@ export class IconButtonComponent extends BaseButton {
|
|
|
25
25
|
args: [{ selector: 'app-icon-button', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [MatIconButton, MatIcon], template: "<button mat-icon-button onclick=\"this.blur()\" (click)=\"buttonClick.emit();\" [disabled]=\"buttonDisabled()\">\r\n <mat-icon [style.color]=\"color()\" [class.button-spin]=\"isInProgress()\">{{iconToShow()}}</mat-icon>\r\n</button>", styles: [".mdc-button.mat-white,.mat-stroked-button.mat-white{color:#fff;border-color:#fff}.mdc-button.mat-white:hover,.mat-mdc-outlined-button.mat-white:hover{background-color:transparent}.mat-mdc-button-disabled .mat-icon{color:#12101461}\n"] }]
|
|
26
26
|
}], null, null); })();
|
|
27
27
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(IconButtonComponent, { className: "IconButtonComponent", filePath: "lib\\buttons\\icon-button\\icon-button.component.ts", lineNumber: 14 }); })();
|
|
28
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
28
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaWNvbi1idXR0b24uY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvY2F1Y2EtbWF0ZXJpYWwvc3JjL2xpYi9idXR0b25zL2ljb24tYnV0dG9uL2ljb24tYnV0dG9uLmNvbXBvbmVudC50cyIsIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2NhdWNhLW1hdGVyaWFsL3NyYy9saWIvYnV0dG9ucy9pY29uLWJ1dHRvbi9pY29uLWJ1dHRvbi5jb21wb25lbnQuaHRtbCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsdUJBQXVCLEVBQUUsU0FBUyxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQ25FLE9BQU8sRUFBRSxhQUFhLEVBQUUsTUFBTSwwQkFBMEIsQ0FBQztBQUN6RCxPQUFPLEVBQUUsT0FBTyxFQUFFLE1BQU0sd0JBQXdCLENBQUM7QUFDakQsT0FBTyxFQUFFLHNCQUFzQixFQUFFLE1BQU0sZ0JBQWdCLENBQUM7O0FBVXhELE1BQU0sT0FBTyxtQkFBb0IsU0FBUSxzQkFBc0I7Z1BBQWxELG1CQUFtQixTQUFuQixtQkFBbUI7b0VBQW5CLG1CQUFtQjtZQ2JoQyxpQ0FBMEc7WUFBNUQsZ0dBQVMsc0JBQWtCLElBQUU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cclxuZXhwb3J0IGNsYXNzIEljb25CdXR0b25Db21wb25lbnQgZXh0ZW5kcyBCYXNlQnV0dG9uV2l0aG91dExhYmVsIHtcclxufVxyXG4iLCI8YnV0dG9uIG1hdC1pY29uLWJ1dHRvbiBvbmNsaWNrPVwidGhpcy5ibHVyKClcIiAoY2xpY2spPVwiYnV0dG9uQ2xpY2suZW1pdCgpO1wiIFtkaXNhYmxlZF09XCJidXR0b25EaXNhYmxlZCgpXCI+XHJcbiAgICA8bWF0LWljb24gW3N0eWxlLmNvbG9yXT1cImNvbG9yKClcIiBbY2xhc3MuYnV0dG9uLXNwaW5dPVwiaXNJblByb2dyZXNzKClcIj57e2ljb25Ub1Nob3coKX19PC9tYXQtaWNvbj5cclxuPC9idXR0b24+Il19
|
|
@@ -849,7 +849,7 @@ class CaucaMaterialModule {
|
|
|
849
849
|
CaucaSimpleDialogComponent,
|
|
850
850
|
CaucaSlideshowComponent] }); })();
|
|
851
851
|
|
|
852
|
-
class
|
|
852
|
+
class BaseButtonWithoutLabel {
|
|
853
853
|
constructor() {
|
|
854
854
|
this.color = input(undefined);
|
|
855
855
|
this.icon = input();
|
|
@@ -861,20 +861,28 @@ class BaseButton {
|
|
|
861
861
|
this.buttonDisabled = computed(() => this.isDisabled() || this.isInProgress());
|
|
862
862
|
this.buttonClick = output();
|
|
863
863
|
}
|
|
864
|
-
static { this.ɵfac = function
|
|
865
|
-
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type:
|
|
864
|
+
static { this.ɵfac = function BaseButtonWithoutLabel_Factory(t) { return new (t || BaseButtonWithoutLabel)(); }; }
|
|
865
|
+
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: BaseButtonWithoutLabel, inputs: { color: [1, "color"], icon: [1, "icon"], iconAlignment: [1, "iconAlignment"], isDisabled: [1, "isDisabled"], isInProgress: [1, "isInProgress"] }, outputs: { buttonClick: "buttonClick" } }); }
|
|
866
866
|
}
|
|
867
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(
|
|
867
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(BaseButtonWithoutLabel, [{
|
|
868
868
|
type: Directive
|
|
869
869
|
}], null, null); })();
|
|
870
|
-
class BaseButtonWithLabel
|
|
870
|
+
class BaseButtonWithLabel {
|
|
871
871
|
constructor() {
|
|
872
|
-
super(...arguments);
|
|
873
872
|
this.translateLabel = input(true);
|
|
874
873
|
this.label = input();
|
|
874
|
+
this.color = input(undefined);
|
|
875
|
+
this.icon = input();
|
|
876
|
+
this.iconAlignment = input('left');
|
|
877
|
+
this.isDisabled = input(false);
|
|
878
|
+
this.isInProgress = input(false);
|
|
879
|
+
this.showIcon = computed(() => !!this.icon() || this.isInProgress());
|
|
880
|
+
this.iconToShow = computed(() => this.isInProgress() ? 'update' : this.icon());
|
|
881
|
+
this.buttonDisabled = computed(() => this.isDisabled() || this.isInProgress());
|
|
882
|
+
this.buttonClick = output();
|
|
875
883
|
}
|
|
876
|
-
static { this.ɵfac =
|
|
877
|
-
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: BaseButtonWithLabel, inputs: { translateLabel: [1, "translateLabel"], label: [1, "label"]
|
|
884
|
+
static { this.ɵfac = function BaseButtonWithLabel_Factory(t) { return new (t || BaseButtonWithLabel)(); }; }
|
|
885
|
+
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: BaseButtonWithLabel, inputs: { translateLabel: [1, "translateLabel"], label: [1, "label"], color: [1, "color"], icon: [1, "icon"], iconAlignment: [1, "iconAlignment"], isDisabled: [1, "isDisabled"], isInProgress: [1, "isInProgress"] }, outputs: { buttonClick: "buttonClick" } }); }
|
|
878
886
|
}
|
|
879
887
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(BaseButtonWithLabel, [{
|
|
880
888
|
type: Directive
|
|
@@ -1111,7 +1119,7 @@ class RaisedButtonComponent extends BaseButtonWithLabel {
|
|
|
1111
1119
|
}], null, null); })();
|
|
1112
1120
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(RaisedButtonComponent, { className: "RaisedButtonComponent", filePath: "lib\\buttons\\raised-button\\raised-button.component.ts", lineNumber: 15 }); })();
|
|
1113
1121
|
|
|
1114
|
-
class IconButtonComponent extends
|
|
1122
|
+
class IconButtonComponent extends BaseButtonWithoutLabel {
|
|
1115
1123
|
static { this.ɵfac = /*@__PURE__*/ (() => { let ɵIconButtonComponent_BaseFactory; return function IconButtonComponent_Factory(t) { return (ɵIconButtonComponent_BaseFactory || (ɵIconButtonComponent_BaseFactory = i0.ɵɵgetInheritedFactory(IconButtonComponent)))(t || IconButtonComponent); }; })(); }
|
|
1116
1124
|
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: IconButtonComponent, selectors: [["app-icon-button"]], standalone: true, features: [i0.ɵɵInheritDefinitionFeature, i0.ɵɵStandaloneFeature], decls: 3, vars: 6, consts: [["mat-icon-button", "", "onclick", "this.blur()", 3, "click", "disabled"]], template: function IconButtonComponent_Template(rf, ctx) { if (rf & 1) {
|
|
1117
1125
|
i0.ɵɵelementStart(0, "button", 0);
|