-
Notifications
You must be signed in to change notification settings - Fork 594
Add Evaluate Button to Share Page #10614
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
Conversation
…ks/eval_from_share
…utomatically when project is set
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 a couple of questions
const decoded = decodeURIComponent(projectParam); | ||
const shareId = pxt.Cloud.parseScriptId(decoded); | ||
if (!!shareId) { | ||
pxt.tickEvent(Ticks.LoadProjectFromUrl); |
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 would you prefer to remove the project
param from the URL after processing it, this can be accomplished without a page reload using window.history.replaceState
.
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.
LGTM!
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.
Looks good!
I asked LLM itself on what are the good questions for middle school students project. ✅ Basic Code Quality
🐞 Bug Checking
💡 Suggestions & Improvements
|
Can we put the button after the "Edit Code" button? This is only for Teachers, seems like the hierarchy should be switched... |
Those seem to align fairly well with the questions included, which are:
|
This code is already checked in, but feel free to file an issue. I will note that from my perspective, I feel like the farthest-right button (where Edit Code is currently) is actually the more strongly weighted / most-likely-to-be-clicked one. I feel like my attention is pulled more towards buttons on the end than buttons in the middle. Is it worth checking with a few other folks to see? |
Yeah, I'm not sure. Just feels like evaluating the code is as important as opening the project in the editor (which it isn't). We can keep and see what happens? I think we'll just get a lot of confused people clicking on that button. The other thing maybe we could do is only show it if you're signed in already to try and scope this feature to Teachers? |
Unfortunately, the share page does not currently support sign-in, so that would be a significant amount of work. We could consider changing the appearance of the buttons so one is more "Primary" than the other? |
We could use different color for edit button as well, if that helps to prioritize. Sign-in for share page is lot of work and we shouldn't pick for this release. |
This adds an "Evaluate" button to the share page, which will only appear if the
teachertool/showSharePageEvalButton
is set to true in targetconfig.It also includes some fixes to the load-project-from-url behavior that already existed in the teacher tool. Specifically, it:
The default checklist will only load if the teacher does not already have a checklist loaded. This way, if they're grading the same project for a bunch of students and have a customized rubric, they can still click the evaluate button here and it will load the same rubric they've been working with. It also prevents any accidental loss of work, which could happen if we overwrote the active rubric.
Fixes microsoft/pxt-microbit#5904