Pārlūkot izejas kodu

Merge remote-tracking branch 'origin/february_release' into february_release

KrisVos130 9 gadi atpakaļ
vecāks
revīzija
f43495e6d4

+ 5 - 11
app/client/scripts/events.js

@@ -176,22 +176,13 @@ function sendMessageGlobal() {
 }
 
 Template.admin.events({
-    "click #croom_create": function() {
-        Meteor.call("createRoom", $("#croom_display").val(), $("#croom_tag").val(), function (err, res) {
-            if (err) {
-                alert("Error " + err.error + ": " + err.reason);
-            } else {
-                window.location = "/" + $("#croom_tag").val();
-            }
-        });
-    },
     "click a": function(e){
         var id = e.currentTarget.id;
         console.log(id.toLowerCase());
         Session.set("playlistToEdit", id);
     },
     "click #croom_create": function() {
-        Meteor.call("createRoom", $("#croom_display").val(), $("#croom_tag").val(), $("#two").prop("checked"), function (err, res) {
+        Meteor.call("createRoom", $("#croom_display").val(), $("#croom_tag").val(), $("#croom_private").prop("checked"), $("#croom_desc").val(), function (err, res) {
             if (err) {
                 alert("Error " + err.error + ": " + err.reason);
             } else {
@@ -233,10 +224,13 @@ Template.alertsDashboard.events({
 
 Template.feedback.events({
     "click #feedback_submit": function(){
-        if($("#feedback_message").val().length !== 0){
+        if($("#feedback_message").val().length !== 0 && $("#feedback_message").hasClass("invalid") === false){
             Meteor.call("sendFeedback", $("#feedback_message").val());
             $("#feedback_message").val("");
             $("#modal1").closeModal()
+        } else{
+            var $toastContent = $('<span><strong>Feedback not sent.</strong> Possible reasons include:<ul><li>- Empty Feedback Message</li><li>- Feedback is more than 500 words</li></ul></span>');
+            Materialize.toast($toastContent, 8000);
         }
     },
     "click .upvote": function(){

+ 9 - 1
app/client/stylesheets/app.css

@@ -177,4 +177,12 @@ textarea{
     margin-left: 0;
     margin-right: 0;
     /* Weird hack... No clue why this is needed but it is.*/
-}
+}
+
+#room-content {
+  padding-top: 15px;
+}
+
+.feedback-message{
+    word-wrap: break-word;
+}

+ 8 - 5
app/client/templates/admin.html

@@ -53,7 +53,6 @@
                 </div>
                 <div class="row">
                     <a class="btn col l12 s12 m12 waves-effect waves-light" href="/admin/queues">Manage Queues</a> <!-- TODO Make this redirect to the queues -->
-                    <a class="btn col l12 s12 m12 waves-effect waves-light" href="/admin/news">Manage News</a>
                 </div>
             </div>
         </div>
@@ -64,14 +63,18 @@
                     <h4>Add Room</h4>
                     <div class="input-field">
                         <input type="text" class="croom" id="croom_display" name="croom" required/>
-                        <label for="croom_display" class="white-text">Room Display Name</label>
+                        <label for="croom_display" class="black-text">Room Display Name</label>
                     </div>
                     <div class="input-field">
                         <input type="text" class="croom" id="croom_tag" name="croom" required/>
-                        <label for="croom_tag" class="white-text">Room Tag</label>
+                        <label for="croom_tag" class="black-text">Room Tag</label>
+                    </div>
+                    <div class="input-field">
+                        <input type="text" class="croom" id="croom_desc" name="croom" required/>
+                        <label for="croom_desc" class="black-text">Room Description</label>
                     </div>
                     <input type="checkbox" name="croom_private" id="croom_private"/>
-                    <label for="croom_private" class="white-text">Make Room Private?</label>
+                    <label for="croom_private" class="black-text">Make Room Private?</label>
                     <div class="section">
                         <button class="btn btn-warning btn-block waves-effect waves-light" id="croom_create">Create</button>
                     </div>
@@ -122,7 +125,7 @@
                     <a id="submit_desc" class="waves-effect waves-light btn">Submit</a>
                 </div>
                 <div class="modal-footer">
-                    <button id="close-modal" type="button" class="btn btn-default waves-effect waves-light" data-dismiss="modal">Close</button>
+                    <a href="#!" class=" modal-action modal-close waves-effect waves-light btn-flat">Close</a>
                 </div>
             </div>
         </div>

+ 1 - 1
app/client/templates/faq.html

@@ -1,5 +1,4 @@
 <template name="faq">
-    {{> alerts}}
     {{> header}}
     <div class="text-center">
         <h3>FAQ
@@ -37,4 +36,5 @@
         <p class="flow-text">Yes! Just type /commands or /help in chat and it will show you all of the available
             chat commands.</p>
     </div>
+    {{> footer}}
 </template>

+ 6 - 4
app/client/templates/feedback.html

@@ -1,9 +1,11 @@
 <template name="feedback">
     {{> header}}
     <main>
-        <h3 class="black-text thin text-center">Feedback</h3>
+        <div class="center-align">
+        <h3 class="black-text thin">Feedback</h3>
         <a class="waves-effect waves-light btn modal-trigger feedback-btn" href="#modal1">Send New Feedback</a>
         <a id="editModal" class="modal-trigger" href="#editFeedback" style="display:none"></a>
+        </div>
 
         <div class="row">
             {{#each feedback}}
@@ -23,7 +25,7 @@
                                     </ul>
                                 </div>
                             {{/if}}
-                            <p>{{message}}</p>
+                            <p class="feedback-message">{{message}}</p>
                         </div>
                         <div class="card-action">
                             <a class="lowercase" href="/u/{{username}}">{{username}}</a>
@@ -38,7 +40,7 @@
     <div id="modal1" class="modal">
         <div class="modal-content teal darken-4">
             <div class="input-field">
-                <textarea id="feedback_message" class="materialize-textarea" length="500"></textarea>
+                <textarea id="feedback_message" class="materialize-textarea validate" length="500"></textarea>
                 <label for="feedback_message">Give us your feedback and suggestions!</label>
             </div>
             <a id="feedback_submit" class="waves-effect waves-light btn">Submit</a>
@@ -48,7 +50,7 @@
         <div class="modal-content teal darken-4">
             <label>Edit Feedback Message</label>
             <div class="input-field">
-                <textarea id="edit_feedback_message" class="materialize-textarea" length="500"></textarea>
+                <textarea id="edit_feedback_message" class="materialize-textarea validate" length="500"></textarea>
             </div>
             <a id="edit_feedback_submit" class="waves-effect waves-light btn">Submit</a>
         </div>

+ 6 - 0
app/client/templates/header.html

@@ -26,6 +26,9 @@
                 <a href="/" class="brand-logo light">Musare</a>
                 <a href="#" data-activates="mobile-navi" class="button-collapse"><i class="material-icons">menu</i></a>
                 <ul class="right hide-on-med-and-down scroll-fix">
+                  {{#if isModerator}}
+                    <li><a  class="orange-text" href="/admin"><b>Admin</b></a></li>
+                  {{/if}}
                     <li><a href="/news">News</a></li>
                     <li><a class="dropdown-button" href="#!" data-activates="contributeDrop">Contribute<i
                             class="material-icons right">arrow_drop_down</i></a></li>
@@ -41,6 +44,9 @@
                 </ul>
                 <ul class="side-nav" id="mobile-navi" style="width: 240px;">
                     <ul class="collapsible" data-collapsible="accordion">
+                      {{#if isModerator}}
+                        <li><a href="/admin">Admin</a></li>
+                      {{/if}}
                         <li>
                             <a href="/news">News</a>
                         </li>

+ 56 - 43
app/client/templates/privacy.html

@@ -1,45 +1,58 @@
 <template name="privacy">
-    {{> alerts}}
-    {{> header}}
-    <h2>Privacy Policy</h2>
-    <hr>
-    <p class="flow-text">
-        Your privacy is very important to us. Accordingly, we have developed this Policy in order for you to understand
-        how we collect, use, communicate, disclose and make use of personal information. The following outlines our
-        privacy policy.
-    </p>
-    <ul class="flow-text">
-        <li>
-            Before or at the time of collecting personal information, we will identify the purposes for which
-            information is being collected.
-        </li>
-        <li>
-            We will collect and use personal information solely with the objective of fulfilling those purposes
-            specified by us and for other compatible purposes, unless we obtain the consent of the individual concerned
-            or as required by law.
-        </li>
-        <li>
-            We will only retain personal information as long as necessary for the fulfillment of those purposes.
-        </li>
-        <li>
-            We will collect personal information by lawful and fair means and, where appropriate, with the knowledge or
-            consent of the individual concerned.
-        </li>
-        <li>
-            Personal data should be relevant to the purposes for which it is to be used, and, to the extent necessary
-            for those purposes, should be accurate, complete, and up-to-date.
-        </li>
-        <li>
-            We will protect personal information by reasonable security safeguards against loss or theft, as well as
-            unauthorized access, disclosure, copying, use or modification.
-        </li>
-        <li>
-            We will make readily available to customers information about our policies and practices relating to the
-            management of personal information.
-        </li>
-    </ul>
-    <p class="flow-text">
-        We are committed to conducting our business in accordance with these principles in order to ensure that the
-        confidentiality of personal information is protected and maintained.
-    </p>
+  {{> header}}
+<div class="container">
+	<h1 class="center-align">MUSARE PRIVACY POLICY</h1>
+	<h4 class="center-align">Last Updated: January 25, 2016</h4>
+
+	<h4 class="center-align">1. Introduction</h4>
+	Musare.com respects your privacy and the security of your personal information, and we want to do as much as we can to protect it. Because of this, we have created this Privacy Policy to govern how we deal with your personal information. Since our Site is built off of Content that you provide, including shared information from third party sites, it is important that you read and understand their information sharing policies as well. Please check back often, as we will update this Privacy Policy as we grow.
+
+	<h4 class="center-align">2. Personal Information We Collect</h4>
+	<p>In order for you to sign up for our service, we may ask for personal information from you including your name, e-mail address, mailing address, phone number, photo, username from other social media sites, gender, date of birth, or other relevant information. In addition, we utilize third party API’s like GitHub Authentication, and other API’s that allow you to transfer your profile information from those Sites to ours depending on your settings on those Sites. We are not responsible for any information that does not transfer or if any information is inaccurate.</p>
+
+	<p>Your use of any of the video or chat features may be recorded or logged by our servers. We may use this data to improve our Site or Platform, or to determine how best to provide marketing opportunities to you.</p>
+
+	<p>We use the above referenced information to contact you regarding your account, assist in customer service and support, and to improve our Site and the musare.com platform. We also use the information we collect to send periodic communications to you regarding updates to our Site, new features, and marketing opportunities that we think you may find interesting.</p>
+
+	<p>We may send you periodic emails that concern updates or features. We make sure to comply with CAN-SPAM Act of 2003, 15 U.S.C. 7701 whenever we send you these goodies. If you feel that you are receiving unwanted messages from us (which we hope isn’t the case!) then please use the unsubscribe button or email us at musaremusic@gmail.com to remove yourself from our list. Please allow for up to ten (10) business days to process the removal.</p>
+
+	<h4 class="center-align">3. Non-Personal Information</h4>
+	<p>We may collect information about you that we consider to be less sensitive. When you access our website, we may collect such things as your IP address, browser, operating system, and other information that helps us know about the general nature of our visitors. We use this information to improve our Site and the musare.com platform.</p>
+
+	<h4 class="center-align">4. Cookies</h4>
+	<p>We use tracking cookies to distinguish you from other users to help prevent one user from unwittingly logging into another user’s account on the same computer or network. In conjunction with third party API’s, we also allow you to login using your credentials on those third party sites. These Sites may use cookies to track your web browsing, and have separate privacy policies that you must read. In addition, any time you share Content with others those third party Sites may collect information about people who view or share that Content. You must also read their privacy policies.</p>
+
+	<p>We also may use tracking cookies to help ourselves or third party advertisers increase the effectiveness and quality of, and interest in, our marketing programs, or for other advertising or marketing purposes.</p>
+
+	<p>Any advertisements served by Google, Inc., and affiliated companies may be controlled using cookies. These cookies allow Google to display ads based on your visits to this site and other sites that use Google advertising services. Learn how to opt out of Google’s cookie usage. As mentioned above, any tracking done by Google through cookies and other mechanisms is subject to Google’s own privacy policies.</p>
+
+	<p>Your use of the Site may require that you have cookies turned on, depending on your login preferences.</p>
+
+	<h4 class="center-align">5. User Content</h4>
+	<p>We may allow you to post Content to our website, including videos and music. This content, once posted, is available for anyone to see and you are granting us the limited license for our use in accordance with our Terms of Service. As such, you must make sure you do not post anything that you do not have the rights to distribute. Please engage your brain when posting content.</p>
+
+	<h4 class="center-align">6. Third Party Sites</h4>
+	<p>Since our Site is built off of Content and sharing, you can be sure that you will encounter links to third party sites or Content that is being displayed from a third party site. Anytime you encounter a link to a website outside of musare.com, you should know that we have no control over that Site. We recommend that you consult those websites privacy policies, terms of service, and other similar documents when using them.</p>
+
+	<p>You may also have the ability to interface, through the use of APIs, with third party websites such as social websites like Facebook, GitHub and Twitter. Be advised that we cannot be responsible for any breaches of privacy that may arise from the use of these third party websites.</p>
+
+	<h4 class="center-align">7. Access to Information and Data Storage</h4>
+	<p>We may host data with third parties and allow third parties to access, maintain, or otherwise use your information for purposes that we deem conducive to improving our business and service. We will strive to always deal with reputable providers, but we cannot make any guarantees. As such, you hereby agree that we are not liable for any privacy breaches that may occur as a result of the actions of third parties. In addition, how you interact with our Site may be shared with the third party service that you used to login, which means you are also storing information on their servers, which is governed by their own agreements.</p>
+
+	<h4 class="center-align">8. Law Enforcement</h4>
+	<p>We may disclose your information to a third party where we believe, in good faith that we are required to for legal purposes. The disclosure may be due to a criminal investigation, or a civil subpoena. If we receive such a request we may, but are not required to, notify you of such request and give you an opportunity to respond.</p>
+
+	<h4 class="center-align">9. Children's Online Privacy Protection Act</h4>
+	<p>We do not allow users on our website who are under the age of thirteen years old. If you become aware of such a user, please notify us immediately. If you are reported as being in violation of our age policy, we may freeze your account and require that you submit satisfactory proof of age before you may continue using our service.</p>
+
+	<h4 class="center-align">10. Amendments</h4>
+	<p>We may amend this Privacy Policy under the same conditions as our Terms of Service. Your responsibility to keep yourself updated as to changes to this Privacy Policy is the same as in our “Amendments” section in our Terms of Service.</p>
+
+	<h4 class="center-align">11. Users from outside the United States</h4>
+	<p>We may have users who are from outside the United States. If you are, you are acknowledging that your information is being transferred from your country to ours. To the extent we are required, we maintain our Site and information collection practices in a way that conforms with most laws. If you are from a jurisdiction who's information collection practices differ from ours, please notify us so that we may take necessary action. This may include terminating your account and deleting your information. We are committed to resolving those issues, so if you have any questions about how we collect or use your information you may email us at musaremusic@gmail.com.</p>
+
+	<h4 class="center-align">12. Deactivating your account</h4>
+	<p>You may deactivate your account at any time by accessing your account settings, or send us a mail at musaremusic@gmail.com. When submitting your request, please let us know what led you to deactivate your account. Your feedback is greatly appreciated, and will help us to better accommodate members of the community.</p>
+</div>
+{{> footer}}
 </template>

+ 1 - 1
app/client/templates/profile.html

@@ -3,7 +3,7 @@
     {{> header}}
     {{#if loaded}}
         <!--{{> avatar userId=profileUserId shape="circle" class="profile-img" initials=initials}}-->
-        <h1 id="profile-name" class="black-text thin">{{username}}</h1>
+        <h1 id="profile-name" class="center-align black-text thin">{{username}}</h1>
         <div class="row">
             <div class="col s12 m6 l4">
                 <div class="card blue-grey darken-1 profile-card">

+ 6 - 0
app/client/templates/register.html

@@ -20,6 +20,12 @@
                         <label for="password">Password</label>
                     </div>
                 </div>
+                <div class="row">
+                    <p>
+                        <input type="checkbox" id="termsPrivacyBTN" />
+                        <label for="termsPrivacyBTN">By registering you agree to musare.com <a href="/terms" target="_blank">terms & conditions</a> and <a href="/privacy" target="_blank">privacy policy.</a></label>
+                    </p>
+                </div>
                 {{> reCAPTCHA}}
                 <button class="btn waves-effect waves-light register" type="submit" name="action">Submit
                     <i class="material-icons right">send</i>

+ 13 - 7
app/client/templates/room.html

@@ -19,7 +19,7 @@
             </nav>
         </header>
 
-        <main>
+        <main id="room-content">
             <div class="container">
                 <div class="row">
                     <div class="col s12 m10 l8 offset-l2 offset-m1" id="media-container">
@@ -33,17 +33,23 @@
                                 <h3>{{{title}}} - {{{artist}}}</h3>
                                 <h4 id="time-display"><span id="time-elapsed"></span> / <span id="time-total"></span></h4>
                                 <div class="row">
-                                    <form action="#" class="col s4 m4 l4">
-                                        <p class="range-field" style="margin-top: 0">
-                                            <input type="range" id="volume_slider" min="0" max="100" />
-                                        </p>
-                                    </form>
+                                  <form action="#" class="left col s4 m4 l4">
+                                      <p class="range-field" style="margin-top: 0">
+                                          <input type="range" id="volume_slider" min="0" max="100" />
+                                      </p>
+                                  </form>
+                                  <div class="right col s4 m2 l2">
+                                    <ul>
+                                      <li class="left"><a href="#add_song_modal"><i class="material-icons black-text">thumb_up</i></a></li>
+                                      <li class="right"><a href="#bug_report_modal"><i class="material-icons black-text">thumb_down</i></a></li>
+                                    </ul>
+                                  </div>
                                 </div>
                                 <div class="seeker-bar-container white" id="preview-progress">
                                     <div class="seeker-bar teal" style="width: 0%"></div>
                                 </div>
                             </div>
-                            <img alt="Not loading" class="song-img col s12 m12 l4" onError="this.src='http://static.boredpanda.com/blog/wp-content/uploads/2014/04/amazing-fox-photos-182.jpg'" id="song-img"/>
+                            <img alt="Not loading" class="responsive-img song-img col s12 m12 l4" onError="this.src='http://static.boredpanda.com/blog/wp-content/uploads/2014/04/amazing-fox-photos-182.jpg'" id="song-img"/>
                         </div>
                     </div>
                 </div>

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 28 - 160
app/client/templates/terms.html


+ 1 - 1
app/server/server.js

@@ -1233,4 +1233,4 @@ Meteor.setInterval(function () {
 
 Meteor.users.after.insert(function (err, user) {
     Accounts.sendVerificationEmail(user._id);
-});
+});

Daži faili netika attēloti, jo izmaiņu fails ir pārāk liels