TCsvEditor constructor

const TCsvEditor({
  1. Key? key,
  2. required List<TCsvColumn> columns,
  3. List<Map<String, dynamic>>? initialData,
  4. Future<void> onSave(
    1. List<Map<String, dynamic>> data
    )?,
  5. ValueChanged<List<Map<String, dynamic>>>? onDataChanged,
  6. String? title = 'CSV Data Editor',
  7. String? subtitle = 'Upload a CSV file or add rows manually to review and edit data.',
  8. String saveButtonText = 'Upload Data',
  9. IconData saveButtonIcon = Icons.cloud_upload_outlined,
  10. bool showDownloadTemplate = true,
  11. bool showExport = true,
  12. bool allowAddRow = true,
  13. bool allowDeleteRow = true,
  14. bool allowDuplicateRow = true,
  15. bool allowPaste = true,
  16. bool autoPromptMappingOnDiff = true,
  17. TCsvEditorTheme? theme,
  18. int itemsPerPage = 20,
})

Implementation

const TCsvEditor({
  super.key,
  required this.columns,
  this.initialData,
  this.onSave,
  this.onDataChanged,
  this.title = 'CSV Data Editor',
  this.subtitle = 'Upload a CSV file or add rows manually to review and edit data.',
  this.saveButtonText = 'Upload Data',
  this.saveButtonIcon = Icons.cloud_upload_outlined,
  this.showDownloadTemplate = true,
  this.showExport = true,
  this.allowAddRow = true,
  this.allowDeleteRow = true,
  this.allowDuplicateRow = true,
  this.allowPaste = true,
  this.autoPromptMappingOnDiff = true,
  this.theme,
  this.itemsPerPage = 20,
});