@pega/lists-core 9.0.0-build.14.6 → 9.0.0-build.14.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"RowGenerator.d.ts","sourceRoot":"","sources":["../../../../src/core/generators/RowGenerator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sDAAsD,CAAC;AAKtF,OAAO,KAAK,UAAU,MAAM,eAAe,CAAC;AAK5C,OAAO,KAAK,IAAI,MAAM,iBAAiB,CAAC;AACxC,OAAO,EACL,OAAO,EACP,KAAK,SAAS,EACd,KAAK,SAAS,EACd,KAAK,UAAU,EACf,KAAK,OAAO,EACZ,KAAK,SAAS,EACd,KAAK,UAAU,EACf,KAAK,OAAO,EACb,MAAM,sBAAsB,CAAC;AAE9B,0EAA0E;AAC1E,MAAM,CAAC,OAAO,OAAO,GAAG;;IACtB,sHAAsH;IAC/G,GAAG,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IACb;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB,+CAA+C;IACxC,SAAS,CAAC,EAAE,SAAS,CAAC;IAC7B,+CAA+C;IACxC,SAAS,CAAC,EAAE,SAAS,CAAC;IAC7B,oCAAoC;IACpC,OAAO,EAAE,OAAO,CAAC;IACjB,sIAAsI;IACtI,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAGzB;;;;;;;;;;;OAWG;gBAED,EAAE,GAAG,EAAE,IAAY,EAAE,QAAY,EAAE,SAAS,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,UAAU,EACxF,UAAU,EAAE,UAAU;IAwBxB,0CAA0C;IAC1C,IAAI,MAAM,SAET;IAmBD;;;;OAIG;IACH,IAAI,QAAQ,WAEX;IAED,4BAA4B;IAC5B,IAAI,IAAI,YAEP;IAED;yFACqF;IACrF,I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166
  const { dispatch } = getRsStateResolver();
167
167
  const state = getRsStateResolver().getState();
168
168
  // TODO: Check if fetchRowData api is really needed? In case of grouped tables updating single row may cause issues. It is better to refresh whole view.
169
- const [rowData] = (await rsProps.apiContext.fetchRowData?.(deepCopy(state), getView().meta, getView().meta.itemKey, this[dataKey], {
169
+ const [rowData] = (await rsProps.apiContext.fetchRowData?.(deepCopy(state), getView().meta, getView().meta.itemKey, this[dataKey], this.data, {
170
170
  ...(getRsStore().refreshInProgress && {
171
171
  invalidateCache: true,
172
172
  invalidateCacheToken: getRsStore().refreshToken
@@ -1 +1 @@
1
- {"version":3,"file":"RowGenerator.js","sourceRoot":"","sources":["../../../../src/core/generators/RowGenerator.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,QAAQ,EAAE,wBAAwB,EAAE,MAAM,eAAe,CAAC;AACnF,OAAO,EAAE,iBAAiB,EAAE,wBAAwB,EAAE,MAAM,oBAAoB,CAAC;AAOjF,OAAO,EACL,OAAO,EAQR,MAAM,sBAAsB,CAAC;AAE9B,0EAA0E;AAC1E,MAAM,CAAC,OAAO,OAAO,GAAG;IACtB,sHAAsH;IAC/G,GAAG,CAAS;IACnB;;OAEG;IACH,IAAI,CAAS;IACb;;OAEG;IACH,QAAQ,CAAS;IACjB,+CAA+C;IACxC,SAAS,CAAa;IAC7B,+CAA+C;IACxC,SAAS,CAAa;IAC7B,oCAAoC;IACpC,OAAO,CAAU;IACjB,sIAAsI;IACtI,QAAQ,CAAiB;IACzB,gDAAgD;IAChD,WAAW,CAAa;IACxB;;;;;;;;;;;OAWG;IACH,YACE,EAAE,GAAG,EAAE,IAAI,GAAG,KAAK,EAAE,QAAQ,GAAG,CAAC,EAAE,SAAS,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAc,EACxF,UAAsB;QAEtB,IAAI,CAAC,GAAG,GAAG,GAAG,CAAC;QAC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AAI,CAAC,MAAM,CAAC,UAAU;YACxC,mBAAmB,EAAE,CAAC,UAAmB,EAAE,EAAE;gBAC3C,OAAO,CACL,OAAO,CAAC,UAAU,CAAC,qBAAqB,EAAE,CACxC,UAAU,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC,OAAO,CAAW,EAC5C,UAAU,CACX,IAAI,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,CACzB,CAAC;YACJ,CAAC;YACD,YAAY,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,SAAS;YAClC,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,UAAU,EAAE,IAAI,CAAC,SAAS;YAC1B,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,YAAY,EAAE,IAAI,CAAC,YAAY;SAChC,CAAC;IACJ,CAAC;CACF","sourcesContent":["import type { DataError } from 'pega-repeating-structures-core/lib/types/State.types';\n\nimport { STATE, SELECTION_MODES } from '../constants';\nimport { compareObjects, deepCopy, isRowReorderFieldEnabled } from '../utils/util';\nimport { actionForceUpdate, actionRowSelectionUpdate } from '../actions/actions';\nimport type RsInternal from '../RsInternal';\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport type { Meta } from '../../../types/Meta.types';\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport type View from './ViewGenerator';\nimport {\n dataKey,\n type DragProps,\n type DropProps,\n type RowContext,\n type RowData,\n type RowHeader,\n type RowOptions,\n type UIProps\n} from './RowGenerator.types';\nimport type Column from './ColumnGenerator';\n/** A row model that represents row of a repeating structure component. */\nexport default class Row {\n /** A unique key to identify a row object. The value of this must be derived from one of the key of {@link rowData} */\n public key: string;\n /** Value for Html attribute 'role'.\n * @default 'row'\n */\n role: string;\n /** Value of Html attribute 'tabindex'.\n * @default 0\n */\n tabIndex: number;\n /** Properties related to dragging behavior. */\n public dragProps?: DragProps;\n /** Properties related to dropping behavior. */\n public dropProps?: DropProps;\n /** Represents the data of a row. */\n rowData: RowData;\n /** A unique key to identify a row object in case {@link key} is duplicate. This can be used in the dom to uniquely identify a row. */\n uniqueId?: string | null;\n /** A reference to {@link RsInternal} object. */\n #rsInternal: RsInternal;\n /**\n * Creates an instance of Row object for a repeating structure.\n * @param args Constructor arguments\n * @param args.key A unique key to identify a row object.\n * @param args.role Value for Html attribute 'role'. Default is 'row'\n * @param args.tabIndex Value of Html attribute 'tabindex'. Default is 0.\n * @param args.dragProps Properties related to dragging behavior.\n * @param args.dropProps Properties related to dropping behavior.\n * @param args.rowData Represents the data of a row.\n * @param args.uniqueId A unique key to identify a row object in case {@link key} is duplicate.\n * @param rsInternal A reference to {@link RsInternal} object.\n */\n constructor(\n { key, role = 'row', tabIndex = 0, dragProps, dropProps, rowData, uniqueId }: RowOptions,\n rsInternal: RsInternal\n ) {\n this.key = key;\n this.role = role;\n this.tabIndex = tabIndex;\n this.dragProps = dragProps;\n this.dropProps = dropProps;\n this.rowData = rowData;\n this.uniqueId = uniqueId;\n this.#rsInternal = rsInternal;\n\n /** IMP: For generator methods use traditional function syntax\n * rather than arrow function for memory efficiency\n * and bind 'this' to the methods which requires 'this' context. */\n this.getUIProps = this.getUIProps.bind(this);\n this.getContext = this.getContext.bind(this);\n this.updateRow = this.updateRow.bind(this);\n this.selectRow = this.selectRow.bind(this);\n\n this.setProp = this.setProp.bind(this);\n this.getRowError = this.getRowError.bind(this);\n this.getRowHeader = this.getRowHeader.bind(this);\n }\n\n /** A reference to {@link View} object. */\n get parent() {\n return this.#rsInternal.getView();\n }\n\n /**\n * This is majorly used by {@link setprop} function to create a new row object from existing row object.\n * @returns the row instance properties.\n */\n #get(): RowOptions & { className: string } {\n return {\n key: this.key,\n role: this.role,\n tabIndex: this.tabIndex,\n className: this.className,\n dragProps: this.dragProps,\n dropProps: this.dropProps,\n rowData: this.rowData,\n uniqueId: this.uniqueId\n };\n }\n\n /**\n * This property serves to uniquely identify a row's DOM element within a DOM hierarchy.\n * It plays a vital role in modern JavaScript frameworks such as React, where optimizing DOM manipulation requires unique keys.\n * The value is derived from either {@link key} or {@link uniqueId} if {@link key} is duplicate.\n */\n get reactKey() {\n return this.uniqueId || this.key;\n }\n\n /** The data for the row. */\n get data() {\n return this.rowData;\n }\n\n /** Value of HTMl attribute data-key. The value is derived from\n * either the value of {@link Meta.itemKey itemkey} in {@link data} or {@link key} */\n get [dataKey](): string {\n const keyData = this.data?.[this.parent.meta.itemKey];\n if (keyData) return keyData as string;\n return this.key;\n }\n\n /** A set of CSS class names for Row element. */\n get className() {\n const baseRowClass = this.getRowError()?.message ? 'row row-error' : 'row';\n if (this.parent.meta.selectionMode === SELECTION_MODES.multi_on_hover)\n return this.$selected ? `${baseRowClass} selected-row` : `${baseRowClass} row-on-hover`;\n\n return this.parent.onRowClickAction ? `${baseRowClass} click` : `${baseRowClass}`;\n }\n\n /** A transient value to signifies if a row is selected or not if selection mode is on. */\n get $selected(): RowContext['$selected'] {\n const temporaryChangeSetValue = this.parent.state.rowSelectionChangeSet?.[this.key]?.selected;\n const committedValue = this.parent.state.selectedRows?.includes(this.key);\n if (\n (temporaryChangeSetValue ?? committedValue) &&\n this.parent.meta.selectionMode === SELECTION_MODES.single &&\n this.uniqueId\n ) {\n /**\n * temporaryChangeSetValue ?? committedValue - Is current row selected\n * this.parent.meta.selectionMode === SELECTION_MODES.single - Is single select mode\n * this.uniqueId - unique id is present only in case of duplicate rows\n */\n if (this.parent.getSingleSelectionRowKey()) {\n // This block is to avoid duplicate radio button selection on user selection\n return this.parent.getSingleSelectionRowKey() === this.uniqueId;\n }\n for (let i = 0; i < this.parent.rows!.length; i += 1) {\n // This block is to avoid duplicate radio button selection onload / remount\n const row = this.parent.rows![i];\n const rowTemporaryChangeSetValue =\n this.parent.state.rowSelectionChangeSet?.[row.key]?.selected;\n const rowCommittedValue =\n this.parent.state.selectedRows && this.parent.state.selectedRows?.includes(row.key);\n if (rowTemporaryChangeSetValue ?? rowCommittedValue) {\n // 'row' - first selected row in this.parent.rows\n return this.uniqueId === row.uniqueId; // If 'row' is same as current object return true otherwise return false\n }\n }\n }\n return temporaryChangeSetValue ?? committedValue;\n }\n\n /**\n * This is used to create immutable objects of {@link Row} instance. Always call setProp if updating any properties of Row to make it immutable.\n * @param prop Either partial of row object or individual properties of row object.\n * @param [value] An optional parameter to provide value for {@link prop} in case prop is not of type {@link Row}\n */\n setProp(\n prop: Partial<RowOptions> | keyof RowOptions,\n value?: string | number | Date | boolean | DragProps | DropProps\n ) {\n const { getView } = this.#rsInternal;\n const index = getView().rows!.findIndex(r => r === this);\n let pObject = prop;\n if (typeof prop !== 'object') {\n pObject = { [prop]: value };\n }\n\n // Change object if any value changes actually.\n // @ts-expect-error utils should be converted to TS in order to resolve this.\n if (!compareObjects(this, pObject, Object.keys(pObject))) {\n const newRow = new Row(\n {\n ...this.#get(),\n ...(pObject as RowOptions)\n },\n this.#rsInternal\n );\n const cloned = [...getView().rows!];\n cloned.splice(index, 1, newRow);\n getView().rows = cloned;\n }\n }\n\n /** This fetches the latest data of the row using\n * {@link rsProps.apiContext.fetchRowData fetchRowData} and updates the same in the {@link View} and {@link Row}\n * @returns void\n */\n async updateRow(): Promise<void> {\n const { getView, getRsProps, getRsStateResolver, getRsStore } = this.#rsInternal;\n const rsProps = getRsProps();\n const { dispatch } = getRsStateResolver();\n const state = getRsStateResolver().getState();\n // TODO: Check if fetchRowData api is really needed? In case of grouped tables updating single row may cause issues. It is better to refresh whole view.\n const [rowData] =\n (await rsProps.apiContext.fetchRowData?.(\n deepCopy(state),\n getView().meta,\n getView().meta.itemKey,\n this[dataKey],\n {\n ...(getRsStore().refreshInProgress && {\n invalidateCache: true,\n invalidateCacheToken: getRsStore().refreshToken\n })\n }\n )) || [];\n const dataIndex = getView().data!.findIndex(\n row => row[getView().meta.itemKey] === rowData[getView().meta.itemKey]\n );\n const rowIndex = getView().rows!.findIndex(row => row.key === rowData[getView().meta.itemKey]);\n if (dataIndex > -1) {\n getView().setProp({\n data: [\n ...getView().data!.slice(0, dataIndex),\n rowData,\n ...getView().data!.slice(dataIndex + 1)\n ],\n rows: [\n ...getView().rows!.slice(0, rowIndex),\n new Row(\n {\n key: rowData[getView().meta.itemKey] as string,\n rowData\n },\n this.#rsInternal\n ),\n ...getView().rows!.slice(rowIndex + 1)\n ]\n });\n dispatch(actionForceUpdate());\n }\n }\n\n /**\n * Used to select/deselect a {@link Row}.\n * @param selected Flag to indicate the row is selected or not.\n */\n selectRow(selected = true): void {\n const { getRsStateResolver } = this.#rsInternal;\n const { dispatch } = getRsStateResolver();\n this.parent.setSingleSelectionRowKey(this.uniqueId ?? (this.key as string));\n\n dispatch(\n actionRowSelectionUpdate({\n key: this.key as string,\n selected,\n data: this.data,\n status: STATE.NOT_STARTED,\n mode: this.parent.meta.selectionMode\n })\n );\n }\n\n /**\n * Returns the ui props for the {@link Row} that can be used to build a row in DOM.\n *\n */\n getUIProps(): UIProps {\n const { getView } = this.#rsInternal;\n return {\n className: this.className,\n 'data-error-message': this.getRowError()?.message,\n [dataKey]: this[dataKey],\n role: this.role,\n 'aria-rowindex':\n // eslint-disable-next-line no-unsafe-optional-chaining\n this.parent.state.paginationOptions?.rootVirtualiser?.startIndex! +\n this.parent.rows!.findIndex(r => r === this)! +\n 1,\n onClick: getView().onRowClickAction?.bind(this, this.data),\n ...(!isRowReorderFieldEnabled(getView().meta) ? this.dragProps : {}),\n ...this.dropProps\n };\n }\n\n /**\n *\n * @returns the errors on the row.\n */\n getRowError(): DataError[string | number] | undefined {\n return this.parent.state.errors?.dataErrors?.[this.key as string | number];\n }\n\n /**\n * Returns the current row Header field and value.\n * This api is exposed to the consumers of Repeating structures to access the row header information of the current row.\n *\n * @public\n */\n getRowHeader(): RowHeader | undefined {\n let rowHeaderColumn: Column | undefined;\n const columns = this.parent.getContext().getColumns();\n for (const column of columns!) {\n if (column.field.isRowHeader) {\n rowHeaderColumn = column;\n break;\n }\n if (column.isFirstDataColumn) {\n rowHeaderColumn = column;\n }\n }\n if (!rowHeaderColumn) {\n return undefined;\n }\n return {\n field: rowHeaderColumn as Column,\n getValue: () => rowHeaderColumn!.getContext().getValue()\n };\n }\n\n /**\n * Returns the current row context.\n * This api can be exposed to the consumers of Repeating structures to access the basic info regarding Row.\n *\n * @public\n */\n getContext(): RowContext {\n const { getRsProps, getView } = this.#rsInternal;\n const rsProps = getRsProps();\n return {\n name: 'row',\n getValue: () => this.data,\n getParentContext: this.parent.getContext,\n getRowActionDetails: (rowContext: RowData) => {\n return (\n rsProps.apiContext.fetchRowActionDetails?.(\n rowContext[getView().meta.itemKey] as string,\n rowContext\n ) ?? Promise.resolve([])\n );\n },\n getDragProps: () => this.dragProps,\n selectRow: this.selectRow,\n refreshRow: this.updateRow,\n $selected: this.$selected,\n getRowError: this.getRowError,\n getRowHeader: this.getRowHeader\n };\n }\n}\n"]}
1
+ {"version":3,"file":"RowGenerator.js","sourceRoot":"","sources":["../../../../src/core/generators/RowGenerator.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,QAAQ,EAAE,wBAAwB,EAAE,MAAM,eAAe,CAAC;AACnF,OAAO,EAAE,iBAAiB,EAAE,wBAAwB,EAAE,MAAM,oBAAoB,CAAC;AAOjF,OAAO,EACL,OAAO,EAQR,MAAM,sBAAsB,CAAC;AAE9B,0EAA0E;AAC1E,MAAM,CAAC,OAAO,OAAO,GAAG;IACtB,sHAAsH;IAC/G,GAAG,CAAS;IACnB;;OAEG;IACH,IAAI,CAAS;IACb;;OAEG;IACH,QAAQ,CAAS;IACjB,+CAA+C;IACxC,SAAS,CAAa;IAC7B,+CAA+C;IACxC,SAAS,CAAa;IAC7B,oCAAoC;IACpC,OAAO,CAAU;IACjB,sIAAsI;IACtI,QAAQ,CAAiB;IACzB,gDAAgD;IAChD,WAAW,CAAa;IACxB;;;;;;;;;;;OAWG;IACH,YACE,EAAE,GAAG,EAAE,IAAI,GAAG,KAAK,E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,CAAC;QACjD,MAAM,OAAO,GAAG,UAAU,EAAE,CAAC;QAC7B,OAAO;YACL,IAAI,EAAE,KAAK;YACX,QAAQ,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,IAAI;YACzB,gBAAgB,EAAE,IAAI,CAAC,MAAM,CAAC,UAAU;YACxC,mBAAmB,EAAE,CAAC,UAAmB,EAAE,EAAE;gBAC3C,OAAO,CACL,OAAO,CAAC,UAAU,CAAC,qBAAqB,EAAE,CACxC,UAAU,CAAC,OAAO,EAAE,CAAC,IAAI,CAAC,OAAO,CAAW,EAC5C,UAAU,CACX,IAAI,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,CACzB,CAAC;YACJ,CAAC;YACD,YAAY,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,SAAS;YAClC,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,UAAU,EAAE,IAAI,CAAC,SAAS;YAC1B,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,YAAY,EAAE,IAAI,CAAC,YAAY;SAChC,CAAC;IACJ,CAAC;CACF","sourcesContent":["import type { DataError } from 'pega-repeating-structures-core/lib/types/State.types';\n\nimport { STATE, SELECTION_MODES } from '../constants';\nimport { compareObjects, deepCopy, isRowReorderFieldEnabled } from '../utils/util';\nimport { actionForceUpdate, actionRowSelectionUpdate } from '../actions/actions';\nimport type RsInternal from '../RsInternal';\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport type { Meta } from '../../../types/Meta.types';\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport type View from './ViewGenerator';\nimport {\n dataKey,\n type DragProps,\n type DropProps,\n type RowContext,\n type RowData,\n type RowHeader,\n type RowOptions,\n type UIProps\n} from './RowGenerator.types';\nimport type Column from './ColumnGenerator';\n/** A row model that represents row of a repeating structure component. */\nexport default class Row {\n /** A unique key to identify a row object. The value of this must be derived from one of the key of {@link rowData} */\n public key: string;\n /** Value for Html attribute 'role'.\n * @default 'row'\n */\n role: string;\n /** Value of Html attribute 'tabindex'.\n * @default 0\n */\n tabIndex: number;\n /** Properties related to dragging behavior. */\n public dragProps?: DragProps;\n /** Properties related to dropping behavior. */\n public dropProps?: DropProps;\n /** Represents the data of a row. */\n rowData: RowData;\n /** A unique key to identify a row object in case {@link key} is duplicate. This can be used in the dom to uniquely identify a row. */\n uniqueId?: string | null;\n /** A reference to {@link RsInternal} object. */\n #rsInternal: RsInternal;\n /**\n * Creates an instance of Row object for a repeating structure.\n * @param args Constructor arguments\n * @param args.key A unique key to identify a row object.\n * @param args.role Value for Html attribute 'role'. Default is 'row'\n * @param args.tabIndex Value of Html attribute 'tabindex'. Default is 0.\n * @param args.dragProps Properties related to dragging behavior.\n * @param args.dropProps Properties related to dropping behavior.\n * @param args.rowData Represents the data of a row.\n * @param args.uniqueId A unique key to identify a row object in case {@link key} is duplicate.\n * @param rsInternal A reference to {@link RsInternal} object.\n */\n constructor(\n { key, role = 'row', tabIndex = 0, dragProps, dropProps, rowData, uniqueId }: RowOptions,\n rsInternal: RsInternal\n ) {\n this.key = key;\n this.role = role;\n this.tabIndex = tabIndex;\n this.dragProps = dragProps;\n this.dropProps = dropProps;\n this.rowData = rowData;\n this.uniqueId = uniqueId;\n this.#rsInternal = rsInternal;\n\n /** IMP: For generator methods use traditional function syntax\n * rather than arrow function for memory efficiency\n * and bind 'this' to the methods which requires 'this' context. */\n this.getUIProps = this.getUIProps.bind(this);\n this.getContext = this.getContext.bind(this);\n this.updateRow = this.updateRow.bind(this);\n this.selectRow = this.selectRow.bind(this);\n\n this.setProp = this.setProp.bind(this);\n this.getRowError = this.getRowError.bind(this);\n this.getRowHeader = this.getRowHeader.bind(this);\n }\n\n /** A reference to {@link View} object. */\n get parent() {\n return this.#rsInternal.getView();\n }\n\n /**\n * This is majorly used by {@link setprop} function to create a new row object from existing row object.\n * @returns the row instance properties.\n */\n #get(): RowOptions & { className: string } {\n return {\n key: this.key,\n role: this.role,\n tabIndex: this.tabIndex,\n className: this.className,\n dragProps: this.dragProps,\n dropProps: this.dropProps,\n rowData: this.rowData,\n uniqueId: this.uniqueId\n };\n }\n\n /**\n * This property serves to uniquely identify a row's DOM element within a DOM hierarchy.\n * It plays a vital role in modern JavaScript frameworks such as React, where optimizing DOM manipulation requires unique keys.\n * The value is derived from either {@link key} or {@link uniqueId} if {@link key} is duplicate.\n */\n get reactKey() {\n return this.uniqueId || this.key;\n }\n\n /** The data for the row. */\n get data() {\n return this.rowData;\n }\n\n /** Value of HTMl attribute data-key. The value is derived from\n * either the value of {@link Meta.itemKey itemkey} in {@link data} or {@link key} */\n get [dataKey](): string {\n const keyData = this.data?.[this.parent.meta.itemKey];\n if (keyData) return keyData as string;\n return this.key;\n }\n\n /** A set of CSS class names for Row element. */\n get className() {\n const baseRowClass = this.getRowError()?.message ? 'row row-error' : 'row';\n if (this.parent.meta.selectionMode === SELECTION_MODES.multi_on_hover)\n return this.$selected ? `${baseRowClass} selected-row` : `${baseRowClass} row-on-hover`;\n\n return this.parent.onRowClickAction ? `${baseRowClass} click` : `${baseRowClass}`;\n }\n\n /** A transient value to signifies if a row is selected or not if selection mode is on. */\n get $selected(): RowContext['$selected'] {\n const temporaryChangeSetValue = this.parent.state.rowSelectionChangeSet?.[this.key]?.selected;\n const committedValue = this.parent.state.selectedRows?.includes(this.key);\n if (\n (temporaryChangeSetValue ?? committedValue) &&\n this.parent.meta.selectionMode === SELECTION_MODES.single &&\n this.uniqueId\n ) {\n /**\n * temporaryChangeSetValue ?? committedValue - Is current row selected\n * this.parent.meta.selectionMode === SELECTION_MODES.single - Is single select mode\n * this.uniqueId - unique id is present only in case of duplicate rows\n */\n if (this.parent.getSingleSelectionRowKey()) {\n // This block is to avoid duplicate radio button selection on user selection\n return this.parent.getSingleSelectionRowKey() === this.uniqueId;\n }\n for (let i = 0; i < this.parent.rows!.length; i += 1) {\n // This block is to avoid duplicate radio button selection onload / remount\n const row = this.parent.rows![i];\n const rowTemporaryChangeSetValue =\n this.parent.state.rowSelectionChangeSet?.[row.key]?.selected;\n const rowCommittedValue =\n this.parent.state.selectedRows && this.parent.state.selectedRows?.includes(row.key);\n if (rowTemporaryChangeSetValue ?? rowCommittedValue) {\n // 'row' - first selected row in this.parent.rows\n return this.uniqueId === row.uniqueId; // If 'row' is same as current object return true otherwise return false\n }\n }\n }\n return temporaryChangeSetValue ?? committedValue;\n }\n\n /**\n * This is used to create immutable objects of {@link Row} instance. Always call setProp if updating any properties of Row to make it immutable.\n * @param prop Either partial of row object or individual properties of row object.\n * @param [value] An optional parameter to provide value for {@link prop} in case prop is not of type {@link Row}\n */\n setProp(\n prop: Partial<RowOptions> | keyof RowOptions,\n value?: string | number | Date | boolean | DragProps | DropProps\n ) {\n const { getView } = this.#rsInternal;\n const index = getView().rows!.findIndex(r => r === this);\n let pObject = prop;\n if (typeof prop !== 'object') {\n pObject = { [prop]: value };\n }\n\n // Change object if any value changes actually.\n // @ts-expect-error utils should be converted to TS in order to resolve this.\n if (!compareObjects(this, pObject, Object.keys(pObject))) {\n const newRow = new Row(\n {\n ...this.#get(),\n ...(pObject as RowOptions)\n },\n this.#rsInternal\n );\n const cloned = [...getView().rows!];\n cloned.splice(index, 1, newRow);\n getView().rows = cloned;\n }\n }\n\n /** This fetches the latest data of the row using\n * {@link rsProps.apiContext.fetchRowData fetchRowData} and updates the same in the {@link View} and {@link Row}\n * @returns void\n */\n async updateRow(): Promise<void> {\n const { getView, getRsProps, getRsStateResolver, getRsStore } = this.#rsInternal;\n const rsProps = getRsProps();\n const { dispatch } = getRsStateResolver();\n const state = getRsStateResolver().getState();\n // TODO: Check if fetchRowData api is really needed? In case of grouped tables updating single row may cause issues. It is better to refresh whole view.\n const [rowData] =\n (await rsProps.apiContext.fetchRowData?.(\n deepCopy(state),\n getView().meta,\n getView().meta.itemKey,\n this[dataKey],\n this.data,\n {\n ...(getRsStore().refreshInProgress && {\n invalidateCache: true,\n invalidateCacheToken: getRsStore().refreshToken\n })\n }\n )) || [];\n const dataIndex = getView().data!.findIndex(\n row => row[getView().meta.itemKey] === rowData[getView().meta.itemKey]\n );\n const rowIndex = getView().rows!.findIndex(row => row.key === rowData[getView().meta.itemKey]);\n if (dataIndex > -1) {\n getView().setProp({\n data: [\n ...getView().data!.slice(0, dataIndex),\n rowData,\n ...getView().data!.slice(dataIndex + 1)\n ],\n rows: [\n ...getView().rows!.slice(0, rowIndex),\n new Row(\n {\n key: rowData[getView().meta.itemKey] as string,\n rowData\n },\n this.#rsInternal\n ),\n ...getView().rows!.slice(rowIndex + 1)\n ]\n });\n dispatch(actionForceUpdate());\n }\n }\n\n /**\n * Used to select/deselect a {@link Row}.\n * @param selected Flag to indicate the row is selected or not.\n */\n selectRow(selected = true): void {\n const { getRsStateResolver } = this.#rsInternal;\n const { dispatch } = getRsStateResolver();\n this.parent.setSingleSelectionRowKey(this.uniqueId ?? (this.key as string));\n\n dispatch(\n actionRowSelectionUpdate({\n key: this.key as string,\n selected,\n data: this.data,\n status: STATE.NOT_STARTED,\n mode: this.parent.meta.selectionMode\n })\n );\n }\n\n /**\n * Returns the ui props for the {@link Row} that can be used to build a row in DOM.\n *\n */\n getUIProps(): UIProps {\n const { getView } = this.#rsInternal;\n return {\n className: this.className,\n 'data-error-message': this.getRowError()?.message,\n [dataKey]: this[dataKey],\n role: this.role,\n 'aria-rowindex':\n // eslint-disable-next-line no-unsafe-optional-chaining\n this.parent.state.paginationOptions?.rootVirtualiser?.startIndex! +\n this.parent.rows!.findIndex(r => r === this)! +\n 1,\n onClick: getView().onRowClickAction?.bind(this, this.data),\n ...(!isRowReorderFieldEnabled(getView().meta) ? this.dragProps : {}),\n ...this.dropProps\n };\n }\n\n /**\n *\n * @returns the errors on the row.\n */\n getRowError(): DataError[string | number] | undefined {\n return this.parent.state.errors?.dataErrors?.[this.key as string | number];\n }\n\n /**\n * Returns the current row Header field and value.\n * This api is exposed to the consumers of Repeating structures to access the row header information of the current row.\n *\n * @public\n */\n getRowHeader(): RowHeader | undefined {\n let rowHeaderColumn: Column | undefined;\n const columns = this.parent.getContext().getColumns();\n for (const column of columns!) {\n if (column.field.isRowHeader) {\n rowHeaderColumn = column;\n break;\n }\n if (column.isFirstDataColumn) {\n rowHeaderColumn = column;\n }\n }\n if (!rowHeaderColumn) {\n return undefined;\n }\n return {\n field: rowHeaderColumn as Column,\n getValue: () => rowHeaderColumn!.getContext().getValue()\n };\n }\n\n /**\n * Returns the current row context.\n * This api can be exposed to the consumers of Repeating structures to access the basic info regarding Row.\n *\n * @public\n */\n getContext(): RowContext {\n const { getRsProps, getView } = this.#rsInternal;\n const rsProps = getRsProps();\n return {\n name: 'row',\n getValue: () => this.data,\n getParentContext: this.parent.getContext,\n getRowActionDetails: (rowContext: RowData) => {\n return (\n rsProps.apiContext.fetchRowActionDetails?.(\n rowContext[getView().meta.itemKey] as string,\n rowContext\n ) ?? Promise.resolve([])\n );\n },\n getDragProps: () => this.dragProps,\n selectRow: this.selectRow,\n refreshRow: this.updateRow,\n $selected: this.$selected,\n getRowError: this.getRowError,\n getRowHeader: this.getRowHeader\n };\n }\n}\n"]}
@@ -268,9 +268,10 @@ export interface ApiContext {
268
268
  * @param {Meta} rsMeta - Repeating structures {@link Meta}.
269
269
  * @param {string} key - A unique identifier for a given row. This is equal to {@link Meta.itemKey 'itemKey'}
270
270
  * @param {string} value - The value for the given {@link Meta.itemKey 'itemKey'} for given row.
271
+ * @param {RowData} existingRowData - Existing row data for the given row.
271
272
  * @returns {Promise<RowData[]>} It should return a promise of type {@link RowData} array containing the data for a given row.Only 0th index is considered from the array.
272
273
  */
273
- fetchRowData?: (rsState: State, rsMeta: Meta, key: string, value: string, apiOptions: ApiOptions) => Promise<RowData[]>;
274
+ fetchRowData?: (rsState: State, rsMeta: Meta, key: string, value: string, existingRowData: RowData, apiOptions: ApiOptions) => Promise<RowData[]>;
274
275
  /**
275
276
  * This api is used to fetch the latest data for given set of rows identified uniquely by itemKey in {@link FieldDef}. This is passed as callback to all the {@link BulkAction.onClick bulk actions 'onClick'} method with {@link ApiContext.clearSelectedRows clearSelectedRows} api.
276
277
  * @requireWhen {@link Meta.allowBulkActions 'allowBulkActions'} is set to true.
@@ -1 +1 @@
1
- {"version":3,"file":"ApiContext.types.d.ts","sourceRoot":"","sources":["../../types/ApiContext.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,0DAA0D,CAAC;AACzG,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sCAAsC,CAAC;AAEtE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,2CAA2C,CAAC;AACzE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAC;AAElF,OAAO,KAAK,EACV,eAAe,EACf,mBAAmB,EACnB,iBAAiB,EACjB,KAAK,EACL,KAAK,EAIL,WAAW,EACX,oBAAoB,EAErB,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,EACV,IAAI,EACJ,SAAS,EACT,QAAQ,EAGT,MAAM,cAAc,CAAC;AAEtB;;GAEG;AACH,KAAK,cAAc,GAAG;IACpB;;OAEG;IACH,EAAE,EAAE,MAAM,GAAG,SAAS,CAAC;IAEvB;;OAEG;IACH,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IAEzB;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,KAAK,GAAG;IAClB;;;OAGG;IACH,WAAW,EAAE,gBAAgB,CAAC,cAAc,CAAC,CAAC;IAE9C;;;OAGG;IACH,cAAc,EAAE,gBAAgB,CAAC,gBAAgB,CAAC,CAAC;IAEnD;;;OAGG;IACH,cAAc,EAAE,gBAAgB,CAAC,gBAAgB,CAAC,CAAC;IAEnD;;;OAGG;IACH,iBAAiB,EAAE,MAAM,cAAc,GAAG,IAAI,CAAC;IAE/C;;;;;OAKG;IACH,gBAAgB,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,WAAW,CAAC,EAAE;QAAE,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U,KACjB,OAAO,CAAC,gCAAgC,CAAC,CAAC;CAChD"}
@@ -1 +1 @@
1
- {"version":3,"file":"ApiContext.types.js","sourceRoot":"","sources":["../../types/ApiContext.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ModalManagerContextValue } from '@pega/cosmos-react-core/lib/components/Modal/Modal.types';\nimport type { Condition } from '@pega/cosmos-react-condition-builder';\n\nimport type { RowData } from '../src/core/generators/RowGenerator.types';\nimport type { UtilityFunctions } from '../src/core/generators/viewUtilityMethods';\n\nimport type {\n Personalization,\n PersonalizationInfo,\n PersonalizedState,\n State,\n Group,\n /* eslint-disable @typescript-eslint/no-unused-vars */\n DateGroupAdditionalField,\n NumberGroupAdditionalField,\n GroupFilter,\n GroupAdditionalField\n /* eslint-enable @typescript-eslint/no-unused-vars */\n} from './State.types';\nimport type {\n Meta,\n RowAction,\n FieldDef,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n FieldType\n} from './Meta.types';\n\n/**\n * Represents information about the currently active view in the repeating structures.\n */\ntype ActiveViewInfo = {\n /**\n * The unique identifier of the active view.\n */\n id: string | undefined;\n\n /**\n * The name of the active view.\n */\n name: string | undefined;\n\n /**\n * Indicates whether the active view has unsaved changes.\n */\n isDirty: boolean;\n};\n\nexport type RsApi = {\n /**\n * Refreshes the current view.\n * @see {@link UtilityFunctions.refreshView}\n */\n refreshView: UtilityFunctions['forceRefresh'];\n\n /**\n * Sets the record count in the view.\n * @see {@link UtilityFunctions.setRecordCount}\n */\n setRecordCount: UtilityFunctions['setRecordCount'];\n\n /**\n * Dispatches an action to the repeating structures with an payload.\n * @see {@link UtilityFunctions.dispatchAction}\n */\n dispatchAction: UtilityFunctions['dispatchAction'];\n\n /**\n * Retrieves information about the currently active view.\n * @returns The {@link ActiveViewInfo active view information} or `void` if unavailable.\n */\n getActiveViewInfo: () => ActiveViewInfo | void;\n\n /**\n * Sets hidden columns of the view.\n * @param columns - An array of column IDs to hide.\n * @param ootbColumns - .\n * @param ootbColumns.dragHandle - Whether to hide the drag-and-drop column.\n */\n setHiddenColumns?: (columns: string[], ootbColumns?: { dragHandle: boolean }) => void;\n\n /**\n * Sets Column order of the view.\n * @param columns - An array of column IDs to reorder.\n */\n setColumnOrder?: (columns: string[]) => void;\n\n /**\n * Sets the filters of the view.\n * @param filter - The filter condition to apply.\n */\n setFilter: (filter: Condition) => void;\n\n /**\n * Sets the groups of the view.\n * @param groups - The grouping configuration.\n */\n setGrouping?: (groups: Group[]) => void;\n\n /**\n * Sets the sorting order of the view.\n * @param {NonNullable<State['sortingOrder']>} sorts - The sorting configuration.\n */\n setSorting: (sorts: NonNullable<State['sortingOrder']>) => void;\n\n /**\n * Sets the column aliases of the view.\n * @param aliases - The column alias configuration.\n */\n setAliases: (aliases: State['columnAlias']) => void;\n\n /**\n * Sets the aggregation information of the view.\n * @param {State['aggregationInfo']} agg - The aggregation configuration.\n */\n setAggregations: (agg: State['aggregationInfo']) => void;\n\n /**\n * Sets the visibility of the row reorder field.\n * @param {boolean} visibility - Whether the row reorder field should be visible.\n */\n setRowReorderFieldVisibility: (visibility: boolean) => void;\n\n /**\n * Updates the visibility of specific columns.\n * @param {Object} columns - A mapping of column IDs to their visibility state.\n */\n updateColumnsVisibility: (columns: { [key: FieldDef['id']]: boolean }) => void;\n\n /**\n * Sets the `renderFormatter` for the given column.\n * @param columnId - Column ID\n * @param formatterName - ID of the formatter/renderer\n */\n setRenderFormatter: (columnId: string, formatterName: string) => void;\n\n /**\n * Sets the conditional style formats of the view.\n * @param conditionalStyleFormats - The conditional style formats to apply.\n */\n setConditionalStyleFormats: (\n conditionalStyleFormats: NonNullable<State['conditionalStyleFormats']>\n ) => void;\n};\n\nexport interface ApiOptions {\n signal?: AbortSignal;\n /** Indicates current api triggered should invalidate the cache if any and reload the data. */\n invalidateCache?: boolean;\n /** A unique token or version identifier that changes whenever a refresh is triggered. Unlike a boolean `invalidateCache` flag, the `invalidateCacheToken` ensures that multiple APIs triggered\n in the same refresh cycle receive the same identifier. */\n invalidateCacheToken?: number;\n}\n// Aggregation response type\ntype AggregationTypeResp = 'avg' | 'max' | 'min' | 'nonNullCount' | 'sum' | 'distinctCount';\n/** An object with key equal to {@link AggregationTypeResp aggregation type} and value is equal to the actual value of that aggregation type */\ntype AggregationOptions = {\n [agg in AggregationTypeResp]?: number | null;\n};\n/** An object where key is equal to the column id (i.e. {@link FieldDef.id id} in FieldDef) and value is equal to its {@link AggregationOptions Aggregation values} */\nexport type AggregationResp = {\n [columnId: string]: AggregationOptions;\n};\n\nexport type AdditionalFieldData = {\n /** {@link FieldDef.id Field Id} of the additional field. */\n id: string;\n /** Value of the additional field that should be displayed for additional field.\n * The value can represent:\n * - An aggregated value (e.g., sum, max, min, avg) for {@link FieldType.NUMBER number} type fields when\n * {@link NumberGroupAdditionalField.aggregation aggregation} is selected in additional fields meta.\n * - A date function value (e.g., Day, Month, Year) for {@link FieldType.DATE 'date'} / {@link FieldType.DATE_TIME 'datetime'}\n * fields when a {@link DateGroupAdditionalField.dateFunction date function} is selected in the additional fields metadata..\n * - A scalar or single value for the additional field.\n */\n value: null | string | number | boolean | Date;\n /** Represents the distinct count of\n * occurrences for the additional field data. This is generally required,\n * but may be omitted if {@link NumberGroupAdditionalField.aggregation aggregation} is selected for number type fields\n * in the additional fields metadata. */\n count?: number;\n};\n\n// Grouping response type\nexport interface GroupedInfo {\n /** Value for the current group node. */\n name: null | string | number | boolean | Date; // Value for the current node\n /** # of data rows in this node */\n count: number;\n /** An optional data row from the group node that is used to process extra information required by group node */\n data?: RowData;\n /** Additional fields data for the current group node */\n additionalFieldsData?: AdditionalFieldData[];\n /** Aggregation values of a column if applied */\n agg?: AggregationResp;\n /** Nested groups within the parent group node */\n children?: GroupedInfo[];\n}\n\nexport interface HierarchicalGroupedInfo extends Pick<GroupedInfo, 'count' | 'agg'> {\n info: RowData;\n children?: HierarchicalGroupedInfo[];\n}\n\nexport type AggregateValueResponse = {\n [columnId: string]: number | null;\n};\n/** An object where key is equal to column id i.e. {@link FieldDef.id id key in fieldDef} and value is equal to the aggregation value for the given aggregation */\nexport type AggregationResult = {\n [columnId: string]: number;\n};\n\nexport interface FetchDataResponse {\n /** An array of {@link RowData} */\n data: RowData[];\n /** An optional parameter to provide the total record count for a given Repeating structures with a given filter criteria in the query. If not provided, use callback setRecordCount */\n totalRecordCount?: number;\n /** @deprecated An optional parameter to provide the total record count for a given Repeating structures with a given filter criteria in the query. If not provided, use callback setRecordCount */\n filteredRecordCount?: number;\n}\n\ntype BulkAction = Pick<RowAction, 'id' | 'text'> & {\n /**\n * @param rowIds - The values for the {@link Meta.itemKey 'itemkey'} for given rows.\n * @param clearSelectionAndRefreshRowsCallback - A callback used to trigger deselection of all the selected rows and then call\n * {@link ApiContext.fetchRowsData 'fetchRowsData'} api of to fetch latest data for given rows, after action is completed.\n * @return {void} - void\n */\n onClick: (rowIds: string[], clearSelectionAndRefreshRowsCallback: () => void) => void;\n};\n\ninterface ConditionConfig {\n condition: Condition;\n data: RowData;\n}\n\nexport type PersonalizationResponse = Pick<Personalization, 'defaultPersonalization'> & {\n allPersonalizations: {\n [personalizationKey: string]: Pick<PersonalizationInfo, 'name'> & {\n personalizationState: PersonalizedState;\n };\n };\n};\n\nexport interface GroupAdditionalFieldUniqueValues {\n /** Unique values for the group additional field. */\n values: (string | number | boolean | Date)[];\n /** Indicates if there are more values. */\n hasMore: boolean;\n}\n\nexport interface ApiContext {\n /**\n * This api is used to fetch a list of raw data rows (excluding aggregations) for a given group or at the top level when no groups.\n *Refer **[apiContext](https://git.pega.io/projects/PS/repos/ui-lists-lib/browse/docs/apiContext.md?useDefaultHandler=true#29) documentation** for more details.\n * @requireWhen Always\n * @invokedWhen filters are changed OR\\\n * search criteria is changed OR\\\n end user scrolls through the RS records OR\\\n sorting is changed OR\\\n forceRefresh is triggered by consumer OR\\\n groups are changed OR\\\n hierarchicalGroups are changed OR\\\n hiddenColumns are changed\n * @param {State} rsState - Current repeating structures {@link State}. Majorly used to build the criteria for query(e.g. filter, sort, group criteria, paginationOptions).\n * @param {Meta} rsMeta - Repeating structures {@link Meta}. Majorly used to determine the fields for which data needs to be fetched.\n * @param {ApiOptions} apiOptions - Extra api options provided by repeating structures,\n * for instance, abort signal handler is sent which can be attached to the native fetch call or any framework like axios. Repeating structures will use to cancel the api calls which might be using stale state, e.g. in case of progressive scroll.\n * @returns {Promise<FetchDataResponse>} - It should return a promise of type {@link FetchDataResponse} that should contain data as one key of type Array<{@link RowData}> to provide data for given query.\n */\n fetchData: (rsState: State, rsMeta: Meta, apiOptions: ApiOptions) => Promise<FetchDataResponse>;\n\n /**\n * This api is used to fetch details for any group/sub-group ribbons in the RS. Should return labels, counts, aggregation values at each group node.This can sometimes be called even when there are no groups. Avoid running into exceptions in those cases.\n * Refer **[apiContext](https://git.pega.io/projects/PS/repos/ui-lists-lib/browse/docs/apiContext.md?useDefaultHandler=true#59) documentation** for more details.\n * @requireWhen {@link Meta.grouping 'grouping'} key is set to true in\n * @invokedWhen Grouping is applied on any {@link FieldDef fieldDef} OR\\\n * filters are changed OR\\\n * search criteria is changed OR\\\n * personalization is toggled. OR\\\n * aggregation is changed OR\\\n * hiddenColumns are changed OR\\\n * forceRefresh of RS is triggered by consumer.\n * @param {State} rsState - Current repeating structures {@link State}. Majorly used to build the criteria for query. For e.g. use rsState.groups and rsState.aggregationInfo to determine the query.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}. Majorly used to determine the fields info for which data needs to be fetched.\n * @returns {GroupedInfo[]} - It should return a promise of type array of all the {@link GroupedInfo } for the specific field. It can also include nested groups in children key.\n */\n fetchGroupedInfo?: (\n rsState: State,\n rsMeta: Meta,\n apiOptions: ApiOptions\n ) => Promise<GroupedInfo[]>;\n\n /**\n * This api is used to fetch aggregation results for a given aggregation type(sum/min/max/count) on a field. This is called when aggregations are configured on one or more column.\n * Refer **[apiContext](https://git.pega.io/projects/PS/repos/ui-lists-lib/browse/docs/apiContext.md?useDefaultHandler=true#84) documentation** for more details.\n * @requireWhen {@link FieldDef.aggregation 'aggregation'} key is set to true for at least one FieldDef AND {@link FieldDef.type 'type'} key in FieldDef should be of number for that particular fieldDef.\n * @invokedWhen When aggregation is applied on any {@link FieldDef fieldDef} OR\\\n * filters are changed OR\\\n * search criteria is changed OR\\\n * personalization is toggled. OR\\\n * hiddenColumns are changed.\n * @param {State} rsState - Current repeating structures {@link State}. Majorly used to get current aggregations applied on the RS from aggregationInfo key in state. Apart from this current filters and search criteria can also be picked from state.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}. Majorly used to determine the fields for which data needs to be fetched.\n * @returns {Promise<AggregationResult>} - It should return a promise of type {@link AggregationResult}\n */\n fetchAggregatedValues?: (\n rsState: State,\n rsMeta: Meta,\n apiOptions: ApiOptions\n ) => Promise<AggregationResult>;\n\n /**\n * This api is used to fetch unique values available for a particular field. It is generally called for a field which has {@link FieldDef.filterPickList filterPickList} key set to true.The unique values are presented to the user while filtering.\n * Refer **[apiContext](https://git.pega.io/projects/PS/repos/ui-lists-lib/browse/docs/apiContext.md?useDefaultHandler=true#99) documentation** for more details.\n * @requireWhen {@link FieldDef.filterPickList filterPickList} key set to true for at least one FieldDef\n * @invokedWhen Picklist Filter is invoked by end user from FieldDef header action menu.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @param {string} columnId - This is equal to { @link FieldDef.id 'id'} key of the field for which unique values needs to be fetched.\n * @returns {Promise<Array<string | number | boolean | Date>>} It should return a promise of type array of unique values for a given fieldDef id.\n */\n fetchUniqueColValues?: (\n rsState: State,\n rsMeta: Meta,\n columnId: string,\n apiOptions: ApiOptions\n ) => Promise<(string | number | boolean | Date)[]>;\n\n /**\n * This api is used to fetch the latest data for a given row identified uniquely by {@link FieldDef.itemKey itemKey}.\n * @requireWhen {@link Meta.editing 'editing'} OR {@link Meta.deleting 'deleting'} is set to true\n * @invokedWhen A {@link Meta.rowActions rowAction} is submitted by consumer of RS, as part of {@link RowAction. rowAction.onClick} 'refresRow' callback.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @param {string} key - A unique identifier for a given row. This is equal to {@link Meta.itemKey 'itemKey'}\n * @param {string} value - The value for the given {@link Meta.itemKey 'itemKey'} for given row.\n * @returns {Promise<RowData[]>} It should return a promise of type {@link RowData} array containing the data for a given row.Only 0th index is considered from the array.\n */\n fetchRowData?: (\n rsState: State,\n rsMeta: Meta,\n key: string,\n value: string,\n apiOptions: ApiOptions\n ) => Promise<RowData[]>;\n\n /**\n * This api is used to fetch the latest data for given set of rows identified uniquely by itemKey in {@link FieldDef}. This is passed as callback to all the {@link BulkAction.onClick bulk actions 'onClick'} method with {@link ApiContext.clearSelectedRows clearSelectedRows} api.\n * @requireWhen {@link Meta.allowBulkActions 'allowBulkActions'} is set to true.\n * @invokedWhen The bulk action is submitted, this can be called by bulk actions {@link BulkAction.onClick 'onClick'} method by RS consumer.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @param {Array<string | number | boolean | Date>} rowIds - The values for the given {@link Meta.itemKey 'itemKey'} for given rows.\n * @param itemKey - A unique identifier for a given row. This is equal to {@link Meta.itemKey 'itemKey'}\n * @returns {Promise<RowData[]>} It should return a promise of type {@link RowData} array containing the data for given rows.\n */\n fetchRowsData?: (\n rsState: State,\n rsMeta: Meta,\n rowIds: string[],\n itemKey: string,\n apiOptions: ApiOptions\n ) => Promise<RowData[]>;\n\n /**\n * This api is used to fetch the actions that is supported on rows of Repeating Structure. It is generally called when {@link Meta.editing 'editing'} is set to true.\n * @requireWhen {@link Meta.editing 'editing'} OR {@link Meta.deleting 'deleting'} is set to true\n * @invokedWhen The end user clicks on 'RowActionMenu'.Once fetched it is not refetched.\n * @param {} uniqueKey - A unique identifier for a given row. This is equal to value for {@link Meta.itemKey 'itemKey'} in {@link RowData} data.\n * @returns - A promise of type Array of {@link RowAction}\n */\n fetchRowActionDetails?: (uniqueKey: string, rowContext: RowData) => Promise<RowAction[]>;\n\n /**\n * This api is used to submit the updated row data to apiContext. It is generally called when {@link FieldDef.editable 'editable'} key is set to true for at least one FieldDef to enable inline editing for a cell.\n * @requireWhen {@link FieldDef.editable 'editable'} key is set to true for at least one FieldDef.\n * @invokedWhen The end user is done editing the cell using inline editing.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @param dataToSubmit - Updated row data to be submitted to apiContext\n * @returns It should return a promise of type {@link RowData} with the updated contents that is passed in {@link dataToSubmit} param.\n */\n submitData?: (\n rsState: State,\n rsMeta: Meta,\n dataToSubmit: RowData\n ) => Promise<{ rowData: RowData }>;\n\n /**\n * This api is used to submit moved records in a repeating structure. It is called when {@link Meta.moveListRecords 'moveListRecords'} is set to true. Repeating structure allow moving of records based on it's value.\n * @requireWhen {@link Meta.moveListRecords 'moveListRecords'} is set to true\n * @invokedWhen The move process is completed by end user this api is called to provide the info related to move records.\n * @param moveInfo - It is an object that contains sourceID(the data of {@link Meta.itemKey 'itemKey'} for the given row) that user has selected to move and\n * destinationID(the data of {@link Meta.itemKey 'itemKey'} for the given row) where the user has dropped the source row.\n * @returns It should return a promise of type object that contains a refresh key if set to true, repeating structures will trigger a refresh and fetch the whole data agin using {@link ApiContext.fetchData 'fetchData'} api\n */\n moveListRecords?: (moveInfo: {\n sourceID: string;\n destinationID: string;\n }) => Promise<{ refresh: boolean }>;\n\n /**\n * This api is used to fetch the bulkActions for a repeating structures if {@link Meta.allowBulkActions 'allowBulkActions'} is set to true.\n * This is called on demand, when the bulk action button in repeating structures is clicked. The button will be disabled till the time at least one record is not selected in repeating structures to trigger bulk action.\n * @requireWhen {@link Meta.allowBulkActions 'allowBulkActions'} is set to true.\n * @invokedWhen End user clicks on 'Bulk actions' button in RS Toolbar.Once fetched it is not refetched.\n * @param {Array<string>} rowIds - The values for the given {@link Meta.itemKey 'itemKey'} for given rows.\n * @returns A promise of type Array of {@link BulkAction}\n */\n fetchActions?: (rowIds: string[]) => Promise<BulkAction[]>;\n\n /**\n * This API is used to pass utility callbacks to the consumer. Consumers can use these callbacks at any point in the lifecycle of Repeating Structures to interact with them.\n *\n * @returns {void} This function does not return any value.\n */\n addCallbacks?: (\n /**\n * @param rsUtilityCallbacks - A set of callbacks exposed by Repeating Structures, including methods for interacting with the view and managing state.\n * See {@link RsApi} for the list of available callbacks.\n *\n */\n rsUtilityCallbacks: RsApi & {\n /**\n * @deprecated This method will be removed in future versions. Please use {@link RsApi.refreshView refreshView} instead.\n *\n * It is used to trigger a force refresh the data and re-fetch selections using apiContext.getSelectedRows api (if any of the selection mode is enabled) of repeating structures\n * @returns {void} void\n */\n forceRefresh: UtilityFunctions['forceRefresh'];\n }\n ) => void;\n\n /**\n * This api passes a unique identifier to apiContext to identify a repeating structure instance. This can be used to uniquely identify a RS instance in case of multiple RS instances.\n * @requireWhen Optional\n * @invokedWhen On Repeating structures mount to share current repeating structure instance identifier.\n * @param {string} rsID - A unique identifier\n * @returns {void} void\n */\n setRsID?: (rsID: string) => void;\n\n /**\n * This api is called to fetch all the personalizations for a repeating structure.\n * @requireWhen {@link Meta.personalization 'personalization'} key is set to true.\n * @invokedWhen On Repeating structures mount to fetch all personalizations.\n * @returns {PersonalizationResponse} It should return all the personalizations.\n */\n fetchPersonalizations?: () => Promise<PersonalizationResponse>;\n\n /**\n * This api is called to update the personalization for a repeating structure.\n * @requireWhen {@link Meta.personalization 'personalization'} key is set to true.\n * @invokedWhen End user deletes a personalization.\n * @param {string} personalizationKey - Unique identifier for the personalization.\n * @param personalization - The updated personalization state.\n * @returns {void} void\n */\n updatePersonalization?: (\n personalizationKey: string,\n personalization: {\n markAsDefault?: boolean;\n markAsAppDefault?: boolean;\n name?: string;\n personalizationState?: PersonalizedState;\n }\n ) => Promise<void>;\n\n /**\n * This api is called to delete the personalization for a repeating structure.\n * @requireWhen {@link Meta.personalization 'personalization'} key is set to true.\n * @invokedWhen End user deletes a personalization.\n * @param personalizationKey - Unique identifier for a personalization.\n * @returns {void} void\n */\n deletePersonalization?: (personalizationKey: string) => Promise<void>;\n\n /**\n * This api is called to create the personalization for a repeating structure.\n * @requireWhen {@link Meta.personalization 'personalization'} key is set to true.\n * @invokedWhen End user create a new personalization.\n * @param {string} personalizationKey - Unique identifier for the personalization.\n * @param personalization - The personalization state to be saved\n * @returns {void} void\n */\n createPersonalization?: (\n personalizationKey: string,\n personalization: {\n markAsDefault: boolean;\n name: string;\n personalizationState: PersonalizedState;\n }\n ) => Promise<string> | Promise<{ data: string }>;\n\n /**\n * This api is used to communicate selectedRows in the repeating structures to the consumer.\n * @requireWhen {@link Meta.selectionMode 'selectionMode'} key is set to true.\n * @invokedWhen {@link Meta.selectionMode 'selectionMode'} key is set to true and whenever selection changes in RS.\n * @param {Array<RowData & { $selected: boolean }>} selectedRows The selectedRows that needs to be communicated.\n * @returns {Promise<void>} A promise\n */\n setSelectedRows?: (selectedRows: (RowData & { $selected: boolean })[]) => Promise<void>;\n\n /**\n * This api is used to get the selectedRows for the repeating structures from the consumer, to populate the selections in RS.\n * @requireWhen {@link Meta.selectionMode 'selectionMode'} key is set to true.\n * @invokedWhen {@link Meta.selectionMode 'selectionMode'} key is set to true and RS requires current selected rows from the consumer.\n * @returns {Promise<Array<string>>} A promise of type array of unique identifiers for all the row. It is value of {@link Meta.itemKey 'itemKey'}\n */\n getSelectedRows?: () => Promise<string[]>;\n\n /** This api is used to communicate the clearance of all the selectedRows for the repeating structures to the consumer.\n * This is also passed as callback to all the {@link BulkAction.onClick bulk actions 'onClick'} method with {@link ApiContext.fetchRowsData fetchRowsData} api.\n * @requireWhen {@link Meta.selectionMode 'selectionMode'} key is set to true.\n * @invokedWhen In case of {@link Meta.selectionMode \"multi\"} selection mode, while toggling all the selections OR\\\n * while switching personalizations OR\\\n * when the bulk action is submitted, this can be called by bulk actions {@link BulkAction.onClick 'onClick'} method by RS consumer.\n * @returns {Promise<void>} A promise\n */\n clearSelectedRows?: () => Promise<void>;\n\n /**\n * This api is used to fetch the hierarchical groups for an RS if {@link FieldDef.hierarchicalInfo 'hierarchicalInfo'} key is set to true for at least one FieldDef.\n * @requireWhen {@link FieldDef.hierarchicalInfo 'hierarchicalInfo'} key is set to true for at least one FieldDef\n * @invokedWhen Any change in filters, search criteria, hierarchichal groups, aggregations is detected in RS state or personalizations are toggled.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @returns {HierarchicalGroupedInfo[]} - It should return a promise of type array of all the {@link HierarchicalGroupedInfo } for the specific field. It can also include nested hierarchical groups in children key.\n */\n fetchHierarchicalGroupedInfo?: (\n rsState: State,\n rsMeta: Meta,\n apiOptions: ApiOptions\n ) => Promise<HierarchicalGroupedInfo[]>;\n\n /**\n * This api is used to communicate repeating structure state to the consumer. It also includes visibleColumns apart from regular repeating structure state.\n * @requireWhen Optional\n * @invokedWhen After any action performed on Repeating structures that results in updating of state.\n * @param state Repeating structure state\n * @returns {void} void\n */\n stateUpdateCallback?: (state: PersonalizedState & { visibleColumns?: string[] }) => void;\n\n /**\n * This api is used to communicate repeating structure state to the consumer. It also includes active personalization in RS apart from regular repeating structure state.\n * @requireWhen Optional\n * @param state Repeating structure state\n * @returns {void} void\n */\n setComponentState?: (state: PersonalizedState & { activePersonalization?: string }) => void;\n /**\n * This api is used to communicate repeating structure state to RS from consumer.\n * @requireWhen Optional\n * @returns RS state.\n */\n getComponentState?: () => Promise<PersonalizedState & { activePersonalization?: string }>;\n /** This api is called on click of 'Import data' option in repeating structures toolbar and should open a modal to allow import of data from a CSV file.\n * @requireWhen {@link Meta.showImportDataOption showImportDataOption} is set to true in Meta.\n * @invokedWhen \"Import data\" button is clicked in the repeating structures toolbar\n * @param {ModalManagerContextValue['create']} create - The function to create a modal in the current context {@link ModalManagerContextValue['create']}.\n * @returns {void} void\n */\n importCSVData?: (create: ModalManagerContextValue['create']) => Promise<void>;\n /** This api is called on click of 'Export to excel' option in repeating structures toolbar and should export the data into a excel file.\n * @requireWhen {@link Meta.showExportToExcelOption showExportToExcelOption} is set to true in Meta.\n * @invokedWhen \"Export to excel\" button is clicked in the repeating structures toolbar\n * @param {State} rsState - Current repeating structures state {@link State}.\n * @param {Meta} rsMeta - Repeating structures meta {@link Meta}.\n * @returns {void} void\n */\n exportData?: (rsState: State, rsMeta: Meta, apiOptions: ApiOptions) => Promise<void>;\n\n /** This api is called on click of 'Export to CSV' option in repeating structures toolbar and should export the data into a CSV file.\n * @requireWhen {@link Meta.showExportToCSVOption showExportToCSVOption} is set to true in Meta.\n * @invokedWhen \"Export to CSV\" button is clicked in the repeating structures toolbar\n * @param {State} rsState - Current repeating structures state {@link State}.\n * @param {Meta} rsMeta - Repeating structures meta {@link Meta}.\n * @returns {void} void\n */\n exportDataToCSV?: (rsState: State, rsMeta: Meta, apiOptions: ApiOptions) => Promise<void>;\n\n /** This api is used to communicate source and destinaltion row keys to apiContext during row-reordering operation.\n * @requireWhen {@link Meta.reorderItems reorderItems} is set to true and {@link Meta.moveListRecords moveListRecords} is set to false in Meta.\n * @invokedWhen Reordering operations is being performed on rows.\n * @param {string} sourceKey - the value of {@link Meta.itemKey 'itemKey'} for the given row that user has selected to move.\n * @param {string} destinationKey - the value of {@link Meta.itemKey 'itemKey'} for the given row where the user has dropped the source row.\n * @returns {void} void\n */\n applyRowReorder?: (sourceKey: string, destinationKey: string) => Promise<void>;\n\n /**\n * This API allows Repeating Structures to determine if a given `data` meets a specified `condition`. It is utilized in the following features if provided:\n * - `Conditional Formatting` - Optional. If `evaluateCondition` is not provided, Repeating Structures will evaluate the row condition on their own. Otherwise, this function will be used.\n *\n * @param {State} rsState - The state of the Repeating Structures.\n * @param {Meta} rsMeta - The meta information of the Repeating Structures.\n * @param {ConditionConfig} config - The configuration for the condition.\n * @returns {Promise<boolean> | boolean} - Returns `true` if the data satisfies the condition, otherwise `false`.\n */\n evaluateCondition?: (rsState: State, rsMeta: Meta, config: ConditionConfig) => boolean;\n\n /**\n * This api is used to fetch unique values for a particular group additional field. It is generally called for a group additional field which has more than 1 value.\n * It should return unique values for the additional field along with hasMore flag to indicate if there are more values.\n * @param additionalField - The group additional field for which unique values needs to be fetched.\n * @param groupFilters - The current group filters on which the additional field is set.\n * @param rsState - The state of the Repeating Structures.\n * @param rsMeta - The meta information of the Repeating Structures.\n * @param options - Extra api options provided by repeating structures.\n * @returns GroupAdditionalFieldUniqueValues - It should return a promise of type {@link GroupAdditionalFieldUniqueValues}\n */\n fetchGroupAdditionalFieldUniqueValues?: (\n additionalField: GroupAdditionalField,\n groupFilters: GroupFilter['filters'],\n rsState: State,\n rsMeta: Meta,\n options?: ApiOptions\n ) => Promise<GroupAdditionalFieldUniqueValues>;\n}\n"]}
1
+ {"version":3,"file":"ApiContext.types.js","sourceRoot":"","sources":["../../types/ApiContext.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ModalManagerContextValue } from '@pega/cosmos-react-core/lib/components/Modal/Modal.types';\nimport type { Condition } from '@pega/cosmos-react-condition-builder';\n\nimport type { RowData } from '../src/core/generators/RowGenerator.types';\nimport type { UtilityFunctions } from '../src/core/generators/viewUtilityMethods';\n\nimport type {\n Personalization,\n PersonalizationInfo,\n PersonalizedState,\n State,\n Group,\n /* eslint-disable @typescript-eslint/no-unused-vars */\n DateGroupAdditionalField,\n NumberGroupAdditionalField,\n GroupFilter,\n GroupAdditionalField\n /* eslint-enable @typescript-eslint/no-unused-vars */\n} from './State.types';\nimport type {\n Meta,\n RowAction,\n FieldDef,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n FieldType\n} from './Meta.types';\n\n/**\n * Represents information about the currently active view in the repeating structures.\n */\ntype ActiveViewInfo = {\n /**\n * The unique identifier of the active view.\n */\n id: string | undefined;\n\n /**\n * The name of the active view.\n */\n name: string | undefined;\n\n /**\n * Indicates whether the active view has unsaved changes.\n */\n isDirty: boolean;\n};\n\nexport type RsApi = {\n /**\n * Refreshes the current view.\n * @see {@link UtilityFunctions.refreshView}\n */\n refreshView: UtilityFunctions['forceRefresh'];\n\n /**\n * Sets the record count in the view.\n * @see {@link UtilityFunctions.setRecordCount}\n */\n setRecordCount: UtilityFunctions['setRecordCount'];\n\n /**\n * Dispatches an action to the repeating structures with an payload.\n * @see {@link UtilityFunctions.dispatchAction}\n */\n dispatchAction: UtilityFunctions['dispatchAction'];\n\n /**\n * Retrieves information about the currently active view.\n * @returns The {@link ActiveViewInfo active view information} or `void` if unavailable.\n */\n getActiveViewInfo: () => ActiveViewInfo | void;\n\n /**\n * Sets hidden columns of the view.\n * @param columns - An array of column IDs to hide.\n * @param ootbColumns - .\n * @param ootbColumns.dragHandle - Whether to hide the drag-and-drop column.\n */\n setHiddenColumns?: (columns: string[], ootbColumns?: { dragHandle: boolean }) => void;\n\n /**\n * Sets Column order of the view.\n * @param columns - An array of column IDs to reorder.\n */\n setColumnOrder?: (columns: string[]) => void;\n\n /**\n * Sets the filters of the view.\n * @param filter - The filter condition to apply.\n */\n setFilter: (filter: Condition) => void;\n\n /**\n * Sets the groups of the view.\n * @param groups - The grouping configuration.\n */\n setGrouping?: (groups: Group[]) => void;\n\n /**\n * Sets the sorting order of the view.\n * @param {NonNullable<State['sortingOrder']>} sorts - The sorting configuration.\n */\n setSorting: (sorts: NonNullable<State['sortingOrder']>) => void;\n\n /**\n * Sets the column aliases of the view.\n * @param aliases - The column alias configuration.\n */\n setAliases: (aliases: State['columnAlias']) => void;\n\n /**\n * Sets the aggregation information of the view.\n * @param {State['aggregationInfo']} agg - The aggregation configuration.\n */\n setAggregations: (agg: State['aggregationInfo']) => void;\n\n /**\n * Sets the visibility of the row reorder field.\n * @param {boolean} visibility - Whether the row reorder field should be visible.\n */\n setRowReorderFieldVisibility: (visibility: boolean) => void;\n\n /**\n * Updates the visibility of specific columns.\n * @param {Object} columns - A mapping of column IDs to their visibility state.\n */\n updateColumnsVisibility: (columns: { [key: FieldDef['id']]: boolean }) => void;\n\n /**\n * Sets the `renderFormatter` for the given column.\n * @param columnId - Column ID\n * @param formatterName - ID of the formatter/renderer\n */\n setRenderFormatter: (columnId: string, formatterName: string) => void;\n\n /**\n * Sets the conditional style formats of the view.\n * @param conditionalStyleFormats - The conditional style formats to apply.\n */\n setConditionalStyleFormats: (\n conditionalStyleFormats: NonNullable<State['conditionalStyleFormats']>\n ) => void;\n};\n\nexport interface ApiOptions {\n signal?: AbortSignal;\n /** Indicates current api triggered should invalidate the cache if any and reload the data. */\n invalidateCache?: boolean;\n /** A unique token or version identifier that changes whenever a refresh is triggered. Unlike a boolean `invalidateCache` flag, the `invalidateCacheToken` ensures that multiple APIs triggered\n in the same refresh cycle receive the same identifier. */\n invalidateCacheToken?: number;\n}\n// Aggregation response type\ntype AggregationTypeResp = 'avg' | 'max' | 'min' | 'nonNullCount' | 'sum' | 'distinctCount';\n/** An object with key equal to {@link AggregationTypeResp aggregation type} and value is equal to the actual value of that aggregation type */\ntype AggregationOptions = {\n [agg in AggregationTypeResp]?: number | null;\n};\n/** An object where key is equal to the column id (i.e. {@link FieldDef.id id} in FieldDef) and value is equal to its {@link AggregationOptions Aggregation values} */\nexport type AggregationResp = {\n [columnId: string]: AggregationOptions;\n};\n\nexport type AdditionalFieldData = {\n /** {@link FieldDef.id Field Id} of the additional field. */\n id: string;\n /** Value of the additional field that should be displayed for additional field.\n * The value can represent:\n * - An aggregated value (e.g., sum, max, min, avg) for {@link FieldType.NUMBER number} type fields when\n * {@link NumberGroupAdditionalField.aggregation aggregation} is selected in additional fields meta.\n * - A date function value (e.g., Day, Month, Year) for {@link FieldType.DATE 'date'} / {@link FieldType.DATE_TIME 'datetime'}\n * fields when a {@link DateGroupAdditionalField.dateFunction date function} is selected in the additional fields metadata..\n * - A scalar or single value for the additional field.\n */\n value: null | string | number | boolean | Date;\n /** Represents the distinct count of\n * occurrences for the additional field data. This is generally required,\n * but may be omitted if {@link NumberGroupAdditionalField.aggregation aggregation} is selected for number type fields\n * in the additional fields metadata. */\n count?: number;\n};\n\n// Grouping response type\nexport interface GroupedInfo {\n /** Value for the current group node. */\n name: null | string | number | boolean | Date; // Value for the current node\n /** # of data rows in this node */\n count: number;\n /** An optional data row from the group node that is used to process extra information required by group node */\n data?: RowData;\n /** Additional fields data for the current group node */\n additionalFieldsData?: AdditionalFieldData[];\n /** Aggregation values of a column if applied */\n agg?: AggregationResp;\n /** Nested groups within the parent group node */\n children?: GroupedInfo[];\n}\n\nexport interface HierarchicalGroupedInfo extends Pick<GroupedInfo, 'count' | 'agg'> {\n info: RowData;\n children?: HierarchicalGroupedInfo[];\n}\n\nexport type AggregateValueResponse = {\n [columnId: string]: number | null;\n};\n/** An object where key is equal to column id i.e. {@link FieldDef.id id key in fieldDef} and value is equal to the aggregation value for the given aggregation */\nexport type AggregationResult = {\n [columnId: string]: number;\n};\n\nexport interface FetchDataResponse {\n /** An array of {@link RowData} */\n data: RowData[];\n /** An optional parameter to provide the total record count for a given Repeating structures with a given filter criteria in the query. If not provided, use callback setRecordCount */\n totalRecordCount?: number;\n /** @deprecated An optional parameter to provide the total record count for a given Repeating structures with a given filter criteria in the query. If not provided, use callback setRecordCount */\n filteredRecordCount?: number;\n}\n\ntype BulkAction = Pick<RowAction, 'id' | 'text'> & {\n /**\n * @param rowIds - The values for the {@link Meta.itemKey 'itemkey'} for given rows.\n * @param clearSelectionAndRefreshRowsCallback - A callback used to trigger deselection of all the selected rows and then call\n * {@link ApiContext.fetchRowsData 'fetchRowsData'} api of to fetch latest data for given rows, after action is completed.\n * @return {void} - void\n */\n onClick: (rowIds: string[], clearSelectionAndRefreshRowsCallback: () => void) => void;\n};\n\ninterface ConditionConfig {\n condition: Condition;\n data: RowData;\n}\n\nexport type PersonalizationResponse = Pick<Personalization, 'defaultPersonalization'> & {\n allPersonalizations: {\n [personalizationKey: string]: Pick<PersonalizationInfo, 'name'> & {\n personalizationState: PersonalizedState;\n };\n };\n};\n\nexport interface GroupAdditionalFieldUniqueValues {\n /** Unique values for the group additional field. */\n values: (string | number | boolean | Date)[];\n /** Indicates if there are more values. */\n hasMore: boolean;\n}\n\nexport interface ApiContext {\n /**\n * This api is used to fetch a list of raw data rows (excluding aggregations) for a given group or at the top level when no groups.\n *Refer **[apiContext](https://git.pega.io/projects/PS/repos/ui-lists-lib/browse/docs/apiContext.md?useDefaultHandler=true#29) documentation** for more details.\n * @requireWhen Always\n * @invokedWhen filters are changed OR\\\n * search criteria is changed OR\\\n end user scrolls through the RS records OR\\\n sorting is changed OR\\\n forceRefresh is triggered by consumer OR\\\n groups are changed OR\\\n hierarchicalGroups are changed OR\\\n hiddenColumns are changed\n * @param {State} rsState - Current repeating structures {@link State}. Majorly used to build the criteria for query(e.g. filter, sort, group criteria, paginationOptions).\n * @param {Meta} rsMeta - Repeating structures {@link Meta}. Majorly used to determine the fields for which data needs to be fetched.\n * @param {ApiOptions} apiOptions - Extra api options provided by repeating structures,\n * for instance, abort signal handler is sent which can be attached to the native fetch call or any framework like axios. Repeating structures will use to cancel the api calls which might be using stale state, e.g. in case of progressive scroll.\n * @returns {Promise<FetchDataResponse>} - It should return a promise of type {@link FetchDataResponse} that should contain data as one key of type Array<{@link RowData}> to provide data for given query.\n */\n fetchData: (rsState: State, rsMeta: Meta, apiOptions: ApiOptions) => Promise<FetchDataResponse>;\n\n /**\n * This api is used to fetch details for any group/sub-group ribbons in the RS. Should return labels, counts, aggregation values at each group node.This can sometimes be called even when there are no groups. Avoid running into exceptions in those cases.\n * Refer **[apiContext](https://git.pega.io/projects/PS/repos/ui-lists-lib/browse/docs/apiContext.md?useDefaultHandler=true#59) documentation** for more details.\n * @requireWhen {@link Meta.grouping 'grouping'} key is set to true in\n * @invokedWhen Grouping is applied on any {@link FieldDef fieldDef} OR\\\n * filters are changed OR\\\n * search criteria is changed OR\\\n * personalization is toggled. OR\\\n * aggregation is changed OR\\\n * hiddenColumns are changed OR\\\n * forceRefresh of RS is triggered by consumer.\n * @param {State} rsState - Current repeating structures {@link State}. Majorly used to build the criteria for query. For e.g. use rsState.groups and rsState.aggregationInfo to determine the query.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}. Majorly used to determine the fields info for which data needs to be fetched.\n * @returns {GroupedInfo[]} - It should return a promise of type array of all the {@link GroupedInfo } for the specific field. It can also include nested groups in children key.\n */\n fetchGroupedInfo?: (\n rsState: State,\n rsMeta: Meta,\n apiOptions: ApiOptions\n ) => Promise<GroupedInfo[]>;\n\n /**\n * This api is used to fetch aggregation results for a given aggregation type(sum/min/max/count) on a field. This is called when aggregations are configured on one or more column.\n * Refer **[apiContext](https://git.pega.io/projects/PS/repos/ui-lists-lib/browse/docs/apiContext.md?useDefaultHandler=true#84) documentation** for more details.\n * @requireWhen {@link FieldDef.aggregation 'aggregation'} key is set to true for at least one FieldDef AND {@link FieldDef.type 'type'} key in FieldDef should be of number for that particular fieldDef.\n * @invokedWhen When aggregation is applied on any {@link FieldDef fieldDef} OR\\\n * filters are changed OR\\\n * search criteria is changed OR\\\n * personalization is toggled. OR\\\n * hiddenColumns are changed.\n * @param {State} rsState - Current repeating structures {@link State}. Majorly used to get current aggregations applied on the RS from aggregationInfo key in state. Apart from this current filters and search criteria can also be picked from state.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}. Majorly used to determine the fields for which data needs to be fetched.\n * @returns {Promise<AggregationResult>} - It should return a promise of type {@link AggregationResult}\n */\n fetchAggregatedValues?: (\n rsState: State,\n rsMeta: Meta,\n apiOptions: ApiOptions\n ) => Promise<AggregationResult>;\n\n /**\n * This api is used to fetch unique values available for a particular field. It is generally called for a field which has {@link FieldDef.filterPickList filterPickList} key set to true.The unique values are presented to the user while filtering.\n * Refer **[apiContext](https://git.pega.io/projects/PS/repos/ui-lists-lib/browse/docs/apiContext.md?useDefaultHandler=true#99) documentation** for more details.\n * @requireWhen {@link FieldDef.filterPickList filterPickList} key set to true for at least one FieldDef\n * @invokedWhen Picklist Filter is invoked by end user from FieldDef header action menu.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @param {string} columnId - This is equal to { @link FieldDef.id 'id'} key of the field for which unique values needs to be fetched.\n * @returns {Promise<Array<string | number | boolean | Date>>} It should return a promise of type array of unique values for a given fieldDef id.\n */\n fetchUniqueColValues?: (\n rsState: State,\n rsMeta: Meta,\n columnId: string,\n apiOptions: ApiOptions\n ) => Promise<(string | number | boolean | Date)[]>;\n\n /**\n * This api is used to fetch the latest data for a given row identified uniquely by {@link FieldDef.itemKey itemKey}.\n * @requireWhen {@link Meta.editing 'editing'} OR {@link Meta.deleting 'deleting'} is set to true\n * @invokedWhen A {@link Meta.rowActions rowAction} is submitted by consumer of RS, as part of {@link RowAction. rowAction.onClick} 'refresRow' callback.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @param {string} key - A unique identifier for a given row. This is equal to {@link Meta.itemKey 'itemKey'}\n * @param {string} value - The value for the given {@link Meta.itemKey 'itemKey'} for given row.\n * @param {RowData} existingRowData - Existing row data for the given row.\n * @returns {Promise<RowData[]>} It should return a promise of type {@link RowData} array containing the data for a given row.Only 0th index is considered from the array.\n */\n fetchRowData?: (\n rsState: State,\n rsMeta: Meta,\n key: string,\n value: string,\n existingRowData: RowData,\n apiOptions: ApiOptions\n ) => Promise<RowData[]>;\n\n /**\n * This api is used to fetch the latest data for given set of rows identified uniquely by itemKey in {@link FieldDef}. This is passed as callback to all the {@link BulkAction.onClick bulk actions 'onClick'} method with {@link ApiContext.clearSelectedRows clearSelectedRows} api.\n * @requireWhen {@link Meta.allowBulkActions 'allowBulkActions'} is set to true.\n * @invokedWhen The bulk action is submitted, this can be called by bulk actions {@link BulkAction.onClick 'onClick'} method by RS consumer.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @param {Array<string | number | boolean | Date>} rowIds - The values for the given {@link Meta.itemKey 'itemKey'} for given rows.\n * @param itemKey - A unique identifier for a given row. This is equal to {@link Meta.itemKey 'itemKey'}\n * @returns {Promise<RowData[]>} It should return a promise of type {@link RowData} array containing the data for given rows.\n */\n fetchRowsData?: (\n rsState: State,\n rsMeta: Meta,\n rowIds: string[],\n itemKey: string,\n apiOptions: ApiOptions\n ) => Promise<RowData[]>;\n\n /**\n * This api is used to fetch the actions that is supported on rows of Repeating Structure. It is generally called when {@link Meta.editing 'editing'} is set to true.\n * @requireWhen {@link Meta.editing 'editing'} OR {@link Meta.deleting 'deleting'} is set to true\n * @invokedWhen The end user clicks on 'RowActionMenu'.Once fetched it is not refetched.\n * @param {} uniqueKey - A unique identifier for a given row. This is equal to value for {@link Meta.itemKey 'itemKey'} in {@link RowData} data.\n * @returns - A promise of type Array of {@link RowAction}\n */\n fetchRowActionDetails?: (uniqueKey: string, rowContext: RowData) => Promise<RowAction[]>;\n\n /**\n * This api is used to submit the updated row data to apiContext. It is generally called when {@link FieldDef.editable 'editable'} key is set to true for at least one FieldDef to enable inline editing for a cell.\n * @requireWhen {@link FieldDef.editable 'editable'} key is set to true for at least one FieldDef.\n * @invokedWhen The end user is done editing the cell using inline editing.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @param dataToSubmit - Updated row data to be submitted to apiContext\n * @returns It should return a promise of type {@link RowData} with the updated contents that is passed in {@link dataToSubmit} param.\n */\n submitData?: (\n rsState: State,\n rsMeta: Meta,\n dataToSubmit: RowData\n ) => Promise<{ rowData: RowData }>;\n\n /**\n * This api is used to submit moved records in a repeating structure. It is called when {@link Meta.moveListRecords 'moveListRecords'} is set to true. Repeating structure allow moving of records based on it's value.\n * @requireWhen {@link Meta.moveListRecords 'moveListRecords'} is set to true\n * @invokedWhen The move process is completed by end user this api is called to provide the info related to move records.\n * @param moveInfo - It is an object that contains sourceID(the data of {@link Meta.itemKey 'itemKey'} for the given row) that user has selected to move and\n * destinationID(the data of {@link Meta.itemKey 'itemKey'} for the given row) where the user has dropped the source row.\n * @returns It should return a promise of type object that contains a refresh key if set to true, repeating structures will trigger a refresh and fetch the whole data agin using {@link ApiContext.fetchData 'fetchData'} api\n */\n moveListRecords?: (moveInfo: {\n sourceID: string;\n destinationID: string;\n }) => Promise<{ refresh: boolean }>;\n\n /**\n * This api is used to fetch the bulkActions for a repeating structures if {@link Meta.allowBulkActions 'allowBulkActions'} is set to true.\n * This is called on demand, when the bulk action button in repeating structures is clicked. The button will be disabled till the time at least one record is not selected in repeating structures to trigger bulk action.\n * @requireWhen {@link Meta.allowBulkActions 'allowBulkActions'} is set to true.\n * @invokedWhen End user clicks on 'Bulk actions' button in RS Toolbar.Once fetched it is not refetched.\n * @param {Array<string>} rowIds - The values for the given {@link Meta.itemKey 'itemKey'} for given rows.\n * @returns A promise of type Array of {@link BulkAction}\n */\n fetchActions?: (rowIds: string[]) => Promise<BulkAction[]>;\n\n /**\n * This API is used to pass utility callbacks to the consumer. Consumers can use these callbacks at any point in the lifecycle of Repeating Structures to interact with them.\n *\n * @returns {void} This function does not return any value.\n */\n addCallbacks?: (\n /**\n * @param rsUtilityCallbacks - A set of callbacks exposed by Repeating Structures, including methods for interacting with the view and managing state.\n * See {@link RsApi} for the list of available callbacks.\n *\n */\n rsUtilityCallbacks: RsApi & {\n /**\n * @deprecated This method will be removed in future versions. Please use {@link RsApi.refreshView refreshView} instead.\n *\n * It is used to trigger a force refresh the data and re-fetch selections using apiContext.getSelectedRows api (if any of the selection mode is enabled) of repeating structures\n * @returns {void} void\n */\n forceRefresh: UtilityFunctions['forceRefresh'];\n }\n ) => void;\n\n /**\n * This api passes a unique identifier to apiContext to identify a repeating structure instance. This can be used to uniquely identify a RS instance in case of multiple RS instances.\n * @requireWhen Optional\n * @invokedWhen On Repeating structures mount to share current repeating structure instance identifier.\n * @param {string} rsID - A unique identifier\n * @returns {void} void\n */\n setRsID?: (rsID: string) => void;\n\n /**\n * This api is called to fetch all the personalizations for a repeating structure.\n * @requireWhen {@link Meta.personalization 'personalization'} key is set to true.\n * @invokedWhen On Repeating structures mount to fetch all personalizations.\n * @returns {PersonalizationResponse} It should return all the personalizations.\n */\n fetchPersonalizations?: () => Promise<PersonalizationResponse>;\n\n /**\n * This api is called to update the personalization for a repeating structure.\n * @requireWhen {@link Meta.personalization 'personalization'} key is set to true.\n * @invokedWhen End user deletes a personalization.\n * @param {string} personalizationKey - Unique identifier for the personalization.\n * @param personalization - The updated personalization state.\n * @returns {void} void\n */\n updatePersonalization?: (\n personalizationKey: string,\n personalization: {\n markAsDefault?: boolean;\n markAsAppDefault?: boolean;\n name?: string;\n personalizationState?: PersonalizedState;\n }\n ) => Promise<void>;\n\n /**\n * This api is called to delete the personalization for a repeating structure.\n * @requireWhen {@link Meta.personalization 'personalization'} key is set to true.\n * @invokedWhen End user deletes a personalization.\n * @param personalizationKey - Unique identifier for a personalization.\n * @returns {void} void\n */\n deletePersonalization?: (personalizationKey: string) => Promise<void>;\n\n /**\n * This api is called to create the personalization for a repeating structure.\n * @requireWhen {@link Meta.personalization 'personalization'} key is set to true.\n * @invokedWhen End user create a new personalization.\n * @param {string} personalizationKey - Unique identifier for the personalization.\n * @param personalization - The personalization state to be saved\n * @returns {void} void\n */\n createPersonalization?: (\n personalizationKey: string,\n personalization: {\n markAsDefault: boolean;\n name: string;\n personalizationState: PersonalizedState;\n }\n ) => Promise<string> | Promise<{ data: string }>;\n\n /**\n * This api is used to communicate selectedRows in the repeating structures to the consumer.\n * @requireWhen {@link Meta.selectionMode 'selectionMode'} key is set to true.\n * @invokedWhen {@link Meta.selectionMode 'selectionMode'} key is set to true and whenever selection changes in RS.\n * @param {Array<RowData & { $selected: boolean }>} selectedRows The selectedRows that needs to be communicated.\n * @returns {Promise<void>} A promise\n */\n setSelectedRows?: (selectedRows: (RowData & { $selected: boolean })[]) => Promise<void>;\n\n /**\n * This api is used to get the selectedRows for the repeating structures from the consumer, to populate the selections in RS.\n * @requireWhen {@link Meta.selectionMode 'selectionMode'} key is set to true.\n * @invokedWhen {@link Meta.selectionMode 'selectionMode'} key is set to true and RS requires current selected rows from the consumer.\n * @returns {Promise<Array<string>>} A promise of type array of unique identifiers for all the row. It is value of {@link Meta.itemKey 'itemKey'}\n */\n getSelectedRows?: () => Promise<string[]>;\n\n /** This api is used to communicate the clearance of all the selectedRows for the repeating structures to the consumer.\n * This is also passed as callback to all the {@link BulkAction.onClick bulk actions 'onClick'} method with {@link ApiContext.fetchRowsData fetchRowsData} api.\n * @requireWhen {@link Meta.selectionMode 'selectionMode'} key is set to true.\n * @invokedWhen In case of {@link Meta.selectionMode \"multi\"} selection mode, while toggling all the selections OR\\\n * while switching personalizations OR\\\n * when the bulk action is submitted, this can be called by bulk actions {@link BulkAction.onClick 'onClick'} method by RS consumer.\n * @returns {Promise<void>} A promise\n */\n clearSelectedRows?: () => Promise<void>;\n\n /**\n * This api is used to fetch the hierarchical groups for an RS if {@link FieldDef.hierarchicalInfo 'hierarchicalInfo'} key is set to true for at least one FieldDef.\n * @requireWhen {@link FieldDef.hierarchicalInfo 'hierarchicalInfo'} key is set to true for at least one FieldDef\n * @invokedWhen Any change in filters, search criteria, hierarchichal groups, aggregations is detected in RS state or personalizations are toggled.\n * @param {State} rsState - Current repeating structures {@link State}.\n * @param {Meta} rsMeta - Repeating structures {@link Meta}.\n * @returns {HierarchicalGroupedInfo[]} - It should return a promise of type array of all the {@link HierarchicalGroupedInfo } for the specific field. It can also include nested hierarchical groups in children key.\n */\n fetchHierarchicalGroupedInfo?: (\n rsState: State,\n rsMeta: Meta,\n apiOptions: ApiOptions\n ) => Promise<HierarchicalGroupedInfo[]>;\n\n /**\n * This api is used to communicate repeating structure state to the consumer. It also includes visibleColumns apart from regular repeating structure state.\n * @requireWhen Optional\n * @invokedWhen After any action performed on Repeating structures that results in updating of state.\n * @param state Repeating structure state\n * @returns {void} void\n */\n stateUpdateCallback?: (state: PersonalizedState & { visibleColumns?: string[] }) => void;\n\n /**\n * This api is used to communicate repeating structure state to the consumer. It also includes active personalization in RS apart from regular repeating structure state.\n * @requireWhen Optional\n * @param state Repeating structure state\n * @returns {void} void\n */\n setComponentState?: (state: PersonalizedState & { activePersonalization?: string }) => void;\n /**\n * This api is used to communicate repeating structure state to RS from consumer.\n * @requireWhen Optional\n * @returns RS state.\n */\n getComponentState?: () => Promise<PersonalizedState & { activePersonalization?: string }>;\n /** This api is called on click of 'Import data' option in repeating structures toolbar and should open a modal to allow import of data from a CSV file.\n * @requireWhen {@link Meta.showImportDataOption showImportDataOption} is set to true in Meta.\n * @invokedWhen \"Import data\" button is clicked in the repeating structures toolbar\n * @param {ModalManagerContextValue['create']} create - The function to create a modal in the current context {@link ModalManagerContextValue['create']}.\n * @returns {void} void\n */\n importCSVData?: (create: ModalManagerContextValue['create']) => Promise<void>;\n /** This api is called on click of 'Export to excel' option in repeating structures toolbar and should export the data into a excel file.\n * @requireWhen {@link Meta.showExportToExcelOption showExportToExcelOption} is set to true in Meta.\n * @invokedWhen \"Export to excel\" button is clicked in the repeating structures toolbar\n * @param {State} rsState - Current repeating structures state {@link State}.\n * @param {Meta} rsMeta - Repeating structures meta {@link Meta}.\n * @returns {void} void\n */\n exportData?: (rsState: State, rsMeta: Meta, apiOptions: ApiOptions) => Promise<void>;\n\n /** This api is called on click of 'Export to CSV' option in repeating structures toolbar and should export the data into a CSV file.\n * @requireWhen {@link Meta.showExportToCSVOption showExportToCSVOption} is set to true in Meta.\n * @invokedWhen \"Export to CSV\" button is clicked in the repeating structures toolbar\n * @param {State} rsState - Current repeating structures state {@link State}.\n * @param {Meta} rsMeta - Repeating structures meta {@link Meta}.\n * @returns {void} void\n */\n exportDataToCSV?: (rsState: State, rsMeta: Meta, apiOptions: ApiOptions) => Promise<void>;\n\n /** This api is used to communicate source and destinaltion row keys to apiContext during row-reordering operation.\n * @requireWhen {@link Meta.reorderItems reorderItems} is set to true and {@link Meta.moveListRecords moveListRecords} is set to false in Meta.\n * @invokedWhen Reordering operations is being performed on rows.\n * @param {string} sourceKey - the value of {@link Meta.itemKey 'itemKey'} for the given row that user has selected to move.\n * @param {string} destinationKey - the value of {@link Meta.itemKey 'itemKey'} for the given row where the user has dropped the source row.\n * @returns {void} void\n */\n applyRowReorder?: (sourceKey: string, destinationKey: string) => Promise<void>;\n\n /**\n * This API allows Repeating Structures to determine if a given `data` meets a specified `condition`. It is utilized in the following features if provided:\n * - `Conditional Formatting` - Optional. If `evaluateCondition` is not provided, Repeating Structures will evaluate the row condition on their own. Otherwise, this function will be used.\n *\n * @param {State} rsState - The state of the Repeating Structures.\n * @param {Meta} rsMeta - The meta information of the Repeating Structures.\n * @param {ConditionConfig} config - The configuration for the condition.\n * @returns {Promise<boolean> | boolean} - Returns `true` if the data satisfies the condition, otherwise `false`.\n */\n evaluateCondition?: (rsState: State, rsMeta: Meta, config: ConditionConfig) => boolean;\n\n /**\n * This api is used to fetch unique values for a particular group additional field. It is generally called for a group additional field which has more than 1 value.\n * It should return unique values for the additional field along with hasMore flag to indicate if there are more values.\n * @param additionalField - The group additional field for which unique values needs to be fetched.\n * @param groupFilters - The current group filters on which the additional field is set.\n * @param rsState - The state of the Repeating Structures.\n * @param rsMeta - The meta information of the Repeating Structures.\n * @param options - Extra api options provided by repeating structures.\n * @returns GroupAdditionalFieldUniqueValues - It should return a promise of type {@link GroupAdditionalFieldUniqueValues}\n */\n fetchGroupAdditionalFieldUniqueValues?: (\n additionalField: GroupAdditionalField,\n groupFilters: GroupFilter['filters'],\n rsState: State,\n rsMeta: Meta,\n options?: ApiOptions\n ) => Promise<GroupAdditionalFieldUniqueValues>;\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pega/lists-core",
3
- "version": "9.0.0-build.14.6",
3
+ "version": "9.0.0-build.14.7",
4
4
  "description": "Core headless UI library that the users can use to write their own UI and create repeating structures like table, gallery, timeline etc.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "author": "Pegasystems",
@@ -14,8 +14,8 @@
14
14
  "build": "tsc -b tsconfig.build.json"
15
15
  },
16
16
  "dependencies": {
17
- "@pega/cosmos-react-condition-builder": "9.0.0-build.14.6",
18
- "@pega/cosmos-react-core": "9.0.0-build.14.6",
17
+ "@pega/cosmos-react-condition-builder": "9.0.0-build.14.7",
18
+ "@pega/cosmos-react-core": "9.0.0-build.14.7",
19
19
  "@types/lodash.get": "^4.4.9",
20
20
  "@types/uuid": "^9.0.0",
21
21
  "dayjs": "^1.11.13",