mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-25 12:55:00 +08:00
This commit adds an API `upload_image` to `FormKitField` page object for setting an image file on an `Image` field in FormKit. Usage is like this:
```ruby
form.field("image_field").upload_image(image_path)
```
The `value` API also now supports `Image` fields; it returns an `Upload` record if the field has an uploaded image.
|
||
|---|---|---|
| .. | ||
| components | ||
| modals | ||
| pages | ||
| admin_backups.rb | ||
| admin_badges.rb | ||
| admin_badges_groupings.rb | ||
| admin_user_badges.rb | ||
| cdp.rb | ||