novo-elements 7.13.0-next.6 → 7.13.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/esm2020/src/elements/query-builder/condition-definitions/address-condition.definition.mjs +26 -12
- package/fesm2015/novo-elements.mjs +28 -11
- package/fesm2015/novo-elements.mjs.map +1 -1
- package/fesm2020/novo-elements.mjs +25 -11
- package/fesm2020/novo-elements.mjs.map +1 -1
- package/package.json +1 -1
- package/src/elements/query-builder/condition-definitions/address-condition.definition.d.ts +6 -3
|
@@ -57571,7 +57571,8 @@ class NovoDefaultAddressConditionDef extends AbstractConditionFieldDef {
|
|
|
57571
57571
|
this.chipListModel = '';
|
|
57572
57572
|
this.term = '';
|
|
57573
57573
|
}
|
|
57574
|
-
onKeyup(event) {
|
|
57574
|
+
onKeyup(event, viewIndex) {
|
|
57575
|
+
this.openPlacesList(viewIndex);
|
|
57575
57576
|
this.term = event.target.value;
|
|
57576
57577
|
}
|
|
57577
57578
|
getValue(formGroup) {
|
|
@@ -57580,6 +57581,15 @@ class NovoDefaultAddressConditionDef extends AbstractConditionFieldDef {
|
|
|
57580
57581
|
getCurrentOverlay(viewIndex) {
|
|
57581
57582
|
return this.overlayChildren?.find(item => item.overlayId === viewIndex);
|
|
57582
57583
|
}
|
|
57584
|
+
getCurrentInput(viewIndex) {
|
|
57585
|
+
return this.inputChildren?.find(item => item.nativeElement.id === viewIndex);
|
|
57586
|
+
}
|
|
57587
|
+
openPlacesList(viewIndex) {
|
|
57588
|
+
this.getCurrentOverlay(viewIndex)?.openPanel();
|
|
57589
|
+
}
|
|
57590
|
+
closePlacesList(viewIndex) {
|
|
57591
|
+
this.getCurrentOverlay(viewIndex)?.closePanel();
|
|
57592
|
+
}
|
|
57583
57593
|
selectPlace(event, formGroup, viewIndex) {
|
|
57584
57594
|
const valueToAdd = {
|
|
57585
57595
|
address_components: event.address_components,
|
|
@@ -57597,9 +57607,10 @@ class NovoDefaultAddressConditionDef extends AbstractConditionFieldDef {
|
|
|
57597
57607
|
this.inputChildren.forEach(input => {
|
|
57598
57608
|
input.nativeElement.value = '';
|
|
57599
57609
|
});
|
|
57600
|
-
this.
|
|
57610
|
+
this.getCurrentInput(viewIndex)?.nativeElement.focus();
|
|
57611
|
+
this.closePlacesList(viewIndex);
|
|
57601
57612
|
}
|
|
57602
|
-
remove(valueToRemove, formGroup) {
|
|
57613
|
+
remove(valueToRemove, formGroup, viewIndex) {
|
|
57603
57614
|
const current = this.getValue(formGroup);
|
|
57604
57615
|
const index = current.indexOf(valueToRemove);
|
|
57605
57616
|
if (index >= 0) {
|
|
@@ -57607,6 +57618,7 @@ class NovoDefaultAddressConditionDef extends AbstractConditionFieldDef {
|
|
|
57607
57618
|
oldValue.splice(index, 1);
|
|
57608
57619
|
formGroup.get('value').setValue(oldValue);
|
|
57609
57620
|
}
|
|
57621
|
+
this.closePlacesList(viewIndex);
|
|
57610
57622
|
}
|
|
57611
57623
|
}
|
|
57612
57624
|
NovoDefaultAddressConditionDef.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.11", ngImport: i0, type: NovoDefaultAddressConditionDef, deps: [{ token: i0.ElementRef }, { token: NovoLabelService }], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -57620,19 +57632,20 @@ NovoDefaultAddressConditionDef.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
|
57620
57632
|
</novo-field>
|
|
57621
57633
|
<ng-container *novoConditionInputDef="let formGroup; viewIndex as viewIndex; fieldMeta as meta" [ngSwitch]="formGroup.value.operator" [formGroup]="formGroup">
|
|
57622
57634
|
<novo-field *novoSwitchCases="['includeAny', 'excludeAny']" #novoField>
|
|
57623
|
-
<novo-chip-list [(ngModel)]="chipListModel" [ngModelOptions]="{ standalone: true }">
|
|
57624
|
-
<novo-chip *ngFor="let item of formGroup.get('value').value" (removed)="remove(item, formGroup)">
|
|
57635
|
+
<novo-chip-list [(ngModel)]="chipListModel" [ngModelOptions]="{ standalone: true }" (click)="openPlacesList(viewIndex)">
|
|
57636
|
+
<novo-chip *ngFor="let item of formGroup.get('value').value" (removed)="remove(item, formGroup, viewIndex)">
|
|
57625
57637
|
{{ item.formatted_address }}
|
|
57626
57638
|
<novo-icon novoChipRemove>close</novo-icon>
|
|
57627
57639
|
</novo-chip>
|
|
57628
57640
|
<input
|
|
57629
57641
|
novoChipInput
|
|
57642
|
+
[id]="viewIndex"
|
|
57630
57643
|
[placeholder]="labels.location"
|
|
57631
|
-
(keyup)="onKeyup($event)"
|
|
57644
|
+
(keyup)="onKeyup($event, viewIndex)"
|
|
57632
57645
|
[picker]="placesPicker"
|
|
57633
57646
|
#addressInput />
|
|
57634
57647
|
</novo-chip-list>
|
|
57635
|
-
<novo-picker-toggle
|
|
57648
|
+
<novo-picker-toggle [overlayId]="viewIndex" icon="location" novoSuffix>
|
|
57636
57649
|
<google-places-list [term]="term" (select)="selectPlace($event, formGroup, viewIndex)" formControlName="value" #placesPicker></google-places-list>
|
|
57637
57650
|
</novo-picker-toggle>
|
|
57638
57651
|
</novo-field>
|
|
@@ -57653,19 +57666,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.11", ngImpo
|
|
|
57653
57666
|
</novo-field>
|
|
57654
57667
|
<ng-container *novoConditionInputDef="let formGroup; viewIndex as viewIndex; fieldMeta as meta" [ngSwitch]="formGroup.value.operator" [formGroup]="formGroup">
|
|
57655
57668
|
<novo-field *novoSwitchCases="['includeAny', 'excludeAny']" #novoField>
|
|
57656
|
-
<novo-chip-list [(ngModel)]="chipListModel" [ngModelOptions]="{ standalone: true }">
|
|
57657
|
-
<novo-chip *ngFor="let item of formGroup.get('value').value" (removed)="remove(item, formGroup)">
|
|
57669
|
+
<novo-chip-list [(ngModel)]="chipListModel" [ngModelOptions]="{ standalone: true }" (click)="openPlacesList(viewIndex)">
|
|
57670
|
+
<novo-chip *ngFor="let item of formGroup.get('value').value" (removed)="remove(item, formGroup, viewIndex)">
|
|
57658
57671
|
{{ item.formatted_address }}
|
|
57659
57672
|
<novo-icon novoChipRemove>close</novo-icon>
|
|
57660
57673
|
</novo-chip>
|
|
57661
57674
|
<input
|
|
57662
57675
|
novoChipInput
|
|
57676
|
+
[id]="viewIndex"
|
|
57663
57677
|
[placeholder]="labels.location"
|
|
57664
|
-
(keyup)="onKeyup($event)"
|
|
57678
|
+
(keyup)="onKeyup($event, viewIndex)"
|
|
57665
57679
|
[picker]="placesPicker"
|
|
57666
57680
|
#addressInput />
|
|
57667
57681
|
</novo-chip-list>
|
|
57668
|
-
<novo-picker-toggle
|
|
57682
|
+
<novo-picker-toggle [overlayId]="viewIndex" icon="location" novoSuffix>
|
|
57669
57683
|
<google-places-list [term]="term" (select)="selectPlace($event, formGroup, viewIndex)" formControlName="value" #placesPicker></google-places-list>
|
|
57670
57684
|
</novo-picker-toggle>
|
|
57671
57685
|
</novo-field>
|