File tree Expand file tree Collapse file tree 4 files changed +23
-4
lines changed
Expand file tree Collapse file tree 4 files changed +23
-4
lines changed Original file line number Diff line number Diff line change 287287 Results will appear here...
288288 </ div >
289289
290- < button id ="copyButton " class ="btn btn-light ">
290+ < button
291+ id ="copyButton "
292+ class ="btn btn-light "
293+ onclick ="showCopiedMessage() "
294+ >
291295 < i class ="fas fa-copy "> </ i >
296+ < span
297+ id ="copiedMsg "
298+ style ="display: none; color: green; margin-left: 10px "
299+ > Copied!</ span
300+ >
292301 </ button >
293302 </ div >
294303 </ div >
756765 const crossTabCopyPaste = new CrossTabCopyPaste ( ) ;
757766 crossTabCopyPaste . init ( crossTabCopyPasteOptions , ( ) => { } ) ;
758767
768+ // show "Copied!" message when result is copied
769+ function showCopiedMessage ( ) {
770+ const msg = document . getElementById ( 'copiedMsg' ) ;
771+ msg . style . display = 'inline' ;
772+
773+ setTimeout ( ( ) => {
774+ msg . style . display = 'none' ;
775+ } , 1500 ) ;
776+ }
777+
759778 // Optional: Remove the duplication command from Blockly's context menu
760779 Blockly . ContextMenuRegistry . registry . unregister ( 'blockDuplicate' ) ;
761780
Original file line number Diff line number Diff line change @@ -426,7 +426,7 @@ function saveWorkspaceLocally() {
426426 * Copies the generated command text to the clipboard.
427427 */
428428function copyToClipboard ( ) {
429- const text = document . getElementById ( 'resultsArea ' ) . innerText ;
429+ const text = document . getElementById ( 'resultsText ' ) . innerText ;
430430 navigator . clipboard . writeText ( text ) . catch ( ( err ) => {
431431 console . error ( 'Unable to copy:' , err ) ;
432432 alert ( 'Failed to copy text.' ) ;
Original file line number Diff line number Diff line change @@ -199,7 +199,7 @@ app.post(
199199 ] ,
200200 function ( err ) {
201201 if ( err ) {
202- req . flash ( 'error' , 'Registration failed .' ) ;
202+ req . flash ( 'error' , 'Username and/or Email already in use .' ) ;
203203 return res . redirect ( '/register' ) ;
204204 }
205205 req . logIn ( newUser , ( err ) => {
Original file line number Diff line number Diff line change 352352 <h4 >Links</h4 >
353353 <ul >
354354 <li ><i class =" bx bx-chevron-right" ></i > <a href =" #" >Home</a ></li >
355- <li ><i class =" bx bx-chevron-right" ></i > <a href =" /index.html " >Ublocks</a ></li >
355+ <li ><i class =" bx bx-chevron-right" ></i > <a href =" /blockly_unix " >Ublocks</a ></li >
356356 <li ><i class =" bx bx-chevron-right" ></i > <a href =" /tutorials" >Tutorials</a ></li >
357357 </ul >
358358 </div >
You can’t perform that action at this time.
0 commit comments