Version 4.2.0
This commit is contained in:
1 parent
0dc2aee5ed
commit
96997ddd8e
2074 files changed
+125454
-55780
No files matched your search
@@ -1,8 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<javascript app="gallery">
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/browse" javascript_name="ips.browse.list.js" javascript_type="controller" javascript_version="101099" javascript_position="1000050">/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/browse" javascript_name="ips.browse.list.js" javascript_type="controller" javascript_version="102002" javascript_position="1000050">/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.browse.list.js - Gallery browse list controller
|
||||
*
|
||||
@@ -48,9 +48,9 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));</file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.chooseCategory.js" javascript_type="controller" javascript_version="101099" javascript_position="1000100"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.chooseCategory.js" javascript_type="controller" javascript_version="102002" javascript_position="1000100"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.submit.chooseCategory.js - AJAX to show album options after selecting category
|
||||
*
|
||||
@@ -156,9 +156,9 @@
|
||||
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.existingAlbums.js" javascript_type="controller" javascript_version="101099" javascript_position="1000100"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.existingAlbums.js" javascript_type="controller" javascript_version="102002" javascript_position="1000100"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.submit.existingAlbums.js - Allows user to select an existing gallery album
|
||||
*
|
||||
@@ -203,9 +203,9 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.imageInfo.js" javascript_type="controller" javascript_version="101099" javascript_position="1000100"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.imageInfo.js" javascript_type="controller" javascript_version="102002" javascript_position="1000100"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.submit.imageInfo.js - Image information controller for an individual image
|
||||
*
|
||||
@@ -290,6 +290,9 @@
|
||||
.focus();
|
||||
|
||||
$( e.currentTarget ).closest('li').remove();
|
||||
|
||||
e.preventDefault();
|
||||
return false;
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -340,9 +343,9 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.main.js" javascript_type="controller" javascript_version="101099" javascript_position="1000100"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.main.js" javascript_type="controller" javascript_version="102002" javascript_position="1000100"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.submit.main.js - Main submit controller
|
||||
*
|
||||
@@ -364,6 +367,7 @@
|
||||
this.on( 'formError.gallerySubmit', this.formError );
|
||||
this.on( 'submit', '[data-role="allImagesForm"]', this.finishEditing );
|
||||
this.on( 'click', '[data-role="imageThumb"]', this.switchToImage );
|
||||
this.on( 'click', '[data-action="finishAndCopy"]', this.markAllDoneAndSubmit );
|
||||
this.setup();
|
||||
},
|
||||
|
||||
@@ -423,7 +427,6 @@
|
||||
|
||||
// 02/02/16 - If currentIndex is undefined, it means there's no 'current' image; i.e., we've finished.
|
||||
// So we'll skip the events on subcontrollers (which won't exist now anyway) and run our finish method
|
||||
// See https://community.invisionpower.com/4bugtrack/pre-release-reports/gallery-cant-finish-editing-r10213/
|
||||
if( _.isUndefined( currentIndex ) ){
|
||||
this._doFinish();
|
||||
return;
|
||||
@@ -535,7 +538,7 @@
|
||||
},
|
||||
|
||||
/**
|
||||
* Finishes editing and submits the wizard to continu to the next step after
|
||||
* Finishes editing and submits the wizard to continue to the next step after
|
||||
* verifying there's no unsaved images
|
||||
*
|
||||
* @returns {void}
|
||||
@@ -566,6 +569,27 @@
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Marks all images done and submits
|
||||
*
|
||||
* @returns {void}
|
||||
*/
|
||||
markAllDoneAndSubmit: function() {
|
||||
var currentIndex = this._slider.find('.cGallerySubmit_current').attr('data-index');
|
||||
|
||||
this._slider.find('li:not( .cGallerySubmit_done )').addClass( 'cGallerySubmit_done' );
|
||||
|
||||
var form = this.scope.find('[data-role="allImagesForm"]');
|
||||
form.prepend( "<input type='hidden' name='copyImageDetails', value='1' />" );
|
||||
|
||||
this._switchToAfterLoad = { finish: true };
|
||||
|
||||
// Does the currently-selected image need to be saved first?
|
||||
this.triggerOn( 'gallery.front.submit.imageInfo', 'submitWithoutRedirect.gallerySubmit', {
|
||||
index: currentIndex
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* Marks an image in the slider as done (i.e. info is saved)
|
||||
*
|
||||
@@ -619,9 +643,9 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.uploadImages.js" javascript_type="controller" javascript_version="101099" javascript_position="1000100"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.uploadImages.js" javascript_type="controller" javascript_version="102002" javascript_position="1000100"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.submit.uploadImages.js - Image upload step
|
||||
*
|
||||
@@ -635,6 +659,11 @@
|
||||
_shrunk: false,
|
||||
|
||||
initialize: function () {
|
||||
var self = this;
|
||||
this.scope.find('[data-role="addFiles"]').on( 'click', function(e){
|
||||
self.scope.find('input[type="file"]').click();
|
||||
} );
|
||||
|
||||
this.on( 'fileAdded', '[data-ipsUploader]', this.filesAdded );
|
||||
this.on( 'uploadComplete', '[data-ipsUploader]', this.uploadComplete );
|
||||
$( window ).on( 'resize', _.bind( this.resizeUploader, this ) );
|
||||
@@ -704,6 +733,8 @@
|
||||
this._shrinkUploader( true );
|
||||
this.scope.find('[data-role="submitForm"]').prop( 'disabled', true );
|
||||
|
||||
this.scope.find('[data-role="addFiles"]').removeClass( 'ipsHide' );
|
||||
|
||||
$( window ).trigger('resize');
|
||||
},
|
||||
|
||||
@@ -738,9 +769,9 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.wizard.js" javascript_type="controller" javascript_version="101099" javascript_position="1000100"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/submit" javascript_name="ips.submit.wizard.js" javascript_type="controller" javascript_version="102002" javascript_position="1000100"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.submit.main.js - Main gallery submit dialog controller
|
||||
*
|
||||
@@ -838,9 +869,9 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.image.js" javascript_type="controller" javascript_version="101099" javascript_position="1000150"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.image.js" javascript_type="controller" javascript_version="102002" javascript_position="1000150"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.view.image.js - Image controller
|
||||
*
|
||||
@@ -879,8 +910,51 @@
|
||||
*/
|
||||
setup: function () {
|
||||
this._setUpSizing();
|
||||
|
||||
this._setUpLightboxEvents();
|
||||
},
|
||||
|
||||
/**
|
||||
* Handles URL state changes
|
||||
*
|
||||
* @returns {void}
|
||||
*/
|
||||
_setUpLightboxEvents: function() {
|
||||
var self = this;
|
||||
|
||||
// When a lightbox image is shown, see if there are any next/previous and emit the appropriate events
|
||||
$( document ).on( 'lightboxImageShown', function(){
|
||||
// See if we have a previous image
|
||||
if( self.scope.find('[data-action="prevImage"]').length )
|
||||
{
|
||||
$( document ).trigger('lightboxEnable_prev');
|
||||
}
|
||||
else
|
||||
{
|
||||
$( document ).trigger('lightboxDisable_prev');
|
||||
}
|
||||
|
||||
// See if we have a next image
|
||||
if( self.scope.find('[data-action="nextImage"]').length )
|
||||
{
|
||||
$( document ).trigger('lightboxEnable_next');
|
||||
}
|
||||
else
|
||||
{
|
||||
$( document ).trigger('lightboxDisable_next');
|
||||
}
|
||||
});
|
||||
|
||||
// When you click next image in the lightbox, trigger our normal next image routine which will later emit an event to update the lightbox
|
||||
$( document ).on( 'lightboxNextImage', function(){
|
||||
self.scope.find('[data-action="nextImage"]').click();
|
||||
});
|
||||
|
||||
$( document ).on( 'lightboxPrevImage', function(){
|
||||
self.scope.find('[data-action="prevImage"]').click();
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* Handles URL state changes
|
||||
*
|
||||
@@ -911,7 +985,7 @@
|
||||
return;
|
||||
}
|
||||
|
||||
var self = this;
|
||||
var self = this;
|
||||
|
||||
// Get top postition of table
|
||||
var elemPosition = ips.utils.position.getElemPosition( this.scope );
|
||||
@@ -940,7 +1014,7 @@
|
||||
keyDown: function (e) {
|
||||
|
||||
// Ignore the keypress if we're in a form element
|
||||
if( $( e.target ).closest('input, textarea, .ipsComposeArea').length ){
|
||||
if( $( e.target ).closest('input, textarea, .ipsComposeArea, .ipsComposeArea_editor').length ){
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1060,7 +1134,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Get the position of the middle image
|
||||
var newLeftPos = item.position().left;
|
||||
var leftPos = parseInt( collection.css('left') ) * -1;
|
||||
@@ -1076,8 +1149,6 @@
|
||||
|
||||
collectionItems.removeClass('cGalleryAlbumSlider_active');
|
||||
item.addClass('cGalleryAlbumSlider_active');
|
||||
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -1415,11 +1486,9 @@
|
||||
$('video[data-role="video"]').attr('id', newId);
|
||||
|
||||
if( _.isUndefined( window.videojs ) ){
|
||||
ips.loader.get( ['gallery/interface/videojs/video.js'] ).then( function() {
|
||||
ips.loader.get( ['gallery/interface/videojs/videojs-loadswf.js'] ).then( function() {
|
||||
var thisOptions = $('video[data-role="video"]').attr('data-setup') ? $.parseJSON( $('video[data-role="video"]').attr('data-setup') ) : {};
|
||||
videojs( newId, thisOptions, function(){});
|
||||
});
|
||||
ips.loader.get( ['gallery/interface/videojs/video.min.js'] ).then( function() {
|
||||
var thisOptions = $('video[data-role="video"]').attr('data-setup') ? $.parseJSON( $('video[data-role="video"]').attr('data-setup') ) : {};
|
||||
videojs( newId, thisOptions, function(){});
|
||||
});
|
||||
} else {
|
||||
videojs.players = {};
|
||||
@@ -1434,7 +1503,7 @@
|
||||
}
|
||||
|
||||
// Update breadcrumb
|
||||
$('nav.ipsBreadcrumb [itemtype="http://schema.org/BreadcrumbList"] > li:last-child').html( response.title );
|
||||
$('nav.ipsBreadcrumb [data-role="breadcrumbList"] > li:last-child').html( response.title );
|
||||
|
||||
// Reinit each area
|
||||
$( document )
|
||||
@@ -1442,6 +1511,38 @@
|
||||
.trigger( 'contentChange', [ this.scope.find('[data-role="imageFrame"]') ] )
|
||||
.trigger( 'contentChange', [ this.scope.find('[data-role="imageComments"]') ] );
|
||||
|
||||
// Trigger event for lightbox handler
|
||||
$( document )
|
||||
.trigger( 'imageUpdated', [ {
|
||||
closeLightbox: ( response.image.match( /<video /ig ) || response.image.match( /<embed /ig ) ) ? true : false,
|
||||
updateImage: {
|
||||
imageElem: null,
|
||||
largeImage: ( response.image.match( /<video /ig ) || response.image.match( /<embed /ig ) ) ? null : this.scope.find('[data-role="theImage"]')[0].src,
|
||||
commentsURL: null,
|
||||
meta: null
|
||||
}
|
||||
} ] );
|
||||
|
||||
// See if we have a previous image
|
||||
if( this.scope.find('[data-action="prevImage"]').length )
|
||||
{
|
||||
$( document ).trigger('lightboxEnable_prev');
|
||||
}
|
||||
else
|
||||
{
|
||||
$( document ).trigger('lightboxDisable_prev');
|
||||
}
|
||||
|
||||
// See if we have a next image
|
||||
if( this.scope.find('[data-action="nextImage"]').length )
|
||||
{
|
||||
$( document ).trigger('lightboxEnable_next');
|
||||
}
|
||||
else
|
||||
{
|
||||
$( document ).trigger('lightboxDisable_next');
|
||||
}
|
||||
|
||||
this._setUpSizing();
|
||||
},
|
||||
|
||||
@@ -1469,6 +1570,9 @@
|
||||
})
|
||||
.html('')
|
||||
.addClass('ipsLoading');
|
||||
|
||||
// Trigger event for lightbox handler
|
||||
$( document ).trigger( 'imageLoading', [] );
|
||||
} else {
|
||||
|
||||
}
|
||||
@@ -1536,9 +1640,9 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.note.js" javascript_type="controller" javascript_version="101099" javascript_position="1000150"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.note.js" javascript_type="controller" javascript_version="102002" javascript_position="1000150"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.view.note.js - Note controller
|
||||
*
|
||||
@@ -1934,9 +2038,9 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.notes.js" javascript_type="controller" javascript_version="101099" javascript_position="1000150"><![CDATA[/**
|
||||
* IPS Community Suite 4
|
||||
* (c) 2013 Invision Power Services - http://www.invisionpower.com
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="controllers/view" javascript_name="ips.view.notes.js" javascript_type="controller" javascript_version="102002" javascript_position="1000150"><![CDATA[/**
|
||||
* Invision Community
|
||||
* (c) Invision Power Services, Inc. - https://www.invisioncommunity.com
|
||||
*
|
||||
* ips.view.notes.js - Gallery notes controller
|
||||
*
|
||||
@@ -2017,7 +2121,7 @@
|
||||
}
|
||||
});
|
||||
}(jQuery, _));]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="templates" javascript_name="ips.templates.browse.js" javascript_type="template" javascript_version="101099" javascript_position="1000200"><![CDATA[ips.templates.set('gallery.patchwork.indexItem', " \
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="templates" javascript_name="ips.templates.browse.js" javascript_type="template" javascript_version="102002" javascript_position="1000200"><![CDATA[ips.templates.set('gallery.patchwork.indexItem', " \
|
||||
{{#showThumb}}\
|
||||
<span class='cGalleryPatchwork_item' style='width: {{dims.width}}px; height: {{dims.height}}px; margin: {{dims.margin}}px {{dims.marginRight}}px {{dims.margin}}px {{dims.marginLeft}}px'>\
|
||||
{{/showThumb}}\
|
||||
@@ -2039,7 +2143,7 @@
|
||||
</a>\
|
||||
</span>\
|
||||
");]]></file>
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="templates" javascript_name="ips.templates.view.js" javascript_type="template" javascript_version="101099" javascript_position="1000200"><![CDATA[ips.templates.set('gallery.notes.wrapper', " \
|
||||
<file javascript_app="gallery" javascript_location="front" javascript_path="templates" javascript_name="ips.templates.view.js" javascript_type="template" javascript_version="102002" javascript_position="1000200"><![CDATA[ips.templates.set('gallery.notes.wrapper', " \
|
||||
<div class='cGalleryNote' data-controller='gallery.front.view.note' data-noteID='{{id}}' data-note=\"{{note}}\" {{#editable}}data-editable{{/editable}} data-posLeft='{{left}}' data-posTop='{{top}}' data-dimWidth='{{width}}' data-dimHeight='{{height}}'>\
|
||||
<div class='cGalleryNote_border'></div>\
|
||||
<div class='cGalleryNote_note' style='display: none'>\
|
||||
@@ -2074,4 +2178,6 @@ app.js</order>
|
||||
<order app="global" path="/dev/js//library//jquery">jquery.js
|
||||
jquery.history.js
|
||||
jquery.transform.js</order>
|
||||
<order app="global" path="/dev/js//library//linkify">linkify.min.js
|
||||
linkify-jquery.min.js</order>
|
||||
</javascript>
|
||||
Reference in new issue
Block a user