Skip to content

Commit

Permalink
initial, changed menu
Browse files Browse the repository at this point in the history
  • Loading branch information
wezeolaky committed Sep 27, 2016
0 parents commit 7925644
Show file tree
Hide file tree
Showing 36 changed files with 973 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Created by .ignore support plugin (hsz.mobi)
### Node template
# Logs
logs
*.log
npm-debug.log*

# Runtime data
pids
*.pid
*.seed

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# node-waf configuration
.lock-wscript

# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules
jspm_packages

# Optional npm cache directory
.npm

# Optional REPL history
.node_repl_history
12 changes: 12 additions & 0 deletions .idea/JSRespoWeb.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .idea/dictionaries/lucky.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions .idea/jsLibraryMappings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

47 changes: 47 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions config
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name : Total.js
author : You company name
version : 1.0.0
secret : secret-key-for-web

// Mail settings
mail.smtp : smtp.yourwebsite.com
mail.smtp.options : {"secure":false,"port":25,"user":"","password":"","timeout":10000}
mail.address.from : [email protected]
mail.address.reply : [email protected]
mail.address.bcc :
mail.contact : [email protected]
10 changes: 10 additions & 0 deletions controllers/api.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
exports.install = function() {
F.route('/api/newsletter/', json_save, ['post', '*Newsletter']);
F.route('/api/contact/', json_save, ['post', '*Contact']);
};

function json_save() {
var self = this;
self.body.ip = self.ip;
self.body.$save(self.callback());
}
7 changes: 7 additions & 0 deletions controllers/default.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@

exports.install = function() {
F.route('/');
F.route('/docs/');
F.route('/contact/');
F.route('/examples/');
};
15 changes: 15 additions & 0 deletions debug.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions definitions/merge.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
F.merge('/css/default.css', '/css/bootstrap.min.css', '/css/ui.css', '/css/default.css');
F.merge('/js/default.js', '/js/jctajr.min.js', '/js/ui.js', '/js/default.js');
37 changes: 37 additions & 0 deletions models/contact.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
NEWSCHEMA('Contact').make(function(schema) {

schema.define('firstname', 'Capitalize(40)', true);
schema.define('lastname', 'Capitalize(40)', true);
schema.define('email', 'Email', true);
schema.define('message', String, true);
schema.define('phone', 'Phone');
schema.define('ip', 'String(80)');

// Saves the model into the database
schema.setSave(function(error, model, options, callback) {

model.id = UID();
model.datecreated = new Date();

// Saves to database
NOSQL('contactforms').insert(model.$clean());

// Returns response
callback(SUCCESS(true));

var builder = [];

builder.push('<b>Created:</b><br />' + new Date().format('yyyy-MM-dd HH:mm:ss'))
builder.push('<b>IP address:</b><br />' + model.ip);
builder.push('<b>Name:</b><br />' + model.firstname + ' ' + model.lastname);
builder.push('<b>Email address:</b><br />' + model.email);

if (model.phone)
builder.push('<b>Phone number:</b><br />' + model.phone);

builder.push('<b>Question:</b><br />' + model.body);

// Sends email
F.logmail(CONFIG('mail.contact'), 'Contact form # ' + model.id, builder.join('\n\n')).reply(model.email);
});
});
16 changes: 16 additions & 0 deletions models/newsletter.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
NEWSCHEMA('Newsletter').make(function(schema) {

schema.define('email', 'Email', true);
schema.define('ip', 'String(80)');

// Saves the model into the database
schema.setSave(function(error, model, options, callback) {

model.datecreated = new Date();

NOSQL('newsletter').insert(model.$clean());

// Returns response
callback(SUCCESS(true));
});
});
10 changes: 10 additions & 0 deletions public/css/bootstrap.min.css

Large diffs are not rendered by default.

61 changes: 61 additions & 0 deletions public/css/default.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
/*auto*/

$font : 'Source Sans Pro';
.container { padding-left: 25px; padding-right: 25px; }

html,body { height: 100%; }
body { background-color: white; padding: 0; color: #AAB2BD; font-smoothing: antialiased; }
form { padding: 0; margin: 0; }

header { border-bottom: 1px solid #F0F0F0; padding: 15px 0; margin-bottom: 30px; }
header nav { float: right; margin: 5px 0 0 0; }
header nav a { margin-left: 20px; color: gray; }
header nav a:first-child { margin-left: 0; }
header nav .fa { margin-right: 5px; }
footer { text-align: center; font-size: 12px; padding: 50px 0; color: gray; border-top: 1px dotted #E0E0E0; margin: 40px 20px 0; }

.mainmenu-button { border: 1px solid #F0F0F0; background-color: white; outline: 0; border-radius: 4px; font-size: 18px; width: 34px; height: 30px; position: absolute; right: 20px; display: none; text-align: center; color: silver; padding: 1px 0 0 0; text-decoration: none !important; }
.mainmenu-visible { display: block; }

h1 { font-family: $font; margin: 10px 0 30px; padding: 0; font-size: 34px; font-weight: 400; color: #656D78; text-align: center; }
h1 b, h1 strong { font-weight: 700; }
h2 { font-family: $font; margin: 0 0 10px; padding: 0; font-size: 20px; font-weight: 400; color: gray; }
h2.large { font-size: 30px; margin-bottom: 15px; font-weight: 200; }

h3 { font-family: $font; margin: 0 0 10px; padding: 0; font-size: 20px; font-weight: 400; color: #656D78; }
h3.large { font-size: 30px; margin-bottom: 15px; font-weight: 200; }

.m { margin-bottom: 20px; }

.newsletter { background-color: #F0F0F0; margin: 20px 0; }
.newsletter-input { margin-right: 150px; padding: 0 20px; background-color: #F0F0F0; }
.newsletter-input input { width: 100%; background-color: transparent; border: 0; font-size: 16px; height: 40px; outline: 0; color: black; }
.newsletter-button { width: 150px; float: right; margin: 0; padding: 0; }
.newsletter-button button { width: 100%; background-color: #D0D0D0; border: 0; height: 40px; color: gray; }
.newsletter-button button:hover { background-color: black; color: white; }
.newsletter-button .fa { margin-right: 8px; font-size: 16px; }
.newsletter-success { color: #7B9B46 !important; }

.linkbutton { display: block; border: 2px solid #69AF44; padding: 20px 0; text-align: center; border-radius: 4px; color: #69AF44; font-family: $font; font-size: 20px; background-color: white; text-decoration: none; }
.linkbutton:hover { color: white; text-decoration: none; background-color: #69AF44; }
.linkbutton:focus { color: #69AF44; text-decoration: none; background-color: white; }
.linkbutton:active { box-shadow: inset 0 2px 5px rgba(0,0,0,0.1); color: white; background-color: #69AF44; }

.reference * { transition: all 0.5s; }
.reference a { position: relative; display: block; color: gray; }
.reference a:hover { text-decoration: none !important; }
.reference a:hover * { text-decoration: none; }
.reference a:hover span { background-color: #F0F0F0; color: black; }
.reference-title { display: block; padding: 10px 0; background-color: #F8F8F8; text-align: center; font-size: 12px; }
.reference b { display: block; font-size: 14px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.reference { margin-bottom: 30px; }

.message-success { background-color: #8CC152; color: white; padding: 18px 20px; text-align: center; font-size: 16px; }

@media (max-width: 767px) {
.mainmenu-button { display: block; }
header { padding-bottom: 15px; }
header nav { display: none; float: none; margin-top: 20px; }
header nav a { display: block; border-top: 1px solid #F0F0F0; margin: 3px 0; padding: 5px 0; font-size: 16px; }
header nav a:first-child { border-top: 0; }
}
33 changes: 33 additions & 0 deletions public/css/ui.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
/* Source: www.componentator.com */

.ui-textbox { border: 1px solid #E0E0E0; padding: 5px 2px 5px 5px; border-radius: 2px; position: relative; width: 100%; background-color: white; display: table; }
.ui-textbox input { display: table-cell; border: 0; outline: 0; font: normal 14px Arial; color: black; width: 100%; background-color: white; }
.ui-textbox div { width: 1%; position: relative; vertical-align: middle; display: table-cell; text-align: center; white-space: nowrap; text-overflow: clip; border-left: 1px solid #E0E0E0; width: 30px; color: silver; }
.ui-textbox-label { margin-bottom: 5px; font-size: 12px; color: #656D78; text-align: left; }
.ui-textbox-label .fa { width: 14px; }
.ui-textbox-label-required:before { color: red; content: '***'; margin-right: 5px; }
.ui-textbox-invalid { border: 1px solid #E1A1A1 !important; background-color: #FFF3F3 !important; }
.ui-textbox-invalid input { background-color: #FFF3F3 !important; }
.ui-textbox .fa-caret-up, .ui-textbox .fa-caret-down { display:block; line-height:9px; cursor: pointer; }

.ui-right { text-align: right; }
.ui-center { text-align: center; }
.ui-disabled { background-color: #F0F0F0; cursor: not-allowed; }
.ui-disabled > div { background-color: #F0F0F0; }

.ui-textarea { border: 1px solid #E0E0E0; padding: 4px 5px; border-radius: 2px; position: relative; display: block; width: 100%; background-color: white; }
.ui-textarea textarea { border: 0; width: 100%; outline: 0; font: normal 14px Arial; color: black; resize: none; min-height: 50px; background-color: white; padding: 0; }
.ui-textarea-label { margin-bottom: 5px; font-size: 12px; text-align: left; color: #656D78; }
.ui-textarea-label .fa { width: 14px; }
.ui-textarea-label-required:before { color: red; content: '***'; margin-right: 5px; }
.ui-textarea-invalid { border-color: #E7B8B8 !important; background-color: #FFF3F3 !important; }
.ui-textarea-invalid textarea { background-color: #FFF3F3 !important; }
.ui-textarea-code textarea { font-family: monospace; font-size: 14px; }

.hidden { display: none; }

.button { position: relative; display: inline-block; margin: 0; padding: 0; border: 2px solid #D0D0D0; border-radius: 4px; background-color: white; background: linear-gradient(white,#F0F0F0); padding: 20px 0; font: normal normal 14px Arial; vertical-align: middle; color: gray; width: 100%; }
.button:hover { border-color: silver; }
.button:active { background: white; color: #A4A4A4; }
.button:disabled { color: silver; border-color: #E0E0E0; cursor: not-allowed; background: white; }
.button-small { padding: 13px 0; }
Binary file added public/favicon.ico
Binary file not shown.
Binary file added public/img/001.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/002.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/003.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/image.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/reference.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/signature.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 7925644

Please sign in to comment.