PageSourceSearch

https://actionnetwork.org/includes/js/redactor_emoji.js?v=71

js actionnetwork.org collected 2026-10-01 07:20:48 UTC 2,237 bytes, 72 lines download raw bytes

1(function($)
2{
3	$.Redactor.prototype.emoji = function()
4	{
5	    return {
6	    	init: function()
7	    	{
8	    		var redactor_emoji_plugin = this;
9
10			    // Assign this to variable so we can use it later
11			    var emojiPlugin = this;
12
13                // Create button to use for a trigger the emojioneArea plugin
14			    var button = this.button.add('emoji', '<span class="screen-reader">Emoji</span> <i class="far fa-smile"></i>');
15				
16				button.attr('title', 'Emoji');
17
18                // Create button to initialize the emojioneArea plugin
19			    var emojiArea = this.button.add('emoji', 'Emoji Area');
20
21                // Add classes for button
22                button.addClass('js-add-emoji-btn');
23			
24			    // Add classes for CSS
25			    emojiArea.addClass('emoji_picker js-emoji_picker');
26
27                emojiArea.parent().css('display', 'none');
28			
29			    // Initialize the plugin on the original button 
30			    emojiArea.emojioneArea ({
31			        standalone: true,
32			        autocomplete: false,
33			        pickerPosition: "bottom",
34			        search: false,
35                    hidePickerOnBlur: true
36			    });
37
38                var $emojionearea = emojiArea[0].emojioneArea;
39
40                button.on('click', function(e) {
41                    e.preventDefault();
42                    emojiArea.parent().css('display', 'inline-block');
43                    $emojionearea.showPicker();
44                });
45
46                button.on('blur', function(e){
47                    $emojionearea.hidePicker();
48                });
49
50                $emojionearea.setText('');
51
52                $emojionearea.on('picker.hide', function() {
53                    var emoji = $emojionearea.getText();
54                    $emojionearea.setText('');
55                    if(emoji) {
56                        redactor_emoji_plugin.emoji.insert(emoji);
57                    }
58                });
59                
60
61			},
62			insert: function(html)
63			{
64				this.buffer.set();
65				this.air.collapsedEnd();
66				this.insert.html(html);
67				this.$toolbar.parents('.floatlabel-wrapper-redactor').find('.floatlabel-redactor').addClass('floatlabel-label-active floatlabel-label-focus').removeClass('floatlabel-label-inactive');
68			}
69		};
70	};
71})(jQuery);
72

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.