Skip to content
This repository has been archived by the owner on Dec 8, 2022. It is now read-only.

Improved flyout demo & show iterator #2239

Merged
merged 13 commits into from
Jan 10, 2019
Merged

Conversation

Blackbaud-AlexKingman
Copy link
Contributor

@Blackbaud-AlexKingman Blackbaud-AlexKingman commented Jan 3, 2019

Added several examples of how to use flyout. Split complicated grid into its own demo to show how to use flyout with provider and iterator.

Addresses #2241

@Blackbaud-AlexKingman Blackbaud-AlexKingman changed the title Added rough draft of iterator demo Added rough draft of flyout iterator demo Jan 3, 2019
Copy link
Member

@Blackbaud-SteveBrush Blackbaud-SteveBrush left a comment

Choose a reason for hiding this comment

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

I feel like the complexity of the demo isn't great enough to merit a separate library. Some of the logic of stepping through the array could probably be simplified as well, which would make it even less complex. Overall looks great.

src/demos/flyout/flyout-demo.component.ts Outdated Show resolved Hide resolved
});

flyout.iteratorPreviousButtonClick
.takeUntil(this.openFlyoutStream)

Choose a reason for hiding this comment

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

You could use takeWhile in conjunction with a simple boolean property to reduce complexity.

.takeWhile(() => this.isFlyoutOpen)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

will do 👍

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not sure if I can do this because isFlyoutOpen becomes false before the animation finishes. It causes some weird issues where the flyout won't ever fully open.

Is using .takeUntil() causing performance issues or is it just the complexity you're worried about?

src/demos/flyout/flyout-demo.component.ts Outdated Show resolved Hide resolved
@codecov-io
Copy link

codecov-io commented Jan 7, 2019

Codecov Report

Merging #2239 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #2239   +/-   ##
=======================================
  Coverage   98.34%   98.34%           
=======================================
  Files          22       22           
  Lines         121      121           
  Branches       12       12           
=======================================
  Hits          119      119           
  Misses          2        2

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 619e6af...6d744e1. Read the comment docs.

@Blackbaud-AlexKingman Blackbaud-AlexKingman changed the title Added rough draft of flyout iterator demo Improved flyout demo & show iterator Jan 9, 2019
@Blackbaud-AlexKingman
Copy link
Contributor Author

This is ready for another pass. All "rough" stuff has been refined and code is intended for final review.

selector: 'sky-flyout-demo-internal',
template: `
<div class="sky-padding-even-large">
<h2>This is an example of a simple flyout</h2>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hmm, should this be real content instead of "This is an example..." ?

Copy link
Contributor

Choose a reason for hiding this comment

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

Normally I would say no, but it seems like it would be valuable to have decriptions on some of these for what is special about the flyout. For example: the primary action one could say that the primary action is a button in the flyout header and if clicked it will execute something and then close the flyout.
I don't think it's necessary, but could be nice

Copy link
Contributor

@blackbaud-conorwright blackbaud-conorwright left a comment

Choose a reason for hiding this comment

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

Bunch of style stuff

selector: 'sky-flyout-demo-internal',
template: `
<div class="sky-padding-even-large">
<h2>This is an example of a simple flyout</h2>
Copy link
Contributor

Choose a reason for hiding this comment

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

Normally I would say no, but it seems like it would be valuable to have decriptions on some of these for what is special about the flyout. For example: the primary action one could say that the primary action is a button in the flyout header and if clicked it will execute something and then close the flyout.
I don't think it's necessary, but could be nice

src/demos/flyout/flyout-demo-internal-simple.component.ts Outdated Show resolved Hide resolved
src/demos/flyout/flyout-demo-internal.component.html Outdated Show resolved Hide resolved
src/demos/flyout/flyout-demo-internal.component.html Outdated Show resolved Hide resolved
src/demos/flyout/flyout-demo.component.ts Outdated Show resolved Hide resolved
src/demos/flyout/flyout-demo.component.ts Outdated Show resolved Hide resolved
src/demos/flyout/flyout-demo.component.ts Outdated Show resolved Hide resolved
src/demos/flyout/flyout-demo.component.ts Outdated Show resolved Hide resolved
src/demos/flyout/flyout-demo.component.ts Outdated Show resolved Hide resolved
@blackbaud-conorwright
Copy link
Contributor

blackbaud-conorwright commented Jan 9, 2019

For the buttons with simple flyouts, could they be justified in some way? It's kind of weird to look through at the moment. The button labels could stand to be shorter too, but I'm not sure of good alternatives on that so maybe not. 😜

Otherwise, this demo looks fine to me for demonstrating flyouts and the nav-button functionality

@Blackbaud-AlexKingman
Copy link
Contributor Author

@blackbaud-conorwright ready for you again. I think I saw to every comment above, plus I organized the buttons to be a bit more tidy in the interest of legibility.

Copy link
Contributor

@blackbaud-conorwright blackbaud-conorwright left a comment

Choose a reason for hiding this comment

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

Beautiful! Those buttons look great and I much prefer the delete button being there and disabled or not.
Great job 👍

Copy link
Contributor

@Blackbaud-ToddRoberts Blackbaud-ToddRoberts left a comment

Choose a reason for hiding this comment

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

I think we should remove the "primary action" example, since the intended usage of that button in the header is to drill to the underlying content e.g. record or list page, which is covered by the permalink examples. General actions should be in a toolbar in the flyout view.

@Blackbaud-AlexKingman
Copy link
Contributor Author

@Blackbaud-ToddRoberts @blackbaud-johnly Docs and UX changes have been made. Ready for final review.

Copy link
Contributor

@blackbaud-johnly blackbaud-johnly left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks for making all those tweaks.

@Blackbaud-AlexKingman Blackbaud-AlexKingman merged commit 79a78c4 into master Jan 10, 2019
@Blackbaud-AlexKingman Blackbaud-AlexKingman deleted the flyout-iterator-demo branch January 10, 2019 19:19
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants