Cleanup and fixes for resource viewer and filter plugin (#12154)

* Cleanup and fixes for resource viewer and filter plugin

* fix strict nulls
This commit is contained in:
Charles Gagnon
2020-09-04 19:10:26 -07:00
committed by GitHub
parent fa5bfee0cf
commit b8d0e2a9e3
10 changed files with 191 additions and 134 deletions

View File

@@ -68,6 +68,10 @@ export function textFormatter(row: number | undefined, cell: any | undefined, va
return `<span title="${titleValue}" class="${cellClasses}">${valueToDisplay}</span>`;
}
export function imageFormatter(row: number | undefined, cell: any | undefined, value: any, columnDef: any | undefined, dataContext: any | undefined): string {
return `<img src="${value.text}" />`;
}
/**
* Provide slick grid cell with encoded ariaLabel and plain text.
* text will be escaped by the textFormatter and ariaLabel will be consumed by slickgrid directly.