@po-ui/ng-components 19.3.0-beta.1 → 19.3.1
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/po-ui-ng-components.mjs +44 -124
- package/fesm2022/po-ui-ng-components.mjs.map +1 -1
- package/lib/components/po-field/po-combo/po-combo-base.component.d.ts +1 -10
- package/lib/components/po-field/po-multiselect/po-multiselect-base.component.d.ts +1 -10
- package/lib/components/po-field/po-select/po-select.component.d.ts +1 -10
- package/lib/services/po-i18n/index.d.ts +0 -1
- package/lib/services/po-i18n/interfaces/po-i18n-config.interface.d.ts +1 -2
- package/lib/services/po-i18n/po-i18n-config-injection-token.d.ts +1 -1
- package/lib/services/po-i18n/po-i18n.module.d.ts +2 -1
- package/lib/services/po-i18n/po-i18n.service.d.ts +1 -2
- package/package.json +4 -4
- package/po-ui-ng-components-19.3.1.tgz +0 -0
- package/schematics/ng-add/index.js +1 -1
- package/schematics/ng-update/v14/index.js +1 -1
- package/schematics/ng-update/v15/index.js +1 -1
- package/schematics/ng-update/v16/index.js +1 -1
- package/schematics/ng-update/v17/index.js +1 -1
- package/schematics/ng-update/v18/index.js +2 -2
- package/schematics/ng-update/v19/index.js +2 -2
- package/schematics/ng-update/v2/index.js +1 -1
- package/schematics/ng-update/v3/index.js +1 -1
- package/schematics/ng-update/v4/index.js +1 -1
- package/schematics/ng-update/v5/index.js +1 -1
- package/schematics/ng-update/v6/index.js +1 -1
- package/lib/services/po-i18n/interfaces/po-i18n-config-context.interface.d.ts +0 -18
- package/po-ui-ng-components-19.3.0-beta.1.tgz +0 -0
|
@@ -27853,11 +27853,15 @@ class PoTableComponent extends PoTableBaseComponent {
|
|
|
27853
27853
|
}
|
|
27854
27854
|
getTemplate(column) {
|
|
27855
27855
|
const template = this.tableColumnTemplates?.find(tableColumnTemplate => tableColumnTemplate.targetProperty === column.property);
|
|
27856
|
-
if (!
|
|
27856
|
+
if (!this.initialized)
|
|
27857
|
+
return null;
|
|
27858
|
+
if (template) {
|
|
27859
|
+
return template.templateRef;
|
|
27860
|
+
}
|
|
27861
|
+
else {
|
|
27857
27862
|
console.warn(`Não foi possível encontrar o template para a coluna: ${column.property}, por gentileza informe a propriedade [p-property]`);
|
|
27858
27863
|
return null;
|
|
27859
27864
|
}
|
|
27860
|
-
return template.templateRef;
|
|
27861
27865
|
}
|
|
27862
27866
|
getWidthColumnManager() {
|
|
27863
27867
|
return this.columnManager?.nativeElement.offsetWidth;
|
|
@@ -29297,12 +29301,6 @@ class PoComboBaseComponent {
|
|
|
29297
29301
|
*
|
|
29298
29302
|
*/
|
|
29299
29303
|
inputChange = new EventEmitter();
|
|
29300
|
-
/**
|
|
29301
|
-
* @docsPrivate
|
|
29302
|
-
*
|
|
29303
|
-
* Determinar se o valor do compo deve retorna objeto do tipo {value: any, label: any}
|
|
29304
|
-
*/
|
|
29305
|
-
controlValueWithLabel = false;
|
|
29306
29304
|
cacheOptions = [];
|
|
29307
29305
|
defaultService;
|
|
29308
29306
|
firstInWriteValue = true;
|
|
@@ -29819,7 +29817,6 @@ class PoComboBaseComponent {
|
|
|
29819
29817
|
}
|
|
29820
29818
|
// Recebe as alterações do model
|
|
29821
29819
|
writeValue(value) {
|
|
29822
|
-
value = this.getValueWrite(value);
|
|
29823
29820
|
this.fromWriteValue = true;
|
|
29824
29821
|
if (validValue(value) && !this.service && this.comboOptionsList && this.comboOptionsList.length) {
|
|
29825
29822
|
const option = this.getOptionFromValue(value, this.comboOptionsList);
|
|
@@ -29930,22 +29927,6 @@ class PoComboBaseComponent {
|
|
|
29930
29927
|
return labelA < labelB ? -1 : labelA > labelB ? 1 : 0;
|
|
29931
29928
|
};
|
|
29932
29929
|
}
|
|
29933
|
-
getValueUpdate(data, selectedOption) {
|
|
29934
|
-
if (this.controlValueWithLabel && selectedOption?.value) {
|
|
29935
|
-
const { value, label } = selectedOption;
|
|
29936
|
-
return {
|
|
29937
|
-
value,
|
|
29938
|
-
label
|
|
29939
|
-
};
|
|
29940
|
-
}
|
|
29941
|
-
return data;
|
|
29942
|
-
}
|
|
29943
|
-
getValueWrite(data) {
|
|
29944
|
-
if (this.controlValueWithLabel && data?.value) {
|
|
29945
|
-
return data.value;
|
|
29946
|
-
}
|
|
29947
|
-
return data;
|
|
29948
|
-
}
|
|
29949
29930
|
hasDuplicatedOption(options, currentOption, accumulatedGroupOptions) {
|
|
29950
29931
|
if (accumulatedGroupOptions) {
|
|
29951
29932
|
return accumulatedGroupOptions.some(option => option[this.dynamicLabel] === currentOption);
|
|
@@ -30024,7 +30005,7 @@ class PoComboBaseComponent {
|
|
|
30024
30005
|
updateModel(value) {
|
|
30025
30006
|
if (value !== this.selectedValue) {
|
|
30026
30007
|
if (!this.fromWriteValue) {
|
|
30027
|
-
this.callModelChange(
|
|
30008
|
+
this.callModelChange(value);
|
|
30028
30009
|
}
|
|
30029
30010
|
this.change.emit(this.emitObjectValue ? this.selectedOption : value);
|
|
30030
30011
|
}
|
|
@@ -30043,7 +30024,7 @@ class PoComboBaseComponent {
|
|
|
30043
30024
|
}
|
|
30044
30025
|
}
|
|
30045
30026
|
static ɵfac = function PoComboBaseComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || PoComboBaseComponent)(i0.ɵɵdirectiveInject(PoLanguageService), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
30046
|
-
static ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: PoComboBaseComponent, inputs: { additionalHelpEventTrigger: "additionalHelpEventTrigger", additionalHelpTooltip: [0, "p-additional-help-tooltip", "additionalHelpTooltip"], autoFocus: [2, "p-auto-focus", "autoFocus", convertToBoolean], label: [0, "p-label", "label"], help: [0, "p-help", "help"], name: "name", filterService: [0, "p-filter-service", "filterService"], infiniteScroll: [0, "p-infinite-scroll", "infiniteScroll"], infiniteScrollDistance: [0, "p-infinite-scroll-distance", "infiniteScrollDistance"], icon: [0, "p-icon", "icon"], optional: [0, "p-optional", "optional"], clean: [2, "p-clean", "clean", convertToBoolean], emitObjectValue: [2, "p-emit-object-value", "emitObjectValue", convertToBoolean], disabledTabFilter: [2, "p-disabled-tab-filter", "disabledTabFilter", convertToBoolean], removeInitialFilter: [0, "p-remove-initial-filter", "removeInitialFilter"], fieldErrorMessage: [0, "p-field-error-message", "fieldErrorMessage"], errorLimit: [0, "p-error-limit", "errorLimit"],
|
|
30027
|
+
static ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: PoComboBaseComponent, inputs: { additionalHelpEventTrigger: "additionalHelpEventTrigger", additionalHelpTooltip: [0, "p-additional-help-tooltip", "additionalHelpTooltip"], autoFocus: [2, "p-auto-focus", "autoFocus", convertToBoolean], label: [0, "p-label", "label"], help: [0, "p-help", "help"], name: "name", filterService: [0, "p-filter-service", "filterService"], infiniteScroll: [0, "p-infinite-scroll", "infiniteScroll"], infiniteScrollDistance: [0, "p-infinite-scroll-distance", "infiniteScrollDistance"], icon: [0, "p-icon", "icon"], optional: [0, "p-optional", "optional"], clean: [2, "p-clean", "clean", convertToBoolean], emitObjectValue: [2, "p-emit-object-value", "emitObjectValue", convertToBoolean], disabledTabFilter: [2, "p-disabled-tab-filter", "disabledTabFilter", convertToBoolean], removeInitialFilter: [0, "p-remove-initial-filter", "removeInitialFilter"], fieldErrorMessage: [0, "p-field-error-message", "fieldErrorMessage"], errorLimit: [0, "p-error-limit", "errorLimit"], placeholder: [0, "p-placeholder", "placeholder"], debounceTime: [0, "p-debounce-time", "debounceTime"], disabledInitFilter: [0, "p-disabled-init-filter", "disabledInitFilter"], fieldValue: [0, "p-field-value", "fieldValue"], fieldLabel: [0, "p-field-label", "fieldLabel"], filterMinlength: [0, "p-filter-minlength", "filterMinlength"], required: [0, "p-required", "required"], showRequired: [0, "p-show-required", "showRequired"], changeOnEnter: [0, "p-change-on-enter", "changeOnEnter"], disabled: [0, "p-disabled", "disabled"], sort: [0, "p-sort", "sort"], options: [0, "p-options", "options"], filterMode: [0, "p-filter-mode", "filterMode"], filterParams: [0, "p-filter-params", "filterParams"], literals: [0, "p-literals", "literals"], cache: [2, "p-cache", "cache", convertToBoolean], appendBox: [2, "p-append-in-body", "appendBox", convertToBoolean] }, outputs: { additionalHelp: "p-additional-help", change: "p-change", keydown: "p-keydown", ngModelChange: "ngModelChange", inputChange: "p-input-change" }, features: [i0.ɵɵInputTransformsFeature] });
|
|
30047
30028
|
}
|
|
30048
30029
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(PoComboBaseComponent, [{
|
|
30049
30030
|
type: Directive
|
|
@@ -30112,9 +30093,6 @@ class PoComboBaseComponent {
|
|
|
30112
30093
|
}], inputChange: [{
|
|
30113
30094
|
type: Output,
|
|
30114
30095
|
args: ['p-input-change']
|
|
30115
|
-
}], controlValueWithLabel: [{
|
|
30116
|
-
type: Input,
|
|
30117
|
-
args: [{ alias: 'p-control-value-with-label', transform: convertToBoolean }]
|
|
30118
30096
|
}], placeholder: [{
|
|
30119
30097
|
type: Input,
|
|
30120
30098
|
args: ['p-placeholder']
|
|
@@ -37629,12 +37607,6 @@ class PoMultiselectBaseComponent {
|
|
|
37629
37607
|
* @default `false`
|
|
37630
37608
|
*/
|
|
37631
37609
|
appendBox = false;
|
|
37632
|
-
/**
|
|
37633
|
-
* @docsPrivate
|
|
37634
|
-
*
|
|
37635
|
-
* Determinar se o valor do compo deve retorna objeto do tipo {value: any, label: any}
|
|
37636
|
-
*/
|
|
37637
|
-
controlValueWithLabel = false;
|
|
37638
37610
|
selectedOptions = [];
|
|
37639
37611
|
visibleOptionsDropdown = [];
|
|
37640
37612
|
visibleTags = [];
|
|
@@ -38016,7 +37988,7 @@ class PoMultiselectBaseComponent {
|
|
|
38016
37988
|
}
|
|
38017
37989
|
callOnChange(selectedOptions) {
|
|
38018
37990
|
if (this.onModelChange) {
|
|
38019
|
-
this.onModelChange(this.
|
|
37991
|
+
this.onModelChange(this.getValuesFromOptions(selectedOptions));
|
|
38020
37992
|
this.eventChange(selectedOptions);
|
|
38021
37993
|
}
|
|
38022
37994
|
}
|
|
@@ -38096,7 +38068,7 @@ class PoMultiselectBaseComponent {
|
|
|
38096
38068
|
this.updateVisibleItems();
|
|
38097
38069
|
}
|
|
38098
38070
|
writeValue(values) {
|
|
38099
|
-
values =
|
|
38071
|
+
values = values || [];
|
|
38100
38072
|
if (this.service && values.length) {
|
|
38101
38073
|
this.getObjectsByValuesSubscription = this.service.getObjectsByValues(values).subscribe(options => {
|
|
38102
38074
|
this.updateSelectedOptions(options);
|
|
@@ -38125,18 +38097,6 @@ class PoMultiselectBaseComponent {
|
|
|
38125
38097
|
registerOnValidatorChange(fn) {
|
|
38126
38098
|
this.validatorChange = fn;
|
|
38127
38099
|
}
|
|
38128
|
-
getValueUpdate(selectedOptions) {
|
|
38129
|
-
if (this.controlValueWithLabel && selectedOptions?.length) {
|
|
38130
|
-
return selectedOptions.map(option => ({ value: option[this.fieldValue], label: option[this.fieldLabel] }));
|
|
38131
|
-
}
|
|
38132
|
-
return this.getValuesFromOptions(selectedOptions);
|
|
38133
|
-
}
|
|
38134
|
-
getValueWrite(data) {
|
|
38135
|
-
if (this.controlValueWithLabel && data?.length && data.some(x => x.value)) {
|
|
38136
|
-
return data.map(option => option.value || null);
|
|
38137
|
-
}
|
|
38138
|
-
return data;
|
|
38139
|
-
}
|
|
38140
38100
|
setLabelsAndValuesOptions() {
|
|
38141
38101
|
if (this.fieldLabel && this.fieldValue && this.options) {
|
|
38142
38102
|
this.options.map(option => {
|
|
@@ -38151,7 +38111,7 @@ class PoMultiselectBaseComponent {
|
|
|
38151
38111
|
}
|
|
38152
38112
|
}
|
|
38153
38113
|
static ɵfac = function PoMultiselectBaseComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || PoMultiselectBaseComponent)(i0.ɵɵdirectiveInject(PoLanguageService)); };
|
|
38154
|
-
static ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: PoMultiselectBaseComponent, inputs: { additionalHelpEventTrigger: "additionalHelpEventTrigger", additionalHelpTooltip: [0, "p-additional-help-tooltip", "additionalHelpTooltip"], autoFocus: [2, "p-auto-focus", "autoFocus", convertToBoolean], label: [0, "p-label", "label"], help: [0, "p-help", "help"], optional: [0, "p-optional", "optional"], placeholder: [0, "p-placeholder", "placeholder"], placeholderSearch: [0, "p-placeholder-search", "placeholderSearch"], name: "name", hideSelectAll: [2, "p-hide-select-all", "hideSelectAll", convertToBoolean], fieldErrorMessage: [0, "p-field-error-message", "fieldErrorMessage"], errorLimit: [0, "p-error-limit", "errorLimit"], appendBox: [2, "p-append-in-body", "appendBox", convertToBoolean],
|
|
38114
|
+
static ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: PoMultiselectBaseComponent, inputs: { additionalHelpEventTrigger: "additionalHelpEventTrigger", additionalHelpTooltip: [0, "p-additional-help-tooltip", "additionalHelpTooltip"], autoFocus: [2, "p-auto-focus", "autoFocus", convertToBoolean], label: [0, "p-label", "label"], help: [0, "p-help", "help"], optional: [0, "p-optional", "optional"], placeholder: [0, "p-placeholder", "placeholder"], placeholderSearch: [0, "p-placeholder-search", "placeholderSearch"], name: "name", hideSelectAll: [2, "p-hide-select-all", "hideSelectAll", convertToBoolean], fieldErrorMessage: [0, "p-field-error-message", "fieldErrorMessage"], errorLimit: [0, "p-error-limit", "errorLimit"], appendBox: [2, "p-append-in-body", "appendBox", convertToBoolean], filterService: [0, "p-filter-service", "filterService"], autoHeight: [2, "p-auto-height", "autoHeight", convertToBoolean], debounceTime: [0, "p-debounce-time", "debounceTime"], literals: [0, "p-literals", "literals"], required: [0, "p-required", "required"], showRequired: [0, "p-show-required", "showRequired"], disabled: [0, "p-disabled", "disabled"], hideSearch: [0, "p-hide-search", "hideSearch"], options: [0, "p-options", "options"], sort: [0, "p-sort", "sort"], filterMode: [0, "p-filter-mode", "filterMode"], fieldLabel: [0, "p-field-label", "fieldLabel"], fieldValue: [0, "p-field-value", "fieldValue"] }, outputs: { additionalHelp: "p-additional-help", change: "p-change", keydown: "p-keydown" }, features: [i0.ɵɵInputTransformsFeature] });
|
|
38155
38115
|
}
|
|
38156
38116
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(PoMultiselectBaseComponent, [{
|
|
38157
38117
|
type: Directive
|
|
@@ -38202,9 +38162,6 @@ class PoMultiselectBaseComponent {
|
|
|
38202
38162
|
}], appendBox: [{
|
|
38203
38163
|
type: Input,
|
|
38204
38164
|
args: [{ alias: 'p-append-in-body', transform: convertToBoolean }]
|
|
38205
|
-
}], controlValueWithLabel: [{
|
|
38206
|
-
type: Input,
|
|
38207
|
-
args: [{ alias: 'p-control-value-with-label', transform: convertToBoolean }]
|
|
38208
38165
|
}], filterService: [{
|
|
38209
38166
|
type: Input,
|
|
38210
38167
|
args: ['p-filter-service']
|
|
@@ -43965,12 +43922,6 @@ class PoSelectComponent extends PoFieldValidateModel {
|
|
|
43965
43922
|
this.options = [...this.options];
|
|
43966
43923
|
}
|
|
43967
43924
|
}
|
|
43968
|
-
/**
|
|
43969
|
-
* @docsPrivate
|
|
43970
|
-
*
|
|
43971
|
-
* Determinar se o valor do compo deve retorna objeto do tipo {value: any, label: any}
|
|
43972
|
-
*/
|
|
43973
|
-
controlValueWithLabel = false;
|
|
43974
43925
|
get fieldValue() {
|
|
43975
43926
|
return this._fieldValue;
|
|
43976
43927
|
}
|
|
@@ -44043,14 +43994,13 @@ class PoSelectComponent extends PoFieldValidateModel {
|
|
|
44043
43994
|
if (this.selectedValue !== option[this.fieldValue]) {
|
|
44044
43995
|
this.selectedValue = option[this.fieldValue];
|
|
44045
43996
|
this.selectElement.nativeElement.value = option[this.fieldValue];
|
|
44046
|
-
this.updateModel(this.
|
|
43997
|
+
this.updateModel(option[this.fieldValue]);
|
|
44047
43998
|
this.displayValue = option[this.fieldLabel];
|
|
44048
43999
|
this.emitChange(option[this.fieldValue]);
|
|
44049
44000
|
}
|
|
44050
44001
|
}
|
|
44051
44002
|
// Recebe as alterações do model
|
|
44052
44003
|
onWriteValue(value) {
|
|
44053
|
-
value = this.getValueWrite(value);
|
|
44054
44004
|
const optionFound = this.findOptionValue(value);
|
|
44055
44005
|
if (optionFound) {
|
|
44056
44006
|
this.selectElement.nativeElement.value = optionFound.value;
|
|
@@ -44121,21 +44071,6 @@ class PoSelectComponent extends PoFieldValidateModel {
|
|
|
44121
44071
|
return this.options.find(option => this.isEqual(option.value, value));
|
|
44122
44072
|
}
|
|
44123
44073
|
}
|
|
44124
|
-
getValueUpdate(option) {
|
|
44125
|
-
if (this.controlValueWithLabel) {
|
|
44126
|
-
return {
|
|
44127
|
-
value: option[this.fieldValue],
|
|
44128
|
-
label: option[this.fieldLabel]
|
|
44129
|
-
};
|
|
44130
|
-
}
|
|
44131
|
-
return option[this.fieldValue];
|
|
44132
|
-
}
|
|
44133
|
-
getValueWrite(data) {
|
|
44134
|
-
if (this.controlValueWithLabel) {
|
|
44135
|
-
return data?.value ?? null;
|
|
44136
|
-
}
|
|
44137
|
-
return data;
|
|
44138
|
-
}
|
|
44139
44074
|
transformInArray(objectWithArray) {
|
|
44140
44075
|
return objectWithArray.reduce((options, items) => {
|
|
44141
44076
|
if (items.options) {
|
|
@@ -44168,7 +44103,7 @@ class PoSelectComponent extends PoFieldValidateModel {
|
|
|
44168
44103
|
} if (rf & 2) {
|
|
44169
44104
|
let _t;
|
|
44170
44105
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.selectElement = _t.first);
|
|
44171
|
-
} }, inputs: { readonly: [2, "p-readonly", "readonly", convertToBoolean], placeholder: [0, "p-placeholder", "placeholder"], options: [0, "p-options", "options"], fieldLabel: [0, "p-field-label", "fieldLabel"], fieldValue: [0, "p-field-value", "fieldValue"]
|
|
44106
|
+
} }, inputs: { readonly: [2, "p-readonly", "readonly", convertToBoolean], placeholder: [0, "p-placeholder", "placeholder"], options: [0, "p-options", "options"], fieldLabel: [0, "p-field-label", "fieldLabel"], fieldValue: [0, "p-field-value", "fieldValue"] }, outputs: { ngModelChange: "ngModelChange" }, standalone: false, features: [i0.ɵɵProvidersFeature([
|
|
44172
44107
|
{
|
|
44173
44108
|
provide: NG_VALUE_ACCESSOR,
|
|
44174
44109
|
useExisting: forwardRef(() => PoSelectComponent),
|
|
@@ -44245,9 +44180,6 @@ class PoSelectComponent extends PoFieldValidateModel {
|
|
|
44245
44180
|
}], fieldValue: [{
|
|
44246
44181
|
type: Input,
|
|
44247
44182
|
args: ['p-field-value']
|
|
44248
|
-
}], controlValueWithLabel: [{
|
|
44249
|
-
type: Input,
|
|
44250
|
-
args: [{ alias: 'p-control-value-with-label', transform: convertToBoolean }]
|
|
44251
44183
|
}] }); })();
|
|
44252
44184
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(PoSelectComponent, { className: "PoSelectComponent", filePath: "lib/components/po-field/po-select/po-select.component.ts", lineNumber: 124 }); })();
|
|
44253
44185
|
|
|
@@ -57891,7 +57823,10 @@ class PoStepperComponent extends PoStepperBaseComponent {
|
|
|
57891
57823
|
this.changeStep(previousIndex, previousStep);
|
|
57892
57824
|
}
|
|
57893
57825
|
changeStep(stepIndex, step) {
|
|
57894
|
-
this.
|
|
57826
|
+
if (!step || (this.currentActiveStep && this.currentActiveStep.id === step.id)) {
|
|
57827
|
+
return;
|
|
57828
|
+
}
|
|
57829
|
+
this.allowNextStep(stepIndex, step)
|
|
57895
57830
|
.pipe(take(1))
|
|
57896
57831
|
.subscribe(nextStepAllowed => {
|
|
57897
57832
|
if (nextStepAllowed) {
|
|
@@ -57901,7 +57836,6 @@ class PoStepperComponent extends PoStepperBaseComponent {
|
|
|
57901
57836
|
this.onChangeStep.emit(step);
|
|
57902
57837
|
}
|
|
57903
57838
|
else if (!this.usePoSteps && stepIndex !== this.currentStepIndex) {
|
|
57904
|
-
// if para tratamento do modelo antigo do po-stepper
|
|
57905
57839
|
this.onChangeStep.emit(stepIndex + 1);
|
|
57906
57840
|
}
|
|
57907
57841
|
}
|
|
@@ -57960,17 +57894,17 @@ class PoStepperComponent extends PoStepperBaseComponent {
|
|
|
57960
57894
|
this.changeStep(0, this.poSteps.first);
|
|
57961
57895
|
}
|
|
57962
57896
|
}
|
|
57963
|
-
allowNextStep(nextStepIndex) {
|
|
57897
|
+
allowNextStep(nextStepIndex, step) {
|
|
57964
57898
|
if (!this.sequential) {
|
|
57965
57899
|
return of(true);
|
|
57966
57900
|
}
|
|
57967
57901
|
if (this.hasStepWithCanActiveNextStep() && this.hasDefaultBeforeDone(nextStepIndex)) {
|
|
57968
57902
|
return of(false);
|
|
57969
57903
|
}
|
|
57970
|
-
const isAllowNextStep$ = this.checkAllowNextStep(nextStepIndex);
|
|
57904
|
+
const isAllowNextStep$ = this.checkAllowNextStep(nextStepIndex, step);
|
|
57971
57905
|
return typeof isAllowNextStep$ === 'boolean' ? of(isAllowNextStep$) : isAllowNextStep$;
|
|
57972
57906
|
}
|
|
57973
|
-
canActiveNextStep(currentActiveStep = {}, nextStepIndex) {
|
|
57907
|
+
canActiveNextStep(currentActiveStep = {}, nextStepIndex, step) {
|
|
57974
57908
|
const isCurrentStep = this.isCurrentStep(nextStepIndex);
|
|
57975
57909
|
if (!currentActiveStep.canActiveNextStep) {
|
|
57976
57910
|
if (!isCurrentStep) {
|
|
@@ -57978,7 +57912,7 @@ class PoStepperComponent extends PoStepperBaseComponent {
|
|
|
57978
57912
|
}
|
|
57979
57913
|
return of(true);
|
|
57980
57914
|
}
|
|
57981
|
-
const canActiveNextStep$ = this.getCanActiveNextStepObservable(currentActiveStep);
|
|
57915
|
+
const canActiveNextStep$ = this.getCanActiveNextStepObservable(currentActiveStep, step);
|
|
57982
57916
|
return of(this.isBeforeStep(nextStepIndex)).pipe(mergeMap(isBefore => {
|
|
57983
57917
|
if (isBefore && !isCurrentStep) {
|
|
57984
57918
|
return canActiveNextStep$.pipe(tap(isCanActiveNextStep => {
|
|
@@ -57997,13 +57931,19 @@ class PoStepperComponent extends PoStepperBaseComponent {
|
|
|
57997
57931
|
return throwError(err);
|
|
57998
57932
|
}));
|
|
57999
57933
|
}
|
|
58000
|
-
checkAllowNextStep(nextStepIndex) {
|
|
57934
|
+
checkAllowNextStep(nextStepIndex, step) {
|
|
58001
57935
|
return this.usePoSteps
|
|
58002
|
-
? this.canActiveNextStep(this.currentActiveStep, nextStepIndex)
|
|
57936
|
+
? this.canActiveNextStep(this.currentActiveStep, nextStepIndex, step)
|
|
58003
57937
|
: of(this.steps.slice(this.step, nextStepIndex).every(step => step.status === PoStepperStatus.Done));
|
|
58004
57938
|
}
|
|
58005
|
-
getCanActiveNextStepObservable(currentActiveStep) {
|
|
58006
|
-
|
|
57939
|
+
getCanActiveNextStepObservable(currentActiveStep, step) {
|
|
57940
|
+
let canActiveNextStep;
|
|
57941
|
+
if (step && step.status === PoStepperStatus.Done) {
|
|
57942
|
+
canActiveNextStep = false;
|
|
57943
|
+
}
|
|
57944
|
+
else {
|
|
57945
|
+
canActiveNextStep = currentActiveStep.canActiveNextStep(currentActiveStep);
|
|
57946
|
+
}
|
|
58007
57947
|
return canActiveNextStep instanceof Observable ? canActiveNextStep : of(canActiveNextStep);
|
|
58008
57948
|
}
|
|
58009
57949
|
hasDefaultBeforeDone(nextStepIndex) {
|
|
@@ -58056,7 +57996,7 @@ class PoStepperComponent extends PoStepperBaseComponent {
|
|
|
58056
57996
|
}
|
|
58057
57997
|
}
|
|
58058
57998
|
hasStepWithCanActiveNextStep() {
|
|
58059
|
-
return this.getPoSteps().some(step => step.canActiveNextStep
|
|
57999
|
+
return this.getPoSteps().some(step => step.canActiveNextStep);
|
|
58060
58000
|
}
|
|
58061
58001
|
isBeforeStep(stepIndex) {
|
|
58062
58002
|
const currentActiveStepIndex = () => this.getPoSteps().findIndex(step => step.id === this.currentActiveStep.id);
|
|
@@ -62192,9 +62132,11 @@ class PoI18nBaseService {
|
|
|
62192
62132
|
const literals = options['literals'] ? options['literals'] : [];
|
|
62193
62133
|
return new Observable(observer => {
|
|
62194
62134
|
if (this.servicesContext[context]) {
|
|
62135
|
+
// Faz o processo de busca de um contexto que contém serviço
|
|
62195
62136
|
this.getLiteralsFromContextService(language, context, literals, observer);
|
|
62196
62137
|
}
|
|
62197
62138
|
else {
|
|
62139
|
+
// Faz o processo de busca de um contexto que utiliza constante
|
|
62198
62140
|
this.getLiteralsFromContextConstant(language, context, literals, observer);
|
|
62199
62141
|
}
|
|
62200
62142
|
});
|
|
@@ -62471,31 +62413,8 @@ class PoI18nService extends PoI18nBaseService {
|
|
|
62471
62413
|
}]
|
|
62472
62414
|
}], null, null); })();
|
|
62473
62415
|
// Função usada para retornar instância para o módulo po-i18n.module
|
|
62474
|
-
function returnPoI18nService(
|
|
62475
|
-
|
|
62476
|
-
...config,
|
|
62477
|
-
contexts: config.contexts,
|
|
62478
|
-
default: config.default
|
|
62479
|
-
}));
|
|
62480
|
-
const mergedObject = mergePoI18nConfigs(validatedConfigs);
|
|
62481
|
-
return new PoI18nService(mergedObject, http, languageService);
|
|
62482
|
-
}
|
|
62483
|
-
function mergePoI18nConfigs(objects) {
|
|
62484
|
-
return objects.reduce((acc, current) => {
|
|
62485
|
-
if (!acc.default) {
|
|
62486
|
-
acc.default = { ...current.default };
|
|
62487
|
-
}
|
|
62488
|
-
Object.entries(current.contexts || {}).forEach(([context, languages]) => {
|
|
62489
|
-
acc.contexts[context] = acc.contexts[context] || {};
|
|
62490
|
-
Object.entries(languages).forEach(([lang, translations]) => {
|
|
62491
|
-
acc.contexts[context][lang] = {
|
|
62492
|
-
...acc.contexts[context][lang],
|
|
62493
|
-
...translations
|
|
62494
|
-
};
|
|
62495
|
-
});
|
|
62496
|
-
});
|
|
62497
|
-
return acc;
|
|
62498
|
-
}, { contexts: {} });
|
|
62416
|
+
function returnPoI18nService(config, http, languageService) {
|
|
62417
|
+
return new PoI18nService(config, http, languageService);
|
|
62499
62418
|
}
|
|
62500
62419
|
|
|
62501
62420
|
/**
|
|
@@ -62634,6 +62553,7 @@ function mergePoI18nConfigs(objects) {
|
|
|
62634
62553
|
* Para aplicações que utilizem a abordagem de módulos com carregamento *lazy loading*, caso seja
|
|
62635
62554
|
* definida outra configuração do `PoI18nModule`, deve-se atentar os seguintes detalhes:
|
|
62636
62555
|
*
|
|
62556
|
+
* - Caso existam literais comuns na aplicação, estas devem ser reimportadas;
|
|
62637
62557
|
* - Não defina outra *default language* para este módulo. Caso for definida, será sobreposta para
|
|
62638
62558
|
* toda a aplicação;
|
|
62639
62559
|
* - Caso precise de módulos carregados via *lazy loading* com linguagens diferentes, utilize o
|
|
@@ -62647,8 +62567,7 @@ class PoI18nModule {
|
|
|
62647
62567
|
providers: [
|
|
62648
62568
|
{
|
|
62649
62569
|
provide: I18N_CONFIG,
|
|
62650
|
-
useValue: config
|
|
62651
|
-
multi: true
|
|
62570
|
+
useValue: config
|
|
62652
62571
|
},
|
|
62653
62572
|
provideAppInitializer(() => {
|
|
62654
62573
|
const initializerFn = initializeLanguageDefault(inject(I18N_CONFIG), inject(PoLanguageService));
|
|
@@ -62673,13 +62592,14 @@ class PoI18nModule {
|
|
|
62673
62592
|
}]
|
|
62674
62593
|
}], null, null); })();
|
|
62675
62594
|
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(PoI18nModule, { imports: [PoLanguageModule] }); })();
|
|
62676
|
-
function initializeLanguageDefault(
|
|
62677
|
-
|
|
62678
|
-
|
|
62679
|
-
if (config
|
|
62595
|
+
function initializeLanguageDefault(config, languageService) {
|
|
62596
|
+
// eslint-disable-next-line sonarjs/prefer-immediate-return
|
|
62597
|
+
const setDefaultLanguage = () => {
|
|
62598
|
+
if (config.default.language) {
|
|
62680
62599
|
languageService.setLanguageDefault(config.default.language);
|
|
62681
62600
|
}
|
|
62682
62601
|
};
|
|
62602
|
+
return setDefaultLanguage;
|
|
62683
62603
|
}
|
|
62684
62604
|
|
|
62685
62605
|
/**
|
|
@@ -62699,5 +62619,5 @@ function initializeLanguageDefault(configs, languageService) {
|
|
|
62699
62619
|
* Generated bundle index. Do not edit.
|
|
62700
62620
|
*/
|
|
62701
62621
|
|
|
62702
|
-
export { AnimaliaIconDictionary, ForceBooleanComponentEnum, ForceOptionComponentEnum, I18N_CONFIG, ICONS_DICTIONARY, InputBoolean, InputRequired, PO_CONTROL_POSITIONS, PoAccordionComponent, PoAccordionItemComponent, PoAccordionModule, PoActiveOverlayModule, PoActiveOverlayService, PoAvatarComponent, PoAvatarModule, PoBadgeComponent, PoBadgeModule, PoBreadcrumbComponent, PoBreadcrumbModule, PoButtonComponent, PoButtonGroupComponent, PoButtonGroupModule, PoButtonGroupToggle, PoButtonModule, PoButtonType, PoCalendarComponent, PoCalendarMode, PoCalendarModule, PoChartComponent, PoChartLabelFormat, PoChartModule, PoChartType, PoCheckboxComponent, PoCheckboxGroupComponent, PoCheckboxGroupModule, PoCheckboxModule, PoCheckboxSize, PoCleanComponent, PoCleanModule, PoColorPaletteModule, PoColorPaletteService, PoComboComponent, PoComboFilterMode, PoComboOptionTemplateDirective, PoComponentInjectorModule, PoComponentInjectorService, PoComponentsModule, PoContainerComponent, PoContainerModule, PoControlPositionModule, PoDateService, PoDateTimeModule, PoDatepickerComponent, PoDatepickerIsoFormat, PoDatepickerModule, PoDatepickerRangeComponent, PoDecimalComponent, PoDialogComponent, PoDialogModule, PoDialogService, PoDialogType, PoDirectivesModule, PoDisclaimerComponent, PoDisclaimerGroupComponent, PoDisclaimerGroupModule, PoDisclaimerModule, PoDividerComponent, PoDividerModule, PoDividerSize, PoDropdownComponent, PoDropdownModule, PoDynamicContainerComponent, PoDynamicFieldType, PoDynamicFormComponent, PoDynamicModule, PoDynamicSharedBase, PoDynamicViewComponent, PoEmailComponent, PoFieldContainerBottomComponent, PoFieldContainerComponent, PoFieldContainerModule, PoFieldModule, PoGaugeComponent, PoGaugeModule, PoGridComponent, PoGridModule, PoGuardsModule, PoHttpInterceptorModule, PoHttpInterceptorService, PoHttpRequestInterceptorService, PoHttpRequestModule, PoI18nModule, PoI18nPipe, PoI18nService, PoIconComponent, PoIconDictionary, PoIconModule, PoImageComponent, PoImageModule, PoInfoComponent, PoInfoModule, PoInfoOrientation, PoInputComponent, PoInterceptorsModule, PoItemListComponent, PoLabelComponent, PoLabelModule, PoLanguageModule, PoLanguageService, PoLinkComponent, PoLinkModule, PoListBoxComponent, PoListBoxModule, PoListViewComponent, PoListViewContentTemplateDirective, PoListViewDetailTemplateDirective, PoListViewModule, PoLoadingComponent, PoLoadingIconComponent, PoLoadingModule, PoLoadingOverlayComponent, PoLoginComponent, PoLogoComponent, PoLogoModule, PoLookupComponent, PoLookupModalComponent, PoMask, PoMediaQueryModule, PoMediaQueryService, PoMenuComponent, PoMenuGlobalService, PoMenuHeaderTemplateDirective, PoMenuModule, PoMenuPanelComponent, PoMenuPanelModule, PoModalComponent, PoModalFooterComponent, PoModalModule, PoModule, PoMultiselectComponent, PoMultiselectFilterMode, PoMultiselectOptionTemplateDirective, PoNavbarComponent, PoNavbarModule, PoNotificationModule, PoNotificationService, PoNumberComponent, PoOverlayComponent, PoOverlayModule, PoPageDefaultComponent, PoPageDetailComponent, PoPageEditComponent, PoPageListComponent, PoPageModule, PoPageSlideComponent, PoPageSlideFooterComponent, PoPageSlideModule, PoPasswordComponent, PoPipesModule, PoPopoverComponent, PoPopoverModule, PoPopupComponent, PoPopupModule, PoProgressComponent, PoProgressModule, PoProgressSize, PoProgressStatus, PoRadioComponent, PoRadioGroupComponent, PoRadioGroupModule, PoRadioModule, PoRichTextComponent, PoRichTextToolbarActions, PoSearchComponent, PoSearchFilterMode, PoSearchListComponent, PoSearchModule, PoSelectComponent, PoServicesModule, PoSlideComponent, PoSlideContentTemplateDirective, PoSlideModule, PoStepComponent, PoStepperComponent, PoStepperModule, PoStepperOrientation, PoStepperStatus, PoSwitchComponent, PoSwitchLabelPosition, PoSwitchModule, PoTabComponent, PoTableCellTemplateDirective, PoTableColumnFrozenDirective, PoTableColumnSortType, PoTableColumnSpacing, PoTableColumnTemplateDirective, PoTableComponent, PoTableModule, PoTableRowTemplateArrowDirection, PoTableRowTemplateDirective, PoTabsComponent, PoTabsModule, PoTabsService, PoTagComponent, PoTagModule, PoTagOrientation, PoTagType, PoTextareaComponent, PoThemeA11yEnum, PoThemeModule, PoThemeService, PoThemeTypeEnum, PoTimeModule, PoTimePipe, PoToasterComponent, PoToasterMode, PoToasterModule, PoToasterOrientation, PoToasterType, PoToolbarComponent, PoToolbarModule, PoTooltipDirective, PoTooltipModule, PoTreeViewComponent, PoTreeViewModule, PoUploadComponent, PoUploadFile, PoUploadStatus, PoUrlComponent, PoWidgetComponent, PoWidgetModule, initializeLanguageDefault,
|
|
62622
|
+
export { AnimaliaIconDictionary, ForceBooleanComponentEnum, ForceOptionComponentEnum, I18N_CONFIG, ICONS_DICTIONARY, InputBoolean, InputRequired, PO_CONTROL_POSITIONS, PoAccordionComponent, PoAccordionItemComponent, PoAccordionModule, PoActiveOverlayModule, PoActiveOverlayService, PoAvatarComponent, PoAvatarModule, PoBadgeComponent, PoBadgeModule, PoBreadcrumbComponent, PoBreadcrumbModule, PoButtonComponent, PoButtonGroupComponent, PoButtonGroupModule, PoButtonGroupToggle, PoButtonModule, PoButtonType, PoCalendarComponent, PoCalendarMode, PoCalendarModule, PoChartComponent, PoChartLabelFormat, PoChartModule, PoChartType, PoCheckboxComponent, PoCheckboxGroupComponent, PoCheckboxGroupModule, PoCheckboxModule, PoCheckboxSize, PoCleanComponent, PoCleanModule, PoColorPaletteModule, PoColorPaletteService, PoComboComponent, PoComboFilterMode, PoComboOptionTemplateDirective, PoComponentInjectorModule, PoComponentInjectorService, PoComponentsModule, PoContainerComponent, PoContainerModule, PoControlPositionModule, PoDateService, PoDateTimeModule, PoDatepickerComponent, PoDatepickerIsoFormat, PoDatepickerModule, PoDatepickerRangeComponent, PoDecimalComponent, PoDialogComponent, PoDialogModule, PoDialogService, PoDialogType, PoDirectivesModule, PoDisclaimerComponent, PoDisclaimerGroupComponent, PoDisclaimerGroupModule, PoDisclaimerModule, PoDividerComponent, PoDividerModule, PoDividerSize, PoDropdownComponent, PoDropdownModule, PoDynamicContainerComponent, PoDynamicFieldType, PoDynamicFormComponent, PoDynamicModule, PoDynamicSharedBase, PoDynamicViewComponent, PoEmailComponent, PoFieldContainerBottomComponent, PoFieldContainerComponent, PoFieldContainerModule, PoFieldModule, PoGaugeComponent, PoGaugeModule, PoGridComponent, PoGridModule, PoGuardsModule, PoHttpInterceptorModule, PoHttpInterceptorService, PoHttpRequestInterceptorService, PoHttpRequestModule, PoI18nModule, PoI18nPipe, PoI18nService, PoIconComponent, PoIconDictionary, PoIconModule, PoImageComponent, PoImageModule, PoInfoComponent, PoInfoModule, PoInfoOrientation, PoInputComponent, PoInterceptorsModule, PoItemListComponent, PoLabelComponent, PoLabelModule, PoLanguageModule, PoLanguageService, PoLinkComponent, PoLinkModule, PoListBoxComponent, PoListBoxModule, PoListViewComponent, PoListViewContentTemplateDirective, PoListViewDetailTemplateDirective, PoListViewModule, PoLoadingComponent, PoLoadingIconComponent, PoLoadingModule, PoLoadingOverlayComponent, PoLoginComponent, PoLogoComponent, PoLogoModule, PoLookupComponent, PoLookupModalComponent, PoMask, PoMediaQueryModule, PoMediaQueryService, PoMenuComponent, PoMenuGlobalService, PoMenuHeaderTemplateDirective, PoMenuModule, PoMenuPanelComponent, PoMenuPanelModule, PoModalComponent, PoModalFooterComponent, PoModalModule, PoModule, PoMultiselectComponent, PoMultiselectFilterMode, PoMultiselectOptionTemplateDirective, PoNavbarComponent, PoNavbarModule, PoNotificationModule, PoNotificationService, PoNumberComponent, PoOverlayComponent, PoOverlayModule, PoPageDefaultComponent, PoPageDetailComponent, PoPageEditComponent, PoPageListComponent, PoPageModule, PoPageSlideComponent, PoPageSlideFooterComponent, PoPageSlideModule, PoPasswordComponent, PoPipesModule, PoPopoverComponent, PoPopoverModule, PoPopupComponent, PoPopupModule, PoProgressComponent, PoProgressModule, PoProgressSize, PoProgressStatus, PoRadioComponent, PoRadioGroupComponent, PoRadioGroupModule, PoRadioModule, PoRichTextComponent, PoRichTextToolbarActions, PoSearchComponent, PoSearchFilterMode, PoSearchListComponent, PoSearchModule, PoSelectComponent, PoServicesModule, PoSlideComponent, PoSlideContentTemplateDirective, PoSlideModule, PoStepComponent, PoStepperComponent, PoStepperModule, PoStepperOrientation, PoStepperStatus, PoSwitchComponent, PoSwitchLabelPosition, PoSwitchModule, PoTabComponent, PoTableCellTemplateDirective, PoTableColumnFrozenDirective, PoTableColumnSortType, PoTableColumnSpacing, PoTableColumnTemplateDirective, PoTableComponent, PoTableModule, PoTableRowTemplateArrowDirection, PoTableRowTemplateDirective, PoTabsComponent, PoTabsModule, PoTabsService, PoTagComponent, PoTagModule, PoTagOrientation, PoTagType, PoTextareaComponent, PoThemeA11yEnum, PoThemeModule, PoThemeService, PoThemeTypeEnum, PoTimeModule, PoTimePipe, PoToasterComponent, PoToasterMode, PoToasterModule, PoToasterOrientation, PoToasterType, PoToolbarComponent, PoToolbarModule, PoTooltipDirective, PoTooltipModule, PoTreeViewComponent, PoTreeViewModule, PoUploadComponent, PoUploadFile, PoUploadStatus, PoUrlComponent, PoWidgetComponent, PoWidgetModule, initializeLanguageDefault, poBreadcrumbLiterals, poDialogAlertLiteralsDefault, poDialogConfirmLiteralsDefault, poLanguageDefault, poLocaleDateSeparatorList, poLocaleDecimalSeparatorList, poLocaleDefault, poLocaleThousandSeparatorList, poLocales, poPageSlideLiteralsDefault, poTabsLiterals, poThemeDefault, poThemeDefaultAA, poThemeDefaultAAA, poThemeDefaultActions, poThemeDefaultActionsDark, poThemeDefaultBrands, poThemeDefaultBrandsDark, poThemeDefaultDark, poThemeDefaultDarkValues, poThemeDefaultFeedback, poThemeDefaultFeedbackDark, poThemeDefaultLight, poThemeDefaultLightValues, poThemeDefaultNeutrals, poThemeDefaultNeutralsDark, poToasterLiterals, returnPoI18nService };
|
|
62703
62623
|
//# sourceMappingURL=po-ui-ng-components.mjs.map
|