Custom channel emoticons WIP (#130): fix CSS

This commit is contained in:
John Livingston
2024-06-07 14:08:35 +02:00
parent f1cf98921f
commit 92cf83dcdf
5 changed files with 16 additions and 7 deletions

View File

@ -70,6 +70,7 @@ interface CellDataSchema {
separators?: string[]
inputType?: DynamicTableAcceptedInputTypes
default?: DynamicTableAcceptedTypes
colClassList?: string[] // CSS classes to add to the <td> element.
}
interface DynamicTableRowData {
@ -460,7 +461,11 @@ export class DynamicTableFormElement extends LivechatElement {
`with field type '${propertySchema.inputType as string}' for form entry '${propertyName.toString()}'.`)
}
return html`<td class="form-group">${formElement}</td>`
const classList = ['form-group']
if (propertySchema.colClassList) {
classList.push(...propertySchema.colClassList)
}
return html`<td class=${classList.join(' ')}>${formElement}</td>`
}
_renderInput = (rowId: number,