Provide live eval context from legacy table components
This commit is contained in:
parent
53cd48e866
commit
a64738fa25
|
@ -17,8 +17,14 @@
|
|||
|
||||
const component = getContext("component")
|
||||
const context = getContext("context")
|
||||
const { styleable, getAction, ActionTypes, rowSelectionStore } =
|
||||
getContext("sdk")
|
||||
const {
|
||||
styleable,
|
||||
getAction,
|
||||
ActionTypes,
|
||||
rowSelectionStore,
|
||||
generateGoldenSample,
|
||||
} = getContext("sdk")
|
||||
|
||||
const customColumnKey = `custom-${Math.random()}`
|
||||
const customRenderers = [
|
||||
{
|
||||
|
@ -63,6 +69,16 @@
|
|||
selectedRows,
|
||||
}
|
||||
|
||||
// Provide additional data context for live binding eval
|
||||
export const getAdditionalDataContext = () => {
|
||||
const goldenRow = generateGoldenSample(data)
|
||||
return {
|
||||
eventContext: {
|
||||
row: goldenRow,
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
const getFields = (
|
||||
schema,
|
||||
customColumns,
|
||||
|
|
Loading…
Reference in New Issue