theming

Material-Ui theming issue with React components imported from a library

生来就可爱ヽ(ⅴ<●) 提交于 2021-01-29 13:28:52
问题 I'm facing an issue, and I searched in Google to find answer with no chance. I have created a React / material Ui library, with a lot of components extended from Material UI. This library belongs to a yarn workspace, together with a main app. The library is built with webpack and babel. In the main app, I'm importing these components and try to apply the global theme, created in the main app, using ThemeProvider. It's seems to work as first sight. When the lib component is alone in the page,

Best way to dynamically change theme of my Vue.js SPA?

℡╲_俬逩灬. 提交于 2020-08-24 06:22:05
问题 So I think the title is enough explaination: I would like to dynamically theme my whole application. Maybe this means to change color of all divs when I press a specific button, or change the whole webapp's colors when a specific user logs in. Just to give some insights on what I am currently working on I will say that I have built a Vue.js app that uses many libraries, including one called Element-ui which already has a theming option built onto it. The problem is that it's written in scss

Best way to dynamically change theme of my Vue.js SPA?

爷,独闯天下 提交于 2020-08-24 06:21:39
问题 So I think the title is enough explaination: I would like to dynamically theme my whole application. Maybe this means to change color of all divs when I press a specific button, or change the whole webapp's colors when a specific user logs in. Just to give some insights on what I am currently working on I will say that I have built a Vue.js app that uses many libraries, including one called Element-ui which already has a theming option built onto it. The problem is that it's written in scss

Scss theming depends on body class with predefined variables

╄→гoц情女王★ 提交于 2020-05-15 11:43:07
问题 I want to have checkbox which, when you clicked it add class to body tag for example like 'dark-theme' or 'light theme'. The problem is that theming requirment is appeared after i styled all elements, and it would be suicide to change each element styles now. Please help $color-white: #ffffff; $color-black: #000000; // Dark $color-green: #328332; $color-red: #a23232; $color-background-dark: #212734; $color-backgound-light: #31394c; $color-text: rgba(255, 255, 255, 0.3); $color-text-darker:

Symfony 2 - Form theming - Overriden block renders two times

我只是一个虾纸丫 提交于 2020-01-17 06:26:08
问题 I'm trying to customize a theme form submit button but this button is being rendered two times. The first time when the block is overriden and the second time when i'm using it in my form. Here is the code and the result. Thanks a lot. {# src/YagoQuinoy/Simple/BlogBundle/Resources/views/Blog/searchArtciles.html.twig #} {% form_theme form _self %} {% block submit_widget %} <button><i class="fa fa-bicycle"></i></button> {% endblock submit_widget %} {{ form_start(form, {'attr': {'novalidate':

How to override template “folder_full_view_item.pt” only for a Custom Type?

百般思念 提交于 2020-01-13 14:55:33
问题 This question has evolved in a confusing way. Some of its parts though, and specially some answers, might be useful for someone. Therefore I'll let this question unmodified and I'll try to reformulate the question here. Overriding the template folder_full_view_item.pt with z3c.jbot will override the template for all Content Types. How do I override it only for a single Content Type MyType in a Product with many types? Having the following structure: Folder (layout=folder_full_view) Document

Is it possible to use Twig addClass with condition?

此生再无相见时 提交于 2020-01-06 08:06:10
问题 In Twig, it's easy to add dynamic classes to elements. But instead of duplicate rules settings , I wonder if I could use condition on element type to use the same "set" array like this: {% set champ5_classes = [ 'label-' ~ node.field_liens_vdl.fieldDefinition.name | replace({"_" : "-"}), ***if it's a UL, add this class :*** 'liste-' ~ node.field_liens_vdl.fieldDefinition.name | replace({"_" : "-"}), ]%} and then apply it as usual: <ul {{ champ5_attribute.addClass(champ5_classes) }}></ul>

GTK3: Getting a style's class property

你离开我真会死。 提交于 2020-01-05 08:07:49
问题 I'm trying to get the text color of a class of a GTK style. I have a GtkStyleContext with the widget path and the classes that I want to get their properties. GtkWidgetPath* widgetPath = gtk_widget_path_new (); gtk_widget_path_append_type(widgetPath, GTK_TYPE_WINDOW); gtk_widget_path_iter_set_name(widgetPath, -1 , "UnityPanelWidget"); GtkStyleContext *context = gtk_style_context_new(); gtk_style_context_set_path(context, widgetPath); gtk_style_context_add_class(context, "gnome-panel-menu-bar"

GTK3: Getting a style's class property

心已入冬 提交于 2020-01-05 08:07:03
问题 I'm trying to get the text color of a class of a GTK style. I have a GtkStyleContext with the widget path and the classes that I want to get their properties. GtkWidgetPath* widgetPath = gtk_widget_path_new (); gtk_widget_path_append_type(widgetPath, GTK_TYPE_WINDOW); gtk_widget_path_iter_set_name(widgetPath, -1 , "UnityPanelWidget"); GtkStyleContext *context = gtk_style_context_new(); gtk_style_context_set_path(context, widgetPath); gtk_style_context_add_class(context, "gnome-panel-menu-bar"

React component theme using sass variables depending on React prop value

旧巷老猫 提交于 2020-01-05 04:31:12
问题 I cannot find better solution for theming. I have a sass-file with variables: vars.scss: $colors: ( dark: ( theme1: #0096dc, theme2: #eb8200, … ), … ); For now I pass theme prop to all components which should have some styling depending on which page user is viewing. In React I build classname like this: <div className={styles[`button${theme ? `-${theme}` : ``}`]}>{children}</div> and in sass I do: @import 'vars'; .button{ /* basic styles */ font-size: 14px; border: 1px solid; @each $theme,