-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Implementation of walkthrough infrastructure #13182
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
base: main
Are you sure you want to change the base?
Conversation
jabgui/src/main/java/org/jabref/gui/util/component/PulseAnimateIndicator.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughManager.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughManager.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/InfoBlockContentBlock.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/StepType.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/WalkthroughContentBlock.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/WalkthroughStep.java
Outdated
Show resolved
Hide resolved
So far I like the idea.
|
This refs #12664 somehow :) |
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughManager.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughUIFactory.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/NodeResolverFactory.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughOverlay.java
Outdated
Show resolved
Hide resolved
jablib/src/main/java/org/jabref/logic/preferences/JabRefCliPreferences.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughOverlay.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/Walkthrough.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughOverlay.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughOverlay.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/NodeResolverFactory.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/TextContentBlock.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/Walkthrough.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/Walkthrough.java
Outdated
Show resolved
Hide resolved
@Yubo-Cao can you fix the failing tests - should be simple, both are related to localization. |
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughAction.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/step/PanelStep.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/declarative/step/PanelStep.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughAction.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
First half of first iteration through review. More to come on the weekend.
jabgui/src/main/java/org/jabref/gui/walkthrough/SingleWindowWalkthroughOverlay.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/SingleWindowWalkthroughOverlay.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/Walkthrough.java
Outdated
Show resolved
Hide resolved
jabgui/src/main/java/org/jabref/gui/walkthrough/WalkthroughAction.java
Outdated
Show resolved
Hide resolved
overlay.displayStep(step); | ||
} | ||
|
||
public WalkthroughStep getStepAtIndex(int index) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What If I call it with -1?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Array index out of bounds.
Co-authored-by: Subhramit Basu <subhramit.bb@live.in>
@trag-bot didn't find any issues in the code! ✅✨ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some small nits when reading otherwise lgtm
CompletableFuture<Void> timeoutFuture = CompletableFuture.runAsync(() -> { | ||
try { | ||
Thread.sleep(HANDLER_TIMEOUT_MS); | ||
} catch (InterruptedException e) { | ||
Thread.currentThread().interrupt(); | ||
} | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this entire class could make use of some more javadoc - I sense high cognitive load on if someone wants to work on this in future. Things like, why we are using a completable future, etc.
But these refinements can be done in future, we can get this in and start focusing on the next steps.
.filter(menuItem -> Optional.ofNullable(menuItem.getGraphic()) | ||
.map(graphic -> graphic.equals(node) | ||
|| Stream.iterate(graphic, Objects::nonNull, Node::getParent) | ||
.anyMatch(cm -> cm.equals(node))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I am not wrong on the expansion:
.filter(menuItem -> Optional.ofNullable(menuItem.getGraphic()) | |
.map(graphic -> graphic.equals(node) | |
|| Stream.iterate(graphic, Objects::nonNull, Node::getParent) | |
.anyMatch(cm -> cm.equals(node))) | |
.filter(menuItem -> Optional.ofNullable(menuItem.getGraphic()) | |
.map(graphic -> graphic.equals(node) | |
|| Stream.iterate(graphic, Objects::nonNull, Node::getParent) | |
.anyMatch(contextMenu -> contextMenu.equals(node))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch
Closes N/A
Initial implementation of the walkthrough feature. See this Google Drive video for demonstration: https://drive.google.com/file/d/19sUz1XoSjP0UkuhUvKQE-MZjmVASy2ot/view?usp=sharing
The completion of the walkthrough is also tracked through modifying the preferences class.
This refs #12664
Mandatory checks
CHANGELOG.md
described in a way that is understandable for the average user (if change is visible to the user)