matcha-components 20.166.0 → 20.168.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.
|
@@ -9221,6 +9221,7 @@ class MatchaSelectComponent {
|
|
|
9221
9221
|
this.opened = new EventEmitter();
|
|
9222
9222
|
this.closed = new EventEmitter();
|
|
9223
9223
|
this.selectionChange = new EventEmitter();
|
|
9224
|
+
this.openedChange = new EventEmitter();
|
|
9224
9225
|
this.open = false;
|
|
9225
9226
|
this.activeIndex = -1;
|
|
9226
9227
|
// ControlValueAccessor properties
|
|
@@ -9364,6 +9365,7 @@ class MatchaSelectComponent {
|
|
|
9364
9365
|
this.setActiveIndexFromSelectedValue();
|
|
9365
9366
|
this.updateSelectedStates();
|
|
9366
9367
|
this.opened.emit();
|
|
9368
|
+
this.openedChange.emit(true);
|
|
9367
9369
|
}
|
|
9368
9370
|
closePanel() {
|
|
9369
9371
|
if (!this.open)
|
|
@@ -9373,6 +9375,7 @@ class MatchaSelectComponent {
|
|
|
9373
9375
|
this.updateSelectedStates();
|
|
9374
9376
|
this.panel.closePanel();
|
|
9375
9377
|
this.closed.emit();
|
|
9378
|
+
this.openedChange.emit(false);
|
|
9376
9379
|
// Marcar como touched quando o painel fecha (importante para validação)
|
|
9377
9380
|
this.onTouched();
|
|
9378
9381
|
}
|
|
@@ -9438,8 +9441,8 @@ class MatchaSelectComponent {
|
|
|
9438
9441
|
});
|
|
9439
9442
|
// Notificar a diretiva sobre a seleção
|
|
9440
9443
|
this.notifyDirectiveOfSelection(option.value);
|
|
9441
|
-
// Emitir evento de mudança de seleção
|
|
9442
|
-
this.selectionChange.emit(option.value);
|
|
9444
|
+
// Emitir evento de mudança de seleção (compatível com MatSelectChange)
|
|
9445
|
+
this.selectionChange.emit({ source: this, value: option.value });
|
|
9443
9446
|
// Notificar o Angular Forms sobre a mudança
|
|
9444
9447
|
this.onChange(option.value);
|
|
9445
9448
|
this.onTouched();
|
|
@@ -9499,8 +9502,8 @@ class MatchaSelectComponent {
|
|
|
9499
9502
|
});
|
|
9500
9503
|
// Notificar a diretiva sobre a seleção antes de fechar o painel
|
|
9501
9504
|
this.notifyDirectiveOfSelection(option.value);
|
|
9502
|
-
// Emitir evento de mudança de seleção
|
|
9503
|
-
this.selectionChange.emit(option.value);
|
|
9505
|
+
// Emitir evento de mudança de seleção (compatível com MatSelectChange)
|
|
9506
|
+
this.selectionChange.emit({ source: this, value: option.value });
|
|
9504
9507
|
// Notificar o Angular Forms sobre a mudança
|
|
9505
9508
|
this.onChange(option.value);
|
|
9506
9509
|
this.onTouched();
|
|
@@ -9582,7 +9585,7 @@ class MatchaSelectComponent {
|
|
|
9582
9585
|
this.cdr.detectChanges();
|
|
9583
9586
|
}
|
|
9584
9587
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: MatchaSelectComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
9585
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.0", type: MatchaSelectComponent, isStandalone: false, selector: "matcha-select", inputs: { placement: "placement", maxHeight: "maxHeight", minWidth: "minWidth", placeholder: "placeholder", disabled: "disabled" }, outputs: { opened: "opened", closed: "closed", selectionChange: "selectionChange" }, host: { properties: { "class.matcha-select-disabled": "this.hostDisabledClass", "attr.disabled": "this.hostDisabledAttr" } }, providers: [
|
|
9588
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.0", type: MatchaSelectComponent, isStandalone: false, selector: "matcha-select", inputs: { placement: "placement", maxHeight: "maxHeight", minWidth: "minWidth", placeholder: "placeholder", disabled: "disabled" }, outputs: { opened: "opened", closed: "closed", selectionChange: "selectionChange", openedChange: "openedChange" }, host: { properties: { "class.matcha-select-disabled": "this.hostDisabledClass", "attr.disabled": "this.hostDisabledAttr" } }, providers: [
|
|
9586
9589
|
{
|
|
9587
9590
|
provide: NG_VALUE_ACCESSOR,
|
|
9588
9591
|
useExisting: forwardRef(() => MatchaSelectComponent),
|
|
@@ -9629,6 +9632,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
9629
9632
|
type: Output
|
|
9630
9633
|
}], selectionChange: [{
|
|
9631
9634
|
type: Output
|
|
9635
|
+
}], openedChange: [{
|
|
9636
|
+
type: Output
|
|
9632
9637
|
}], hostDisabledClass: [{
|
|
9633
9638
|
type: HostBinding,
|
|
9634
9639
|
args: ['class.matcha-select-disabled']
|
|
@@ -12276,6 +12281,9 @@ class MatchaAutocompleteTriggerDirective {
|
|
|
12276
12281
|
get hostDisabled() {
|
|
12277
12282
|
return !!(this.disabled || this.panel?.disabled || this.ngControl?.control?.disabled);
|
|
12278
12283
|
}
|
|
12284
|
+
get autocompleteOff() {
|
|
12285
|
+
return 'off';
|
|
12286
|
+
}
|
|
12279
12287
|
ngAfterViewInit() {
|
|
12280
12288
|
if (!this.panel) {
|
|
12281
12289
|
throw new Error('Você precisa passar uma referência para <matcha-autocomplete> ex: [matchaAutocomplete]="auto"');
|
|
@@ -12590,7 +12598,7 @@ class MatchaAutocompleteTriggerDirective {
|
|
|
12590
12598
|
}
|
|
12591
12599
|
}
|
|
12592
12600
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: MatchaAutocompleteTriggerDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
12593
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.0", type: MatchaAutocompleteTriggerDirective, isStandalone: false, selector: "[matchaAutocomplete]", inputs: { panel: ["matchaAutocomplete", "panel"], disabled: "disabled" }, host: { listeners: { "click": "onClick()", "focus": "onFocus()", "input": "onInput($event)", "blur": "onBlur()", "keydown": "onKeydown($event)", "document:click": "onDocClick($event)" }, properties: { "disabled": "this.hostDisabled" } }, ngImport: i0 }); }
|
|
12601
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.0", type: MatchaAutocompleteTriggerDirective, isStandalone: false, selector: "[matchaAutocomplete]", inputs: { panel: ["matchaAutocomplete", "panel"], disabled: "disabled" }, host: { listeners: { "click": "onClick()", "focus": "onFocus()", "input": "onInput($event)", "blur": "onBlur()", "keydown": "onKeydown($event)", "document:click": "onDocClick($event)" }, properties: { "disabled": "this.hostDisabled", "attr.autocomplete": "this.autocompleteOff" } }, ngImport: i0 }); }
|
|
12594
12602
|
}
|
|
12595
12603
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: MatchaAutocompleteTriggerDirective, decorators: [{
|
|
12596
12604
|
type: Directive,
|
|
@@ -12606,6 +12614,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
12606
12614
|
}], hostDisabled: [{
|
|
12607
12615
|
type: HostBinding,
|
|
12608
12616
|
args: ['disabled']
|
|
12617
|
+
}], autocompleteOff: [{
|
|
12618
|
+
type: HostBinding,
|
|
12619
|
+
args: ['attr.autocomplete']
|
|
12609
12620
|
}], onClick: [{
|
|
12610
12621
|
type: HostListener,
|
|
12611
12622
|
args: ['click']
|