Skip to content

Edit/Create Projects on page in a popup #1901

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

Merged
merged 1 commit into from
Aug 8, 2017

Conversation

jeff-phillips-18
Copy link
Member

@jeff-phillips-18 jeff-phillips-18 commented Aug 2, 2017

@jeff-phillips-18
Copy link
Member Author

I have not removed the create project and/or edit project pages. Not sure if we want them removed as part of this PR or not.

Create Project
</a>
</button>
<origin-modal-popup shown="showNewProjectPanel" modal-title="Create Project" on-close="closeNewProjectPanel()">
Copy link
Member

Choose a reason for hiding this comment

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

As much as possible, I'd like to be consistent in how we handle callbacks for our components. It looks like shown and on-close are handled differently here (as well as on-cancel for create-project).

Copy link
Member Author

Choose a reason for hiding this comment

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

I could change either of the components but that would need to be done there and not here. Most of the components bind functions using < or =, I used & for the new origin-modal-popup component. Should I change that?

Copy link
Member

@spadgett spadgett Aug 4, 2017

Choose a reason for hiding this comment

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

Right, understood. I suggest we should use <. I'd at least like to be consistent with callbacks inside the same component. Here shown is < and onClose is & in the same component.

Sorry, I missed this reviewing openshift/origin-web-common#135

(As an aside, I find callbacks in Angular components generally weird and confusing...)

Copy link
Member

Choose a reason for hiding this comment

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

Wondering if onShown is not better as well for consistent naming.

Copy link
Member Author

Choose a reason for hiding this comment

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

shown is a flag not a function.

Copy link
Member Author

Choose a reason for hiding this comment

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

I can rename the controller variable to reduce confusion.

Copy link
Member

Choose a reason for hiding this comment

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

Ah OK please disregard then :)

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed and renamed the variables.

@@ -101,7 +105,7 @@ <h2 class="h1">
</a>
</li>
<li role="menuitem">
<a ng-href="project/{{project.metadata.name}}/edit?then=./">
<a ng-href="#" ng-click="editProject(project)">
Copy link
Member

Choose a reason for hiding this comment

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

<a href="" ng-click="editProject(project)">

Copy link
Member Author

Choose a reason for hiding this comment

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

fixed

$scope.showEditProjectPanel = false;

$scope.editProject = function(project) {
$scope.edittingProject = project;
Copy link
Member

Choose a reason for hiding this comment

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

editingProject

Copy link
Member Author

Choose a reason for hiding this comment

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

fixed

@jeff-phillips-18 jeff-phillips-18 force-pushed the project branch 2 times, most recently from c618746 to 976a951 Compare August 4, 2017 15:20
@spadgett
Copy link
Member

spadgett commented Aug 7, 2017

I have not removed the create project and/or edit project pages. Not sure if we want them removed as part of this PR or not.

If we remove them, we might think about redirects for the old URLs (maybe just /create-project) in case someone has a link / bookmark. Not too worried about it for this PR.

@@ -25,9 +25,13 @@ <h2 class="text-center">Loading...</h2>
<h1>My Projects</h1>
<div class="projects-options">
<div class="projects-add" ng-if="canCreate">
<a href="create-project" class="btn btn-md btn-primary">
<button ng-click="createProject()" class="btn btn-md btn-primary">
<span class="fa fa-plus"></span>
Copy link
Member

Choose a reason for hiding this comment

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

aria-hidden="true"

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed

@@ -101,7 +105,7 @@ <h2 class="h1">
</a>
</li>
<li role="menuitem">
<a ng-href="project/{{project.metadata.name}}/edit?then=./">
<a ng-href="" ng-click="editProject(project)">
Copy link
Member

Choose a reason for hiding this comment

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

nit: href=""

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed

@spadgett
Copy link
Member

spadgett commented Aug 7, 2017

@jeff-phillips-18
Copy link
Member Author

Created issue #1917 to remove the pages.

@jeff-phillips-18
Copy link
Member Author

Removed WIP status now that we have updated the version of origin-web-common.
Ready for final reviews/merge.

@jeff-phillips-18 jeff-phillips-18 changed the title WIP: Edit/Create Projects on page in a popup Edit/Create Projects on page in a popup Aug 8, 2017
@spadgett
Copy link
Member

spadgett commented Aug 8, 2017

Hey @jeff-phillips-18. I pulled the changes down, and everything works well. Thanks.

A couple of small style questions for @openshift/team-ux-review. I won't block the PR on any of these, particularly if they require origin-web-common changes. Just small things I noticed.

  1. Should there be any margin between the + and the text on the button? I'm not sure if there is a standard style for this in Patternfly.

No margin (current):

openshift web console 2017-08-08 08-15-56

2px margin:

openshift web console 2017-08-08 08-17-48

  1. Should we remove input-lg and btn-lg styles now that the form is only in a dialog?

input-lg (current):

openshift web console 2017-08-08 08-18-59

Without input-lg:

openshift web console 2017-08-08 08-20-42

  1. I noticed the dialog is spaced farther from the kebab than the actions dropdown and feels a little too far away. I assume the spacing should be about the same.

@spadgett
Copy link
Member

spadgett commented Aug 8, 2017

Added Trello card https://trello.com/c/djoHeMob for QE testing.

@spadgett
Copy link
Member

spadgett commented Aug 8, 2017

[test] to make sure this doesn't break our e2e tests

@spadgett
Copy link
Member

spadgett commented Aug 8, 2017

It looks like we do have padding on the button in the landing page, so we should be consistent here so they look the same.

screen shot 2017-08-08 at 9 54 35 am

@jeff-phillips-18
Copy link
Member Author

Fixed the create button spacing.

Added issue for input and button sizes: openshift/origin-web-common#142

Copy link
Member

@spadgett spadgett left a comment

Choose a reason for hiding this comment

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

LGTM except for the typo

@@ -41,3 +41,7 @@
text-decoration: none;
}
}

.icon-button-text {
padding-left: 4px;
Copy link
Member

Choose a reason for hiding this comment

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

👍 thanks for making this a generic style

@@ -101,7 +105,7 @@ <h2 class="h1">
</a>
</li>
<li role="menuitem">
<a ng-href="project/{{project.metadata.name}}/edit?then=./">
<a g-href="" ng-click="editProject(project)">
Copy link
Member

Choose a reason for hiding this comment

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

typo: g-href

Copy link
Member Author

Choose a reason for hiding this comment

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

ugh

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed

@jeff-phillips-18
Copy link
Member Author

Fixed popup vertical positioning for projects with descriptions.

@openshift-bot
Copy link

Evaluated for origin web console test up to 8a5d4fa

Copy link
Member

@spadgett spadgett left a comment

Choose a reason for hiding this comment

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

LGTM

@openshift-bot
Copy link

Origin Web Console Test Results: SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pull_request_origin_web_console/37/) (Base Commit: 8cb608b) (PR Branch Commit: 8a5d4fa)

@spadgett
Copy link
Member

spadgett commented Aug 8, 2017

[merge]

@openshift-bot
Copy link

openshift-bot commented Aug 8, 2017

Origin Web Console Merge Results: Waiting: You are in the build queue at position: 1

@openshift-bot
Copy link

Evaluated for origin web console merge up to 8a5d4fa

@openshift-bot openshift-bot merged commit 419c1e6 into openshift:master Aug 8, 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.

4 participants