Merge pull request #13948 from MrPetovan/task/12420-frio-remove-legacy-scheme

[frio] Remove legacy schemes
This commit is contained in:
Michael Vogel 2024-03-02 06:06:15 +01:00 committed by GitHub
commit f2ccce05b8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
16 changed files with 145 additions and 522 deletions

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 2024.03-rc\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-02-24 15:29+0000\n"
"POT-Creation-Date: 2024-03-01 08:51-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -244,7 +244,7 @@ msgstr ""
msgid "Discard"
msgstr ""
#: mod/message.php:135 src/Content/Nav.php:318 view/theme/frio/theme.php:241
#: mod/message.php:135 src/Content/Nav.php:318 view/theme/frio/theme.php:244
msgid "Messages"
msgstr ""
@ -315,7 +315,7 @@ msgstr ""
#: src/Module/Profile/Profile.php:274 src/Module/Settings/Profile/Index.php:257
#: src/Module/Settings/Server/Action.php:79 src/Module/User/Delegation.php:189
#: src/Object/Post.php:1154 view/theme/duepuntozero/config.php:85
#: view/theme/frio/config.php:171 view/theme/quattro/config.php:87
#: view/theme/frio/config.php:150 view/theme/quattro/config.php:87
#: view/theme/vier/config.php:135
msgid "Submit"
msgstr ""
@ -1807,7 +1807,7 @@ msgstr ""
msgid "%1$s tagged %2$s's %3$s with %4$s"
msgstr ""
#: src/Content/Item.php:429 view/theme/frio/theme.php:262
#: src/Content/Item.php:429 view/theme/frio/theme.php:265
msgid "Follow Thread"
msgstr ""
@ -1925,42 +1925,42 @@ msgstr ""
#: src/Content/Nav.php:230 src/Module/BaseProfile.php:49
#: src/Module/BaseSettings.php:98 src/Module/Contact.php:503
#: src/Module/Contact/Profile.php:419 src/Module/Profile/Profile.php:268
#: src/Module/Welcome.php:57 view/theme/frio/theme.php:230
#: src/Module/Welcome.php:57 view/theme/frio/theme.php:233
msgid "Profile"
msgstr ""
#: src/Content/Nav.php:230 view/theme/frio/theme.php:230
#: src/Content/Nav.php:230 view/theme/frio/theme.php:233
msgid "Your profile page"
msgstr ""
#: src/Content/Nav.php:231 src/Module/BaseProfile.php:65
#: src/Module/Media/Photo/Browser.php:74 view/theme/frio/theme.php:234
#: src/Module/Media/Photo/Browser.php:74 view/theme/frio/theme.php:237
msgid "Photos"
msgstr ""
#: src/Content/Nav.php:231 view/theme/frio/theme.php:234
#: src/Content/Nav.php:231 view/theme/frio/theme.php:237
msgid "Your photos"
msgstr ""
#: src/Content/Nav.php:232 src/Module/BaseProfile.php:73
#: src/Module/BaseProfile.php:76 src/Module/Contact.php:527
#: view/theme/frio/theme.php:235
#: view/theme/frio/theme.php:238
msgid "Media"
msgstr ""
#: src/Content/Nav.php:232 view/theme/frio/theme.php:235
#: src/Content/Nav.php:232 view/theme/frio/theme.php:238
msgid "Your postings with media"
msgstr ""
#: src/Content/Nav.php:233 src/Content/Nav.php:293
#: src/Module/BaseProfile.php:85 src/Module/BaseProfile.php:88
#: src/Module/BaseProfile.php:96 src/Module/BaseProfile.php:99
#: src/Module/Settings/Display.php:319 view/theme/frio/theme.php:236
#: view/theme/frio/theme.php:240
#: src/Module/Settings/Display.php:319 view/theme/frio/theme.php:239
#: view/theme/frio/theme.php:243
msgid "Calendar"
msgstr ""
#: src/Content/Nav.php:233 view/theme/frio/theme.php:236
#: src/Content/Nav.php:233 view/theme/frio/theme.php:239
msgid "Your calendar"
msgstr ""
@ -2030,7 +2030,7 @@ msgstr ""
#: src/Content/Nav.php:274 src/Content/Nav.php:329
#: src/Content/Text/HTML.php:877 src/Module/BaseProfile.php:127
#: src/Module/BaseProfile.php:130 src/Module/Contact.php:426
#: src/Module/Contact.php:535 view/theme/frio/theme.php:243
#: src/Module/Contact.php:535 view/theme/frio/theme.php:246
msgid "Contacts"
msgstr ""
@ -2069,15 +2069,15 @@ msgstr ""
msgid "Terms of Service of this Friendica instance"
msgstr ""
#: src/Content/Nav.php:306 view/theme/frio/theme.php:239
#: src/Content/Nav.php:306 view/theme/frio/theme.php:242
msgid "Network"
msgstr ""
#: src/Content/Nav.php:306 view/theme/frio/theme.php:239
#: src/Content/Nav.php:306 view/theme/frio/theme.php:242
msgid "Conversations from your friends"
msgstr ""
#: src/Content/Nav.php:308 view/theme/frio/theme.php:229
#: src/Content/Nav.php:308 view/theme/frio/theme.php:232
msgid "Your posts and conversations"
msgstr ""
@ -2106,7 +2106,7 @@ msgstr ""
msgid "Mark all system notifications as seen"
msgstr ""
#: src/Content/Nav.php:318 view/theme/frio/theme.php:241
#: src/Content/Nav.php:318 view/theme/frio/theme.php:244
msgid "Private mail"
msgstr ""
@ -2128,15 +2128,15 @@ msgstr ""
#: src/Content/Nav.php:327 src/Module/Admin/Addons/Details.php:114
#: src/Module/Admin/Themes/Details.php:93 src/Module/BaseSettings.php:182
#: src/Module/Welcome.php:52 view/theme/frio/theme.php:242
#: src/Module/Welcome.php:52 view/theme/frio/theme.php:245
msgid "Settings"
msgstr ""
#: src/Content/Nav.php:327 view/theme/frio/theme.php:242
#: src/Content/Nav.php:327 view/theme/frio/theme.php:245
msgid "Account settings"
msgstr ""
#: src/Content/Nav.php:329 view/theme/frio/theme.php:243
#: src/Content/Nav.php:329 view/theme/frio/theme.php:246
msgid "Manage/edit friends and contacts"
msgstr ""
@ -6892,7 +6892,7 @@ msgid "Actions"
msgstr ""
#: src/Module/Contact/Profile.php:417
#: src/Module/Settings/TwoFactor/Index.php:140 view/theme/frio/theme.php:229
#: src/Module/Settings/TwoFactor/Index.php:140 view/theme/frio/theme.php:232
msgid "Status"
msgstr ""
@ -8875,7 +8875,7 @@ msgstr ""
msgid "Unsupported or missing response type"
msgstr ""
#: src/Module/OAuth/Authorize.php:59 src/Module/OAuth/Token.php:78
#: src/Module/OAuth/Authorize.php:59 src/Module/OAuth/Token.php:75
msgid "Incomplete request data"
msgstr ""
@ -8886,11 +8886,11 @@ msgid ""
"close this window: %s"
msgstr ""
#: src/Module/OAuth/Token.php:83
#: src/Module/OAuth/Token.php:80
msgid "Invalid data or unknown client"
msgstr ""
#: src/Module/OAuth/Token.php:108
#: src/Module/OAuth/Token.php:105
msgid "Unsupported or missing grant type"
msgstr ""
@ -10630,7 +10630,7 @@ msgid "Content Settings"
msgstr ""
#: src/Module/Settings/Display.php:316 view/theme/duepuntozero/config.php:86
#: view/theme/frio/config.php:172 view/theme/quattro/config.php:88
#: view/theme/frio/config.php:151 view/theme/quattro/config.php:88
#: view/theme/vier/config.php:136
msgid "Theme settings"
msgstr ""
@ -12696,124 +12696,100 @@ msgstr ""
msgid "Variations"
msgstr ""
#: view/theme/frio/config.php:153
msgid "Light (Accented)"
msgstr ""
#: view/theme/frio/config.php:154
msgid "Dark (Accented)"
msgstr ""
#: view/theme/frio/config.php:155
msgid "Black (Accented)"
msgstr ""
#: view/theme/frio/config.php:167
#: view/theme/frio/config.php:146
msgid "Note"
msgstr ""
#: view/theme/frio/config.php:167
#: view/theme/frio/config.php:146
msgid "Check image permissions if all users are allowed to see the image"
msgstr ""
#: view/theme/frio/config.php:173
msgid "Custom"
#: view/theme/frio/config.php:152
msgid "Appearance"
msgstr ""
#: view/theme/frio/config.php:174
msgid "Legacy"
#: view/theme/frio/config.php:153
msgid "Accent color"
msgstr ""
#: view/theme/frio/config.php:175
msgid "Accented"
msgstr ""
#: view/theme/frio/config.php:176
msgid "Select color scheme"
msgstr ""
#: view/theme/frio/config.php:177
msgid "Select scheme accent"
msgstr ""
#: view/theme/frio/config.php:177
#: view/theme/frio/config.php:153
msgid "Blue"
msgstr ""
#: view/theme/frio/config.php:177
#: view/theme/frio/config.php:153
msgid "Red"
msgstr ""
#: view/theme/frio/config.php:177
#: view/theme/frio/config.php:153
msgid "Purple"
msgstr ""
#: view/theme/frio/config.php:177
#: view/theme/frio/config.php:153
msgid "Green"
msgstr ""
#: view/theme/frio/config.php:177
#: view/theme/frio/config.php:153
msgid "Pink"
msgstr ""
#: view/theme/frio/config.php:178
#: view/theme/frio/config.php:154
msgid "Copy or paste schemestring"
msgstr ""
#: view/theme/frio/config.php:178
#: view/theme/frio/config.php:154
msgid ""
"You can copy this string to share your theme with others. Pasting here "
"applies the schemestring"
msgstr ""
#: view/theme/frio/config.php:179
#: view/theme/frio/config.php:155
msgid "Navigation bar background color"
msgstr ""
#: view/theme/frio/config.php:180
#: view/theme/frio/config.php:156
msgid "Navigation bar icon color "
msgstr ""
#: view/theme/frio/config.php:181
#: view/theme/frio/config.php:157
msgid "Link color"
msgstr ""
#: view/theme/frio/config.php:182
#: view/theme/frio/config.php:158
msgid "Set the background color"
msgstr ""
#: view/theme/frio/config.php:183
#: view/theme/frio/config.php:159
msgid "Content background opacity"
msgstr ""
#: view/theme/frio/config.php:184
#: view/theme/frio/config.php:160
msgid "Set the background image"
msgstr ""
#: view/theme/frio/config.php:185
#: view/theme/frio/config.php:161
msgid "Background image style"
msgstr ""
#: view/theme/frio/config.php:188
#: view/theme/frio/config.php:164
msgid "Always open Compose page"
msgstr ""
#: view/theme/frio/config.php:188
#: view/theme/frio/config.php:164
msgid ""
"The New Post button always open the <a href=\"/compose\">Compose page</a> "
"instead of the modal form. When this is disabled, the Compose page can be "
"accessed with a middle click on the link or from the modal."
msgstr ""
#: view/theme/frio/config.php:192
#: view/theme/frio/config.php:168
msgid "Login page background image"
msgstr ""
#: view/theme/frio/config.php:196
#: view/theme/frio/config.php:172
msgid "Login page background color"
msgstr ""
#: view/theme/frio/config.php:196
#: view/theme/frio/config.php:172
msgid "Leave background image and color empty for theme defaults"
msgstr ""
@ -12853,19 +12829,35 @@ msgstr ""
msgid "Repeat image to fill the screen."
msgstr ""
#: view/theme/frio/php/default.php:81 view/theme/frio/php/standard.php:40
#: view/theme/frio/php/default.php:82 view/theme/frio/php/standard.php:40
msgid "Skip to main content"
msgstr ""
#: view/theme/frio/php/default.php:152 view/theme/frio/php/standard.php:75
#: view/theme/frio/php/default.php:153 view/theme/frio/php/standard.php:75
msgid "Back to top"
msgstr ""
#: view/theme/frio/theme.php:211
msgid "Guest"
#: view/theme/frio/php/scheme.php:105
msgid "Light"
msgstr ""
#: view/theme/frio/php/scheme.php:106
msgid "Dark"
msgstr ""
#: view/theme/frio/php/scheme.php:107
msgid "Black"
msgstr ""
#: view/theme/frio/php/scheme.php:118
msgid "Custom"
msgstr ""
#: view/theme/frio/theme.php:214
msgid "Guest"
msgstr ""
#: view/theme/frio/theme.php:217
msgid "Visitor"
msgstr ""

View File

@ -24,6 +24,7 @@ use Friendica\Core\Renderer;
use Friendica\DI;
require_once 'view/theme/frio/php/Image.php';
require_once 'view/theme/frio/php/scheme.php';
function theme_post(App $a)
{
@ -93,14 +94,7 @@ function theme_content(): string
}
$arr = [
'scheme' => DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'frio', 'scheme',
DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'frio', 'schema',
DI::config()->get('frio', 'scheme',
DI::config()->get('frio', 'schema')
)
)
),
'scheme' => frio_scheme_get_current_for_user(DI::userSession()->getLocalUserId()),
'share_string' => '',
'scheme_accent' => DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'frio', 'scheme_accent' , DI::config()->get('frio', 'scheme_accent')),
'nav_bg' => DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'frio', 'nav_bg' , DI::config()->get('frio', 'nav_bg')),
@ -123,8 +117,8 @@ function theme_admin(): string
}
$arr = [
'scheme' => DI::config()->get('frio', 'scheme', DI::config()->get('frio', 'schema')),
'scheme_accent' => DI::config()->get('frio', 'scheme_accent'),
'scheme' => frio_scheme_get_current(),
'scheme_accent' => DI::config()->get('frio', 'scheme_accent') ?: FRIO_SCHEME_ACCENT_BLUE,
'share_string' => '',
'nav_bg' => DI::config()->get('frio', 'nav_bg'),
'nav_icon_color' => DI::config()->get('frio', 'nav_icon_color'),
@ -149,33 +143,15 @@ function frio_form($arr)
$scheme_info = get_scheme_info($arr['scheme']);
$disable = $scheme_info['overwrites'];
$schemes = [
'light' => DI::l10n()->t('Light (Accented)'),
'dark' => DI::l10n()->t('Dark (Accented)'),
'black' => DI::l10n()->t('Black (Accented)'),
];
$legacy_schemes = [];
foreach (glob('view/theme/frio/scheme/*.php') ?: [] as $file) {
$scheme = basename($file, '.php');
if (!in_array($scheme, ['default', 'light', 'dark', 'black'])) {
$scheme_name = ucfirst($scheme);
$legacy_schemes[$scheme] = $scheme_name;
}
}
$background_image_help = '<strong>' . DI::l10n()->t('Note') . ': </strong>' . DI::l10n()->t('Check image permissions if all users are allowed to see the image');
$t = Renderer::getMarkupTemplate('theme_settings.tpl');
$ctx = [
'$submit' => DI::l10n()->t('Submit'),
'$title' => DI::l10n()->t('Theme settings'),
'$custom' => DI::l10n()->t('Custom'),
'$legacy' => DI::l10n()->t('Legacy'),
'$accented' => DI::l10n()->t('Accented'),
'$scheme' => ['frio_scheme', DI::l10n()->t('Select color scheme'), $arr['scheme'], $schemes, $legacy_schemes],
'$scheme_accent' => !$scheme_info['accented'] ? '' : ['frio_scheme_accent', DI::l10n()->t('Select scheme accent'), $arr['scheme_accent'], ['blue' => DI::l10n()->t('Blue'), 'red' => DI::l10n()->t('Red'), 'purple' => DI::l10n()->t('Purple'), 'green' => DI::l10n()->t('Green'), 'pink' => DI::l10n()->t('Pink')]],
'$share_string' => $arr['scheme'] != '---' ? '' : ['frio_share_string', DI::l10n()->t('Copy or paste schemestring'), $arr['share_string'], DI::l10n()->t('You can copy this string to share your theme with others. Pasting here applies the schemestring'), false, false],
'$scheme' => ['frio_scheme', DI::l10n()->t('Appearance'), $arr['scheme'], frio_scheme_get_list()],
'$scheme_accent' => !$scheme_info['accented'] ? '' : ['frio_scheme_accent', DI::l10n()->t('Accent color'), $arr['scheme_accent'], ['blue' => DI::l10n()->t('Blue'), 'red' => DI::l10n()->t('Red'), 'purple' => DI::l10n()->t('Purple'), 'green' => DI::l10n()->t('Green'), 'pink' => DI::l10n()->t('Pink')]],
'$share_string' => $arr['scheme'] != FRIO_CUSTOM_SCHEME ? '' : ['frio_share_string', DI::l10n()->t('Copy or paste schemestring'), $arr['share_string'], DI::l10n()->t('You can copy this string to share your theme with others. Pasting here applies the schemestring'), false, false],
'$nav_bg' => array_key_exists('nav_bg', $disable) ? '' : ['frio_nav_bg', DI::l10n()->t('Navigation bar background color'), $arr['nav_bg'], '', false],
'$nav_icon_color' => array_key_exists('nav_icon_color', $disable) ? '' : ['frio_nav_icon_color', DI::l10n()->t('Navigation bar icon color '), $arr['nav_icon_color'], '', false],
'$link_color' => array_key_exists('link_color', $disable) ? '' : ['frio_link_color', DI::l10n()->t('Link color'), $arr['link_color'], '', false],

View File

@ -29,6 +29,7 @@ use Friendica\Model\Profile;
require_once 'view/theme/frio/theme.php';
require_once 'view/theme/frio/php/frio_boot.php';
require_once 'view/theme/frio/php/scheme.php';
// $minimal = is_modal();
if (!isset($minimal)) {
@ -59,8 +60,8 @@ $is_singleuser_class = $is_singleuser ? "is-singleuser" : "is-not-singleuser";
// Add the theme color meta
// It makes mobile Chrome UI match Frio's top bar color.
$uid = Profile::getThemeUid($a);
$scheme = DI::pConfig()->get($uid, 'frio', 'scheme', DI::pConfig()->get($uid, 'frio', 'schema'));
if ($scheme && is_string($scheme) && $scheme != '---') {
$scheme = frio_scheme_get_current_for_user($uid);
if ($scheme != FRIO_CUSTOM_SCHEME) {
if (file_exists('view/theme/frio/scheme/' . $scheme . '.php')) {
$schemefile = 'view/theme/frio/scheme/' . $scheme . '.php';
$scheme_accent =

View File

@ -37,15 +37,13 @@
use Friendica\DI;
use Friendica\Util\Strings;
require_once 'view/theme/frio/theme.php';
function get_scheme_info($scheme)
{
$theme = DI::app()->getCurrentTheme();
$themepath = 'view/theme/' . $theme . '/';
if (empty($scheme)) {
$scheme = DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'frio', 'scheme', DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'frio', 'schema', '---'));
}
$scheme = Strings::sanitizeFilePathItem($scheme);
$scheme = Strings::sanitizeFilePathItem($scheme) ?: FRIO_DEFAULT_SCHEME;
$info = [
'name' => $scheme,
@ -100,3 +98,54 @@ function get_scheme_info($scheme)
return $info;
}
function frio_scheme_get_list(): array
{
$schemes = [
'light' => DI::l10n()->t('Light'),
'dark' => DI::l10n()->t('Dark'),
'black' => DI::l10n()->t('Black'),
];
foreach (glob('view/theme/frio/scheme/*.php') ?: [] as $file) {
$scheme = basename($file, '.php');
if (!in_array($scheme, ['default', 'light', 'dark', 'black'])) {
$scheme_info = get_scheme_info($scheme);
$schemes[$scheme] = $scheme_info['name'] ?? ucfirst($scheme);
}
}
$schemes[FRIO_CUSTOM_SCHEME] = DI::l10n()->t('Custom');
return $schemes;
}
function frio_scheme_get_current()
{
$available = array_keys(frio_scheme_get_list());
$scheme = DI::config()->get('frio', 'scheme') ?: DI::config()->get('frio', 'schema');
if (!in_array($scheme, $available)) {
return FRIO_DEFAULT_SCHEME;
}
return $scheme;
}
function frio_scheme_get_current_for_user(int $uid)
{
$available = array_keys(frio_scheme_get_list());
$scheme =
DI::pConfig()->get($uid, 'frio', 'scheme') ?:
DI::pConfig()->get($uid, 'frio', 'schema') ?:
DI::config()->get('frio', 'scheme') ?:
DI::config()->get('frio', 'schema');
if (!in_array($scheme, $available)) {
return FRIO_DEFAULT_SCHEME;
}
return $scheme;
}

View File

@ -1,16 +0,0 @@
<?php
/*
* Name: Blue
* Author: Rabuzarus
*
* List here all variables which will get overwritten through this scheme
* Overwrites: nav_bg, nav_icon_color, link_color, background_color, login_bg_color, contentbg_transp
*/
$nav_bg = "#708fa0";
$nav_icon_color = "#fff";
$link_color = "#6fdbe8";
$background_color = "#ededed";
$login_bg_color = "#ededed";
$contentbg_transp = 100;

View File

@ -1,52 +0,0 @@
/*
Licence : AGPL
Created on : 30.04.2018, 15:03:06
Author : koyu
*/
#topbar-first,
#topbar-second,
body {
background: #111;
border: 0;
}
#topbar-first .dropdown.account > a,
#topbar-first .dropdown.account.open > a,
#topbar-first .dropdown.account > button,
#topbar-first .dropdown.account.open > button,
#topbar-first .dropdown.account > :hover,
#topbar-first .dropdown.account.open > :hover {
background: #111;
border: 0;
}
.nav-pills .dropdown-menu,
.nav-tabs .dropdown-menu,
.account .dropdown-menu,
.contact-photo-wrapper .dropdown-menu {
background: #111;
-webkit-box-shadow: 0px 0px 69px 4px rgba(0, 0, 0, 0.25);
-moz-box-shadow: 0px 0px 69px 4px rgba(0, 0, 0, 0.25);
box-shadow: 0px 0px 69px 4px rgba(0, 0, 0, 0.25);
border: 0;
}
.account .dropdown-menu li,
.account .dropdown-menu li:hover {
border: 0;
background: #111;
}
#topbar-first .topbar-nav .nav-segment > a:hover {
background: #333;
}
.account .dropdown-menu li:hover {
background: #333 !important;
}
.account .dropdown-menu li.divider {
background: #111;
}

View File

@ -1,10 +0,0 @@
<?php
/* Licence: AGPL
* Author: koyu
* Overwrites: nav_bg, nav_icon_color, link_color, background_color
*/
$nav_bg = "#111";
$nav_icon_color = "#fff";
$link_color = "#6fdbe8";
$background_color = "#111";

View File

@ -1,74 +0,0 @@
/*
Licence : AGPL
Created on : 28.03.2016, 03:13:19
Author : rabuzarus
*/
body {
color: #000;
}
/*
* Navbar
*/
#topbar-first,
nav.navbar {
box-shadow: 0 -1px 5px 2px #000;
}
#topbar-first .nav > li > a:hover,
nav.navbar .nav > li > a:hover {
background-color: #000;
color: #15e3ff;
}
#topbar-first .nav > li > a.selected {
background: #e355e0;
color: #000;
padding: 9px;
border-radius: 8px;
}
#topbar-first #nav-notifications-menu li.notif-entry:hover,
#topbar-second .nav > li > ul > li > a:hover,
#topbar-second .nav > li > ul > li > a.active,
#topbar-second .nav > li > a:hover,
#topbar-second .nav .open > a,
#topbar-second .nav > li.active,
.nav-pills .dropdown-menu li:hover,
.nav-tabs .dropdown-menu li:hover,
.account .dropdown-menu li:hover,
.contact-photo-wrapper .dropdown-menu li:hover,
.nav-pills .dropdown-menu li.selected,
.nav-tabs .dropdown-menu li.selected,
.account .dropdown-menu li.selected,
.contact-photo-wrapper .dropdown-menu li.selected,
aside .widget li:hover,
aside .widget li.selected,
.nav-container .widget li:hover {
border-left: 3px solid #15e3ff !important;
}
.panel,
aside .widget,
.nav-container .widget,
#profile-page,
.photos-content-wrapper,
.settings-content-wrapper {
border-style: solid solid solid solid;
border-width: 1px;
border-color: #dddddd;
box-shadow: none;
border-radius: 15px;
color: #000;
}
aside .widget li a,
aside .widget li a:hover,
.panel .panel-body .wall-item-content,
.toplevel_item .wall-item-container .btn-link {
color: #000;
}
.wall-item-content a:hover,
nav.navbar .navbar-brand {
color: #15e3ff !important;
}

View File

@ -1,15 +0,0 @@
<?php
/* Licence: AGP
* Author: rabuzarus
* Overwrites: nav_bg, nav_icon_color, link_color, background_color, contentbg_transp, background_image, bg_image_option, link_hover_color
*/
$nav_bg = "#000";
$nav_icon_color = "#e355e0";
$link_color = "#e355e0";
$background_color = "#fff";
$contentbg_transp = 100;
$background_image = "img/bg_circle.png";
$bg_image_option = "repeat";
$link_hover_color ="#15e3ff";

View File

@ -1,168 +0,0 @@
/*
Licence : AGPL
Created on : 29.06.2018, 15:03:06
Author : hoergen
Color picker : https://www.w3schools.com/colors/colors_names.asp
CSS UTF8 icons : https://www.utf8icons.com
*/
body {
background: url(scheme/plusminus.jpg);
background-repeat: no-repeat;
background-size: cover;
background-attachment: fixed;
height: auto;
}
aside .widget,
.form-control,
.panel,
.nav-container,
.wall-item-content,
.e-content,
.p-name,
.topbar,
post,
shiny,
tread-wrapper,
#topbar-second {
color: #000;
background-color: #f5f5f5;
}
.form-control {
font-family: ".SFNSText-Regular", "San Francisco", "Roboto", "Segoe UI", "Helvetica Neue", "Lucida Grande",
Helvetica, Arial, sans-serif;
}
#topbar-first #nav-notifications-menu li.notification-unseen {
border-left: 3px solid #e3eff3;
background-color: antiquewhite;
}
#topbar-first #nav-notifications-menu li.notif-entry {
padding: 0px;
}
.birthday-notice {
background-color: #cc0000;
color: white;
}
#birthday-title {
background-color: #ff0000;
color: white;
text-indent: 6px;
}
.birthday-list:before {
content: "\1F382 ";
}
.birthday-list {
margin: 1px;
color: black;
background-color: yellow;
text-indent: 10px;
border-radius: 5px;
}
#event-notice {
color: white;
background-color: #004c5b;
text-indent: 2px;
}
#event-title {
color: whitesmoke;
background-color: #006c83;
text-indent: 6px;
}
.event-list:before {
content: "\1F5D3 ";
}
.event-list {
margin: 1px;
color: black;
background-color: #00c7f0;
text-indent: 10px;
border-radius: 5px;
}
.panel .panel-body {
padding-top: 1px;
padding-bottom: 1px;
padding-left: 5px;
padding-right: 5px;
border: 1px;
}
.wall-item-network {
font-size: 12px;
}
.wall-item-content
.clearfix
.post
.comment-container
.well
.well-sm
.wall-item-body
.e-content
.p-name
.media
.comment
.wall-item-bottom
.wall-item-links
.wall-item-tags
.wall-item-actions
.wall-item-responses
#hr {
box-sizing: border-box;
margin-top: 0px;
margin-bottom: 0px;
border: 0px;
padding: 0px;
color: black;
}
.wall-spacer {
height: 0px;
}
/* Contact-page */
#connect-desc {
color: grey;
}
.search-input.form-control.form-search {
background-color: #ebebeb;
border-color: lightgrey;
}
.search-input.form-control.form-search:focus {
background-color: white;
border-color: grey;
}
/* Addon-Showmore*/
.showmore-wrap {
background-color: lightgrey;
text-decoration: underline;
text-decoration-color: black;
text-decoration-style: wavy;
}
/* New compose popup */
.profile-jot-net {
background: #dff0d8;
}
.profile-jot-net summary {
color: #3c763d;
font-weight: bold;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

View File

@ -1,17 +0,0 @@
<?php
/*
* Name: Plusminus
* Author: hoergen
*
* List here all variables which will get overwritten through this scheme
* Overwrites: nav_bg, nav_icon_color, link_color, background_color, contentbg_transp
*/
$nav_bg = "#000b95";
$nav_icon_color = "#eee";
$link_color = "#000b95";
//$background_color = "#ededed";
//$login_bg_color = "#ededed";
$contentbg_transp = 100;

View File

@ -1,15 +0,0 @@
<?php
/*
* Name: Red
* Author: Rabuzarus
*
* List here all variables which will get overwritten through this scheme
* Overwrites: nav_bg, nav_icon_color, link_color, background_color, contentbg_transp
*/
$nav_bg = "#870000";
$nav_icon_color = "#f5f5f5";
$link_color = "#b50404";
$background_color = "#ededed";
$contentbg_transp = 95;

View File

@ -24,10 +24,9 @@ use Friendica\Network\HTTPException\NotModifiedException;
use Friendica\Util\Strings;
require_once 'view/theme/frio/theme.php';
require_once 'view/theme/frio/php/scheme.php';
require_once 'view/theme/frio/php/PHPColors/Color.php';
$scheme = '';
$schemecss = '';
$schemecssfile = false;
$scheme_modified = 0;
@ -35,7 +34,7 @@ $scheme_modified = 0;
* This script can be included when the maintenance mode is on, which requires us to avoid any config call and
* use the following hardcoded defaults
*/
$scheme = null;
$scheme = FRIO_DEFAULT_SCHEME;
$scheme_accent = FRIO_SCHEME_ACCENT_BLUE;
$nav_bg = '#708fa0';
$nav_icon_color = '#ffffff';
@ -52,7 +51,7 @@ if (DI::mode()->has(\Friendica\App\Mode::MAINTENANCEDISABLED)) {
DI::config()->reload();
// Default to hard-coded values for empty settings
$scheme = DI::config()->get('frio', 'scheme', DI::config()->get('frio', 'schema'));
$scheme = frio_scheme_get_current();
$scheme_accent = DI::config()->get('frio', 'scheme_accent') ?: $scheme_accent;
$nav_bg = DI::config()->get('frio', 'nav_bg') ?: $nav_bg;
$nav_icon_color = DI::config()->get('frio', 'nav_icon_color') ?: $nav_icon_color;
@ -71,7 +70,7 @@ if (DI::mode()->has(\Friendica\App\Mode::MAINTENANCEDISABLED)) {
DI::pConfig()->load($uid, 'frio');
// Only override display settings that have actually been set
$scheme = DI::pConfig()->get($uid, 'frio', 'scheme', DI::pConfig()->get($uid, 'frio', 'schema')) ?: $scheme;
$scheme = frio_scheme_get_current_for_user($uid);
$scheme_accent = DI::pConfig()->get($uid, 'frio', 'scheme_accent') ?: $scheme_accent;
$nav_bg = DI::pConfig()->get($uid, 'frio', 'nav_bg') ?: $nav_bg;
$nav_icon_color = DI::pConfig()->get($uid, 'frio', 'nav_icon_color') ?: $nav_icon_color;
@ -89,18 +88,9 @@ if (!$login_bg_image && !$login_bg_color) {
}
$login_bg_color = $login_bg_color ?: '#ededed';
// Now load the scheme. If a value is changed above, we'll keep the settings
// If not, we'll keep those defined by the scheme
// Setting $scheme to '' wasn't working for some reason, so we'll check it's
// not --- like the mobile theme does instead.
// Allow layouts to over-ride the scheme.
if (!empty($_REQUEST['scheme'])) {
$scheme = $_REQUEST['scheme'];
}
$scheme = Strings::sanitizeFilePathItem($scheme);
$scheme = Strings::sanitizeFilePathItem($scheme ?? '');
if ($scheme && ($scheme != '---')) {
if ($scheme != FRIO_CUSTOM_SCHEME) {
if (file_exists('view/theme/frio/scheme/' . $scheme . '.php')) {
$schemefile = 'view/theme/frio/scheme/' . $scheme . '.php';
require_once $schemefile;
@ -110,19 +100,6 @@ if ($scheme && ($scheme != '---')) {
}
}
// If we haven't got a scheme, load the default. We shouldn't touch this - we
// should leave it for admins to define for themselves.
// default.php and default.css MUST be symlinks to existing scheme files.
if (!$scheme) {
if (file_exists('view/theme/frio/scheme/default.php')) {
$schemefile = 'view/theme/frio/scheme/default.php';
require_once $schemefile;
}
if (file_exists('view/theme/frio/scheme/default.css')) {
$schemecssfile = 'view/theme/frio/scheme/default.css';
}
}
$contentbg_transp = $contentbg_transp != '' ? $contentbg_transp : 100;
// Calculate some colors in dependance of existing colors.

View File

@ -4,17 +4,9 @@
<div class="form-group field select">
<label for="id_{{$scheme.0}}">{{$scheme.1}}</label>
<select name="{{$scheme.0}}" id="id_{{$scheme.0}}" class="form-control">
<option value="---" {{if '---' == $scheme.2}}selected="selected"{{/if}}>{{$custom}}</option>
<optgroup label="{{$accented}}">
{{foreach $scheme.3 as $value => $label}}
<option value="{{$value}}" {{if $value == $scheme.2}}selected="selected"{{/if}}>{{$label}}</option>
<option value="{{$value}}" {{if $value == $scheme.2}}selected="selected"{{/if}}>{{$label}}</option>
{{/foreach}}
</optgroup>
<optgroup label="{{$legacy}}">
{{foreach $scheme.4 as $value => $label}}
<option value="{{$value}}" {{if $value == $scheme.2}}selected="selected"{{/if}}>{{$label}}</option>
{{/foreach}}
</optgroup>
</select>
</div>

View File

@ -41,6 +41,9 @@ const FRIO_SCHEME_ACCENT_PURPLE = '#a54bad';
const FRIO_SCHEME_ACCENT_GREEN = '#218f39';
const FRIO_SCHEME_ACCENT_PINK = '#d900a9';
const FRIO_DEFAULT_SCHEME = 'light';
const FRIO_CUSTOM_SCHEME = '---';
/*
* This script can be included even when the app is in maintenance mode which requires us to avoid any config call
*/