Merge pull request #4588 from chz/fix/4558
Fix #4558 - locale "selectedItemsLabel" is broken on MultiSelectpull/4649/head
commit
dfb6c1081a
|
@ -9,4 +9,5 @@ coverage
|
||||||
dist
|
dist
|
||||||
.DS_Store
|
.DS_Store
|
||||||
.vscode
|
.vscode
|
||||||
|
.idea
|
||||||
.eslintcache
|
.eslintcache
|
||||||
|
|
|
@ -770,12 +770,11 @@ export default {
|
||||||
},
|
},
|
||||||
getSelectedItemsLabel() {
|
getSelectedItemsLabel() {
|
||||||
let pattern = /{(.*?)}/;
|
let pattern = /{(.*?)}/;
|
||||||
|
const selectedItemsLabel = this.$primevue.config.locale.selectionMessage || this.selectedItemsLabel
|
||||||
if (pattern.test(this.selectedItemsLabel)) {
|
if (pattern.test(selectedItemsLabel)) {
|
||||||
return this.selectedItemsLabel.replace(this.selectedItemsLabel.match(pattern)[0], this.modelValue.length + '');
|
return selectedItemsLabel.replace(selectedItemsLabel.match(pattern)[0], this.modelValue.length + '');
|
||||||
}
|
}
|
||||||
|
return selectedItemsLabel;
|
||||||
return this.selectedItemsLabel;
|
|
||||||
},
|
},
|
||||||
onToggleAll(event) {
|
onToggleAll(event) {
|
||||||
if (this.selectAll !== null) {
|
if (this.selectAll !== null) {
|
||||||
|
|
Loading…
Reference in New Issue