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

Use image listing from registry-image-widgets #1136

Merged
merged 4 commits into from
Jun 13, 2017

Conversation

stefwalter
Copy link
Contributor

This shares code with the Registry Console and Openshift Web Console for the ImageStream image listing.

@stefwalter
Copy link
Contributor Author

Openshift Web Console View:

screenshot from 2017-01-18 20-55-26

@stefwalter
Copy link
Contributor Author

Existing Registry Console Views:

screenshot from 2017-01-18 20-54-31

screenshot from 2017-01-18 20-54-36

@stefwalter
Copy link
Contributor Author

CC @andreasn @jwforres

@stefwalter
Copy link
Contributor Author

CC @dperpeet

@spadgett
Copy link
Member

Very cool

@jwforres
Copy link
Member

I see this is pulling in gettext now @stefwalter is this going to cause the image stream bits to be translated when the rest of the console is not? or does something have to be enabled for gettext to use a different language other than the default

@stefwalter
Copy link
Contributor Author

I see this is pulling in gettext now @stefwalter is this going to cause the image stream bits to be translated when the rest of the console is not? or does something have to be enabled for gettext to use a different language other than the default.

It won't. The because project does not initiallize angular-gettext ... nor does the project load any translations.

@jwforres
Copy link
Member

jwforres commented Jan 19, 2017 via email

@jwforres
Copy link
Member

When no tags have been pushed it says "No image streams are present" seems like that should say "No tags are present"

image-stream-1

When no tags have been pushed the Image count is empty instead of saying '0'. Also noticed it is inconsistent on this screen whether the labels have a ':' after them. The rest of the console does have ':' after any labels.

image-stream-2

This version of the image widgets has some kind of issue with the image layers widget, when i revert back to master and use the image widgets version that points to this same image shows up just fine in the layers widget:

image-stream-3

@jwforres
Copy link
Member

When I hover over the dropdown arrow it messes up the row highlighting, part of the row is gray and part of the row is blue.

image-stream-4

@jwforres
Copy link
Member

The "pushed from" in the originates from column is not on the same horizontal as the tag and the SHA, which creates a strange white gap, seems like it should move up.

image-stream-5

@jwforres
Copy link
Member

The text "To push to an image to this image stream:" isnt right, should be "To push an image to this image stream:"

@jwforres
Copy link
Member

What is expanding a tag supposed to do? I thought maybe it was supposed to show the history for that tag, but when I expand it then it isn't showing me anything different, even when I know a tag has had multiple images pushed to it. It just seems to add a line between the sha and the timestamp.

@jwforres
Copy link
Member

The sha causes problems at various responsive sizes, pushing content off screen. It needs to have word-break on it

image-stream-6

@jwforres
Copy link
Member

I'm actually seeing similar issues on the image widget page with long identifiers pushing off the page at mobile

@jwforres
Copy link
Member

When no images are pushed yet, the table doesn't extend all the way to the right of the screen, as soon as there as an image it does

image-stream-7

@andreasn
Copy link

There is a couple of things I'm not currently satisfied about how this view works, also in the registry.

  • Tags appearance looks out of place. Maybe this would do well from using the badge look. http://www.patternfly.org/pattern-library/widgets/#badges
  • The rows are very tall.
  • The list view looks and works a bit different from both Cockpit and Patternfly (mostly because it's older code from before we refined the appearance of things) http://www.patternfly.org/pattern-library/content-views/list-view/#/expanding-rows
  • The SHA string is reeeeally long and just breaks the rows apart. This will only get worse with SHA512. I understand the idea about not hiding part of it (opening the question of "will I be able to copy this out?"), but maybe we can ellipsis it a bit and then show the full value on hover.

I'll put together a suggestion in a mockup for how to solve these.

@stefwalter
Copy link
Contributor Author

Thanks for the review @andreasn. May I suggest changes as a follow up pull request, and the first one gets the two projects mostly in sync on the view? Are you okay with that @jwforres

@jwforres and @andreasn: The inline expansion stuff wasn't supposed to show up in the Openshift Web Console. That's a bug.

@andreasn In the registry the entire sha256 is necessary as the docker command line doesn't support abbreviated SHA identifiers for images. But perhaps that's a place where the Openshift Web Console can diverge and the implementation can take a CSS option to truncate this ... just thinking outloud.

@andreasn
Copy link

I'm OK with doing it as a followup if @jwforres is.

@stefwalter
Copy link
Contributor Author

When no tags have been pushed it says "No image streams are present" seems like that should say "No tags are present"

Fixed.

When no tags have been pushed the Image count is empty instead of saying '0'.

Fixed.

Also noticed it is inconsistent on this screen whether the labels have a ':' after them. The rest of the console does have ':' after any labels.

The Registry Console doesn't use colons, and uses different styling for metadata/data. So to make it consistent I've just added these colons via CSS in the Openshift Web Console use of the widgets.

This version of the image widgets has some kind of issue with the image layers widget, when i revert back to master and use the image widgets version that points to this same image shows up just fine in the layers widget:

Fixed. This was a regression from when we marked is translatable. Now works.

When I hover over the dropdown arrow it messes up the row highlighting, part of the row is gray and part of the row is blue.

This doesn't happen for me. Maybe I tagged the bower registry-image-widgets build incorrectly or something. Should work now. The dropdown arrow is not part of the changes we intended to share with the Openshift Web Console. The Registry Console has a listing pattern that allows expansion of data inline, but that doesn't need to be carried over into the Openshift Web Console.

The "pushed from" in the originates from column is not on the same horizontal as the tag and the SHA, which creates a strange white gap, seems like it should move up.

I'll leave this up to @andreasn's follow up pull request.

The text "To push to an image to this image stream:" isnt right, should be "To push an image to this image stream:"

Fixed.

When no images are pushed yet, the table doesn't extend all the way to the right of the screen, as soon as there as an image it does

Fixed.

The sha causes problems at various responsive sizes, pushing content off screen. It needs to have word-break on it

Added word-break.

@stefwalter
Copy link
Contributor Author

stefwalter commented Jan 20, 2017

Everything fixed except for the row redesign, which should be done as a follow up, so this feature can get "in" before the feature freeze.

@openshift-bot openshift-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Feb 2, 2017
@pweil-
Copy link
Contributor

pweil- commented Feb 3, 2017

@stefwalter please rebase

@jwforres @spadgett bump for another review since a lot of things have been fixed 👍

@stefwalter
Copy link
Contributor Author

Rebased.

@stefwalter
Copy link
Contributor Author

stefwalter commented Feb 6, 2017

However origin-web-console no longer authenticates my version of openshift, and I'm running out of time to sort that all out, so I've been unable to do any smoke test after the rebase.

[root@f1 ~]# openshift version
openshift v1.4.1+3f9807a
kubernetes v1.4.0+776c994
etcd 3.1.0-rc.0

@openshift-bot openshift-bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Feb 6, 2017
@petervo
Copy link
Contributor

petervo commented Jun 12, 2017

@jwforres, Thanks, rebased and updated this one.

@jwforres
Copy link
Member

thanks @petervo

I'm seeing two bugs currently

  1. When you hover over a row the visual style is a little weird where the blue hover color appears on three sides of the tag but not on the left. This one is lower severity and I'd be ok fixing it in a follow-up as long as we get an issue open to track it.
    hover-state

  2. Bad overflow can occur at mobile res in a couple places. The table can overflow, and the docker pull commands can overflow.
    overflow-mobile

</tr>
</tbody>
</table>
<registry-imagestream-body imagestream="imageStream">
Copy link
Member

Choose a reason for hiding this comment

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

sorry I didn't notice it before, but the switch to use registry-imagestream-body changes the behavior of how annotations are presented to the user, everywhere else in the UI we do not show these to the user unless they click a link to reveal them. This is because annotations are typically intended for machine use and not end user facing.

@petervo
Copy link
Contributor

petervo commented Jun 12, 2017

@jwforres, for the docker commands do you want ellipsis or line wrapping with small sizes. Line wraping looks weird but is better for copy/paste. Is that ok?

<dt>Docker pull spec:</dt>
<dd>{{imageStream.status.dockerImageRepository}}</dd>
</dl>
<annotations annotations="imageStream.metadata.annotations"></annotations>
Copy link
Member

Choose a reason for hiding this comment

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

for reference, this is the annotations directive we use today that handles the show/hide behavior plus how we format annotations when visible

@jwforres
Copy link
Member

jwforres commented Jun 12, 2017 via email

petervo and others added 3 commits June 13, 2017 02:28
This starts work to share code between the Registry Console and
Openshift Web Console for the imagestream page.

In particular this commit changes the body and push sections
of the page.
This shares code with the Registry Console and Openshift Web
Console for the ImageStream image listing.
In the Registry, they use styling rather than colons to
differentiate metadata from data. However we can simply
add colons via CSS to make these parts consistent with
the rest of the Openshift Web Console.
@petervo petervo force-pushed the image-stream-from-registry branch from e89a66b to 13ac6a9 Compare June 13, 2017 09:32
@petervo
Copy link
Contributor

petervo commented Jun 13, 2017

@jwforres, opened openshift/registry-image-widgets#8 and built this with that so you can check this out first before merging the other one.

Once that is in i can do a rebuild

@openshift-bot openshift-bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 13, 2017
@jwforres
Copy link
Member

looks like the table still has an issue at iphone 5 res which is 320px width

the quick fix is in imagestream.html to wrap <registry-imagestream-body> in a <div class="table-responsive" style="padding: 0 5px;">

this will prevent the layout like the nav from getting messed up when the table overflows the page, it wraps the table in a scrollable content area with a border when at mobile resolutions

if you are fine just making that change in this PR then we can merge the PR to image-registry-widgets and cut that release, let me know

@petervo petervo force-pushed the image-stream-from-registry branch from 13ac6a9 to b4bf383 Compare June 13, 2017 14:10
@petervo
Copy link
Contributor

petervo commented Jun 13, 2017

@jwforres pushed an update that fixes it for me.

@jwforres
Copy link
Member

@petervo I have your latest changes but I can still reproduce it with a tag name that is long

long-tag-name

@petervo petervo force-pushed the image-stream-from-registry branch from b4bf383 to 7f36fa2 Compare June 13, 2017 15:09
@petervo
Copy link
Contributor

petervo commented Jun 13, 2017

@jwforres updated again.

@jwforres
Copy link
Member

thanks LGTM now, think we can merge the other PR

@jwforres
Copy link
Member

I'll LGTM the other PR and you can merge/release it if you are ready

@petervo
Copy link
Contributor

petervo commented Jun 13, 2017

@jwforres, i don't have access to marge or deploy to npm. I'll see if can I track down someone who does.

@jwforres
Copy link
Member

@petervo ah k i can merge and create the tag for bower, i dont think i have the npm access but bower is all we need to the console

@jwforres
Copy link
Member

@petervo ok 0.0.9 should be available for bower now

@petervo petervo force-pushed the image-stream-from-registry branch from 7f36fa2 to 3ac0f90 Compare June 13, 2017 15:52
@jwforres
Copy link
Member

[merge]

@openshift-bot
Copy link

Evaluated for origin web console merge up to 3ac0f90

@openshift-bot
Copy link

openshift-bot commented Jun 13, 2017

Origin Web Console Merge Results: SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pull_requests_origin_web_console/1511/) (Base Commit: 9c3ecd1)

@openshift-bot openshift-bot merged commit cf4b122 into openshift:master Jun 13, 2017
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.

7 participants