🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis →
Socket
Book a DemoInstallSign in
Socket

akamai-filerobot-converter

Package Overview
Dependencies
Maintainers
2
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

akamai-filerobot-converter

[![Release](https://img.shields.io/badge/release-v0.1.6-blue.svg)](https://github.com/scaleflex/akamai-filerobot-converter) [![Contributions welcome](https://img.shields.io/badge/contributions-welcome-orange.svg)](#contributing) [![License](https://img.

latest
npmnpm
Version
0.1.6
Version published
Maintainers
2
Created
Source

Release Contributions welcome License Scaleflex team

Learn more about Filerobot

Akamai to Filerobot Connector

Converts Akamai URl image transformation parameters to Filerobot and vice versa.

Installation

$ npm install --save akamai-filerobot-converter

Usage

There are two available methods: akamaiToFilerobot, filerobotToAkamai.

akamaiToFilerobot('<URL>?im=Rotate,degrees=50;BackgroundColor=00ff00')

// '<URL>?r=-50&bg_colour=00ff00'
filerobotToAkamai('<URL>?r=50&bg_colour=ff00ff')

// '<URL>?im=Rotate,degrees=-50;BackgroundColor,color=ff00ff'

Supported Options

Akamai to Filerobot

  • Rotate

    • syntax: [ImageURL]?im=Rotate,degrees=[number_of_degrees])
  • Auto Crop

    • syntax #1: [ImageURL]?im=Crop,width=[width_to_crop],height=[height_to_crop]

    • syntax #2: [ImageURL]?im=Crop,size=([width_to_crop],[height_to_crop]

  • Positionable Crop

    • syntax: [ImageURL]?im=Crop,rect=([xPostion],[yPosition],[width_to_crop],[height_to_crop])
  • Region of interest Crop

    • syntax: [ImageURL]?im=RegionOfInterestCrop,width=[value],height=[value],regionOfInterest=width=[value],height=[value]
  • Resize

    • syntax #1: [ImageURL]?im=Resize,width=[resized_width],height=[resized_height]

    • syntax #2: [ImageURL]?im=Resize=([resized_width],[resized_height])

    • syntax #3: [ImageURL]?im=Resize,width=[resized_width]

    • syntax #3: [ImageURL]?im=Resize,height=[resized_height]

  • Watermark

    • syntax minimum: [ImageURL]?im=Composite,image=(url=[url_to_the_image_text_or_shape])

    • syntax position: [ImageURL]?im=Composite,xPosition=[value],yPosition=[value],image=(url=[url_to_the_image_text_or_shape])

    • syntax scaling: [ImageURL]?im=Composite,scaleDimension=[height/width],scale=[value],image=(url=[url_to_the_image_text_or_shape])

  • Text Watermark

    • syntax minimum: [ImageURL]?im=Composite,image=(type=Text,text=[URL_encoded_string])

    • syntax position: [ImageURL]?im=Composite,xPosition=[value],yPosition=[value],gravity=[direction],image=(type=Text,text=[URL_encoded_string])

    • syntax scale and color : [ImageURL]?im=Composite,image=(type=Text,text=[URL_encoded_string],size=[font_size],fill=[hex_color_value])

  • Background Color

    • syntax: [ImageURL]?im=BackgroundColor,color=[hex_color_value]

Filerobot to Akamai

  • Rotate

    • syntax: [ImageURL]?r=[number_of_degrees])
  • Auto Crop

    • syntax #1: [ImageURL]?w=[width_to_crop]&h=[height_to_crop]
  • Positionable Crop

    • syntax: [ImageURL]?tl=[x1Position],[y1Position]&br[x2Position],[y2Position]
  • Region of interest Crop

    • syntax: [ImageURL]?w=[width_to_crop]&h=[height_to_crop]&gravity=[xPosition],[yPosition]
  • Resize

    • syntax #1: [ImageURL]?w=[resized_width]&h=[resized_height]

    • syntax #2: [ImageURL]?w=[resized_width]

    • syntax #3: [ImageURL]?h=[resized_height]

  • Watermark

    • syntax minimum: [ImageURL]?=wat=1&wat_url=[url_to_the_image_text_or_shape]

    • syntax position: [ImageURL]?=wat=1&wat_url=[url_to_the_image_text_or_shape]&wat_pad=[xPosition],[yPosition]&gravity=[direction]

    • syntax scaling: [ImageURL]?=wat=1&wat_url=[url_to_the_image_text_or_shape]&wat_scale=[scale_valuetion]

  • Text Watermark

    • syntax minimum: [ImageURL]?=wat=1&wat_text=[URL_encoded_string]

    • syntax position: [ImageURL]?=wat=1&wat_text=[URL_encoded_string]&wat_pad=[xPosition],[yPosition]&gravity=[direction]

    • syntax scaling and coloring: [ImageURL]?=wat=1&wat_text=[URL_encoded_string]&wat_fontsize=[font_size]&wat_color=[hex_color_value]

  • Background Color

    • syntax: [ImageURL]?bg_colour=[hex_color_value]

FAQs

Package last updated on 08 Sep 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts