dist/crocodoc.viewer.js
function ($pageEl, config) {
            var $text, $svg, $links;
            $el = $pageEl;
            $svg = $pageEl.find('.' + CSS_CLASS_PAGE_SVG);
            $text = $pageEl.find('.' + CSS_CLASS_PAGE_TEXT);
            $links = $pageEl.find('.' + CSS_CLASS_PAGE_LINKS);

            status = config.status || PAGE_STATUS_NOT_LOADED;
            index = config.index;
            pageNum = index + 1;
            this.config = config;

            config.url = config.url || '';
            pageText = scope.createComponent('page-text');
            if (config.useSVG === undefined) {
                config.useSVG = true;
            }
            pageContent = support.svg && config.useSVG ?
                    scope.createComponent('page-svg') :
                    scope.createComponent('page-img');

            pageText.init($text, pageNum);
            pageContent.init($svg, pageNum);

            if (config.enableLinks && config.links.length) {
                pageLinks = scope.createComponent('page-links');
                pageLinks.init($links, config.links);
            }
        }
function ($pageEl, config) {
            var $text, $svg, $links;
            $el = $pageEl;
            $svg = $pageEl.find('.' + CSS_CLASS_PAGE_SVG);
            $text = $pageEl.find('.' + CSS_CLASS_PAGE_TEXT);
            $links = $pageEl.find('.' + CSS_CLASS_PAGE_LINKS);

            status = config.status || PAGE_STATUS_NOT_LOADED;
            index = config.index;
            pageNum = index + 1;
            this.config = config;

            config.url = config.url || '';
            pageText = scope.createComponent('page-text');
            if (config.useSVG === undefined) {
                config.useSVG = true;
            }
            pageContent = support.svg && config.useSVG ?
                    scope.createComponent('page-svg') :
                    scope.createComponent('page-img');

            pageText.init($text, pageNum);
            pageContent.init($svg, pageNum);

            if (config.enableLinks && config.links.length) {
                pageLinks = scope.createComponent('page-links');
                pageLinks.init($links, config.links);
            }
        }
function ( $pageEl , config ) { var $text , $svg , $links ; $el = $pageEl ; $svg = $pageEl . find ( '.' + CSS_CLASS_PAGE_SVG ) ; $text = $pageEl . find ( '.' + CSS_CLASS_PAGE_TEXT ) ; $links = $pageEl . find ( '.' + CSS_CLASS_PAGE_LINKS ) ; status = config . status || PAGE_STATUS_NOT_LOADED ; index = config . index ; pageNum = index + 1 ; this . config = config ; config . url = config . url || '' ; pageText = scope . createComponent ( 'page-text' ) ; if ( config . useSVG === undefined ) { config . useSVG = true ; } pageContent = support . svg && config . useSVG ? scope . createComponent ( 'page-svg' ) : scope . createComponent ( 'page-img' ) ; pageText . init ( $text , pageNum ) ; pageContent . init ( $svg , pageNum ) ; if ( config . enableLinks && config . links . length ) { pageLinks = scope . createComponent ( 'page-links' ) ; pageLinks . init ( $links , config . links ) ; } }
Initialize the Page component
@returns {void}
Initialize the Page component