igorkasyanchuk/active_storage_validations
Do it like => validates :photos, attached: true, content_type: ['image/png', 'image/jpg', 'image/jpeg'], size: { less_than: 500.kilobytes }, limit: { min: 1, max: 3 }, aspect_ratio: :landscape, dimension: { width: { in: 800..1600 }
RubyMIT
Issues
- 9
- 0
Add validators for audio & video
#255 opened by Mth0158 - 0
Refactor the `metadata.rb` using built-in `ActiveStorage::Analyzer::ImageAnalyzer::ImageMagick/Vips.new(blob).metadata`
#254 opened by Mth0158 - 4
"Skipping image analysis because ImageMagick or Vips doesn't support the file" when using open-uri to import images
#189 opened by olbrich - 2
Validation fails when attached using io URI open
#154 opened by gryphon - 3
- 4
Passing :allow_blank option raises
#243 opened by joelmoss - 3
Not working with not-yet-persisted blobs
#242 opened by marckohlbrugge - 3
Dimensions validations on saved attachment
#193 opened by gaelchriste - 5
.ino files seem to be ignored
#239 opened by vnguyen13 - 7
Matchers - Add matchers for all validators
#211 opened by Mth0158 - 5
Size `less_than` depending content type
#177 opened by GesJeremie - 5
- 12
Problem with conditional validations
#234 opened by sergiopatricio - 1
Adapt code to remove warning for Rails 7.1
#222 opened by Mth0158 - 0
Add support for multiple aspect ratios
#230 opened by Mth0158 - 0
- 0
Make sure a zero byte image is properly managed
#231 opened by Mth0158 - 2
Add filename to error message
#212 opened by tanaylakhani - 0
Add allow_nil, allow_blank methods to our matchers
#224 opened by Mth0158 - 0
Add tests to limit validator
#227 opened by Mth0158 - 0
Add a validity check on content_type validator
#225 opened by Mth0158 - 2
Aspect Ratio generally includes a ':', not a 'x'
#160 opened by yarmiganosca - 5
Dimension of videos are not validated
#190 opened by mikefranken - 4
- 2
Wrong More Examples section in README.md
#200 opened by pozabil - 0
Add a :on method on our test matchers
#215 opened by Mth0158 - 4
- 2
- 5
Unknown validator: 'ContentTypeValidator' error
#147 opened by SamihaFansur - 1
1.1.2 release is breaking
#216 opened by aditya-cherukuri - 9
"foobar is not a valid image" for valid image (error only in production)
#170 opened by marckohlbrugge - 1
- 0
Translation missing for `image_not_processable`
#204 opened by ocarreterom - 0
ActiveRecord::Base subclass requirement
#207 opened by dvodvo - 6
Existing specs started failing after upgrade to 1.1.0. Probably an issue with the matcher
#201 opened by tagliala - 0
- 2
Your website is down it looks like
#194 opened by dorianmariecom - 1
Known Issue
#175 opened by limitlessmind - 0
- 0
NoMethodError: undefined method `attached?' for <#Attachment> with nested records
#186 opened by marckohlbrugge - 1
Validate files uploaded in rich_text (trix)
#182 opened by 2c84cdd8 - 1
[Validations] Validations fail when using dimension: { min: 1080..1080 } syntax
#163 opened by Mth0158 - 3
if and unless conditions broken on 1.0.0
#171 opened by daan-b - 1
Some video examples in the readme
#159 opened by stevecondylios - 3
Conditional validation not working
#166 opened by kukicola - 0
Conditional validation not working
#165 opened by kukicola - 2
Release 0.9.8 (or so)
#155 opened by kronn - 3
Push release tags
#156 opened by tagliala - 1