Skip to content

Theming: Fix missing color usage - #771

Merged
rullzer merged 5 commits into
masterfrom
theming-fixes
Aug 26, 2016
Merged

Theming: Fix missing color usage#771
rullzer merged 5 commits into
masterfrom
theming-fixes

Conversation

@juliusknorr

@juliusknorrjuliusknorr commented Aug 8, 2016

Copy link
Copy Markdown
Member
  • Theming: colorize primary buttons
  • Remove internal from getThemingDefaults, maybe @LukasReschke can check if that makes sense
  • Theming: colorize jquery ui elements jQuery UI not affected by Theming #830
  • Theming: fix federated sharing button color
  • federated sharing button text color / custom logo

requires #1026

@jancborchardt

Copy link
Copy Markdown
Member

cc @Mar1u5@nickvergessen @nextcloud/designers @nextcloud/theming please help reviewing :)

@juliusknorr

Copy link
Copy Markdown
MemberAuthor

@jancborchardt still not complete for review ;) - we need #1026 for all the remaining theming pull requests. But i'll rebase this one later today and make it ready.

@juliusknorrjuliusknorr added 3. to review Waiting for reviews and removed 2. developing Work in progress labels Aug 25, 2016
@juliusknorr
juliusknorrforce-pushed the theming-fixes branch 2 times, most recently from 6870e43 to 6b68f3bCompareAugust 25, 2016 11:19
@juliusknorr

Copy link
Copy Markdown
MemberAuthor

CI is happy, ready for review @nextcloud/designers @nextcloud/theming

I've included #1026 for easier testing, will rebase to master once this is merged.

$theme = \OC::$server->query("ThemingDefaults");
$color = $theme->getMailHeaderColor();
$textColor = "#ffffff";
if($theme instanceof \OCA\Theming\ThemingDefaults) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will throw an Exception if the theming app is disabled.

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nickvergessen Hmm, I've disabled it, but there was no Exception for me.

Sould I just check if the app is enabled like this:

if(\OC::$server->getAppManager()->isEnabledForUser("theming")) { ...

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah that's better since it's more explicit.

@juliusknorr

Copy link
Copy Markdown
MemberAuthor

@nickvergessen Thanks for the comments. I've just pushed an update.

$textColor = "#ffffff";
if(\OC::$server->getAppManager()->isEnabledForUser("theming")) {
$logoPath = $theme->getLogo();
$util = \OC::$server->query("\OCA\Theming\Util");

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could throw an exception OCP\AppFramework\QueryException, better catch it so the page still displayes 😉

@juliusknorr

Copy link
Copy Markdown
MemberAuthor

@nickvergessen ok, i've added a try-catch-block as well.

@oparoz

Copy link
Copy Markdown
Member

Does that fix media type icons? That's the biggest problem right now.

@LukasReschke

Copy link
Copy Markdown
Member

@oparoz#840

@oparoz

Copy link
Copy Markdown
Member

Awesome, thanks.

@rullzer

Copy link
Copy Markdown
Member

#1026 is in. @juliushaertl can you rebase?

@juliusknorr

Copy link
Copy Markdown
MemberAuthor

@rullzer done.

@nickvergessen

Copy link
Copy Markdown
Member

👍 works and looks nice. Thanks!

@@ -66,7 +65,7 @@ class='js-gs-share social-gnu'>
<?php p($l->t('HTML Code:')); ?>
<xmp><a target="_blank" rel="noreferrer" href="<?php p($_['reference']); ?>"
style="padding:10px;background-color:#0082c9;color:#fff;border-radius:3px;padding-left:4px;">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You forgot to use the colors here? It still uses blue+white instead of what the preview shows.

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah also forgot to apply the style changes here. I'll fix that.

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nickvergessen ok, i've updated the html code as well.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@nickvergessen

Copy link
Copy Markdown
Member

Second review, @rullzer ?

@rullzer

Copy link
Copy Markdown
Member

LGTM

@rullzer
rullzer merged commit 53725d4 into masterAug 26, 2016
@rullzer
rullzer deleted the theming-fixes branch August 26, 2016 13:02
@MorrisJobkeMorrisJobke mentioned this pull request Sep 21, 2016
67 tasks
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

@juliusknorr@jancborchardt@oparoz@LukasReschke@rullzer@nickvergessen