Open scottsawyer opened 6 years ago
Hi @scottsawyer, Your idea looks cool! What is your idea on management UI? I'm not sure when I'd have the time to look at this closely so feel free to make a start if you want to!
@JoryHogeveen ,
Thanks for the response. I haven't looked over the code, but I think it could introduce a "group" type of abstraction, each group represents a set of css classes.
group[] = [
'id' => $group_id,
'label' => __( 'My styling group label' )
];
class[] = [
'group' => $group_id,
'classes' => ['background-blue', 'background-red',]
];
So, the UI would show a field to create a group (text input). Then you edit the group to add classes.
Group Name: [ enter group name ] (add classes)
So, I could then have a series of inputs on the widgets screen:
Background Colors
Text Colors
Title Align
Unfortunately, I don't have time to work on this for my current project, but I like the plug-in, and I will likely use it for future projects, so if you haven't started anything by that time, maybe I can contribute more.
Predefined widget class groups / radio buttons.
I have a set of classes that affect different CSS properties, and would like them to be grouped since they are mutually exclusive: Group 1 ( text color )
Group 2 ( background color )
Group 3 ( text alignment )
It would be great to have 2 additional features with predefined classes:
If I could define Groups in my $theme_classes array like so:
Then on the Widget form, the options within each group would be converted to an array of radio buttons ( or select options ). This would help prevent users from setting more than one background color, etc. They would be able to set 1 background color, 1 text color, 1 alignment, and not have to worry about setting conflicting styles ( which could have unpredictable results ).
A further enhancement could be to add titles to each group:
And to make it even nicer for users, the classes themselves could be given labels:
I think this would be a kick ass addition. This feature could even be exposed in the UI.