blob: 5f56968dd080f6588ef84c084c8b58003781758c [file] [log] [blame]
import i18n from '@/i18n';
export const expandRowLabel = i18n.global.t('global.table.expandTableRow');
const TableRowExpandMixin = {
methods: {
toggleRowDetails(row) {
row.toggleDetails();
// When details are shown, label should instruct to collapse; otherwise, expand
this.expandRowLabel = row.detailsShowing
? i18n.global.t('global.table.collapseTableRow')
: i18n.global.t('global.table.expandTableRow');
},
},
};
export default TableRowExpandMixin;