Bug description
When a grid has min_row: 1 and has an asset field in that row, and the whole grid is conditionally hidden, hitting save causes the control panel to freeze with console errors.
I'm aware of #15427 just posed but wanted to report this as there are no default values being set. (Possibly the min_rows setting is equivalent to having a default value here?)
How to reproduce
It be reproduced with the following paired down blueprint
title: test
tabs:
main:
display: Main
sections:
-
fields:
-
handle: title
field:
type: text
required: true
validate:
- required
-
handle: radio_field
field:
options:
-
key: hide
value: Hide
-
key: show
value: Show
type: radio
default: hide
display: 'Radio Field'
-
handle: grid_field
field:
type: grid
display: 'Grid Field'
if:
radio_field: 'equals show'
min_rows: 1
fields:
-
handle: assets_field
field:
container: assets
type: assets
display: 'Assets Field'
Saving the entry works on first save, but then every save after that with the grid field hidden causes the control panel to freeze.
Saving with the grid field showing works.
Logs
Environment
Environment
Laravel Version: 13.30.1
PHP Version: 8.4.23
Composer Version: 2.10.2
Environment: local
Debug Mode: ENABLED
Maintenance Mode: OFF
Timezone: UTC
Locale: en
Cache
Config: NOT CACHED
Events: NOT CACHED
Routes: NOT CACHED
Views: CACHED
Drivers
Broadcasting: log
Cache: file
Database: sqlite
Logs: stack / single
Mail: log
Queue: sync
Session: file
Storage
public/storage: NOT LINKED
Statamic
Addons: 0
License Key: Not set
Sites: 1
Stache Watcher: Enabled (auto)
Static Caching: Disabled
Version: 6.31.0 Solo
➜ v6 herd php please support:details
Environment
Laravel Version: 13.30.1
PHP Version: 8.5.8
Composer Version: 2.10.2
Environment: local
Debug Mode: ENABLED
Maintenance Mode: OFF
Timezone: UTC
Locale: en
Cache
Config: NOT CACHED
Events: NOT CACHED
Routes: NOT CACHED
Views: CACHED
Drivers
Broadcasting: log
Cache: file
Database: sqlite
Logs: stack / single
Mail: log
Queue: sync
Session: file
Storage
public/storage: NOT LINKED
Statamic
Addons: 0
License Key: Not set
Sites: 1
Stache Watcher: Enabled (auto)
Static Caching: Disabled
Version: 6.31.0 Solo
Installation
Fresh statamic/statamic site via CLI
Additional details
No response
Bug description
When a grid has
min_row: 1and has anassetfield in that row, and the whole grid is conditionally hidden, hitting save causes the control panel to freeze with console errors.I'm aware of #15427 just posed but wanted to report this as there are no default values being set. (Possibly the
min_rowssetting is equivalent to having a default value here?)How to reproduce
It be reproduced with the following paired down blueprint
Saving the entry works on first save, but then every save after that with the grid field hidden causes the control panel to freeze.
Saving with the grid field showing works.
Logs
Environment
Installation
Fresh statamic/statamic site via CLI
Additional details
No response