#95 encapsulte pagination state of multi-run HAR. #110

Merged
merged 3 commits into from Jan 11, 2017

Projects

None yet

2 participants

@micmro
Owner
micmro commented Jan 11, 2017

No description provided.

@micmro #95 encapsulte pagination state of multi-run HAR.
e6d5dd4
@micmro micmro requested a review from tobli Jan 11, 2017
@micmro fix comment
ebf35e4
-import * as waterfallDocsService from "../state/waterfall-docs-service";
+/** Class to keep track of run of a multi-run har is beeing shown */
+export default class Paging {
@micmro
micmro Jan 11, 2017 Owner

changed to class

@@ -1,24 +0,0 @@
-import {WaterfallDocs} from "../typing/waterfall";
@micmro
micmro Jan 11, 2017 Owner

not needed anymore

@tobli
tobli approved these changes Jan 11, 2017 View changes

Nice. Great to remove waterfall-docs-service!

src/ts/paging/paging.ts
+ selectbox.style.display = "none";
+ return;
+ }
+ this.doc.pages.forEach((p, i) => {
@tobli
tobli Jan 11, 2017 Collaborator

I realised we need to empty the select box before adding new options. Either include that, or fix it in a follow-up commit.

@micmro
micmro Jan 11, 2017 Owner

Ahh - good catch - will fix now.

@micmro
micmro Jan 11, 2017 Owner

Just looked at it and it only seems to be executed once on init time.

I am now wondering if someone has an options in the select box already could there be a use-case where they should not be cleared? I suppose a please select... placeholder or so should be cleared.

Anyway for now I'll clear them, since I can't think of any real-world case where they'd need to be kept.

@tobli
tobli Jan 11, 2017 Collaborator

I managed to get pages from multiple HARs in there, by loading several multi page HARs in sequence via the file chooser in the example page. I too have thought about the possibility of additional non-page options, but don't have a good answer. Maybe just clearing any option that has a numerical value?

@micmro empty multi-run select box before population and type improvements
1865d20
@micmro micmro merged commit ee6a013 into master Jan 11, 2017

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
@micmro micmro deleted the 95-2 branch Jan 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment