cms icon indicating copy to clipboard operation
cms copied to clipboard

Selected syntax/language doesn't get saved in code field inside Bard

Open joshuablum opened this issue 9 months ago • 0 comments

Bug description

When you have a code field as a set inside of a bard field and select a different syntax/language than the default and save it, it doesn't save the selection but jumps back to the default. Works fine with a non-bard code field.

How to reproduce

  1. Create a bard field
  2. Add a code field set to it
  3. Select a default mode like PHP
  4. Edit an entry with the updated blueprint and select a different language than the default, like Markdown
  5. Save the entry
  6. See that the language mode is PHP instead of Markdown

Logs

No response

Environment

Environment
Application Name: Statamic
Laravel Version: 11.7.0
PHP Version: 8.3.6
Composer Version: 2.7.6
Environment: local
Debug Mode: ENABLED
URL: sandbox.test
Maintenance Mode: OFF

Cache
Config: NOT CACHED
Events: NOT CACHED
Routes: NOT CACHED
Views: CACHED

Drivers
Broadcasting: log
Cache: statamic
Database: sqlite
Logs: stack / single
Mail: log
Queue: sync
Session: file

Statamic
Addons: 0
Sites: 1
Stache Watcher: Enabled
Static Caching: Disabled
Version: 5.2.0 Pro

Installation

Fresh statamic/statamic site via CLI

Additional details

No response

joshuablum avatar May 17 '24 11:05 joshuablum