[6.x] Addon settings' fields' default can't parse antlers
Bug description
I have a addon setting timezone:
I was hoping that the default could parse antlers and the config, but the above doesn't work:
How to reproduce
- have an addon setting field w/ a default w/ antlers:
Logs
Environment
Environment
Application Name: Statamic
Laravel Version: 12.35.1
PHP Version: 8.3.26
Composer Version: 2.8.11
Environment: local
Debug Mode: ENABLED
URL: events.test
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: 1
Sites: 1
Stache Watcher: Enabled (auto)
Static Caching: Disabled
Version: 6.0.0-alpha.14 Solo
Statamic Addons
transformstudios/events: dev-use-settings
Installation
Fresh statamic/statamic site via CLI
Additional details
No response
It won't parse the Antlers in the CP (because it opens a can of worms around what happens when you update the value, do we update the config/env/etc).
However, it will parse the Antlers when you attempt to get the value from the settings. Eg: $settings->get('timezone')
It won't parse the Antlers in the CP (because it opens a can of worms around what happens when you update the value, do we update the config/env/etc).
If it's antlers it should be read-only
Then, if you wanted to change the value to something else, you wouldn't be able to without manually editing the YAML file or the database.
It's handled the same way as sites - the env/config variables show in the CP, but they get evaluated everywhere else.