Configuration Options
The following table shows the properties available for the configuration object. For more details, take a look at Configuring the Query Builder the page.
|
Property |
Description |
|
Property: animate |
Speed of animations in the Query Builder (in milliseconds). |
|
Property: cancelButton
|
Adds or removes a cancel button on the stream creation interface. Tip: Set to false if you don't want your users to hide the Query Builder. |
|
Property: googleMapsApiKey |
Enter your Google Maps API Key here. Amongst other effects it allows you to monitor your Maps API usage. Highly advised. |
|
Property: mapsOverlay |
Object literal that is passed to all Google Maps overlay elements (rectangle box, circle and polygon) and is used to configure their visualization. Additional possible options are strokeColor and strokeOpacity. |
|
Property: mapsMarker |
Path of the marker icon used on the maps. This can be configured here since this cannot be styled in CSS and since on some websites/in some applications the relative URL may not work. In most cases the default should work out of the box. |
|
Property: hideTargets |
If you want to hide specific targets from the Query Builder you can pass them here as an Array of Strings. The targets in this array will not be visible in the Query Builder. This also applies to any „children” of these targets, for example if you hide „facebook”, all its fields will be hidden. Other examples are "twitter.author” or "twitter.retweet.author”. You can target whole data sources or their specific fields, e.g. „facebook.og.by”. Example input format: ['facebook.og', 'myspace', 'interaction.type'] |
|
Property: definition |
This option can be used to override any of the default JCSDLDefinition variables. See this section for more info. |
|
Property: save |
Function that is called on the 'save' event in the Query Builder, when a user clicks the 'Save and Preview' button. It's first (and only) argument is the resulting JCSDL code (a string). In the function, this keyword represents the Query Builder instance. |
|
Property: cancel Type: Function() Default: hides the Query Builder |
Function that is called on the 'cancel' event in the Query Builder, ie. when a user clicks the 'Cancel' button. It is called without any arguments. The keyword identifies the Query Builder instance. |
|
Property: change Type: Function() Default: (empty) |
Function called whenever a change in the editor occurs that may cause a change of JCSDL. |
|
Property: saveError Type: Function(error) Default: (empty) |
Function called whenever an error occurs during saving of the stream. |
|
Property: invalidJCSDL Type: Function(code) Default: (empty) |
Function called when invalid JCSDL is loaded into the editor. |
|
Property: viewModeChange Type: Function(mode) Default: (empty) |
Function called when user changes view mode of the main filters list. |
|
Property: filterNew Type: Function() Default: (empty) |
Function called when user clicks on "Add new filter". |
|
Property: filterEdit Type: Function(filter) Default: (empty) |
Function called when user starts to edit an existing filter. |
|
Property: filterDelete Type: Function(filter) Default: (empty) |
Function called when user deletes a filter. |
|
Property: filterSave Type: Function(filter) Default: (empty) |
Function called when user saves a filter. |
|
Property: filterCancel Type: Function(filter) Default: (empty) |
Function called when user cancels adding or editing a filter. |
|
Property: targetSelect Type: Function(target) Default: (empty) |
Function called when user selects a target. |
|
Property: operatorSelect Type: Function(operator) Default: (empty) |
Function called when user selects an operator. |
|
Property: caseSensitivityChange Type: Function(on) Default: (empty) |
Function called when user toggles case sensitivity in the filter editor. |
|
Property: logicChange Type: Function(logic) Default: (empty) |
Function called when user changes the logic of the stream. |
|
Property: logicError Type: Function(error) Default: (empty) |
Function called when there is an error in advanced logic expression. |
|
Property: advancedLogicChange Type: Function(expression) Default: (empty) |
Function called when there is a change in the advanced logic. |
|
Property: manualLogic Type: Function() Default: (empty) |
Function called when user opens manual advanced logic editor. |
|
Property: manualLogicChange Type: Function(expression) Default: (empty) |
Function called when user changes something inside the manual advanced logic editor. |
|
Property: graphicalLogic Type: Function() Default: (empty) |
Function called when user opens graphical advanced logic editor. |
|
Property: graphicalLogicChange Type: Function(expression) Default: (empty) |
Function called when user changes something inside the graphical advanced logic editor. |
|
Property: graphicalLogicTokenMove Type: Function(expression) Default: (empty) |
Function called when user moves a token or tile inside the graphical advanced logic editor. |
|
Property: parenthesisAdd Type: Function(expression) Default: (empty) |
Function called when user adds parenthesis to the graphical advanced logic editor. |
|
Property: parenthesisDelete Type: Function(expression) Default: (empty) |
Function called when user deletes parenthesis from the graphical advanced logic editor. |
|
Property: logicOperatorSwitch Type: Function(expression) Default: (empty) |
Function called when user switches a logic operator tile from AND to OR or other way around inside the graphical advanced logic editor. |
