/**
 * Materials feature 公共出口。
 *
 * 当前导出：
 *   - lib/*       — 纯函数 helper / 常量 / column 配置 / 日期范围解析
 *   - components/ — Materials 页面专用的子组件
 *
 * 后续 PR 计划继续抽：data 与 mutation 的 hooks、filter primitives、表格 section。
 */

export {
  ACCEPTED_TYPES,
  ACCEPTED_EXTENSIONS,
  MAX_FILE_SIZE_BYTES,
  PAGE_SIZE_OPTIONS,
  UPLOAD_SUCCESS_TOAST_OPTIONS,
} from './lib/constants';

export {
  MATERIAL_COLUMN_KEYS,
  MATERIAL_REQUIRED_COLUMN_KEYS,
  MATERIAL_COLUMN_STORAGE_KEY,
  getInitialMaterialColumnConfig,
} from './lib/columnConfig';

export {
  normalizeCompactDate,
  parseCreatedAtRange,
  toCompactDate,
  formatCreatedAtRangeValue,
  parseDateValue,
  formatDateForFilter,
} from './lib/dateRangeFilter';

export {
  renderUploadError,
  deriveMaterialName,
  isSpreadsheetFile,
  looksLikeUuid,
  isLocalDraftMaterial,
  matchesMaterialDeletionTarget,
  buildUploadedMaterialInput,
  getFileIcon,
} from './lib/materialHelpers';

export { MaterialDetailPanel } from './components/MaterialDetailPanel';
export { MaterialEditDialog } from './components/MaterialEditDialog';
export { MaterialFilterBar } from './components/MaterialFilterBar';
export { SourceFileViewDialog } from './components/SourceFileViewDialog';
export { StandardizeConfirmDialog } from './components/StandardizeConfirmDialog';

export { useMaterialsList } from './hooks/useMaterialsList';
export type { UseMaterialsListResult } from './hooks/useMaterialsList';
export {
  useFilteredMaterials,
  type MaterialFilterInputs,
  type MaterialSortDir,
} from './hooks/useFilteredMaterials';
export {
  useMaterialMutations,
  type UseMaterialMutationsOptions,
  type UploadMaterialMutationResult,
} from './hooks/useMaterialMutations';
