5 * Description: Theme based on Testbubble and optimized for Tablets.
6 * Version: Version 2013-05-08
7 * Author: Anne Walk, Devlon Duthied
8 * Author: Alex <https://red.pixelbits.de/channel/alex>
9 * Maintainer: Nomen Nominandum
10 * Screenshot: <a href="screenshot.png">Screenshot</a>
14 use Friendica\Core\Renderer;
18 * This script can be included even when the app is in maintenance mode which requires us to avoid any config call
21 function smoothly_init(App $a) {
22 Renderer::setActiveTemplateEngine('smarty3');
26 $baseurl = DI::baseUrl()->get($ssl_state);
27 DI::page()['htmlhead'] .= <<< EOT
30 function cmtBbOpen(id) {
31 $(".comment-edit-bb-" + id).show();
33 function cmtBbClose(comment, id) {
34 $(".comment-edit-bb-" + id).hide();
36 $(document).ready(function() {
38 $('html').click(function() { $("#nav-notifications-menu" ).hide(); });
40 $('.group-edit-icon').hover(
42 $(this).addClass('icon'); $(this).removeClass('iconspacer');},
44 $(this).removeClass('icon'); $(this).addClass('iconspacer');}
47 $('.sidebar-group-element').hover(
49 id = $(this).attr('id');
50 $('#edit-' + id).addClass('icon'); $('#edit-' + id).removeClass('iconspacer');},
53 id = $(this).attr('id');
54 $('#edit-' + id).removeClass('icon');$('#edit-' + id).addClass('iconspacer');}
58 $('.savedsearchdrop').hover(
60 $(this).addClass('drop'); $(this).addClass('icon'); $(this).removeClass('iconspacer');},
62 $(this).removeClass('drop'); $(this).removeClass('icon'); $(this).addClass('iconspacer');}
65 $('.savedsearchterm').hover(
67 id = $(this).attr('id');
68 $('#drop-' + id).addClass('icon'); $('#drop-' + id).addClass('drophide'); $('#drop-' + id).removeClass('iconspacer');},
71 id = $(this).attr('id');
72 $('#drop-' + id).removeClass('icon');$('#drop-' + id).removeClass('drophide'); $('#drop-' + id).addClass('iconspacer');}
81 if (!is_null($cssFile)) {
82 DI::page()['htmlhead'] .= sprintf('<link rel="stylesheet" type="text/css" href="%s" />', $cssFile);
88 if (! function_exists('_js_in_foot')) {
89 function _js_in_foot() {
90 /** @purpose insert stuff in bottom of page
93 $baseurl = DI::baseUrl()->get($ssl_state);
94 $bottom['$baseurl'] = $baseurl;
95 $tpl = Renderer::getMarkupTemplate('bottom.tpl');
97 return DI::page()['bottom'] = Renderer::replaceMacros($tpl, $bottom);
102 * @param int|null $uid
104 * @see \Friendica\Core\Theme::getBackgroundColor()
105 * @TODO Implement this function
107 function smoothly_get_background_color(int $uid = null)
113 * @param int|null $uid
115 * @see \Friendica\Core\Theme::getThemeColor()
116 * @TODO Implement this function
118 function smoothly_get_theme_color(int $uid = null)