imagekitio 4.4.1 → 4.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -288,6 +288,12 @@ module Imagekitio
288
288
  sig { params(aperture_value: Float).void }
289
289
  attr_writer :aperture_value
290
290
 
291
+ sig { returns(T.nilable(Float)) }
292
+ attr_reader :brightness_value
293
+
294
+ sig { params(brightness_value: Float).void }
295
+ attr_writer :brightness_value
296
+
291
297
  sig { returns(T.nilable(Integer)) }
292
298
  attr_reader :color_space
293
299
 
@@ -372,12 +378,18 @@ module Imagekitio
372
378
  sig { params(f_number: Float).void }
373
379
  attr_writer :f_number
374
380
 
375
- sig { returns(T.nilable(Integer)) }
381
+ sig { returns(T.nilable(Float)) }
376
382
  attr_reader :focal_length
377
383
 
378
- sig { params(focal_length: Integer).void }
384
+ sig { params(focal_length: Float).void }
379
385
  attr_writer :focal_length
380
386
 
387
+ sig { returns(T.nilable(Integer)) }
388
+ attr_reader :focal_length_in35mm_format
389
+
390
+ sig { params(focal_length_in35mm_format: Integer).void }
391
+ attr_writer :focal_length_in35mm_format
392
+
381
393
  sig { returns(T.nilable(Integer)) }
382
394
  attr_reader :focal_plane_resolution_unit
383
395
 
@@ -408,6 +420,24 @@ module Imagekitio
408
420
  sig { params(iso: Integer).void }
409
421
  attr_writer :iso
410
422
 
423
+ sig { returns(T.nilable(String)) }
424
+ attr_reader :lens_model
425
+
426
+ sig { params(lens_model: String).void }
427
+ attr_writer :lens_model
428
+
429
+ sig { returns(T.nilable(Integer)) }
430
+ attr_reader :light_source
431
+
432
+ sig { params(light_source: Integer).void }
433
+ attr_writer :light_source
434
+
435
+ sig { returns(T.nilable(Float)) }
436
+ attr_reader :max_aperture_value
437
+
438
+ sig { params(max_aperture_value: Float).void }
439
+ attr_writer :max_aperture_value
440
+
411
441
  sig { returns(T.nilable(Integer)) }
412
442
  attr_reader :metering_mode
413
443
 
@@ -420,6 +450,18 @@ module Imagekitio
420
450
  sig { params(scene_capture_type: Integer).void }
421
451
  attr_writer :scene_capture_type
422
452
 
453
+ sig { returns(T.nilable(String)) }
454
+ attr_reader :scene_type
455
+
456
+ sig { params(scene_type: String).void }
457
+ attr_writer :scene_type
458
+
459
+ sig { returns(T.nilable(Integer)) }
460
+ attr_reader :sensing_method
461
+
462
+ sig { params(sensing_method: Integer).void }
463
+ attr_writer :sensing_method
464
+
423
465
  sig { returns(T.nilable(Float)) }
424
466
  attr_reader :shutter_speed_value
425
467
 
@@ -432,6 +474,12 @@ module Imagekitio
432
474
  sig { params(sub_sec_time: String).void }
433
475
  attr_writer :sub_sec_time
434
476
 
477
+ sig { returns(T.nilable(String)) }
478
+ attr_reader :user_comment
479
+
480
+ sig { params(user_comment: String).void }
481
+ attr_writer :user_comment
482
+
435
483
  sig { returns(T.nilable(Integer)) }
436
484
  attr_reader :white_balance
437
485
 
@@ -442,6 +490,7 @@ module Imagekitio
442
490
  sig do
443
491
  params(
444
492
  aperture_value: Float,
493
+ brightness_value: Float,
445
494
  color_space: Integer,
446
495
  create_date: String,
447
496
  custom_rendered: Integer,
@@ -456,21 +505,29 @@ module Imagekitio
456
505
  flash: Integer,
457
506
  flashpix_version: String,
458
507
  f_number: Float,
459
- focal_length: Integer,
508
+ focal_length: Float,
509
+ focal_length_in35mm_format: Integer,
460
510
  focal_plane_resolution_unit: Integer,
461
511
  focal_plane_x_resolution: Float,
462
512
  focal_plane_y_resolution: Float,
463
513
  interop_offset: Integer,
464
514
  iso: Integer,
515
+ lens_model: String,
516
+ light_source: Integer,
517
+ max_aperture_value: Float,
465
518
  metering_mode: Integer,
466
519
  scene_capture_type: Integer,
520
+ scene_type: String,
521
+ sensing_method: Integer,
467
522
  shutter_speed_value: Float,
468
523
  sub_sec_time: String,
524
+ user_comment: String,
469
525
  white_balance: Integer
470
526
  ).returns(T.attached_class)
471
527
  end
472
528
  def self.new(
473
529
  aperture_value: nil,
530
+ brightness_value: nil,
474
531
  color_space: nil,
475
532
  create_date: nil,
476
533
  custom_rendered: nil,
@@ -486,15 +543,22 @@ module Imagekitio
486
543
  flashpix_version: nil,
487
544
  f_number: nil,
488
545
  focal_length: nil,
546
+ focal_length_in35mm_format: nil,
489
547
  focal_plane_resolution_unit: nil,
490
548
  focal_plane_x_resolution: nil,
491
549
  focal_plane_y_resolution: nil,
492
550
  interop_offset: nil,
493
551
  iso: nil,
552
+ lens_model: nil,
553
+ light_source: nil,
554
+ max_aperture_value: nil,
494
555
  metering_mode: nil,
495
556
  scene_capture_type: nil,
557
+ scene_type: nil,
558
+ sensing_method: nil,
496
559
  shutter_speed_value: nil,
497
560
  sub_sec_time: nil,
561
+ user_comment: nil,
498
562
  white_balance: nil
499
563
  )
500
564
  end
@@ -503,6 +567,7 @@ module Imagekitio
503
567
  override.returns(
504
568
  {
505
569
  aperture_value: Float,
570
+ brightness_value: Float,
506
571
  color_space: Integer,
507
572
  create_date: String,
508
573
  custom_rendered: Integer,
@@ -517,16 +582,23 @@ module Imagekitio
517
582
  flash: Integer,
518
583
  flashpix_version: String,
519
584
  f_number: Float,
520
- focal_length: Integer,
585
+ focal_length: Float,
586
+ focal_length_in35mm_format: Integer,
521
587
  focal_plane_resolution_unit: Integer,
522
588
  focal_plane_x_resolution: Float,
523
589
  focal_plane_y_resolution: Float,
524
590
  interop_offset: Integer,
525
591
  iso: Integer,
592
+ lens_model: String,
593
+ light_source: Integer,
594
+ max_aperture_value: Float,
526
595
  metering_mode: Integer,
527
596
  scene_capture_type: Integer,
597
+ scene_type: String,
598
+ sensing_method: Integer,
528
599
  shutter_speed_value: Float,
529
600
  sub_sec_time: String,
601
+ user_comment: String,
530
602
  white_balance: Integer
531
603
  }
532
604
  )
@@ -544,6 +616,66 @@ module Imagekitio
544
616
  )
545
617
  end
546
618
 
619
+ sig { returns(T.nilable(Float)) }
620
+ attr_reader :gps_altitude
621
+
622
+ sig { params(gps_altitude: Float).void }
623
+ attr_writer :gps_altitude
624
+
625
+ sig { returns(T.nilable(Integer)) }
626
+ attr_reader :gps_altitude_ref
627
+
628
+ sig { params(gps_altitude_ref: Integer).void }
629
+ attr_writer :gps_altitude_ref
630
+
631
+ sig { returns(T.nilable(String)) }
632
+ attr_reader :gps_date_stamp
633
+
634
+ sig { params(gps_date_stamp: String).void }
635
+ attr_writer :gps_date_stamp
636
+
637
+ sig { returns(T.nilable(Float)) }
638
+ attr_reader :gps_img_direction
639
+
640
+ sig { params(gps_img_direction: Float).void }
641
+ attr_writer :gps_img_direction
642
+
643
+ sig { returns(T.nilable(String)) }
644
+ attr_reader :gps_img_direction_ref
645
+
646
+ sig { params(gps_img_direction_ref: String).void }
647
+ attr_writer :gps_img_direction_ref
648
+
649
+ sig { returns(T.nilable(T::Array[Float])) }
650
+ attr_reader :gps_latitude
651
+
652
+ sig { params(gps_latitude: T::Array[Float]).void }
653
+ attr_writer :gps_latitude
654
+
655
+ sig { returns(T.nilable(String)) }
656
+ attr_reader :gps_latitude_ref
657
+
658
+ sig { params(gps_latitude_ref: String).void }
659
+ attr_writer :gps_latitude_ref
660
+
661
+ sig { returns(T.nilable(T::Array[Float])) }
662
+ attr_reader :gps_longitude
663
+
664
+ sig { params(gps_longitude: T::Array[Float]).void }
665
+ attr_writer :gps_longitude
666
+
667
+ sig { returns(T.nilable(String)) }
668
+ attr_reader :gps_longitude_ref
669
+
670
+ sig { params(gps_longitude_ref: String).void }
671
+ attr_writer :gps_longitude_ref
672
+
673
+ sig { returns(T.nilable(T::Array[Float])) }
674
+ attr_reader :gps_time_stamp
675
+
676
+ sig { params(gps_time_stamp: T::Array[Float]).void }
677
+ attr_writer :gps_time_stamp
678
+
547
679
  sig { returns(T.nilable(T::Array[Integer])) }
548
680
  attr_reader :gps_version_id
549
681
 
@@ -552,12 +684,52 @@ module Imagekitio
552
684
 
553
685
  # Object containing GPS information.
554
686
  sig do
555
- params(gps_version_id: T::Array[Integer]).returns(T.attached_class)
687
+ params(
688
+ gps_altitude: Float,
689
+ gps_altitude_ref: Integer,
690
+ gps_date_stamp: String,
691
+ gps_img_direction: Float,
692
+ gps_img_direction_ref: String,
693
+ gps_latitude: T::Array[Float],
694
+ gps_latitude_ref: String,
695
+ gps_longitude: T::Array[Float],
696
+ gps_longitude_ref: String,
697
+ gps_time_stamp: T::Array[Float],
698
+ gps_version_id: T::Array[Integer]
699
+ ).returns(T.attached_class)
556
700
  end
557
- def self.new(gps_version_id: nil)
701
+ def self.new(
702
+ gps_altitude: nil,
703
+ gps_altitude_ref: nil,
704
+ gps_date_stamp: nil,
705
+ gps_img_direction: nil,
706
+ gps_img_direction_ref: nil,
707
+ gps_latitude: nil,
708
+ gps_latitude_ref: nil,
709
+ gps_longitude: nil,
710
+ gps_longitude_ref: nil,
711
+ gps_time_stamp: nil,
712
+ gps_version_id: nil
713
+ )
558
714
  end
559
715
 
560
- sig { override.returns({ gps_version_id: T::Array[Integer] }) }
716
+ sig do
717
+ override.returns(
718
+ {
719
+ gps_altitude: Float,
720
+ gps_altitude_ref: Integer,
721
+ gps_date_stamp: String,
722
+ gps_img_direction: Float,
723
+ gps_img_direction_ref: String,
724
+ gps_latitude: T::Array[Float],
725
+ gps_latitude_ref: String,
726
+ gps_longitude: T::Array[Float],
727
+ gps_longitude_ref: String,
728
+ gps_time_stamp: T::Array[Float],
729
+ gps_version_id: T::Array[Integer]
730
+ }
731
+ )
732
+ end
561
733
  def to_hash
562
734
  end
563
735
  end
@@ -571,6 +743,18 @@ module Imagekitio
571
743
  )
572
744
  end
573
745
 
746
+ sig { returns(T.nilable(String)) }
747
+ attr_reader :artist
748
+
749
+ sig { params(artist: String).void }
750
+ attr_writer :artist
751
+
752
+ sig { returns(T.nilable(String)) }
753
+ attr_reader :copyright
754
+
755
+ sig { params(copyright: String).void }
756
+ attr_writer :copyright
757
+
574
758
  sig { returns(T.nilable(Integer)) }
575
759
  attr_reader :exif_offset
576
760
 
@@ -583,6 +767,12 @@ module Imagekitio
583
767
  sig { params(gps_info: Integer).void }
584
768
  attr_writer :gps_info
585
769
 
770
+ sig { returns(T.nilable(String)) }
771
+ attr_reader :image_description
772
+
773
+ sig { params(image_description: String).void }
774
+ attr_writer :image_description
775
+
586
776
  sig { returns(T.nilable(String)) }
587
777
  attr_reader :make
588
778
 
@@ -619,10 +809,10 @@ module Imagekitio
619
809
  sig { params(software: String).void }
620
810
  attr_writer :software
621
811
 
622
- sig { returns(T.nilable(Integer)) }
812
+ sig { returns(T.nilable(Float)) }
623
813
  attr_reader :x_resolution
624
814
 
625
- sig { params(x_resolution: Integer).void }
815
+ sig { params(x_resolution: Float).void }
626
816
  attr_writer :x_resolution
627
817
 
628
818
  sig { returns(T.nilable(Integer)) }
@@ -631,31 +821,37 @@ module Imagekitio
631
821
  sig { params(y_cb_cr_positioning: Integer).void }
632
822
  attr_writer :y_cb_cr_positioning
633
823
 
634
- sig { returns(T.nilable(Integer)) }
824
+ sig { returns(T.nilable(Float)) }
635
825
  attr_reader :y_resolution
636
826
 
637
- sig { params(y_resolution: Integer).void }
827
+ sig { params(y_resolution: Float).void }
638
828
  attr_writer :y_resolution
639
829
 
640
830
  # Object containing EXIF image information.
641
831
  sig do
642
832
  params(
833
+ artist: String,
834
+ copyright: String,
643
835
  exif_offset: Integer,
644
836
  gps_info: Integer,
837
+ image_description: String,
645
838
  make: String,
646
839
  model: String,
647
840
  modify_date: String,
648
841
  orientation: Integer,
649
842
  resolution_unit: Integer,
650
843
  software: String,
651
- x_resolution: Integer,
844
+ x_resolution: Float,
652
845
  y_cb_cr_positioning: Integer,
653
- y_resolution: Integer
846
+ y_resolution: Float
654
847
  ).returns(T.attached_class)
655
848
  end
656
849
  def self.new(
850
+ artist: nil,
851
+ copyright: nil,
657
852
  exif_offset: nil,
658
853
  gps_info: nil,
854
+ image_description: nil,
659
855
  make: nil,
660
856
  model: nil,
661
857
  modify_date: nil,
@@ -671,17 +867,20 @@ module Imagekitio
671
867
  sig do
672
868
  override.returns(
673
869
  {
870
+ artist: String,
871
+ copyright: String,
674
872
  exif_offset: Integer,
675
873
  gps_info: Integer,
874
+ image_description: String,
676
875
  make: String,
677
876
  model: String,
678
877
  modify_date: String,
679
878
  orientation: Integer,
680
879
  resolution_unit: Integer,
681
880
  software: String,
682
- x_resolution: Integer,
881
+ x_resolution: Float,
683
882
  y_cb_cr_positioning: Integer,
684
- y_resolution: Integer
883
+ y_resolution: Float
685
884
  }
686
885
  )
687
886
  end
@@ -759,16 +958,16 @@ module Imagekitio
759
958
  sig { params(thumbnail_offset: Integer).void }
760
959
  attr_writer :thumbnail_offset
761
960
 
762
- sig { returns(T.nilable(Integer)) }
961
+ sig { returns(T.nilable(Float)) }
763
962
  attr_reader :x_resolution
764
963
 
765
- sig { params(x_resolution: Integer).void }
964
+ sig { params(x_resolution: Float).void }
766
965
  attr_writer :x_resolution
767
966
 
768
- sig { returns(T.nilable(Integer)) }
967
+ sig { returns(T.nilable(Float)) }
769
968
  attr_reader :y_resolution
770
969
 
771
- sig { params(y_resolution: Integer).void }
970
+ sig { params(y_resolution: Float).void }
772
971
  attr_writer :y_resolution
773
972
 
774
973
  # Object containing Thumbnail information.
@@ -778,8 +977,8 @@ module Imagekitio
778
977
  resolution_unit: Integer,
779
978
  thumbnail_length: Integer,
780
979
  thumbnail_offset: Integer,
781
- x_resolution: Integer,
782
- y_resolution: Integer
980
+ x_resolution: Float,
981
+ y_resolution: Float
783
982
  ).returns(T.attached_class)
784
983
  end
785
984
  def self.new(
@@ -799,8 +998,8 @@ module Imagekitio
799
998
  resolution_unit: Integer,
800
999
  thumbnail_length: Integer,
801
1000
  thumbnail_offset: Integer,
802
- x_resolution: Integer,
803
- y_resolution: Integer
1001
+ x_resolution: Float,
1002
+ y_resolution: Float
804
1003
  }
805
1004
  )
806
1005
  end
@@ -198,6 +198,19 @@ module Imagekitio
198
198
  sig { params(border: String).void }
199
199
  attr_writer :border
200
200
 
201
+ # Applies a color tint to the image. Accepts color and intensity as optional
202
+ # parameters.
203
+ #
204
+ # - `co-color` - Color to apply (e.g., `red`, `blue`, `FF0022`). Default is gray
205
+ # color.
206
+ # - `in-intensity` - Intensity of the color (0-100). Default is 35. See
207
+ # [Colorize](https://imagekit.io/docs/effects-and-enhancements#colorize---e-colorize).
208
+ sig { returns(T.nilable(String)) }
209
+ attr_reader :colorize
210
+
211
+ sig { params(colorize: String).void }
212
+ attr_writer :colorize
213
+
201
214
  # Indicates whether the output image should retain the original color profile. See
202
215
  # [Color profile](https://imagekit.io/docs/image-optimization#color-profile---cp).
203
216
  sig { returns(T.nilable(T::Boolean)) }
@@ -664,6 +677,7 @@ module Imagekitio
664
677
  background: String,
665
678
  blur: Float,
666
679
  border: String,
680
+ colorize: String,
667
681
  color_profile: T::Boolean,
668
682
  color_replace: String,
669
683
  contrast_stretch:
@@ -785,6 +799,14 @@ module Imagekitio
785
799
  # expression like `ih_div_20_FF00FF`. See
786
800
  # [Border](https://imagekit.io/docs/effects-and-enhancements#border---b).
787
801
  border: nil,
802
+ # Applies a color tint to the image. Accepts color and intensity as optional
803
+ # parameters.
804
+ #
805
+ # - `co-color` - Color to apply (e.g., `red`, `blue`, `FF0022`). Default is gray
806
+ # color.
807
+ # - `in-intensity` - Intensity of the color (0-100). Default is 35. See
808
+ # [Colorize](https://imagekit.io/docs/effects-and-enhancements#colorize---e-colorize).
809
+ colorize: nil,
788
810
  # Indicates whether the output image should retain the original color profile. See
789
811
  # [Color profile](https://imagekit.io/docs/image-optimization#color-profile---cp).
790
812
  color_profile: nil,
@@ -998,6 +1020,7 @@ module Imagekitio
998
1020
  background: String,
999
1021
  blur: Float,
1000
1022
  border: String,
1023
+ colorize: String,
1001
1024
  color_profile: T::Boolean,
1002
1025
  color_replace: String,
1003
1026
  contrast_stretch:
@@ -1285,6 +1308,11 @@ module Imagekitio
1285
1308
  T.let(:at_least, Imagekitio::Transformation::Crop::TaggedSymbol)
1286
1309
  MAINTAIN_RATIO =
1287
1310
  T.let(:maintain_ratio, Imagekitio::Transformation::Crop::TaggedSymbol)
1311
+ MAINTAIN_RATIO_NO_ENLARGE =
1312
+ T.let(
1313
+ :maintain_ratio_no_enlarge,
1314
+ Imagekitio::Transformation::Crop::TaggedSymbol
1315
+ )
1288
1316
 
1289
1317
  sig do
1290
1318
  override.returns(
@@ -1313,6 +1341,16 @@ module Imagekitio
1313
1341
  :pad_extract,
1314
1342
  Imagekitio::Transformation::CropMode::TaggedSymbol
1315
1343
  )
1344
+ PAD_RESIZE_NO_ENLARGE =
1345
+ T.let(
1346
+ :pad_resize_no_enlarge,
1347
+ Imagekitio::Transformation::CropMode::TaggedSymbol
1348
+ )
1349
+ PAD_EXTRACT_NO_SHRINK =
1350
+ T.let(
1351
+ :pad_extract_no_shrink,
1352
+ Imagekitio::Transformation::CropMode::TaggedSymbol
1353
+ )
1316
1354
 
1317
1355
  sig do
1318
1356
  override.returns(