initImage(modalId, modalImage) {

        const self = this;
        this.modalId = modalId;
        this.modalImg = modalImage;

        for (let img of document.querySelectorAll("[data-large-img]")) {
            this.imageDataSet.push({
                image: img.getAttribute('data-large-img'),
                imageStep: img.getAttribute('data-stepping'),
                imageCaption: img.getAttribute('data-caption')
            });

            if (img.getAttribute('data-large-img') === this.modalImg) {
                this.imageData.image = img.getAttribute('data-large-img');
                this.imageData.imageStep = img.getAttribute('data-stepping');
                this.imageData.imageCaption = img.getAttribute('data-caption');
            }
        }

        this.container = document.getElementById(this.modalId);
        this.container.querySelector('.c-image').innerHTML = '';
        self.createImg(this.container, this.imageData);

    }
/**
     * Init Modal Image in Gallery
     * @param modalId
     * @param modalImage
     */
Init Modal Image in Gallery
@param modalId
@param modalImage
Init Modal Image in Gallery @param modalId @param modalImage
initImage(modalId, modalImage) {
        const self = this;
        this.modalId = modalId;
        this.modalImg = modalImage;
        for (let img of document.querySelectorAll("[data-large-img]")) {
            this.imageDataSet.push({
                image: img.getAttribute('data-large-img'),
                imageStep: img.getAttribute('data-stepping'),
                imageCaption: img.getAttribute('data-caption')
            });
            if (img.getAttribute('data-large-img') === this.modalImg) {
                this.imageData.image = img.getAttribute('data-large-img');
                this.imageData.imageStep = img.getAttribute('data-stepping');
                this.imageData.imageCaption = img.getAttribute('data-caption');
            }
        }
        this.container = document.getElementById(this.modalId);
        this.container.querySelector('.c-image').innerHTML = '';
        self.createImg(this.container, this.imageData);
    }
initImage ( modalId , modalImage ) { const self = this ; this . modalId = modalId ; this . modalImg = modalImage ; for ( let img of document . querySelectorAll ( "[data-large-img]" ) ) { this . imageDataSet . push ( { image : img . getAttribute ( 'data-large-img' ) , imageStep : img . getAttribute ( 'data-stepping' ) , imageCaption : img . getAttribute ( 'data-caption' ) } ) ; if ( img . getAttribute ( 'data-large-img' ) === this . modalImg ) { this . imageData . image = img . getAttribute ( 'data-large-img' ) ; this . imageData . imageStep = img . getAttribute ( 'data-stepping' ) ; this . imageData . imageCaption = img . getAttribute ( 'data-caption' ) ; } } this . container = document . getElementById ( this . modalId ) ; this . container . querySelector ( '.c-image' ) . innerHTML = '' ; self . createImg ( this . container , this . imageData ) ; }
Init Modal Image in Gallery
 @param modalId
 @param modalImage
Init Modal Image in Gallery @param modalId @param modalImage