4 use Friendica\Core\Config;
5 use Friendica\Core\PConfig;
6 use Friendica\Core\Renderer;
9 function duepuntozero_init(App $a) {
11 Renderer::setActiveTemplateEngine('smarty3');
13 $colorset = PConfig::get( local_user(), 'duepuntozero','colorset');
15 $colorset = Config::get('duepuntozero', 'colorset'); // user setting have priority, then node settings
17 if ($colorset == 'greenzero')
18 DI::page()['htmlhead'] .= '<link rel="stylesheet" href="view/theme/duepuntozero/deriv/greenzero.css" type="text/css" media="screen" />'."\n";
19 if ($colorset == 'purplezero')
20 DI::page()['htmlhead'] .= '<link rel="stylesheet" href="view/theme/duepuntozero/deriv/purplezero.css" type="text/css" media="screen" />'."\n";
21 if ($colorset == 'easterbunny')
22 DI::page()['htmlhead'] .= '<link rel="stylesheet" href="view/theme/duepuntozero/deriv/easterbunny.css" type="text/css" media="screen" />'."\n";
23 if ($colorset == 'darkzero')
24 DI::page()['htmlhead'] .= '<link rel="stylesheet" href="view/theme/duepuntozero/deriv/darkzero.css" type="text/css" media="screen" />'."\n";
25 if ($colorset == 'comix')
26 DI::page()['htmlhead'] .= '<link rel="stylesheet" href="view/theme/duepuntozero/deriv/comix.css" type="text/css" media="screen" />'."\n";
27 if ($colorset == 'slackr')
28 DI::page()['htmlhead'] .= '<link rel="stylesheet" href="view/theme/duepuntozero/deriv/slackr.css" type="text/css" media="screen" />'."\n";
30 DI::page()['htmlhead'] .= <<< EOT
32 function cmtBbOpen(comment, id) {
33 if ($(comment).hasClass('comment-edit-text-full')) {
34 $(".comment-edit-bb-" + id).show();
39 function cmtBbClose(comment, id) {
42 $(document).ready(function() {
44 $('html').click(function() { $("#nav-notifications-menu" ).hide(); });
46 $('.group-edit-icon').hover(
48 $(this).addClass('icon'); $(this).removeClass('iconspacer');},
50 $(this).removeClass('icon'); $(this).addClass('iconspacer');}
53 $('.sidebar-group-element').hover(
55 id = $(this).attr('id');
56 $('#edit-' + id).addClass('icon'); $('#edit-' + id).removeClass('iconspacer');},
59 id = $(this).attr('id');
60 $('#edit-' + id).removeClass('icon');$('#edit-' + id).addClass('iconspacer');}
64 $('.savedsearchdrop').hover(
66 $(this).addClass('drop'); $(this).addClass('icon'); $(this).removeClass('iconspacer');},
68 $(this).removeClass('drop'); $(this).removeClass('icon'); $(this).addClass('iconspacer');}
71 $('.savedsearchterm').hover(
73 id = $(this).attr('id');
74 $('#drop-' + id).addClass('icon'); $('#drop-' + id).addClass('drophide'); $('#drop-' + id).removeClass('iconspacer');},
77 id = $(this).attr('id');
78 $('#drop-' + id).removeClass('icon');$('#drop-' + id).removeClass('drophide'); $('#drop-' + id).addClass('iconspacer');}