Closed (fixed)
Project:
Drupal core
Version:
8.0.x-dev
Component:
extension system
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
7 May 2014 at 14:47 UTC
Updated:
14 Mar 2016 at 10:54 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
Jeff Burnz commentedComment #2
dawehnerDoes this fix the issue for you?
Comment #3
Jeff Burnz commentedYes, it fixes the issue, looks good to me.
Comment #4
jhedstromThis is a re-roll + I added a test to illustrate the issue and the fix.
Comment #6
dawehnerGreat to have some test coverage ...
I'm a bit confused, what are the usecases for hidden themes, just curious ....
Comment #7
Jeff Burnz commented1) when a theme is useless as a front end theme, i.e. its just a base theme. However with themes now being installed, rather than just enabled, hiding them is not user friendly as the user can never uninstall the hidden theme.
2) you have a starter kit theme that is supposed to be copied somehow and not actually used, there are several themes like this in D7 and in D8 also. I.e the starterkit is not entirely viable as it is, it needs to be modified somehow in order to be a viable theme. You might want to hide these so users don't inadvertently blow up there sites.
How base themes are handled is rather lame in Drupal to be frank, there does not appear to be any way to switch off "set as default" or "settings" etc. Pretty basic stuff really.
Comment #8
dawehnerThank you for the explanation!
Do you remember maybe how it used to be handled in Drupal 7?
Comment #11
jhedstromAnd back to RTBC.
Comment #12
alexpottThe documentation in InfoParserInterface::parse() needs updating to reflect the fact the theme's support the hidden property (again).
Comment #13
jhedstromUpdated documentation.
Comment #14
mile23The patch in #13 doesn't apply, so it'll need a reroll if it's still an issue.
I tried to repro this with adaptivetheme.
I grabbed the 8.x version of
adaptivetheme.I enabled
at_coreto see if it appeared in the Settings page.As it turns out, yes, it does, because it doesn't have
hidden: truein.info.yml. :-)So I disabled it and then set
hidden: truein AT Core's.info.ymlfile.AT Core then didn't appear in the list of uninstalled themes, which I believe is expected behavior.
But... I couldn't re-enable it or the supplied
at_generatorsubtheme, due to this error:Unable to install at_core, responsive_image.mappings.at_content_image, responsive_image.mappings.at_teaser_image already exist in active configuration.So the real bug here appears to be that these config elements aren't cleared when we uninstall. I'm not sure whether that's core, or whether it's
adaptivetheme, though I'd bet on the latter.Unable to repro.
Comment #15
drupradJust re-rolled the patch for comment #13
Comment #16
drupradMerge failed find attached screen for reference.
+needs reroll
Comment #17
drupradI am working on reroll
Comment #18
drupradre-rolled the patch for comment #15
Comment #19
drupradUnassigned as reroll completed, so someone can review.
Comment #20
Jeff Burnz commented#14not sure whats going on there, but AT deliberately does not have hidden: true because there is no easy way to uninstall a theme that is hidden, also I think you may have missed the actual bug - its when hidden: true is set the link to the supposedly hidden themes settings is still visible in the secondary links.
With regards to the responsive image style config, indeed this is a bit of a mess and is another unrelated bug IMO, unless there is some way for us to clean up the config on uninstall, but surely we can't be expected to do this?
Comment #21
dawehnerThis was solved in #2574975: Allow (base-)themes to be excluded from the UI (e.g. blocks, Appearance).