Skip to content

More Custom Labels for datatable #1704

Description

@oskarkris

Not all displayed text is translateable through custom labels.
In file datatable.js, could these be added?

CustomLabels:

ers_selectedSuffix messages en_US false x • x selected suffix selected ers_of messages en_US false of of

imports:

import SelectedSuffix from '@salesforce/label/c.ers_selectedSuffix';
import Of from '@salesforce/label/c.ers_of';

Labels:
label = {
SelectedSuffix,
Of
};

Getters:

get selectedSuffixLabel() {
return this.label.SelectedSuffix;
}

get ofLabel() {
    return this.label.Of
}

get formattedTableLabel() {
let filteredCount = (this.filteredRecordCount != this.tableRecordCount) ? ${this.filteredRecordCount} ${this.ofLabel} : '';
let selectedCount = (this.showSelectedCount) ? • ${this.numberOfRowsSelected} ${this.selectedSuffixLabel} : '';
return (this.showRecordCount) ? ${this._tableLabel} (${filteredCount}${this.tableRecordCount}${selectedCount}) : this._tableLabel;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions