mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-04 05:53:43 +00:00 
			
		
		
		
	js: Convert static/js/lightbox_canvas.js to ES6 module.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
		
				
					committed by
					
						
						Tim Abbott
					
				
			
			
				
	
			
			
			
						parent
						
							8bbb0d9193
						
					
				
				
					commit
					1d64e7a8eb
				
			@@ -131,7 +131,6 @@
 | 
				
			|||||||
                "$": false,
 | 
					                "$": false,
 | 
				
			||||||
                "FetchStatus": false,
 | 
					                "FetchStatus": false,
 | 
				
			||||||
                "Filter": false,
 | 
					                "Filter": false,
 | 
				
			||||||
                "LightboxCanvas": false,
 | 
					 | 
				
			||||||
                "ListCursor": false,
 | 
					                "ListCursor": false,
 | 
				
			||||||
                "MessageListData": false,
 | 
					                "MessageListData": false,
 | 
				
			||||||
                "MessageListView": false,
 | 
					                "MessageListView": false,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -17,7 +17,6 @@ import "../i18n";
 | 
				
			|||||||
import "../loading";
 | 
					import "../loading";
 | 
				
			||||||
import "../vdom";
 | 
					import "../vdom";
 | 
				
			||||||
import "../keydown_util";
 | 
					import "../keydown_util";
 | 
				
			||||||
import "../lightbox_canvas";
 | 
					 | 
				
			||||||
import "../rtl";
 | 
					import "../rtl";
 | 
				
			||||||
import "../rendered_markdown";
 | 
					import "../rendered_markdown";
 | 
				
			||||||
import "../fold_dict";
 | 
					import "../fold_dict";
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										1
									
								
								static/js/global.d.ts
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								static/js/global.d.ts
									
									
									
									
										vendored
									
									
								
							@@ -5,7 +5,6 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
declare let FetchStatus: any;
 | 
					declare let FetchStatus: any;
 | 
				
			||||||
declare let Filter: any;
 | 
					declare let Filter: any;
 | 
				
			||||||
declare let LightboxCanvas: any;
 | 
					 | 
				
			||||||
declare let ListCursor: any;
 | 
					declare let ListCursor: any;
 | 
				
			||||||
declare let MessageListData: any;
 | 
					declare let MessageListData: any;
 | 
				
			||||||
declare let MessageListView: any;
 | 
					declare let MessageListView: any;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,5 +1,6 @@
 | 
				
			|||||||
"use strict";
 | 
					"use strict";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					const {LightboxCanvas} = require("./lightbox_canvas");
 | 
				
			||||||
const people = require("./people");
 | 
					const people = require("./people");
 | 
				
			||||||
 | 
					
 | 
				
			||||||
let is_open = false;
 | 
					let is_open = false;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,5 +1,3 @@
 | 
				
			|||||||
"use strict";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
const funcs = {
 | 
					const funcs = {
 | 
				
			||||||
    setZoom(meta, zoom) {
 | 
					    setZoom(meta, zoom) {
 | 
				
			||||||
        // condition to handle zooming event by zoom hotkeys
 | 
					        // condition to handle zooming event by zoom hotkeys
 | 
				
			||||||
@@ -206,7 +204,7 @@ const funcs = {
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
class LightboxCanvas {
 | 
					export class LightboxCanvas {
 | 
				
			||||||
    meta = {
 | 
					    meta = {
 | 
				
			||||||
        direction: -1,
 | 
					        direction: -1,
 | 
				
			||||||
        zoom: 1,
 | 
					        zoom: 1,
 | 
				
			||||||
@@ -270,6 +268,3 @@ class LightboxCanvas {
 | 
				
			|||||||
        this.meta.resize_handler = callback;
 | 
					        this.meta.resize_handler = callback;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					 | 
				
			||||||
module.exports = LightboxCanvas;
 | 
					 | 
				
			||||||
window.LightboxCanvas = LightboxCanvas;
 | 
					 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user