<commit_before><div class="icon-selector-container">
	<input type="hidden" name="{$field.ins_id|escape}" value="{$field.value|escape}">
	<img class="icon" src="{$field.value|escape}" alt="{tr}Select Icon{/tr}">
	<div class="selector" style="display: none;">
		<div class="sections" style="float: left; width: 25%;">
			<div class="buttons">
				{foreach from=$data.galleries item=gal}
					<a href="{$gal.url|escape}">{$gal.label|escape}</a>
				{/foreach}
			</div>
		</div>
		<div class="contents" style="float: left; width: 75%;">
		</div>
	</div>
</div>

{jq}
$('.icon-selector-container').removeClass('icon-selector-container').each(function () {
	var icon = $('.icon', this).button();
	var field = $(':input', this);
	var jqxhr;
	var selector = $('.selector', this)
		.dialog({
			title: icon.attr('alt'),
			width: 600,
			autoOpen: false,
			modal: true,
			open: function () { $(document).trigger('iconsloaded'); }
		})
		.each(function () {
			var contents = $('.contents', this);
			$('.buttons', this).buttonset();
			$('.sections a', this).css('display', 'block').click(function () {
				contents.empty().append($('<img/>').attr('src', 'img/spinner.gif'));
				if (jqxhr) {
					jqxhr.abort();
				}
				jqxhr = $.getJSON($(this).attr('href'), function (data) {
					jqxhr = null;
					contents.empty();
					$.each(data, function (k, v) {
						var link = $(v.link);
						link.empty().append($('<img/>').attr('src', link.attr('href')));
						link.click(function () {
							field.val($(this).attr('href'));
							icon.attr('src', $(this).attr('href'));
							selector.dialog('close');
							return false;
						});

						link.appendTo(contents);
					});
				});
				return false;
			});
			$('.sections a:first', this).click();
		});
	icon.click(function () {
		selector.dialog('open');
	});
});
{/jq}
<commit_msg>[FIX] tracker icons: Use file title as icon title attribute<commit_after><div class="icon-selector-container">
	<input type="hidden" name="{$field.ins_id|escape}" value="{$field.value|escape}">
	<img class="icon" src="{$field.value|escape}" alt="{tr}Select Icon{/tr}">
	<div class="selector" style="display: none;">
		<div class="sections" style="float: left; width: 25%;">
			<div class="buttons">
				{foreach from=$data.galleries item=gal}
					<a href="{$gal.url|escape}">{$gal.label|escape}</a>
				{/foreach}
			</div>
		</div>
		<div class="contents" style="float: left; width: 75%;">
		</div>
	</div>
</div>

{jq}
$('.icon-selector-container').removeClass('icon-selector-container').each(function () {
	var icon = $('.icon', this).button();
	var field = $(':input', this);
	var jqxhr;
	var selector = $('.selector', this)
		.dialog({
			title: icon.attr('alt'),
			width: 600,
			autoOpen: false,
			modal: true,
			open: function () { $(document).trigger('iconsloaded'); }
		})
		.each(function () {
			var contents = $('.contents', this);
			$('.buttons', this).buttonset();
			$('.sections a', this).css('display', 'block').click(function () {
				contents.empty().append($('<img/>').attr('src', 'img/spinner.gif'));
				if (jqxhr) {
					jqxhr.abort();
				}
				jqxhr = $.getJSON($(this).attr('href'), function (data) {
					jqxhr = null;
					contents.empty();
					$.each(data, function (k, v) {
						var link = $(v.link);
						link.attr('title', tr(v.title));
						link.empty().append($('<img/>').attr('src', link.attr('href')));
						link.click(function () {
							field.val($(this).attr('href'));
							icon.attr('src', $(this).attr('href'));
							selector.dialog('close');
							return false;
						});

						link.appendTo(contents);
					});
				});
				return false;
			});
			$('.sections a:first', this).click();
		});
	icon.click(function () {
		selector.dialog('open');
	});
});
{/jq}

{'fraction_non_alphanumeric': 0.24314247669773636, 'fraction_numerical': 0.0037283621837549932, 'mean_word_length': 3.5916870415647923, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 35, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3494926', 'n_tokens_mistral': 1574, 'n_tokens_neox': 1269, 'n_words': 243}