windhamdavid 4 years ago
parent
commit
6d305cd145
6 changed files with 22 additions and 38 deletions
  1. 5 1
      css/message.css
  2. 11 1
      front-page.php
  3. 3 2
      gruntfile.js
  4. 2 1
      inc/tweaks.php
  5. 1 1
      js/init.min.js
  6. 0 32
      js/messenger.min.js

+ 5 - 1
css/message.css

@@ -1,3 +1,7 @@
+.modal-content.message {
+	width:528;
+	background:000;
+}
 .modal-open {
   overflow: hidden;
 }
@@ -37,7 +41,7 @@
 }
 .modal-content {
   position: relative;
-  background-color: #fff;
+  background-color: #000;
   -webkit-background-clip: padding-box;
           background-clip: padding-box;
   border: 1px solid #999;

+ 11 - 1
front-page.php

@@ -14,7 +14,7 @@
 <meta name="author" content="David Windham">
 <link rel='canonical' href='https://davidawindham.com/' />
 <link rel="stylesheet" type="text/css" media="all" href="<?php echo get_template_directory_uri();?>/css/front.min.css"/>
-
+<link rel="stylesheet" type="text/css" media="all" href="<?php echo get_template_directory_uri();?>/css/message.css"/>
 </head>
 <body>
 <div class="container card">
@@ -117,10 +117,20 @@
 				</div>
 			</div> 
 			<div id="footer" role="contentinfo">
+			<!--<a data-target="#chat" role="button" class="btn" data-toggle="modal">Chat</a> // Add remote poll for control -->
+			<div class="modal fade chat" id="chat" tabindex="-1" role="dialog" aria-labelledby="chat" aria-hidden="true">
+				<div class="modal-dialog modal-lg">
+					<div class="modal-content message">
+						<iframe id="chat" width="528px" height="420px" scrolling="no" frameborder="0"  style="background:#000" /></iframe>
+					</div>
+				</div>
+			</div>
 			</div>
 
 </div> 
 <script type='text/javascript' src='<?php echo get_template_directory_uri();?>/js/front.min.js'></script>
+<script type='text/javascript' src='<?php echo get_template_directory_uri();?>/js/messenger.min.js'></script>
+<?php dw_online_get_status(); ?>
 <?php wp_footer(); ?>
 <script type="application/ld+json">{"@context": "http://schema.org","@type": "WebSite","url":"https://davidawindham.com/","potentialAction":{"@type":"SearchAction","target":"https://davidawindham.com/?s={search_term_string}","query-input": "required name=search_term_string"}}
 </script>

+ 3 - 2
gruntfile.js

@@ -35,7 +35,7 @@ module.exports = function(grunt) {
 			disto: {
 				src: ['js/jquery-2.1.1.min.js', 'js/svg-morpheus.js', 'js/front-page.js'],
 				dest: 'js/front-page.min.js',
-			},
+			}
 		},
 		
 	    jshint: {
@@ -52,7 +52,8 @@ module.exports = function(grunt) {
 				'js/script-o.min.js': ['js/script-o.js'],
 				'js/init-o.min.js': ['js/init-o.js'],
 				'js/init.min.js': ['js/init.js'],
-				'js/front.min.js' : ['js/front-page.min.js'],  
+				'js/front.min.js' : ['js/front-page.min.js'], 
+				'js/message.js' : ['js/message.min.js'],  
 		      }
 		    }
 		  }

+ 2 - 1
inc/tweaks.php

@@ -110,7 +110,8 @@ function dw_online_get_status() {
 									if (++i < 6) {
 										return opts.error({status: 500,readyState: 0,responseText: 0});
 									} 
-									else if (++i < 2) { //TODO: connect with backbone and Twilio
+									else if (++i < 21) { 
+										// Connect with Cackbone and Twilio via webrtc app at code.davidawindham.com
 										return opts.success();
 									}
 									else {

File diff suppressed because it is too large
+ 1 - 1
js/init.min.js


+ 0 - 32
js/messenger.min.js

@@ -36,39 +36,7 @@
 }).call(this);
 
 
-(function() {
-  var $, FutureMessage, spinner_template,
-    __hasProp = {}.hasOwnProperty,
-    __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
-
-  $ = jQuery;
-
-  spinner_template = '<div class="messenger-spinner">\n    <span class="messenger-spinner-side messenger-spinner-side-left">\n        <span class="messenger-spinner-fill"></span>\n    </span>\n    <span class="messenger-spinner-side messenger-spinner-side-right">\n        <span class="messenger-spinner-fill"></span>\n    </span>\n</div>';
-
-  FutureMessage = (function(_super) {
-
-    __extends(FutureMessage, _super);
-
-    function FutureMessage() {
-      return FutureMessage.__super__.constructor.apply(this, arguments);
-    }
 
-    FutureMessage.prototype.template = function(opts) {
-      var $message;
-      $message = FutureMessage.__super__.template.apply(this, arguments);
-      $message.append($(spinner_template));
-      return $message;
-    };
-
-    return FutureMessage;
-
-  })(window.Messenger.Message);
-
-  window.Messenger.themes.future = {
-    Message: FutureMessage
-  };
-
-}).call(this);