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 component = getContext("component")
|
||||||
const context = getContext("context")
|
const context = getContext("context")
|
||||||
const { styleable, getAction, ActionTypes, rowSelectionStore } =
|
const {
|
||||||
getContext("sdk")
|
styleable,
|
||||||
|
getAction,
|
||||||
|
ActionTypes,
|
||||||
|
rowSelectionStore,
|
||||||
|
generateGoldenSample,
|
||||||
|
} = getContext("sdk")
|
||||||
|
|
||||||
const customColumnKey = `custom-${Math.random()}`
|
const customColumnKey = `custom-${Math.random()}`
|
||||||
const customRenderers = [
|
const customRenderers = [
|
||||||
{
|
{
|
||||||
|
@ -63,6 +69,16 @@
|
||||||
selectedRows,
|
selectedRows,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Provide additional data context for live binding eval
|
||||||
|
export const getAdditionalDataContext = () => {
|
||||||
|
const goldenRow = generateGoldenSample(data)
|
||||||
|
return {
|
||||||
|
eventContext: {
|
||||||
|
row: goldenRow,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const getFields = (
|
const getFields = (
|
||||||
schema,
|
schema,
|
||||||
customColumns,
|
customColumns,
|
||||||
|
|
Loading…
Reference in New Issue