mirror of
https://github.com/baserow/baserow.git
synced 2026-12-04 08:18:42 +00:00
11 lines
396 B
JavaScript
11 lines
396 B
JavaScript
import { filterVisibleFieldsFunction } from '@baserow/modules/database/utils/view'
|
|
|
|
/**
|
|
* In the grid view, the primary field is always rendered even when its field
|
|
* options mark it as hidden.
|
|
*/
|
|
export function filterGridViewVisibleFieldsFunction(fieldOptions) {
|
|
const isFieldVisible = filterVisibleFieldsFunction(fieldOptions)
|
|
return (field) => field.primary || isFieldVisible(field)
|
|
}
|