Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugins: Include action buttons and icon in the plugin-item edit mode #1554

Merged
merged 7 commits into from
Dec 21, 2015

Conversation

johnHackworth
Copy link
Contributor

fix #413
fix #1206

This PR changes the layout of the plugin items in the users plugins list, so it includes both the action toggles and the plugin icon:

Before:
image

After:
image

How to test:

  1. Go to http://calypso.dev:3000/plugins/
  2. Select any of your jetpack sites
  3. Click on 'manage'.
  4. You should keep seeing both action toggles and plugin icon

ping @enejb @rickybanister

@johnHackworth johnHackworth added [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. [Status] Needs Design Review Add this when you'd like to get a review / feedback from the Design team on your PR Jetpack Plugins labels Dec 14, 2015
@johnHackworth johnHackworth self-assigned this Dec 14, 2015
@johnHackworth johnHackworth force-pushed the update/plugin-item-selectable-layout branch from 2f6eee6 to 5b2d59b Compare December 14, 2015 17:40
@enejb
Copy link
Member

enejb commented Dec 14, 2015

I tried it and in the bulk manage mode having the toggles feels kind of strange. Since there are so many things to click on. In the original design we just had visibility of the state and not toggles. Could we have an updated version of the mockup where we show the 3 possible stats. active, not active and disabled.

From #413
image

@johnHackworth
Copy link
Contributor Author

hmm, I may have missinterpreted that mockup, yeah! I'll change this PR to include just a visual indicator instead of the full working toggle!

@rickybanister
Copy link

Ooops, I missed this PR earlier. Glad to see the icons back.

I remember the design for the indicator, but I'm curious if we could just see the actions be disabled prior to building out those indicators.

I picture clicking the bulk edit button, the checkboxes slide in (once we have time to do a bit of animation), and the individual actions simple are disabled while bulk editing. We already have disabled states built and they would serve to show the current status of each plugin.

It seems easier to give that a try before building this (and I don't think these are very visually clear—this isn't a standard interface or indicator).

@johnHackworth
Copy link
Contributor Author

What do you mean with "we already have disabled states built", rick? I mean, if I'm not wrong, the only 'disabled' states those toggles have is the one we use for avoiding any interaction in the feature examples, but the look is the same than if they were fully functional. This is how they would look with the funcionality disabled:

image

They look great, but since the visuals are the same than when they are working, wouldn't it be a little missleading for the user? Maybe we could add a external css making them semi transparent or something when they couldn't be clicked on ..

@johnHackworth johnHackworth force-pushed the update/plugin-item-selectable-layout branch from 5b2d59b to bd790ed Compare December 15, 2015 09:47
@johnHackworth
Copy link
Contributor Author

Quick test with opacity:

Normal mode:
image

Bulk edit mode:
image

@johnHackworth
Copy link
Contributor Author

fun with filters!

This is with

        .plugin-item__actions {
            opacity: 0.3;
            filter: grayscale(70%);
        }

I've commited this version just in case you want to experiment a little, @rickybanister

image

@rickybanister
Copy link

@johnHackworth I think I sort of tricked myself—the inactive state of the toggle has disabled styles, but the active state of the toggle does not. I like where you're going with the opacity, BUT I think we should make a change in the toggle component to allow us to disable an active toggle (meaning: the toggle is always one, but cannot be interacted with). We should probably also make sure the labels have sensible defaults within the toggle component—right now they are custom to Plugins and cannot be reused elsewhere.

I'll take a look at the branch a little later, but perhaps we'd want to do the refactoring of toggle before getting this merged. Or maybe we make this PR just about the icons for now.

@johnHackworth
Copy link
Contributor Author

yeah, refactoring toggles to include a disabled state before mergin this one sounds the way to go. Also, that way maybe we could use the new disabled state in the plugins feature gates, so we can ditch the "isMock" property, which is pretty awful ...

@johnHackworth
Copy link
Contributor Author

@rickybanister it turned out that you were right ... there's a 'disabled' state from toggles... it's just that we were not including that property in the wrapper we use on plugins (plugin-actions). I've added it and now we can disable the toggles when on bulk edit mode is on:

image

@rickybanister
Copy link

I haven't checked out the branch but it looks like those are disabled AND you have some opacity styles on top of them. We only need the disabled state ideally.

@johnHackworth
Copy link
Contributor Author

@rickybanister Not really... I only apply


    .is-disabled & {
        color: lighten( $gray, 30% );
    }

to the toggle label when bulk editing (since the label doesn't get affected by the 'disabled' property by default). But maybe the effect we are looking for is more similar to how it look without that?

image

@johnHackworth johnHackworth force-pushed the update/plugin-item-selectable-layout branch from adc23ef to 0cb0241 Compare December 16, 2015 17:54
@johnHackworth
Copy link
Contributor Author

I commited the version without that 'is-disabled' css class, just in case

@rickybanister
Copy link

Ah, I understand. I think you should bring back the

.is-disabled & { color: lighten( $gray, 30% ); }

styles for the label text. I went checking on the disabled toggle styles and realized we didn't set cursor: default on the toggle, which lead to #1688 and a bunch of other stuff getting removed.

This should be good to go once we change the text color back. Sorry for the run-around.

@johnHackworth johnHackworth force-pushed the update/plugin-item-selectable-layout branch from 0cb0241 to f75768b Compare December 16, 2015 20:28
@johnHackworth
Copy link
Contributor Author

@rickybanister ok, restored the lighter color for the disabled action labels! I think with you tackling all the toggles small improvements in #1688, this one should be pretty much ready to go, isn't it?

@rickybanister
Copy link

Yeah 🚢 this one. This is a great basis. Editing All is soooooo close.

@enejb
Copy link
Member

enejb commented Dec 17, 2015

I found 2 issues with this.
I think it is kind of hard to tell if a plugin is active or not.

screen shot 2015-12-16 at 17 53 13

To me it is not very clear that BuddyPress is not active and Akismet is.

The other issue that I found is that
There is a mouse over state on the toggles. Is that intentional? Also you get a pointer curser when you mouse over it. As if you should be able to toggle the item.

@enejb enejb force-pushed the update/plugin-item-selectable-layout branch from f75768b to 5e63b99 Compare December 17, 2015 02:09
@enejb
Copy link
Member

enejb commented Dec 17, 2015

I just rebased this so.

@johnHackworth
Copy link
Contributor Author

about knowing if a plugin is active or not when you are in bulk edit mode... well, yeah, you're right... but this is also a problem that we have had in all the previous versions (including current production's one:
image

). So maybe we should do something to fix it (but not in this PR :) )

The cursor over the disabled toggles should be fixed once rebased, @rickybanister fixed it in another PR

@johnHackworth johnHackworth force-pushed the update/plugin-item-selectable-layout branch 2 times, most recently from 7769559 to 88d5e24 Compare December 17, 2015 11:12
@johnHackworth
Copy link
Contributor Author

@enejb oops, I wasn't getting what you were saying about the mouseover, I thought you were talking about the cursor... yeah, it seems that there was a bug in that form-toggle css... I have included the fix here ,it shouldn't change the color when disabled anymore

@rickybanister
Copy link

I agree with @johnHackworth here, we were hiding this info previously. I hope that if you're interacting with your site you'll see the toggles transition from active to disabled and it will be more clear.

We can also try creating active + disabled styles that are lighterned blue, but I'd like to do that in a future PR. Let's merge this and keep at it.

@enejb
Copy link
Member

enejb commented Dec 18, 2015

Rebased with master and removed curser pointers to show as default.
I still have some concerns but I think this is good to go code wise. Some of these issues could be address in a different PR.

👍

@enejb enejb added [Status] Ready to Merge and removed [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. labels Dec 18, 2015
@johnHackworth johnHackworth force-pushed the update/plugin-item-selectable-layout branch from e1295c0 to 8252efc Compare December 21, 2015 09:38
johnHackworth added a commit that referenced this pull request Dec 21, 2015
…e-layout

Plugins: Include action buttons and icon in the plugin-item edit mode
@johnHackworth johnHackworth merged commit b3b71d3 into master Dec 21, 2015
@johnHackworth johnHackworth deleted the update/plugin-item-selectable-layout branch December 21, 2015 09:51
@lancewillett lancewillett removed the [Status] Needs Design Review Add this when you'd like to get a review / feedback from the Design team on your PR label Oct 19, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Plugins: show plugin icons in bulk edit mode Jetpack Plugins: Show toggle statuses in Manage view
5 participants