ImagePreviewPresenter.ts 493 Bytes
import { Presenter } from "../../../../common/classbase/PresenterBase";
import { ImagePreviewView, ImagePreviewViewType } from "../../view/type/ImagePreviewView";
import { RegPresenter } from "../../PresenterCCViewFactory";

@RegPresenter(ImagePreviewViewType)
export class ImagePreviewPresenter extends Presenter<string, ImagePreviewView> {
    static uuid = "ImagePreviewPresenter";
    
    onOpen(image: string) {
        super.onOpen(image);
        this.view.setProps({ image });
    }
}