- fixed conflicts with raty JS plugin;

- fixed members directory and meta section visibility;
This commit is contained in:
nikitozzzzzzz
2018-01-29 17:10:02 +02:00
parent dca45dad6b
commit fa288dbe0b
3 changed files with 34 additions and 39 deletions
+12 -12
View File
@@ -20,7 +20,7 @@
methods.destroy.call(this.self);
this.opt = $.extend(true, {}, $.fn.raty.defaults, options);
this.opt = $.extend(true, {}, $.fn.um_raty.defaults, options);
methods._adjustCallback.call(this);
@@ -125,7 +125,7 @@
_bindClick: function() {
var that = this;
that.stars.on('click.raty', function(evt) {
that.stars.on('click.um_raty', function(evt) {
var star = $(this);
that.score.val((that.opt.half || that.opt.precision) ? that.self.data('score') : (this.alt || star.data('alt')));
@@ -139,7 +139,7 @@
_bindClickCancel: function() {
var that = this;
that.cancel.on('click.raty', function(evt) {
that.cancel.on('click.um_raty', function(evt) {
that.score.removeAttr('value');
if (that.opt.click) {
@@ -151,7 +151,7 @@
_bindOut: function() {
var that = this;
that.self.on('mouseleave.raty', function(evt) {
that.self.on('mouseleave.um_raty', function(evt) {
var score = +that.score.val() || undefined;
methods._apply.call(that, score);
@@ -166,7 +166,7 @@
_bindOutCancel: function() {
var that = this;
that.cancel.on('mouseleave.raty', function(evt) {
that.cancel.on('mouseleave.um_raty', function(evt) {
var icon = that.opt.cancelOff;
if (that.opt.starType !== 'img') {
@@ -185,7 +185,7 @@
_bindOver: function() {
var that = this,
action = that.opt.half ? 'mousemove.raty' : 'mouseover.raty';
action = that.opt.half ? 'mousemove.um_raty' : 'mouseover.um_raty';
that.stars.on(action, function(evt) {
var score = methods._getScoreByPosition.call(that, evt, this);
@@ -209,7 +209,7 @@
_bindOverCancel: function() {
var that = this;
that.cancel.on('mouseover.raty', function(evt) {
that.cancel.on('mouseover.um_raty', function(evt) {
var
starOff = that.opt.path + that.opt.starOff,
icon = that.opt.cancelOn;
@@ -504,7 +504,7 @@
raw = self.data('raw');
if (raw) {
self.off('.raty').empty().css({ cursor: raw.style.cursor }).removeData('readonly');
self.off('.um_raty').empty().css({ cursor: raw.style.cursor }).removeData('readonly');
} else {
self.data('raw', self.clone()[0]);
}
@@ -553,7 +553,7 @@
if (self.data('readonly') !== readonly) {
if (readonly) {
self.off('.raty').children('img').off('.raty');
self.off('.um_raty').children('img').off('.um_raty');
methods._lock.call(this);
} else {
@@ -582,7 +582,7 @@
actual = self.data('options'),
news = $.extend({}, actual, options);
self.raty(news);
self.um_raty(news);
});
},
@@ -596,7 +596,7 @@
}
};
$.fn.raty = function(method) {
$.fn.um_raty = function(method) {
if (methods[method]) {
return methods[method].apply(this, Array.prototype.slice.call(arguments, 1));
} else if (typeof method === 'object' || !method) {
@@ -606,7 +606,7 @@
}
};
$.fn.raty.defaults = {
$.fn.um_raty.defaults = {
cancel : false,
cancelClass : 'raty-cancel',
cancelHint : 'Cancel this rating!',
+2 -2
View File
@@ -113,7 +113,7 @@ jQuery(document).ready(function() {
});
});
jQuery('.um-rating').raty({
jQuery('.um-rating').um_raty({
half: false,
starType: 'i',
number: function() {return jQuery(this).attr('data-number');},
@@ -127,7 +127,7 @@ jQuery(document).ready(function() {
}
});
jQuery('.um-rating-readonly').raty({
jQuery('.um-rating-readonly').um_raty({
half: false,
starType: 'i',
number: function() {return jQuery(this).attr('data-number');},
+20 -25
View File
@@ -65,38 +65,33 @@
} // end if
} // end foreach
} // end if $show_tagline
?>
<?php if ( $show_userinfo ) { ?>
<div class="um-member-meta-main">
if ( ! empty( $show_userinfo ) ) { ?>
<div class="um-member-meta-main">
<?php if ( $userinfo_animate ) { ?>
<div class="um-member-more"><a href="#"><i class="um-faicon-angle-down"></i></a></div>
<div class="um-member-more"><a href="#"><i class="um-faicon-angle-down"></i></a></div>
<?php } ?>
<div class="um-member-meta <?php if ( !$userinfo_animate ) { echo 'no-animate'; } ?>">
<div class="um-member-meta <?php if ( ! $userinfo_animate ) { echo 'no-animate'; } ?>">
<?php foreach( $reveal_fields as $key ) {
if ( $key /*&& um_filtered_value( $key )*/ ) {
$value = um_filtered_value( $key );
if ( ! $value )
continue;
?>
<?php um_fetch_user( $member );
foreach ( $reveal_fields as $key ) {
if ( $key ) {
$value = um_filtered_value( $key );
if ( ! $value )
continue; ?>
<div class="um-member-metaline um-member-metaline-<?php echo $key; ?>"><span><strong><?php echo UM()->fields()->get_label( $key ); ?>:</strong> <?php echo $value; ?></span></div>
<?php
}
}
?>
<?php if ( $show_social ) { ?>
<div class="um-member-connect">
<?php UM()->fields()->show_social_urls(); ?>
<div class="um-member-metaline um-member-metaline-<?php echo $key; ?>"><span><strong><?php echo UM()->fields()->get_label( $key ); ?>:</strong> <?php echo $value; ?></span></div>
</div>
<?php }
}
if ( $show_social ) { ?>
<div class="um-member-connect">
<?php UM()->fields()->show_social_urls(); ?>
</div>
<?php } ?>
</div>