rtMedia for WordPress, BuddyPress and bbPress - Version 4.2

Version Description

Requires BuddyPress 1.7 or higher, if using BuddyPress. Album media count, @mention functionality on media comments, Next previous link on media page and bug.

=

Download this release

Release Info

Developer mangeshp
Plugin Icon 128x128 rtMedia for WordPress, BuddyPress and bbPress
Version 4.2
Comparing to
See all releases

Code changes from version 4.1.7 to 4.2

Files changed (39) hide show
  1. Local +0 -0
  2. app/admin/RTMediaAdmin.php +2 -1
  3. app/assets/admin/css/admin.css +9 -0
  4. app/assets/admin/css/admin.min.css +1 -1
  5. app/assets/admin/css/sass/_layout.scss +14 -0
  6. app/assets/admin/js/admin.min.js +1 -1
  7. app/assets/admin/js/settings.js +50 -1
  8. app/assets/css/rtmedia.css +55 -0
  9. app/assets/css/rtmedia.min.css +1 -1
  10. app/assets/css/sass/_activity.scss +51 -23
  11. app/assets/css/sass/_buddypress.scss +8 -0
  12. app/assets/css/sass/_popup.scss +20 -0
  13. app/assets/css/sass/_rtm.scss +11 -0
  14. app/assets/js/rtMedia.backbone.js +428 -335
  15. app/assets/js/rtMedia.js +33 -8
  16. app/assets/js/rtmedia.min.js +2 -2
  17. app/helper/RTMediaCommentNotification.php +2 -3
  18. app/helper/RTMediaLicense.php +13 -1
  19. app/helper/RTMediaSupport.php +130 -24
  20. app/helper/db/RTDBModel.php +0 -1
  21. app/helper/rtUploadAttachment.php +43 -0
  22. app/importers/RTMediaMediaSizeImporter.php +2 -1
  23. app/importers/RTMediaMigration.php +1 -1
  24. app/main/RTMedia.php +29 -1
  25. app/main/controllers/activity/RTMediaBuddyPressActivity.php +160 -161
  26. app/main/controllers/media/RTMediaComment.php +2 -2
  27. app/main/controllers/media/RTMediaLike.php +18 -1
  28. app/main/controllers/media/RTMediaLoginPopup.php +1 -1
  29. app/main/controllers/template/RTMediaNav.php +17 -10
  30. app/main/controllers/template/RTMediaTemplate.php +5 -1
  31. app/main/controllers/template/rtmedia-actions.php +273 -12
  32. app/main/controllers/template/rtmedia-filters.php +93 -51
  33. app/main/controllers/template/rtmedia-functions.php +251 -53
  34. app/main/routers/query/RTMediaQuery.php +80 -80
  35. index.php +1 -1
  36. languages/buddypress-media.po +325 -245
  37. readme.txt +43 -5
  38. templates/media/album-gallery-item.php +13 -8
  39. templates/media/media-single.php +11 -3
Local ADDED
File without changes
app/admin/RTMediaAdmin.php CHANGED
@@ -863,7 +863,8 @@ if ( ! class_exists( 'RTMediaAdmin' ) ) {
863
wp_localize_script( 'rtmedia-admin', 'rtmedia_off_label', esc_html__( 'OFF', 'buddypress-media' ) );
864
wp_localize_script( 'rtmedia-admin', 'rtmedia_admin_ajax', $admin_ajax );
865
wp_localize_script( 'rtmedia-admin', 'rtmedia_admin_url', admin_url() );
866
- wp_localize_script( 'rtmedia-admin', 'rtmedia_admin_url', admin_url() );
867
868
$rtmedia_admin_strings = array(
869
'no_refresh' => esc_html__( 'Please do not refresh this page.', 'buddypress-media' ),
863
wp_localize_script( 'rtmedia-admin', 'rtmedia_off_label', esc_html__( 'OFF', 'buddypress-media' ) );
864
wp_localize_script( 'rtmedia-admin', 'rtmedia_admin_ajax', $admin_ajax );
865
wp_localize_script( 'rtmedia-admin', 'rtmedia_admin_url', admin_url() );
866
+ /* path for file upload using ajax */
867
+ wp_localize_script( 'rtmedia-admin', 'rtmedia_fileupload_url', RTMEDIA_URL.'app/helper/rtUploadAttachment.php' );
868
869
$rtmedia_admin_strings = array(
870
'no_refresh' => esc_html__( 'Please do not refresh this page.', 'buddypress-media' ),
app/assets/admin/css/admin.css CHANGED
@@ -83,6 +83,15 @@
83
padding: 20px 30px;
84
vertical-align: top;
85
}
86
87
.rtm-setting-container {
88
background-color: #f5f5f5;
83
padding: 20px 30px;
84
vertical-align: top;
85
}
86
+ .rtm-admin-tab-container .rtm-tabs-content #debug tbody {
87
+ display: block;
88
+ height: 400px;
89
+ overflow-y: auto;
90
+ }
91
+ .rtm-admin-tab-container .rtm-tabs-content #debug .rtm-download-debuginfo {
92
+ float: right;
93
+ margin-top: 14px;
94
+ }
95
96
.rtm-setting-container {
97
background-color: #f5f5f5;
app/assets/admin/css/admin.min.css CHANGED
@@ -1 +1 @@
1
- .alignleft{float:left}.alignright{float:right}.aligncenter{display:block;margin-left:auto;margin-right:auto;text-align:center}.clear-both{clear:both}.clear-none{clear:none}.clear-left{clear:left}.clear-right{clear:right}.rtm-inline-block{display:inline-block}.rtm-text-left{text-align:left}.rtm-text-right{text-align:right}.rtm-text-center{text-align:center}.rtm-border-0{border:0 !important}.hide{display:none}.clearfix:after{content:"";display:table;clear:both}.rtm-row-container{padding-top:10px}.rtm-admin-tab-container{display:table;width:100%}.rtm-admin-tab-container .rtm-tabs-content{background:#fff;border-left:1px solid #e7e7e7;display:table-cell;min-height:300px;padding:20px 30px;vertical-align:top}.rtm-setting-container{background-color:#f5f5f5;border:1px solid #dedede;box-shadow:0 1px 1px rgba(0,0,0,0.04);margin-top:10px}.rtm-sidebar .postbox .hndle{cursor:default}.rtm-tabs{display:table-cell;list-style:none;margin:0;min-height:300px;width:202px}.rtm-button-container{background:#f3f3f3;border-bottom:1px solid #dedede;box-shadow:0 1px 0 #fcfcfc inset;overflow:hidden;padding:6px 10px 6px 6px;position:relative;text-align:right}.rtm-button-container.bottom{background:#eee;border-top:1px solid #e7e7e7;box-shadow:0 0 0;z-index:999}#mce-EMAIL{width:100%}#mc-embedded-subscribe{display:block;margin:10px auto 0;width:100%}.license-row{box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-flex:0;-ms-flex:0 1 auto;flex:0 1 auto;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.license-column,.license-column{box-sizing:border-box;-webkit-box-flex:0;-ms-flex:0 0 auto;flex:0 0 auto;padding-right:.5rem;padding-left:.5rem}.large-4{-ms-flex-preferred-size:33.33333333%;flex-basis:33.33333333%;max-width:33.33333333%}@media screen and (max-width: 768px){.medium-6{-ms-flex-preferred-size:50%;flex-basis:50%;max-width:50%}}@media screen and (max-width: 667px){.small-12{-ms-flex-preferred-size:100%;flex-basis:100%;max-width:100%}}.rtm-social-links a{display:inline-block;margin:4px 0 4px 4px;text-decoration:none}.nav-tab.rtm-premium{background:#e74c3c;color:white;letter-spacing:0.5px}.rtm-setting-title{border-bottom:1px solid #eee;font-size:22px;font-weight:400;line-height:1;margin-bottom:20px;margin-top:0;padding-bottom:14px;display:none}.rtm-setting-title.rtm-show{display:block}.rtm-option-wrapper{margin-bottom:40px}.rtm-option-wrapper:last-child{margin-bottom:20px}.rtm-setting-title+.rtm-option-wrapper{margin-top:0}.rtm-option-wrapper:last-child{border-bottom:0}.rtm-option-wrapper .form-table{clear:none}.rtm-option-wrapper .rtm-field-wrap{float:left}.rtm-option-wrapper a{text-decoration:none}.rtm-option-wrapper .form-table th{color:#444;font-size:13px;font-weight:400;padding:5px 30px 5px 0;vertical-align:top;width:48%}.rtm-option-wrapper .form-table td{font-size:13px;padding:0 0 5px;vertical-align:top}.rtm-option-wrapper .form-table td fieldset label{display:block;margin:0 !important}.rtm-option-wrapper .form-table .rtm-form-radio label{margin-top:5px !important}.rtm-option-wrapper textarea,.rtm-option-wrapper select,.rtm-option-wrapper input[type=text],.rtm-option-wrapper input[type=number]{border-radius:3px}.rtm-option-wrapper input[type=number]{width:60px}.rtm-option-wrapper .rt-form-radio{height:28px;line-height:24px}.rtm-option-wrapper .rt-form-radio label:first-child{margin-right:12px !important}.rtm-option-wrapper .dashicons-info{color:#aaa;font-size:14px;height:26px;line-height:26px;position:relative}.rtm-option-wrapper .rtm-debug-info{margin-top:32px}.rtm-option-wrapper .rtm-debug-info tr{border-bottom:1px solid #eee}.rtm-option-wrapper .rtm-debug-info tr:first-child{border-top:1px solid #eee}.rtm-option-wrapper .rtm-debug-info tr:nth-child(2n){background-color:#f8f8f8}.rtm-option-wrapper .rtm-debug-info th{border-right:1px solid #eee;font-weight:600;width:auto}.rtm-option-wrapper .rtm-debug-info th,.rtm-option-wrapper .rtm-debug-info td{padding:10px}.rtm-option-title{border-bottom:1px solid #eee;font-size:14px;letter-spacing:0.02rem;margin-bottom:12px;margin-top:0;padding:0 0 6px;text-transform:uppercase}.rtm-sidebar .button{display:block;opacity:0.8;position:relative;text-decoration:none}.rtm-social-share .dashicons{font-size:18px;position:absolute;right:10px;top:4px}.rtm-social-share .twitter .dashicons{color:#45b0e3}.rtm-social-share .facebook .dashicons{color:#3b5998}.rtm-social-share .wordpress .dashicons{color:#21759b}.rtm-social-share .rss .dashicons{color:#FF6600}.rtm-social-share p:last-child{margin-bottom:0}.rtm-notice{background:rgba(238,238,238,0.8);color:#777;font-size:12px;line-height:1.6;margin-top:10px;overflow:hidden;padding:0 10px}.rtm-notice p{font-size:inherit;line-height:inherit;margin:10px 0}.rtm-warning{background-color:#fcf8e3;border-bottom:1px solid #EEE;color:#c09853;padding:10px 15px}.rtmedia-theme-warning{margin-bottom:26px}.rtm-success{background-color:#dff0d8;border-bottom:1px solid #e7e7e7;color:#468847;margin:0;padding:8px 35px 8px 14px;text-shadow:0 1px 0 rgba(255,255,255,0.5)}.rtm-fly-warning{border-bottom:0;left:-10px;letter-spacing:1px;line-height:22px;margin-bottom:0;padding:14px 25px;position:absolute;top:-5px}#rtmedia-types .form-table th{line-height:26px;padding:5px 0 20px;width:33%}#rtmedia-types .form-table td{padding:0 0 12px}#rtmedia-custom-css-settings .form-table th{width:35%}#rtmedia-custom-css-settings .form-table:last-child .rtm-field-wrap{width:92%}#rtmedia-custom-css-settings textarea{height:300px;width:100%}.rtm-img-size-setting .form-table th{border-bottom:1px solid #eee;padding-bottom:10px;padding-top:10px;width:20%}.rtm-img-size-setting .form-table tr:nth-child(2) td{padding-top:20px}.rtm-img-size-setting .form-table tr:nth-child(4){border-bottom:1px solid #eee}.rtm-img-size-setting .form-table tr:nth-child(4) td{padding-bottom:20px}.rtm-img-size-setting .form-table tr:nth-child(5) td{padding-top:20px}.rtm-img-size-setting .form-table tr:nth-child(6) td{padding-bottom:20px}.rtm-img-size-setting .form-table tr:nth-child(7){border-top:1px solid #eee}.rtm-img-size-setting .form-table tr:nth-child(7) td{padding-top:20px}.rtm-img-size-setting .form-table tr:nth-last-child(2) td{padding-bottom:20px}.rtm-img-size-setting .form-table tr:last-child{border-top:1px solid #eee}.rtm-img-size-setting .form-table tr:last-child td{padding-top:20px;padding-bottom:20px}.rtm-img-size-setting .form-table .rtm-row-title{font-weight:600}#rtmedia-privacy .rt-form-radio{font-size:12px}#rtmedia-privacy .rt-form-radio strong{font-size:13px}.rtm-addon-license{border:1px solid #ddd;margin:.5rem 0;background-color:#fff}.rtm-addon-license .title{background-color:#fafafa;border-bottom:1px solid #ddd;margin:0;padding:15px 10px}.rtm-addon-license .license-inner{padding:10px}form.license-form{padding:0;margin:0}form.license-form input[type="text"]{width:100%;max-width:100%;height:35px;line-height:35px}form.license-form input[type="submit"]{margin:10px 0 0}.license-message{margin:15px 0 0 0;padding:8px}.license-message.warning{background:rgba(255,185,0,0.1);border:1px solid #ffb900}.license-message.success{background:rgba(70,180,80,0.1);border:1px solid #46b450}.license-message.info{background:rgba(0,160,210,0.1);border:1px solid #00a0d2}.license-message.alert{background:rgba(220,50,50,0.1);border:1px solid #dc3232}.rtml-submit-wrapper .submit{margin-left:8px;margin-right:8px;margin-top:0;padding-top:0;padding-bottom:10px}#rtmedia-encoding-usage strong{display:inline-block;min-width:120px}#rtmedia-encoding-usage p{overflow:hidden}.encoding-used,.encoding-remaining{background:#7AD03A;float:right;height:12px;margin-top:3px;width:12px}.encoding-remaining{background:#dedede}#rtprogressbar{background:#dedede;height:10px;position:relative}#rtprogressbar div{background:#7AD03A;height:10px;left:0;position:absolute}.rtm-tabs li{margin:0}.rtm-tabs li.error{border-left:4px solid #dc3232}.rtm-tabs a{border-bottom:1px solid #e7e7e7;border-top:1px solid #f2f2f2;color:#222;display:block;font-weight:700;outline:none;opacity:0.8;padding:10px 4px 10px 14px;position:relative;text-decoration:none;z-index:10}.rtm-tabs a:hover{background:#eee;color:#269ad6;margin-right:0;opacity:1;width:auto}.rtm-tabs a:focus{background:#fff;box-shadow:0 0 0}.rtm-tabs .active{background:white;position:relative}.rtm-tabs .active:after{background:#fff;content:' ';height:100%;position:absolute;right:-1px;top:0;width:1px}.rtm-tabs .active a{border-top-color:#fff;color:#222;opacity:1}.rtm-tabs .active a:hover{background:#fff}.rtm-tabs span{display:block;padding:0 0 0 25px}.rtm-tabs .dashicons{font-size:14px;height:auto;line-height:1;margin-top:3px;position:absolute;vertical-align:middle;width:auto}.rtm-horizotanl-tabs .rtm-tabs{list-style:none;margin:0;display:block;width:auto;min-height:0}.rtm-horizotanl-tabs .rtm-tabs-content{border-left:none;background:#fff;min-height:300px;padding:20px 30px;vertical-align:top}.rtm-horizotanl-tabs .rtm-tabs a{border-bottom:none}.rtm-horizotanl-tabs .rtm-tabs li{display:inline-block}.rtm-horizotanl-tabs.rtm-admin-tab-container{width:100%;display:block}.switch{position:relative;display:inline-block;vertical-align:top;width:58px;height:22px;padding:3px;border-radius:18px}.switch input[type=checkbox]{position:absolute;top:0;left:0;opacity:0}.switch-label{position:relative;display:block;height:inherit;color:#fff;font-size:12px;text-transform:uppercase;background:#b4b4b4;border-radius:inherit;-webkit-transition:0.15s ease-out;transition:0.15s ease-out;-webkit-transition-property:opacity background;transition-property:opacity background}.switch-label:before,.switch-label:after{position:absolute;top:50%;margin-top:-.5em;line-height:1;-webkit-transition:inherit;transition:inherit}.switch-label:before{content:attr(data-off);right:11px;color:#fff}.switch-label:after{content:attr(data-on);left:11px;opacity:0}input[type=checkbox]:checked ~ .switch-label{background:#33a7d1}input[type=checkbox]:checked ~ .switch-label:before{opacity:0}input[type=checkbox]:checked ~ .switch-label:after{opacity:1}.switch-handle{position:absolute;top:5px;left:5px;width:18px;height:18px;background:white;border-radius:10px;box-shadow:1px 1px 5px rgba(0,0,0,0.2);background-image:-webkit-linear-gradient(top, #fff 40%, #f0f0f0);background-image:linear-gradient(to bottom, #fff 40%, #f0f0f0);-webkit-transition:left 0.15s ease-out;transition:left 0.15s ease-out}.switch-handle:before{content:'';position:absolute;top:50%;left:50%;margin:-6px 0 0 -6px;width:12px;height:12px;background:#f9f9f9;border-radius:6px;box-shadow:inset 0 1px rgba(0,0,0,0.02);background-image:-webkit-linear-gradient(top, #eee, #fff);background-image:linear-gradient(to bottom, #eee, #fff)}input[type=checkbox]:checked ~ .switch-handle{left:41px;box-shadow:-1px 1px 5px rgba(0,0,0,0.2)}.rtm-tooltip{display:inline-block;margin-left:3px;position:relative}.rtm-tooltip:hover .rtm-tip-top,.rtm-tooltip:hover .rtm-tip{margin-left:0;opacity:1;visibility:visible}.rtm-tooltip .rtm-title{border-bottom:1px dotted;padding-bottom:2px}.rtm-tip-top,.rtm-tip{background:#fffAF0;border:1px solid #f5deaf;border-radius:3px;font-size:12px;left:24px;margin-top:-4px;margin-left:-10px;line-height:1.5;opacity:0;padding:6px 12px;position:absolute;top:0;visibility:hidden;width:210px;z-index:9999;-webkit-transition:all ease-in-out 0.4s;transition:all ease-in-out 0.4s}.rtm-tip-top{bottom:26px;left:auto;right:-66px;top:auto;width:200px}.rtm-tip-top:after,.rtm-tip-top:before{right:auto;top:100%;left:50%;border:solid transparent;content:' ';height:0;width:0;position:absolute;pointer-events:none}.rtm-tip-top:after{border-color:rgba(255,250,240,0);border-top-color:#fffAF0;border-width:6px;margin-left:-6px}.rtm-tip-top:before{border-color:rgba(245,222,175,0);border-top-color:#f5deaf;border-width:8px;margin-left:-8px}.rtm-extensions .dashicons{font-size:12px;margin-left:-4px;position:relative;top:-3px}.rtm-extensions.rtm-set-top .dashicons{top:1px}.rtm-plugin-card.plugin-card{margin:1%;overflow:hidden;width:48%}.rtm-plugin-card.plugin-card .rtm-logo{float:left;margin-right:10px;max-width:200px;width:auto}.rtm-plugin-card.plugin-card .rtm-logo img{height:auto;max-width:120px}.rtm-plugin-card.plugin-card .desc,.rtm-plugin-card.plugin-card .name{margin-left:0;margin-right:0;overflow:hidden}.rtm-plugin-card.plugin-card h4{margin-bottom:0;margin-top:0}.rtm-plugin-card.plugin-card a{text-decoration:none}.rtm-plugin-card.plugin-card .rtm-live-demo{margin-right:10px}.rtm-plugin-card.plugin-card .price{color:#269ad6;font-size:22px;line-height:1.2}#rtm-plugins .rtm-option-title{margin-top:50px}#rtm-plugins .rtm-setting-title+.rtm-option-title{margin-top:0}#rtm-plugins .plugin-card-top{padding:10px}.rtm-encoding-table{border-collapse:collapse;clear:none}.rtm-encoding-table th,.rtm-encoding-table td{border:1px solid #e7e7e7}.rtm-encoding-table th{font-size:13px;font-weight:600}.rtm-theme-browser .rtm-themes{clear:none;padding:0}.rtm-theme-browser .rtm-themes .rtm-theme{width:48%}.rtm-theme-browser .rtm-themes .rtm-theme:nth-child(even){margin-right:0 !important}.rtm-theme-browser .rtm-themes .rtm-theme:nth-child(3n){margin-right:4%}.admin-bar .theme-overlay .theme-wrap{z-index:99999}.rtm-support-container{min-height:300px}.rtm-support-form .rtm-form-filed{clear:both;margin:15px 0}.rtm-support-form label{float:left;width:15%}.rtm-support-form .bp-media-textarea{height:80px}.rtm-button-wrapper{padding-left:15%}.rtm-page-container{background:#fff;overflow:hidden;padding:20px}.rtm-pro-feature-list li{box-sizing:border-box;float:left;padding:0 10px 20px;width:33%}.rtm-pro-feature-list .rtm-icon-wrap{float:left;margin-top:15px;width:30px}.rtm-pro-feature-list .dashicons{font-size:18px}.rtm-pro-feature-list .rtm-title{font-size:18px;margin-left:30px;margin-top:0px}.rtm-pro-feature-list .rtm-content{font-size:14px;line-height:25px;margin-left:30px;color:#8a8a8a;width:auto}.rtm-update-to-pro{text-align:center}.rtm-button{background-color:#269ad6;border:0;border-radius:3px;color:#fff;cursor:pointer;display:inline-block;font-size:13px;letter-spacing:1px;line-height:1;margin-bottom:10px;padding:12px 26px;text-align:center;text-decoration:none;text-transform:uppercase}.rtm-button:hover,.rtm-button:focus{background-color:#228ac0;color:#fff}.rtm-button.large{font-size:16px;margin-bottom:20px;padding:20px 40px}.rtm-button.rtm-button-success{background-color:#2ecc71}.rtm-button.rtm-button-success:hover,.rtm-button.rtm-button-success:focus{background-color:#2fab41}.rtm-hire-points{font-size:14px;margin-bottom:24px}@media only screen and (min-width: 1025px){.rtm-setting-container{float:left;width:78.2%}.rtm-sidebar{float:right;width:20%}.rtm-sidebar .postbox{min-width:0}.rtm-field-wrap{max-width:92%}.rtm-tip:after,.rtm-tip:before{right:100%;top:15px;border:solid transparent;content:" ";height:0;width:0;position:absolute;pointer-events:none}.rtm-tip:after{border-color:rgba(255,250,240,0);border-right-color:#fffAF0;border-width:6px;margin-top:-6px}.rtm-tip:before{border-color:rgba(221,204,170,0);border-right-color:#f5deaf;border-width:7px;margin-top:-7px}.rtm-support-form .bp-media-input,.rtm-support-form .bp-media-textarea{float:left;width:40%}}@media only screen and (min-width: 641px) and (max-width: 1024px){.rtm-sidebar{width:100%}.rtm-sidebar .postbox{display:inline-block;margin-left:5px;vertical-align:top}.rtm-sidebar .postbox:first-child{margin-left:0}}@media screen and (max-width: 1024px){.rtm-tip{bottom:26px;left:auto;right:-102px;top:auto;width:200px}.rtm-tip:after,.rtm-tip:before{right:auto;top:100%;left:50%;border:solid transparent;content:' ';height:0;width:0;position:absolute;pointer-events:none}.rtm-tip:after{border-color:rgba(255,250,240,0);border-top-color:#fffAF0;border-width:6px;margin-left:-6px}.rtm-tip:before{border-color:rgba(245,222,175,0);border-top-color:#f5deaf;border-width:7px;margin-left:-7px}#rtmedia-custom-css-settings .form-table:last-child .rtm-field-wrap{width:100%}.rtm-field-wrap input[type=text]{max-width:140px !important}.theme-browser .theme:nth-child(2n+1){margin-right:4%}.rtmedia-settings-submit{margin-bottom:0 !important}}@media only screen and (min-width: 641px){.rtm-pro-feature-list li:nth-child(3n+1){clear:left}}@media screen and (min-width: 421px) and (max-width: 782px){.rtm-option-wrapper .form-table td{display:table-cell}.rtm-option-wrapper .form-table th{display:table-cell}}@media only screen and (max-width: 640px){.rtm-pro-feature-list li{width:50%}.rtm-pro-feature-list li:nth-child(2n+1){clear:left}.rtm-tabs{width:40px}.rtm-tabs li{width:40px}.rtm-tabs a{height:18px}.rtm-tabs a:hover{width:140px}.rtm-tabs a:hover span{display:block}.rtm-tabs span{display:none;padding:0 0 0 28px;position:absolute}.rtm-support-form label{width:100%;margin-bottom:5px}.rtm-support-form .bp-media-input,.rtm-support-form .bp-media-textarea{width:70%}.rtm-button-wrapper{padding-left:0}}@media screen and (max-width: 481px){.rtm-plugin-card.plugin-card .rtm-logo{display:inline-block;float:none}.rtm-theme-browser .rtm-themes .rtm-theme{margin:0 0 20px;width:100%}}@media screen and (max-width: 420px){.rtm-option-wrapper .form-table th{padding-bottom:15px;width:100%}#rtmedia-types .form-table th,#rtmedia-custom-css-settings .form-table th{width:100%}.rtm-pro-feature-list li{width:100%}.rtm-tip-top{right:-115px}}body.rtl .rtm-tabs a{padding:10px 32px 10px 4px}body.rtl .rtm-tabs .dashicons{right:10px}body.rtl .rtm-social-share .dashicons{left:10px;right:auto}body.rtl .rtm-option-wrapper .rtm-field-wrap{float:right}body.rtl .rtm-tip-top,body.rtl .rtm-tip{left:auto;right:24px}body.rtl .rtm-tip-top:after,body.rtl .rtm-tip-top:before,body.rtl .rtm-tip:after,body.rtl .rtm-tip:before{display:none}body.rtl .rtm-edit-td,body.rtl .rtm-delete-td{float:right;margin-left:0}body.rtl .rtm-edit-td{margin-right:-15px}body.rtl #rtmedia-membership span.float-right{float:left}body.rtl .theme-browser .theme{float:left;margin:0 4% 4% 0}.rtmedia-license .rtm-tabs span{padding:0}
1
+ .alignleft{float:left}.alignright{float:right}.aligncenter{display:block;margin-left:auto;margin-right:auto;text-align:center}.clear-both{clear:both}.clear-none{clear:none}.clear-left{clear:left}.clear-right{clear:right}.rtm-inline-block{display:inline-block}.rtm-text-left{text-align:left}.rtm-text-right{text-align:right}.rtm-text-center{text-align:center}.rtm-border-0{border:0 !important}.hide{display:none}.clearfix:after{content:"";display:table;clear:both}.rtm-row-container{padding-top:10px}.rtm-admin-tab-container{display:table;width:100%}.rtm-admin-tab-container .rtm-tabs-content{background:#fff;border-left:1px solid #e7e7e7;display:table-cell;min-height:300px;padding:20px 30px;vertical-align:top}.rtm-admin-tab-container .rtm-tabs-content #debug tbody{display:block;height:400px;overflow-y:auto}.rtm-admin-tab-container .rtm-tabs-content #debug .rtm-download-debuginfo{float:right;margin-top:14px}.rtm-setting-container{background-color:#f5f5f5;border:1px solid #dedede;box-shadow:0 1px 1px rgba(0,0,0,0.04);margin-top:10px}.rtm-sidebar .postbox .hndle{cursor:default}.rtm-tabs{display:table-cell;list-style:none;margin:0;min-height:300px;width:202px}.rtm-button-container{background:#f3f3f3;border-bottom:1px solid #dedede;box-shadow:0 1px 0 #fcfcfc inset;overflow:hidden;padding:6px 10px 6px 6px;position:relative;text-align:right}.rtm-button-container.bottom{background:#eee;border-top:1px solid #e7e7e7;box-shadow:0 0 0;z-index:999}#mce-EMAIL{width:100%}#mc-embedded-subscribe{display:block;margin:10px auto 0;width:100%}.license-row{box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-flex:0;-ms-flex:0 1 auto;flex:0 1 auto;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.license-column,.license-column{box-sizing:border-box;-webkit-box-flex:0;-ms-flex:0 0 auto;flex:0 0 auto;padding-right:.5rem;padding-left:.5rem}.large-4{-ms-flex-preferred-size:33.33333333%;flex-basis:33.33333333%;max-width:33.33333333%}@media screen and (max-width: 768px){.medium-6{-ms-flex-preferred-size:50%;flex-basis:50%;max-width:50%}}@media screen and (max-width: 667px){.small-12{-ms-flex-preferred-size:100%;flex-basis:100%;max-width:100%}}.rtm-social-links a{display:inline-block;margin:4px 0 4px 4px;text-decoration:none}.nav-tab.rtm-premium{background:#e74c3c;color:white;letter-spacing:0.5px}.rtm-setting-title{border-bottom:1px solid #eee;font-size:22px;font-weight:400;line-height:1;margin-bottom:20px;margin-top:0;padding-bottom:14px;display:none}.rtm-setting-title.rtm-show{display:block}.rtm-option-wrapper{margin-bottom:40px}.rtm-option-wrapper:last-child{margin-bottom:20px}.rtm-setting-title+.rtm-option-wrapper{margin-top:0}.rtm-option-wrapper:last-child{border-bottom:0}.rtm-option-wrapper .form-table{clear:none}.rtm-option-wrapper .rtm-field-wrap{float:left}.rtm-option-wrapper a{text-decoration:none}.rtm-option-wrapper .form-table th{color:#444;font-size:13px;font-weight:400;padding:5px 30px 5px 0;vertical-align:top;width:48%}.rtm-option-wrapper .form-table td{font-size:13px;padding:0 0 5px;vertical-align:top}.rtm-option-wrapper .form-table td fieldset label{display:block;margin:0 !important}.rtm-option-wrapper .form-table .rtm-form-radio label{margin-top:5px !important}.rtm-option-wrapper textarea,.rtm-option-wrapper select,.rtm-option-wrapper input[type=text],.rtm-option-wrapper input[type=number]{border-radius:3px}.rtm-option-wrapper input[type=number]{width:60px}.rtm-option-wrapper .rt-form-radio{height:28px;line-height:24px}.rtm-option-wrapper .rt-form-radio label:first-child{margin-right:12px !important}.rtm-option-wrapper .dashicons-info{color:#aaa;font-size:14px;height:26px;line-height:26px;position:relative}.rtm-option-wrapper .rtm-debug-info{margin-top:32px}.rtm-option-wrapper .rtm-debug-info tr{border-bottom:1px solid #eee}.rtm-option-wrapper .rtm-debug-info tr:first-child{border-top:1px solid #eee}.rtm-option-wrapper .rtm-debug-info tr:nth-child(2n){background-color:#f8f8f8}.rtm-option-wrapper .rtm-debug-info th{border-right:1px solid #eee;font-weight:600;width:auto}.rtm-option-wrapper .rtm-debug-info th,.rtm-option-wrapper .rtm-debug-info td{padding:10px}.rtm-option-title{border-bottom:1px solid #eee;font-size:14px;letter-spacing:0.02rem;margin-bottom:12px;margin-top:0;padding:0 0 6px;text-transform:uppercase}.rtm-sidebar .button{display:block;opacity:0.8;position:relative;text-decoration:none}.rtm-social-share .dashicons{font-size:18px;position:absolute;right:10px;top:4px}.rtm-social-share .twitter .dashicons{color:#45b0e3}.rtm-social-share .facebook .dashicons{color:#3b5998}.rtm-social-share .wordpress .dashicons{color:#21759b}.rtm-social-share .rss .dashicons{color:#FF6600}.rtm-social-share p:last-child{margin-bottom:0}.rtm-notice{background:rgba(238,238,238,0.8);color:#777;font-size:12px;line-height:1.6;margin-top:10px;overflow:hidden;padding:0 10px}.rtm-notice p{font-size:inherit;line-height:inherit;margin:10px 0}.rtm-warning{background-color:#fcf8e3;border-bottom:1px solid #EEE;color:#c09853;padding:10px 15px}.rtmedia-theme-warning{margin-bottom:26px}.rtm-success{background-color:#dff0d8;border-bottom:1px solid #e7e7e7;color:#468847;margin:0;padding:8px 35px 8px 14px;text-shadow:0 1px 0 rgba(255,255,255,0.5)}.rtm-fly-warning{border-bottom:0;left:-10px;letter-spacing:1px;line-height:22px;margin-bottom:0;padding:14px 25px;position:absolute;top:-5px}#rtmedia-types .form-table th{line-height:26px;padding:5px 0 20px;width:33%}#rtmedia-types .form-table td{padding:0 0 12px}#rtmedia-custom-css-settings .form-table th{width:35%}#rtmedia-custom-css-settings .form-table:last-child .rtm-field-wrap{width:92%}#rtmedia-custom-css-settings textarea{height:300px;width:100%}.rtm-img-size-setting .form-table th{border-bottom:1px solid #eee;padding-bottom:10px;padding-top:10px;width:20%}.rtm-img-size-setting .form-table tr:nth-child(2) td{padding-top:20px}.rtm-img-size-setting .form-table tr:nth-child(4){border-bottom:1px solid #eee}.rtm-img-size-setting .form-table tr:nth-child(4) td{padding-bottom:20px}.rtm-img-size-setting .form-table tr:nth-child(5) td{padding-top:20px}.rtm-img-size-setting .form-table tr:nth-child(6) td{padding-bottom:20px}.rtm-img-size-setting .form-table tr:nth-child(7){border-top:1px solid #eee}.rtm-img-size-setting .form-table tr:nth-child(7) td{padding-top:20px}.rtm-img-size-setting .form-table tr:nth-last-child(2) td{padding-bottom:20px}.rtm-img-size-setting .form-table tr:last-child{border-top:1px solid #eee}.rtm-img-size-setting .form-table tr:last-child td{padding-top:20px;padding-bottom:20px}.rtm-img-size-setting .form-table .rtm-row-title{font-weight:600}#rtmedia-privacy .rt-form-radio{font-size:12px}#rtmedia-privacy .rt-form-radio strong{font-size:13px}.rtm-addon-license{border:1px solid #ddd;margin:.5rem 0;background-color:#fff}.rtm-addon-license .title{background-color:#fafafa;border-bottom:1px solid #ddd;margin:0;padding:15px 10px}.rtm-addon-license .license-inner{padding:10px}form.license-form{padding:0;margin:0}form.license-form input[type="text"]{width:100%;max-width:100%;height:35px;line-height:35px}form.license-form input[type="submit"]{margin:10px 0 0}.license-message{margin:15px 0 0 0;padding:8px}.license-message.warning{background:rgba(255,185,0,0.1);border:1px solid #ffb900}.license-message.success{background:rgba(70,180,80,0.1);border:1px solid #46b450}.license-message.info{background:rgba(0,160,210,0.1);border:1px solid #00a0d2}.license-message.alert{background:rgba(220,50,50,0.1);border:1px solid #dc3232}.rtml-submit-wrapper .submit{margin-left:8px;margin-right:8px;margin-top:0;padding-top:0;padding-bottom:10px}#rtmedia-encoding-usage strong{display:inline-block;min-width:120px}#rtmedia-encoding-usage p{overflow:hidden}.encoding-used,.encoding-remaining{background:#7AD03A;float:right;height:12px;margin-top:3px;width:12px}.encoding-remaining{background:#dedede}#rtprogressbar{background:#dedede;height:10px;position:relative}#rtprogressbar div{background:#7AD03A;height:10px;left:0;position:absolute}.rtm-tabs li{margin:0}.rtm-tabs li.error{border-left:4px solid #dc3232}.rtm-tabs a{border-bottom:1px solid #e7e7e7;border-top:1px solid #f2f2f2;color:#222;display:block;font-weight:700;outline:none;opacity:0.8;padding:10px 4px 10px 14px;position:relative;text-decoration:none;z-index:10}.rtm-tabs a:hover{background:#eee;color:#269ad6;margin-right:0;opacity:1;width:auto}.rtm-tabs a:focus{background:#fff;box-shadow:0 0 0}.rtm-tabs .active{background:white;position:relative}.rtm-tabs .active:after{background:#fff;content:' ';height:100%;position:absolute;right:-1px;top:0;width:1px}.rtm-tabs .active a{border-top-color:#fff;color:#222;opacity:1}.rtm-tabs .active a:hover{background:#fff}.rtm-tabs span{display:block;padding:0 0 0 25px}.rtm-tabs .dashicons{font-size:14px;height:auto;line-height:1;margin-top:3px;position:absolute;vertical-align:middle;width:auto}.rtm-horizotanl-tabs .rtm-tabs{list-style:none;margin:0;display:block;width:auto;min-height:0}.rtm-horizotanl-tabs .rtm-tabs-content{border-left:none;background:#fff;min-height:300px;padding:20px 30px;vertical-align:top}.rtm-horizotanl-tabs .rtm-tabs a{border-bottom:none}.rtm-horizotanl-tabs .rtm-tabs li{display:inline-block}.rtm-horizotanl-tabs.rtm-admin-tab-container{width:100%;display:block}.switch{position:relative;display:inline-block;vertical-align:top;width:58px;height:22px;padding:3px;border-radius:18px}.switch input[type=checkbox]{position:absolute;top:0;left:0;opacity:0}.switch-label{position:relative;display:block;height:inherit;color:#fff;font-size:12px;text-transform:uppercase;background:#b4b4b4;border-radius:inherit;-webkit-transition:0.15s ease-out;transition:0.15s ease-out;-webkit-transition-property:opacity background;transition-property:opacity background}.switch-label:before,.switch-label:after{position:absolute;top:50%;margin-top:-.5em;line-height:1;-webkit-transition:inherit;transition:inherit}.switch-label:before{content:attr(data-off);right:11px;color:#fff}.switch-label:after{content:attr(data-on);left:11px;opacity:0}input[type=checkbox]:checked ~ .switch-label{background:#33a7d1}input[type=checkbox]:checked ~ .switch-label:before{opacity:0}input[type=checkbox]:checked ~ .switch-label:after{opacity:1}.switch-handle{position:absolute;top:5px;left:5px;width:18px;height:18px;background:white;border-radius:10px;box-shadow:1px 1px 5px rgba(0,0,0,0.2);background-image:-webkit-linear-gradient(top, #fff 40%, #f0f0f0);background-image:linear-gradient(to bottom, #fff 40%, #f0f0f0);-webkit-transition:left 0.15s ease-out;transition:left 0.15s ease-out}.switch-handle:before{content:'';position:absolute;top:50%;left:50%;margin:-6px 0 0 -6px;width:12px;height:12px;background:#f9f9f9;border-radius:6px;box-shadow:inset 0 1px rgba(0,0,0,0.02);background-image:-webkit-linear-gradient(top, #eee, #fff);background-image:linear-gradient(to bottom, #eee, #fff)}input[type=checkbox]:checked ~ .switch-handle{left:41px;box-shadow:-1px 1px 5px rgba(0,0,0,0.2)}.rtm-tooltip{display:inline-block;margin-left:3px;position:relative}.rtm-tooltip:hover .rtm-tip-top,.rtm-tooltip:hover .rtm-tip{margin-left:0;opacity:1;visibility:visible}.rtm-tooltip .rtm-title{border-bottom:1px dotted;padding-bottom:2px}.rtm-tip-top,.rtm-tip{background:#fffAF0;border:1px solid #f5deaf;border-radius:3px;font-size:12px;left:24px;margin-top:-4px;margin-left:-10px;line-height:1.5;opacity:0;padding:6px 12px;position:absolute;top:0;visibility:hidden;width:210px;z-index:9999;-webkit-transition:all ease-in-out 0.4s;transition:all ease-in-out 0.4s}.rtm-tip-top{bottom:26px;left:auto;right:-66px;top:auto;width:200px}.rtm-tip-top:after,.rtm-tip-top:before{right:auto;top:100%;left:50%;border:solid transparent;content:' ';height:0;width:0;position:absolute;pointer-events:none}.rtm-tip-top:after{border-color:rgba(255,250,240,0);border-top-color:#fffAF0;border-width:6px;margin-left:-6px}.rtm-tip-top:before{border-color:rgba(245,222,175,0);border-top-color:#f5deaf;border-width:8px;margin-left:-8px}.rtm-extensions .dashicons{font-size:12px;margin-left:-4px;position:relative;top:-3px}.rtm-extensions.rtm-set-top .dashicons{top:1px}.rtm-plugin-card.plugin-card{margin:1%;overflow:hidden;width:48%}.rtm-plugin-card.plugin-card .rtm-logo{float:left;margin-right:10px;max-width:200px;width:auto}.rtm-plugin-card.plugin-card .rtm-logo img{height:auto;max-width:120px}.rtm-plugin-card.plugin-card .desc,.rtm-plugin-card.plugin-card .name{margin-left:0;margin-right:0;overflow:hidden}.rtm-plugin-card.plugin-card h4{margin-bottom:0;margin-top:0}.rtm-plugin-card.plugin-card a{text-decoration:none}.rtm-plugin-card.plugin-card .rtm-live-demo{margin-right:10px}.rtm-plugin-card.plugin-card .price{color:#269ad6;font-size:22px;line-height:1.2}#rtm-plugins .rtm-option-title{margin-top:50px}#rtm-plugins .rtm-setting-title+.rtm-option-title{margin-top:0}#rtm-plugins .plugin-card-top{padding:10px}.rtm-encoding-table{border-collapse:collapse;clear:none}.rtm-encoding-table th,.rtm-encoding-table td{border:1px solid #e7e7e7}.rtm-encoding-table th{font-size:13px;font-weight:600}.rtm-theme-browser .rtm-themes{clear:none;padding:0}.rtm-theme-browser .rtm-themes .rtm-theme{width:48%}.rtm-theme-browser .rtm-themes .rtm-theme:nth-child(even){margin-right:0 !important}.rtm-theme-browser .rtm-themes .rtm-theme:nth-child(3n){margin-right:4%}.admin-bar .theme-overlay .theme-wrap{z-index:99999}.rtm-support-container{min-height:300px}.rtm-support-form .rtm-form-filed{clear:both;margin:15px 0}.rtm-support-form label{float:left;width:15%}.rtm-support-form .bp-media-textarea{height:80px}.rtm-button-wrapper{padding-left:15%}.rtm-page-container{background:#fff;overflow:hidden;padding:20px}.rtm-pro-feature-list li{box-sizing:border-box;float:left;padding:0 10px 20px;width:33%}.rtm-pro-feature-list .rtm-icon-wrap{float:left;margin-top:15px;width:30px}.rtm-pro-feature-list .dashicons{font-size:18px}.rtm-pro-feature-list .rtm-title{font-size:18px;margin-left:30px;margin-top:0px}.rtm-pro-feature-list .rtm-content{font-size:14px;line-height:25px;margin-left:30px;color:#8a8a8a;width:auto}.rtm-update-to-pro{text-align:center}.rtm-button{background-color:#269ad6;border:0;border-radius:3px;color:#fff;cursor:pointer;display:inline-block;font-size:13px;letter-spacing:1px;line-height:1;margin-bottom:10px;padding:12px 26px;text-align:center;text-decoration:none;text-transform:uppercase}.rtm-button:hover,.rtm-button:focus{background-color:#228ac0;color:#fff}.rtm-button.large{font-size:16px;margin-bottom:20px;padding:20px 40px}.rtm-button.rtm-button-success{background-color:#2ecc71}.rtm-button.rtm-button-success:hover,.rtm-button.rtm-button-success:focus{background-color:#2fab41}.rtm-hire-points{font-size:14px;margin-bottom:24px}@media only screen and (min-width: 1025px){.rtm-setting-container{float:left;width:78.2%}.rtm-sidebar{float:right;width:20%}.rtm-sidebar .postbox{min-width:0}.rtm-field-wrap{max-width:92%}.rtm-tip:after,.rtm-tip:before{right:100%;top:15px;border:solid transparent;content:" ";height:0;width:0;position:absolute;pointer-events:none}.rtm-tip:after{border-color:rgba(255,250,240,0);border-right-color:#fffAF0;border-width:6px;margin-top:-6px}.rtm-tip:before{border-color:rgba(221,204,170,0);border-right-color:#f5deaf;border-width:7px;margin-top:-7px}.rtm-support-form .bp-media-input,.rtm-support-form .bp-media-textarea{float:left;width:40%}}@media only screen and (min-width: 641px) and (max-width: 1024px){.rtm-sidebar{width:100%}.rtm-sidebar .postbox{display:inline-block;margin-left:5px;vertical-align:top}.rtm-sidebar .postbox:first-child{margin-left:0}}@media screen and (max-width: 1024px){.rtm-tip{bottom:26px;left:auto;right:-102px;top:auto;width:200px}.rtm-tip:after,.rtm-tip:before{right:auto;top:100%;left:50%;border:solid transparent;content:' ';height:0;width:0;position:absolute;pointer-events:none}.rtm-tip:after{border-color:rgba(255,250,240,0);border-top-color:#fffAF0;border-width:6px;margin-left:-6px}.rtm-tip:before{border-color:rgba(245,222,175,0);border-top-color:#f5deaf;border-width:7px;margin-left:-7px}#rtmedia-custom-css-settings .form-table:last-child .rtm-field-wrap{width:100%}.rtm-field-wrap input[type=text]{max-width:140px !important}.theme-browser .theme:nth-child(2n+1){margin-right:4%}.rtmedia-settings-submit{margin-bottom:0 !important}}@media only screen and (min-width: 641px){.rtm-pro-feature-list li:nth-child(3n+1){clear:left}}@media screen and (min-width: 421px) and (max-width: 782px){.rtm-option-wrapper .form-table td{display:table-cell}.rtm-option-wrapper .form-table th{display:table-cell}}@media only screen and (max-width: 640px){.rtm-pro-feature-list li{width:50%}.rtm-pro-feature-list li:nth-child(2n+1){clear:left}.rtm-tabs{width:40px}.rtm-tabs li{width:40px}.rtm-tabs a{height:18px}.rtm-tabs a:hover{width:140px}.rtm-tabs a:hover span{display:block}.rtm-tabs span{display:none;padding:0 0 0 28px;position:absolute}.rtm-support-form label{width:100%;margin-bottom:5px}.rtm-support-form .bp-media-input,.rtm-support-form .bp-media-textarea{width:70%}.rtm-button-wrapper{padding-left:0}}@media screen and (max-width: 481px){.rtm-plugin-card.plugin-card .rtm-logo{display:inline-block;float:none}.rtm-theme-browser .rtm-themes .rtm-theme{margin:0 0 20px;width:100%}}@media screen and (max-width: 420px){.rtm-option-wrapper .form-table th{padding-bottom:15px;width:100%}#rtmedia-types .form-table th,#rtmedia-custom-css-settings .form-table th{width:100%}.rtm-pro-feature-list li{width:100%}.rtm-tip-top{right:-115px}}body.rtl .rtm-tabs a{padding:10px 32px 10px 4px}body.rtl .rtm-tabs .dashicons{right:10px}body.rtl .rtm-social-share .dashicons{left:10px;right:auto}body.rtl .rtm-option-wrapper .rtm-field-wrap{float:right}body.rtl .rtm-tip-top,body.rtl .rtm-tip{left:auto;right:24px}body.rtl .rtm-tip-top:after,body.rtl .rtm-tip-top:before,body.rtl .rtm-tip:after,body.rtl .rtm-tip:before{display:none}body.rtl .rtm-edit-td,body.rtl .rtm-delete-td{float:right;margin-left:0}body.rtl .rtm-edit-td{margin-right:-15px}body.rtl #rtmedia-membership span.float-right{float:left}body.rtl .theme-browser .theme{float:left;margin:0 4% 4% 0}.rtmedia-license .rtm-tabs span{padding:0}
app/assets/admin/css/sass/_layout.scss CHANGED
@@ -16,6 +16,20 @@ $container-min-height: 300px;
16
min-height: $container-min-height;
17
padding: 20px 30px;
18
vertical-align: top;
19
}
20
}
21
16
min-height: $container-min-height;
17
padding: 20px 30px;
18
vertical-align: top;
19
+
20
+ #debug {
21
+ tbody {
22
+ display: block;
23
+ height: 400px;
24
+ overflow-y: auto;
25
+ }
26
+
27
+ .rtm-download-debuginfo {
28
+ float: right;
29
+ margin-top: 14px;
30
+ }
31
+ }
32
+
33
}
34
}
35
app/assets/admin/js/admin.min.js CHANGED
@@ -2,4 +2,4 @@
2
* rtMedia JavaScript Library
3
* @package rtMedia
4
*/
5
- function rtmedia_addon_do_not_show(){var a={action:"rtmedia_addon_popup_not_show_again"};jQuery.post(rtmedia_admin_ajax,a,function(a){jQuery("#TB_window").remove(),jQuery("#TB_overlay").remove()})}"function"!=typeof Object.create&&(Object.create=function(a){function b(){}return b.prototype=a,new b}),function(a,b,c,d){var e={init:function(b,c){var d=this;d.elem=c,d.$elem=a(c),d.options=a.extend({},a.fn.rtTab.options,b),d.rtTabs()},rtTabs:function(){var c=this,d=c.options.activeTab;c.$elem.find("li:nth-child("+d+")").addClass("active"),c.rtTabContent(activeTabContent="yes"),c.rtClick();var e="false"!==c.$elem.attr("data-hash");if(e===!0){var f=b.location.hash;f&&c.$elem.find("li").find('a[href="'+f+'"]').trigger("click"),a(b).on("hashchange",function(){var a=b.location.hash;c.$elem.find("li").find('a[href="'+a+'"]').trigger("click")})}},rtClick:function(){var c=this,d=c.$elem.find("li"),e=d.find("a");e.on("click",function(e){e.preventDefault(),d.removeClass("active"),c.rtTabContent(),a(this).parent().addClass("active");var f=a(this).attr("href");a(f).removeClass("hide");var g="false"!==c.$elem.attr("data-hash");if(g===!0){var h=a(b).scrollTop();location.hash=a(this).attr("href"),a(b).scrollTop(h)}"function"==typeof c.options.onComplete&&c.options.onComplete.apply(c.elem,arguments)})},rtTabContent:function(b){var c=this,d=c.$elem.find("li"),e=d.find("a");e.each(function(){var c=a(this),d=c.attr("href");"yes"===b?c.parent().hasClass("active")||a(d).addClass("hide"):a(d).addClass("hide")})}};a.fn.rtTab=function(b){return this.each(function(){var c=Object.create(e);c.init(b,this),a.data(this,"rtTab",c)})},a.fn.rtTab.options={activeTab:1,onComplete:null}}(jQuery,window,document),jQuery(document).ready(function(a){var b=document.createElement("div");b.setAttribute("class","rtm-warning rtm-fly-warning hide"),a(".rtm-tabs").rtTab(),a('input[name^="rtmedia-options"]').on("change",function(){a(".rtm-save-settings-msg").remove(),0===a(".rtm-fly-warning").length&&(b.innerText=rtmedia_admin_strings.settings_changed,a(".rtm-button-container.top").prepend(b),a(".rtm-fly-warning").slideDown())}),a(".rtm-img-size-setting .form-table tr:nth-child(7) td:last-child").attr("colspan","3"),a(".rtm-field-wrap .switch input[type=checkbox]").each(function(){var b=a(this);b.parents("table").attr("data-depends")||(b.is(":checked")?(b.parents("table").next(".rtm-notice").slideDown(),b.parents("table").siblings("table").each(function(){a(this).attr("data-depends")&&a(this).slideDown()})):(b.parents("table").next(".rtm-notice").slideUp(),b.parents("table").siblings("table").each(function(){a(this).attr("data-depends")&&a(this).slideUp()}))),b.parents("tr").next("tr").attr("data-depends")&&(b.is(":checked")?b.parents("tr").next("tr").slideDown():b.parents("tr").next("tr").slideUp())}),a(".rtm-field-wrap .switch input[type=checkbox]").on("change",function(){var b=a(this);b.parents("table").attr("data-depends")||(b.parents("table").next(".rtm-notice").slideToggle(),b.parents("table").siblings("table").each(function(){a(this).attr("data-depends")&&a(this).slideToggle()})),b.parents("tr").next("tr").attr("data-depends")&&b.parents("tr").next("tr").slideToggle()});var c=Backbone.View.extend({el:a(".bp-media-admin"),events:{"click .rtm-theme":"render","click .rtm-close":"close","click .rtm-previous":"previousTheme","click .rtm-next":"nextTheme",keyup:"keyEvent"},initialize:function(){_.bindAll(this,"render","close","nextTheme","previousTheme","keyEvent"),this.keyEvent()},render:function(b){a(".rtm-theme").removeClass("rtm-modal-open");var c=a(b.currentTarget).addClass("rtm-modal-open").find(".rtm-theme-content").html();if(a(".rtm-theme-overlay")[0])a(".rtm-theme-overlay").show(),a(this.el).find(".rtm-theme-content-wrap").empty().append(c);else{var d={themeContent:c};a(this.el).append(rtMediaAdmin.templates.rtm_theme_overlay(d))}a(b.currentTarget).is(":first-child")?a(".rtm-previous").addClass("disabled"):a(b.currentTarget).is(":last-child")?a(".rtm-next").addClass("disabled"):a(".rtm-next, .rtm-previous").removeClass("disabled")},close:function(){a(".rtm-theme").removeClass("rtm-modal-open"),a(".rtm-theme-overlay").hide(),a(".rtm-next, .rtm-previous").removeClass("disabled")},nextTheme:function(b){return a(".rtm-next, .rtm-previous").removeClass("disabled"),a(".rtm-theme:last-child").hasClass("rtm-modal-open")&&a(b.currentTarget).addClass("disabled"),a(".rtm-modal-open").next().trigger("click"),!1},previousTheme:function(b){return a(".rtm-next, .rtm-previous").removeClass("disabled"),a(".rtm-theme:first-child").hasClass("rtm-modal-open")&&a(b.currentTarget).addClass("disabled"),a(".rtm-modal-open").prev().trigger("click"),!1},keyEvent:function(){a("body").on("keyup",function(b){return 39===b.keyCode?(a(".rtm-next, .rtm-previous").removeClass("disabled"),a(".rtm-theme:last-child").hasClass("rtm-modal-open")&&a(b.currentTarget).addClass("disabled"),a(".rtm-modal-open").next().trigger("click"),!1):37===b.keyCode?(a(".rtm-next, .rtm-previous").removeClass("disabled"),a(".rtm-theme:first-child").hasClass("rtm-modal-open")&&a(b.currentTarget).addClass("disabled"),a(".rtm-modal-open").prev().trigger("click"),!1):void(27===b.keyCode&&a(".rtm-close").trigger("click"))})}});new c});var rtMediaAdmin=new Object;rtMediaAdmin.templates={rtm_image:wp.template("rtm-image"),rtm_msg_div:wp.template("rtm-msg-div"),rtm_album_favourites_importer:wp.template("rtm-album-favourites-importer"),rtm_map_mapping_failure:wp.template("rtm-map-mapping-failure"),rtm_p_tag:wp.template("rtm-p-tag"),rtm_theme_overlay:wp.template("rtm-theme-overlay")},jQuery(document).ready(function(a){function b(a){return jQuery.post(ajaxurl,a,function(b){if(0!=b){var c=!1,d=Math.ceil((20*parseInt(b)+parseInt(a.values.finished))/parseInt(a.values.total)*100);d>100&&(d=100,c=!0),jQuery("#rtprogressbar>div").css("width",d+"%"),finished=jQuery("#rtprivacyinstaller span.finished").html(),jQuery("#rtprivacyinstaller span.finished").html(parseInt(finished)+a.count),c&&jQuery.post(ajaxurl,{action:"rtmedia_privacy_redirect"},function(a){window.location=settings_url})}else{var e={msg:"Row "+b+" failed."};jQuery("#map_progress_msgs").html(rtMediaAdmin.templates.rtm_map_mapping_failure(e))}})}function c(a){return jQuery.getJSON(ajaxurl,a,function(b){if(favorites=!1,b){var c=Math.ceil((5*parseInt(b.page)+parseInt(a.values.finished))/parseInt(a.values.total)*100);comments_total=jQuery("#bpmedia-bpalbumimporter .bp-album-comments span.total").html(),users_total=jQuery("#bpmedia-bpalbumimporter .bp-album-users span.total").html(),media_total=jQuery("#bpmedia-bpalbumimporter .bp-album-media span.total").html(),comments_finished=jQuery("#bpmedia-bpalbumimporter .bp-album-comments span.finished").html(),users_finished=jQuery("#bpmedia-bpalbumimporter .bp-album-users span.finished").html();var f=Math.ceil((parseInt(b.comments)+parseInt(comments_finished))/parseInt(comments_total)*100),g=Math.ceil(parseInt(b.users)/parseInt(users_total)*100);(c>100||100==c)&&(c=100,favorites=!0),jQuery(".bp-album-media #rtprogressbar>div").css("width",c+"%"),jQuery(".bp-album-comments #rtprogressbar>div").css("width",f+"%"),jQuery(".bp-album-users #rtprogressbar>div").css("width",g+"%"),media_finished=jQuery("#bpmedia-bpalbumimporter .bp-album-media span.finished").html(),parseInt(media_finished)<parseInt(media_total)&&jQuery("#bpmedia-bpalbumimporter .bp-album-media span.finished").html(parseInt(media_finished)+a.count),jQuery("#bpmedia-bpalbumimporter .bp-album-comments span.finished").html(parseInt(b.comments)+parseInt(comments_finished)),jQuery("#bpmedia-bpalbumimporter .bp-album-users span.finished").html(parseInt(b.users)),favorites&&(favorite_data={action:"rtmedia_rt_album_import_favorites",rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()},jQuery.post(ajaxurl,favorite_data,function(a){if(!a.hasOwnProperty(favorites)||0===a.favorites&&"0"===a.favorites)window.setTimeout(e,2e3);else{if(!jQuery(".bp-album-favorites").length){var b={users:a.users};jQuery(".bp-album-comments").after(rtMediaAdmin.templates.rtm_album_favourites_importer(b))}$favorites={},0!=a.offset||"0"!=a.offset?start=1*a.offset+1:start=1;for(var c=start;c<=a.users;c++)$count=1,c==a.users&&($count=parseInt(a.users%$count),0==$count&&($count=1)),newvals={action:"rtmedia_rt_album_import_step_favorites",offset:1*(c-1),redirect:c==a.users,rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()},$favorites[c]=newvals;var f=jQuery.Deferred();f.resolve(),jQuery.each($favorites,function(a,b){f=f.pipe(function(){return d(b)})})}},"json"))}else if(a.hasOwnProperty(page)){var h={msg:"Row "+b.page+" failed."};jQuery("#map_progress_msgs").html(rtMediaAdmin.templates.rtm_map_mapping_failure(h))}else{var h={msg:rtmedia_admin_strings.request_failed};jQuery("#map_progress_msgs").html(rtMediaAdmin.templates.rtm_map_mapping_failure(h))}})}function d(a){return jQuery.post(ajaxurl,a,function(a){redirect=!1,favorites_total=jQuery("#bpmedia-bpalbumimporter .bp-album-favorites span.total").html(),favorites_finished=jQuery("#bpmedia-bpalbumimporter .bp-album-favorites span.finished").html(),jQuery("#bpmedia-bpalbumimporter .bp-album-favorites span.finished").html(parseInt(favorites_finished)+1);var b=Math.ceil(parseInt(favorites_finished+1)/parseInt(favorites_total)*100);(b>100||100==b)&&(b=100,redirect=!0),jQuery(".bp-album-favorites #rtprogressbar>div").css("width",b+"%"),redirect&&window.setTimeout(e,2e3)})}function e(){window.location=document.URL}var f=document.createElement("div");f.className="support_form_loader",a(".rtm-save-settings-msg").length>0&&setTimeout(function(){a(".rtm-save-settings-msg").remove()},1e4),jQuery("#spread-the-word").on("click","#bp-media-add-linkback",function(){var a={action:"rtmedia_linkback",linkback:jQuery("#bp-media-add-linkback:checked").length};jQuery.post(rtmedia_admin_ajax,a,function(a){})}),jQuery("#bp-media-settings-boxes").on("change","#select-request",function(){if(jQuery(this).val()){jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(),jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(f);var a={action:"rtmedia_select_request",form:jQuery(this).val()};jQuery.post(ajaxurl,a,function(a){jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(),jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(a).fadeIn("slow")})}}),jQuery("#bp-media-settings-boxes").on("click","#cancel-request",function(){if(jQuery(this).val()){jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(),jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(f);var a={action:"rtmedia_cancel_request"};jQuery.post(ajaxurl,a,function(a){jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(),jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(a).fadeIn("slow")})}}),jQuery("#bp-media-settings-boxes").on("submit","#bp_media_settings_form, .rtmedia-settings-submit",function(a){var b=!0,c=new RegExp("^[0-9]+quot;);jQuery("input[name*='defaultSizes']").each(function(a){if(!c.test(jQuery(this).val()))return alert("Invalid value for "+jQuery(this).attr("name").replace("rtmedia-options[defaultSizes_","").replace("]","").replace(/_/g," ").replace(/(\b)([a-zA-Z] )/g,function(a){return a.toUpperCase()})),b=!1,!1});var d=jQuery('input[name^="rtmedia-options[general_videothumbs]"]');if(b&&d.length>0&&"undefined"!=typeof d){var e="",f=0;if(d.val()<=0?(e+=rtmedia_admin_strings.video_thumbnail_error,f=2):c.test(d.val())||(e+=rtmedia_admin_strings.video_thumbnail_invalid_value+" "+Math.round(d.val())+".",f=Math.round(d.val())),""!=e)return alert(e),d.val(f),b=!1,!1}var g=jQuery('input[name^="rtmedia-options[general_jpeg_image_quality]"]');if(b&&g.length>0&&"undefined"!=typeof g){var e="",h=0;if(g.val()<=0?(e+=rtmedia_admin_strings.jpeg_quality_negative_error,h=90):g.val()>100?(e+=rtmedia_admin_strings.jpeg_quality_percentage_error,h=100):c.test(g.val())||(e+=rtmedia_admin_strings.jpeg_quality_invalid_value+" "+Math.round(g.val())+".",h=Math.round(g.val())),""!=e)return alert(e),g.val(h),b=!1,!1}var i=jQuery('input[name^="rtmedia-options[general_perPageMedia]"]');if(b&&i.length>0&&"undefined"!=typeof i){var e="",j=0;if(i.val()<1?(e+=rtmedia_admin_strings.per_page_media_negative_value,j=10):jQuery.isNumeric(i.val())&&Math.floor(i.val())!=i.val()&&(e+=rtmedia_admin_strings.per_page_media_positive_error+" "+Math.round(i.val())+".",j=Math.round(i.val())),""!=e)return alert(e),i.val(j),b=!1,!1}b||a.preventDefault()}),jQuery(document).on("click","#bpm-services .encoding-try-now,#rtm-services .encoding-try-now",function(a){if(a.preventDefault(),confirm(rtmedia_admin_strings.are_you_sure)){var b={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(b));var b={action:"rtmedia_free_encoding_subscribe"};jQuery.getJSON(ajaxurl,b,function(a){if(void 0===a.error&&a.apikey){var b=window.location.href,c=window.location.hash;b=b.replace(c,""),document.location.href=b+"&apikey="+a.apikey+c}else{jQuery(".encoding-try-now").next().remove(),jQuery("#settings-error-encoding-error").remove();var d={id:"settings-error-encoding-error",msg:a.error,class:"error"};jQuery("#bp-media-settings-boxes").before(rtMediaAdmin.templates.rtm_msg_div(d))}})}}),jQuery(document).on("click","#api-key-submit",function(a){if(a.preventDefault(),0==jQuery(this).next("img").length){var b={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(b))}var b={action:"rtmedia_enter_api_key",apikey:jQuery("#new-api-key").val()};jQuery.getJSON(ajaxurl,b,function(a){if(void 0===a.error&&a.apikey){var b=window.location.href,c=window.location.hash;b=b.replace(c,""),b.toString().indexOf("&apikey="+a.apikey)==-1&&(b+="&apikey="+a.apikey),b.toString().indexOf("&update=true")==-1&&(b+="&update=true"),document.location.href=b+c}else{jQuery("#settings-error-api-key-error").remove();var d={id:"settings-error-api-key-error",msg:a.error,class:"error"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(d))}jQuery("#api-key-submit").next("img").remove()})}),jQuery(document).on("click","#disable-encoding",function(a){if(a.preventDefault(),confirm(rtmedia_admin_strings.disable_encoding)){var b={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(b));var b={action:"rtmedia_disable_encoding"};jQuery.post(ajaxurl,b,function(a){if(a){if(jQuery(".settings-error-encoding-disabled").remove(),jQuery("#settings-encoding-successfully-updated").length>0)jQuery("#settings-encoding-successfully-updated p").html(a);else{var b={id:"settings-encoding-successfully-updated",msg:a,class:"updated"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b))}jQuery("#rtmedia-encoding-usage").hide(),jQuery("#disable-encoding").next("img").remove(),jQuery("#disable-encoding").hide(),jQuery("#enable-encoding").show()}else{jQuery("#settings-error-encoding-disabled").remove();var b={id:"settings-error-encoding-disabled",msg:rtmedia_admin_strings.something_went_wrong,class:"error"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b))}})}}),jQuery(document).on("click","#enable-encoding",function(a){if(a.preventDefault(),confirm(rtmedia_admin_strings.enable_encoding)){var b={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(b));var b={action:"rtmedia_enable_encoding"};jQuery.post(ajaxurl,b,function(a){if(a){if(jQuery(".settings-error-encoding-enabled").remove(),jQuery("#settings-encoding-successfully-updated").length>0)jQuery("#settings-encoding-successfully-updated p").html(a);else{var b={id:"settings-encoding-successfully-updated",msg:a,class:"updated"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b))}jQuery("#enable-encoding").next("img").remove(),jQuery("#enable-encoding").hide(),jQuery("#disable-encoding").show()}else{jQuery("#settings-error-encoding-disabled").remove();var b={id:"settings-error-encoding-enabled",msg:rtmedia_admin_strings.something_went_wrong,class:"error"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b))}})}}),jQuery(".bp-media-encoding-table").on("click",".bpm-unsubscribe",function(a){a.preventDefault(),jQuery("#bpm-unsubscribe-dialog").dialog({dialogClass:"wp-dialog",modal:!0,buttons:{Unsubscribe:function(){jQuery(this).dialog("close");var a={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(".bpm-unsubscribe").after(rtMediaAdmin.templates.rtm_image(a));var a={action:"rtmedia_unsubscribe_encoding_service",note:jQuery("#bpm-unsubscribe-note").val(),plan:jQuery(".bpm-unsubscribe").attr("data-plan"),price:jQuery(".bpm-unsubscribe").attr("data-price")};jQuery.getJSON(ajaxurl,a,function(a){if(void 0===a.error&&a.updated){jQuery(".bpm-unsubscribe").next().remove(),jQuery(".bpm-unsubscribe").after(a.form),jQuery(".bpm-unsubscribe").remove(),jQuery("#settings-unsubscribed-successfully").remove(),jQuery("#settings-unsubscribe-error").remove();var b={id:"settings-unsubscribed-successfully",msg:a.updated,class:"updated"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b)),window.location.hash="#settings-unsubscribed-successfully"}else{jQuery(".bpm-unsubscribe").next().remove(),jQuery("#settings-unsubscribed-successfully").remove(),jQuery("#settings-unsubscribe-error").remove();var b={id:"settings-unsubscribe-error",msg:a.error,class:"error"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b)),window.location.hash="#settings-unsubscribe-error"}})}}})}),jQuery("#bpmedia-bpalbumimporter").on("change","#bp-album-import-accept",function(){jQuery(".bp-album-import-accept").toggleClass("i-accept"),jQuery(".bp-album-importer-wizard").slideToggle()}),jQuery("#rtprivacyinstall").click(function(a){a.preventDefault(),$progress_parent=jQuery("#rtprivacyinstaller"),$progress_parent.find(".rtprivacytype").each(function(){if($type=jQuery(this).attr("id"),"total"==$type){$values=[],jQuery(this).find("input").each(function(){$values[jQuery(this).attr("name")]=[jQuery(this).val()]}),$data={};for(var a=1;a<=$values.steps[0];a++)$count=20,a==$values.steps[0]&&($count=parseInt($values.laststep[0]),0==$count&&($count=20)),newvals={page:a,action:"rtmedia_privacy_install",count:$count,values:$values},$data[a]=newvals;var c=jQuery.Deferred();c.resolve(),jQuery.each($data,function(a,d){c=c.pipe(function(){return b(d)})})}})}),jQuery("#bpmedia-bpalbumimport-cleanup").click(function(a){a.preventDefault(),jQuery.post(ajaxurl,{action:"rtmedia_rt_album_cleanup",rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()},function(a){window.location=settings_rt_album_import_url})}),jQuery("#bpmedia-bpalbumimporter").on("click","#bpmedia-bpalbumimport",function(a){if(a.preventDefault(),!jQuery("#bp-album-import-accept").prop("checked")){jQuery("html, body").animate({scrollTop:jQuery("#bp-album-import-accept").offset().top},500);var b=jQuery(".bp-album-import-accept"),d=500,e="#FFEBE8",f=3;return void function a(){b.css("background-color","#EE0000"),setTimeout(function(){b.css("background-color",e),--f&&setTimeout(a,d)},d)}()}if(jQuery(this).prop("disabled",!0),wp_admin_url=ajaxurl.replace("admin-ajax.php",""),!jQuery(".bpm-ajax-loader").length){var g={src:rtmedia_admin_url+"images/wpspin_light.gif",class:"bpm-ajax-loader",norefresh:rtmedia_admin_strings.no_refresh};jQuery(this).after(rtMediaAdmin.templates.rtm_image(g))}$progress_parent=jQuery("#bpmedia-bpalbumimport"),$values=[],jQuery(this).parent().find("input").each(function(){$values[jQuery(this).attr("name")]=[jQuery(this).val()]}),0==$values.steps[0]&&($values.steps[0]=1),$data={};for(var f=1;f<=$values.steps[0];f++)$count=5,f==$values.steps[0]&&($count=parseInt($values.laststep[0]),0==$count&&($count=5)),newvals={page:f,action:"rtmedia_rt_album_import",count:$count,values:$values,rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()},$data[f]=newvals;var h=jQuery.Deferred();h.resolve(),jQuery.each($data,function(a,b){h=h.pipe(function(){return c(b)})})}),jQuery("#bp-media-settings-boxes").on("click",".interested",function(){jQuery(".interested-container").removeClass("hidden"),jQuery(".choice-free").attr("required","required")}),jQuery("#bp-media-settings-boxes").on("click",".not-interested",function(){jQuery(".interested-container").addClass("hidden"),jQuery(".choice-free").removeAttr("required")}),jQuery("#video-transcoding-main-container").on("click",".video-transcoding-survey",function(a){a.preventDefault();var b={action:"rtmedia_convert_videos_form",email:jQuery(".email").val(),url:jQuery(".url").val(),choice:jQuery('input[name="choice"]:checked').val(),interested:jQuery('input[name="interested"]:checked').val()};return jQuery.post(ajaxurl,b,function(a){var b={msg:a,strong:"yes"};jQuery("#video-transcoding-main-container").html(rtMediaAdmin.templates.rtm_p_tag(b))}),!1}),jQuery("#bpmedia-bpalbumimporter").on("click",".deactivate-bp-album",function(a){a.preventDefault(),$bpalbum=jQuery(this);var b={action:"rtmedia_rt_album_deactivate",rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()};jQuery.get(ajaxurl,b,function(a){if(a)location.reload();else{var b={msg:rtmedia_admin_strings.something_went_wrong};$bpalbum.parent().after(rtMediaAdmin.templates.rtm_p_tag(b))}})}),jQuery(".updated").on("click",".bpm-hide-encoding-notice",function(){var a={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(a));var a={action:"rtmedia_hide_encoding_notice"};jQuery.post(ajaxurl,a,function(a){a&&jQuery(".bpm-hide-encoding-notice").closest(".updated").remove()})}),jQuery("#rtmedia-bp-enable-activity").is(":checked")?jQuery(".rtmedia-bp-activity-setting").prop("readonly",!1):jQuery(".rtmedia-bp-activity-setting").prop("readonly",!0),jQuery("#rtmedia-bp-enable-activity").on("click",function(a){jQuery(this).is(":checked")?jQuery(".rtmedia-bp-activity-setting").prop("readonly",!1):jQuery(".rtmedia-bp-activity-setting").prop("readonly",!0)});var g="",h="";void 0!==rtmedia_on_label&&(g='data-on-label="'+rtmedia_on_label+'"'),void 0!==rtmedia_off_label&&(h='data-off-label="'+rtmedia_off_label+'"'),jQuery("#rtmedia-submit-request").click(function(){var b=jQuery("#name").val(),c=jQuery("#email").val(),d=jQuery("#website").val(),e=jQuery("#phone").val(),f=jQuery("#subject").val(),g=jQuery("#details").val(),h=jQuery('input[name="request_type"]').val(),i=jQuery('input[name="request_id"]').val(),j=jQuery('input[name="server_address"]').val(),k=jQuery('input[name="ip_address"]').val(),l=jQuery('input[name="server_type"]').val(),m=jQuery('input[name="user_agent"]').val(),n={name:b,email:c,website:d,phone:e,subject:f,details:g,request_id:i,request_type:"premium_support",server_address:j,ip_address:k,server_type:l,user_agent:m};if("bug_report"==h){var o=jQuery("#wp_admin_username").val();if(""==o)return alert(rtmedia_admin_support_strings.wp_admin_username_error),!1;var p=jQuery("#wp_admin_pwd").val();if(""==p)return alert(rtmedia_admin_support_strings.wp_admin_pwd_error),!1;var q=jQuery("#ssh_ftp_host").val();if(""==q)return alert(rtmedia_admin_support_strings.ssh_ftp_host_error),!1;var r=jQuery("#ssh_ftp_username").val();if(""==r)return alert(rtmedia_admin_support_strings.ssh_ftp_username_error),!1;var s=jQuery("#ssh_ftp_pwd").val();if(""==s)return alert(rtmedia_admin_support_strings.ssh_ftp_pwd_error),!1;n={name:b,email:c,website:d,phone:e,subject:f,details:g,request_id:i,request_type:"premium_support",server_address:j,ip_address:k,server_type:l,user_agent:m,wp_admin_username:o,wp_admin_pwd:p,ssh_ftp_host:q,ssh_ftp_username:r,ssh_ftp_pwd:s}}for(formdata in n)if(""==n[formdata]&&"phone"!=formdata)return alert("Please enter "+formdata.replace("_"," ")+" field."),!1;return data={action:"rtmedia_submit_request",form_data:n,support_wpnonce:jQuery("#support_wpnonce").val()},jQuery.post(ajaxurl,data,function(b){return b=b.trim(),"false"==b?(alert(rtmedia_admin_support_strings.all_fields_error),!1):(a("#rtmedia_service_contact_container").empty(),void a("#rtmedia_service_contact_container").append(b))}),!1}),jQuery("#cancel-request").click(function(){return!1}),jQuery(".rtm_enable_masonry_view input[type=checkbox]").is(":checked")?jQuery(".rtm_enable_masonry_view").parents(".metabox-holder").find(".rtmedia-info").show():jQuery(".rtm_enable_masonry_view").parents(".metabox-holder").find(".rtmedia-info").hide(),jQuery(".rtm_enable_masonry_view input[type=checkbox]").on("click",function(a){jQuery(this).is(":checked")?jQuery(".rtm_enable_masonry_view").parents(".metabox-holder").find(".rtmedia-info").show():jQuery(".rtm_enable_masonry_view").parents(".metabox-holder").find(".rtmedia-info").hide()}),jQuery("#rtm-masonry-change-thumbnail-info").click(function(a){jQuery("html, body").animate({scrollTop:0},"500","swing")})}),jQuery(window).load(function(){jQuery(".rtmedia-addon-thickbox").trigger("click")});
2
* rtMedia JavaScript Library
3
* @package rtMedia
4
*/
5
+ function rtmedia_addon_do_not_show(){var a={action:"rtmedia_addon_popup_not_show_again"};jQuery.post(rtmedia_admin_ajax,a,function(a){jQuery("#TB_window").remove(),jQuery("#TB_overlay").remove()})}"function"!=typeof Object.create&&(Object.create=function(a){function b(){}return b.prototype=a,new b}),function(a,b,c,d){var e={init:function(b,c){var d=this;d.elem=c,d.$elem=a(c),d.options=a.extend({},a.fn.rtTab.options,b),d.rtTabs()},rtTabs:function(){var c=this,d=c.options.activeTab;c.$elem.find("li:nth-child("+d+")").addClass("active"),c.rtTabContent(activeTabContent="yes"),c.rtClick();var e="false"!==c.$elem.attr("data-hash");if(e===!0){var f=b.location.hash;f&&c.$elem.find("li").find('a[href="'+f+'"]').trigger("click"),a(b).on("hashchange",function(){var a=b.location.hash;c.$elem.find("li").find('a[href="'+a+'"]').trigger("click")})}},rtClick:function(){var c=this,d=c.$elem.find("li"),e=d.find("a");e.on("click",function(e){e.preventDefault(),d.removeClass("active"),c.rtTabContent(),a(this).parent().addClass("active");var f=a(this).attr("href");a(f).removeClass("hide");var g="false"!==c.$elem.attr("data-hash");if(g===!0){var h=a(b).scrollTop();location.hash=a(this).attr("href"),a(b).scrollTop(h)}"function"==typeof c.options.onComplete&&c.options.onComplete.apply(c.elem,arguments)})},rtTabContent:function(b){var c=this,d=c.$elem.find("li"),e=d.find("a");e.each(function(){var c=a(this),d=c.attr("href");"yes"===b?c.parent().hasClass("active")||a(d).addClass("hide"):a(d).addClass("hide")})}};a.fn.rtTab=function(b){return this.each(function(){var c=Object.create(e);c.init(b,this),a.data(this,"rtTab",c)})},a.fn.rtTab.options={activeTab:1,onComplete:null}}(jQuery,window,document),jQuery(document).ready(function(a){var b=document.createElement("div");b.setAttribute("class","rtm-warning rtm-fly-warning hide"),a(".rtm-tabs").rtTab(),a('input[name^="rtmedia-options"]').on("change",function(){a(".rtm-save-settings-msg").remove(),0===a(".rtm-fly-warning").length&&(b.innerText=rtmedia_admin_strings.settings_changed,a(".rtm-button-container.top").prepend(b),a(".rtm-fly-warning").slideDown())}),a(".rtm-img-size-setting .form-table tr:nth-child(7) td:last-child").attr("colspan","3"),a(".rtm-field-wrap .switch input[type=checkbox]").each(function(){var b=a(this);b.parents("table").attr("data-depends")||(b.is(":checked")?(b.parents("table").next(".rtm-notice").slideDown(),b.parents("table").siblings("table").each(function(){a(this).attr("data-depends")&&a(this).slideDown()})):(b.parents("table").next(".rtm-notice").slideUp(),b.parents("table").siblings("table").each(function(){a(this).attr("data-depends")&&a(this).slideUp()}))),b.parents("tr").next("tr").attr("data-depends")&&(b.is(":checked")?b.parents("tr").next("tr").slideDown():b.parents("tr").next("tr").slideUp())}),a(".rtm-field-wrap .switch input[type=checkbox]").on("change",function(){var b=a(this);b.parents("table").attr("data-depends")||(b.parents("table").next(".rtm-notice").slideToggle(),b.parents("table").siblings("table").each(function(){a(this).attr("data-depends")&&a(this).slideToggle()})),b.parents("tr").next("tr").attr("data-depends")&&b.parents("tr").next("tr").slideToggle()});var c=Backbone.View.extend({el:a(".bp-media-admin"),events:{"click .rtm-theme":"render","click .rtm-close":"close","click .rtm-previous":"previousTheme","click .rtm-next":"nextTheme",keyup:"keyEvent"},initialize:function(){_.bindAll(this,"render","close","nextTheme","previousTheme","keyEvent"),this.keyEvent()},render:function(b){a(".rtm-theme").removeClass("rtm-modal-open");var c=a(b.currentTarget).addClass("rtm-modal-open").find(".rtm-theme-content").html();if(a(".rtm-theme-overlay")[0])a(".rtm-theme-overlay").show(),a(this.el).find(".rtm-theme-content-wrap").empty().append(c);else{var d={themeContent:c};a(this.el).append(rtMediaAdmin.templates.rtm_theme_overlay(d))}a(b.currentTarget).is(":first-child")?a(".rtm-previous").addClass("disabled"):a(b.currentTarget).is(":last-child")?a(".rtm-next").addClass("disabled"):a(".rtm-next, .rtm-previous").removeClass("disabled")},close:function(){a(".rtm-theme").removeClass("rtm-modal-open"),a(".rtm-theme-overlay").hide(),a(".rtm-next, .rtm-previous").removeClass("disabled")},nextTheme:function(b){return a(".rtm-next, .rtm-previous").removeClass("disabled"),a(".rtm-theme:last-child").hasClass("rtm-modal-open")&&a(b.currentTarget).addClass("disabled"),a(".rtm-modal-open").next().trigger("click"),!1},previousTheme:function(b){return a(".rtm-next, .rtm-previous").removeClass("disabled"),a(".rtm-theme:first-child").hasClass("rtm-modal-open")&&a(b.currentTarget).addClass("disabled"),a(".rtm-modal-open").prev().trigger("click"),!1},keyEvent:function(){a("body").on("keyup",function(b){return 39===b.keyCode?(a(".rtm-next, .rtm-previous").removeClass("disabled"),a(".rtm-theme:last-child").hasClass("rtm-modal-open")&&a(b.currentTarget).addClass("disabled"),a(".rtm-modal-open").next().trigger("click"),!1):37===b.keyCode?(a(".rtm-next, .rtm-previous").removeClass("disabled"),a(".rtm-theme:first-child").hasClass("rtm-modal-open")&&a(b.currentTarget).addClass("disabled"),a(".rtm-modal-open").prev().trigger("click"),!1):void(27===b.keyCode&&a(".rtm-close").trigger("click"))})}});new c});var rtMediaAdmin=new Object;rtMediaAdmin.templates={rtm_image:wp.template("rtm-image"),rtm_msg_div:wp.template("rtm-msg-div"),rtm_album_favourites_importer:wp.template("rtm-album-favourites-importer"),rtm_map_mapping_failure:wp.template("rtm-map-mapping-failure"),rtm_p_tag:wp.template("rtm-p-tag"),rtm_theme_overlay:wp.template("rtm-theme-overlay")},jQuery(document).ready(function(a){function b(a){return jQuery.post(ajaxurl,a,function(b){if(0!=b){var c=!1,d=Math.ceil((20*parseInt(b)+parseInt(a.values.finished))/parseInt(a.values.total)*100);d>100&&(d=100,c=!0),jQuery("#rtprogressbar>div").css("width",d+"%"),finished=jQuery("#rtprivacyinstaller span.finished").html(),jQuery("#rtprivacyinstaller span.finished").html(parseInt(finished)+a.count),c&&jQuery.post(ajaxurl,{action:"rtmedia_privacy_redirect"},function(a){window.location=settings_url})}else{var e={msg:"Row "+b+" failed."};jQuery("#map_progress_msgs").html(rtMediaAdmin.templates.rtm_map_mapping_failure(e))}})}function c(a){return jQuery.getJSON(ajaxurl,a,function(b){if(favorites=!1,b){var c=Math.ceil((5*parseInt(b.page)+parseInt(a.values.finished))/parseInt(a.values.total)*100);comments_total=jQuery("#bpmedia-bpalbumimporter .bp-album-comments span.total").html(),users_total=jQuery("#bpmedia-bpalbumimporter .bp-album-users span.total").html(),media_total=jQuery("#bpmedia-bpalbumimporter .bp-album-media span.total").html(),comments_finished=jQuery("#bpmedia-bpalbumimporter .bp-album-comments span.finished").html(),users_finished=jQuery("#bpmedia-bpalbumimporter .bp-album-users span.finished").html();var f=Math.ceil((parseInt(b.comments)+parseInt(comments_finished))/parseInt(comments_total)*100),g=Math.ceil(parseInt(b.users)/parseInt(users_total)*100);(c>100||100==c)&&(c=100,favorites=!0),jQuery(".bp-album-media #rtprogressbar>div").css("width",c+"%"),jQuery(".bp-album-comments #rtprogressbar>div").css("width",f+"%"),jQuery(".bp-album-users #rtprogressbar>div").css("width",g+"%"),media_finished=jQuery("#bpmedia-bpalbumimporter .bp-album-media span.finished").html(),parseInt(media_finished)<parseInt(media_total)&&jQuery("#bpmedia-bpalbumimporter .bp-album-media span.finished").html(parseInt(media_finished)+a.count),jQuery("#bpmedia-bpalbumimporter .bp-album-comments span.finished").html(parseInt(b.comments)+parseInt(comments_finished)),jQuery("#bpmedia-bpalbumimporter .bp-album-users span.finished").html(parseInt(b.users)),favorites&&(favorite_data={action:"rtmedia_rt_album_import_favorites",rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()},jQuery.post(ajaxurl,favorite_data,function(a){if(!a.hasOwnProperty(favorites)||0===a.favorites&&"0"===a.favorites)window.setTimeout(e,2e3);else{if(!jQuery(".bp-album-favorites").length){var b={users:a.users};jQuery(".bp-album-comments").after(rtMediaAdmin.templates.rtm_album_favourites_importer(b))}$favorites={},0!=a.offset||"0"!=a.offset?start=1*a.offset+1:start=1;for(var c=start;c<=a.users;c++)$count=1,c==a.users&&($count=parseInt(a.users%$count),0==$count&&($count=1)),newvals={action:"rtmedia_rt_album_import_step_favorites",offset:1*(c-1),redirect:c==a.users,rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()},$favorites[c]=newvals;var f=jQuery.Deferred();f.resolve(),jQuery.each($favorites,function(a,b){f=f.pipe(function(){return d(b)})})}},"json"))}else if(a.hasOwnProperty(page)){var h={msg:"Row "+b.page+" failed."};jQuery("#map_progress_msgs").html(rtMediaAdmin.templates.rtm_map_mapping_failure(h))}else{var h={msg:rtmedia_admin_strings.request_failed};jQuery("#map_progress_msgs").html(rtMediaAdmin.templates.rtm_map_mapping_failure(h))}})}function d(a){return jQuery.post(ajaxurl,a,function(a){redirect=!1,favorites_total=jQuery("#bpmedia-bpalbumimporter .bp-album-favorites span.total").html(),favorites_finished=jQuery("#bpmedia-bpalbumimporter .bp-album-favorites span.finished").html(),jQuery("#bpmedia-bpalbumimporter .bp-album-favorites span.finished").html(parseInt(favorites_finished)+1);var b=Math.ceil(parseInt(favorites_finished+1)/parseInt(favorites_total)*100);(b>100||100==b)&&(b=100,redirect=!0),jQuery(".bp-album-favorites #rtprogressbar>div").css("width",b+"%"),redirect&&window.setTimeout(e,2e3)})}function e(){window.location=document.URL}function f(a){k=a.target.files,g(a)}function g(a){a.stopPropagation(),a.preventDefault();var b=new FormData;jQuery.each(k,function(a,c){b.append(a,c)}),jQuery.ajax({url:rtmedia_fileupload_url,type:"POST",data:b,cache:!1,dataType:"json",processData:!1,contentType:!1,success:function(a){if("undefined"==typeof a.error){if(a.exceed_size_msg)return jQuery("#debuglog").val(""),alert(a.exceed_size_msg),!1;jQuery("#debuglog_temp_path").val(a.debug_attachmanet)}else jQuery("#debuglog").val(""),alert("ERRORS: "+a.error)}})}var h=document.createElement("div");h.className="support_form_loader",a(".rtm-save-settings-msg").length>0&&setTimeout(function(){a(".rtm-save-settings-msg").remove()},1e4),jQuery("#spread-the-word").on("click","#bp-media-add-linkback",function(){var a={action:"rtmedia_linkback",linkback:jQuery("#bp-media-add-linkback:checked").length};jQuery.post(rtmedia_admin_ajax,a,function(a){})}),jQuery("#bp-media-settings-boxes").on("change","#select-request",function(){if(jQuery(this).val()){jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(),jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(h);var a={action:"rtmedia_select_request",form:jQuery(this).val()};jQuery.post(ajaxurl,a,function(a){jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(),jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(a).fadeIn("slow")})}}),jQuery("#bp-media-settings-boxes").on("click","#cancel-request",function(){if(jQuery(this).val()){jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(),jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(h);var a={action:"rtmedia_cancel_request"};jQuery.post(ajaxurl,a,function(a){jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(),jQuery("#bp_media_settings_form .bp-media-metabox-holder").html(a).fadeIn("slow")})}}),jQuery("#bp-media-settings-boxes").on("submit","#bp_media_settings_form, .rtmedia-settings-submit",function(a){var b=!0,c=new RegExp("^[0-9]+quot;);jQuery("input[name*='defaultSizes']").each(function(a){if(!c.test(jQuery(this).val()))return alert("Invalid value for "+jQuery(this).attr("name").replace("rtmedia-options[defaultSizes_","").replace("]","").replace(/_/g," ").replace(/(\b)([a-zA-Z] )/g,function(a){return a.toUpperCase()})),b=!1,!1});var d=jQuery('input[name^="rtmedia-options[general_videothumbs]"]');if(b&&d.length>0&&"undefined"!=typeof d){var e="",f=0;if(d.val()<=0?(e+=rtmedia_admin_strings.video_thumbnail_error,f=2):c.test(d.val())||(e+=rtmedia_admin_strings.video_thumbnail_invalid_value+" "+Math.round(d.val())+".",f=Math.round(d.val())),""!=e)return alert(e),d.val(f),b=!1,!1}var g=jQuery('input[name^="rtmedia-options[general_jpeg_image_quality]"]');if(b&&g.length>0&&"undefined"!=typeof g){var e="",h=0;if(g.val()<=0?(e+=rtmedia_admin_strings.jpeg_quality_negative_error,h=90):g.val()>100?(e+=rtmedia_admin_strings.jpeg_quality_percentage_error,h=100):c.test(g.val())||(e+=rtmedia_admin_strings.jpeg_quality_invalid_value+" "+Math.round(g.val())+".",h=Math.round(g.val())),""!=e)return alert(e),g.val(h),b=!1,!1}var i=jQuery('input[name^="rtmedia-options[general_perPageMedia]"]');if(b&&i.length>0&&"undefined"!=typeof i){var e="",j=0;if(i.val()<1?(e+=rtmedia_admin_strings.per_page_media_negative_value,j=10):jQuery.isNumeric(i.val())&&Math.floor(i.val())!=i.val()&&(e+=rtmedia_admin_strings.per_page_media_positive_error+" "+Math.round(i.val())+".",j=Math.round(i.val())),""!=e)return alert(e),i.val(j),b=!1,!1}b||a.preventDefault()}),jQuery(document).on("click","#bpm-services .encoding-try-now,#rtm-services .encoding-try-now",function(a){if(a.preventDefault(),confirm(rtmedia_admin_strings.are_you_sure)){var b={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(b));var b={action:"rtmedia_free_encoding_subscribe"};jQuery.getJSON(ajaxurl,b,function(a){if(void 0===a.error&&a.apikey){var b=window.location.href,c=window.location.hash;b=b.replace(c,""),document.location.href=b+"&apikey="+a.apikey+c}else{jQuery(".encoding-try-now").next().remove(),jQuery("#settings-error-encoding-error").remove();var d={id:"settings-error-encoding-error",msg:a.error,class:"error"};jQuery("#bp-media-settings-boxes").before(rtMediaAdmin.templates.rtm_msg_div(d))}})}}),jQuery(document).on("click","#api-key-submit",function(a){if(a.preventDefault(),0==jQuery(this).next("img").length){var b={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(b))}var b={action:"rtmedia_enter_api_key",apikey:jQuery("#new-api-key").val()};jQuery.getJSON(ajaxurl,b,function(a){if(void 0===a.error&&a.apikey){var b=window.location.href,c=window.location.hash;b=b.replace(c,""),b.toString().indexOf("&apikey="+a.apikey)==-1&&(b+="&apikey="+a.apikey),b.toString().indexOf("&update=true")==-1&&(b+="&update=true"),document.location.href=b+c}else{jQuery("#settings-error-api-key-error").remove();var d={id:"settings-error-api-key-error",msg:a.error,class:"error"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(d))}jQuery("#api-key-submit").next("img").remove()})}),jQuery(document).on("click","#disable-encoding",function(a){if(a.preventDefault(),confirm(rtmedia_admin_strings.disable_encoding)){var b={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(b));var b={action:"rtmedia_disable_encoding"};jQuery.post(ajaxurl,b,function(a){if(a){if(jQuery(".settings-error-encoding-disabled").remove(),jQuery("#settings-encoding-successfully-updated").length>0)jQuery("#settings-encoding-successfully-updated p").html(a);else{var b={id:"settings-encoding-successfully-updated",msg:a,class:"updated"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b))}jQuery("#rtmedia-encoding-usage").hide(),jQuery("#disable-encoding").next("img").remove(),jQuery("#disable-encoding").hide(),jQuery("#enable-encoding").show()}else{jQuery("#settings-error-encoding-disabled").remove();var b={id:"settings-error-encoding-disabled",msg:rtmedia_admin_strings.something_went_wrong,class:"error"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b))}})}}),jQuery(document).on("click","#enable-encoding",function(a){if(a.preventDefault(),confirm(rtmedia_admin_strings.enable_encoding)){var b={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(b));var b={action:"rtmedia_enable_encoding"};jQuery.post(ajaxurl,b,function(a){if(a){if(jQuery(".settings-error-encoding-enabled").remove(),jQuery("#settings-encoding-successfully-updated").length>0)jQuery("#settings-encoding-successfully-updated p").html(a);else{var b={id:"settings-encoding-successfully-updated",msg:a,class:"updated"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b))}jQuery("#enable-encoding").next("img").remove(),jQuery("#enable-encoding").hide(),jQuery("#disable-encoding").show()}else{jQuery("#settings-error-encoding-disabled").remove();var b={id:"settings-error-encoding-enabled",msg:rtmedia_admin_strings.something_went_wrong,class:"error"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b))}})}}),jQuery(".bp-media-encoding-table").on("click",".bpm-unsubscribe",function(a){a.preventDefault(),jQuery("#bpm-unsubscribe-dialog").dialog({dialogClass:"wp-dialog",modal:!0,buttons:{Unsubscribe:function(){jQuery(this).dialog("close");var a={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(".bpm-unsubscribe").after(rtMediaAdmin.templates.rtm_image(a));var a={action:"rtmedia_unsubscribe_encoding_service",note:jQuery("#bpm-unsubscribe-note").val(),plan:jQuery(".bpm-unsubscribe").attr("data-plan"),price:jQuery(".bpm-unsubscribe").attr("data-price")};jQuery.getJSON(ajaxurl,a,function(a){if(void 0===a.error&&a.updated){jQuery(".bpm-unsubscribe").next().remove(),jQuery(".bpm-unsubscribe").after(a.form),jQuery(".bpm-unsubscribe").remove(),jQuery("#settings-unsubscribed-successfully").remove(),jQuery("#settings-unsubscribe-error").remove();var b={id:"settings-unsubscribed-successfully",msg:a.updated,class:"updated"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b)),window.location.hash="#settings-unsubscribed-successfully"}else{jQuery(".bpm-unsubscribe").next().remove(),jQuery("#settings-unsubscribed-successfully").remove(),jQuery("#settings-unsubscribe-error").remove();var b={id:"settings-unsubscribe-error",msg:a.error,class:"error"};jQuery("h2:first").after(rtMediaAdmin.templates.rtm_msg_div(b)),window.location.hash="#settings-unsubscribe-error"}})}}})}),jQuery("#bpmedia-bpalbumimporter").on("change","#bp-album-import-accept",function(){jQuery(".bp-album-import-accept").toggleClass("i-accept"),jQuery(".bp-album-importer-wizard").slideToggle()}),jQuery("#rtprivacyinstall").click(function(a){a.preventDefault(),$progress_parent=jQuery("#rtprivacyinstaller"),$progress_parent.find(".rtprivacytype").each(function(){if($type=jQuery(this).attr("id"),"total"==$type){$values=[],jQuery(this).find("input").each(function(){$values[jQuery(this).attr("name")]=[jQuery(this).val()]}),$data={};for(var a=1;a<=$values.steps[0];a++)$count=20,a==$values.steps[0]&&($count=parseInt($values.laststep[0]),0==$count&&($count=20)),newvals={page:a,action:"rtmedia_privacy_install",count:$count,values:$values},$data[a]=newvals;var c=jQuery.Deferred();c.resolve(),jQuery.each($data,function(a,d){c=c.pipe(function(){return b(d)})})}})}),jQuery("#bpmedia-bpalbumimport-cleanup").click(function(a){a.preventDefault(),jQuery.post(ajaxurl,{action:"rtmedia_rt_album_cleanup",rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()},function(a){window.location=settings_rt_album_import_url})}),jQuery("#bpmedia-bpalbumimporter").on("click","#bpmedia-bpalbumimport",function(a){if(a.preventDefault(),!jQuery("#bp-album-import-accept").prop("checked")){jQuery("html, body").animate({scrollTop:jQuery("#bp-album-import-accept").offset().top},500);var b=jQuery(".bp-album-import-accept"),d=500,e="#FFEBE8",f=3;return void function a(){b.css("background-color","#EE0000"),setTimeout(function(){b.css("background-color",e),--f&&setTimeout(a,d)},d)}()}if(jQuery(this).prop("disabled",!0),wp_admin_url=ajaxurl.replace("admin-ajax.php",""),!jQuery(".bpm-ajax-loader").length){var g={src:rtmedia_admin_url+"images/wpspin_light.gif",class:"bpm-ajax-loader",norefresh:rtmedia_admin_strings.no_refresh};jQuery(this).after(rtMediaAdmin.templates.rtm_image(g))}$progress_parent=jQuery("#bpmedia-bpalbumimport"),$values=[],jQuery(this).parent().find("input").each(function(){$values[jQuery(this).attr("name")]=[jQuery(this).val()]}),0==$values.steps[0]&&($values.steps[0]=1),$data={};for(var f=1;f<=$values.steps[0];f++)$count=5,f==$values.steps[0]&&($count=parseInt($values.laststep[0]),0==$count&&($count=5)),newvals={page:f,action:"rtmedia_rt_album_import",count:$count,values:$values,rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()},$data[f]=newvals;var h=jQuery.Deferred();h.resolve(),jQuery.each($data,function(a,b){h=h.pipe(function(){return c(b)})})}),jQuery("#bp-media-settings-boxes").on("click",".interested",function(){jQuery(".interested-container").removeClass("hidden"),jQuery(".choice-free").attr("required","required")}),jQuery("#bp-media-settings-boxes").on("click",".not-interested",function(){jQuery(".interested-container").addClass("hidden"),jQuery(".choice-free").removeAttr("required")}),jQuery("#video-transcoding-main-container").on("click",".video-transcoding-survey",function(a){a.preventDefault();var b={action:"rtmedia_convert_videos_form",email:jQuery(".email").val(),url:jQuery(".url").val(),choice:jQuery('input[name="choice"]:checked').val(),interested:jQuery('input[name="interested"]:checked').val()};return jQuery.post(ajaxurl,b,function(a){var b={msg:a,strong:"yes"};jQuery("#video-transcoding-main-container").html(rtMediaAdmin.templates.rtm_p_tag(b))}),!1}),jQuery("#bpmedia-bpalbumimporter").on("click",".deactivate-bp-album",function(a){a.preventDefault(),$bpalbum=jQuery(this);var b={action:"rtmedia_rt_album_deactivate",rtm_wpnonce:jQuery("#bpaimporter_wpnonce").val()};jQuery.get(ajaxurl,b,function(a){if(a)location.reload();else{var b={msg:rtmedia_admin_strings.something_went_wrong};$bpalbum.parent().after(rtMediaAdmin.templates.rtm_p_tag(b))}})}),jQuery(".updated").on("click",".bpm-hide-encoding-notice",function(){var a={src:rtmedia_admin_url+"images/wpspin_light.gif"};jQuery(this).after(rtMediaAdmin.templates.rtm_image(a));var a={action:"rtmedia_hide_encoding_notice"};jQuery.post(ajaxurl,a,function(a){a&&jQuery(".bpm-hide-encoding-notice").closest(".updated").remove()})}),jQuery("#rtmedia-bp-enable-activity").is(":checked")?jQuery(".rtmedia-bp-activity-setting").prop("readonly",!1):jQuery(".rtmedia-bp-activity-setting").prop("readonly",!0),jQuery("#rtmedia-bp-enable-activity").on("click",function(a){jQuery(this).is(":checked")?jQuery(".rtmedia-bp-activity-setting").prop("readonly",!1):jQuery(".rtmedia-bp-activity-setting").prop("readonly",!0)});var i="",j="";void 0!==rtmedia_on_label&&(i='data-on-label="'+rtmedia_on_label+'"'),void 0!==rtmedia_off_label&&(j='data-off-label="'+rtmedia_off_label+'"');var k;jQuery("input[type=file]").on("change",f),jQuery("#rtmedia-submit-request").click(function(){var b=jQuery("#name").val(),c=jQuery("#email").val(),d=jQuery("#website").val(),e=jQuery("#phone").val(),f=jQuery("#subject").val(),g=jQuery("#details").val(),h=jQuery('input[name="request_type"]').val(),i=jQuery('input[name="request_id"]').val(),j=jQuery('input[name="server_address"]').val(),k=jQuery('input[name="ip_address"]').val(),l=jQuery('input[name="server_type"]').val(),m=jQuery('input[name="user_agent"]').val(),n=jQuery('input[name="debuglog_temp_path"]').val(),o={name:b,email:c,website:d,phone:e,subject:f,details:g,request_id:i,request_type:"premium_support",server_address:j,ip_address:k,server_type:l,user_agent:m,debuglog_temp_path:n};if("bug_report"==h){var p=jQuery("#wp_admin_username").val();if(""==p)return alert(rtmedia_admin_support_strings.wp_admin_username_error),!1;var q=jQuery("#wp_admin_pwd").val();if(""==q)return alert(rtmedia_admin_support_strings.wp_admin_pwd_error),!1;var r=jQuery("#ssh_ftp_host").val();if(""==r)return alert(rtmedia_admin_support_strings.ssh_ftp_host_error),!1;var s=jQuery("#ssh_ftp_username").val();if(""==s)return alert(rtmedia_admin_support_strings.ssh_ftp_username_error),!1;var t=jQuery("#ssh_ftp_pwd").val();if(""==t)return alert(rtmedia_admin_support_strings.ssh_ftp_pwd_error),!1;o={name:b,email:c,website:d,phone:e,subject:f,details:g,request_id:i,request_type:"premium_support",server_address:j,ip_address:k,server_type:l,user_agent:m,wp_admin_username:p,wp_admin_pwd:q,ssh_ftp_host:r,ssh_ftp_username:s,ssh_ftp_pwd:t}}for(formdata in o)if(""==o[formdata]&&"phone"!=formdata)return alert("Please enter "+formdata.replace("_"," ")+" field."),!1;return data={action:"rtmedia_submit_request",form_data:o,support_wpnonce:jQuery("#support_wpnonce").val()},jQuery.post(ajaxurl,data,function(b){return b=b.trim(),"false"==b?(alert(rtmedia_admin_support_strings.all_fields_error),!1):(a("#rtmedia_service_contact_container").empty(),void a("#rtmedia_service_contact_container").append(b))}),!1}),jQuery("#cancel-request").click(function(){return!1}),jQuery(".rtm_enable_masonry_view input[type=checkbox]").is(":checked")?jQuery(".rtm_enable_masonry_view").parents(".metabox-holder").find(".rtmedia-info").show():jQuery(".rtm_enable_masonry_view").parents(".metabox-holder").find(".rtmedia-info").hide(),jQuery(".rtm_enable_masonry_view input[type=checkbox]").on("click",function(a){jQuery(this).is(":checked")?jQuery(".rtm_enable_masonry_view").parents(".metabox-holder").find(".rtmedia-info").show():jQuery(".rtm_enable_masonry_view").parents(".metabox-holder").find(".rtmedia-info").hide()}),jQuery("#rtm-masonry-change-thumbnail-info").click(function(a){jQuery("html, body").animate({scrollTop:0},"500","swing")})}),jQuery(window).load(function(){jQuery(".rtmedia-addon-thickbox").trigger("click")});
app/assets/admin/js/settings.js CHANGED
@@ -752,6 +752,15 @@ jQuery( document ).ready( function ( $ ) {
752
if ( rtmedia_off_label !== undefined )
753
offData = 'data-off-label="' + rtmedia_off_label + '"';
754
755
jQuery( '#rtmedia-submit-request' ).click( function () {
756
var flag = true;
757
var name = jQuery( '#name' ).val();
@@ -766,6 +775,7 @@ jQuery( document ).ready( function ( $ ) {
766
var ip_address = jQuery( 'input[name="ip_address"]' ).val();
767
var server_type = jQuery( 'input[name="server_type"]' ).val();
768
var user_agent = jQuery( 'input[name="user_agent"]' ).val();
769
var form_data = {
770
name: name,
771
email: email,
@@ -778,7 +788,8 @@ jQuery( document ).ready( function ( $ ) {
778
server_address: server_address,
779
ip_address: ip_address,
780
server_type: server_type,
781
- user_agent: user_agent
782
};
783
if ( request_type == "bug_report" ) {
784
var wp_admin_username = jQuery( '#wp_admin_username' ).val();
@@ -849,6 +860,44 @@ jQuery( document ).ready( function ( $ ) {
849
return false;
850
} );
851
852
jQuery( '#cancel-request' ).click( function () {
853
return false;
854
} );
752
if ( rtmedia_off_label !== undefined )
753
offData = 'data-off-label="' + rtmedia_off_label + '"';
754
755
+ var files;
756
+ /* upload file immediately after selecting it */
757
+ jQuery( 'input[type=file]' ).on( 'change', rtmedia_prepare_upload );
758
+
759
+ function rtmedia_prepare_upload( event ) {
760
+ files = event.target.files;
761
+ rtmedia_upload_files( event );
762
+ }
763
+
764
jQuery( '#rtmedia-submit-request' ).click( function () {
765
var flag = true;
766
var name = jQuery( '#name' ).val();
775
var ip_address = jQuery( 'input[name="ip_address"]' ).val();
776
var server_type = jQuery( 'input[name="server_type"]' ).val();
777
var user_agent = jQuery( 'input[name="user_agent"]' ).val();
778
+ var debuglog_temp_path = jQuery( 'input[name="debuglog_temp_path"]' ).val();
779
var form_data = {
780
name: name,
781
email: email,
788
server_address: server_address,
789
ip_address: ip_address,
790
server_type: server_type,
791
+ user_agent: user_agent,
792
+ debuglog_temp_path: debuglog_temp_path
793
};
794
if ( request_type == "bug_report" ) {
795
var wp_admin_username = jQuery( '#wp_admin_username' ).val();
860
return false;
861
} );
862
863
+ /* Upload file to temporary folder */
864
+ function rtmedia_upload_files( event ) {
865
+ event.stopPropagation(); // Stop stuff happening
866
+ event.preventDefault(); // Totally stop stuff happening
867
+
868
+ /* Create a formdata object and add the files */
869
+ var data = new FormData();
870
+ jQuery.each( files, function( key, value ) {
871
+ data.append( key, value );
872
+ });
873
+
874
+ jQuery.ajax ({
875
+ url: rtmedia_fileupload_url,
876
+ type: 'POST',
877
+ data: data,
878
+ cache: false,
879
+ dataType: 'json',
880
+ processData: false,
881
+ contentType: false,
882
+ success: function( data ) {
883
+
884
+ if( typeof data.error === 'undefined' ) {
885
+ if ( data.exceed_size_msg ) {
886
+ jQuery( '#debuglog' ).val( '' );
887
+ alert( data.exceed_size_msg );
888
+ return false;
889
+ }
890
+ /* if file uploaded successfully, then set that path into a hidden field. */
891
+ jQuery('#debuglog_temp_path').val( data.debug_attachmanet );
892
+ } else {
893
+ jQuery( '#debuglog' ).val( '' );
894
+ /* Show error in alert box. */
895
+ alert( 'ERRORS: ' + data.error );
896
+ }
897
+ }
898
+ });
899
+ }
900
+
901
jQuery( '#cancel-request' ).click( function () {
902
return false;
903
} );
app/assets/css/rtmedia.css CHANGED
@@ -132,6 +132,14 @@ body.media.buddypress {
132
overflow-y: auto;
133
}
134
135
.rtmedia-container {
136
box-sizing: border-box;
137
}
@@ -476,6 +484,15 @@ table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete span {
476
display: none;
477
}
478
479
.rtm-tabs.rtm-tabs {
480
border-bottom: 1px solid #EEEEEE;
481
list-style: none;
@@ -1012,6 +1029,13 @@ img.mfp-img {
1012
padding-right: 6px;
1013
}
1014
}
1015
.mfp-content .rtm-lightbox-container {
1016
background: #000000;
1017
margin: 0 auto;
@@ -1104,6 +1128,10 @@ img.mfp-img {
1104
padding: 0 4px 0 0;
1105
}
1106
1107
#buddypress #rtm-media-options-list .rtm-options .button {
1108
background: transparent;
1109
border: 0 none;
@@ -1251,6 +1279,7 @@ img.mfp-img {
1251
.rtm-time-privacy .dashicons {
1252
font-size: 14px;
1253
line-height: 1.5;
1254
}
1255
1256
.rtmedia-actions-before-comments > span {
@@ -1523,6 +1552,32 @@ img.mfp-img {
1523
margin-bottom: 10px;
1524
}
1525
1526
.rtmedia-album-edit .rtm-checkbox-wrap {
1527
background: rgba(255, 255, 255, 0.9);
1528
height: 30px;
132
overflow-y: auto;
133
}
134
135
+ #buddypress input[type=submit]:focus {
136
+ background: #ededed;
137
+ border: 1px solid #bbb;
138
+ color: #555;
139
+ outline: 0;
140
+ text-decoration: none;
141
+ }
142
+
143
.rtmedia-container {
144
box-sizing: border-box;
145
}
484
display: none;
485
}
486
487
+ .rtmedia-list-item .rtmedia-album-media-count {
488
+ position: absolute;
489
+ top: 0;
490
+ right: 0;
491
+ background-color: black;
492
+ color: white;
493
+ padding: 0 5px;
494
+ }
495
+
496
.rtm-tabs.rtm-tabs {
497
border-bottom: 1px solid #EEEEEE;
498
list-style: none;
1029
padding-right: 6px;
1030
}
1031
}
1032
+ /*
1033
+ * popup autocomplete
1034
+ */
1035
+ #atwho-container #atwho-ground-comment_content .atwho-view {
1036
+ z-index: 2147483647;
1037
+ }
1038
+
1039
.mfp-content .rtm-lightbox-container {
1040
background: #000000;
1041
margin: 0 auto;
1128
padding: 0 4px 0 0;
1129
}
1130
1131
+ #buddypress #rtm-media-options-list .rtm-options form button {
1132
+ font-size: small;
1133
+ }
1134
+
1135
#buddypress #rtm-media-options-list .rtm-options .button {
1136
background: transparent;
1137
border: 0 none;
1279
.rtm-time-privacy .dashicons {
1280
font-size: 14px;
1281
line-height: 1.5;
1282
+ margin-top: -2px;
1283
}
1284
1285
.rtmedia-actions-before-comments > span {
1552
margin-bottom: 10px;
1553
}
1554
1555
+ .previous-pagination {
1556
+ float: left;
1557
+ margin-top: 10px;
1558
+ }
1559
+
1560
+ .next-pagination {
1561
+ float: right;
1562
+ margin-top: 10px;
1563
+ }
1564
+
1565
+ @media screen and (max-width: 500px) {
1566
+ #activity-stream li .media-type-video {
1567
+ width: 100%;
1568
+ }
1569
+ #activity-stream li .media-type-video .mejs-video {
1570
+ max-width: 100%;
1571
+ min-width: 100%;
1572
+ }
1573
+ }
1574
+ #rtmedia_show_all_comment {
1575
+ cursor: pointer;
1576
+ }
1577
+ #rtmedia_show_all_comment:hover {
1578
+ text-decoration: underline;
1579
+ }
1580
+
1581
.rtmedia-album-edit .rtm-checkbox-wrap {
1582
background: rgba(255, 255, 255, 0.9);
1583
height: 30px;
app/assets/css/rtmedia.min.css CHANGED
@@ -1 +1 @@
1
- .alignleft{float:left}.alignright{float:right}.aligncenter{display:block;margin-left:auto;margin-right:auto;text-align:center}.clear-both{clear:both}.clear-none{clear:none}.clear-left{clear:left}.clear-right{clear:right}.rtm-inline-block{display:inline-block}.rtm-text-left{text-align:left}.rtm-text-right{text-align:right}.rtm-text-center{text-align:center}.rtm-border-0{border:0 !important}.hide{display:none}.rtmedia-success,.rtmedia-warning{margin:10px 0;padding:8px 14px 8px 14px;text-shadow:0 1px 0 rgba(255,255,255,0.5);border-bottom:1px solid #e7e7e7;cursor:pointer}.rtmedia-success{background-color:#dff0d8;color:#468847}.rtmedia-warning{background-color:#F0D8DD;color:#884646}.clearfix:after{content:"";display:table;clear:both}#buddypress form#whats-new-form textarea{box-sizing:border-box;min-height:70px;width:100%}#buddypress #whats-new-options{height:auto !important;overflow:hidden}#buddypress form#whats-new-form p.activity-greeting{line-height:1}#buddypress form#whats-new-form #whats-new-options select{border:1px solid #ccc;font-size:13px;margin-top:0;padding:3px 2px}#whats-new-submit #aw-whats-new-submit{font-size:12px;line-height:18px;padding:4px 6px}#whats-new-post-in-box{float:left;font-size:13px}#buddypress form#whats-new-form #whats-new-submit{margin-top:0}#whats-new-textarea{margin-bottom:10px}body.media.buddypress{overflow-y:auto}.rtmedia-container{box-sizing:border-box}.rtmedia-container *,.rtmedia-container *:before,.rtmedia-container *:after{box-sizing:inherit}.rtmedia-list.rtmedia-list{list-style:none;margin:0;padding:0}.rtmedia-list-item>a{border:0;display:inline-block;text-decoration:none}.rtmedia-list-item>a:focus{outline:0}.rtmedia-list-item>a+p{display:none}.rtmedia-list-item>a .rtmedia-item-thumbnail img{display:inline-block}#rtmedia-uploader-form .rtm-plupload-list,#rtmedia_uploader_filelist{list-style:none;margin-left:-4px;margin-right:-4px;padding-left:0;padding-top:10px}#rtmedia-uploader-form .rtm-plupload-list li,#rtmedia_uploader_filelist li{background:#eee;float:left;margin:4px;max-width:110px;padding:5px;position:relative}#rtmedia-uploader-form .rtm-plupload-list li.upload-error,#rtmedia_uploader_filelist li.upload-error{border:1px solid red}#rtmedia-uploader-form .rtm-plupload-list img,#rtmedia_uploader_filelist img{max-width:100%}#rtmedia-uploader-form .rtm-plupload-list canvas,#rtmedia_uploader_filelist canvas{display:block;max-width:100%}#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-title,#rtmedia_uploader_filelist .rtm-upload-edit-title{font-size:12px}#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-desc,#rtmedia_uploader_filelist .rtm-upload-edit-desc{font-size:12px;display:block}#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-title-wrapper label,#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-desc-wrapper label,#rtmedia_uploader_filelist .rtm-upload-edit-title-wrapper label,#rtmedia_uploader_filelist .rtm-upload-edit-desc-wrapper label{display:block}#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-title-wrapper input.rtm-upload-edit-title,#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-desc-wrapper input.rtm-upload-edit-title,#rtmedia_uploader_filelist .rtm-upload-edit-title-wrapper input.rtm-upload-edit-title,#rtmedia_uploader_filelist .rtm-upload-edit-desc-wrapper input.rtm-upload-edit-title{min-width:100%;margin-top:1px}.rtm-plupload-list:empty{display:none}.rtmedia-uploader-div,.rtmedia-uploader{clear:both}button#rtmedia-add-media-button-post-update{padding:3px 6px}button#rtmedia-add-media-button-post-update .dashicons{font-size:18px;line-height:20px}.plupload_file_name{font-size:11px;font-weight:bold;line-height:1.2;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.plupload_file_size{color:#666;font-size:10px}.plupload_file_action{background:#eee;position:absolute;height:18px;right:4px;top:0;width:18px;z-index:10}.plupload_file_action .dashicons{color:#DD3D36;cursor:pointer;font-size:16px;height:18px;padding:2px 1px;width:18px}.plupload_file_status{height:18px;overflow:hidden;position:relative}.plupload_file_progress{background:#7AD03A;height:4px;position:absolute;top:0}.rtm-form .rtm-field-wrap{margin-bottom:20px}.rtmedia_next_prev{padding:0 10px}.rtm-page-number{float:left}.rtm-page-number .rtm-label{line-height:30px}.rtm-page-number .rtm-label,.rtm-page-number .rtm-go-to-num,.rtm-page-number .rtmedia-page-link{float:left}.rtm-pagination{background:transparent;border:none;color:#888;font-size:small;margin:0;position:relative;display:block;float:left;width:100%;padding:10px 0}.rtm-pagination .rtm-paginate{float:right;font-size:15px}.rtm-pagination .rtm-paginate a,.rtm-pagination .rtm-paginate span{display:inline-block;line-height:1;margin:0 2px;padding:8px;text-decoration:none}.rtm-pagination .rtm-paginate a.rtmedia-page-link{padding:8px}.rtm-pagination .dashicons{font-size:14px;height:auto;line-height:1.2;margin:0;padding:0;width:auto}#rtmedia_go_to_num{font-size:16px;margin:0 5px;padding:4px 5px;width:80px}.rtmedia-upload-not-allowed{background-color:#fcf8e3;border-bottom:1px solid #EEE;color:#c09853;margin-bottom:20px;padding:10px 15px}.plupload_file_name{position:relative}.plupload_file_name .dashicons{background:#eee;color:#DD3D36;cursor:pointer;font-size:14px;height:auto;padding:0 2px 0 5px;position:absolute;right:0;top:0;width:auto}.plupload_file_name .dashicons-yes{color:#7AD03A}.rtmedia-gallery-item-actions{background-color:rgba(0,0,0,0.6);opacity:0;position:absolute;text-align:center;-webkit-transition:all ease-in-out 0.4s;transition:all ease-in-out 0.4s;width:100%;z-index:9}.rtmedia-gallery-item-actions a{border:0;box-shadow:0 0 0;color:#fff;display:inline-block;font-size:12px;outline:none;padding:4px;text-align:left;text-decoration:none;text-transform:uppercase}.rtmedia-gallery-item-actions .dashicons{font-size:17px;margin-right:2px;position:relative;top:1px}.rtmedia-gallery-item-actions .dashicons-trash{font-size:15px}.rtm-pro-allow-action .rtmedia-list-item:hover .rtmedia-gallery-item-actions{opacity:1}.rtm-pro-allow-action .rtmedia-list-item:hover .rtmedia-bulk-edit-item-wrap+.rtmedia-gallery-item-actions{opacity:0}.rtmedia-footer-link{clear:both;overflow:hidden;padding:16px 0;position:relative;text-align:center}.rtmedia-text-link-decoration,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit a,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit span,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete a,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete span,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title a,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title span{text-decoration:none}.rtmedia-text-link-decoration:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit a:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit span:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete a:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete span:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title a:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title span:hover{text-decoration:underline}.rtmedia-container .rtmedia-edit-list-media-table{max-height:300px;overflow-y:auto}.rtmedia-container .rtmedia-edit-list-media-table thead tr{background-color:#50A1D7}.rtmedia-container .rtmedia-edit-list-media-table thead th{text-align:center;color:#FFF}.rtmedia-container .rtmedia-edit-list-media-table tbody tr:nth-child(odd){background:#FFF}.rtmedia-container .rtmedia-edit-list-media-table tbody tr:nth-child(even){background:#DCDCDC}table.rtmedia-edit-media-list tr{line-height:30px}table.rtmedia-edit-media-list tr th{color:#333;padding:4px 10px;line-height:20px}table.rtmedia-edit-media-list tr .rtm-edit-media-list-heading{width:44%}table.rtmedia-edit-media-list tr .rtm-edit-media-list-title-heading{width:56%}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title{padding:4px;font-size:14px;line-height:24px}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title a{text-decoration:none;color:#333}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit{text-align:center}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit a{color:#333;font-size:13px}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete{text-align:center}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete span{color:#FF0000;cursor:pointer;font-size:13px}.rtm-hide{display:none}.rtm-tabs.rtm-tabs{border-bottom:1px solid #eee;list-style:none;margin:0 0 20px;padding:0}.rtm-tabs li{border:1px solid #eee;border-bottom:0;float:left;margin:0 5px;padding:0}.rtm-tabs a{border:0;display:block;padding:5px 15px;text-decoration:none}.rtm-tabs a:focus{background:transparent;box-shadow:0 0 0}.rtm-tabs .active{position:relative}.rtm-tabs .active:after{background:#fff;bottom:-1px;content:' ';height:1px;left:0;position:absolute;width:100%}.rtm-tabs .dashicons{font-size:16px;height:auto;line-height:20px;margin-right:8px;width:auto}.rtmedia-edit-media-tabs .rtm-tabs a{border-bottom:0 none}.mfp-bg{top:0;left:0;width:100%;height:100%;z-index:104211;overflow:hidden;position:fixed;background:rgba(0,0,0,0.9)}.mfp-wrap{top:0;left:0;width:100%;height:100%;z-index:104311;position:fixed;outline:none !important;-webkit-backface-visibility:hidden}.mfp-container{text-align:center;position:absolute;width:100%;max-width:84%;margin:0 auto;right:0;height:100%;left:0;top:0;padding:0 8px;box-sizing:border-box}.mfp-container:before{content:' ';display:inline-block;height:100%;vertical-align:middle}.mfp-align-top .mfp-container:before{display:none}.mfp-content{position:relative;display:inline-block;vertical-align:middle;margin:0 auto;text-align:left;z-index:1045}.mfp-inline-holder .mfp-content,.mfp-ajax-holder .mfp-content{width:100%;cursor:auto}.mfp-ajax-cur{cursor:progress}.mfp-zoom-out-cur,.mfp-zoom-out-cur .mfp-image-holder .mfp-close{cursor:zoom-out}.mfp-zoom{cursor:pointer;cursor:zoom-in}.mfp-auto-cursor .mfp-content{cursor:auto}.mfp-close,.mfp-arrow,.mfp-preloader,.mfp-counter{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.mfp-loading.mfp-figure{display:none}.mfp-hide{display:none !important}.mfp-s-ready .mfp-preloader{display:none}.mfp-s-error .mfp-content{display:none}button.mfp-close,button.mfp-arrow{overflow:visible;cursor:pointer;background:transparent;border:0;-webkit-appearance:none;display:block;outline:none;padding:0;z-index:1046;box-shadow:none}button::-moz-focus-inner{padding:0;border:0}.mfp-close{background:#fff;color:#999;cursor:pointer;font-size:24px;font-style:normal;height:30px;line-height:30px;padding:0;position:absolute;right:1px;text-align:center;text-decoration:none;text-indent:2px;top:0;width:32px;z-index:12}.mfp-close:hover,.mfp-close:focus{opacity:1;filter:alpha(opacity=100)}.mfp-close:active{top:1px}.mfp-image-holder .mfp-close,.mfp-iframe-holder .mfp-close{color:#FFF;right:-6px;text-align:right;padding-right:6px;width:100%}.mfp-counter{position:absolute;top:0;right:0;color:#CCC;font-size:12px;line-height:18px;white-space:nowrap}.mfp-arrow{cursor:pointer;position:absolute;opacity:0.65;filter:alpha(opacity=65);margin:0;top:50%;margin-top:-55px;padding:0;width:90px;height:110px;-webkit-tap-highlight-color:transparent;opacity:0;z-index:10;-webkit-transition:all 300ms ease-out;transition:all 300ms ease-out}.rtm-single-media:hover .mfp-arrow{opacity:1}@media (max-device-width: 640px){.mfp-arrow{display:none}.rtm-single-media:hover .mfp-arrow{display:none}}.mfp-arrow:active{margin-top:-54px}.mfp-arrow:hover,.mfp-arrow:focus{opacity:1;filter:alpha(opacity=100)}.mfp-arrow:before,.mfp-arrow:after,.mfp-arrow .mfp-b,.mfp-arrow .mfp-a{content:'';display:block;width:0;height:0;position:absolute;left:0;top:0;margin-top:35px;margin-left:35px;border:medium inset transparent}.mfp-arrow:after,.mfp-arrow .mfp-a{border-top-width:13px;border-bottom-width:13px;top:8px}.mfp-arrow:before,.mfp-arrow .mfp-b{border-top-width:21px;border-bottom-width:21px;opacity:0.7}.mfp-arrow-left{left:0}.mfp-arrow-left:after,.mfp-arrow-left .mfp-a{border-right:17px solid #FFF;margin-left:31px}.mfp-arrow-left:before,.mfp-arrow-left .mfp-b{margin-left:25px;border-right:27px solid #3F3F3F}.mfp-arrow-right{right:0}.mfp-arrow-right:after,.mfp-arrow-right .mfp-a{border-left:17px solid #FFF;margin-left:39px}.mfp-arrow-right:before,.mfp-arrow-right .mfp-b{border-left:27px solid #3F3F3F}.mfp-iframe-holder{padding-top:40px;padding-bottom:40px}.mfp-iframe-holder .mfp-content{line-height:0;width:100%;max-width:900px}.mfp-iframe-holder .mfp-close{top:-40px}.mfp-iframe-scaler{width:100%;height:0;overflow:hidden;padding-top:56.25%}.mfp-iframe-scaler iframe{position:absolute;display:block;top:0;left:0;width:100%;height:100%;box-shadow:0 0 8px rgba(0,0,0,0.6);background:#000}img.mfp-img{width:auto;max-width:100%;height:auto;display:block;line-height:0;box-sizing:border-box;padding:40px 0 40px;margin:0 auto}.mfp-figure{line-height:0}.mfp-figure:after{content:'';position:absolute;left:0;top:40px;bottom:40px;display:block;right:0;width:auto;height:auto;z-index:-1;box-shadow:0 0 8px rgba(0,0,0,0.6);background:#444}.mfp-figure small{color:#BDBDBD;display:block;font-size:12px;line-height:14px}.mfp-figure figure{margin:0}.mfp-bottom-bar{margin-top:-36px;position:absolute;top:100%;left:0;width:100%;cursor:auto}.mfp-title{text-align:left;line-height:18px;color:#F3F3F3;word-wrap:break-word;padding-right:36px}.mfp-image-holder .mfp-content{max-width:100%}.mfp-gallery .mfp-image-holder .mfp-figure{cursor:pointer}.mfp-preloader{position:absolute;top:50%;left:0;right:0;margin-top:-36px;z-index:1044;font-size:0;width:36px;height:36px;margin-left:auto;margin-right:auto}.mfp-preloader:before{content:'Loading…';position:absolute;width:30px;height:30px}.mfp-preloader:not(:required):before{content:'';border-radius:50%;border:3px solid rgba(255,255,255,0.27);border-top-color:rgba(255,255,255,0.9);animation:spinner .6s linear infinite;-webkit-animation:spinner .6s linear infinite}@keyframes spinner{to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@-webkit-keyframes spinner{to{-webkit-transform:rotate(360deg)}}@media screen and (max-width: 800px) and (orientation: landscape), screen and (max-height: 300px){.mfp-img-mobile .mfp-image-holder{padding-left:0;padding-right:0}.mfp-img-mobile img.mfp-img{padding:0}.mfp-img-mobile .mfp-figure:after{top:0;bottom:0}.mfp-img-mobile .mfp-figure small{display:inline;margin-left:5px}.mfp-img-mobile .mfp-bottom-bar{background:rgba(0,0,0,0.6);bottom:0;margin:0;top:auto;padding:3px 5px;position:fixed;box-sizing:border-box}.mfp-img-mobile .mfp-bottom-bar:empty{padding:0}.mfp-img-mobile .mfp-counter{right:5px;top:3px}.mfp-img-mobile .mfp-close{top:0;right:0;width:35px;height:35px;line-height:35px;background:rgba(0,0,0,0.6);position:fixed;text-align:center;padding:0}}@media all and (max-width: 900px){.mfp-arrow{-webkit-transform:scale(0.75);-ms-transform:scale(0.75);transform:scale(0.75)}.mfp-arrow-left{-webkit-transform-origin:0;-ms-transform-origin:0;transform-origin:0}.mfp-arrow-right{-webkit-transform-origin:100%;-ms-transform-origin:100%;transform-origin:100%}.mfp-container{padding-left:6px;padding-right:6px}}.mfp-content .rtm-lightbox-container{background:#000;margin:0 auto;position:relative}.mfp-content .rtm-single-meta{background:#fff;overflow:hidden;padding:20px 20px 110px;position:relative;vertical-align:top}.rtm-single-media{overflow:hidden;position:relative;text-align:center;vertical-align:middle}.rtm-single-media .mejs-container{margin:0 auto;max-width:inherit}.rtm-single-media .rtmedia-message-container{position:absolute;top:45%;left:0;right:0;margin-left:auto;margin-right:auto}@media (max-device-width: 640px){.rtm-single-media .rtmedia-message-container{top:25%}}.rtm-ltb-action-container{background-color:rgba(0,0,0,0.6);bottom:0;color:#fff;line-height:38px;opacity:0;padding:0 10px;position:absolute;width:100%;-webkit-transition:all 300ms ease-out;transition:all 300ms ease-out}.rtm-single-media:hover .rtm-ltb-action-container{opacity:1}@media (max-device-width: 640px){.rtm-ltb-action-container{clear:both;position:relative;opacity:1}.rtm-single-media:hover .rtm-ltb-action-container{opacity:1}}#buddypress #rtmedia-single-media-container.rtmedia-single-media .button{background:transparent;border:0 none;border-radius:2px;color:rgba(255,255,255,0.5);display:block;font-family:inherit;font-weight:normal;line-height:24px;margin:0;padding:0 6px;text-shadow:0 0 0;text-transform:none}#buddypress #rtmedia-single-media-container.rtmedia-single-media .button:hover{background:rgba(255,255,255,0.2);color:rgba(255,255,255,0.8)}#buddypress #rtmedia-single-media-container.rtmedia-single-media .rtm-options .button{color:#333;margin:0 auto;padding:0 4px 0 0}#buddypress #rtm-media-options-list .rtm-options .button{background:transparent;border:0 none;border-radius:2px;color:rgba(255,255,255,0.5);float:left;font-family:inherit;font-weight:normal;line-height:24px;padding:0 6px;text-shadow:0 0 0;text-transform:none}#buddypress #rtm-media-options-list .rtm-options .rtmedia-delete-favlist{color:#fff;padding:0}.rtm-options.rtm-options{background:#666;color:#fff;display:none;font-size:14px;list-style:none;margin:0;padding:8px 10px;position:absolute;left:0;top:38px;width:190px;z-index:10}.rtm-options li{margin:0;overflow:hidden;padding:2px 0}.rtm-media-options .rtm-options:after{bottom:100%;left:20px;border:solid transparent;content:' ';height:0;width:0;position:absolute;pointer-events:none;border-color:rgba(255,255,255,0);border-bottom-color:#666;border-width:6px;margin-left:-6px}.mfp-content .rtm-options{background:#fff;color:#333;bottom:38px;right:0;left:auto;top:auto}.mfp-content .rtm-options:after{top:100%;right:22px;border:solid transparent;content:' ';height:0;width:0;position:absolute;pointer-events:none;border-color:rgba(255,255,255,0);border-top-color:#fff;border-width:6px;margin-left:-6px}.rtm-options .dashicons{font-size:14px;line-height:24px;margin-right:2px}.rtm-media-options .rtm-options a{border:0;color:#fff;display:block;text-decoration:none}.rtm-ltb-title{color:rgba(255,255,255,0.7);float:left;font-size:13px}.rtm-ltb-title a{color:inherit}.rtm-ltb-title a:hover{border-bottom:1px dotted;color:#fff}.rtm-item-actions{float:right}.rtm-item-actions>div,.rtm-item-actions>form{float:left;margin:0 2px;padding:7px 0;position:relative}.rtmedia-media img{display:inline-block;max-height:inherit;height:auto;max-width:100%;width:auto}@media only screen and (max-device-width: 1024px){.rtmedia-media{margin:40px 0}}.rtm-user-meta-details .username{font-size:16px;line-height:1;margin-bottom:6px}.userprofile{float:left;margin:0 16px 16px 0;max-width:54px}.userprofile a{display:block}.userprofile img{height:auto;max-width:100%}.rtm-time-privacy{color:#999;font-size:12px}.rtm-time-privacy .dashicons{font-size:14px;line-height:1.5}.rtmedia-actions-before-comments>span{float:left;margin-right:10px}.rtmedia-actions-before-comments .rtmedia-comment-link,#buddypress .rtmedia-actions-before-comments .rtmedia-like{border:0;font-size:13px;font-weight:normal;line-height:2;padding:0;text-transform:none}.rtmedia-actions-before-comments .rtmedia-comment-link:hover,#buddypress .rtmedia-actions-before-comments .rtmedia-like:hover{background:transparent}.rtmedia-comment-user-pic{float:left;margin-right:10px;max-width:36px}.rtmedia-comment-user-pic img{height:auto;max-width:100%}.rtm-like-comments-info{position:relative}.rtm-like-comments-info:after{bottom:100%;left:15px;border:solid transparent;content:" ";height:0;width:0;position:absolute;pointer-events:none;border-color:rgba(237,239,244,0);border-bottom-color:#edeff4;border-width:4px;margin-left:-4px}.rtm-comment-list.rtm-comment-list{list-style:none;margin:0;padding:0}.rtm-comment-list li{background:#edeff4;font-size:12px;margin-bottom:1px;padding:10px;position:relative}.rtm-comment-list li:hover .rtmedia-delete-comment{opacity:1}.rtm-comment-list .rtmedia-no-comments{margin:0;padding:5px 10px}.rtmedia-like-info{background:#edeff4;font-size:12px;margin-bottom:1px;padding:5px 10px;position:relative}.rtm-comment-wrap{overflow:hidden}.rtm-comment-wrap .rtmedia-comment-author{font-weight:700}.rtm-comment-wrap .rtmedia-comment-date{color:#999;font-size:11px}.rtmedia-comment-content{margin-top:2px}.rtmedia-delete-comment{color:#999;cursor:pointer;font-size:16px;opacity:0;position:absolute;right:5px;top:5px}.rtmedia-comment-content p{margin:0}.rtmedia-comment-details{line-height:1.5;margin-top:-3px}.rtmedia-item-comments textarea{font-size:14px;padding:4px}.rtm-media-single-comments{background-color:#edeff4;bottom:20px;padding:10px;width:100%}.rtm-media-single-comments textarea{font-size:12px;line-height:14px;max-height:40px;min-height:30px;padding:4px}.rtmedia-popup{background:#fff;margin:20px auto;max-width:600px;padding:20px;position:relative;width:auto}.rtmedia-popup .rtm-modal-title{font-size:24px;margin-bottom:20px;margin-top:0}.rtmedia-popup label{display:block;margin-bottom:5px}#rtm-modal-container p{margin-bottom:10px}#rtm-mejs-video-container{margin:0 auto}.rtmedia-media-name{float:left;max-width:140px;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.rtm-single-media.rtm-media-type-video{padding-bottom:40px;padding-top:40px}.rtmedia-gallery-alert-container{position:fixed;top:0;left:0;height:100%;width:100%;background-color:rgba(0,0,0,0.6);z-index:999997}.rtmedia-gallery-message-box{position:fixed;top:40%;left:50%;margin-left:auto;margin-right:auto;z-index:999999}.rtmedia-gallery-message-box span{position:relative;left:-50%}.rtmedia-activity-container{box-sizing:border-box}.rtmedia-activity-container *,.rtmedia-activity-container *:before,.rtmedia-activity-container *:after{box-sizing:inherit}#buddypress ul.rtmedia-list li{border-bottom:0;padding-bottom:0}.rtmedia-activity-container .rtmedia-item-actions{display:none}.rtmedia-activity-container .rtmedia-item-title,.rtmedia-activity-container .rtmedia-item-title a{border:0;color:#666;font-size:13px;margin:5px 0 0;overflow:hidden;text-align:center;text-overflow:ellipsis;white-space:nowrap}#rtmedia-whts-new-upload-container div{left:0 !important;position:absolute;top:0 !important}#aw-whats-new-submit,.rtmedia-add-media-button{display:block}.rtm-drag-drop-active{border:4px dashed green !important;display:block;height:100%;opacity:0.5;z-index:9999}#rtm-drop-files-title{background:rgba(0,0,0,0.2);display:none;font-size:14px;height:100%;padding:20px;position:absolute;top:0;width:100%}#rtSelectPrivacy{float:right}.rtmedia-plupload-container{position:relative;float:left}.rtm-upload-button-wrapper{float:left;margin-right:5px}#rtmedia-action-update{margin-right:10px}.rtmedia-list-item.media-type-document,.rtmedia-list-item.media-type-music,.rtmedia-list-item.media-type-video{display:inline-block}.media-type-music .mejs-container{margin-bottom:10px}.rtmedia-album-edit .rtm-checkbox-wrap{background:rgba(255,255,255,0.9);height:30px;line-height:1;padding:10px;position:absolute;z-index:10}.rtmedia-album-edit .rtmedia-item-selector{position:relative;top:-7px}.rtmedia-album-edit .rtmedia-move-container{display:none}.rtm-single-actions.rtm-item-actions{float:none}.media-item .describe{border-collapse:collapse;width:100%;border-top-style:solid;border-top-width:1px;clear:both;cursor:default}.media-item.media-blank .describe{border:0}.media-item .describe th{vertical-align:top;text-align:left;padding:5px 10px 10px;width:140px}.media-item .describe .align th{padding-top:0}.media-item .media-item-info tr{background-color:transparent}.media-item .describe td{padding:0 8px 8px 0;vertical-align:top}.media-item thead.media-item-info td{padding:4px 10px 0}.media-item .media-item-info .A1B1{padding:0 0 0 10px}.media-item td.savesend{padding-bottom:15px}.media-item .thumbnail{max-height:128px;max-width:128px}#wpbody-content #async-upload-wrap a{display:none}.media-upload-form{margin-top:20px}.media-upload-form td label{margin-right:6px;margin-left:2px}.media-upload-form .align .field label{display:inline;padding:0 0 0 23px;margin:0 1em 0 3px;font-weight:bold}.media-upload-form tr.image-size label{margin:0 0 0 5px;font-weight:bold}.media-upload-form th.label label{font-weight:bold;margin:0.5em;font-size:13px}.media-upload-form th.label label span{padding:0 5px}abbr.required{border:medium none;text-decoration:none}.media-item .describe input[type="text"],.media-item .describe textarea{width:460px}.media-item .describe p.help{margin:0;padding:0 0 0 5px}.media-item .edit-attachment,.describe-toggle-on,.describe-toggle-off{display:block;line-height:36px;float:right;margin-right:15px}.media-item .describe-toggle-off,.media-item.open .describe-toggle-on{display:none}.media-item.open .describe-toggle-off{display:block}#media-items .media-item{border-style:solid;border-width:1px;min-height:36px;position:relative;margin-top:-1px;width:100%}#media-items{width:623px}.media-new-php #media-items{margin:1em 0}#media-items:empty{border:0 none}.media-item .filename{line-height:36px;overflow:hidden;padding:0 10px}.media-item .error-div{padding-left:10px}.media-item .pinkynail{float:left;margin:2px 2px 0;max-width:40px;max-height:32px}.media-item .startopen,.media-item .startclosed{display:none}.media-item .original{position:relative;height:34px}.media-item .progress{float:right;height:22px;margin:6px 10px 0 0;width:200px;line-height:2em;padding:0;overflow:hidden;margin-bottom:2px;border:1px solid #d1d1d1;background:#f7f7f7;background-image:-webkit-gradient(linear, left bottom, left top, from(#fff), to(#f7f7f7));background-image:-webkit-linear-gradient(bottom, #fff, #f7f7f7);background-image:linear-gradient(to top, #fff, #f7f7f7);border-radius:3px;box-shadow:inset 0 0 3px rgba(0,0,0,0.1)}.media-item .bar{z-index:9;width:0;height:100%;margin-top:-24px;background-color:#8cc1e9;background-image:-webkit-gradient(linear, left bottom, left top, from(#72a7cf), to(#8cc1e9));background-image:-webkit-linear-gradient(bottom, #72a7cf, #8cc1e9);background-image:linear-gradient(to top, #72a7cf, #8cc1e9);border-radius:3px;box-shadow:0 0 3px rgba(0,0,0,0.3)}.media-item .progress .percent{z-index:10;position:relative;width:200px;padding:0 8px;text-shadow:0 1px 0 rgba(255,255,255,0.4);color:rgba(0,0,0,0.6)}.upload-php .fixed .column-parent{width:15%}.js .html-uploader #plupload-upload-ui{display:none}.js .html-uploader #html-upload-ui{display:block}.media-upload-form .media-item.error{margin:0;padding:0}.media-upload-form .media-item.error p,.media-item .error-div{line-height:16px;margin:5px 10px;padding:0}.media-item .error-div a.dismiss{display:block;float:right;margin:5px 4px 0 15px}.find-box{width:600px;height:300px;overflow:hidden;padding:33px 0 51px;position:absolute;z-index:1000}.find-box-head{cursor:move;font-weight:bold;height:2em;line-height:2em;padding:1px 12px;position:absolute;top:5px;width:100%}.find-box-inside{overflow:auto;padding:6px;height:100%}.find-box-search{overflow:hidden;padding:9px;position:relative}.find-box-search .spinner{float:none;left:125px;position:absolute;top:9px}#find-posts-input{float:left;width:140px;height:24px}#find-posts-search{float:left;margin:1px 4px 0 3px}#find-posts-response{margin:8px 0;padding:0 1px 6px}#find-posts-response table{width:100%}#find-posts-response .found-radio{padding:3px 0 0 8px;width:15px}.find-box-buttons{padding:8px;overflow:hidden}.find-box #resize-se{position:absolute;right:1px;bottom:1px}.ui-find-overlay{position:absolute;top:0;left:0;background-color:#000;opacity:0.6;filter:alpha(opacity=60)}ul#dismissed-updates{display:none}form.upgrade{margin-top:8px}form.upgrade .hint{font-style:italic;font-size:85%;margin:-0.5em 0 2em 0}#poststuff .inside .the-tagcloud{margin:5px 0 10px;padding:8px;border-width:1px;border-style:solid;line-height:1.8em;word-spacing:3px;border-radius:6px}.drag-drop #drag-drop-area{border:4px dashed #DDDDDD;height:200px}.drag-drop .drag-drop-inside{margin:70px auto 0;width:250px}.drag-drop-inside p{color:#aaa;font-size:14px;margin:5px 0;display:none}.drag-drop .drag-drop-inside p{text-align:center}.drag-drop-inside p.drag-drop-info{font-size:20px}.drag-drop .drag-drop-inside p,.drag-drop-inside p.drag-drop-buttons{display:block}.drag-drop.drag-over #drag-drop-area{border-color:#83b4d8}#plupload-upload-ui{position:relative}.describe .image-editor{vertical-align:top}.imgedit-wrap{position:relative}.imgedit-settings p{margin:8px 0}.post-php .imgedit-wrap table{width:100%}.describe .imgedit-wrap table td,.wp_attachment_holder .imgedit-wrap table td{vertical-align:top;padding-top:0}.describe .imgedit-wrap table td.imgedit-settings{padding:0 5px}.wp_attachment_holder .imgedit-wrap table td.imgedit-settings{width:250px}td.imgedit-settings input{margin-top:0;vertical-align:middle}.imgedit-wait{position:absolute;top:0;background:#fff url(../../../../../../wp-admin/images/wpspin_light.gif) no-repeat scroll 22px 10px;background-size:16px 16px;opacity:0.7;filter:alpha(opacity=70);width:100%;height:500px;display:none}.spinner{background:url(../../../../../../wp-admin/images/wpspin_light.gif) no-repeat;background-size:16px 16px;display:none;float:right;opacity:0.7;filter:alpha(opacity=70);width:16px;height:16px;margin:5px 5px 0}.no-float{float:none}.media-disabled,.imgedit-settings .disabled{color:grey}.wp_attachment_image,.A1B1{overflow:hidden}.wp_attachment_image .button,.A1B1 .button{float:left}.no-js .wp_attachment_image .button{display:none}.wp_attachment_image .spinner,.A1B1 .spinner{float:left;padding:0 4px 4px;vertical-align:bottom}.imgedit-menu{margin:0 0 12px;min-width:300px}.imgedit-menu div{float:left;width:32px;height:32px}.imgedit-crop-wrap{position:relative}.imgedit-crop{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -9px -31px;margin:0 8px 0 0}.imgedit-crop.disabled:hover{background-position:-9px -31px}.imgedit-crop:hover{background-position:-9px -1px}.imgedit-rleft{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -46px -31px;margin:0 3px}.imgedit-rleft.disabled:hover{background-position:-46px -31px}.imgedit-rleft:hover{background-position:-46px -1px}.imgedit-rright{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -77px -31px;margin:0 8px 0 3px}.imgedit-rright.disabled:hover{background-position:-77px -31px}.imgedit-rright:hover{background-position:-77px -1px}.imgedit-flipv{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -115px -31px;margin:0 3px}.imgedit-flipv.disabled:hover{background-position:-115px -31px}.imgedit-flipv:hover{background-position:-115px -1px}.imgedit-fliph{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -147px -31px;margin:0 8px 0 3px}.imgedit-fliph.disabled:hover{background-position:-147px -31px}.imgedit-fliph:hover{background-position:-147px -1px}.imgedit-undo{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -184px -31px;margin:0 3px}.imgedit-undo.disabled:hover{background-position:-184px -31px}.imgedit-undo:hover{background-position:-184px -1px}.imgedit-redo{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -215px -31px;margin:0 8px 0 3px}.imgedit-redo.disabled:hover{background-position:-215px -31px}.imgedit-redo:hover{background-position:-215px -1px}.imgedit-applyto img{margin:0 8px 0 0}.imgedit-group h3{font-size:18px}.imgedit-group .dashicons{border:0;line-height:1.2}.imgedit-group-top{margin:5px 0}.imgedit-applyto .imgedit-label{padding:2px 0 0;display:block}.imgedit-help{display:none;font-style:italic;margin-bottom:8px}a.imgedit-help-toggle{text-decoration:none}.form-table td.imgedit-response{padding:0}.imgedit-submit{margin:8px 0}.imgedit-submit-btn{margin-left:20px}.imgedit-wrap .nowrap{white-space:nowrap}span.imgedit-scale-warn{color:red;font-size:20px;font-style:normal;visibility:hidden;vertical-align:middle}.wp_attachment_details{margin-bottom:20px}.imgedit-menu div{border-color:#d5d5d5;background-color:#f1f1f1}.imgedit-menu div:hover{border-color:#c1c1c1;background-color:#eaeaea}.imgedit-menu div.disabled{border-color:#ccc;background-color:#ddd;filter:alpha(opacity=50);opacity:0.5}.bp-media-image-editor-cotnainer{margin-top:35px}.wp_attachment_image .bp-media-image-edit{float:left}.wp_attachment_image .spinner{display:none}.bp-media-image-editor-cotnainer .hidden{display:none}.bp-media-image-editor-cotnainer div.updated{margin:5px 0 15px;background-color:#ffffe0;border-color:#e6db55;padding:0 .6em;border-radius:3px;border-width:1px;border-style:solid}.bp-media-image-editor-cotnainer div.updated p{margin:.5em 0;padding:2px}body article.bp_members.bp_member .entry-content,body div.bp_members.bp_member .entry-content{width:100%}.rtm-media-gallery-uploader{display:none}.rtmedia-uploader .drag-drop{border:4px dashed #DDD;text-align:center;background:#fafafa;overflow:hidden;color:#AAAAAA;margin-top:20px;padding:25px 0}.rtmedia-uploader .drag-drop.dragover{border-color:#83b4d8}.rtmedia-uploader .drag-drop .drag-drop-info{font-size:20px;line-height:24px}.rtmedia-uploader .drag-drop .rtm-select-files span{vertical-align:middle}.rtmedia-uploader .drag-drop .rtm-seperator{margin:0px 20px}.rtmedia-uploader .drag-drop .start-media-upload{display:none;margin-top:20px}.rtmedia-uploader .drag-drop .rtm-file-size-limit{vertical-align:middle;font-size:16px;line-height:24px}.rtm-uploader-main-wrapper .rtm-uploader-tabs{margin-bottom:10px;text-align:left}.rtm-uploader-main-wrapper ul{border-bottom:1px solid #CCC}.rtm-uploader-main-wrapper li{margin:0 0 -1px 10px;display:inline-block;padding:5px 10px;line-height:25px;background-color:#e4e4e4;border:1px solid #CCC}.rtm-uploader-main-wrapper li.active{background:transparent;border-left:1px solid #CCC;border-top:1px solid #CCC;border-right:1px solid #CCC;border-bottom:1px solid #fafafa}.rtm-uploader-main-wrapper li:hover{cursor:pointer}.rtmedia-container .rtmedia-list{margin:10px -5px}.rtmedia-container .rtmedia-list .rtmedia-list-item{float:left;margin:5px;position:relative}.rtmedia-container .rtmedia-list .rtmedia-list-item>a{display:block}.rtmedia-container .rtmedia-list .rtmedia_time{background-color:#000;color:#fff;display:inline-block;font-size:11px;font-weight:bold;line-height:14px;opacity:0.75;padding:0 4px;position:absolute;right:2px;top:2px}.rtmedia-container .rtmedia-list img{vertical-align:top}.rtmedia-container .rtmedia-list .rtmedia-item-title h4{color:#666;font-size:12px;font-weight:normal;margin:5px 0 0;overflow:hidden;text-align:center;text-overflow:ellipsis;white-space:nowrap}.rtm-load-more{background:#eee;text-align:center}.rtmedia-container .rtm-load-more a{border:0;padding:10px 0}.rtm-load-more .rtm-media-loading{padding:10px 0}.rtm-media-options{line-height:1.4;margin-bottom:10px}.rtm-media-options>div{display:inline-block;cursor:pointer}.rtm-media-options .rtm-media-options-list{margin-right:5px;padding-right:10px;position:relative}.rtm-media-options>*{border-right:1px solid #999}.rtm-media-options>*:last-child{border-right:none}.rtm-media-options .dashicons{font-size:inherit;line-height:1.4}.rtmedia-upload-media-link{cursor:pointer}a.rtmedia-upload-media-link{border:none}.rtm-album-privacy span{font-size:16px;display:inline-block;margin:0 20px 20px 20px;vertical-align:top}.rtm-album-privacy label{margin-right:8px}.rtm-album-privacy .dashicons{font-size:16px;line-height:1.6;margin-right:5px}#rtm-media-options-list .rtmedia-delete-album{background:transparent;border:0;color:#fff;font-family:inherit;font-size:inherit;font-weight:inherit;padding:0;text-transform:inherit}#rtm-media-options-list .rtmedia-delete-album:hover{background:transparent;border:0;color:#fff}.rtmedia-single-container button.rtmedia-like{background-color:transparent;color:inherit}#buddypress .mejs-controls button{padding:4px 8px;border:none;background:transparent url("../../../lib/media-element/controls.png") no-repeat}#buddypress .mejs-controls .mejs-play button{background-position:0 0}#buddypress .mejs-controls .mejs-pause button{background-position:0 -16px}#buddypress .mejs-controls .mejs-unmute button{background-position:-16px 0}#buddypress .mejs-controls .mejs-mute button{background-position:-16px -16px}#buddypress .mejs-controls .mejs-fullscreen-button button{background-position:-32px 0}#buddypress .mejs-controls .mejs-unfullscreen button{background-position:-32px -16px}.mejs-container .mejs-controls .mejs-time{padding:10px 3px 0;content:''}.rtmedia-activity-container .mejs-playpause-button.mejs-play button:before,.rtmedia-activity-container .mejs-playpause-button.mejs-pause button:before,.rtmedia-activity-container .mejs-volume-button.mejs-mute button:before,.rtmedia-activity-container .mejs-fullscreen-button button:before,.rtmedia-media .mejs-playpause-button.mejs-play button:before,.rtmedia-media .mejs-playpause-button.mejs-pause button:before,.rtmedia-media .mejs-volume-button.mejs-mute button:before,.rtmedia-media .mejs-fullscreen-button button:before{content:''}@media only screen and (min-width: 1025px){.mfp-content .rtm-lightbox-container{display:table;table-layout:fixed;width:100%}.mfp-content .rtm-mfp-close{background:transparent}.mfp-content .rtm-single-media{display:table-cell;width:66.6667%}.mfp-content .rtm-single-meta{display:table-cell;width:33.3333%;padding:20px;height:473px}.mfp-content .rtm-single-meta .rtmedia-scroll{height:100%;overflow-X:hidden}}.rtl #rtSelectPrivacy{float:left}.rtl .rtmedia-plupload-container{float:right}.rtl .rtm-upload-button-wrapper{float:right}.rtl #whats-new-post-in-box{float:right}.rtl .describe-toggle-off{float:left}.rtl .media-item .pinkynail{float:right}.rtl .media-item .progress{float:left}.rtl .media-item .error-div a.dismiss{float:left}.rtl #find-posts-input{float:right}.rtl #find-posts-search{float:right}.rtl .spinner{float:left}.rtl .wp_attachment_image .button,.rtl .A1B1 .button{float:right}.rtl .wp_attachment_image .spinner,.rtl .A1B1 .spinner{float:right}.rtl .imgedit-menu div{float:right}.rtl .wp_attachment_image .bp-media-image-edit{float:right}.rtl .rtmedia-container .rtmedia-list .rtmedia-list-item{float:right}.rtl #buddypress #rtm-media-options-list .rtm-options .button{float:right}.rtl .rtm-ltb-title{float:right}.rtl .rtm-item-actions{float:left}.rtl .rtm-item-actions>div,.rtl .rtm-item-actions>form{float:right}.rtl .userprofile{float:right}.rtl .rtmedia-actions-before-comments>span{float:right}.rtl .rtmedia-comment-user-pic{float:right}.rtl .rtmedia-media-name{float:right}.rtl #rtmedia-uploader-form .rtm-plupload-list li,.rtl #rtmedia_uploader_filelist li{float:right}.rtl .rtm-page-number{float:right}.rtl .rtm-page-number .rtmedia-page-link{float:right}.rtl .rtm-pagination{float:right}.rtl .rtm-pagination .rtm-paginate{float:left}.rtl .rtm-tabs li{float:right}.rtl .alignleft{float:right}.rtl .alignright{float:left}
1
+ .alignleft{float:left}.alignright{float:right}.aligncenter{display:block;margin-left:auto;margin-right:auto;text-align:center}.clear-both{clear:both}.clear-none{clear:none}.clear-left{clear:left}.clear-right{clear:right}.rtm-inline-block{display:inline-block}.rtm-text-left{text-align:left}.rtm-text-right{text-align:right}.rtm-text-center{text-align:center}.rtm-border-0{border:0 !important}.hide{display:none}.rtmedia-success,.rtmedia-warning{margin:10px 0;padding:8px 14px 8px 14px;text-shadow:0 1px 0 rgba(255,255,255,0.5);border-bottom:1px solid #e7e7e7;cursor:pointer}.rtmedia-success{background-color:#dff0d8;color:#468847}.rtmedia-warning{background-color:#F0D8DD;color:#884646}.clearfix:after{content:"";display:table;clear:both}#buddypress form#whats-new-form textarea{box-sizing:border-box;min-height:70px;width:100%}#buddypress #whats-new-options{height:auto !important;overflow:hidden}#buddypress form#whats-new-form p.activity-greeting{line-height:1}#buddypress form#whats-new-form #whats-new-options select{border:1px solid #ccc;font-size:13px;margin-top:0;padding:3px 2px}#whats-new-submit #aw-whats-new-submit{font-size:12px;line-height:18px;padding:4px 6px}#whats-new-post-in-box{float:left;font-size:13px}#buddypress form#whats-new-form #whats-new-submit{margin-top:0}#whats-new-textarea{margin-bottom:10px}body.media.buddypress{overflow-y:auto}#buddypress input[type=submit]:focus{background:#ededed;border:1px solid #bbb;color:#555;outline:0;text-decoration:none}.rtmedia-container{box-sizing:border-box}.rtmedia-container *,.rtmedia-container *:before,.rtmedia-container *:after{box-sizing:inherit}.rtmedia-list.rtmedia-list{list-style:none;margin:0;padding:0}.rtmedia-list-item>a{border:0;display:inline-block;text-decoration:none}.rtmedia-list-item>a:focus{outline:0}.rtmedia-list-item>a+p{display:none}.rtmedia-list-item>a .rtmedia-item-thumbnail img{display:inline-block}#rtmedia-uploader-form .rtm-plupload-list,#rtmedia_uploader_filelist{list-style:none;margin-left:-4px;margin-right:-4px;padding-left:0;padding-top:10px}#rtmedia-uploader-form .rtm-plupload-list li,#rtmedia_uploader_filelist li{background:#eee;float:left;margin:4px;max-width:110px;padding:5px;position:relative}#rtmedia-uploader-form .rtm-plupload-list li.upload-error,#rtmedia_uploader_filelist li.upload-error{border:1px solid red}#rtmedia-uploader-form .rtm-plupload-list img,#rtmedia_uploader_filelist img{max-width:100%}#rtmedia-uploader-form .rtm-plupload-list canvas,#rtmedia_uploader_filelist canvas{display:block;max-width:100%}#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-title,#rtmedia_uploader_filelist .rtm-upload-edit-title{font-size:12px}#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-desc,#rtmedia_uploader_filelist .rtm-upload-edit-desc{font-size:12px;display:block}#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-title-wrapper label,#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-desc-wrapper label,#rtmedia_uploader_filelist .rtm-upload-edit-title-wrapper label,#rtmedia_uploader_filelist .rtm-upload-edit-desc-wrapper label{display:block}#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-title-wrapper input.rtm-upload-edit-title,#rtmedia-uploader-form .rtm-plupload-list .rtm-upload-edit-desc-wrapper input.rtm-upload-edit-title,#rtmedia_uploader_filelist .rtm-upload-edit-title-wrapper input.rtm-upload-edit-title,#rtmedia_uploader_filelist .rtm-upload-edit-desc-wrapper input.rtm-upload-edit-title{min-width:100%;margin-top:1px}.rtm-plupload-list:empty{display:none}.rtmedia-uploader-div,.rtmedia-uploader{clear:both}button#rtmedia-add-media-button-post-update{padding:3px 6px}button#rtmedia-add-media-button-post-update .dashicons{font-size:18px;line-height:20px}.plupload_file_name{font-size:11px;font-weight:bold;line-height:1.2;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.plupload_file_size{color:#666;font-size:10px}.plupload_file_action{background:#eee;position:absolute;height:18px;right:4px;top:0;width:18px;z-index:10}.plupload_file_action .dashicons{color:#DD3D36;cursor:pointer;font-size:16px;height:18px;padding:2px 1px;width:18px}.plupload_file_status{height:18px;overflow:hidden;position:relative}.plupload_file_progress{background:#7AD03A;height:4px;position:absolute;top:0}.rtm-form .rtm-field-wrap{margin-bottom:20px}.rtmedia_next_prev{padding:0 10px}.rtm-page-number{float:left}.rtm-page-number .rtm-label{line-height:30px}.rtm-page-number .rtm-label,.rtm-page-number .rtm-go-to-num,.rtm-page-number .rtmedia-page-link{float:left}.rtm-pagination{background:transparent;border:none;color:#888;font-size:small;margin:0;position:relative;display:block;float:left;width:100%;padding:10px 0}.rtm-pagination .rtm-paginate{float:right;font-size:15px}.rtm-pagination .rtm-paginate a,.rtm-pagination .rtm-paginate span{display:inline-block;line-height:1;margin:0 2px;padding:8px;text-decoration:none}.rtm-pagination .rtm-paginate a.rtmedia-page-link{padding:8px}.rtm-pagination .dashicons{font-size:14px;height:auto;line-height:1.2;margin:0;padding:0;width:auto}#rtmedia_go_to_num{font-size:16px;margin:0 5px;padding:4px 5px;width:80px}.rtmedia-upload-not-allowed{background-color:#fcf8e3;border-bottom:1px solid #EEE;color:#c09853;margin-bottom:20px;padding:10px 15px}.plupload_file_name{position:relative}.plupload_file_name .dashicons{background:#eee;color:#DD3D36;cursor:pointer;font-size:14px;height:auto;padding:0 2px 0 5px;position:absolute;right:0;top:0;width:auto}.plupload_file_name .dashicons-yes{color:#7AD03A}.rtmedia-gallery-item-actions{background-color:rgba(0,0,0,0.6);opacity:0;position:absolute;text-align:center;-webkit-transition:all ease-in-out 0.4s;transition:all ease-in-out 0.4s;width:100%;z-index:9}.rtmedia-gallery-item-actions a{border:0;box-shadow:0 0 0;color:#fff;display:inline-block;font-size:12px;outline:none;padding:4px;text-align:left;text-decoration:none;text-transform:uppercase}.rtmedia-gallery-item-actions .dashicons{font-size:17px;margin-right:2px;position:relative;top:1px}.rtmedia-gallery-item-actions .dashicons-trash{font-size:15px}.rtm-pro-allow-action .rtmedia-list-item:hover .rtmedia-gallery-item-actions{opacity:1}.rtm-pro-allow-action .rtmedia-list-item:hover .rtmedia-bulk-edit-item-wrap+.rtmedia-gallery-item-actions{opacity:0}.rtmedia-footer-link{clear:both;overflow:hidden;padding:16px 0;position:relative;text-align:center}.rtmedia-text-link-decoration,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit a,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit span,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete a,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete span,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title a,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title span{text-decoration:none}.rtmedia-text-link-decoration:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit a:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit span:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete a:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete span:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title a:hover,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title span:hover{text-decoration:underline}.rtmedia-container .rtmedia-edit-list-media-table{max-height:300px;overflow-y:auto}.rtmedia-container .rtmedia-edit-list-media-table thead tr{background-color:#50A1D7}.rtmedia-container .rtmedia-edit-list-media-table thead th{text-align:center;color:#FFF}.rtmedia-container .rtmedia-edit-list-media-table tbody tr:nth-child(odd){background:#FFF}.rtmedia-container .rtmedia-edit-list-media-table tbody tr:nth-child(even){background:#DCDCDC}table.rtmedia-edit-media-list tr{line-height:30px}table.rtmedia-edit-media-list tr th{color:#333;padding:4px 10px;line-height:20px}table.rtmedia-edit-media-list tr .rtm-edit-media-list-heading{width:44%}table.rtmedia-edit-media-list tr .rtm-edit-media-list-title-heading{width:56%}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete,table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title{padding:4px;font-size:14px;line-height:24px}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-title a{text-decoration:none;color:#333}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit{text-align:center}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-edit a{color:#333;font-size:13px}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete{text-align:center}table.rtmedia-edit-media-list tr td.rtm-edit-media-list-delete span{color:#FF0000;cursor:pointer;font-size:13px}.rtm-hide{display:none}.rtmedia-list-item .rtmedia-album-media-count{position:absolute;top:0;right:0;background-color:black;color:white;padding:0 5px}.rtm-tabs.rtm-tabs{border-bottom:1px solid #eee;list-style:none;margin:0 0 20px;padding:0}.rtm-tabs li{border:1px solid #eee;border-bottom:0;float:left;margin:0 5px;padding:0}.rtm-tabs a{border:0;display:block;padding:5px 15px;text-decoration:none}.rtm-tabs a:focus{background:transparent;box-shadow:0 0 0}.rtm-tabs .active{position:relative}.rtm-tabs .active:after{background:#fff;bottom:-1px;content:' ';height:1px;left:0;position:absolute;width:100%}.rtm-tabs .dashicons{font-size:16px;height:auto;line-height:20px;margin-right:8px;width:auto}.rtmedia-edit-media-tabs .rtm-tabs a{border-bottom:0 none}.mfp-bg{top:0;left:0;width:100%;height:100%;z-index:104211;overflow:hidden;position:fixed;background:rgba(0,0,0,0.9)}.mfp-wrap{top:0;left:0;width:100%;height:100%;z-index:104311;position:fixed;outline:none !important;-webkit-backface-visibility:hidden}.mfp-container{text-align:center;position:absolute;width:100%;max-width:84%;margin:0 auto;right:0;height:100%;left:0;top:0;padding:0 8px;box-sizing:border-box}.mfp-container:before{content:' ';display:inline-block;height:100%;vertical-align:middle}.mfp-align-top .mfp-container:before{display:none}.mfp-content{position:relative;display:inline-block;vertical-align:middle;margin:0 auto;text-align:left;z-index:1045}.mfp-inline-holder .mfp-content,.mfp-ajax-holder .mfp-content{width:100%;cursor:auto}.mfp-ajax-cur{cursor:progress}.mfp-zoom-out-cur,.mfp-zoom-out-cur .mfp-image-holder .mfp-close{cursor:zoom-out}.mfp-zoom{cursor:pointer;cursor:zoom-in}.mfp-auto-cursor .mfp-content{cursor:auto}.mfp-close,.mfp-arrow,.mfp-preloader,.mfp-counter{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.mfp-loading.mfp-figure{display:none}.mfp-hide{display:none !important}.mfp-s-ready .mfp-preloader{display:none}.mfp-s-error .mfp-content{display:none}button.mfp-close,button.mfp-arrow{overflow:visible;cursor:pointer;background:transparent;border:0;-webkit-appearance:none;display:block;outline:none;padding:0;z-index:1046;box-shadow:none}button::-moz-focus-inner{padding:0;border:0}.mfp-close{background:#fff;color:#999;cursor:pointer;font-size:24px;font-style:normal;height:30px;line-height:30px;padding:0;position:absolute;right:1px;text-align:center;text-decoration:none;text-indent:2px;top:0;width:32px;z-index:12}.mfp-close:hover,.mfp-close:focus{opacity:1;filter:alpha(opacity=100)}.mfp-close:active{top:1px}.mfp-image-holder .mfp-close,.mfp-iframe-holder .mfp-close{color:#FFF;right:-6px;text-align:right;padding-right:6px;width:100%}.mfp-counter{position:absolute;top:0;right:0;color:#CCC;font-size:12px;line-height:18px;white-space:nowrap}.mfp-arrow{cursor:pointer;position:absolute;opacity:0.65;filter:alpha(opacity=65);margin:0;top:50%;margin-top:-55px;padding:0;width:90px;height:110px;-webkit-tap-highlight-color:transparent;opacity:0;z-index:10;-webkit-transition:all 300ms ease-out;transition:all 300ms ease-out}.rtm-single-media:hover .mfp-arrow{opacity:1}@media (max-device-width: 640px){.mfp-arrow{display:none}.rtm-single-media:hover .mfp-arrow{display:none}}.mfp-arrow:active{margin-top:-54px}.mfp-arrow:hover,.mfp-arrow:focus{opacity:1;filter:alpha(opacity=100)}.mfp-arrow:before,.mfp-arrow:after,.mfp-arrow .mfp-b,.mfp-arrow .mfp-a{content:'';display:block;width:0;height:0;position:absolute;left:0;top:0;margin-top:35px;margin-left:35px;border:medium inset transparent}.mfp-arrow:after,.mfp-arrow .mfp-a{border-top-width:13px;border-bottom-width:13px;top:8px}.mfp-arrow:before,.mfp-arrow .mfp-b{border-top-width:21px;border-bottom-width:21px;opacity:0.7}.mfp-arrow-left{left:0}.mfp-arrow-left:after,.mfp-arrow-left .mfp-a{border-right:17px solid #FFF;margin-left:31px}.mfp-arrow-left:before,.mfp-arrow-left .mfp-b{margin-left:25px;border-right:27px solid #3F3F3F}.mfp-arrow-right{right:0}.mfp-arrow-right:after,.mfp-arrow-right .mfp-a{border-left:17px solid #FFF;margin-left:39px}.mfp-arrow-right:before,.mfp-arrow-right .mfp-b{border-left:27px solid #3F3F3F}.mfp-iframe-holder{padding-top:40px;padding-bottom:40px}.mfp-iframe-holder .mfp-content{line-height:0;width:100%;max-width:900px}.mfp-iframe-holder .mfp-close{top:-40px}.mfp-iframe-scaler{width:100%;height:0;overflow:hidden;padding-top:56.25%}.mfp-iframe-scaler iframe{position:absolute;display:block;top:0;left:0;width:100%;height:100%;box-shadow:0 0 8px rgba(0,0,0,0.6);background:#000}img.mfp-img{width:auto;max-width:100%;height:auto;display:block;line-height:0;box-sizing:border-box;padding:40px 0 40px;margin:0 auto}.mfp-figure{line-height:0}.mfp-figure:after{content:'';position:absolute;left:0;top:40px;bottom:40px;display:block;right:0;width:auto;height:auto;z-index:-1;box-shadow:0 0 8px rgba(0,0,0,0.6);background:#444}.mfp-figure small{color:#BDBDBD;display:block;font-size:12px;line-height:14px}.mfp-figure figure{margin:0}.mfp-bottom-bar{margin-top:-36px;position:absolute;top:100%;left:0;width:100%;cursor:auto}.mfp-title{text-align:left;line-height:18px;color:#F3F3F3;word-wrap:break-word;padding-right:36px}.mfp-image-holder .mfp-content{max-width:100%}.mfp-gallery .mfp-image-holder .mfp-figure{cursor:pointer}.mfp-preloader{position:absolute;top:50%;left:0;right:0;margin-top:-36px;z-index:1044;font-size:0;width:36px;height:36px;margin-left:auto;margin-right:auto}.mfp-preloader:before{content:'Loading…';position:absolute;width:30px;height:30px}.mfp-preloader:not(:required):before{content:'';border-radius:50%;border:3px solid rgba(255,255,255,0.27);border-top-color:rgba(255,255,255,0.9);animation:spinner .6s linear infinite;-webkit-animation:spinner .6s linear infinite}@keyframes spinner{to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@-webkit-keyframes spinner{to{-webkit-transform:rotate(360deg)}}@media screen and (max-width: 800px) and (orientation: landscape), screen and (max-height: 300px){.mfp-img-mobile .mfp-image-holder{padding-left:0;padding-right:0}.mfp-img-mobile img.mfp-img{padding:0}.mfp-img-mobile .mfp-figure:after{top:0;bottom:0}.mfp-img-mobile .mfp-figure small{display:inline;margin-left:5px}.mfp-img-mobile .mfp-bottom-bar{background:rgba(0,0,0,0.6);bottom:0;margin:0;top:auto;padding:3px 5px;position:fixed;box-sizing:border-box}.mfp-img-mobile .mfp-bottom-bar:empty{padding:0}.mfp-img-mobile .mfp-counter{right:5px;top:3px}.mfp-img-mobile .mfp-close{top:0;right:0;width:35px;height:35px;line-height:35px;background:rgba(0,0,0,0.6);position:fixed;text-align:center;padding:0}}@media all and (max-width: 900px){.mfp-arrow{-webkit-transform:scale(0.75);-ms-transform:scale(0.75);transform:scale(0.75)}.mfp-arrow-left{-webkit-transform-origin:0;-ms-transform-origin:0;transform-origin:0}.mfp-arrow-right{-webkit-transform-origin:100%;-ms-transform-origin:100%;transform-origin:100%}.mfp-container{padding-left:6px;padding-right:6px}}#atwho-container #atwho-ground-comment_content .atwho-view{z-index:2147483647}.mfp-content .rtm-lightbox-container{background:#000;margin:0 auto;position:relative}.mfp-content .rtm-single-meta{background:#fff;overflow:hidden;padding:20px 20px 110px;position:relative;vertical-align:top}.rtm-single-media{overflow:hidden;position:relative;text-align:center;vertical-align:middle}.rtm-single-media .mejs-container{margin:0 auto;max-width:inherit}.rtm-single-media .rtmedia-message-container{position:absolute;top:45%;left:0;right:0;margin-left:auto;margin-right:auto}@media (max-device-width: 640px){.rtm-single-media .rtmedia-message-container{top:25%}}.rtm-ltb-action-container{background-color:rgba(0,0,0,0.6);bottom:0;color:#fff;line-height:38px;opacity:0;padding:0 10px;position:absolute;width:100%;-webkit-transition:all 300ms ease-out;transition:all 300ms ease-out}.rtm-single-media:hover .rtm-ltb-action-container{opacity:1}@media (max-device-width: 640px){.rtm-ltb-action-container{clear:both;position:relative;opacity:1}.rtm-single-media:hover .rtm-ltb-action-container{opacity:1}}#buddypress #rtmedia-single-media-container.rtmedia-single-media .button{background:transparent;border:0 none;border-radius:2px;color:rgba(255,255,255,0.5);display:block;font-family:inherit;font-weight:normal;line-height:24px;margin:0;padding:0 6px;text-shadow:0 0 0;text-transform:none}#buddypress #rtmedia-single-media-container.rtmedia-single-media .button:hover{background:rgba(255,255,255,0.2);color:rgba(255,255,255,0.8)}#buddypress #rtmedia-single-media-container.rtmedia-single-media .rtm-options .button{color:#333;margin:0 auto;padding:0 4px 0 0}#buddypress #rtm-media-options-list .rtm-options form button{font-size:small}#buddypress #rtm-media-options-list .rtm-options .button{background:transparent;border:0 none;border-radius:2px;color:rgba(255,255,255,0.5);float:left;font-family:inherit;font-weight:normal;line-height:24px;padding:0 6px;text-shadow:0 0 0;text-transform:none}#buddypress #rtm-media-options-list .rtm-options .rtmedia-delete-favlist{color:#fff;padding:0}.rtm-options.rtm-options{background:#666;color:#fff;display:none;font-size:14px;list-style:none;margin:0;padding:8px 10px;position:absolute;left:0;top:38px;width:190px;z-index:10}.rtm-options li{margin:0;overflow:hidden;padding:2px 0}.rtm-media-options .rtm-options:after{bottom:100%;left:20px;border:solid transparent;content:' ';height:0;width:0;position:absolute;pointer-events:none;border-color:rgba(255,255,255,0);border-bottom-color:#666;border-width:6px;margin-left:-6px}.mfp-content .rtm-options{background:#fff;color:#333;bottom:38px;right:0;left:auto;top:auto}.mfp-content .rtm-options:after{top:100%;right:22px;border:solid transparent;content:' ';height:0;width:0;position:absolute;pointer-events:none;border-color:rgba(255,255,255,0);border-top-color:#fff;border-width:6px;margin-left:-6px}.rtm-options .dashicons{font-size:14px;line-height:24px;margin-right:2px}.rtm-media-options .rtm-options a{border:0;color:#fff;display:block;text-decoration:none}.rtm-ltb-title{color:rgba(255,255,255,0.7);float:left;font-size:13px}.rtm-ltb-title a{color:inherit}.rtm-ltb-title a:hover{border-bottom:1px dotted;color:#fff}.rtm-item-actions{float:right}.rtm-item-actions>div,.rtm-item-actions>form{float:left;margin:0 2px;padding:7px 0;position:relative}.rtmedia-media img{display:inline-block;max-height:inherit;height:auto;max-width:100%;width:auto}@media only screen and (max-device-width: 1024px){.rtmedia-media{margin:40px 0}}.rtm-user-meta-details .username{font-size:16px;line-height:1;margin-bottom:6px}.userprofile{float:left;margin:0 16px 16px 0;max-width:54px}.userprofile a{display:block}.userprofile img{height:auto;max-width:100%}.rtm-time-privacy{color:#999;font-size:12px}.rtm-time-privacy .dashicons{font-size:14px;line-height:1.5;margin-top:-2px}.rtmedia-actions-before-comments>span{float:left;margin-right:10px}.rtmedia-actions-before-comments .rtmedia-comment-link,#buddypress .rtmedia-actions-before-comments .rtmedia-like{border:0;font-size:13px;font-weight:normal;line-height:2;padding:0;text-transform:none}.rtmedia-actions-before-comments .rtmedia-comment-link:hover,#buddypress .rtmedia-actions-before-comments .rtmedia-like:hover{background:transparent}.rtmedia-comment-user-pic{float:left;margin-right:10px;max-width:36px}.rtmedia-comment-user-pic img{height:auto;max-width:100%}.rtm-like-comments-info{position:relative}.rtm-like-comments-info:after{bottom:100%;left:15px;border:solid transparent;content:" ";height:0;width:0;position:absolute;pointer-events:none;border-color:rgba(237,239,244,0);border-bottom-color:#edeff4;border-width:4px;margin-left:-4px}.rtm-comment-list.rtm-comment-list{list-style:none;margin:0;padding:0}.rtm-comment-list li{background:#edeff4;font-size:12px;margin-bottom:1px;padding:10px;position:relative}.rtm-comment-list li:hover .rtmedia-delete-comment{opacity:1}.rtm-comment-list .rtmedia-no-comments{margin:0;padding:5px 10px}.rtmedia-like-info{background:#edeff4;font-size:12px;margin-bottom:1px;padding:5px 10px;position:relative}.rtm-comment-wrap{overflow:hidden}.rtm-comment-wrap .rtmedia-comment-author{font-weight:700}.rtm-comment-wrap .rtmedia-comment-date{color:#999;font-size:11px}.rtmedia-comment-content{margin-top:2px}.rtmedia-delete-comment{color:#999;cursor:pointer;font-size:16px;opacity:0;position:absolute;right:5px;top:5px}.rtmedia-comment-content p{margin:0}.rtmedia-comment-details{line-height:1.5;margin-top:-3px}.rtmedia-item-comments textarea{font-size:14px;padding:4px}.rtm-media-single-comments{background-color:#edeff4;bottom:20px;padding:10px;width:100%}.rtm-media-single-comments textarea{font-size:12px;line-height:14px;max-height:40px;min-height:30px;padding:4px}.rtmedia-popup{background:#fff;margin:20px auto;max-width:600px;padding:20px;position:relative;width:auto}.rtmedia-popup .rtm-modal-title{font-size:24px;margin-bottom:20px;margin-top:0}.rtmedia-popup label{display:block;margin-bottom:5px}#rtm-modal-container p{margin-bottom:10px}#rtm-mejs-video-container{margin:0 auto}.rtmedia-media-name{float:left;max-width:140px;overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap}.rtm-single-media.rtm-media-type-video{padding-bottom:40px;padding-top:40px}.rtmedia-gallery-alert-container{position:fixed;top:0;left:0;height:100%;width:100%;background-color:rgba(0,0,0,0.6);z-index:999997}.rtmedia-gallery-message-box{position:fixed;top:40%;left:50%;margin-left:auto;margin-right:auto;z-index:999999}.rtmedia-gallery-message-box span{position:relative;left:-50%}.rtmedia-activity-container{box-sizing:border-box}.rtmedia-activity-container *,.rtmedia-activity-container *:before,.rtmedia-activity-container *:after{box-sizing:inherit}#buddypress ul.rtmedia-list li{border-bottom:0;padding-bottom:0}.rtmedia-activity-container .rtmedia-item-actions{display:none}.rtmedia-activity-container .rtmedia-item-title,.rtmedia-activity-container .rtmedia-item-title a{border:0;color:#666;font-size:13px;margin:5px 0 0;overflow:hidden;text-align:center;text-overflow:ellipsis;white-space:nowrap}#rtmedia-whts-new-upload-container div{left:0 !important;position:absolute;top:0 !important}#aw-whats-new-submit,.rtmedia-add-media-button{display:block}.rtm-drag-drop-active{border:4px dashed green !important;display:block;height:100%;opacity:0.5;z-index:9999}#rtm-drop-files-title{background:rgba(0,0,0,0.2);display:none;font-size:14px;height:100%;padding:20px;position:absolute;top:0;width:100%}#rtSelectPrivacy{float:right}.rtmedia-plupload-container{position:relative;float:left}.rtm-upload-button-wrapper{float:left;margin-right:5px}#rtmedia-action-update{margin-right:10px}.rtmedia-list-item.media-type-document,.rtmedia-list-item.media-type-music,.rtmedia-list-item.media-type-video{display:inline-block}.media-type-music .mejs-container{margin-bottom:10px}.previous-pagination{float:left;margin-top:10px}.next-pagination{float:right;margin-top:10px}@media screen and (max-width: 500px){#activity-stream li .media-type-video{width:100%}#activity-stream li .media-type-video .mejs-video{max-width:100%;min-width:100%}}#rtmedia_show_all_comment{cursor:pointer}#rtmedia_show_all_comment:hover{text-decoration:underline}.rtmedia-album-edit .rtm-checkbox-wrap{background:rgba(255,255,255,0.9);height:30px;line-height:1;padding:10px;position:absolute;z-index:10}.rtmedia-album-edit .rtmedia-item-selector{position:relative;top:-7px}.rtmedia-album-edit .rtmedia-move-container{display:none}.rtm-single-actions.rtm-item-actions{float:none}.media-item .describe{border-collapse:collapse;width:100%;border-top-style:solid;border-top-width:1px;clear:both;cursor:default}.media-item.media-blank .describe{border:0}.media-item .describe th{vertical-align:top;text-align:left;padding:5px 10px 10px;width:140px}.media-item .describe .align th{padding-top:0}.media-item .media-item-info tr{background-color:transparent}.media-item .describe td{padding:0 8px 8px 0;vertical-align:top}.media-item thead.media-item-info td{padding:4px 10px 0}.media-item .media-item-info .A1B1{padding:0 0 0 10px}.media-item td.savesend{padding-bottom:15px}.media-item .thumbnail{max-height:128px;max-width:128px}#wpbody-content #async-upload-wrap a{display:none}.media-upload-form{margin-top:20px}.media-upload-form td label{margin-right:6px;margin-left:2px}.media-upload-form .align .field label{display:inline;padding:0 0 0 23px;margin:0 1em 0 3px;font-weight:bold}.media-upload-form tr.image-size label{margin:0 0 0 5px;font-weight:bold}.media-upload-form th.label label{font-weight:bold;margin:0.5em;font-size:13px}.media-upload-form th.label label span{padding:0 5px}abbr.required{border:medium none;text-decoration:none}.media-item .describe input[type="text"],.media-item .describe textarea{width:460px}.media-item .describe p.help{margin:0;padding:0 0 0 5px}.media-item .edit-attachment,.describe-toggle-on,.describe-toggle-off{display:block;line-height:36px;float:right;margin-right:15px}.media-item .describe-toggle-off,.media-item.open .describe-toggle-on{display:none}.media-item.open .describe-toggle-off{display:block}#media-items .media-item{border-style:solid;border-width:1px;min-height:36px;position:relative;margin-top:-1px;width:100%}#media-items{width:623px}.media-new-php #media-items{margin:1em 0}#media-items:empty{border:0 none}.media-item .filename{line-height:36px;overflow:hidden;padding:0 10px}.media-item .error-div{padding-left:10px}.media-item .pinkynail{float:left;margin:2px 2px 0;max-width:40px;max-height:32px}.media-item .startopen,.media-item .startclosed{display:none}.media-item .original{position:relative;height:34px}.media-item .progress{float:right;height:22px;margin:6px 10px 0 0;width:200px;line-height:2em;padding:0;overflow:hidden;margin-bottom:2px;border:1px solid #d1d1d1;background:#f7f7f7;background-image:-webkit-gradient(linear, left bottom, left top, from(#fff), to(#f7f7f7));background-image:-webkit-linear-gradient(bottom, #fff, #f7f7f7);background-image:linear-gradient(to top, #fff, #f7f7f7);border-radius:3px;box-shadow:inset 0 0 3px rgba(0,0,0,0.1)}.media-item .bar{z-index:9;width:0;height:100%;margin-top:-24px;background-color:#8cc1e9;background-image:-webkit-gradient(linear, left bottom, left top, from(#72a7cf), to(#8cc1e9));background-image:-webkit-linear-gradient(bottom, #72a7cf, #8cc1e9);background-image:linear-gradient(to top, #72a7cf, #8cc1e9);border-radius:3px;box-shadow:0 0 3px rgba(0,0,0,0.3)}.media-item .progress .percent{z-index:10;position:relative;width:200px;padding:0 8px;text-shadow:0 1px 0 rgba(255,255,255,0.4);color:rgba(0,0,0,0.6)}.upload-php .fixed .column-parent{width:15%}.js .html-uploader #plupload-upload-ui{display:none}.js .html-uploader #html-upload-ui{display:block}.media-upload-form .media-item.error{margin:0;padding:0}.media-upload-form .media-item.error p,.media-item .error-div{line-height:16px;margin:5px 10px;padding:0}.media-item .error-div a.dismiss{display:block;float:right;margin:5px 4px 0 15px}.find-box{width:600px;height:300px;overflow:hidden;padding:33px 0 51px;position:absolute;z-index:1000}.find-box-head{cursor:move;font-weight:bold;height:2em;line-height:2em;padding:1px 12px;position:absolute;top:5px;width:100%}.find-box-inside{overflow:auto;padding:6px;height:100%}.find-box-search{overflow:hidden;padding:9px;position:relative}.find-box-search .spinner{float:none;left:125px;position:absolute;top:9px}#find-posts-input{float:left;width:140px;height:24px}#find-posts-search{float:left;margin:1px 4px 0 3px}#find-posts-response{margin:8px 0;padding:0 1px 6px}#find-posts-response table{width:100%}#find-posts-response .found-radio{padding:3px 0 0 8px;width:15px}.find-box-buttons{padding:8px;overflow:hidden}.find-box #resize-se{position:absolute;right:1px;bottom:1px}.ui-find-overlay{position:absolute;top:0;left:0;background-color:#000;opacity:0.6;filter:alpha(opacity=60)}ul#dismissed-updates{display:none}form.upgrade{margin-top:8px}form.upgrade .hint{font-style:italic;font-size:85%;margin:-0.5em 0 2em 0}#poststuff .inside .the-tagcloud{margin:5px 0 10px;padding:8px;border-width:1px;border-style:solid;line-height:1.8em;word-spacing:3px;border-radius:6px}.drag-drop #drag-drop-area{border:4px dashed #DDDDDD;height:200px}.drag-drop .drag-drop-inside{margin:70px auto 0;width:250px}.drag-drop-inside p{color:#aaa;font-size:14px;margin:5px 0;display:none}.drag-drop .drag-drop-inside p{text-align:center}.drag-drop-inside p.drag-drop-info{font-size:20px}.drag-drop .drag-drop-inside p,.drag-drop-inside p.drag-drop-buttons{display:block}.drag-drop.drag-over #drag-drop-area{border-color:#83b4d8}#plupload-upload-ui{position:relative}.describe .image-editor{vertical-align:top}.imgedit-wrap{position:relative}.imgedit-settings p{margin:8px 0}.post-php .imgedit-wrap table{width:100%}.describe .imgedit-wrap table td,.wp_attachment_holder .imgedit-wrap table td{vertical-align:top;padding-top:0}.describe .imgedit-wrap table td.imgedit-settings{padding:0 5px}.wp_attachment_holder .imgedit-wrap table td.imgedit-settings{width:250px}td.imgedit-settings input{margin-top:0;vertical-align:middle}.imgedit-wait{position:absolute;top:0;background:#fff url(../../../../../../wp-admin/images/wpspin_light.gif) no-repeat scroll 22px 10px;background-size:16px 16px;opacity:0.7;filter:alpha(opacity=70);width:100%;height:500px;display:none}.spinner{background:url(../../../../../../wp-admin/images/wpspin_light.gif) no-repeat;background-size:16px 16px;display:none;float:right;opacity:0.7;filter:alpha(opacity=70);width:16px;height:16px;margin:5px 5px 0}.no-float{float:none}.media-disabled,.imgedit-settings .disabled{color:grey}.wp_attachment_image,.A1B1{overflow:hidden}.wp_attachment_image .button,.A1B1 .button{float:left}.no-js .wp_attachment_image .button{display:none}.wp_attachment_image .spinner,.A1B1 .spinner{float:left;padding:0 4px 4px;vertical-align:bottom}.imgedit-menu{margin:0 0 12px;min-width:300px}.imgedit-menu div{float:left;width:32px;height:32px}.imgedit-crop-wrap{position:relative}.imgedit-crop{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -9px -31px;margin:0 8px 0 0}.imgedit-crop.disabled:hover{background-position:-9px -31px}.imgedit-crop:hover{background-position:-9px -1px}.imgedit-rleft{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -46px -31px;margin:0 3px}.imgedit-rleft.disabled:hover{background-position:-46px -31px}.imgedit-rleft:hover{background-position:-46px -1px}.imgedit-rright{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -77px -31px;margin:0 8px 0 3px}.imgedit-rright.disabled:hover{background-position:-77px -31px}.imgedit-rright:hover{background-position:-77px -1px}.imgedit-flipv{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -115px -31px;margin:0 3px}.imgedit-flipv.disabled:hover{background-position:-115px -31px}.imgedit-flipv:hover{background-position:-115px -1px}.imgedit-fliph{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -147px -31px;margin:0 8px 0 3px}.imgedit-fliph.disabled:hover{background-position:-147px -31px}.imgedit-fliph:hover{background-position:-147px -1px}.imgedit-undo{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -184px -31px;margin:0 3px}.imgedit-undo.disabled:hover{background-position:-184px -31px}.imgedit-undo:hover{background-position:-184px -1px}.imgedit-redo{background:transparent url("../../../../../../wp-admin/images/imgedit-icons.png") no-repeat scroll -215px -31px;margin:0 8px 0 3px}.imgedit-redo.disabled:hover{background-position:-215px -31px}.imgedit-redo:hover{background-position:-215px -1px}.imgedit-applyto img{margin:0 8px 0 0}.imgedit-group h3{font-size:18px}.imgedit-group .dashicons{border:0;line-height:1.2}.imgedit-group-top{margin:5px 0}.imgedit-applyto .imgedit-label{padding:2px 0 0;display:block}.imgedit-help{display:none;font-style:italic;margin-bottom:8px}a.imgedit-help-toggle{text-decoration:none}.form-table td.imgedit-response{padding:0}.imgedit-submit{margin:8px 0}.imgedit-submit-btn{margin-left:20px}.imgedit-wrap .nowrap{white-space:nowrap}span.imgedit-scale-warn{color:red;font-size:20px;font-style:normal;visibility:hidden;vertical-align:middle}.wp_attachment_details{margin-bottom:20px}.imgedit-menu div{border-color:#d5d5d5;background-color:#f1f1f1}.imgedit-menu div:hover{border-color:#c1c1c1;background-color:#eaeaea}.imgedit-menu div.disabled{border-color:#ccc;background-color:#ddd;filter:alpha(opacity=50);opacity:0.5}.bp-media-image-editor-cotnainer{margin-top:35px}.wp_attachment_image .bp-media-image-edit{float:left}.wp_attachment_image .spinner{display:none}.bp-media-image-editor-cotnainer .hidden{display:none}.bp-media-image-editor-cotnainer div.updated{margin:5px 0 15px;background-color:#ffffe0;border-color:#e6db55;padding:0 .6em;border-radius:3px;border-width:1px;border-style:solid}.bp-media-image-editor-cotnainer div.updated p{margin:.5em 0;padding:2px}body article.bp_members.bp_member .entry-content,body div.bp_members.bp_member .entry-content{width:100%}.rtm-media-gallery-uploader{display:none}.rtmedia-uploader .drag-drop{border:4px dashed #DDD;text-align:center;background:#fafafa;overflow:hidden;color:#AAAAAA;margin-top:20px;padding:25px 0}.rtmedia-uploader .drag-drop.dragover{border-color:#83b4d8}.rtmedia-uploader .drag-drop .drag-drop-info{font-size:20px;line-height:24px}.rtmedia-uploader .drag-drop .rtm-select-files span{vertical-align:middle}.rtmedia-uploader .drag-drop .rtm-seperator{margin:0px 20px}.rtmedia-uploader .drag-drop .start-media-upload{display:none;margin-top:20px}.rtmedia-uploader .drag-drop .rtm-file-size-limit{vertical-align:middle;font-size:16px;line-height:24px}.rtm-uploader-main-wrapper .rtm-uploader-tabs{margin-bottom:10px;text-align:left}.rtm-uploader-main-wrapper ul{border-bottom:1px solid #CCC}.rtm-uploader-main-wrapper li{margin:0 0 -1px 10px;display:inline-block;padding:5px 10px;line-height:25px;background-color:#e4e4e4;border:1px solid #CCC}.rtm-uploader-main-wrapper li.active{background:transparent;border-left:1px solid #CCC;border-top:1px solid #CCC;border-right:1px solid #CCC;border-bottom:1px solid #fafafa}.rtm-uploader-main-wrapper li:hover{cursor:pointer}.rtmedia-container .rtmedia-list{margin:10px -5px}.rtmedia-container .rtmedia-list .rtmedia-list-item{float:left;margin:5px;position:relative}.rtmedia-container .rtmedia-list .rtmedia-list-item>a{display:block}.rtmedia-container .rtmedia-list .rtmedia_time{background-color:#000;color:#fff;display:inline-block;font-size:11px;font-weight:bold;line-height:14px;opacity:0.75;padding:0 4px;position:absolute;right:2px;top:2px}.rtmedia-container .rtmedia-list img{vertical-align:top}.rtmedia-container .rtmedia-list .rtmedia-item-title h4{color:#666;font-size:12px;font-weight:normal;margin:5px 0 0;overflow:hidden;text-align:center;text-overflow:ellipsis;white-space:nowrap}.rtm-load-more{background:#eee;text-align:center}.rtmedia-container .rtm-load-more a{border:0;padding:10px 0}.rtm-load-more .rtm-media-loading{padding:10px 0}.rtm-media-options{line-height:1.4;margin-bottom:10px}.rtm-media-options>div{display:inline-block;cursor:pointer}.rtm-media-options .rtm-media-options-list{margin-right:5px;padding-right:10px;position:relative}.rtm-media-options>*{border-right:1px solid #999}.rtm-media-options>*:last-child{border-right:none}.rtm-media-options .dashicons{font-size:inherit;line-height:1.4}.rtmedia-upload-media-link{cursor:pointer}a.rtmedia-upload-media-link{border:none}.rtm-album-privacy span{font-size:16px;display:inline-block;margin:0 20px 20px 20px;vertical-align:top}.rtm-album-privacy label{margin-right:8px}.rtm-album-privacy .dashicons{font-size:16px;line-height:1.6;margin-right:5px}#rtm-media-options-list .rtmedia-delete-album{background:transparent;border:0;color:#fff;font-family:inherit;font-size:inherit;font-weight:inherit;padding:0;text-transform:inherit}#rtm-media-options-list .rtmedia-delete-album:hover{background:transparent;border:0;color:#fff}.rtmedia-single-container button.rtmedia-like{background-color:transparent;color:inherit}#buddypress .mejs-controls button{padding:4px 8px;border:none;background:transparent url("../../../lib/media-element/controls.png") no-repeat}#buddypress .mejs-controls .mejs-play button{background-position:0 0}#buddypress .mejs-controls .mejs-pause button{background-position:0 -16px}#buddypress .mejs-controls .mejs-unmute button{background-position:-16px 0}#buddypress .mejs-controls .mejs-mute button{background-position:-16px -16px}#buddypress .mejs-controls .mejs-fullscreen-button button{background-position:-32px 0}#buddypress .mejs-controls .mejs-unfullscreen button{background-position:-32px -16px}.mejs-container .mejs-controls .mejs-time{padding:10px 3px 0;content:''}.rtmedia-activity-container .mejs-playpause-button.mejs-play button:before,.rtmedia-activity-container .mejs-playpause-button.mejs-pause button:before,.rtmedia-activity-container .mejs-volume-button.mejs-mute button:before,.rtmedia-activity-container .mejs-fullscreen-button button:before,.rtmedia-media .mejs-playpause-button.mejs-play button:before,.rtmedia-media .mejs-playpause-button.mejs-pause button:before,.rtmedia-media .mejs-volume-button.mejs-mute button:before,.rtmedia-media .mejs-fullscreen-button button:before{content:''}@media only screen and (min-width: 1025px){.mfp-content .rtm-lightbox-container{display:table;table-layout:fixed;width:100%}.mfp-content .rtm-mfp-close{background:transparent}.mfp-content .rtm-single-media{display:table-cell;width:66.6667%}.mfp-content .rtm-single-meta{display:table-cell;width:33.3333%;padding:20px;height:473px}.mfp-content .rtm-single-meta .rtmedia-scroll{height:100%;overflow-X:hidden}}.rtl #rtSelectPrivacy{float:left}.rtl .rtmedia-plupload-container{float:right}.rtl .rtm-upload-button-wrapper{float:right}.rtl #whats-new-post-in-box{float:right}.rtl .describe-toggle-off{float:left}.rtl .media-item .pinkynail{float:right}.rtl .media-item .progress{float:left}.rtl .media-item .error-div a.dismiss{float:left}.rtl #find-posts-input{float:right}.rtl #find-posts-search{float:right}.rtl .spinner{float:left}.rtl .wp_attachment_image .button,.rtl .A1B1 .button{float:right}.rtl .wp_attachment_image .spinner,.rtl .A1B1 .spinner{float:right}.rtl .imgedit-menu div{float:right}.rtl .wp_attachment_image .bp-media-image-edit{float:right}.rtl .rtmedia-container .rtmedia-list .rtmedia-list-item{float:right}.rtl #buddypress #rtm-media-options-list .rtm-options .button{float:right}.rtl .rtm-ltb-title{float:right}.rtl .rtm-item-actions{float:left}.rtl .rtm-item-actions>div,.rtl .rtm-item-actions>form{float:right}.rtl .userprofile{float:right}.rtl .rtmedia-actions-before-comments>span{float:right}.rtl .rtmedia-comment-user-pic{float:right}.rtl .rtmedia-media-name{float:right}.rtl #rtmedia-uploader-form .rtm-plupload-list li,.rtl #rtmedia_uploader_filelist li{float:right}.rtl .rtm-page-number{float:right}.rtl .rtm-page-number .rtmedia-page-link{float:right}.rtl .rtm-pagination{float:right}.rtl .rtm-pagination .rtm-paginate{float:left}.rtl .rtm-tabs li{float:right}.rtl .alignleft{float:right}.rtl .alignright{float:left}
app/assets/css/sass/_activity.scss CHANGED
@@ -6,12 +6,11 @@
6
* {
7
&,
8
&:before,
9
- &:after {
10
-webkit-box-sizing: inherit;
11
-moz-box-sizing: inherit;
12
box-sizing: inherit;
13
}
14
-
15
}
16
}
17
@@ -23,13 +22,11 @@
23
24
// hide unnecessory div
25
.rtmedia-activity-container {
26
-
27
.rtmedia-item-actions {
28
display: none;
29
}
30
31
.rtmedia-item-title {
32
-
33
&, a {
34
border: 0;
35
color: $gray;
@@ -41,38 +38,39 @@
41
white-space: nowrap;
42
}
43
}
44
-
45
}
46
47
// Uploader Button
48
#rtmedia-whts-new-upload-container div {
49
- left: 0 !important;
50
- position: absolute;
51
- top: 0 !important;
52
}
53
54
#aw-whats-new-submit,
55
.rtmedia-add-media-button {
56
- display: block; // Remove extra space
57
}
58
59
.rtm-drag-drop-active {
60
- border: 4px dashed green !important;
61
- display: block;
62
- height: 100%;
63
- opacity: 0.5;
64
- z-index: 9999;
65
}
66
67
#rtm-drop-files-title {
68
background: rgba(0, 0, 0, 0.2);
69
- display: none;
70
- font-size: 14px;
71
- height: 100%;
72
- padding: 20px;
73
- position: absolute;
74
- top: 0;
75
- width: 100%;
76
}
77
78
#rtSelectPrivacy {
@@ -80,7 +78,7 @@
80
}
81
82
.rtmedia-plupload-container {
83
- position: relative;
84
float: left;
85
}
86
@@ -106,4 +104,34 @@
106
.mejs-container {
107
margin-bottom: 10px;
108
}
109
- }
6
* {
7
&,
8
&:before,
9
+ &:after {
10
-webkit-box-sizing: inherit;
11
-moz-box-sizing: inherit;
12
box-sizing: inherit;
13
}
14
}
15
}
16
22
23
// hide unnecessory div
24
.rtmedia-activity-container {
25
.rtmedia-item-actions {
26
display: none;
27
}
28
29
.rtmedia-item-title {
30
&, a {
31
border: 0;
32
color: $gray;
38
white-space: nowrap;
39
}
40
}
41
}
42
43
// Uploader Button
44
#rtmedia-whts-new-upload-container div {
45
+ left: 0 !important;
46
+ position: absolute;
47
+ top: 0 !important;
48
}
49
50
#aw-whats-new-submit,
51
.rtmedia-add-media-button {
52
+ display: block;
53
+
54
+ // Remove extra space
55
}
56
57
.rtm-drag-drop-active {
58
+ border: 4px dashed green !important;
59
+ display: block;
60
+ height: 100%;
61
+ opacity: 0.5;
62
+ z-index: 9999;
63
}
64
65
#rtm-drop-files-title {
66
background: rgba(0, 0, 0, 0.2);
67
+ display: none;
68
+ font-size: 14px;
69
+ height: 100%;
70
+ padding: 20px;
71
+ position: absolute;
72
+ top: 0;
73
+ width: 100%;
74
}
75
76
#rtSelectPrivacy {
78
}
79
80
.rtmedia-plupload-container {
81
+ position: relative;
82
float: left;
83
}
84
104
.mejs-container {
105
margin-bottom: 10px;
106
}
107
+ }
108
+
109
+ .previous-pagination {
110
+ float: left;
111
+ margin-top: 10px;
112
+ }
113
+
114
+ .next-pagination {
115
+ float: right;
116
+ margin-top: 10px;
117
+ }
118
+
119
+ @media screen and (max-width: 500px) {
120
+ #activity-stream li .media-type-video {
121
+ width: 100%;
122
+
123
+ .mejs-video {
124
+ max-width: 100%;
125
+ min-width: 100%;
126
+ }
127
+ }
128
+ }
129
+
130
+ //
131
+ #rtmedia_show_all_comment {
132
+ cursor: pointer;
133
+
134
+ &:hover {
135
+ text-decoration: underline;
136
+ }
137
+ }
app/assets/css/sass/_buddypress.scss CHANGED
@@ -48,3 +48,11 @@
48
body.media.buddypress {
49
overflow-y: auto;
50
}
48
body.media.buddypress {
49
overflow-y: auto;
50
}
51
+
52
+ #buddypress input[type=submit]:focus {
53
+ background: #ededed;
54
+ border: 1px solid #bbb;
55
+ color: #555;
56
+ outline: 0;
57
+ text-decoration: none;
58
+ }
app/assets/css/sass/_popup.scss CHANGED
@@ -1,3 +1,14 @@
1
// Additional Styles
2
.mfp-content {
3
.rtm-lightbox-container {
@@ -106,6 +117,14 @@
106
}
107
}
108
109
#buddypress #rtm-media-options-list {
110
.rtm-options {
111
.button {
@@ -293,6 +312,7 @@
293
.dashicons {
294
font-size: 14px;
295
line-height: 1.5;
296
}
297
}
298
1
+ /*
2
+ * popup autocomplete
3
+ */
4
+ #atwho-container {
5
+ #atwho-ground-comment_content {
6
+ .atwho-view {
7
+ z-index: 2147483647;
8
+ }
9
+ }
10
+ }
11
+
12
// Additional Styles
13
.mfp-content {
14
.rtm-lightbox-container {
117
}
118
}
119
120
+ #buddypress #rtm-media-options-list {
121
+ .rtm-options {
122
+ form button {
123
+ font-size: small;
124
+ }
125
+ }
126
+ }
127
+
128
#buddypress #rtm-media-options-list {
129
.rtm-options {
130
.button {
312
.dashicons {
313
font-size: 14px;
314
line-height: 1.5;
315
+ margin-top: -2px;
316
}
317
}
318
app/assets/css/sass/_rtm.scss CHANGED
@@ -438,3 +438,14 @@ table.rtmedia-edit-media-list {
438
.rtm-hide {
439
display: none;
440
}
438
.rtm-hide {
439
display: none;
440
}
441
+
442
+ .rtmedia-list-item {
443
+ .rtmedia-album-media-count {
444
+ position: absolute;
445
+ top: 0;
446
+ right: 0;
447
+ background-color: black;
448
+ color: white;
449
+ padding: 0 5px;
450
+ }
451
+ }
app/assets/js/rtMedia.backbone.js CHANGED
@@ -1,21 +1,21 @@
1
var galleryObj;
2
var nextpage = 2;
3
var upload_sync = false;
4
- var activity_id = - 1;
5
var uploaderObj;
6
var objUploadView;
7
var rtmedia_load_template_flag = true;
8
9
- jQuery( function ( $ ) {
10
11
var o_is_album, o_is_edit_allowed;
12
- if ( typeof ( is_album ) == "undefined" ) {
13
- o_is_album = new Array( "" );
14
} else {
15
- o_is_album = is_album
16
}
17
- if ( typeof ( is_edit_allowed ) == "undefined" ) {
18
- o_is_edit_allowed = new Array( "" )
19
} else {
20
o_is_edit_allowed = is_edit_allowed;
21
}
@@ -25,8 +25,8 @@ jQuery( function ( $ ) {
25
rtMedia = window.rtMedia || { };
26
27
rtMedia.Context = Backbone.Model.extend( {
28
- url: function () {
29
- var url = rtmedia_media_slug + "/";
30
31
if ( ! upload_sync && nextpage > 0 ) {
32
url += 'pg/' + nextpage + '/';
@@ -35,34 +35,34 @@ jQuery( function ( $ ) {
35
return url;
36
},
37
defaults: {
38
- "context": "post",
39
- "context_id": false
40
}
41
} );
42
43
rtMedia.Media = Backbone.Model.extend( {
44
defaults: {
45
- "id": 0,
46
- "blog_id": false,
47
- "media_id": false,
48
- "media_author": false,
49
- "media_title": false,
50
- "album_id": false,
51
- "media_type": "photo",
52
- "activity_id": false,
53
- "privacy": 0,
54
- "views": 0,
55
- "downloads": 0,
56
- "ratings_average": 0,
57
- "ratings_total": 0,
58
- "ratings_count": 0,
59
- "likes": 0,
60
- "dislikes": 0,
61
- "guid": false,
62
- "width": 0,
63
- "height": 0,
64
- "rt_permalink": false,
65
- "duration": "0:00"
66
// "next" : -1,
67
// "prev" : -1
68
}
@@ -71,30 +71,30 @@ jQuery( function ( $ ) {
71
72
rtMedia.Gallery = Backbone.Collection.extend( {
73
model: rtMedia.Media,
74
- url: function () {
75
var temp = window.location.pathname;
76
var url = '';
77
- if ( temp.indexOf( "/" + rtmedia_media_slug + "/" ) == - 1 ) {
78
url = rtmedia_media_slug + '/';
79
} else {
80
- if ( temp.indexOf( 'pg/' ) == - 1 ) {
81
url = temp;
82
} else {
83
- url = window.location.pathname.substr( 0, window.location.pathname.lastIndexOf( "pg/" ) );
84
}
85
}
86
if ( ! upload_sync && nextpage > 1 ) {
87
- if ( url.substr( url.length - 1 ) != "/" ) {
88
- url += "/";
89
}
90
91
url += 'pg/' + nextpage + '/';
92
}
93
return url;
94
},
95
- getNext: function ( page, el, element ) {
96
if ( jQuery( '.rtmedia-no-media-found' ).length > 0 ) {
97
- jQuery( '.rtmedia-no-media-found' ).replaceWith( "<ul class='rtmedia-list rtmedia-list-media'></ul>" );
98
}
99
that = this;
100
if ( rtmedia_load_template_flag == true ) {
@@ -104,7 +104,7 @@ jQuery( function ( $ ) {
104
if ( jQuery( '.rtmedia_gallery_wrapper' ).find( 'input[name=lightbox]' ).length > 0 ) {
105
template_url += '&lightbox=' + jQuery( '.rtmedia_gallery_wrapper' ).find( 'input[name=lightbox]' ).val();
106
}
107
- $( "#rtmedia-gallery-item-template" ).load( template_url, { backbone: true, is_album: o_is_album, is_edit_allowed: o_is_edit_allowed }, function () {
108
rtmedia_load_template_flag = false;
109
that.getNext( page, el, element );
110
} );
@@ -116,36 +116,36 @@ jQuery( function ( $ ) {
116
rtmedia_page: nextpage
117
};
118
if ( el == undefined ) {
119
- el = jQuery( ".rtmedia-list" ).parent().parent();
120
}
121
122
if ( el != undefined ) {
123
if ( element != undefined ) {
124
- $( element ).parent().parent().prevAll( "input[type=hidden]" ).not( "input[name=_wp_http_referer], input[name=rtmedia_media_delete_nonce], input[name=rtmedia_bulk_delete_nonce], input[name=bulk-action], input[name=rtmedia_create_album_nonce], input[name=rtmedia_media_nonce], input[name=rtmedia_upload_nonce], input[name=rtmedia_allow_upload_attribute]" ).each( function ( e ) {
125
- if ( $( this ).attr( "name" ) ) {
126
- query[ $( this ).attr( "name" ) ] = $( this ).val();
127
}
128
} );
129
}
130
131
- $( el ).find( "input[type=hidden]" ).not( "input[name=_wp_http_referer], input[name=rtmedia_media_delete_nonce], input[name=rtmedia_bulk_delete_nonce], input[name=bulk-action], input[name=rtmedia_create_album_nonce], input[name=rtmedia_media_nonce], input[name=rtmedia_upload_nonce], input[name=rtmedia_allow_upload_attribute]" ).each( function ( e ) {
132
- if ( $( this ).attr( "name" ) ) {
133
- query[ $( this ).attr( "name" ) ] = $( this ).val();
134
}
135
} );
136
}
137
138
this.fetch( {
139
data: query,
140
- success: function ( model, response ) {
141
jQuery( '.rtm-media-loading' ).hide();
142
- var list_el = "";
143
144
- if ( typeof ( element ) === "undefined" ) {
145
- if( jQuery( el ).find( '.rtmedia-list' ).length > 0 ) {
146
list_el = jQuery( el ).find( '.rtmedia-list' );
147
} else {
148
- list_el = $( ".rtmedia-list" )[0];
149
}
150
} else {
151
list_el = element.parent().siblings( '.rtmedia-list' );
@@ -154,7 +154,7 @@ jQuery( function ( $ ) {
154
nextpage = response.next;
155
156
if ( nextpage < 1 ) {
157
- if ( typeof el == "object" ) {
158
jQuery( el ).find( '.rtmedia_next_prev' ).children( '#rtMedia-galary-next' ).hide();
159
}
160
//$("#rtMedia-galary-next").show();
@@ -164,8 +164,8 @@ jQuery( function ( $ ) {
164
collection: new rtMedia.Gallery( response.data ),
165
el: list_el
166
} );
167
- //element.show();
168
- jQuery( '.rtmedia-container .rtmedia-list' ).css( 'opacity', '1' );
169
rtMediaHook.call( 'rtmedia_after_gallery_load' );
170
171
jQuery( '.rtmedia-container .rtmedia_next_prev .rtm-pagination' ).remove();
@@ -173,11 +173,16 @@ jQuery( function ( $ ) {
173
jQuery( '.rtmedia-container .rtmedia_next_prev .rtm-media-loading' ).remove();
174
jQuery( '.rtmedia-container .rtmedia_next_prev br' ).remove();
175
jQuery( '.rtmedia-container .rtmedia_next_prev' ).append( response.pagination );
176
}
177
} );
178
}
179
},
180
- reloadView: function ( parent_el ) {
181
upload_sync = true;
182
nextpage = 1;
183
jQuery( '.rtmedia-container .rtmedia-list' ).css( 'opacity', '0.5' );
@@ -188,20 +193,20 @@ jQuery( function ( $ ) {
188
rtMedia.MediaView = Backbone.View.extend( {
189
tagName: 'li',
190
className: 'rtmedia-list-item',
191
- initialize: function () {
192
- this.template = _.template( $( "#rtmedia-gallery-item-template" ).html() );
193
this.model.bind( 'change', this.render );
194
this.model.bind( 'remove', this.unrender );
195
this.render();
196
},
197
- render: function () {
198
$( this.el ).html( this.template( this.model.toJSON() ) );
199
return this.el;
200
},
201
- unrender: function () {
202
$( this.el ).remove();
203
},
204
- remove: function () {
205
this.model.destroy();
206
}
207
} );
@@ -209,11 +214,11 @@ jQuery( function ( $ ) {
209
rtMedia.GalleryView = Backbone.View.extend( {
210
tagName: 'ul',
211
className: 'rtmedia-list',
212
- initialize: function () {
213
- this.template = _.template( $( "#rtmedia-gallery-item-template" ).html() );
214
this.render();
215
},
216
- render: function () {
217
218
that = this;
219
@@ -225,7 +230,7 @@ jQuery( function ( $ ) {
225
$( that.el ).html( '' );
226
}
227
228
- $.each( this.collection.toJSON(), function ( key, media ) {
229
$( that.el ).append( that.template( media ) );
230
} );
231
@@ -236,12 +241,12 @@ jQuery( function ( $ ) {
236
$( that.el ).siblings( '.rtmedia_next_prev' ).children( '#rtMedia-galary-next' ).show();
237
//$("#rtMedia-galary-next").show();
238
}
239
- if ( typeof rtmedia_masonry_layout != "undefined" && rtmedia_masonry_layout == "true" && jQuery( '.rtmedia-container .rtmedia-list.rtm-no-masonry' ).length == 0 ) {
240
rtm_masonry_reload( rtm_masonry_container );
241
}
242
},
243
- appendTo: function ( media ) {
244
- //console.log("append");
245
var mediaView = new rtMedia.MediaView( {
246
model: media
247
} );
@@ -251,11 +256,11 @@ jQuery( function ( $ ) {
251
252
galleryObj = new rtMedia.Gallery();
253
254
- $( "body" ).append( '<script id="rtmedia-gallery-item-template" type="text/template"></script>' );
255
256
- $( document ).on( "click", "#rtMedia-galary-next", function ( e ) {
257
if ( jQuery( '.rtm-media-loading' ).length == 0 ) {
258
- $( this ).before( "<div class='rtm-media-loading'><img src='" + rMedia_loading_media + "' /></div>" );
259
} else {
260
jQuery( '.rtm-media-loading' ).show();
261
}
@@ -264,12 +269,26 @@ jQuery( function ( $ ) {
264
galleryObj.getNext( nextpage, $( this ).parent().parent().parent(), $( this ) );
265
} );
266
267
- $( document ).on( "keypress", "#rtmedia_go_to_num", function( e ) {
268
if ( e.keyCode == 13 ) {
269
e.preventDefault();
270
271
if ( jQuery( '.rtm-media-loading' ).length == 0 ) {
272
- $( '.rtm-pagination' ).before( "<div class='rtm-media-loading'><img src='" + rMedia_loading_media + "' /></div>" );
273
} else {
274
jQuery( '.rtm-media-loading' ).show();
275
}
@@ -286,12 +305,12 @@ jQuery( function ( $ ) {
286
}
287
} );
288
289
- $( document ).on( "click", ".rtmedia-page-link", function ( e ) {
290
/* Get current clicked href value */
291
href = $( this ).attr( 'href' );
292
293
if ( jQuery( '.rtm-media-loading' ).length == 0 ) {
294
- $( '.rtm-pagination' ).before( "<div class='rtm-media-loading'><img src='" + rMedia_loading_media + "' /></div>" );
295
} else {
296
jQuery( '.rtm-media-loading' ).show();
297
}
@@ -300,7 +319,7 @@ jQuery( function ( $ ) {
300
if ( $( this ).data( 'page-type' ) == 'page' ) {
301
nextpage = $( this ).data( 'page' );
302
} else if ( $( this ).data( 'page-type' ) == 'prev' ) {
303
- if ( nextpage == - 1 ) {
304
nextpage = parseInt( $( '#rtmedia_last_page' ).val() ) - 1;
305
} else {
306
nextpage -= 2;
@@ -323,11 +342,11 @@ jQuery( function ( $ ) {
323
galleryObj.getNext( nextpage, $( this ).parent().parent().parent().parent().parent(), $( this ).parent().parent() );
324
}
325
change_rtBrowserAddressUrl( href, '' );
326
-
327
} );
328
329
- if ( window.location.pathname.indexOf( rtmedia_media_slug ) != - 1 ) {
330
- var tempNext = window.location.pathname.substring( window.location.pathname.lastIndexOf( "pg/" ) + 5, window.location.pathname.lastIndexOf( "/" ) );
331
if ( isNaN( tempNext ) === false ) {
332
nextpage = parseInt( tempNext ) + 1;
333
}
@@ -335,42 +354,42 @@ jQuery( function ( $ ) {
335
336
window.UploadView = Backbone.View.extend( {
337
events: {
338
- "click #rtMedia-start-upload": "uploadFiles"
339
},
340
- initialize: function ( config ) {
341
this.uploader = new plupload.Uploader( config );
342
},
343
- render: function () {
344
345
},
346
- initUploader: function ( a ) {
347
- if ( typeof ( a ) !== "undefined" ) {
348
- a = false;// if rtmediapro widget calls the function, dont show max size note.
349
} this.uploader.init();
350
//The plupload HTML5 code gives a negative z-index making add files button unclickable
351
- $( ".plupload.html5" ).css( {
352
zIndex: 0
353
} );
354
- $( "#rtMedia-upload-button" ).css( {
355
zIndex: 2
356
} );
357
if ( a !== false ) {
358
window.file_size_info = rtmedia_max_file_msg + this.uploader.settings.max_file_size_msg;
359
- if ( rtmedia_version_compare( rtm_wp_version, "3.9" ) ) { // plupload getting updated in 3.9
360
file_extn = this.uploader.settings.filters.mime_types[0].extensions;
361
} else {
362
file_extn = this.uploader.settings.filters[0].extensions;
363
}
364
- window.file_extn_info = rtmedia_allowed_file_formats + " : " + file_extn.split( ',' ).join( ', ' );
365
366
- var info = window.file_size_info + "\n" + window.file_extn_info;
367
- $( ".rtm-file-size-limit" ).attr( 'title', info );
368
//$("#rtMedia-upload-button").after("<span>( <strong>" + rtmedia_max_file_msg + "</strong> "+ this.uploader.settings.max_file_size_msg + ")</span>");
369
}
370
371
return this;
372
},
373
- uploadFiles: function ( e ) {
374
if ( e != undefined ) {
375
e.preventDefault();
376
}
@@ -380,17 +399,17 @@ jQuery( function ( $ ) {
380
381
} );
382
383
- if ( $( "#rtMedia-upload-button" ).length > 0 ) {
384
- if ( typeof rtmedia_upload_type_filter == "object" && rtmedia_upload_type_filter.length > 0 ) {
385
rtMedia_plupload_config.filters[0].extensions = rtmedia_upload_type_filter.join();
386
}
387
uploaderObj = new UploadView( rtMedia_plupload_config );
388
uploaderObj.initUploader();
389
390
- uploaderObj.uploader.bind( 'UploadComplete', function ( up, files ) {
391
- activity_id = - 1;
392
var hook_respo = rtMediaHook.call( 'rtmedia_js_after_files_uploaded' );
393
- if ( typeof rtmedia_gallery_reload_on_upload != "undefined" && rtmedia_gallery_reload_on_upload == '1' ) { //reload gallery view when upload completes if enabled( by default enabled)
394
if ( hook_respo != false ) {
395
galleryObj.reloadView();
396
}
@@ -401,20 +420,20 @@ jQuery( function ( $ ) {
401
window.onbeforeunload = null;
402
} );
403
404
- uploaderObj.uploader.bind( 'FilesAdded', function ( up, files ) {
405
var upload_size_error = false;
406
- var upload_error = "";
407
- var upload_error_sep = "";
408
var upload_remove_array = [ ];
409
- $.each( files, function ( i, file ) {
410
- //set file title along with file
411
rtm_file_name_array = file.name.split( '.' );
412
file.title = rtm_file_name_array[0];
413
414
- var hook_respo = rtMediaHook.call( 'rtmedia_js_file_added', [ up, file, "#rtmedia_uploader_filelist" ] );
415
416
if ( hook_respo == false ) {
417
- file.status = - 1;
418
upload_remove_array.push( file.id );
419
return true;
420
}
@@ -428,8 +447,8 @@ jQuery( function ( $ ) {
428
if ( uploaderObj.uploader.settings.max_file_size < file.size ) {
429
return true;
430
}
431
- var tmp_array = file.name.split( "." );
432
- if ( rtmedia_version_compare( rtm_wp_version, "3.9" ) ) { // plupload getting updated in 3.9
433
var ext_array = uploaderObj.uploader.settings.filters.mime_types[0].extensions.split( ',' );
434
} else {
435
var ext_array = uploaderObj.uploader.settings.filters[0].extensions.split( ',' );
@@ -437,14 +456,14 @@ jQuery( function ( $ ) {
437
if ( tmp_array.length > 1 ) {
438
var ext = tmp_array[tmp_array.length - 1];
439
ext = ext.toLowerCase();
440
- if ( jQuery.inArray( ext, ext_array ) === - 1 ) {
441
return true;
442
}
443
} else {
444
return true;
445
}
446
447
- if ( rtmedia_version_compare( rtm_wp_version, "3.9" ) ) { // plupload getting updated in 3.9
448
uploaderObj.uploader.settings.filters.mime_types[0].title;
449
} else {
450
uploaderObj.uploader.settings.filters[0].title;
@@ -454,16 +473,16 @@ jQuery( function ( $ ) {
454
rtmedia_selected_file_list( plupload, file, '', '' );
455
456
//Delete Function
457
- $( "#" + file.id + " .plupload_delete .remove-from-queue" ).click( function ( e ) {
458
e.preventDefault();
459
uploaderObj.uploader.removeFile( up.getFile( file.id ) );
460
- $( "#" + file.id ).remove();
461
rtMediaHook.call( 'rtmedia_js_file_remove', [ up, file ] );
462
return false;
463
} );
464
465
// To change the name of the uploading file
466
- $( "#label_" + file.id ).click( function ( e ) {
467
e.preventDefault();
468
469
rtm_file_label = this;
@@ -484,7 +503,7 @@ jQuery( function ( $ ) {
484
jQuery( rtm_file_label ).hide();
485
jQuery( rtm_file_label ).siblings( '.plupload_file_name_wrapper' ).hide();
486
487
- // show/create text box to edit media title
488
if ( jQuery( rtm_file_title_input ).length === 0 ) {
489
jQuery( rtm_file_label ).parent( '.plupload_file_name' ).prepend( '<div id="' + rtm_file_title_wrapper_id + '" class="rtm-upload-edit-title-wrapper"><label>' + rtmedia_edit_media_info_upload.title + '</label><input type="text" class="rtm-upload-edit-title" id="' + rtm_file_title_id + '" value="' + file.title + '" style="width: 75%;" /></div><div id="' + rtm_file_desc_wrapper_id + '" class="rtm-upload-edit-desc-wrapper"><label>' + rtmedia_edit_media_info_upload.description + '</label><textarea class="rtm-upload-edit-desc" id="' + rtm_file_desc_id + '"></textarea></div><span id="' + rtm_file_save_id + '" title="Save Change" class="rtmicon dashicons dashicons-yes"></span>' );
490
} else {
@@ -495,32 +514,49 @@ jQuery( function ( $ ) {
495
496
jQuery( rtm_file_title_input ).focus();
497
498
- // set media title and description in file object
499
- jQuery( rtm_file_save_el ).click( function(){
500
- var file_title_val = jQuery( rtm_file_title_input ).val();
501
- var file_desc_val = jQuery( rtm_file_desc_input ).val();
502
- var file_name_wrapper_el = jQuery( rtm_file_label ).siblings( '.plupload_file_name_wrapper' );
503
504
- if ( file_title_val != '' ) {
505
- file_name_wrapper_el.text( file_title_val + "." + rtm_file_name_array[ 1 ] );
506
- file.title = file_title_val;
507
- }
508
509
- if ( file_desc_val != '' ) {
510
- file.description = file_desc_val;
511
- }
512
513
- jQuery( rtm_file_title_wrapper ).hide();
514
- jQuery( rtm_file_desc_wrapper ).hide();
515
- file_name_wrapper_el.show();
516
- jQuery( rtm_file_label ).siblings( '.plupload_file_name_wrapper' )
517
- jQuery( rtm_file_label ).show();
518
- jQuery( this ).hide();
519
} );
520
} );
521
} );
522
523
- $.each( upload_remove_array, function ( i, rfile ) {
524
if ( up.getFile( rfile ) ) {
525
up.removeFile( up.getFile( rfile ) );
526
}
@@ -538,28 +574,28 @@ jQuery( function ( $ ) {
538
539
} );
540
541
- uploaderObj.uploader.bind( 'Error', function ( up, err ) {
542
543
- if ( err.code == - 600 ) { //file size error // if file size is greater than server's max allowed size
544
var tmp_array;
545
var ext = tr = '';
546
- tmp_array = err.file.name.split( "." );
547
if ( tmp_array.length > 1 ) {
548
ext = tmp_array[tmp_array.length - 1];
549
- if ( ! ( typeof ( up.settings.upload_size ) != "undefined" && typeof ( up.settings.upload_size[ext] ) != "undefined" && typeof ( up.settings.upload_size[ext]['size'] ) ) ) {
550
rtmedia_selected_file_list( plupload, err.file, up, err );
551
}
552
}
553
} else {
554
555
- if ( err.code == - 601 ) { // file extension error
556
err.message = rtmedia_file_extension_error_msg;
557
}
558
559
rtmedia_selected_file_list( plupload, err.file, '', err );
560
}
561
562
- jQuery( '.plupload_delete' ).on( 'click', function ( e ) {
563
e.preventDefault();
564
jQuery( this ).parent().parent( 'li' ).remove();
565
} );
@@ -567,7 +603,7 @@ jQuery( function ( $ ) {
567
568
} );
569
570
- jQuery( '.start-media-upload' ).on( 'click', function ( e ) {
571
e.preventDefault();
572
573
/**
@@ -583,43 +619,43 @@ jQuery( function ( $ ) {
583
}
584
} );
585
586
- uploaderObj.uploader.bind( 'UploadProgress', function ( up, file ) {
587
//$("#" + file.id + " .plupload_file_status").html(file.percent + "%");
588
//$( "#" + file.id + " .plupload_file_status" ).html( rtmedia_uploading_msg + '( ' + file.percent + '% )' );
589
- $( "#" + file.id + " .plupload_file_status" ).html( '<div class="plupload_file_progress ui-widget-header" style="width: ' + file.percent + '%;"></div>' );
590
- $( "#" + file.id ).addClass( 'upload-progress' );
591
if ( file.percent == 100 ) {
592
- $( "#" + file.id ).toggleClass( 'upload-success' );
593
}
594
595
- window.onbeforeunload = function ( evt ) {
596
var message = rtmedia_upload_progress_error_message;
597
return message;
598
};
599
} );
600
601
- uploaderObj.uploader.bind( 'BeforeUpload', function ( up, file ) {
602
up.settings.multipart_params.title = file.title.split( '.' )[ 0 ];
603
604
- if ( typeof file.description != "undefined" ) {
605
up.settings.multipart_params.description = file.description;
606
} else {
607
up.settings.multipart_params.description = '';
608
}
609
610
- var privacy = $( "#rtm-file_upload-ui select.privacy" ).val();
611
if ( privacy !== undefined ) {
612
- up.settings.multipart_params.privacy = $( "#rtm-file_upload-ui select.privacy" ).val();
613
}
614
- if ( jQuery( "#rt_upload_hf_redirect" ).length > 0 ) {
615
up.settings.multipart_params.redirect = up.files.length;
616
}
617
- jQuery( "#rtmedia-uploader-form input[type=hidden]" ).each( function () {
618
- up.settings.multipart_params[$( this ).attr( "name" )] = $( this ).val();
619
} );
620
up.settings.multipart_params.activity_id = activity_id;
621
if ( $( '#rtmedia-uploader-form .rtmedia-user-album-list' ).length > 0 ) {
622
- up.settings.multipart_params.album_id = $( '#rtmedia-uploader-form .rtmedia-user-album-list' ).find( ":selected" ).val();
623
} else if ( $( '#rtmedia-uploader-form .rtmedia-current-album' ).length > 0 ) {
624
up.settings.multipart_params.album_id = $( '#rtmedia-uploader-form .rtmedia-current-album' ).val();
625
}
@@ -627,13 +663,14 @@ jQuery( function ( $ ) {
627
rtMediaHook.call( 'rtmedia_js_before_file_upload', [up, file] );
628
} );
629
630
- uploaderObj.uploader.bind( 'FileUploaded', function ( up, file, res ) {
631
- if ( /MSIE (\d+\.\d+);/.test( navigator.userAgent ) ) { //test for MSIE x.x;
632
- var ieversion = new Number( RegExp.$1 ) // capture x.x portion and store as a number
633
634
if ( ieversion < 10 ) {
635
- if ( typeof res.response !== "undefined" ) {
636
- res.status = 200; }
637
}
638
}
639
var rtnObj;
@@ -645,27 +682,26 @@ jQuery( function ( $ ) {
645
if ( rtnObj.permalink != '' ) {
646
$( "#" + file.id + " .plupload_file_name" ).html( "<a href='" + rtnObj.permalink + "' target='_blank' title='" + rtnObj.permalink + "'>" + file.title.substring( 0, 40 ).replace( /(<([^>]+)>)/ig, "" ) + "</a>" );
647
$( "#" + file.id + " .plupload_media_edit" ).html( "<a href='" + rtnObj.permalink + "edit' target='_blank'><span title='" + rtmedia_edit_media + "'><i class='dashicons dashicons-edit rtmicon'></i> " + rtmedia_edit + "</span></a>" );
648
- $( "#" + file.id + " .plupload_delete" ).html( "<span id='" + rtnObj.media_id + "' class='rtmedia-delete-uploaded-media' title='" + rtmedia_delete + "'>&times;</span>" );
649
}
650
651
} catch ( e ) {
652
- // console.log('Invalid Activity ID');
653
}
654
if ( res.status == 200 || res.status == 302 ) {
655
if ( uploaderObj.upload_count == undefined ) {
656
uploaderObj.upload_count = 1;
657
} else {
658
- uploaderObj.upload_count ++;
659
}
660
661
- if ( uploaderObj.upload_count == up.files.length && jQuery( "#rt_upload_hf_redirect" ).length > 0 && jQuery.trim( rtnObj.redirect_url.indexOf( "http" ) == 0 ) ) {
662
window.location = rtnObj.redirect_url;
663
}
664
665
- $( "#" + file.id + " .plupload_file_status" ).html( rtmedia_uploaded_msg );
666
rtMediaHook.call( 'rtmedia_js_after_file_upload', [ up, file, res.response ] );
667
} else {
668
- $( "#" + file.id + " .plupload_file_status" ).html( rtmedia_upload_failed_msg );
669
}
670
671
files = up.files;
@@ -673,26 +709,26 @@ jQuery( function ( $ ) {
673
674
} );
675
676
- uploaderObj.uploader.refresh();//refresh the uploader for opera/IE fix on media page
677
678
- $( "#rtMedia-start-upload" ).click( function ( e ) {
679
uploaderObj.uploadFiles( e );
680
} );
681
- $( "#rtMedia-start-upload" ).hide();
682
683
- jQuery( document ).on( 'click', '#rtm_show_upload_ui', function () {
684
jQuery( '#rtm-media-gallery-uploader' ).slideToggle();
685
- uploaderObj.uploader.refresh();//refresh the uploader for opera/IE fix on media page
686
jQuery( '#rtm_show_upload_ui' ).toggleClass( 'primary' );
687
} );
688
} else {
689
- jQuery( document ).on( 'click', '#rtm_show_upload_ui', function () {
690
jQuery( '#rtm-media-gallery-uploader' ).slideToggle();
691
jQuery( '#rtm_show_upload_ui' ).toggleClass( 'primary' );
692
} );
693
}
694
695
- jQuery( document ).on( 'click', '.plupload_delete .rtmedia-delete-uploaded-media', function () {
696
var that = $( this );
697
if ( confirm( rtmedia_delete_uploaded_media ) ) {
698
var nonce = $( '#rtmedia-upload-container #rtmedia_media_delete_nonce' ).val();
@@ -701,9 +737,9 @@ jQuery( function ( $ ) {
701
action: 'delete_uploaded_media',
702
nonce: nonce,
703
media_id: media_id
704
- }
705
706
- $.post( ajaxurl, data, function ( response ) {
707
if ( response == '1' ) {
708
that.closest( 'tr' ).remove();
709
$( '#' + media_id ).remove();
@@ -716,27 +752,32 @@ jQuery( function ( $ ) {
716
717
/** Activity Update Js **/
718
719
- jQuery( document ).ready( function ( $ ) {
720
-
721
- //handling the "post update: button on activity page
722
- jQuery( '#aw-whats-new-submit' ).removeAttr( 'disabled' );
723
- jQuery( document ).on( "blur", '#whats-new', function () {
724
- setTimeout( function () {
725
jQuery( '#aw-whats-new-submit' ).removeAttr( 'disabled' );
726
}, 100 );
727
} );
728
- jQuery( '#aw-whats-new-submit' ).on( 'click', function ( e ) {
729
- setTimeout( function () {
730
jQuery( '#aw-whats-new-submit' ).removeAttr( 'disabled' );
731
}, 100 );
732
- } );
733
734
- // when user changes the value in activity "post in" dropdown, hide the privacy dropdown and show when posting in profile.
735
- jQuery( '#whats-new-post-in' ).on( 'change', function ( e ) {
736
if ( jQuery( this ).val() == '0' ) {
737
- jQuery( "#rtmedia-action-update .privacy" ).prop( 'disabled', false ).show();
738
} else {
739
- jQuery( "#rtmedia-action-update .privacy" ).prop( 'disabled', true ).hide();
740
}
741
} );
742
@@ -745,15 +786,15 @@ jQuery( document ).ready( function ( $ ) {
745
}
746
var activity_attachemnt_ids = [ ];
747
748
- if ( $( "#rtmedia-add-media-button-post-update" ).length > 0 ) {
749
objUploadView = new UploadView( rtMedia_update_plupload_config );
750
objUploadView.initUploader();
751
752
- setTimeout( function () {
753
- if ( $( "#rtmedia-add-media-button-post-update" ).length > 0 ) {
754
- $( "#whats-new-options" ).prepend( $( ".rtmedia-plupload-container" ) );
755
- if ( $( "#rtm-file_upload-ui .privacy" ).length > 0 ) {
756
- $( ".rtmedia-plupload-container" ).append( $( "#rtm-file_upload-ui .privacy" ) );
757
}
758
$( '#rtmedia-whts-new-upload-container > div' ).css( 'top', '0' );
759
$( '#rtmedia-whts-new-upload-container > div' ).css( 'left', '0' );
@@ -764,31 +805,31 @@ jQuery( document ).ready( function ( $ ) {
764
$( '#whats-new-options' ).append( $( '.rtmedia-uploader-div' ) );
765
}
766
767
- $( "#whats-new-form" ).on( 'click', '#rtmedia-add-media-button-post-update', function ( e ) {
768
objUploadView.uploader.refresh();
769
$( '#rtmedia-whts-new-upload-container > div' ).css( 'top', '0' );
770
$( '#rtmedia-whts-new-upload-container > div' ).css( 'left', '0' );
771
772
//Enable 'post update' button when media get select
773
- $( '#aw-whats-new-submit' ).prop( "disabled", false );
774
} );
775
- //whats-new-post-in
776
777
objUploadView.upload_remove_array = [ ];
778
779
- objUploadView.uploader.bind( 'FilesAdded', function ( upl, rfiles ) {
780
//$("#aw-whats-new-submit").attr('disabled', 'disabled');
781
782
- $.each( rfiles, function ( i, file ) {
783
784
- //set file title along with file
785
rtm_file_name_array = file.name.split( '.' );
786
file.title = rtm_file_name_array[0];
787
788
- var hook_respo = rtMediaHook.call( 'rtmedia_js_file_added', [ upl, file, "#rtmedia_uploader_filelist" ] );
789
790
if ( hook_respo == false ) {
791
- file.status = - 1;
792
objUploadView.upload_remove_array.push( file.id );
793
return true;
794
}
@@ -797,9 +838,9 @@ jQuery( document ).ready( function ( $ ) {
797
return true;
798
}
799
800
- var tmp_array = file.name.split( "." );
801
802
- if ( rtmedia_version_compare( rtm_wp_version, "3.9" ) ) { // plupload getting updated in 3.9
803
var ext_array = objUploadView.uploader.settings.filters.mime_types[0].extensions.split( ',' );
804
} else {
805
var ext_array = objUploadView.uploader.settings.filters[0].extensions.split( ',' );
@@ -807,7 +848,7 @@ jQuery( document ).ready( function ( $ ) {
807
if ( tmp_array.length > 1 ) {
808
var ext = tmp_array[tmp_array.length - 1];
809
ext = ext.toLowerCase();
810
- if ( jQuery.inArray( ext, ext_array ) === - 1 ) {
811
return true;
812
}
813
} else {
@@ -818,26 +859,28 @@ jQuery( document ).ready( function ( $ ) {
818
819
jQuery( '#whats-new-content' ).css( 'padding-bottom', '0px' );
820
821
- $( "#" + file.id + " .plupload_delete" ).click( function ( e ) {
822
e.preventDefault();
823
objUploadView.uploader.removeFile( upl.getFile( file.id ) );
824
- $( "#" + file.id ).remove();
825
return false;
826
} );
827
828
// To change the name of the uploading file
829
- $( "#label_" + file.id ).click( function ( e ) {
830
e.preventDefault();
831
832
rtm_file_label = this;
833
834
rtm_file_title_id = 'text_' + file.id;
835
rtm_file_title_input = '#' + rtm_file_title_id;
836
rtm_file_title_wrapper_id = 'rtm_title_wp_' + file.id;
837
rtm_file_title_wrapper = '#' + rtm_file_title_wrapper_id;
838
839
rtm_file_desc_id = 'rtm_desc_' + file.id;
840
rtm_file_desc_input = '#' + rtm_file_desc_id;
841
rtm_file_desc_wrapper_id = 'rtm_desc_wp_' + file.id;
842
rtm_file_desc_wrapper = '#' + rtm_file_desc_wrapper_id;
843
@@ -847,7 +890,7 @@ jQuery( document ).ready( function ( $ ) {
847
jQuery( rtm_file_label ).hide();
848
jQuery( rtm_file_label ).siblings( '.plupload_file_name_wrapper' ).hide();
849
850
- // show/create text box to edit media title
851
if ( jQuery( rtm_file_title_input ).length === 0 ) {
852
jQuery( rtm_file_label ).parent( '.plupload_file_name' ).prepend( '<div id="' + rtm_file_title_wrapper_id + '" class="rtm-upload-edit-title-wrapper"><label>' + rtmedia_edit_media_info_upload.title + '</label><input type="text" class="rtm-upload-edit-title" id="' + rtm_file_title_id + '" value="' + file.title + '" style="width: 75%;" /></div><div id="' + rtm_file_desc_wrapper_id + '" class="rtm-upload-edit-desc-wrapper"><label>' + rtmedia_edit_media_info_upload.description + '</label><textarea class="rtm-upload-edit-desc" id="' + rtm_file_desc_id + '"></textarea></div><span id="' + rtm_file_save_id + '" title="Save Change" class="rtmicon dashicons dashicons-yes"></span>' );
853
} else {
@@ -858,55 +901,89 @@ jQuery( document ).ready( function ( $ ) {
858
859
jQuery( rtm_file_title_input ).focus();
860
861
- jQuery( rtm_file_save_el ).click( function(){
862
- var file_title_val = jQuery( rtm_file_title_input ).val();
863
- var file_desc_val = jQuery( rtm_file_desc_input ).val();
864
- var file_name_wrapper_el = jQuery( rtm_file_label ).siblings( '.plupload_file_name_wrapper' );
865
866
- if ( file_title_val != '' ) {
867
- file_name_wrapper_el.text( file_title_val + "." + rtm_file_name_array[ 1 ] );
868
- file.title = file_title_val;
869
- }
870
871
- if ( file_desc_val != '' ) {
872
- file.description = file_desc_val;
873
- }
874
875
- jQuery( rtm_file_title_wrapper ).hide();
876
- jQuery( rtm_file_desc_wrapper ).hide();
877
- file_name_wrapper_el.show();
878
- jQuery( rtm_file_label ).siblings( '.plupload_file_name_wrapper' )
879
- jQuery( rtm_file_label ).show();
880
- jQuery( this ).hide();
881
- } );
882
} );
883
} );
884
885
- $.each( objUploadView.upload_remove_array, function ( i, rfile ) {
886
if ( upl.getFile( rfile ) ) {
887
upl.removeFile( upl.getFile( rfile ) );
888
}
889
} );
890
891
- if ( typeof rtmedia_direct_upload_enabled != 'undefined' && rtmedia_direct_upload_enabled == '1' && jQuery.trim( jQuery( "#whats-new" ).val() ) != "" ) {
892
//Call upload event direct when direct upload is enabled (removed UPLOAD button and its triggered event)
893
var allow_upload = rtMediaHook.call( 'rtmedia_js_upload_file', true );
894
895
if ( allow_upload == false ) {
896
return false;
897
}
898
-
899
objUploadView.uploadFiles();
900
}
901
} );
902
903
- objUploadView.uploader.bind( 'FileUploaded', function ( up, file, res ) {
904
- if ( /MSIE (\d+\.\d+);/.test( navigator.userAgent ) ) { //test for MSIE x.x;
905
- var ieversion = new Number( RegExp.$1 ) // capture x.x portion and store as a number
906
907
if ( ieversion < 10 ) {
908
try {
909
- if ( typeof JSON.parse( res.response ) !== "undefined" ) {
910
res.status = 200;
911
}
912
} catch ( e ) {
@@ -917,11 +994,11 @@ jQuery( document ).ready( function ( $ ) {
917
if ( res.status == 200 ) {
918
try {
919
var objIds = JSON.parse( res.response );
920
- $.each( objIds, function ( key, val ) {
921
activity_attachemnt_ids.push( val );
922
- if ( $( "#whats-new-form" ).find( "#rtmedia_attached_id_" + val ).length < 1 ) {
923
- $( "#whats-new-form" ).append( "<input type='hidden' name='rtMedia_attached_files[]' data-mode='rtMedia-update' id='rtmedia_attached_id_" + val + "' value='"
924
- + val + "' />" );
925
}
926
} );
927
} catch ( e ) {
@@ -931,28 +1008,28 @@ jQuery( document ).ready( function ( $ ) {
931
}
932
} );
933
934
- objUploadView.uploader.bind( 'Error', function ( up, err ) {
935
936
- if ( err.code == - 600 ) { //file size error // if file size is greater than server's max allowed size
937
var tmp_array;
938
var ext = tr = '';
939
- tmp_array = err.file.name.split( "." );
940
if ( tmp_array.length > 1 ) {
941
942
ext = tmp_array[tmp_array.length - 1];
943
- if ( ! ( typeof ( up.settings.upload_size ) != "undefined" && typeof ( up.settings.upload_size[ext] ) != "undefined" && ( up.settings.upload_size[ext]["size"] < 1 || ( up.settings.upload_size[ext]["size"] * 1024 * 1024 ) >= err.file.size ) ) ) {
944
rtmedia_selected_file_list( plupload, err.file, up, err );
945
}
946
}
947
} else {
948
- if ( err.code == - 601 ) { // file extension error
949
err.message = rtmedia_file_extension_error_msg;
950
}
951
952
rtmedia_selected_file_list( plupload, err.file, '', err );
953
}
954
955
- jQuery( '.plupload_delete' ).on( 'click', function ( e ) {
956
e.preventDefault();
957
jQuery( this ).parent().parent( 'li' ).remove();
958
} );
@@ -961,70 +1038,72 @@ jQuery( document ).ready( function ( $ ) {
961
962
} );
963
964
- objUploadView.uploader.bind( 'BeforeUpload', function ( up, files ) {
965
966
- $.each( objUploadView.upload_remove_array, function ( i, rfile ) {
967
if ( up.getFile( rfile ) ) {
968
- up.removeFile( up.getFile( rfile ) ); }
969
} );
970
971
var object = '';
972
- var item_id = jQuery( "#whats-new-post-in" ).val();
973
if ( item_id == undefined ) {
974
- item_id = 0; }
975
if ( item_id > 0 ) {
976
- object = "group";
977
} else {
978
- object = "profile";
979
}
980
981
up.settings.multipart_params.context = object;
982
up.settings.multipart_params.context_id = item_id;
983
up.settings.multipart_params.title = files.title.split( '.' )[ 0 ];
984
985
- if ( typeof files.description != "undefined" ) {
986
up.settings.multipart_params.description = files.description;
987
} else {
988
up.settings.multipart_params.description = '';
989
}
990
991
- // if privacy dropdown is not disabled, then get the privacy value of the update
992
- if ( jQuery( "select.privacy" ).prop( 'disabled' ) === false ) {
993
- up.settings.multipart_params.privacy = jQuery( "select.privacy" ).val();
994
}
995
} );
996
997
- objUploadView.uploader.bind( 'UploadComplete', function ( up, files ) {
998
media_uploading = true;
999
- $( "#aw-whats-new-submit" ).click();
1000
$( '#rtmedia_uploader_filelist li.plupload_queue_li' ).remove();
1001
//$("#aw-whats-new-submit").removeAttr('disabled');
1002
window.onbeforeunload = null;
1003
} );
1004
1005
- objUploadView.uploader.bind( 'UploadProgress', function ( up, file ) {
1006
//$( "#" + file.id + " .plupload_file_status" ).html( rtmedia_uploading_msg + '( ' + file.percent + '% )' );
1007
- $( "#" + file.id + " .plupload_file_status" ).html( '<div class="plupload_file_progress ui-widget-header" style="width: ' + file.percent + '%;"></div>' );
1008
- $( "#" + file.id ).addClass( 'upload-progress' );
1009
if ( file.percent == 100 ) {
1010
- $( "#" + file.id ).toggleClass( 'upload-success' );
1011
}
1012
1013
- window.onbeforeunload = function ( evt ) {
1014
var message = rtmedia_upload_progress_error_message;
1015
return message;
1016
};
1017
} );
1018
1019
- $( "#rtMedia-start-upload" ).hide();
1020
1021
- var change_flag = false
1022
var media_uploading = false;
1023
1024
- $.ajaxPrefilter( function ( options, originalOptions, jqXHR ) {
1025
// Modify options, control originalOptions, store jqXHR, etc
1026
try {
1027
- if ( originalOptions.data == null || typeof ( originalOptions.data ) == "undefined" || typeof ( originalOptions.data.action ) == "undefined" ) {
1028
return true;
1029
}
1030
} catch ( e ) {
@@ -1034,7 +1113,7 @@ jQuery( document ).ready( function ( $ ) {
1034
if ( originalOptions.data.action == 'post_update' || originalOptions.data.action == 'activity_widget_filter' ) {
1035
var temp = activity_attachemnt_ids;
1036
while ( activity_attachemnt_ids.length > 0 ) {
1037
- options.data += "&rtMedia_attached_files[]=" + activity_attachemnt_ids.pop();
1038
}
1039
1040
var dynamic_privacy = '';
@@ -1045,11 +1124,11 @@ jQuery( document ).ready( function ( $ ) {
1045
dynamic_privacy = jQuery( 'input[name="privacy"]' ).val();
1046
}
1047
1048
- options.data += "&rtmedia-privacy=" + dynamic_privacy;
1049
activity_attachemnt_ids = temp;
1050
1051
var orignalSuccess = originalOptions.success;
1052
- options.beforeSend = function () {
1053
/**
1054
* This hook is added for rtMedia Upload Terms plugin to check if it is checked or not for activity
1055
*/
@@ -1063,19 +1142,31 @@ jQuery( document ).ready( function ( $ ) {
1063
}
1064
1065
if ( originalOptions.data.action == 'post_update' ) {
1066
- if ( $.trim( $( "#whats-new" ).val() ) == "" && objUploadView.uploader.files.length > 0 ) {
1067
/*
1068
- *Added $nbsp; as activity text to post activity without TEXT
1069
* Disabled TextBox color(transparent)
1070
*/
1071
- $( "#whats-new" ).css( 'color', 'transparent' );
1072
- $( "#whats-new" ).val( '&nbsp;' );
1073
}
1074
}
1075
if ( ! media_uploading && objUploadView.uploader.files.length > 0 ) {
1076
- $( "#whats-new-post-in" ).attr( 'disabled', 'disabled' );
1077
- $( "#rtmedia-add-media-button-post-update" ).attr( 'disabled', 'disabled' );
1078
- objUploadView.uploadFiles()
1079
media_uploading = true;
1080
return false;
1081
} else {
@@ -1083,21 +1174,21 @@ jQuery( document ).ready( function ( $ ) {
1083
return true;
1084
}
1085
1086
- }
1087
- options.success = function ( response ) {
1088
orignalSuccess( response );
1089
if ( response[0] + response[1] == '-1' ) {
1090
//Error
1091
1092
} else {
1093
if ( originalOptions.data.action == 'activity_widget_filter' ) {
1094
- $( "div.activity" ).bind( "fadeIn", function () {
1095
apply_rtMagnificPopup( jQuery( '.rtmedia-list-media, .rtmedia-activity-container ul.rtmedia-list, #bp-media-list,.widget-item-listing,.bp-media-sc-list, li.media.album_updated ul,ul.bp-media-list-media, li.activity-item div.activity-content div.activity-inner div.bp_media_content' ) );
1096
rtMediaHook.call( 'rtmedia_js_after_activity_added', [ ] );
1097
} );
1098
- $( "div.activity" ).fadeIn( 100 );
1099
}
1100
- jQuery( "input[data-mode=rtMedia-update]" ).remove();
1101
while ( objUploadView.uploader.files.pop() != undefined ) {
1102
}
1103
objUploadView.uploader.refresh();
@@ -1106,11 +1197,11 @@ jQuery( document ).ready( function ( $ ) {
1106
//$("#div-attache-rtmedia").hide();
1107
apply_rtMagnificPopup( jQuery( '.rtmedia-list-media, .rtmedia-activity-container ul.rtmedia-list, #bp-media-list,.widget-item-listing,.bp-media-sc-list, li.media.album_updated ul,ul.bp-media-list-media, li.activity-item div.activity-content div.activity-inner div.bp_media_content' ) );
1108
jQuery( 'ul.activity-list li.rtmedia_update:first-child .wp-audio-shortcode, ul.activity-list li.rtmedia_update:first-child .wp-video-shortcode' ).mediaelementplayer( {
1109
- // if the <video width> is not specified, this is the default
1110
defaultVideoWidth: 480,
1111
- // if the <video height> is not specified, this is the default
1112
- defaultVideoHeight: 270,
1113
- // if set, overrides <video width>
1114
//videoWidth: 1,
1115
// if set, overrides <video height>
1116
//videoHeight: 1
@@ -1118,19 +1209,19 @@ jQuery( document ).ready( function ( $ ) {
1118
rtMediaHook.call( 'rtmedia_js_after_activity_added', [ ] );
1119
}
1120
1121
- $( "#whats-new-post-in" ).removeAttr( 'disabled' );
1122
- $( "#rtmedia-add-media-button-post-update" ).removeAttr( 'disabled' );
1123
// Enabled TextBox color back to normal
1124
- $( "#whats-new" ).css( 'color', '' );
1125
1126
- }
1127
}
1128
} );
1129
} else {
1130
- $.ajaxPrefilter( function ( options, originalOptions, jqXHR ) {
1131
// Modify options, control originalOptions, store jqXHR, etc
1132
try {
1133
- if ( originalOptions.data == null || typeof ( originalOptions.data ) == "undefined" || typeof ( originalOptions.data.action ) == "undefined" ) {
1134
return true;
1135
}
1136
} catch ( e ) {
@@ -1146,55 +1237,55 @@ jQuery( document ).ready( function ( $ ) {
1146
dynamic_privacy = jQuery( 'input[name="privacy"]' ).val();
1147
}
1148
1149
- options.data += "&rtmedia-privacy=" + dynamic_privacy;
1150
var orignalSuccess = originalOptions.success;
1151
- options.success = function ( response ) {
1152
orignalSuccess( response );
1153
if ( response[0] + response[1] == '-1' ) {
1154
//Error
1155
} else {
1156
if ( originalOptions.data.action == 'activity_widget_filter' ) {
1157
- $( "div.activity" ).fadeIn( 100 );
1158
}
1159
}
1160
1161
- $( "#whats-new-post-in" ).removeAttr( 'disabled' );
1162
// Enabled TextBox color back to normal
1163
- $( "#whats-new" ).css( 'color', '' );
1164
1165
- }
1166
}
1167
} );
1168
}
1169
} );
1170
/**
1171
- * rtMedia Comment Js
1172
*/
1173
- jQuery( document ).ready( function ( $ ) {
1174
- jQuery( document ).on( "click", "#rt_media_comment_form #rt_media_comment_submit", function ( e ) {
1175
var comment_content_el = jQuery( '#comment_content' );
1176
- var comment_form_el = jQuery( "#rt_media_comment_form" );
1177
var that = this;
1178
1179
e.preventDefault();
1180
- if ( $.trim( $( "#comment_content" ).val() ) == "" ) {
1181
rtmedia_single_media_alert_message( rtmedia_empty_comment_msg, 'warning' );
1182
return false;
1183
}
1184
1185
$( this ).attr( 'disabled', 'disabled' );
1186
1187
- // sanitize comment content and escape html tags
1188
comment_content_el.val( jQuery( '<span/>' ).text( jQuery.trim( comment_content_el.val() ) ).html() );
1189
1190
$.ajax( {
1191
- url: comment_form_el.attr( "action" ),
1192
type: 'post',
1193
- data: comment_form_el.serialize() + "&rtajax=true",
1194
- success: function ( data ) {
1195
$( '#rtmedia-no-comments' ).remove();
1196
- $( "#rtmedia_comment_ul" ).append( data );
1197
- comment_content_el.val( "" );
1198
$( that ).removeAttr( 'disabled' );
1199
rtMediaHook.call( 'rtmedia_js_after_comment_added', [ ] );
1200
}
@@ -1204,9 +1295,9 @@ jQuery( document ).ready( function ( $ ) {
1204
} );
1205
1206
//Delete comment
1207
- jQuery( document ).on( 'click', '.rtmedia-delete-comment', function ( e ) {
1208
e.preventDefault();
1209
- var ask_confirmation = true
1210
ask_confirmation = rtMediaHook.call( 'rtmedia_js_delete_comment_confirmation', [ ask_confirmation ] );
1211
if ( ask_confirmation && ! confirm( rtmedia_media_comment_delete_confirmation ) ) {
1212
return false;
@@ -1218,15 +1309,15 @@ jQuery( document ).ready( function ( $ ) {
1218
if ( comment_id == '' || isNaN( comment_id ) ) {
1219
return false;
1220
}
1221
- var action = current_comment.closest( 'ul' ).data( "action" );
1222
1223
jQuery.ajax( {
1224
url: action,
1225
type: 'post',
1226
data: { comment_id: comment_id },
1227
- success: function ( res ) {
1228
if ( res != 'undefined' && res == 1 ) {
1229
- current_comment.closest( 'li' ).hide( 1000, function () {
1230
current_comment.closest( 'li' ).remove();
1231
} );
1232
} else {
@@ -1238,28 +1329,30 @@ jQuery( document ).ready( function ( $ ) {
1238
1239
} );
1240
1241
- $( document ).on( "click", '.rtmedia-like', function ( e ) {
1242
e.preventDefault();
1243
var that = this;
1244
var like_nonce = $( this ).siblings( '#rtm_media_like_nonce' ).val();
1245
$( this ).attr( 'disabled', 'disabled' );
1246
- var url = $( this ).parent().attr( "action" );
1247
- $( that ).prepend( "<img class='rtm-like-loading' src='" + rMedia_loading_file + "' style='width:10px' />" );
1248
$.ajax( {
1249
url: url,
1250
type: 'post',
1251
data: { json: true, like_nonce: like_nonce },
1252
- success: function ( data ) {
1253
try {
1254
data = JSON.parse( data );
1255
} catch ( e ) {
1256
1257
}
1258
$( '.rtmedia-like span' ).html( data.next );
1259
$( '.rtm-like-loading' ).remove();
1260
$( that ).removeAttr( 'disabled' );
1261
- //update the like counter
1262
- $( '.rtmedia-like-counter' ).html( data.count );
1263
if ( data.count > 0 ) {
1264
$( '.rtmedia-like-info' ).removeClass( 'hide' );
1265
} else {
@@ -1269,18 +1362,18 @@ jQuery( document ).ready( function ( $ ) {
1269
} );
1270
1271
} );
1272
- $( document ).on( "click", '.rtmedia-featured, .rtmedia-group-featured', function ( e ) {
1273
e.preventDefault();
1274
var that = this;
1275
$( this ).attr( 'disabled', 'disabled' );
1276
var featured_nonce = $( this ).siblings( '#rtm_media_featured_nonce' ).val();
1277
- var url = $( this ).parent().attr( "action" );
1278
- $( that ).prepend( "<img class='rtm-featured-loading' src='" + rMedia_loading_file + "' />" );
1279
$.ajax( {
1280
url: url,
1281
type: 'post',
1282
data: { json:true, featured_nonce:featured_nonce },
1283
- success: function ( data ) {
1284
try {
1285
data = JSON.parse( data );
1286
} catch ( e ) {
@@ -1290,7 +1383,7 @@ jQuery( document ).ready( function ( $ ) {
1290
if ( data.nonce ) {
1291
rtmedia_single_media_alert_message( rtmedia_something_wrong_msg, 'warning' );
1292
} else {
1293
- if (data.action) {
1294
rtmedia_single_media_alert_message( rtmedia_set_featured_image_msg, 'success' );
1295
} else {
1296
rtmedia_single_media_alert_message( rtmedia_unset_featured_image_msg, 'success' );
@@ -1303,16 +1396,16 @@ jQuery( document ).ready( function ( $ ) {
1303
} );
1304
1305
} );
1306
- jQuery( "#div-attache-rtmedia" ).find( "input[type=file]" ).each( function () {
1307
//$(this).attr("capture", "camera");
1308
// $(this).attr("accept", $(this).attr("accept") + ';capture=camera');
1309
1310
} );
1311
1312
- // manually trigger fadein event so that we can bind some function on this event. It is used in activity when content getting load via ajax
1313
var _old_fadein = $.fn.fadeIn;
1314
- jQuery.fn.fadeIn = function () {
1315
- return _old_fadein.apply( this, arguments ).trigger( "fadeIn" );
1316
};
1317
} );
1318
@@ -1323,13 +1416,13 @@ function rtmedia_selected_file_list( plupload, file, uploader, error ) {
1323
upload_progress = '<div class="plupload_file_progress ui-widget-header" style="width: 0%;">';
1324
upload_progress += '</div>';
1325
icon = '<span id="label_' + file.id + '" class="dashicons dashicons-edit rtmicon" title="' + rtmedia_backbone_strings.rtm_edit_file_name + '"></span>';
1326
- } else if ( error.code == - 600 ) {
1327
err_msg = ( uploader != '' ) ? rtmedia_max_file_msg + uploader.settings.max_file_size : window.file_size_info;
1328
- title = "title='" + err_msg + "'";
1329
icon = '<i class="dashicons dashicons-info rtmicon" ' + title + '></i>';
1330
- } else if ( error.code == - 601 ) {
1331
err_msg = error.message + '. ' + window.file_extn_info;
1332
- title = "title='" + err_msg + "'";
1333
icon = '<i class="dashicons dashicons-info rtmicon" ' + title + '></i>';
1334
}
1335
@@ -1360,7 +1453,7 @@ function rtmedia_selected_file_list( plupload, file, uploader, error ) {
1360
jQuery( rtmedia_plupload_file ).appendTo( '#rtmedia_uploader_filelist' );
1361
var type = file.type;
1362
var media_title = file.name;
1363
- var ext = media_title.substring( media_title.lastIndexOf( "." ) + 1, media_title.length );
1364
1365
if ( /image/i.test( type ) ) {
1366
if ( ext === 'gif' ) {
@@ -1368,7 +1461,7 @@ function rtmedia_selected_file_list( plupload, file, uploader, error ) {
1368
} else {
1369
var img = new mOxie.Image();
1370
1371
- img.onload = function () {
1372
this.embed( jQuery( '#file_thumb_' + file.id ).get( 0 ), {
1373
width: 100,
1374
height: 60,
@@ -1376,11 +1469,11 @@ function rtmedia_selected_file_list( plupload, file, uploader, error ) {
1376
} );
1377
};
1378
1379
- img.onembedded = function () {
1380
this.destroy();
1381
};
1382
1383
- img.onerror = function () {
1384
this.destroy();
1385
};
1386
@@ -1400,8 +1493,8 @@ function rtmedia_selected_file_list( plupload, file, uploader, error ) {
1400
1401
/* Change URLin browser without reloading the page */
1402
function change_rtBrowserAddressUrl( url, page ) {
1403
- if ( typeof ( history.pushState ) != "undefined" ) {
1404
var obj = { Page: page, Url: url };
1405
history.pushState( obj, obj.Page, obj.Url );
1406
}
1407
- }
1
var galleryObj;
2
var nextpage = 2;
3
var upload_sync = false;
4
+ var activity_id = -1;
5
var uploaderObj;
6
var objUploadView;
7
var rtmedia_load_template_flag = true;
8
9
+ jQuery( function( $ ) {
10
11
var o_is_album, o_is_edit_allowed;
12
+ if ( typeof ( is_album ) == 'undefined' ) {
13
+ o_is_album = new Array( '' );
14
} else {
15
+ o_is_album = is_album;
16
}
17
+ if ( typeof ( is_edit_allowed ) == 'undefined' ) {
18
+ o_is_edit_allowed = new Array( '' );
19
} else {
20
o_is_edit_allowed = is_edit_allowed;
21
}
25
rtMedia = window.rtMedia || { };
26
27
rtMedia.Context = Backbone.Model.extend( {
28
+ url: function() {
29
+ var url = rtmedia_media_slug + '/';
30
31
if ( ! upload_sync && nextpage > 0 ) {
32
url += 'pg/' + nextpage + '/';
35
return url;
36
},
37
defaults: {
38
+ 'context': 'post',
39
+ 'context_id': false
40
}
41
} );
42
43
rtMedia.Media = Backbone.Model.extend( {
44
defaults: {
45
+ 'id': 0,
46
+ 'blog_id': false,
47
+ 'media_id': false,
48
+ 'media_author': false,
49
+ 'media_title': false,
50
+ 'album_id': false,
51
+ 'media_type': 'photo',
52
+ 'activity_id': false,
53
+ 'privacy': 0,
54
+ 'views': 0,
55
+ 'downloads': 0,
56
+ 'ratings_average': 0,
57
+ 'ratings_total': 0,
58
+ 'ratings_count': 0,
59
+ 'likes': 0,
60
+ 'dislikes': 0,
61
+ 'guid': false,
62
+ 'width': 0,
63
+ 'height': 0,
64
+ 'rt_permalink': false,
65
+ 'duration': '0:00'
66
// "next" : -1,
67
// "prev" : -1
68
}
71
72
rtMedia.Gallery = Backbone.Collection.extend( {
73
model: rtMedia.Media,
74
+ url: function() {
75
var temp = window.location.pathname;
76
var url = '';
77
+ if ( temp.indexOf( '/' + rtmedia_media_slug + '/' ) == -1 ) {
78
url = rtmedia_media_slug + '/';
79
} else {
80
+ if ( temp.indexOf( 'pg/' ) == -1 ) {
81
url = temp;
82
} else {
83
+ url = window.location.pathname.substr( 0, window.location.pathname.lastIndexOf( 'pg/' ) );
84
}
85
}
86
if ( ! upload_sync && nextpage > 1 ) {
87
+ if ( url.substr( url.length - 1 ) != '/' ) {
88
+ url += '/';
89
}
90
91
url += 'pg/' + nextpage + '/';
92
}
93
return url;
94
},
95
+ getNext: function( page, el, element ) {
96
if ( jQuery( '.rtmedia-no-media-found' ).length > 0 ) {
97
+ jQuery( '.rtmedia-no-media-found' ).replaceWith( '<ul class=\'rtmedia-list rtmedia-list-media\'></ul>' );
98
}
99
that = this;
100
if ( rtmedia_load_template_flag == true ) {
104
if ( jQuery( '.rtmedia_gallery_wrapper' ).find( 'input[name=lightbox]' ).length > 0 ) {
105
template_url += '&lightbox=' + jQuery( '.rtmedia_gallery_wrapper' ).find( 'input[name=lightbox]' ).val();
106
}
107
+ $( '#rtmedia-gallery-item-template' ).load( template_url, { backbone: true, is_album: o_is_album, is_edit_allowed: o_is_edit_allowed }, function() {
108
rtmedia_load_template_flag = false;
109
that.getNext( page, el, element );
110
} );
116
rtmedia_page: nextpage
117
};
118
if ( el == undefined ) {
119
+ el = jQuery( '.rtmedia-list' ).parent().parent();
120
}
121
122
if ( el != undefined ) {
123
if ( element != undefined ) {
124
+ $( element ).parent().parent().prevAll( 'input[type=hidden]' ).not( 'input[name=_wp_http_referer], input[name=rtmedia_media_delete_nonce], input[name=rtmedia_bulk_delete_nonce], input[name=bulk-action], input[name=rtmedia_create_album_nonce], input[name=rtmedia_media_nonce], input[name=rtmedia_upload_nonce], input[name=rtmedia_allow_upload_attribute]' ).each( function( e ) {
125
+ if ( $( this ).attr( 'name' ) ) {
126
+ query[ $( this ).attr( 'name' ) ] = $( this ).val();
127
}
128
} );
129
}
130
131
+ $( el ).find( 'input[type=hidden]' ).not( 'input[name=_wp_http_referer], input[name=rtmedia_media_delete_nonce], input[name=rtmedia_bulk_delete_nonce], input[name=bulk-action], input[name=rtmedia_create_album_nonce], input[name=rtmedia_media_nonce], input[name=rtmedia_upload_nonce], input[name=rtmedia_allow_upload_attribute]' ).each( function( e ) {
132
+ if ( $( this ).attr( 'name' ) ) {
133
+ query[ $( this ).attr( 'name' ) ] = $( this ).val();
134
}
135
} );
136
}
137
138
this.fetch( {
139
data: query,
140
+ success: function( model, response ) {
141
jQuery( '.rtm-media-loading' ).hide();
142
+ var list_el = '';
143
144
+ if ( typeof ( element ) === 'undefined' ) {
145
+ if ( jQuery( el ).find( '.rtmedia-list' ).length > 0 ) {
146
list_el = jQuery( el ).find( '.rtmedia-list' );
147
} else {
148
+ list_el = $( '.rtmedia-list' )[0];
149
}
150
} else {
151
list_el = element.parent().siblings( '.rtmedia-list' );
154
nextpage = response.next;
155
156
if ( nextpage < 1 ) {
157
+ if ( typeof el == 'object' ) {
158
jQuery( el ).find( '.rtmedia_next_prev' ).children( '#rtMedia-galary-next' ).hide();
159
}
160
//$("#rtMedia-galary-next").show();
164
collection: new rtMedia.Gallery( response.data ),
165
el: list_el
166
} );
167
+ //Element.show();
168
+
169
rtMediaHook.call( 'rtmedia_after_gallery_load' );
170
171
jQuery( '.rtmedia-container .rtmedia_next_prev .rtm-pagination' ).remove();
173
jQuery( '.rtmedia-container .rtmedia_next_prev .rtm-media-loading' ).remove();
174
jQuery( '.rtmedia-container .rtmedia_next_prev br' ).remove();
175
jQuery( '.rtmedia-container .rtmedia_next_prev' ).append( response.pagination );
176
+
177
+ if ( jQuery( '.rtm-uploader-main-wrapper div.rtm-upload-url' ).is( ':visible' ) == false ) {
178
+ jQuery( '.rtmedia-container .rtmedia-list' ).css( 'opacity', '1' );
179
+ jQuery( '#rtm-media-gallery-uploader' ).slideUp();
180
+ }
181
}
182
} );
183
}
184
},
185
+ reloadView: function( parent_el ) {
186
upload_sync = true;
187
nextpage = 1;
188
jQuery( '.rtmedia-container .rtmedia-list' ).css( 'opacity', '0.5' );
193
rtMedia.MediaView = Backbone.View.extend( {
194
tagName: 'li',
195
className: 'rtmedia-list-item',
196
+ initialize: function() {
197
+ this.template = _.template( $( '#rtmedia-gallery-item-template' ).html() );
198
this.model.bind( 'change', this.render );
199
this.model.bind( 'remove', this.unrender );
200
this.render();
201
},
202
+ render: function() {
203
$( this.el ).html( this.template( this.model.toJSON() ) );
204
return this.el;
205
},
206
+ unrender: function() {
207
$( this.el ).remove();
208
},
209
+ remove: function() {
210
this.model.destroy();
211
}
212
} );
214
rtMedia.GalleryView = Backbone.View.extend( {
215
tagName: 'ul',
216
className: 'rtmedia-list',
217
+ initialize: function() {
218
+ this.template = _.template( $( '#rtmedia-gallery-item-template' ).html() );
219
this.render();
220
},
221
+ render: function() {
222
223
that = this;
224
230
$( that.el ).html( '' );
231
}
232
233
+ $.each( this.collection.toJSON(), function( key, media ) {
234
$( that.el ).append( that.template( media ) );
235
} );
236
241
$( that.el ).siblings( '.rtmedia_next_prev' ).children( '#rtMedia-galary-next' ).show();
242
//$("#rtMedia-galary-next").show();
243
}
244
+ if ( typeof rtmedia_masonry_layout != 'undefined' && rtmedia_masonry_layout == 'true' && jQuery( '.rtmedia-container .rtmedia-list.rtm-no-masonry' ).length == 0 ) {
245
rtm_masonry_reload( rtm_masonry_container );
246
}
247
},
248
+ appendTo: function( media ) {
249
+ //Console.log("append");
250
var mediaView = new rtMedia.MediaView( {
251
model: media
252
} );
256
257
galleryObj = new rtMedia.Gallery();
258
259
+ $( 'body' ).append( '<script id="rtmedia-gallery-item-template" type="text/template"></script>' );
260
261
+ $( document ).on( 'click', '#rtMedia-galary-next', function( e ) {
262
if ( jQuery( '.rtm-media-loading' ).length == 0 ) {
263
+ $( this ).before( '<div class=\'rtm-media-loading\'><img src=\'' + rMedia_loading_media + '\' /></div>' );
264
} else {
265
jQuery( '.rtm-media-loading' ).show();
266
}
269
galleryObj.getNext( nextpage, $( this ).parent().parent().parent(), $( this ) );
270
} );
271
272
+ /**
273
+ * onClick Show all comment
274
+ * By: Yahil
275
+ */
276
+ $( document ).on( 'click', '#rtmedia_show_all_comment', function() {
277
+ var show_comment = $( '#rtmedia_show_all_comment' ).parent().next();
278
+ $( show_comment ).each(function() {
279
+ $( this ).find('li').each(function() {
280
+ $(this).removeClass('hide');
281
+ } );
282
+ } );
283
+ $( this ).parent().remove();
284
+ } );
285
+
286
+ $( document ).on( 'keypress', '#rtmedia_go_to_num', function( e ) {
287
if ( e.keyCode == 13 ) {
288
e.preventDefault();
289
290
if ( jQuery( '.rtm-media-loading' ).length == 0 ) {
291
+ $( '.rtm-pagination' ).before( '<div class=\'rtm-media-loading\'><img src=\'' + rMedia_loading_media + '\' /></div>' );
292
} else {
293
jQuery( '.rtm-media-loading' ).show();
294
}
305
}
306
} );
307
308
+ $( document ).on( 'click', '.rtmedia-page-link', function( e ) {
309
/* Get current clicked href value */
310
href = $( this ).attr( 'href' );
311
312
if ( jQuery( '.rtm-media-loading' ).length == 0 ) {
313
+ $( '.rtm-pagination' ).before( '<div class=\'rtm-media-loading\'><img src=\'' + rMedia_loading_media + '\' /></div>' );
314
} else {
315
jQuery( '.rtm-media-loading' ).show();
316
}
319
if ( $( this ).data( 'page-type' ) == 'page' ) {
320
nextpage = $( this ).data( 'page' );
321
} else if ( $( this ).data( 'page-type' ) == 'prev' ) {
322
+ if ( nextpage == -1 ) {
323
nextpage = parseInt( $( '#rtmedia_last_page' ).val() ) - 1;
324
} else {
325
nextpage -= 2;
342
galleryObj.getNext( nextpage, $( this ).parent().parent().parent().parent().parent(), $( this ).parent().parent() );
343
}
344
change_rtBrowserAddressUrl( href, '' );
345
+
346
} );
347
348
+ if ( window.location.pathname.indexOf( rtmedia_media_slug ) != -1 ) {
349
+ var tempNext = window.location.pathname.substring( window.location.pathname.lastIndexOf( 'pg/' ) + 5, window.location.pathname.lastIndexOf( '/' ) );
350
if ( isNaN( tempNext ) === false ) {
351
nextpage = parseInt( tempNext ) + 1;
352
}
354
355
window.UploadView = Backbone.View.extend( {
356
events: {
357
+ 'click #rtMedia-start-upload': 'uploadFiles'
358
},
359
+ initialize: function( config ) {
360
this.uploader = new plupload.Uploader( config );
361
},
362
+ render: function() {
363
364
},
365
+ initUploader: function( a ) {
366
+ if ( typeof ( a ) !== 'undefined' ) {
367
+ a = false;// If rtmediapro widget calls the function, dont show max size note.
368
} this.uploader.init();
369
//The plupload HTML5 code gives a negative z-index making add files button unclickable
370
+ $( '.plupload.html5' ).css( {
371
zIndex: 0
372
} );
373
+ $( '#rtMedia-upload-button' ).css( {
374
zIndex: 2
375
} );
376
if ( a !== false ) {
377
window.file_size_info = rtmedia_max_file_msg + this.uploader.settings.max_file_size_msg;
378
+ if ( rtmedia_version_compare( rtm_wp_version, '3.9' ) ) { // Plupload getting updated in 3.9
379
file_extn = this.uploader.settings.filters.mime_types[0].extensions;
380
} else {
381
file_extn = this.uploader.settings.filters[0].extensions;
382
}
383
+ window.file_extn_info = rtmedia_allowed_file_formats + ' : ' + file_extn.split( ',' ).join( ', ' );
384
385
+ var info = window.file_size_info + '\n' + window.file_extn_info;
386
+ $( '.rtm-file-size-limit' ).attr( 'title', info );
387
//$("#rtMedia-upload-button").after("<span>( <strong>" + rtmedia_max_file_msg + "</strong> "+ this.uploader.settings.max_file_size_msg + ")</span>");
388
}
389
390
return this;
391
},
392
+ uploadFiles: function( e ) {
393
if ( e != undefined ) {
394
e.preventDefault();
395
}
399
400
} );
401
402
+ if ( $( '#rtMedia-upload-button' ).length > 0 ) {
403
+ if ( typeof rtmedia_upload_type_filter == 'object' && rtmedia_upload_type_filter.length > 0 ) {
404
rtMedia_plupload_config.filters[0].extensions = rtmedia_upload_type_filter.join();
405
}
406
uploaderObj = new UploadView( rtMedia_plupload_config );
407
uploaderObj.initUploader();
408
409
+ uploaderObj.uploader.bind( 'UploadComplete', function( up, files ) {
410
+ activity_id = -1;
411
var hook_respo = rtMediaHook.call( 'rtmedia_js_after_files_uploaded' );
412
+ if ( typeof rtmedia_gallery_reload_on_upload != 'undefined' && rtmedia_gallery_reload_on_upload == '1' ) { //Reload gallery view when upload completes if enabled( by default enabled)
413
if ( hook_respo != false ) {
414
galleryObj.reloadView();
415
}
420
window.onbeforeunload = null;
421
} );
422
423
+ uploaderObj.uploader.bind( 'FilesAdded', function( up, files ) {
424
var upload_size_error = false;
425
+ var upload_error = '';
426
+ var upload_error_sep = '';
427
var upload_remove_array = [ ];
428
+ $.each( files, function( i, file ) {
429
+ //Set file title along with file
430
rtm_file_name_array = file.name.split( '.' );
431
file.title = rtm_file_name_array[0];
432
433
+ var hook_respo = rtMediaHook.call( 'rtmedia_js_file_added', [ up, file, '#rtmedia_uploader_filelist' ] );
434
435
if ( hook_respo == false ) {
436
+ file.status = -1;
437
upload_remove_array.push( file.id );
438
return true;
439
}
447
if ( uploaderObj.uploader.settings.max_file_size < file.size ) {
448
return true;
449
}
450
+ var tmp_array = file.name.split( '.' );
451
+ if ( rtmedia_version_compare( rtm_wp_version, '3.9' ) ) { // Plupload getting updated in 3.9
452
var ext_array = uploaderObj.uploader.settings.filters.mime_types[0].extensions.split( ',' );
453
} else {
454
var ext_array = uploaderObj.uploader.settings.filters[0].extensions.split( ',' );
456
if ( tmp_array.length > 1 ) {
457
var ext = tmp_array[tmp_array.length - 1];
458
ext = ext.toLowerCase();
459
+ if ( jQuery.inArray( ext, ext_array ) === -1 ) {
460
return true;
461
}
462
} else {
463
return true;
464
}
465
466
+ if ( rtmedia_version_compare( rtm_wp_version, '3.9' ) ) { // Plupload getting updated in 3.9
467
uploaderObj.uploader.settings.filters.mime_types[0].title;
468
} else {
469
uploaderObj.uploader.settings.filters[0].title;
473
rtmedia_selected_file_list( plupload, file, '', '' );
474
475
//Delete Function
476
+ $( '#' + file.id + ' .plupload_delete .remove-from-queue' ).click( function( e ) {
477
e.preventDefault();
478
uploaderObj.uploader.removeFile( up.getFile( file.id ) );
479
+ $( '#' + file.id ).remove();
480
rtMediaHook.call( 'rtmedia_js_file_remove', [ up, file ] );
481
return false;
482
} );
483
484
// To change the name of the uploading file
485
+ $( '#label_' + file.id ).click( function( e ) {
486
e.preventDefault();
487
488
rtm_file_label = this;
503
jQuery( rtm_file_label ).hide();
504
jQuery( rtm_file_label ).siblings( '.plupload_file_name_wrapper' ).hide();
505
506
+ // Show/create text box to edit media title
507
if ( jQuery( rtm_file_title_input ).length === 0 ) {
508
jQuery( rtm_file_label ).parent( '.plupload_file_name' ).prepend( '<div id="' + rtm_file_title_wrapper_id + '" class="rtm-upload-edit-title-wrapper"><label>' + rtmedia_edit_media_info_upload.title + '</label><input type="text" class="rtm-upload-edit-title" id="' + rtm_file_title_id + '" value="' + file.title + '" style="width: 75%;" /></div><div id="' + rtm_file_desc_wrapper_id + '" class="rtm-upload-edit-desc-wrapper"><label>' + rtmedia_edit_media_info_upload.description + '</label><textarea class="rtm-upload-edit-desc" id="' + rtm_file_desc_id + '"></textarea></div><span id="' + rtm_file_save_id + '" title="Save Change" class="rtmicon dashicons dashicons-yes"></span>' );
509
} else {
514
515
jQuery( rtm_file_title_input ).focus();
516
517
+ // Set media title and description in file object
518
+ $( '#save_' + file.id ).click( function( e ) {
519
+ e.preventDefault();
520
521
+ rtm_file_label = this;
522
523
+ rtm_file_title_id = 'text_' + file.id;
524
+ rtm_file_title_input = '#' + rtm_file_title_id;
525
+ rtm_file_title_wrapper_id = 'rtm_title_wp_' + file.id;
526
+ rtm_file_title_wrapper = '#' + rtm_file_title_wrapper_id;
527
+
528
+ rtm_file_desc_id = 'rtm_desc_' + file.id;
529
+ rtm_file_desc_input = '#' + rtm_file_desc_id;
530
+ rtm_file_desc_wrapper_id = 'rtm_desc_wp_' + file.id;
531
+ rtm_file_desc_wrapper = '#' + rtm_file_desc_wrapper_id;
532
+
533
+ rtm_file_save_id = 'save_' + file.id;
534