mirror of
				https://github.com/TriliumNext/Notes.git
				synced 2025-10-31 21:11:30 +08:00 
			
		
		
		
	fix edit button
This commit is contained in:
		
							parent
							
								
									115bf0af4d
								
							
						
					
					
						commit
						291ef87c9b
					
				| @ -1,8 +1,8 @@ | |||||||
| import NoteContextAwareWidget from "../note_context_aware_widget.js"; | import NoteContextAwareWidget from "../note_context_aware_widget.js"; | ||||||
| 
 | 
 | ||||||
| const TPL = `<span class="button-widget bx"
 | const TPL = `<button class="button-widget bx"
 | ||||||
|       data-toggle="tooltip" |       data-toggle="tooltip" | ||||||
|       title=""></span>`; |       title=""></button>`; | ||||||
| 
 | 
 | ||||||
| export default class AbstractButtonWidget extends NoteContextAwareWidget { | export default class AbstractButtonWidget extends NoteContextAwareWidget { | ||||||
|     isEnabled() { |     isEnabled() { | ||||||
|  | |||||||
| @ -39,12 +39,10 @@ export default class EditButton extends OnClickButtonWidget { | |||||||
|             // make the edit button stand out on the first display, otherwise
 |             // make the edit button stand out on the first display, otherwise
 | ||||||
|             // it's difficult to notice that the note is readonly
 |             // it's difficult to notice that the note is readonly
 | ||||||
|             if (this.isVisible() && !wasVisible) { |             if (this.isVisible() && !wasVisible) { | ||||||
|                 this.$iconSpan.addClass("bx-tada"); |                 this.$widget.addClass("bx-tada bx-lg"); | ||||||
|                 this.$widget.css("transform", "scale(2)"); |  | ||||||
| 
 | 
 | ||||||
|                 setTimeout(() => { |                 setTimeout(() => { | ||||||
|                     this.$iconSpan.removeClass("bx-tada bx-lg"); |                     this.$widget.removeClass("bx-tada bx-lg"); | ||||||
|                     this.$widget.css("transform", "scale(1)"); |  | ||||||
|                 }, 1700); |                 }, 1700); | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 zadam
						zadam