PageSourceSearch

https://www.muma-lehavre.fr/sites/all/modules/contrib/scald/scald/…/scald_image/scald_image.js?t9ml9t

js muma-lehavre.fr collected 2026-10-02 10:00:37 UTC 2,358 bytes, 61 lines download raw bytes

1(function ($) {
2  Drupal.behaviors.scaldImage = {
3    attach: function (context, settings) {
4      if (typeof Drupal.dndck4 !== 'undefined') {
5        Drupal.dndck4.addOption('txtLink', 'image', 'atom', 'scald_image', function (infoTab, dialogDefinition) {
6          infoTab.add({
7            id: 'txtLink',
8            type: 'text',
9            label: Drupal.t('Link'),
10            // "Link" edits the 'link' property in the options JSON string.
11            setup: function (widget) {
12              var options = JSON.parse(widget.data.options);
13              if (options.link) {
14                this.setValue(decodeURIComponent(options.link));
15              }
16            },
17            commit: function (widget) {
18              // Copy the current options into a new object,
19              var options = JSON.parse(widget.data.options);
20              var value = this.getValue();
21              if (value != '') {
22                options.link = encodeURIComponent(value);
23              }
24              else {
25                delete options.link;
26              }
27              widget.setData('options', JSON.stringify(options));
28            }
29          });
30        });
31        Drupal.dndck4.addOption('cmbLinkTarget', 'image', 'atom', 'scald_image', function (infoTab, dialogDefinition) {
32          infoTab.add({
33            id: 'cmbLinkTarget',
34            type: 'select',
35            label: Drupal.t('Link Target'),
36            items: [[Drupal.t('None'), '_self'], [Drupal.t('Blank'), '_blank'], [Drupal.t('Parent'), '_parent']],
37            // "Link Target" edits the 'linkTarget' property in the options JSON string.
38            setup: function (widget) {
39              var options = JSON.parse(widget.data.options);
40              if (options.linkTarget) {
41                this.setValue(options.linkTarget);
42              }
43            },
44            commit: function (widget) {
45              // Copy the current options into a new object,
46              var options = JSON.parse(widget.data.options);
47              var value = this.getValue();
48              if (value != '') {
49                options.linkTarget = value;
50              }
51              else {
52                delete options.linkTarget;
53              }
54              widget.setData('options', JSON.stringify(options));
55            }
56          });
57        });
58      }
59    }
60  };
61})(jQuery);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.