mirror of
https://github.com/vichan-devel/vichan.git
synced 2024-11-23 23:20:57 +01:00
Add some missing i18n tags
This commit is contained in:
parent
5267098cb8
commit
cac428b30c
@ -13,7 +13,7 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
var self = {};
|
var self = {};
|
||||||
self.rules = {
|
self.rules = {
|
||||||
spoiler: {
|
spoiler: {
|
||||||
text: 'Spoiler',
|
text: _('Spoiler'),
|
||||||
key: 's',
|
key: 's',
|
||||||
multiline: false,
|
multiline: false,
|
||||||
exclusiveline: false,
|
exclusiveline: false,
|
||||||
@ -21,7 +21,7 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
suffix:'**'
|
suffix:'**'
|
||||||
},
|
},
|
||||||
italics: {
|
italics: {
|
||||||
text: 'Italics',
|
text: _('Italics'),
|
||||||
key: 'i',
|
key: 'i',
|
||||||
multiline: false,
|
multiline: false,
|
||||||
exclusiveline: false,
|
exclusiveline: false,
|
||||||
@ -29,7 +29,7 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
suffix: "''"
|
suffix: "''"
|
||||||
},
|
},
|
||||||
bold: {
|
bold: {
|
||||||
text: 'Bold',
|
text: _('Bold'),
|
||||||
key: 'b',
|
key: 'b',
|
||||||
multiline: false,
|
multiline: false,
|
||||||
exclusiveline: false,
|
exclusiveline: false,
|
||||||
@ -37,7 +37,7 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
suffix: "'''"
|
suffix: "'''"
|
||||||
},
|
},
|
||||||
underline: {
|
underline: {
|
||||||
text: 'Underline',
|
text: _('Underline'),
|
||||||
key: 'u',
|
key: 'u',
|
||||||
multiline: false,
|
multiline: false,
|
||||||
exclusiveline: false,
|
exclusiveline: false,
|
||||||
@ -45,7 +45,7 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
suffix:'__'
|
suffix:'__'
|
||||||
},
|
},
|
||||||
code: {
|
code: {
|
||||||
text: 'Code',
|
text: _('Code'),
|
||||||
key: 'f',
|
key: 'f',
|
||||||
multiline: true,
|
multiline: true,
|
||||||
exclusiveline: false,
|
exclusiveline: false,
|
||||||
@ -53,7 +53,7 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
suffix: '[/code]'
|
suffix: '[/code]'
|
||||||
},
|
},
|
||||||
strike: {
|
strike: {
|
||||||
text: 'Strike',
|
text: _('Strike'),
|
||||||
key: 'd',
|
key: 'd',
|
||||||
multiline:false,
|
multiline:false,
|
||||||
exclusiveline:false,
|
exclusiveline:false,
|
||||||
@ -61,7 +61,7 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
suffix:'~~'
|
suffix:'~~'
|
||||||
},
|
},
|
||||||
heading: {
|
heading: {
|
||||||
text: 'Heading',
|
text: _('Heading'),
|
||||||
key: 'r',
|
key: 'r',
|
||||||
multiline:false,
|
multiline:false,
|
||||||
exclusiveline:true,
|
exclusiveline:true,
|
||||||
@ -271,7 +271,7 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
|
|
||||||
// add the tab for customizing the format settings
|
// add the tab for customizing the format settings
|
||||||
if (window.Options && !Options.get_tab('formatting')) {
|
if (window.Options && !Options.get_tab('formatting')) {
|
||||||
Options.add_tab('formatting', 'angle-right', 'Customize Formatting');
|
Options.add_tab('formatting', 'angle-right', _('Customize Formatting'));
|
||||||
Options.extend_tab('formatting', '\
|
Options.extend_tab('formatting', '\
|
||||||
<style>\
|
<style>\
|
||||||
.format_option{\
|
.format_option{\
|
||||||
@ -295,10 +295,10 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
|
|
||||||
// Data control row
|
// Data control row
|
||||||
Options.extend_tab('formatting', '\
|
Options.extend_tab('formatting', '\
|
||||||
<button onclick="formatText.add_rule();">Add Rule</button>\
|
<button onclick="formatText.add_rule();">'+_('Add Rule')+'</button>\
|
||||||
<button onclick="formatText.save_rules();">Save Rules</button>\
|
<button onclick="formatText.save_rules();">'+_('Save Rules')+'</button>\
|
||||||
<button onclick="formatText.reset_rules(false);">Revert</button>\
|
<button onclick="formatText.reset_rules(false);">'+_('Revert')+'</button>\
|
||||||
<button onclick="formatText.reset_rules(true);">Reset to Default</button>\
|
<button onclick="formatText.reset_rules(true);">'+_('Reset to Default')+'</button>\
|
||||||
');
|
');
|
||||||
|
|
||||||
// Descriptor row
|
// Descriptor row
|
||||||
@ -380,4 +380,4 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
|
|
||||||
return self;
|
return self;
|
||||||
})(jQuery);
|
})(jQuery);
|
||||||
}
|
}
|
||||||
|
@ -12,8 +12,8 @@ if (active_page == 'thread' || active_page == 'index') {
|
|||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
|
|
||||||
if ($('.delete #password').length) {
|
if ($('.delete #password').length) {
|
||||||
Menu.add_item("delete_post_menu", "Delete post");
|
Menu.add_item("delete_post_menu", _("Delete post"));
|
||||||
Menu.add_item("delete_file_menu", "Delete file");
|
Menu.add_item("delete_file_menu", _("Delete file"));
|
||||||
Menu.onclick(function(e, $buf) {
|
Menu.onclick(function(e, $buf) {
|
||||||
var ele = e.target.parentElement.parentElement;
|
var ele = e.target.parentElement.parentElement;
|
||||||
var $ele = $(ele);
|
var $ele = $(ele);
|
||||||
@ -34,8 +34,8 @@ if ($('.delete #password').length) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Menu.add_item("report_menu", "Report");
|
Menu.add_item("report_menu", _("Report"));
|
||||||
Menu.add_item("global_report_menu", "Global report");
|
Menu.add_item("global_report_menu", _("Global report"));
|
||||||
Menu.onclick(function(e, $buf) {
|
Menu.onclick(function(e, $buf) {
|
||||||
var ele = e.target.parentElement.parentElement;
|
var ele = e.target.parentElement.parentElement;
|
||||||
var $ele = $(ele);
|
var $ele = $(ele);
|
||||||
|
@ -123,8 +123,8 @@ $(document).ready(function() {
|
|||||||
$clone.insertAfter(link.node)
|
$clone.insertAfter(link.node)
|
||||||
}
|
}
|
||||||
|
|
||||||
App.options.add('useInlining', 'Enable inlining')
|
App.options.add('useInlining', _('Enable inlining'))
|
||||||
App.options.add('hidePost', 'Hide inlined backlinked posts')
|
App.options.add('hidePost', _('Hide inlined backlinked posts'))
|
||||||
|
|
||||||
$('head').append(
|
$('head').append(
|
||||||
'<style>' +
|
'<style>' +
|
||||||
|
@ -202,20 +202,20 @@ if (active_page === 'thread' || active_page === 'index' || active_page === 'cata
|
|||||||
function initPostMenu(pageData) {
|
function initPostMenu(pageData) {
|
||||||
|
|
||||||
var submenu;
|
var submenu;
|
||||||
Menu.add_item('filter-menu-hide', 'Hide post');
|
Menu.add_item('filter-menu-hide', _('Hide post'));
|
||||||
Menu.add_item('filter-menu-unhide', 'Unhide post');
|
Menu.add_item('filter-menu-unhide', _('Unhide post'));
|
||||||
|
|
||||||
submenu = Menu.add_submenu('filter-menu-add', 'Add filter');
|
submenu = Menu.add_submenu('filter-menu-add', _('Add filter'));
|
||||||
submenu.add_item('filter-add-post-plus', 'Post +', 'Hide post and all replies');
|
submenu.add_item('filter-add-post-plus', _('Post +'), _('Hide post and all replies'));
|
||||||
submenu.add_item('filter-add-id', 'ID');
|
submenu.add_item('filter-add-id', _('ID'));
|
||||||
submenu.add_item('filter-add-id-plus', 'ID +', 'Hide ID and all replies');
|
submenu.add_item('filter-add-id-plus', _('ID +'), _('Hide ID and all replies'));
|
||||||
submenu.add_item('filter-add-name', 'Name');
|
submenu.add_item('filter-add-name', _('Name'));
|
||||||
submenu.add_item('filter-add-trip', 'Tripcode');
|
submenu.add_item('filter-add-trip', _('Tripcode'));
|
||||||
|
|
||||||
submenu = Menu.add_submenu('filter-menu-remove', 'Remove filter');
|
submenu = Menu.add_submenu('filter-menu-remove', _('Remove filter'));
|
||||||
submenu.add_item('filter-remove-id', 'ID');
|
submenu.add_item('filter-remove-id', _('ID'));
|
||||||
submenu.add_item('filter-remove-name', 'Name');
|
submenu.add_item('filter-remove-name', _('Name'));
|
||||||
submenu.add_item('filter-remove-trip', 'Tripcode');
|
submenu.add_item('filter-remove-trip', _('Tripcode'));
|
||||||
|
|
||||||
Menu.onclick(function (e, $buffer) {
|
Menu.onclick(function (e, $buffer) {
|
||||||
var ele = e.target.parentElement.parentElement;
|
var ele = e.target.parentElement.parentElement;
|
||||||
@ -644,22 +644,22 @@ if (active_page === 'thread' || active_page === 'index' || active_page === 'cata
|
|||||||
|
|
||||||
function initOptionsPanel() {
|
function initOptionsPanel() {
|
||||||
if (window.Options && !Options.get_tab('filter')) {
|
if (window.Options && !Options.get_tab('filter')) {
|
||||||
Options.add_tab('filter', 'list', 'Filters');
|
Options.add_tab('filter', 'list', _('Filters'));
|
||||||
Options.extend_tab('filter',
|
Options.extend_tab('filter',
|
||||||
'<div id="filter-control">' +
|
'<div id="filter-control">' +
|
||||||
'<select>' +
|
'<select>' +
|
||||||
'<option value="name">Name</option>' +
|
'<option value="name">'+_('Name')+'</option>' +
|
||||||
'<option value="trip">Tripcode</option>' +
|
'<option value="trip">'+_('Tripcode')+'</option>' +
|
||||||
'<option value="sub">Subject</option>' +
|
'<option value="sub">'+_('Subject')+'</option>' +
|
||||||
'<option value="com">Comment</option>' +
|
'<option value="com">'+_('Comment')+'</option>' +
|
||||||
'</select>' +
|
'</select>' +
|
||||||
'<input type="text">' +
|
'<input type="text">' +
|
||||||
'<input type="checkbox">' +
|
'<input type="checkbox">' +
|
||||||
'regex ' +
|
'regex ' +
|
||||||
'<button id="set-filter">Add</button>' +
|
'<button id="set-filter">'+_('Add')+'</button>' +
|
||||||
'<button id="clear">Clear all filters</button>' +
|
'<button id="clear">'+_('Clear all filters')+'</button>' +
|
||||||
'<div id="confirm" class="hidden">' +
|
'<div id="confirm" class="hidden">' +
|
||||||
'This will clear all filtering rules including hidden posts. <a id="confirm-y" href="#">yes</a> | <a id="confirm-n" href="#">no</a>' +
|
_('This will clear all filtering rules including hidden posts.')+' <a id="confirm-y" href="#">'+_('yes')+'</a> | <a id="confirm-n" href="#">'+_('no')+'</a>' +
|
||||||
'</div>' +
|
'</div>' +
|
||||||
'</div>' +
|
'</div>' +
|
||||||
'<div id="filter-container"><table id="filter-list"></table></div>'
|
'<div id="filter-container"><table id="filter-list"></table></div>'
|
||||||
|
@ -29,7 +29,7 @@ watchlist.render = function(reset) {
|
|||||||
//look at line 69, that's what (e) is here.
|
//look at line 69, that's what (e) is here.
|
||||||
threads.push('<div class="watchlist-inner" id="watchlist-'+i+'">' +
|
threads.push('<div class="watchlist-inner" id="watchlist-'+i+'">' +
|
||||||
'<span>/'+e[0]+'/ - ' +
|
'<span>/'+e[0]+'/ - ' +
|
||||||
'<a href="'+e[3]+'">'+e[1].replace("thread_", "Thread #")+'</a>' +
|
'<a href="'+e[3]+'">'+e[1].replace("thread_", _("Thread #"))+'</a>' +
|
||||||
' ('+e[2]+') </span>' +
|
' ('+e[2]+') </span>' +
|
||||||
'<a class="watchlist-remove">X</a>'+
|
'<a class="watchlist-remove">X</a>'+
|
||||||
'</div>');
|
'</div>');
|
||||||
@ -44,8 +44,8 @@ watchlist.render = function(reset) {
|
|||||||
$('form[name="post"]').before(
|
$('form[name="post"]').before(
|
||||||
$('<div id="watchlist">'+
|
$('<div id="watchlist">'+
|
||||||
'<div class="watchlist-controls">'+
|
'<div class="watchlist-controls">'+
|
||||||
'<span><a id="clearList">[Clear List]</a></span> '+
|
'<span><a id="clearList">['+_('Clear List')+']</a></span> '+
|
||||||
'<span><a id="clearGhosts">[Clear Ghosts]</a></span>'+
|
'<span><a id="clearGhosts">['+_('Clear Ghosts')+']</a></span>'+
|
||||||
'</div>'+
|
'</div>'+
|
||||||
threads.join('')+
|
threads.join('')+
|
||||||
'</div>').css("background-color", menuStyle.backgroundColor).css("border", menuStyle.borderBottomWidth+" "+menuStyle.borderBottomStyle+" "+menuStyle.borderBottomColor));
|
'</div>').css("background-color", menuStyle.backgroundColor).css("border", menuStyle.borderBottomWidth+" "+menuStyle.borderBottomStyle+" "+menuStyle.borderBottomColor));
|
||||||
@ -80,7 +80,7 @@ watchlist.add = function(sel) {
|
|||||||
postCount = $(sel).parents('.op').siblings('.post').length+1;
|
postCount = $(sel).parents('.op').siblings('.post').length+1;
|
||||||
}
|
}
|
||||||
//Grab the reply link.
|
//Grab the reply link.
|
||||||
var threadLink = $(sel).siblings('a:contains("[Reply]")').attr('href');
|
var threadLink = $(sel).siblings('a:contains("['+_('Reply')+']")').attr('href');
|
||||||
//Figure out the thread name. If anon, use the thread id.
|
//Figure out the thread name. If anon, use the thread id.
|
||||||
if ($(sel).parent().find('.subject').length) {
|
if ($(sel).parent().find('.subject').length) {
|
||||||
threadName = $(sel).parent().find('.subject').text().substring(0,20);
|
threadName = $(sel).parent().find('.subject').text().substring(0,20);
|
||||||
@ -147,9 +147,9 @@ $(document).ready(function(){
|
|||||||
}
|
}
|
||||||
|
|
||||||
//Append the watchlist toggle button.
|
//Append the watchlist toggle button.
|
||||||
$('.boardlist').append('<span>[ <a class="watchlist-toggle" href="#">watchlist</a> ]</span>');
|
$('.boardlist').append('<span>[ <a class="watchlist-toggle" href="#">'+_('watchlist')+'</a> ]</span>');
|
||||||
//Append a watch thread button after every OP.
|
//Append a watch thread button after every OP.
|
||||||
$('.op>.intro').append('<a class="watchThread" href="#">[Watch Thread]</a>');
|
$('.op>.intro').append('<a class="watchThread" href="#">['+_('Watch Thread')+']</a>');
|
||||||
|
|
||||||
//Draw the watchlist, hidden.
|
//Draw the watchlist, hidden.
|
||||||
watchlist.render();
|
watchlist.render();
|
||||||
|
Loading…
Reference in New Issue
Block a user