import { default as React } from 'react'; import { ExtendedColumnType } from './types'; export type ApplyColumnRenderOptions = { runAction?: (actionName: string, arg: unknown) => void; onCellValueChange?: (record: any, dataIndex: string, value: unknown) => void; }; /** * 渲染数据字典列:通过 getCoreConfig().getDictOptions(columnDictType) 取选项,将 value 转成 label */ export declare const renderDictCell: (text: any, col: ExtendedColumnType) => React.ReactNode; /** * 渲染图片列 */ export declare const renderImageCell: (text: any, col: ExtendedColumnType) => React.ReactNode; /** * 渲染金额列 */ export declare const renderMoneyCell: (text: any, col: ExtendedColumnType) => React.ReactNode; /** * 渲染日期列 */ export declare const renderDateCell: (text: any, col: ExtendedColumnType) => React.ReactNode; /** * 渲染数组列 */ export declare const renderArrayCell: (text: any, col: ExtendedColumnType) => React.ReactNode; /** * 渲染文本填报列 */ export declare const renderInputCell: (text: any, col: ExtendedColumnType, record: any, options?: ApplyColumnRenderOptions) => React.ReactNode; /** * 渲染数值填报列 */ export declare const renderInputNumberCell: (text: any, col: ExtendedColumnType, record: any, options?: ApplyColumnRenderOptions) => React.ReactNode; /** * 渲染日期填报列:按 col.dateFormat 选 DatePicker / TimePicker / 带时分秒的 DatePicker * 回写为对应格式的字符串;与 renderInputCell 一样依赖 onCellValueChange 写回 store */ export declare const renderDateInputCell: (text: any, col: ExtendedColumnType, record: any, options?: ApplyColumnRenderOptions) => React.ReactNode; /** * 渲染上传填报列: * - antd Upload 最简模式:showUploadList=false;按 maxCount 控制上传按钮显隐 * - customRequest 复用 coreUpload;onChange 拿到 done 时写回 src 数组到 onCellValueChange * - 已有上传项时显示一个紧凑的「预览」入口;点击通过 runAction 派发命令交业务侧处理 */ export declare const renderUploadInputCell: (text: any, col: ExtendedColumnType, record: any, options?: ApplyColumnRenderOptions) => React.ReactNode; /** * 渲染选择填报列:复用 AndSelect 的「自定义 onChange」分支 * - 不绑 dataSet/dataSetField,不维护 _selected,不发 changeAction * - value 直接由 cell 的 text 提供;onChange 通过 onCellValueChange 写回所在行 * - 字典通过列上的 columnDictType 启用(与「数据字典」展示列共用同一字段) */ export declare const renderSelectInputCell: (text: any, col: ExtendedColumnType, record: any, options?: ApplyColumnRenderOptions) => React.ReactNode; /** * 渲染图标列:列配置固定图标;行字段为空时不展示;可配置点击派发事件 */ export declare const renderIconCell: (text: any, col: ExtendedColumnType, record: any, options?: ApplyColumnRenderOptions) => React.ReactNode; /** * 应用列格式化渲染: * - 列宽硬约束:只要 col.width 解析出像素宽度,就给 onCell/onHeaderCell 注入 max-width、 * min-width 与 width,避免分表模式下 header/body colgroup 不一致导致错列。 * - 自定义 ellipsis:勾选 ellipsis 的文本类列由我们自己包裹截断 + Tooltip,最后关闭 antd 原生 ellipsis。 */ export declare const applyColumnRendering: (col: ExtendedColumnType, options?: ApplyColumnRenderOptions) => ExtendedColumnType; //# sourceMappingURL=renderers.d.ts.map