services:
  _defaults:
    public: true

  prestashop.adapter.image.uploader.category_cover_image_uploader:
    class: 'PrestaShop\PrestaShop\Adapter\Image\Uploader\CategoryCoverImageUploader'

  prestashop.adapter.image.uploader.category_thumbnail_image_uploader:
    class: 'PrestaShop\PrestaShop\Adapter\Image\Uploader\CategoryThumbnailImageUploader'

  prestashop.adapter.image.uploader.category_menu_thumbnail_image_uploader:
    class: 'PrestaShop\PrestaShop\Adapter\Image\Uploader\CategoryMenuThumbnailUploader'
    arguments:
      - '@prestashop.adapter.cache.clearer.smarty_cache_clearer'

  prestashop.adapter.image.uploader.employee_image_uploader:
    class: 'PrestaShop\PrestaShop\Adapter\Image\Uploader\EmployeeImageUploader'
    arguments:
      - !php/const _PS_EMPLOYEE_IMG_DIR_
      - !php/const _PS_TMP_IMG_DIR_

  prestashop.adapter.image.uploader.profile_image_uploader:
    class: 'PrestaShop\PrestaShop\Adapter\Image\Uploader\ProfileImageUploader'
    arguments:
      - !php/const _PS_PROFILE_IMG_DIR_
      - !php/const _PS_TMP_IMG_DIR_

  prestashop.adapter.image.uploader.manufacturer_image_uploader:
    class: 'PrestaShop\PrestaShop\Adapter\Image\Uploader\ManufacturerImageUploader'

  prestashop.adapter.image.uploader.supplier_image_uploader:
    class: 'PrestaShop\PrestaShop\Adapter\Image\Uploader\SupplierImageUploader'

  PrestaShop\PrestaShop\Adapter\Image\ImageGenerator:
    arguments:
      - '@prestashop.core.admin.feature_flag.repository'
      - '@PrestaShop\PrestaShop\Core\Image\ImageFormatConfiguration'

  PrestaShop\PrestaShop\Adapter\Image\ImageValidator:
    arguments:
      - '@=service("prestashop.core.configuration.upload_size_configuration").getMaxUploadSizeInBytes()'

  PrestaShop\PrestaShop\Adapter\Image\ProductImageFileValidator:
    arguments:
      - '@=service("prestashop.core.configuration.upload_size_configuration").getMaxUploadSizeInBytes()'
      - '@prestashop.adapter.upload_quota.configuration'

  prestashop.adapter.image.image_validator:
    alias: PrestaShop\PrestaShop\Adapter\Image\ImageValidator
    deprecated: ~

  prestashop.adapter.image.category_image_path_factory:
    class: 'PrestaShop\PrestaShop\Adapter\Image\ImagePathFactory'
    arguments:
      - '@=service("prestashop.adapter.shop.url.category_image_folder_provider").getUrl()'
