AreaSelector

Widget that allows a user to "pick" a CSS selector on a given website.

Example
define([
  "blueconic/api/widgets/selector/AreaSelector"
], function(AreaSelector) {
  var areaSelector = new AreaSelector();
  // ...
});

Properties

constraints String

Optional CSS selector that determines which HTML elements can be selected.
E.g. 'input,textarea' only allows text inputs and textareas to be selected.

selector String

The CSS selector to open the AreaSelector with.

url String

The URL to open the AreaSelector with, e.g. http://www.blueconic.com.
When not specified, it will determine the URL itself.

Events

onSelect(selector, url)

Event which is called when an area is selected using the visual picker.

Name Type Description
selector String

The CSS selector which identifies the area.

url String

URL on which the area is selected.