feat(search): add search history functionality with dropdown and persistence
- Implement SearchHistoryDropdown component for displaying recent searches - Add useSearchHistory hook for managing search history in localStorage - Integrate search history into SearchOverlay for user convenience - Update GridToolbar to support filter presets - Enhance SearchOverlay with close button and history display
This commit is contained in:
@@ -52,6 +52,18 @@ function mapSingleColumn<T>(col: GriddyColumn<T>): ColumnDef<T> {
|
||||
} else if (col.filterable) {
|
||||
def.filterFn = createOperatorFilter()
|
||||
}
|
||||
|
||||
if (col.renderer) {
|
||||
const renderer = col.renderer
|
||||
def.cell = (info) => renderer({
|
||||
column: col,
|
||||
columnIndex: info.cell.column.getIndex(),
|
||||
row: info.row.original,
|
||||
rowIndex: info.row.index,
|
||||
value: info.getValue(),
|
||||
})
|
||||
}
|
||||
|
||||
return def
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user