forked from MapComplete/MapComplete
		
	
		
			
				
	
	
		
			19 lines
		
	
	
		
			No EOL
		
	
	
		
			531 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
			
		
		
	
	
			19 lines
		
	
	
		
			No EOL
		
	
	
		
			531 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
import {UIElement} from "../UIElement";
 | 
						|
import {UIEventSource} from "../../Logic/UIEventSource";
 | 
						|
 | 
						|
export class VariableUiElement extends UIElement {
 | 
						|
    private _html: UIEventSource<string>;
 | 
						|
    private _innerUpdate: (htmlElement: HTMLElement) => void;
 | 
						|
 | 
						|
    constructor(html: UIEventSource<string>, innerUpdate : ((htmlElement : HTMLElement) => void) = undefined) {
 | 
						|
        super(html);
 | 
						|
        this._html = html;
 | 
						|
        this._innerUpdate = innerUpdate;
 | 
						|
 | 
						|
    }
 | 
						|
 | 
						|
    InnerRender(): string {
 | 
						|
        return this._html.data;
 | 
						|
    }
 | 
						|
 | 
						|
} |