Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions frontend/src/views/chat/component/charts/Table.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,28 @@ export class Table extends BaseChart {
operation: {
sort: true,
},
dataCell: {
enable: true,
content: (cell) => {
const meta = cell.getMeta()
const container = document.createElement('div')
container.style.padding = '8px 0'
container.style.minWidth = '100px'
container.style.maxWidth = '400px'
container.style.display = 'flex'
container.style.alignItems = 'center'
container.style.padding = '8px 16px'
container.style.cursor = 'pointer'
container.style.color = '#606266'
container.style.fontSize = '14px'
container.style.whiteSpace = 'pre-wrap'

const text = document.createTextNode(meta.fieldValue)
container.appendChild(text)

return container
},
},
},
// 如果有省略号, 复制到的是完整文本
interaction: {
Expand Down