diff --git a/config.default.js b/config.default.js index 0e20f9672b..7bd7aa3dcd 100644 --- a/config.default.js +++ b/config.default.js @@ -21,6 +21,10 @@ var config = { "google": { "id": '', "secret": '' + }, + "facebook": { + "app_id": '', + "secret": '' } } diff --git a/package.json b/package.json index 072503960a..bc67486e6b 100644 --- a/package.json +++ b/package.json @@ -22,6 +22,7 @@ "passport-local": "0.1.6", "passport-twitter": "0.1.4", "passport-google-oauth": "0.1.5", + "passport-facebook": "0.1.5", "less-middleware": "0.1.11" }, "devDependencies": {}, diff --git a/public/css/style.less b/public/css/style.less index 55196a5724..4852b00ab4 100644 --- a/public/css/style.less +++ b/public/css/style.less @@ -1,3 +1,13 @@ + +.caret-left { + border-left: 0; + border-right: 4px solid black; + border-top: 4px solid transparent; + border-bottom: 4px solid transparent; +} + + + .pointer { cursor: pointer; *cursor: hand; @@ -9,6 +19,10 @@ zoom: 1; } +body { + background: #fdfdfd; +} + .none { display: none; } @@ -47,7 +61,7 @@ footer.footer { #post_window { width: 100%; - position: absolute; + position: fixed; height: 350px; left: 0px; bottom: 0px; @@ -124,29 +138,70 @@ footer.footer { list-style-type: none; padding: 0; margin: 0; - border: 1px solid #eee; + clear: both; + + .profile-image-block { + background: white; + + } + li { + padding-bottom: 15px; + } + + .profile-block, .post-block { + border: 1px solid #f0f0f0; + border-radius: 5px; + + padding: 10px; + } + + img { + margin: 5px; + } + + .profile-block { + background: #fafafa; + margin-right: -11px; + margin-left: -11px; + margin-bottom: -11px; + margin-top: 15px; + border-radius: 0 0 5px 5px; + font-size: 10px; + padding: 5px; + padding-left: 10px; + } + + .post-block { + + .caret { + margin-top: -10px; + margin-left: -18px; + display: block; + border-width: 8px 8px 8px 0; + border-color: transparent #ddd transparent; + } + .post-buttons { + font-size: 12px; + float: right; + + div { + display: inline-block; + padding-left: 15px; + padding-right: 15px; + border-left: 1px solid #f0f0f0; + cursor: pointer; + + &:last-child { + padding-right: 5px; + } + } + } + background: #fff; + } li:last-child { border-bottom: 0; } - - li.post-row { - cursor: pointer; - border-bottom: 1px solid #eee; - padding: 10px; - - &:nth-child(odd) { - background-color:#fdfdfd; - } - - &:nth-child(even) { - background-color:#fff; - } - - &:hover { - background-color: #eee; - } - } } #user_label { @@ -203,4 +258,4 @@ footer.footer { .inline-block; } } -} \ No newline at end of file +} diff --git a/public/src/app.js b/public/src/app.js index 249bc1b688..29e60a9ddf 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -107,9 +107,14 @@ var socket, app.post_topic(); } } else { + if (post_mode == 'reply') { + reply_title.innerHTML = 'You are replying to "' + title + '"'; + } else if (post_mode == 'quote') { + reply_title.innerHTML = 'You are quoting "' + title + '"'; + } + post_title.style.display = "none"; reply_title.style.display = "block"; - reply_title.innerHTML = 'You are replying to "' + title + '"'; post_content.focus(); submit_post_btn.onclick = function() { app.post_reply(id) @@ -118,6 +123,9 @@ var socket, }; + + + app.post_reply = function(topic_id) { var content = document.getElementById('post_content').value; diff --git a/public/templates/header.tpl b/public/templates/header.tpl index 65635218c9..2068576586 100644 --- a/public/templates/header.tpl +++ b/public/templates/header.tpl @@ -5,6 +5,7 @@ + @@ -47,10 +48,10 @@
- - - - + + + +
Submit diff --git a/public/templates/login.tpl b/public/templates/login.tpl index 6f5bf0a752..85a1f466a7 100644 --- a/public/templates/login.tpl +++ b/public/templates/login.tpl @@ -17,6 +17,7 @@
diff --git a/public/templates/topic.tpl b/public/templates/topic.tpl index 4c8ebfa9cb..58aa321c5a 100644 --- a/public/templates/topic.tpl +++ b/public/templates/topic.tpl @@ -5,19 +5,48 @@ -