Added forceLTR attribute on a column in ha-data-table (#6363)

This commit is contained in:
Yosi Levy 2020-07-11 19:11:13 +03:00 committed by GitHub
parent 7d1835e59c
commit b2a78fd063
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 0 deletions

View File

@ -69,6 +69,7 @@ export interface DataTableColumnData extends DataTableSortColumnData {
width?: string;
maxWidth?: string;
grows?: boolean;
forceLTR?: boolean;
}
export interface DataTableRowData {
@ -352,6 +353,7 @@ export class HaDataTable extends LitElement {
column.type === "icon-button"
),
grows: Boolean(column.grows),
forceLTR: Boolean(column.forceLTR),
})}"
style=${column.width
? styleMap({
@ -855,6 +857,9 @@ export class HaDataTable extends LitElement {
flex-grow: 1;
flex-shrink: 1;
}
.forceLTR {
direction: ltr;
}
`;
}
}

View File

@ -65,6 +65,7 @@ export class HaConfigLovelaceRescources extends LitElement {
filterable: true,
direction: "asc",
grows: true,
forceLTR: true,
},
type: {
title: this.hass.localize(