├── public
├── app_ui_js
│ ├── service
│ │ └── userService.js
│ ├── EditBoard.js
│ └── ConfigBoard.js
├── css
│ ├── error.css
│ ├── sprites.png
│ ├── semantic
│ │ ├── themes
│ │ │ ├── basic
│ │ │ │ └── assets
│ │ │ │ │ └── fonts
│ │ │ │ │ ├── icons.eot
│ │ │ │ │ ├── icons.ttf
│ │ │ │ │ └── icons.woff
│ │ │ ├── default
│ │ │ │ └── assets
│ │ │ │ │ ├── fonts
│ │ │ │ │ ├── icons.eot
│ │ │ │ │ ├── icons.otf
│ │ │ │ │ ├── icons.ttf
│ │ │ │ │ ├── icons.woff
│ │ │ │ │ └── icons.woff2
│ │ │ │ │ └── images
│ │ │ │ │ └── flags.png
│ │ │ └── github
│ │ │ │ └── assets
│ │ │ │ └── fonts
│ │ │ │ ├── octicons.ttf
│ │ │ │ ├── octicons.woff
│ │ │ │ └── octicons-local.ttf
│ │ └── components
│ │ │ ├── sticky.min.css
│ │ │ ├── tab.min.css
│ │ │ ├── rail.min.css
│ │ │ ├── breadcrumb.min.css
│ │ │ ├── video.min.css
│ │ │ ├── nag.min.css
│ │ │ ├── sticky.css
│ │ │ ├── site.min.css
│ │ │ ├── embed.min.css
│ │ │ ├── container.min.css
│ │ │ ├── shape.min.css
│ │ │ ├── ad.min.css
│ │ │ ├── tab.css
│ │ │ ├── reset.min.css
│ │ │ ├── dimmer.min.css
│ │ │ ├── comment.min.css
│ │ │ ├── breadcrumb.css
│ │ │ ├── rail.css
│ │ │ ├── video.css
│ │ │ ├── colorize.min.js
│ │ │ ├── nag.css
│ │ │ ├── loader.min.css
│ │ │ ├── image.min.css
│ │ │ ├── site.css
│ │ │ ├── feed.min.css
│ │ │ ├── container.css
│ │ │ ├── shape.css
│ │ │ ├── embed.css
│ │ │ ├── popup.min.css
│ │ │ ├── dimmer.css
│ │ │ ├── rating.min.js
│ │ │ ├── ad.css
│ │ │ ├── nag.min.js
│ │ │ ├── item.min.css
│ │ │ ├── visit.min.js
│ │ │ ├── message.min.css
│ │ │ ├── search.min.css
│ │ │ ├── video.min.js
│ │ │ ├── comment.css
│ │ │ ├── divider.min.css
│ │ │ └── reveal.min.css
│ ├── bootstrap-colorpicker.min.css
│ └── bootstrap-colorpicker.css
├── images
│ ├── 1.png
│ ├── bg.png
│ ├── logo.png
│ ├── avatar.jpg
│ ├── favicon.ico
│ ├── pointer.png
│ └── file-img.png
├── fonts
│ ├── FontAwesome.otf
│ ├── fontawesome-webfont.eot
│ ├── fontawesome-webfont.ttf
│ ├── fontawesome-webfont.woff
│ ├── fontawesome-webfont.woff2
│ ├── glyphicons-halflings-regular.eot
│ ├── glyphicons-halflings-regular.ttf
│ ├── glyphicons-halflings-regular.woff
│ └── glyphicons-halflings-regular.woff2
├── img
│ └── bootstrap-colorpicker
│ │ ├── hue.png
│ │ ├── alpha.png
│ │ ├── saturation.png
│ │ ├── hue-horizontal.png
│ │ └── alpha-horizontal.png
└── app_3th_js
│ ├── forIE
│ ├── html5shiv.min.js
│ └── respond.min.js
│ └── jQuery
│ └── jquery.mousewheel.min.js
├── app_modules
├── _utils
│ ├── communication.js
│ ├── utils.js
│ ├── messageGenerator.js
│ └── uuidGenerator.js
├── users_mgmt
│ ├── userService.js
│ ├── userDao.js
│ └── userController.js
├── items_mgmt
│ ├── itemController.js
│ ├── itemDao.js
│ └── itemService.js
├── files_mgmt
│ ├── fileController.js
│ ├── fileService.js
│ └── fileDao.js
└── AbstractDao.js
├── config.json
├── README.md
├── package.json
├── views
├── error.ejs
├── index.ejs
└── login.ejs
├── config.js
├── app_db
└── dataSource.js
├── .gitignore
├── app_draw
└── routes
└── root.js
/public/app_ui_js/service/userService.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2016/3/8.
3 | */
4 |
--------------------------------------------------------------------------------
/public/css/error.css:
--------------------------------------------------------------------------------
1 | body{
2 | font-family:微软雅黑;
3 | background: #F4F6F8;
4 | }
5 |
6 |
--------------------------------------------------------------------------------
/public/images/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/images/1.png
--------------------------------------------------------------------------------
/public/images/bg.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/images/bg.png
--------------------------------------------------------------------------------
/public/css/sprites.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/sprites.png
--------------------------------------------------------------------------------
/public/images/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/images/logo.png
--------------------------------------------------------------------------------
/public/images/avatar.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/images/avatar.jpg
--------------------------------------------------------------------------------
/public/images/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/images/favicon.ico
--------------------------------------------------------------------------------
/public/images/pointer.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/images/pointer.png
--------------------------------------------------------------------------------
/public/images/file-img.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/images/file-img.png
--------------------------------------------------------------------------------
/public/fonts/FontAwesome.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/FontAwesome.otf
--------------------------------------------------------------------------------
/app_modules/_utils/communication.js:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/app_modules/_utils/communication.js
--------------------------------------------------------------------------------
/app_modules/users_mgmt/userService.js:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/app_modules/users_mgmt/userService.js
--------------------------------------------------------------------------------
/public/fonts/fontawesome-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/fontawesome-webfont.eot
--------------------------------------------------------------------------------
/public/fonts/fontawesome-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/fontawesome-webfont.ttf
--------------------------------------------------------------------------------
/public/fonts/fontawesome-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/fontawesome-webfont.woff
--------------------------------------------------------------------------------
/public/fonts/fontawesome-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/fontawesome-webfont.woff2
--------------------------------------------------------------------------------
/public/img/bootstrap-colorpicker/hue.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/img/bootstrap-colorpicker/hue.png
--------------------------------------------------------------------------------
/public/img/bootstrap-colorpicker/alpha.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/img/bootstrap-colorpicker/alpha.png
--------------------------------------------------------------------------------
/public/fonts/glyphicons-halflings-regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/glyphicons-halflings-regular.eot
--------------------------------------------------------------------------------
/public/fonts/glyphicons-halflings-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/glyphicons-halflings-regular.ttf
--------------------------------------------------------------------------------
/public/fonts/glyphicons-halflings-regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/glyphicons-halflings-regular.woff
--------------------------------------------------------------------------------
/public/fonts/glyphicons-halflings-regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/fonts/glyphicons-halflings-regular.woff2
--------------------------------------------------------------------------------
/public/img/bootstrap-colorpicker/saturation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/img/bootstrap-colorpicker/saturation.png
--------------------------------------------------------------------------------
/public/img/bootstrap-colorpicker/hue-horizontal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/img/bootstrap-colorpicker/hue-horizontal.png
--------------------------------------------------------------------------------
/public/css/semantic/themes/basic/assets/fonts/icons.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/basic/assets/fonts/icons.eot
--------------------------------------------------------------------------------
/public/css/semantic/themes/basic/assets/fonts/icons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/basic/assets/fonts/icons.ttf
--------------------------------------------------------------------------------
/public/img/bootstrap-colorpicker/alpha-horizontal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/img/bootstrap-colorpicker/alpha-horizontal.png
--------------------------------------------------------------------------------
/public/css/semantic/themes/basic/assets/fonts/icons.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/basic/assets/fonts/icons.woff
--------------------------------------------------------------------------------
/public/css/semantic/themes/default/assets/fonts/icons.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/default/assets/fonts/icons.eot
--------------------------------------------------------------------------------
/public/css/semantic/themes/default/assets/fonts/icons.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/default/assets/fonts/icons.otf
--------------------------------------------------------------------------------
/public/css/semantic/themes/default/assets/fonts/icons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/default/assets/fonts/icons.ttf
--------------------------------------------------------------------------------
/public/css/semantic/themes/default/assets/fonts/icons.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/default/assets/fonts/icons.woff
--------------------------------------------------------------------------------
/public/css/semantic/themes/default/assets/fonts/icons.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/default/assets/fonts/icons.woff2
--------------------------------------------------------------------------------
/public/css/semantic/themes/default/assets/images/flags.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/default/assets/images/flags.png
--------------------------------------------------------------------------------
/public/css/semantic/themes/github/assets/fonts/octicons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/github/assets/fonts/octicons.ttf
--------------------------------------------------------------------------------
/public/css/semantic/themes/github/assets/fonts/octicons.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/github/assets/fonts/octicons.woff
--------------------------------------------------------------------------------
/public/css/semantic/themes/github/assets/fonts/octicons-local.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Eamonnzhang/multi-draw/HEAD/public/css/semantic/themes/github/assets/fonts/octicons-local.ttf
--------------------------------------------------------------------------------
/app_modules/_utils/utils.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/16.
3 | */
4 | exports.extend = function(sub,sup){
5 | var f = function(){};
6 | f.prototype = sup.prototype;
7 | sub.prototype = new f();
8 | sub.prototype.constructor = sub;
9 | };
--------------------------------------------------------------------------------
/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "runMode":"dev",
3 | "port": "4500",
4 | "dbUrl": "mongodb://localhost:27017/multidraw",
5 | "loginUrl":{
6 | "dev":"/login",
7 | "production":"http://www.xuezuowang.com/login"
8 | },
9 | "cookieInfo":{
10 | "dev":{
11 | "maxAge": 5400000
12 | },
13 | "production":{
14 | "maxAge": 5400000,
15 | "domain":".xuezuowang.com"
16 | }
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # MutilDraw
2 | ## Usage
3 | node app
4 | >OnlineDemo : http://draw.eamonn.cn
5 |
6 | ## Canvas Library
7 | Fabric.js
8 | >Official Site : http://fabricjs.com/
9 |
10 | ## DataBase
11 | MongoDB
12 | >中文社区 : http://www.mongoing.com/
13 |
14 | >Official Site : https://www.mongodb.org/
15 |
16 | ## Functions
17 | * 最基本的绘画功能
18 | * 实时同步(Socket.io)
19 | * 可以插入文字、图片、视频
20 | * 可以导出为PNG,SVG或者JSON
21 | * 待更新.....
22 |
23 |
24 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "multidraw",
3 | "version": "0.0.1",
4 | "private": true,
5 | "scripts": {
6 | "start": "node ./bin/www"
7 | },
8 | "dependencies": {
9 | "body-parser": "~1.13.2",
10 | "cookie-parser": "~1.3.5",
11 | "debug": "~2.2.0",
12 | "express": "~4.13.1",
13 | "socket.io": "1.4.3",
14 | "morgan": "~1.6.1",
15 | "serve-favicon": "~2.3.0",
16 | "mongodb": "2.0.39",
17 | "ejs": "2.3.4",
18 | "sessionstore":"1.2.3",
19 | "express-session":"1.11.3",
20 | "node-uuid": "1.4.3",
21 | "moment":"2.11.0",
22 | "session-file-store": "0.0.20",
23 | "connect-mongo":"1.1.0"
24 | }
25 | }
--------------------------------------------------------------------------------
/views/error.ejs:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Error
6 |
7 |
8 |
9 |
13 |
14 |
15 |
16 |
<%= message %>
17 |
<%= error.status %>
18 |
<%= error.stack %>
19 |
20 |
21 |
--------------------------------------------------------------------------------
/public/css/semantic/components/sticky.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Sticky
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.sticky{position:static;-webkit-transition:none;transition:none;z-index:800}.ui.sticky.bound{position:absolute;left:auto;right:auto}.ui.sticky.fixed{position:fixed;left:auto;right:auto}.ui.sticky.bound.top,.ui.sticky.fixed.top{top:0;bottom:auto}.ui.sticky.bound.bottom,.ui.sticky.fixed.bottom{top:auto;bottom:0}.ui.native.sticky{position:-webkit-sticky;position:-moz-sticky;position:-ms-sticky;position:-o-sticky;position:sticky}
--------------------------------------------------------------------------------
/app_modules/_utils/messageGenerator.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by DISI on 17.07.2015.
3 | */
4 |
5 |
6 | var messageType = {
7 | SYS_ERR: 'sys_err'
8 | };
9 |
10 | var BasicMessage = function (isSuccess, type, message, data) {
11 | this.success = isSuccess;
12 | this.type = type;
13 | this.msg = message;
14 | this.data = data;
15 | };
16 |
17 | exports.genSimpSuccessMsg = function(message, value){
18 | return new BasicMessage(true, null, message, value);
19 | };
20 | exports.genSimpFailedMsg = function(message, value){
21 | return new BasicMessage(false, null, message, value);
22 | };
23 |
24 | exports.genSysErrMsg = function(errMsg){
25 | return new BasicMessage(false, messageType.SYS_ERR, errMsg.message, null);
26 | };
27 |
28 |
--------------------------------------------------------------------------------
/config.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/9/17.
3 | */
4 | var express = require('express');
5 | var path = require('path');
6 | var favicon = require('serve-favicon');
7 | var logger = require('morgan');
8 | var cookieParser = require('cookie-parser');
9 | var bodyParser = require('body-parser');
10 | var app = express();
11 |
12 | // view engine setup
13 | app.set('views', path.join(__dirname, 'views'));
14 | app.set('view engine', 'ejs');
15 |
16 | app.use(favicon(path.join(__dirname, 'public/images', 'favicon.ico')));
17 | app.use(logger('dev'));
18 | app.use(bodyParser.urlencoded({extended: false,limit: '100mb'}));
19 | app.use(bodyParser.json({limit: '100mb'}));
20 | app.use(cookieParser());
21 | app.use(express.static(path.join(__dirname, 'public')));
22 |
23 | module.exports = app;
24 |
--------------------------------------------------------------------------------
/app_db/dataSource.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/15.
3 | */
4 | var MongoClient = require('mongodb').MongoClient;
5 | var ObjectID = require('mongodb').ObjectID;
6 | var multidrawDb;
7 |
8 | exports.connectDb=function(url, next){
9 | MongoClient.connect(url, function(err, dbInstance) {
10 | if(err){
11 | console.log('ERROR: Connection to database cannot to be established. \n' +
12 | 'Please check if the database has been started.');
13 | }else{
14 | console.log("Database connection established.");
15 | multidrawDb = dbInstance;
16 | next(multidrawDb);
17 | }
18 | });
19 | };
20 | exports.getDB=function(){
21 | return multidrawDb;
22 | };
23 | exports.getObjectId=function(){
24 | return ObjectID;
25 | };
26 |
--------------------------------------------------------------------------------
/app_modules/_utils/uuidGenerator.js:
--------------------------------------------------------------------------------
1 | exports.generateId = function (len, radix) {
2 | var CHARS = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz'.split('');
3 | Math.uuid = function (len, radix) {
4 | var chars = CHARS, uuid = [], i;
5 | radix = radix || chars.length;
6 | if (len) {
7 | for (i = 0; i < len; i++) uuid[i] = chars[0 | Math.random() * radix];
8 | } else {
9 | var r;
10 | uuid[8] = uuid[13] = uuid[18] = uuid[23] = '-';
11 | uuid[14] = '4';
12 | for (i = 0; i < 36; i++) {
13 | if (!uuid[i]) {
14 | r = 0 | Math.random() * 16;
15 | uuid[i] = chars[(i == 19) ? (r & 0x3) | 0x8 : r];
16 | }
17 | }
18 | }
19 | return uuid.join('');
20 | };
21 | return Math.uuid(len, radix);
22 | };
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Windows image file caches
2 | Thumbs.db
3 | ehthumbs.db
4 |
5 | # Folder config file
6 | Desktop.ini
7 |
8 | # Recycle Bin used on file shares
9 | $RECYCLE.BIN/
10 |
11 | # Windows Installer files
12 | *.cab
13 | *.msi
14 | *.msm
15 | *.msp
16 |
17 | # Windows shortcuts
18 | *.lnk
19 |
20 | # =========================
21 | # Operating System Files
22 | # =========================
23 |
24 | # OSX
25 | # =========================
26 |
27 | .DS_Store
28 | .AppleDouble
29 | .LSOverride
30 |
31 | # Thumbnails
32 | ._*
33 |
34 | # Files that might appear on external disk
35 | .Spotlight-V100
36 | .Trashes
37 |
38 | # Directories potentially created on remote AFP share
39 | .AppleDB
40 | .AppleDesktop
41 | Network Trash Folder
42 | Temporary Items
43 | .apdisk
44 |
45 | # ignore node_modules
46 | node_modules/
47 | *.log
48 | *.iml
49 |
50 | # ignore project setting
51 | .idea/
52 | .svn/
53 | .c9/
54 |
55 |
56 |
57 |
--------------------------------------------------------------------------------
/public/css/semantic/components/tab.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Tab
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.tab{display:none}.ui.tab.active,.ui.tab.open{display:block}.ui.tab.loading{position:relative;overflow:hidden;display:block;min-height:250px}.ui.tab.loading *{position:relative!important;left:-10000px!important}.ui.tab.loading.segment:before,.ui.tab.loading:before{position:absolute;content:'';top:100px;left:50%;margin:-1.25em 0 0 -1.25em;width:2.5em;height:2.5em;border-radius:500rem;border:.2em solid rgba(0,0,0,.1)}.ui.tab.loading.segment:after,.ui.tab.loading:after{position:absolute;content:'';top:100px;left:50%;margin:-1.25em 0 0 -1.25em;width:2.5em;height:2.5em;-webkit-animation:button-spin .6s linear;animation:button-spin .6s linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;border-radius:500rem;border-color:#767676 transparent transparent;border-style:solid;border-width:.2em;box-shadow:0 0 0 1px transparent}
--------------------------------------------------------------------------------
/app_modules/items_mgmt/itemController.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2016/1/11.
3 | */
4 |
5 | var itemService = require('./itemService.js');
6 | var moment = require('moment');
7 |
8 | //post
9 | exports.saveItem = function (req,res) {
10 | var user = req.session.userData;
11 | var data = req.body;
12 | itemService.saveItem(data,user,function (result) {
13 | res.send(result);
14 | });
15 | };
16 |
17 | //get
18 | exports.findItemsInCanvas= function (req,res) {
19 | var data = {
20 | canvasId : req.query.canvasId
21 | };
22 | itemService.findItemsInCanvas(data, function (result) {
23 | res.send(result);
24 | })
25 | };
26 |
27 | //post
28 | exports.deleteItem= function (req,res) {
29 | var data = req.body;
30 | console.log(data);
31 | itemService.deleteItemInCanvas(data, function (result) {
32 | res.send(result);
33 | })
34 | };
35 |
36 | //post
37 | exports.updateItem= function (req,res) {
38 | var data = req.body;
39 | console.log(data);
40 | itemService.updateItemInCanvas(data, function (result) {
41 | res.send(result);
42 | })
43 | };
44 |
45 |
--------------------------------------------------------------------------------
/public/css/semantic/components/rail.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Rail
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.rail{position:absolute;top:0;width:300px;height:100%;font-size:1rem}.ui.left.rail{left:auto;right:100%;padding:0 2rem 0 0;margin:0 2rem 0 0}.ui.right.rail{left:100%;right:auto;padding:0 0 0 2rem;margin:0 0 0 2rem}.ui.left.internal.rail{left:0;right:auto;padding:0 0 0 2rem;margin:0 0 0 2rem}.ui.right.internal.rail{left:auto;right:0;padding:0 2rem 0 0;margin:0 2rem 0 0}.ui.dividing.rail{width:302.5px}.ui.left.dividing.rail{padding:0 2.5rem 0 0;margin:0 2.5rem 0 0;border-right:1px solid rgba(34,36,38,.15)}.ui.right.dividing.rail{border-left:1px solid rgba(34,36,38,.15);padding:0 0 0 2.5rem;margin:0 0 0 2.5rem}.ui.close.rail{width:301px}.ui.close.left.rail{padding:0 1em 0 0;margin:0 1em 0 0}.ui.close.right.rail{padding:0 0 0 1em;margin:0 0 0 1em}.ui.very.close.rail{width:300.5px}.ui.very.close.left.rail{padding:0 .5em 0 0;margin:0 .5em 0 0}.ui.very.close.right.rail{padding:0 0 0 .5em;margin:0 0 0 .5em}.ui.attached.left.rail,.ui.attached.right.rail{padding:0;margin:0}
--------------------------------------------------------------------------------
/app_modules/items_mgmt/itemDao.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2016/1/11.
3 | */
4 | var AbstractDao = require('./../AbstractDao.js');
5 | var utils = require('./../_utils/utils.js');
6 | var message = require('../_utils/messageGenerator.js');
7 |
8 | var itemDao = function(collectionName,dbInstance){
9 | AbstractDao.call(this,collectionName,dbInstance);
10 | };
11 |
12 | utils.extend(itemDao,AbstractDao);
13 |
14 | itemDao.prototype.saveItem = function (data,next) {
15 | this.insertOne(data,next);
16 | };
17 |
18 | itemDao.prototype.deleteItemInCanvas = function (query,canvasId,next) {
19 | query.canvasId = canvasId;
20 | this.deleteOne(query,next);
21 | };
22 |
23 | itemDao.prototype.deleteAllItemsInCanvas = function (canvasId,next) {
24 | this.deleteMany({canvasId:canvasId},next);
25 | };
26 |
27 | itemDao.prototype.updateItemInCanvas = function (query,canvasId,update,next) {
28 | query.canvasId = canvasId;
29 | console.log('query',query);
30 | console.log('update',update);
31 | this.updateOne(query,update,next);
32 | };
33 |
34 | itemDao.prototype.findItemsInCanvas = function (canvasId,next) {
35 | this.findMany({canvasId : canvasId},next);
36 | };
37 |
38 | module.exports = itemDao;
39 |
40 |
41 |
--------------------------------------------------------------------------------
/public/css/semantic/components/breadcrumb.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Breadcrumb
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.breadcrumb{line-height:1;display:inline-block;margin:0;vertical-align:middle}.ui.breadcrumb:first-child{margin-top:0}.ui.breadcrumb:last-child{margin-bottom:0}.ui.breadcrumb .divider{display:inline-block;opacity:.7;margin:0 .21428571rem;font-size:.92857143em;color:rgba(0,0,0,.4);vertical-align:baseline}.ui.breadcrumb a{color:#4183c4}.ui.breadcrumb a:hover{color:#1e70bf}.ui.breadcrumb .icon.divider{font-size:.85714286em;vertical-align:baseline}.ui.breadcrumb a.section{cursor:pointer}.ui.breadcrumb .section{display:inline-block;margin:0;padding:0}.ui.breadcrumb.segment{display:inline-block;padding:.71428571em 1em}.ui.breadcrumb .active.section{font-weight:700}.ui.mini.breadcrumb{font-size:.71428571rem}.ui.tiny.breadcrumb{font-size:.85714286rem}.ui.small.breadcrumb{font-size:.92857143rem}.ui.breadcrumb{font-size:1rem}.ui.large.breadcrumb{font-size:1.14285714rem}.ui.big.breadcrumb{font-size:1.28571429rem}.ui.huge.breadcrumb{font-size:1.42857143rem}.ui.massive.breadcrumb{font-size:1.71428571rem}
--------------------------------------------------------------------------------
/public/css/semantic/components/video.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.0.0 - Video
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2014 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.video{background-color:#ddd;position:relative;max-width:100%;padding-bottom:56.25%;height:0;overflow:hidden}.ui.video .placeholder{background-color:#333}.ui.video .play{cursor:pointer;position:absolute;top:0;left:0;z-index:10;width:100%;height:100%;background:0 0;-webkit-transition:background .2s ease;transition:background .2s ease}.ui.video .play.icon:before{position:absolute;top:50%;left:50%;z-index:11;-webkit-transform:translateX(-50%)translateY(-50%);-ms-transform:translateX(-50%)translateY(-50%);transform:translateX(-50%)translateY(-50%);color:rgba(255,255,255,.7);font-size:7rem;text-shadow:2px 2px 0 rgba(0,0,0,.15);-webkit-transition:color .2s ease;transition:color .2s ease}.ui.video .placeholder{position:absolute;top:0;left:0;display:block;width:100%;height:100%}.ui.video .embed embed,.ui.video .embed iframe,.ui.video .embed object{position:absolute;border:none;width:100%;height:100%;top:0;left:0;margin:0;padding:0}.ui.video .play:hover{background:0 0}.ui.video .play:hover:before{color:#fff}.ui.active.video .placeholder,.ui.active.video .play{display:none}.ui.active.video .embed{display:inline}
--------------------------------------------------------------------------------
/app_modules/items_mgmt/itemService.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2016/1/11.
3 | */
4 |
5 | var itemDao = new (require('./itemDao.js'))('canvasItems');
6 | var message = require('./../_utils/messageGenerator.js');
7 |
8 | exports.saveItem = function (data,user,next) {
9 | data.createUserId = user.id;
10 | data.createUserName = user.name;
11 | itemDao.saveItem(data,next);
12 | };
13 |
14 | /**
15 | * @param data
16 | * data = {
17 | * canvasId: canvasId,
18 | * items : [{itemId:itemId,prop:propValue,...},{},{}]
19 | * }
20 | * @param next
21 | */
22 | exports.updateItemInCanvas = function (data,next) {
23 | if(Array.isArray(data.items)){
24 | data.items.forEach(function (obj) {
25 | var itemId = obj.itemId;
26 | delete obj.itemId;
27 | itemDao.updateItemInCanvas({itemId :itemId},data.canvasId,obj,next);
28 | })
29 | }
30 | };
31 |
32 | exports.findItemsInCanvas = function (data,next) {
33 | itemDao.findItemsInCanvas(data.canvasId,next);
34 | };
35 |
36 | /**
37 | * @param data
38 | * data = {
39 | * canvasId : canvasId,
40 | * itemsId : [id1,id2,...]
41 | * }
42 | * @param next
43 | */
44 |
45 | exports.deleteItemInCanvas = function (data,next) {
46 | if(Array.isArray(data.itemsId)){
47 | data.itemsId.forEach(function (id) {
48 | itemDao.deleteItemInCanvas({itemId : id},data.canvasId,next);
49 | })
50 | }
51 | };
52 |
53 |
--------------------------------------------------------------------------------
/public/css/semantic/components/nag.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Nag
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.nag{display:none;opacity:.95;position:relative;top:0;left:0;z-index:999;min-height:0;width:100%;margin:0;padding:.75em 1em;background:#555;box-shadow:0 1px 2px 0 rgba(0,0,0,.2);font-size:1rem;text-align:center;color:rgba(0,0,0,.87);border-radius:0 0 .28571429rem .28571429rem;-webkit-transition:.2s background ease;transition:.2s background ease}a.ui.nag{cursor:pointer}.ui.nag>.title{display:inline-block;margin:0 .5em;color:#fff}.ui.nag>.close.icon{cursor:pointer;opacity:.4;position:absolute;top:50%;right:1em;font-size:1em;margin:-.5em 0 0;color:#fff;-webkit-transition:opacity .2s ease;transition:opacity .2s ease}.ui.nag:hover{background:#555;opacity:1}.ui.nag .close:hover{opacity:1}.ui.overlay.nag{position:absolute;display:block}.ui.fixed.nag{position:fixed}.ui.bottom.nag,.ui.bottom.nags{border-radius:.28571429rem .28571429rem 0 0;top:auto;bottom:0}.ui.inverted.nag,.ui.inverted.nags .nag{background-color:#f3f4f5;color:rgba(0,0,0,.85)}.ui.inverted.nag .close,.ui.inverted.nag .title,.ui.inverted.nags .nag .close,.ui.inverted.nags .nag .title{color:rgba(0,0,0,.4)}.ui.nags .nag{border-radius:0!important}.ui.nags .nag:last-child{border-radius:0 0 .28571429rem .28571429rem}.ui.bottom.nags .nag:last-child{border-radius:.28571429rem .28571429rem 0 0}
--------------------------------------------------------------------------------
/app_modules/users_mgmt/userDao.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/20.
3 | */
4 |
5 | var AbstractDao = require('../AbstractDao.js');
6 | var utils = require('../_utils/utils.js');
7 | var message = require('../_utils/messageGenerator.js');
8 |
9 | var userDao = function(collectionName){
10 | AbstractDao.call(this,collectionName);
11 | };
12 |
13 | utils.extend(userDao,AbstractDao);
14 |
15 | userDao.prototype.addUser = function (user,next) {
16 | this.insertOne(user,next);
17 | };
18 |
19 | userDao.prototype.loadAll = function (reg,next) {
20 | var query = {
21 | name : reg
22 | };
23 | this.dataCollection.find(query).toArray(function (err, data) {
24 | if (err) {
25 | next(message.genSimpFailedMsg(null,err));
26 | } else {
27 | next(message.genSimpSuccessMsg(null, data));
28 | }
29 | });
30 | };
31 |
32 | userDao.prototype.addParticipants = function (participants, next) {
33 | this.insertMany(participants,next);
34 | };
35 |
36 | userDao.prototype.getParticipants = function (canvasId, next) {
37 | var query = {
38 | canvasId : canvasId
39 | };
40 | this.findMany(query,next);
41 | };
42 |
43 | userDao.prototype.removeParticipants = function (query,next) {
44 | this.deleteOne(query,next);
45 | };
46 |
47 | userDao.prototype.updateParticipants = function (query,updateData,next) {
48 | this.updateOne(query,updateData,next);
49 | };
50 |
51 | userDao.prototype.isExist = function (query,next) {
52 | this.findOne(query,next);
53 | };
54 |
55 | module.exports = userDao;
--------------------------------------------------------------------------------
/public/css/semantic/components/sticky.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Sticky
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Sticky
15 | *******************************/
16 |
17 | .ui.sticky {
18 | position: static;
19 | -webkit-transition: none;
20 | transition: none;
21 | z-index: 800;
22 | }
23 |
24 |
25 | /*******************************
26 | States
27 | *******************************/
28 |
29 |
30 | /* Bound */
31 | .ui.sticky.bound {
32 | position: absolute;
33 | left: auto;
34 | right: auto;
35 | }
36 |
37 | /* Fixed */
38 | .ui.sticky.fixed {
39 | position: fixed;
40 | left: auto;
41 | right: auto;
42 | }
43 |
44 | /* Bound/Fixed Position */
45 | .ui.sticky.bound.top,
46 | .ui.sticky.fixed.top {
47 | top: 0px;
48 | bottom: auto;
49 | }
50 | .ui.sticky.bound.bottom,
51 | .ui.sticky.fixed.bottom {
52 | top: auto;
53 | bottom: 0px;
54 | }
55 |
56 |
57 | /*******************************
58 | Types
59 | *******************************/
60 |
61 | .ui.native.sticky {
62 | position: -webkit-sticky;
63 | position: -moz-sticky;
64 | position: -ms-sticky;
65 | position: -o-sticky;
66 | position: sticky;
67 | }
68 |
69 |
70 | /*******************************
71 | Theme Overrides
72 | *******************************/
73 |
74 |
75 |
76 | /*******************************
77 | Site Overrides
78 | *******************************/
79 |
80 |
--------------------------------------------------------------------------------
/public/css/semantic/components/site.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Site
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */@import url(https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic&subset=latin);body,html{height:100%}html{font-size:14px}body{margin:0;padding:0;overflow-x:hidden;min-width:320px;background:#fff;font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;font-size:14px;line-height:1.4285em;color:rgba(0,0,0,.87);font-smoothing:antialiased}h1,h2,h3,h4,h5{font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;line-height:1.2857em;margin:calc(2rem - .14285em) 0 1rem;font-weight:700;padding:0}h1{min-height:1rem;font-size:2rem}h2{font-size:1.714rem}h3{font-size:1.28rem}h4{font-size:1.071rem}h5{font-size:1rem}h1:first-child,h2:first-child,h3:first-child,h4:first-child,h5:first-child,p:first-child{margin-top:0}h1:last-child,h2:last-child,h3:last-child,h4:last-child,h5:last-child,p:last-child{margin-bottom:0}p{margin:0 0 1em;line-height:1.4285em}a{color:#4183c4;text-decoration:none}a:hover{color:#1e70bf;text-decoration:none}::-webkit-selection{background-color:#cce2ff;color:rgba(0,0,0,.87)}::-moz-selection{background-color:#cce2ff;color:rgba(0,0,0,.87)}::selection{background-color:#cce2ff;color:rgba(0,0,0,.87)}input::-webkit-selection,textarea::-webkit-selection{background-color:rgba(100,100,100,.4);color:rgba(0,0,0,.87)}input::-moz-selection,textarea::-moz-selection{background-color:rgba(100,100,100,.4);color:rgba(0,0,0,.87)}input::selection,textarea::selection{background-color:rgba(100,100,100,.4);color:rgba(0,0,0,.87)}
--------------------------------------------------------------------------------
/public/css/semantic/components/embed.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Video
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.embed{position:relative;max-width:100%;height:0;overflow:hidden;background:#dcddde;padding-bottom:56.25%}.ui.embed embed,.ui.embed iframe,.ui.embed object{position:absolute;border:none;width:100%;height:100%;top:0;left:0;margin:0;padding:0}.ui.embed>.embed{display:none}.ui.embed>.placeholder{position:absolute;cursor:pointer;top:0;left:0;display:block;width:100%;height:100%;background-color:radial-gradient(transparent 45%,rgba(0,0,0,.3))}.ui.embed>.icon{cursor:pointer;position:absolute;top:0;left:0;width:100%;height:100%;z-index:2}.ui.embed>.icon:after{position:absolute;top:0;left:0;width:100%;height:100%;z-index:3;content:'';background:-webkit-radial-gradient(transparent 45%,rgba(0,0,0,.3));background:radial-gradient(transparent 45%,rgba(0,0,0,.3));opacity:.5;-webkit-transition:opacity .5s ease;transition:opacity .5s ease}.ui.embed>.icon:before{position:absolute;top:50%;left:50%;-webkit-transform:translateX(-50%) translateY(-50%);-ms-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%);color:#fff;font-size:6rem;text-shadow:0 2px 10px rgba(34,36,38,.2);-webkit-transition:opacity .5s ease,color .5s ease;transition:opacity .5s ease,color .5s ease;z-index:10}.ui.embed .icon:hover:after{background:-webkit-radial-gradient(transparent 45%,rgba(0,0,0,.3));background:radial-gradient(transparent 45%,rgba(0,0,0,.3));opacity:1}.ui.embed .icon:hover:before{color:#fff}.ui.active.embed>.icon,.ui.active.embed>.placeholder{display:none}.ui.active.embed>.embed{display:block}.ui.square.embed{padding-bottom:100%}.ui[class*="4:3"].embed{padding-bottom:75%}.ui[class*="16:9"].embed{padding-bottom:56.25%}.ui[class*="21:9"].embed{padding-bottom:42.85714286%}
--------------------------------------------------------------------------------
/public/css/semantic/components/container.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Container
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.container{display:block;max-width:100%!important}@media only screen and (max-width:767px){.ui.container{width:auto!important;margin-left:1em!important;margin-right:1em!important}.ui.grid.container,.ui.relaxed.grid.container,.ui.very.relaxed.grid.container{width:auto!important}}@media only screen and (min-width:768px) and (max-width:991px){.ui.container{width:723px;margin-left:auto!important;margin-right:auto!important}.ui.grid.container{width:calc(723px + 2rem)!important}.ui.relaxed.grid.container{width:calc(723px + 3rem)!important}.ui.very.relaxed.grid.container{width:calc(723px + 5rem)!important}}@media only screen and (min-width:992px) and (max-width:1199px){.ui.container{width:933px;margin-left:auto!important;margin-right:auto!important}.ui.grid.container{width:calc(933px + 2rem)!important}.ui.relaxed.grid.container{width:calc(933px + 3rem)!important}.ui.very.relaxed.grid.container{width:calc(933px + 5rem)!important}}@media only screen and (min-width:1200px){.ui.container{width:1127px;margin-left:auto!important;margin-right:auto!important}.ui.grid.container{width:calc(1127px + 2rem)!important}.ui.relaxed.grid.container{width:calc(1127px + 3rem)!important}.ui.very.relaxed.grid.container{width:calc(1127px + 5rem)!important}}.ui.text.container{font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;max-width:700px!important;line-height:1.5;font-size:1.14285714rem}.ui.fluid.container{width:100%}.ui[class*="left aligned"].container{text-align:left}.ui[class*="center aligned"].container{text-align:center}.ui[class*="right aligned"].container{text-align:right}.ui.justified.container{text-align:justify;-webkit-hyphens:auto;-moz-hyphens:auto;-ms-hyphens:auto;hyphens:auto}
--------------------------------------------------------------------------------
/public/app_ui_js/EditBoard.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/9/26.
3 | * you can get every related Objects in EditBoard
4 | * and if you don't know where to put your code,put them here temporarily
5 | */
6 | var EditBoard = function (){
7 | this.socket = io.connect();
8 | var canvas = this.canvas = new fabric.Canvas('c', {
9 | backgroundColor :"#ffffff",
10 | width:750,
11 | height:530,
12 | isDrawingMode:false,
13 | id:canvasId
14 | });
15 | //if(canvasId) this.canvas.id = canvasId;
16 | var configBoard = this.configBord = new ConfigBoard(this);
17 | fabric.Object.prototype.transparentCorners = false;
18 | canvas.add();//chrome抽了,= =必须要加一句为了显示空白canvas
19 |
20 | //监听window的缩放事件 使滚动条始终居中
21 | window.onresize = mdUtils.bind(configBoard,configBoard.resetScroll);
22 | //初始化canvas和滚动条位置,使二者均居中
23 | configBoard.initCanvasPos();
24 |
25 | $(function () { $("[data-toggle='tooltip']").tooltip({container: 'body'}); });
26 |
27 | $('#zoom-in').on('click',mdUtils.bind(configBoard,configBoard.zoomInCanvas));
28 | $('#zoom-out').on('click',mdUtils.bind(configBoard,configBoard.zoomOutCanvas));
29 | $('#customizedCanvas').on('click', mdUtils.bind(configBoard,configBoard.customizedCanvas));
30 |
31 | $('#console-info').on('click', function () {
32 | canvas.getActiveObject()&&console.log(canvas.getActiveObject());
33 | canvas.getActiveGroup()&&console.log(canvas.getActiveGroup().getObjects());
34 | });
35 | $('#test').on('click', function () {
36 | canvas.getActiveGroup()&&mdCanvas.toObject(canvas.getActiveGroup(), function (sGroup) {
37 | console.log(sGroup);
38 | });
39 | canvas.getActiveObject()&&mdCanvas.toObject(canvas.getActiveObject(), function (sObj) {
40 | console.log(sObj);
41 | });
42 | mdCanvas.toObject(canvas, function (sCanvas) {
43 | console.log(sCanvas);
44 | });
45 | })
46 | };
--------------------------------------------------------------------------------
/public/css/semantic/components/shape.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Shape
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.shape{position:relative;vertical-align:top;display:inline-block;-webkit-perspective:2000px;perspective:2000px;-webkit-transition:-webkit-transform .6s ease-in-out,left .6s ease-in-out,width .6s ease-in-out,height .6s ease-in-out;transition:transform .6s ease-in-out,left .6s ease-in-out,width .6s ease-in-out,height .6s ease-in-out}.ui.shape .sides{-webkit-transform-style:preserve-3d;transform-style:preserve-3d}.ui.shape .side{opacity:1;width:100%;margin:0!important;-webkit-backface-visibility:hidden;backface-visibility:hidden;display:none}.ui.shape .side *{-webkit-backface-visibility:visible!important;backface-visibility:visible!important}.ui.cube.shape .side{min-width:15em;height:15em;padding:2em;background-color:#e6e6e6;color:rgba(0,0,0,.87);box-shadow:0 0 2px rgba(0,0,0,.3)}.ui.cube.shape .side>.content{width:100%;height:100%;display:table;text-align:center;-webkit-user-select:text;-moz-user-select:text;-ms-user-select:text;user-select:text}.ui.cube.shape .side>.content>div{display:table-cell;vertical-align:middle;font-size:2em}.ui.text.shape.animating .sides{position:static}.ui.text.shape .side{white-space:nowrap}.ui.text.shape .side>*{white-space:normal}.ui.loading.shape{position:absolute;top:-9999px;left:-9999px}.ui.shape .animating.side{position:absolute;top:0;left:0;display:block;z-index:100}.ui.shape .hidden.side{opacity:.6}.ui.shape.animating .sides{position:absolute;-webkit-transition:-webkit-transform .6s ease-in-out,left .6s ease-in-out,width .6s ease-in-out,height .6s ease-in-out;transition:transform .6s ease-in-out,left .6s ease-in-out,width .6s ease-in-out,height .6s ease-in-out}.ui.shape.animating .side{-webkit-transition:opacity .6s ease-in-out;transition:opacity .6s ease-in-out}.ui.shape .active.side{display:block}
--------------------------------------------------------------------------------
/public/css/semantic/components/ad.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Ad
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2013 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.ad{display:block;overflow:hidden;margin:1em 0}.ui.ad:first-child,.ui.ad:last-child{margin:0}.ui.ad iframe{margin:0;padding:0;border:none;overflow:hidden}.ui.leaderboard.ad{width:728px;height:90px}.ui[class*="medium rectangle"].ad{width:300px;height:250px}.ui[class*="large rectangle"].ad{width:336px;height:280px}.ui[class*="half page"].ad{width:300px;height:600px}.ui.square.ad{width:250px;height:250px}.ui[class*="small square"].ad{width:200px;height:200px}.ui[class*="small rectangle"].ad{width:180px;height:150px}.ui[class*="vertical rectangle"].ad{width:240px;height:400px}.ui.button.ad{width:120px;height:90px}.ui[class*="square button"].ad{width:125px;height:125px}.ui[class*="small button"].ad{width:120px;height:60px}.ui.skyscraper.ad{width:120px;height:600px}.ui[class*="wide skyscraper"].ad{width:160px}.ui.banner.ad{width:468px;height:60px}.ui[class*="vertical banner"].ad{width:120px;height:240px}.ui[class*="top banner"].ad{width:930px;height:180px}.ui[class*="half banner"].ad{width:234px;height:60px}.ui[class*="large leaderboard"].ad{width:970px;height:90px}.ui.billboard.ad{width:970px;height:250px}.ui.panorama.ad{width:980px;height:120px}.ui.netboard.ad{width:580px;height:400px}.ui[class*="large mobile banner"].ad{width:320px;height:100px}.ui[class*="mobile leaderboard"].ad{width:320px;height:50px}.ui.mobile.ad{display:none}@media only screen and (max-width:767px){.ui.mobile.ad{display:block}}.ui.centered.ad{margin-left:auto;margin-right:auto}.ui.test.ad{position:relative;background:#545454}.ui.test.ad:after{position:absolute;top:50%;left:50%;width:100%;text-align:center;-webkit-transform:translateX(-50%) translateY(-50%);-ms-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%);content:'Ad';color:#fff;font-size:1em;font-weight:700}.ui.mobile.test.ad:after{font-size:.85714286em}.ui.test.ad[data-text]:after{content:attr(data-text)}
--------------------------------------------------------------------------------
/public/css/semantic/components/tab.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Tab
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | UI Tabs
15 | *******************************/
16 |
17 | .ui.tab {
18 | display: none;
19 | }
20 |
21 |
22 | /*******************************
23 | States
24 | *******************************/
25 |
26 |
27 | /*--------------------
28 | Active
29 | ---------------------*/
30 |
31 | .ui.tab.active,
32 | .ui.tab.open {
33 | display: block;
34 | }
35 |
36 | /*--------------------
37 | Loading
38 | ---------------------*/
39 |
40 | .ui.tab.loading {
41 | position: relative;
42 | overflow: hidden;
43 | display: block;
44 | min-height: 250px;
45 | }
46 | .ui.tab.loading * {
47 | position: relative !important;
48 | left: -10000px !important;
49 | }
50 | .ui.tab.loading:before,
51 | .ui.tab.loading.segment:before {
52 | position: absolute;
53 | content: '';
54 | top: 100px;
55 | left: 50%;
56 | margin: -1.25em 0em 0em -1.25em;
57 | width: 2.5em;
58 | height: 2.5em;
59 | border-radius: 500rem;
60 | border: 0.2em solid rgba(0, 0, 0, 0.1);
61 | }
62 | .ui.tab.loading:after,
63 | .ui.tab.loading.segment:after {
64 | position: absolute;
65 | content: '';
66 | top: 100px;
67 | left: 50%;
68 | margin: -1.25em 0em 0em -1.25em;
69 | width: 2.5em;
70 | height: 2.5em;
71 | -webkit-animation: button-spin 0.6s linear;
72 | animation: button-spin 0.6s linear;
73 | -webkit-animation-iteration-count: infinite;
74 | animation-iteration-count: infinite;
75 | border-radius: 500rem;
76 | border-color: #767676 transparent transparent;
77 | border-style: solid;
78 | border-width: 0.2em;
79 | box-shadow: 0px 0px 0px 1px transparent;
80 | }
81 |
82 |
83 | /*******************************
84 | Tab Overrides
85 | *******************************/
86 |
87 |
88 |
89 | /*******************************
90 | User Overrides
91 | *******************************/
92 |
93 |
--------------------------------------------------------------------------------
/public/css/semantic/components/reset.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Reset
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */*,:after,:before{box-sizing:inherit}html{box-sizing:border-box;font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}input[type=text],input[type=email],input[type=search],input[type=password]{-webkit-appearance:none;-moz-appearance:none}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background:0 0}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,optgroup,strong{font-weight:700}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{box-sizing:content-box;height:0}pre,textarea{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}input{line-height:normal}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}table{border-collapse:collapse;border-spacing:0}td,th{padding:0}
--------------------------------------------------------------------------------
/views/index.ejs:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | <%= title %>
6 |
7 |
8 |
9 |
10 |
11 |
15 |
28 |
29 |
30 |
31 |
MultiDraw
32 |
33 |
43 |
44 |
45 |
63 |
--------------------------------------------------------------------------------
/app_modules/files_mgmt/fileController.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/16.
3 | */
4 | var fileService = require('./fileService.js');
5 | var moment = require('moment');
6 |
7 | exports.saveFile = function(req,res){
8 | //data.lastModify = moment().format('YYYY-MM-DD HH:mm:ss');
9 | var user = req.session.userData;
10 | var data = req.body; //这里拿到的就是前台传过来的对象,无需转换
11 |
12 | if(!data.id){ //1:新建canvas(save)
13 | fileService.saveFile(data,user,function (data) {
14 | res.send(data);
15 | });
16 | } else { //2: 更新canvas非objs的属性 ({id,value})
17 | var id = data.id;
18 | delete data.id;
19 | fileService.updateFile(id,data,function (data) {
20 | res.send(data);
21 | });
22 | }
23 | };
24 |
25 | exports.renameFile = function(req,res){
26 | fileService.updateFile(req.query.id,{fileName : req.query.fileName},function (data) {
27 | res.send(data);
28 | });
29 | };
30 |
31 | exports.loadAllFiles = function (req,res) {
32 | var user = req.session.userData;
33 | var isRecycled = req.query.isRecycled;
34 | var query = {};
35 | if(isRecycled === 'true')
36 | query.isRecycled = true;
37 | else
38 | query.isRecycled = false;
39 | if(user){
40 | fileService.loadAllFiles(query, user, function (data) {
41 | res.send(data);
42 | })
43 | }
44 | };
45 |
46 | exports.recycleFiles = function (req,res) {
47 | var user = req.session.userData;
48 | var idArray = req.query.id;
49 | if(user){
50 | fileService.recycleOrRestoreFiles(idArray,true,function (data) {
51 | res.send(data);
52 | })
53 | }
54 |
55 | };
56 |
57 | exports.restoreFiles = function (req,res) {
58 | var user = req.session.userData;
59 | var idArray = req.query.id;
60 | if(user){
61 | fileService.recycleOrRestoreFiles(idArray,false, function (data) {
62 | res.send(data);
63 | })
64 | }
65 | };
66 |
67 | exports.deleteFiles = function (req,res) {
68 | var user = req.session.userData;
69 | var idArray = req.query.id;
70 | if(user){
71 | fileService.deleteFiles(idArray,function (data) {
72 | res.send(data);
73 | })
74 | }
75 | };
76 |
77 | exports.loadFile = function (req,res) {
78 | var id = req.query.id;
79 | var userInfo = req.session.userData;
80 | fileService.loadFile(id, userInfo, function (data) {
81 | res.send(data);
82 | });
83 | };
--------------------------------------------------------------------------------
/public/app_3th_js/forIE/html5shiv.min.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @preserve HTML5 Shiv 3.7.2 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed
3 | */
4 | !function(a,b){function c(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x",d.insertBefore(c.lastChild,d.firstChild)}function d(){var a=t.elements;return"string"==typeof a?a.split(" "):a}function e(a,b){var c=t.elements;"string"!=typeof c&&(c=c.join(" ")),"string"!=typeof a&&(a=a.join(" ")),t.elements=c+" "+a,j(b)}function f(a){var b=s[a[q]];return b||(b={},r++,a[q]=r,s[r]=b),b}function g(a,c,d){if(c||(c=b),l)return c.createElement(a);d||(d=f(c));var e;return e=d.cache[a]?d.cache[a].cloneNode():p.test(a)?(d.cache[a]=d.createElem(a)).cloneNode():d.createElem(a),!e.canHaveChildren||o.test(a)||e.tagUrn?e:d.frag.appendChild(e)}function h(a,c){if(a||(a=b),l)return a.createDocumentFragment();c=c||f(a);for(var e=c.frag.cloneNode(),g=0,h=d(),i=h.length;i>g;g++)e.createElement(h[g]);return e}function i(a,b){b.cache||(b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag()),a.createElement=function(c){return t.shivMethods?g(c,a,b):b.createElem(c)},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+d().join().replace(/[\w\-:]+/g,function(a){return b.createElem(a),b.frag.createElement(a),'c("'+a+'")'})+");return n}")(t,b.frag)}function j(a){a||(a=b);var d=f(a);return!t.shivCSS||k||d.hasCSS||(d.hasCSS=!!c(a,"article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")),l||i(a,d),a}var k,l,m="3.7.2",n=a.html5||{},o=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,p=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,q="_html5shiv",r=0,s={};!function(){try{var a=b.createElement("a");a.innerHTML="",k="hidden"in a,l=1==a.childNodes.length||function(){b.createElement("a");var a=b.createDocumentFragment();return"undefined"==typeof a.cloneNode||"undefined"==typeof a.createDocumentFragment||"undefined"==typeof a.createElement}()}catch(c){k=!0,l=!0}}();var t={elements:n.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output picture progress section summary template time video",version:m,shivCSS:n.shivCSS!==!1,supportsUnknownElements:l,shivMethods:n.shivMethods!==!1,type:"default",shivDocument:j,createElement:g,createDocumentFragment:h,addElements:e};a.html5=t,j(b)}(this,document);
--------------------------------------------------------------------------------
/public/css/semantic/components/dimmer.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Dimmer
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.dimmable{position:relative}.ui.dimmer{display:none;position:absolute;top:0!important;left:0!important;width:100%;height:100%;text-align:center;vertical-align:middle;background-color:rgba(0,0,0,.85);opacity:0;line-height:1;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:.5s;animation-duration:.5s;-webkit-transition:background-color .5s linear;transition:background-color .5s linear;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;will-change:opacity;z-index:1000}.ui.dimmer>.content{width:100%;height:100%;display:table;-webkit-user-select:text;-moz-user-select:text;-ms-user-select:text;user-select:text}.ui.dimmer>.content>*{display:table-cell;vertical-align:middle;color:#fff}.ui.segment>.ui.dimmer{border-radius:inherit!important}.animating.dimmable:not(body),.dimmed.dimmable:not(body){overflow:hidden}.dimmed.dimmable>.ui.animating.dimmer,.dimmed.dimmable>.ui.visible.dimmer,.ui.active.dimmer{display:block;opacity:1}.ui.disabled.dimmer{width:0!important;height:0!important}.ui.page.dimmer{position:fixed;-webkit-transform-style:'';transform-style:'';-webkit-perspective:2000px;perspective:2000px;-webkit-transform-origin:center center;-ms-transform-origin:center center;transform-origin:center center}body.animating.in.dimmable,body.dimmed.dimmable{overflow:hidden}body.dimmable>.dimmer{position:fixed}.blurring.dimmable>:not(.dimmer){-webkit-filter:blur(0) grayscale(0);filter:blur(0) grayscale(0);-webkit-transition:800ms -webkit-filter ease,800ms filter ease;transition:800ms filter ease}.blurring.dimmed.dimmable>:not(.dimmer){-webkit-filter:blur(5px) grayscale(.7);filter:blur(5px) grayscale(.7)}.blurring.dimmable>.dimmer{background-color:rgba(0,0,0,.6)}.blurring.dimmable>.inverted.dimmer{background-color:rgba(255,255,255,.6)}.ui.dimmer>.top.aligned.content>*{vertical-align:top}.ui.dimmer>.bottom.aligned.content>*{vertical-align:bottom}.ui.inverted.dimmer{background-color:rgba(255,255,255,.85)}.ui.inverted.dimmer>.content>*{color:#fff}.ui.simple.dimmer{display:block;overflow:hidden;opacity:1;width:0;height:0;z-index:-100;background-color:transparent}.dimmed.dimmable>.ui.simple.dimmer{overflow:visible;opacity:1;width:100%;height:100%;background-color:rgba(0,0,0,.85);z-index:1}.ui.simple.inverted.dimmer{background-color:rgba(255,255,255,0)}.dimmed.dimmable>.ui.simple.inverted.dimmer{background-color:rgba(255,255,255,.85)}
--------------------------------------------------------------------------------
/public/app_ui_js/ConfigBoard.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/22.
3 | * some options for how to show canvas
4 | */
5 | var ConfigBoard = function (editBoard) {
6 | this.editBoard = editBoard;
7 | this.canvasCtner = _('canvasCtn');
8 | this.canvasCtnEl = document.getElementsByClassName('canvas-container')[0];
9 | };
10 |
11 | ConfigBoard.prototype.initCanvasPos = function () {
12 | var o_style = this.canvasCtnEl.getAttribute('style');
13 | var left = (1700-this.editBoard.canvas.width)/2;
14 | var top = (1500-this.editBoard.canvas.height)/2;
15 | this.canvasCtnEl.setAttribute('style',o_style+' position:absolute;left: '+left+'px;top:'+top+'px');
16 | this.resetScroll();
17 | };
18 |
19 | ConfigBoard.prototype.resetCanvas = function () {
20 | var left = (this.canvasCtner.offsetWidth-this.editBoard.canvas.width)/2;
21 | var top = (this.canvasCtner.offsetHeight-this.editBoard.canvas.height)/2;
22 | this.canvasCtnEl.style.top=top+'px';
23 | this.canvasCtnEl.style.left=left+'px';
24 | this.resetScroll();
25 | };
26 |
27 | ConfigBoard.prototype.resetScroll = function () {
28 | var canvasCol = document.getElementById('canvas-col');
29 | var sh= canvasCol.scrollHeight;
30 | var sfh = canvasCol.offsetHeight;
31 | var sTop = (sh-sfh)/2;
32 |
33 | var sw= canvasCol.scrollWidth;
34 | var sfw = canvasCol.offsetWidth;
35 | var sLeft = (sw-sfw)/2;
36 | $('#canvas-col').scrollTop(sTop);
37 | $('#canvas-col').scrollLeft(sLeft);
38 | };
39 |
40 | ConfigBoard.prototype.zoomOutCanvas = function () {
41 | this.editBoard.canvas.setZoom(this.editBoard.canvas.getZoom()/1.2);
42 | this.editBoard.canvas.setWidth(this.editBoard.canvas.getWidth()/1.2);
43 | this.editBoard.canvas.setHeight(this.editBoard.canvas.getHeight()/1.2);
44 | this.canvasCtner.style.width = (this.canvasCtner.offsetWidth)/1.2+'px';
45 | this.canvasCtner.style.height = (this.canvasCtner.offsetHeight)/1.2+'px';
46 | this.resetCanvas();
47 | };
48 |
49 | ConfigBoard.prototype.zoomInCanvas = function () {
50 | this.editBoard.canvas.setZoom(this.editBoard.canvas.getZoom()*1.2);
51 | this.editBoard.canvas.setWidth(this.editBoard.canvas.getWidth()*1.2);
52 | this.editBoard.canvas.setHeight(this.editBoard.canvas.getHeight()*1.2);
53 | this.canvasCtner.style.width = (this.canvasCtner.offsetWidth)*1.2+'px';
54 | this.canvasCtner.style.height = (this.canvasCtner.offsetHeight)*1.2+'px';
55 | this.resetCanvas();
56 | };
57 |
58 | ConfigBoard.prototype.customizedCanvas = function () {
59 | this.editBoard.canvas.setWidth(_('canvas-width').value);
60 | this.editBoard.canvas.setHeight(_('canvas-height').value);
61 | this.resetCanvas();
62 | };
--------------------------------------------------------------------------------
/public/css/semantic/components/comment.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Comment
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.comments{margin:1.5em 0;max-width:650px}.ui.comments:first-child{margin-top:0}.ui.comments:last-child{margin-bottom:0}.ui.comments .comment{position:relative;background:0 0;margin:.5em 0 0;padding:.5em 0 0;border:none;border-top:none;line-height:1.2}.ui.comments .comment:first-child{margin-top:0;padding-top:0}.ui.comments .comment .comments{margin:0 0 .5em .5em;padding:1em 0 1em 1em}.ui.comments .comment .comments:before{position:absolute;top:0;left:0}.ui.comments .comment .comments .comment{border:none;border-top:none;background:0 0}.ui.comments .comment .avatar{display:block;width:2.5em;height:auto;float:left;margin:.2em 0 0}.ui.comments .comment .avatar img,.ui.comments .comment img.avatar{display:block;margin:0 auto;width:100%;height:100%;border-radius:.25rem}.ui.comments .comment>.content{display:block}.ui.comments .comment>.avatar~.content{margin-left:3.5em}.ui.comments .comment .author{font-size:1em;color:rgba(0,0,0,.87);font-weight:700}.ui.comments .comment a.author{cursor:pointer}.ui.comments .comment a.author:hover{color:#1e70bf}.ui.comments .comment .metadata{display:inline-block;margin-left:.5em;color:rgba(0,0,0,.4);font-size:.875em}.ui.comments .comment .metadata>*{display:inline-block;margin:0 .5em 0 0}.ui.comments .comment .metadata>:last-child{margin-right:0}.ui.comments .comment .text{margin:.25em 0 .5em;font-size:1em;word-wrap:break-word;color:rgba(0,0,0,.87);line-height:1.3}.ui.comments .comment .actions{font-size:.875em}.ui.comments .comment .actions a{cursor:pointer;display:inline-block;margin:0 .75em 0 0;color:rgba(0,0,0,.4)}.ui.comments .comment .actions a:last-child{margin-right:0}.ui.comments .comment .actions a.active,.ui.comments .comment .actions a:hover{color:rgba(0,0,0,.8)}.ui.comments>.reply.form{margin-top:1em}.ui.comments .comment .reply.form{width:100%;margin-top:1em}.ui.comments .reply.form textarea{font-size:1em;height:12em}.ui.collapsed.comments,.ui.comments .collapsed.comment,.ui.comments .collapsed.comments{display:none}.ui.threaded.comments .comment .comments{margin:-1.5em 0 -1em 1.25em;padding:3em 0 2em 2.25em;box-shadow:-1px 0 0 rgba(34,36,38,.15)}.ui.minimal.comments .comment .actions{opacity:0;position:absolute;top:0;right:0;left:auto;-webkit-transition:opacity .2s ease;transition:opacity .2s ease;-webkit-transition-delay:.1s;transition-delay:.1s}.ui.minimal.comments .comment>.content:hover>.actions{opacity:1}.ui.small.comments{font-size:.9em}.ui.comments{font-size:1em}.ui.large.comments{font-size:1.1em}.ui.huge.comments{font-size:1.2em}
--------------------------------------------------------------------------------
/public/css/semantic/components/breadcrumb.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Breadcrumb
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Breadcrumb
15 | *******************************/
16 |
17 | .ui.breadcrumb {
18 | line-height: 1;
19 | display: inline-block;
20 | margin: 0em 0em;
21 | vertical-align: middle;
22 | }
23 | .ui.breadcrumb:first-child {
24 | margin-top: 0em;
25 | }
26 | .ui.breadcrumb:last-child {
27 | margin-bottom: 0em;
28 | }
29 |
30 |
31 | /*******************************
32 | Content
33 | *******************************/
34 |
35 |
36 | /* Divider */
37 | .ui.breadcrumb .divider {
38 | display: inline-block;
39 | opacity: 0.7;
40 | margin: 0em 0.21428571rem 0em;
41 | font-size: 0.92857143em;
42 | color: rgba(0, 0, 0, 0.4);
43 | vertical-align: baseline;
44 | }
45 |
46 | /* Link */
47 | .ui.breadcrumb a {
48 | color: #4183c4;
49 | }
50 | .ui.breadcrumb a:hover {
51 | color: #1e70bf;
52 | }
53 |
54 | /* Icon Divider */
55 | .ui.breadcrumb .icon.divider {
56 | font-size: 0.85714286em;
57 | vertical-align: baseline;
58 | }
59 |
60 | /* Section */
61 | .ui.breadcrumb a.section {
62 | cursor: pointer;
63 | }
64 | .ui.breadcrumb .section {
65 | display: inline-block;
66 | margin: 0em;
67 | padding: 0em;
68 | }
69 |
70 | /* Loose Coupling */
71 | .ui.breadcrumb.segment {
72 | display: inline-block;
73 | padding: 0.71428571em 1em;
74 | }
75 |
76 |
77 | /*******************************
78 | States
79 | *******************************/
80 |
81 | .ui.breadcrumb .active.section {
82 | font-weight: bold;
83 | }
84 |
85 |
86 | /*******************************
87 | Variations
88 | *******************************/
89 |
90 | .ui.mini.breadcrumb {
91 | font-size: 0.71428571rem;
92 | }
93 | .ui.tiny.breadcrumb {
94 | font-size: 0.85714286rem;
95 | }
96 | .ui.small.breadcrumb {
97 | font-size: 0.92857143rem;
98 | }
99 | .ui.breadcrumb {
100 | font-size: 1rem;
101 | }
102 | .ui.large.breadcrumb {
103 | font-size: 1.14285714rem;
104 | }
105 | .ui.big.breadcrumb {
106 | font-size: 1.28571429rem;
107 | }
108 | .ui.huge.breadcrumb {
109 | font-size: 1.42857143rem;
110 | }
111 | .ui.massive.breadcrumb {
112 | font-size: 1.71428571rem;
113 | }
114 |
115 |
116 | /*******************************
117 | Theme Overrides
118 | *******************************/
119 |
120 |
121 |
122 | /*******************************
123 | Site Overrides
124 | *******************************/
125 |
126 |
--------------------------------------------------------------------------------
/public/app_3th_js/jQuery/jquery.mousewheel.min.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/29.
3 | */
4 | /*! Copyright (c) 2013 Brandon Aaron (http://brandon.aaron.sh)
5 | * Licensed under the MIT License (LICENSE.txt).
6 | *
7 | * Version: 3.1.12
8 | *
9 | * Requires: jQuery 1.2.2+
10 | */
11 | !function(a){"function"==typeof define&&define.amd?define(["jquery.mousewheel.min"],a):"object"==typeof exports?module.exports=a:a(jQuery)}(function(a){function b(b){var g=b||window.event,h=i.call(arguments,1),j=0,l=0,m=0,n=0,o=0,p=0;if(b=a.event.fix(g),b.type="mousewheel","detail"in g&&(m=-1*g.detail),"wheelDelta"in g&&(m=g.wheelDelta),"wheelDeltaY"in g&&(m=g.wheelDeltaY),"wheelDeltaX"in g&&(l=-1*g.wheelDeltaX),"axis"in g&&g.axis===g.HORIZONTAL_AXIS&&(l=-1*m,m=0),j=0===m?l:m,"deltaY"in g&&(m=-1*g.deltaY,j=m),"deltaX"in g&&(l=g.deltaX,0===m&&(j=-1*l)),0!==m||0!==l){if(1===g.deltaMode){var q=a.data(this,"mousewheel-line-height");j*=q,m*=q,l*=q}else if(2===g.deltaMode){var r=a.data(this,"mousewheel-page-height");j*=r,m*=r,l*=r}if(n=Math.max(Math.abs(m),Math.abs(l)),(!f||f>n)&&(f=n,d(g,n)&&(f/=40)),d(g,n)&&(j/=40,l/=40,m/=40),j=Math[j>=1?"floor":"ceil"](j/f),l=Math[l>=1?"floor":"ceil"](l/f),m=Math[m>=1?"floor":"ceil"](m/f),k.settings.normalizeOffset&&this.getBoundingClientRect){var s=this.getBoundingClientRect();o=b.clientX-s.left,p=b.clientY-s.top}return b.deltaX=l,b.deltaY=m,b.deltaFactor=f,b.offsetX=o,b.offsetY=p,b.deltaMode=0,h.unshift(b,j,l,m),e&&clearTimeout(e),e=setTimeout(c,200),(a.event.dispatch||a.event.handle).apply(this,h)}}function c(){f=null}function d(a,b){return k.settings.adjustOldDeltas&&"mousewheel"===a.type&&b%120===0}var e,f,g=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],h="onwheel"in document||document.documentMode>=9?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"],i=Array.prototype.slice;if(a.event.fixHooks)for(var j=g.length;j;)a.event.fixHooks[g[--j]]=a.event.mouseHooks;var k=a.event.special.mousewheel={version:"3.1.12",setup:function(){if(this.addEventListener)for(var c=h.length;c;)this.addEventListener(h[--c],b,!1);else this.onmousewheel=b;a.data(this,"mousewheel-line-height",k.getLineHeight(this)),a.data(this,"mousewheel-page-height",k.getPageHeight(this))},teardown:function(){if(this.removeEventListener)for(var c=h.length;c;)this.removeEventListener(h[--c],b,!1);else this.onmousewheel=null;a.removeData(this,"mousewheel-line-height"),a.removeData(this,"mousewheel-page-height")},getLineHeight:function(b){var c=a(b),d=c["offsetParent"in a.fn?"offsetParent":"parent"]();return d.length||(d=a("body")),parseInt(d.css("fontSize"),10)||parseInt(c.css("fontSize"),10)||16},getPageHeight:function(b){return a(b).height()},settings:{adjustOldDeltas:!0,normalizeOffset:!0}};a.fn.extend({mousewheel:function(a){return a?this.bind("mousewheel",a):this.trigger("mousewheel")},unmousewheel:function(a){return this.unbind("mousewheel",a)}})});
--------------------------------------------------------------------------------
/public/css/semantic/components/rail.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Rail
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Rails
15 | *******************************/
16 |
17 | .ui.rail {
18 | position: absolute;
19 | top: 0%;
20 | width: 300px;
21 | height: 100%;
22 | }
23 | .ui.left.rail {
24 | left: auto;
25 | right: 100%;
26 | padding: 0em 2rem 0em 0em;
27 | margin: 0em 2rem 0em 0em;
28 | }
29 | .ui.right.rail {
30 | left: 100%;
31 | right: auto;
32 | padding: 0em 0em 0em 2rem;
33 | margin: 0em 0em 0em 2rem;
34 | }
35 |
36 |
37 | /*******************************
38 | Variations
39 | *******************************/
40 |
41 |
42 | /*--------------
43 | Internal
44 | ---------------*/
45 |
46 | .ui.left.internal.rail {
47 | left: 0%;
48 | right: auto;
49 | padding: 0em 0em 0em 2rem;
50 | margin: 0em 0em 0em 2rem;
51 | }
52 | .ui.right.internal.rail {
53 | left: auto;
54 | right: 0%;
55 | padding: 0em 2rem 0em 0em;
56 | margin: 0em 2rem 0em 0em;
57 | }
58 |
59 | /*--------------
60 | Dividing
61 | ---------------*/
62 |
63 | .ui.dividing.rail {
64 | width: 302.5px;
65 | }
66 | .ui.left.dividing.rail {
67 | padding: 0em 2.5rem 0em 0em;
68 | margin: 0em 2.5rem 0em 0em;
69 | border-right: 1px solid rgba(34, 36, 38, 0.15);
70 | }
71 | .ui.right.dividing.rail {
72 | border-left: 1px solid rgba(34, 36, 38, 0.15);
73 | padding: 0em 0em 0em 2.5rem;
74 | margin: 0em 0em 0em 2.5rem;
75 | }
76 |
77 | /*--------------
78 | Distance
79 | ---------------*/
80 |
81 | .ui.close.rail {
82 | width: 301px;
83 | }
84 | .ui.close.left.rail {
85 | padding: 0em 1em 0em 0em;
86 | margin: 0em 1em 0em 0em;
87 | }
88 | .ui.close.right.rail {
89 | padding: 0em 0em 0em 1em;
90 | margin: 0em 0em 0em 1em;
91 | }
92 | .ui.very.close.rail {
93 | width: 300.5px;
94 | }
95 | .ui.very.close.left.rail {
96 | padding: 0em 0.5em 0em 0em;
97 | margin: 0em 0.5em 0em 0em;
98 | }
99 | .ui.very.close.right.rail {
100 | padding: 0em 0em 0em 0.5em;
101 | margin: 0em 0em 0em 0.5em;
102 | }
103 |
104 | /*--------------
105 | Attached
106 | ---------------*/
107 |
108 | .ui.attached.left.rail,
109 | .ui.attached.right.rail {
110 | padding: 0em;
111 | margin: 0em;
112 | }
113 |
114 | /*--------------
115 | Sizing
116 | ---------------*/
117 |
118 | .ui.rail {
119 | font-size: 1rem;
120 | }
121 |
122 |
123 | /*******************************
124 | Theme Overrides
125 | *******************************/
126 |
127 |
128 |
129 | /*******************************
130 | Site Overrides
131 | *******************************/
132 |
133 |
--------------------------------------------------------------------------------
/public/css/semantic/components/video.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.0.0 - Video
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2014 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Video
15 | *******************************/
16 |
17 | .ui.video {
18 | background-color: #dddddd;
19 | position: relative;
20 | max-width: 100%;
21 | padding-bottom: 56.25%;
22 | height: 0px;
23 | overflow: hidden;
24 | }
25 |
26 | /*--------------
27 | Content
28 | ---------------*/
29 |
30 |
31 | /* Placeholder Image */
32 | .ui.video .placeholder {
33 | background-color: #333333;
34 | }
35 |
36 | /* Play Icon Overlay */
37 | .ui.video .play {
38 | cursor: pointer;
39 | position: absolute;
40 | top: 0px;
41 | left: 0px;
42 | z-index: 10;
43 | width: 100%;
44 | height: 100%;
45 | background: transparent;
46 | -webkit-transition: background 0.2s ease;
47 | transition: background 0.2s ease;
48 | }
49 | .ui.video .play.icon:before {
50 | position: absolute;
51 | top: 50%;
52 | left: 50%;
53 | z-index: 11;
54 | -webkit-transform: translateX(-50%) translateY(-50%);
55 | -ms-transform: translateX(-50%) translateY(-50%);
56 | transform: translateX(-50%) translateY(-50%);
57 | color: rgba(255, 255, 255, 0.7);
58 | font-size: 7rem;
59 | text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.15);
60 | -webkit-transition: color 0.2s ease;
61 | transition: color 0.2s ease;
62 | }
63 | .ui.video .placeholder {
64 | position: absolute;
65 | top: 0px;
66 | left: 0px;
67 | display: block;
68 | width: 100%;
69 | height: 100%;
70 | }
71 |
72 | /* IFrame Embed */
73 | .ui.video .embed iframe,
74 | .ui.video .embed embed,
75 | .ui.video .embed object {
76 | position: absolute;
77 | border: none;
78 | width: 100%;
79 | height: 100%;
80 | top: 0px;
81 | left: 0px;
82 | margin: 0em;
83 | padding: 0em;
84 | }
85 |
86 |
87 | /*******************************
88 | States
89 | *******************************/
90 |
91 |
92 | /*--------------
93 | Hover
94 | ---------------*/
95 |
96 | .ui.video .play:hover {
97 | background: rgba(0, 0, 0, 0);
98 | }
99 | .ui.video .play:hover:before {
100 | color: #ffffff;
101 | }
102 |
103 | /*--------------
104 | Active
105 | ---------------*/
106 |
107 | .ui.active.video .play,
108 | .ui.active.video .placeholder {
109 | display: none;
110 | }
111 | .ui.active.video .embed {
112 | display: inline;
113 | }
114 |
115 |
116 | /*******************************
117 | Video Overrides
118 | *******************************/
119 |
120 |
121 |
122 | /*******************************
123 | Site Overrides
124 | *******************************/
125 |
126 |
--------------------------------------------------------------------------------
/app_modules/files_mgmt/fileService.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/16.
3 | */
4 | var fileDao = new (require('./fileDao.js'))('canvasMetaData');
5 | var participantsDao = new (require('./../users_mgmt/userDao.js'))('canvasParticipants');
6 | var message = require('./../_utils/messageGenerator.js');
7 |
8 | exports.saveFile = function (data,user,next) {
9 | data.createUserId = user.id;
10 | data.createUserName = user.name;
11 | data.isRecycled = false;
12 | if(!data.fileName) data.fileName = '未命名文件';
13 | fileDao.saveFile(data, function (data) {
14 | if(data){
15 | var participants = {
16 | canvasId : data.data,
17 | userId : user.id,
18 | userName : user.name,
19 | permission : '2'
20 | };
21 | participantsDao.addParticipants([participants], function (result) {
22 | next(data);
23 | });
24 | }
25 | });
26 | };
27 |
28 | exports.deleteFiles = function (idArray,next) {
29 | if(!(idArray instanceof Array)){
30 | idArray = idArray.split(',');
31 | }
32 | var cbNum = 0;
33 | var result = [];
34 | for (var i = 0; i < idArray.length; i++) {
35 | fileDao.deleteFileById(idArray[i],function (data) {
36 | cbNum ++ ;
37 | if (data) {
38 | result.push(data);
39 | if(cbNum === idArray.length) {
40 | next(message.genSimpSuccessMsg(null, result))
41 | }
42 | }
43 | })
44 | }
45 | };
46 |
47 | exports.updateFile = function (id,update, next) {
48 | fileDao.updateFileById(id,update,function (data) {
49 | if(data)
50 | next(message.genSimpSuccessMsg(null, data));
51 | })
52 | };
53 |
54 |
55 | exports.recycleOrRestoreFiles = function (idArray,isRecycled,next) {
56 | if(!(idArray instanceof Array)){
57 | idArray = idArray.split(',');
58 | }
59 | var cbNum = 0;
60 | var result = [];
61 | for (var i = 0; i < idArray.length; i++) {
62 | fileDao.updateFileById(idArray[i], {isRecycled : isRecycled}, function (data) {
63 | cbNum ++ ;
64 | if (data) {
65 | result.push(data);
66 | if(cbNum === idArray.length) {
67 | next(message.genSimpSuccessMsg(null, result))
68 | }
69 | }
70 | })
71 | }
72 | };
73 |
74 | exports.loadFile= function(id,user,next){
75 | fileDao.findFileByIdUnderAccount(id, user, function (data) {
76 | if(data){
77 | next(data);
78 | }else{
79 | next(message.genSimpFailedMsg('当前文件不存在!', data))
80 | }
81 | });
82 | };
83 |
84 | exports.loadAllFiles= function(query,user,next){
85 | fileDao.findManyFilesUnderAccount(query, user, function (data) {
86 | if(data){
87 | next(data);
88 | }
89 | });
90 | };
91 |
92 |
--------------------------------------------------------------------------------
/app_modules/users_mgmt/userController.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/20.
3 | */
4 | var userService = require('./userService.js');
5 | var message = require('../_utils/messageGenerator.js');
6 |
7 | exports.addUser = function (req, res) {
8 | var user = {
9 | name : req.body.name,
10 | password : req.body.password,
11 | email: req.body.email
12 | };
13 | userService.addUser(user, function (data) {
14 | res.send(data);
15 | });
16 | };
17 |
18 | exports.loadUnParticipantUsers = function (req,res) {
19 | var keyWords = req.query.keyWords;
20 | var canvasId = req.query.canvasId;
21 | if(!keyWords){
22 | res.send({success:false})
23 | } else {
24 | var reg = new RegExp(keyWords);
25 | console.log('reg',reg);
26 | userService.loadUnParticipantUsers(reg,canvasId,function (result) {
27 | res.send(result);
28 | })
29 | }
30 | };
31 |
32 | exports.addParticipants = function (req,res) {
33 | var participants = req.body;
34 | console.log('participants= ',participants);
35 | userService.addParticipants(participants, function (result) {
36 | res.send(result);
37 | })
38 | };
39 | exports.getParticipants = function (req,res) {
40 | var canvasId = req.query.canvasId;
41 | userService.getParticipants(canvasId, function (result) {
42 | if(result.success){
43 | res.send(result);
44 | }
45 | })
46 | };
47 |
48 | exports.removeParticipants = function (req,res) {
49 | var query = {
50 | canvasId : req.query.canvasId,
51 | userId : req.query.userId
52 | };
53 | console.log('remove',query);
54 | userService.removeParticipants(query, function (result) {
55 | res.send(result);
56 | })
57 | };
58 |
59 | exports.updateParticipants = function (req,res) {
60 | var query = {
61 | canvasId : req.body.canvasId,
62 | userId : req.body.userId
63 | };
64 | console.log('update',query);
65 | var updateData = {
66 | permission : req.body.permission
67 | };
68 | console.log('data',updateData);
69 | userService.updateParticipants(query,updateData, function (result) {
70 | res.send(result);
71 | })
72 | };
73 |
74 | exports.isExist = function(req,res){
75 | var query = {
76 | name : req.body.name,
77 | password : req.body.password
78 | };
79 | userService.isExist(query, function (result) {
80 | if (result.success === true) {
81 | req.session.userData = result.data[0];
82 | delete req.session.userData.password;
83 | }
84 | res.send(result);
85 | });
86 | };
87 |
88 | exports.isUserNameExist = function(req,res){
89 | var query = {
90 | name : req.body.name
91 | };
92 | userService.isExist(query,function (message) {
93 | if (message.success === true) {
94 | res.send({valid:false});
95 | }else{
96 | res.send({valid:true});
97 | }
98 | });
99 | };
100 |
101 |
102 |
103 |
--------------------------------------------------------------------------------
/public/css/semantic/components/colorize.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.0.0 - Colorize
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 | !function(e,n,i,t){"use strict";e.fn.colorize=function(n){var i=e.isPlainObject(n)?e.extend(!0,{},e.fn.colorize.settings,n):e.extend({},e.fn.colorize.settings),o=arguments||!1;return e(this).each(function(n){var a,r,c,s,d,g,u,l,m=e(this),f=e("")[0],h=e("")[0],p=e("")[0],v=new Image,w=i.colors,b=(i.paths,i.namespace),y=i.error,C=m.data("module-"+b);return l={checkPreconditions:function(){return l.debug("Checking pre-conditions"),!e.isPlainObject(w)||e.isEmptyObject(w)?(l.error(y.undefinedColors),!1):!0},async:function(e){i.async?setTimeout(e,0):e()},getMetadata:function(){l.debug("Grabbing metadata"),s=m.data("image")||i.image||t,d=m.data("name")||i.name||n,g=i.width||m.width(),u=i.height||m.height(),(0===g||0===u)&&l.error(y.undefinedSize)},initialize:function(){l.debug("Initializing with colors",w),l.checkPreconditions()&&l.async(function(){l.getMetadata(),l.canvas.create(),l.draw.image(function(){l.draw.colors(),l.canvas.merge()}),m.data("module-"+b,l)})},redraw:function(){l.debug("Redrawing image"),l.async(function(){l.canvas.clear(),l.draw.colors(),l.canvas.merge()})},change:{color:function(e,n){return l.debug("Changing color",e),w[e]===t?(l.error(y.missingColor),!1):(w[e]=n,void l.redraw())}},canvas:{create:function(){l.debug("Creating canvases"),f.width=g,f.height=u,h.width=g,h.height=u,p.width=g,p.height=u,a=f.getContext("2d"),r=h.getContext("2d"),c=p.getContext("2d"),m.append(f),a=m.children("canvas")[0].getContext("2d")},clear:function(e){l.debug("Clearing canvas"),c.fillStyle="#FFFFFF",c.fillRect(0,0,g,u)},merge:function(){return e.isFunction(a.blendOnto)?(a.putImageData(r.getImageData(0,0,g,u),0,0),void c.blendOnto(a,"multiply")):void l.error(y.missingPlugin)}},draw:{image:function(e){l.debug("Drawing image"),e=e||function(){},s?(v.src=s,v.onload=function(){r.drawImage(v,0,0),e()}):(l.error(y.noImage),e())},colors:function(){l.debug("Drawing color overlays",w),e.each(w,function(e,n){i.onDraw(c,d,e,n)})}},debug:function(e,n){i.debug&&(n!==t?console.info(i.name+": "+e,n):console.info(i.name+": "+e))},error:function(e){console.warn(i.name+": "+e)},invoke:function(n,o,a){var r;return a=a||Array.prototype.slice.call(arguments,2),"string"==typeof n&&C!==t&&(n=n.split("."),e.each(n,function(n,t){return e.isPlainObject(C[t])?(C=C[t],!0):e.isFunction(C[t])?(r=C[t],!0):(l.error(i.error.method),!1)})),e.isFunction(r)?r.apply(o,a):!1}},C!==t&&o?("invoke"==o[0]&&(o=Array.prototype.slice.call(o,1)),l.invoke(o[0],this,Array.prototype.slice.call(o,1))):void l.initialize()}),this},e.fn.colorize.settings={name:"Image Colorizer",debug:!0,namespace:"colorize",onDraw:function(e,n,i,t){},async:!0,colors:{},metadata:{image:"image",name:"name"},error:{noImage:"No tracing image specified",undefinedColors:"No default colors specified.",missingColor:"Attempted to change color that does not exist",missingPlugin:"Blend onto plug-in must be included",undefinedHeight:"The width or height of image canvas could not be automatically determined. Please specify a height."}}}(jQuery,window,document);
--------------------------------------------------------------------------------
/app_draw:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env node
2 | var debug = require('debug')('multidraw:server');
3 | var http = require('http');
4 | var socket = require('./socket.js');
5 | var dataSource = require('./app_db/dataSource.js');
6 | var config = require('./config.json');
7 | var Session = require('express-session');
8 | const MongoStore = require('connect-mongo')(Session);
9 | var session = Session({
10 | resave : true,
11 | saveUninitialized : true ,
12 | secret : 'fens.me',
13 | cookie: config.cookieInfo[config.runMode],
14 | store: new MongoStore({ url: "mongodb://localhost:27017/session_store"})
15 | });
16 |
17 | dataSource.connectDb(config.dbUrl,function(multidrawDb){
18 | var app = require('./config'); //获取启动app的基本配置信息,实际上就是express对象
19 | app.use(session);
20 | app = require('./routes/root')(app); //把获取的app传到root的参数里,进行对app进行路由的配置,有点儿面向过程的感觉
21 |
22 | var port = normalizePort(process.env.PORT || '4500');
23 | app.set('port', port);
24 |
25 | /**
26 | * Create HTTP server.
27 | */
28 | var server = http.createServer(app);
29 | var ios = function(session) {
30 | return function(socket, next) {
31 | session(socket.handshake, {}, next);
32 | };
33 | };
34 | var itemDao = new (require('./app_modules/items_mgmt/itemDao.js'))('canvasItems',multidrawDb);
35 | socket.startSocketIo(server,itemDao,ios(session));
36 | /**
37 | * Listen on provided port, on all network interfaces.
38 | */
39 | server.listen(port);
40 | server.on('error', onError);
41 | server.on('listening', onListening);
42 |
43 | /**
44 | * Normalize a port into a number, string, or false.
45 | */
46 |
47 | function normalizePort(val) {
48 | var port = parseInt(val, 10);
49 |
50 | if (isNaN(port)) {
51 | // named pipe
52 | return val;
53 | }
54 |
55 | if (port >= 0) {
56 | // port number
57 | return port;
58 | }
59 |
60 | return false;
61 | }
62 |
63 | /**
64 | * Event listener for HTTP server "error" event.
65 | */
66 |
67 | function onError(error) {
68 | if (error.syscall !== 'listen') {
69 | throw error;
70 | }
71 |
72 | var bind = typeof port === 'string'
73 | ? 'Pipe ' + port
74 | : 'Port ' + port;
75 |
76 | // handle specific listen errors with friendly messages
77 | switch (error.code) {
78 | case 'EACCES':
79 | console.error(bind + ' requires elevated privileges');
80 | process.exit(1);
81 | break;
82 | case 'EADDRINUSE':
83 | console.error(bind + ' is already in use');
84 | process.exit(1);
85 | break;
86 | default:
87 | throw error;
88 | }
89 | }
90 |
91 | /**
92 | * Event listener for HTTP server "listening" event.
93 | */
94 |
95 | function onListening() {
96 | var addr = server.address();
97 | var bind = typeof addr === 'string'
98 | ? 'pipe ' + addr
99 | : 'port ' + addr.port;
100 | debug('Listening on ' + bind);
101 | }
102 |
103 | });
104 |
--------------------------------------------------------------------------------
/app_modules/files_mgmt/fileDao.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/16.
3 | * My own CRUD for file
4 | */
5 | var AbstractDao = require('./../AbstractDao.js');
6 | var itemDao = new (require('./../items_mgmt/itemDao.js'))('canvasItems');
7 | var participantsDao = new (require('./../users_mgmt/userDao.js'))('canvasParticipants');
8 | var utils = require('./../_utils/utils.js');
9 | var message = require('../_utils/messageGenerator.js');
10 | var fileDao = function(collectionName){
11 | AbstractDao.call(this,collectionName);
12 | };
13 | utils.extend(fileDao,AbstractDao);
14 |
15 | fileDao.prototype.saveFile = function (data,next) {
16 | this.insertOne(data,next);
17 | };
18 |
19 | fileDao.prototype.deleteFileById = function (id,next) {
20 | this.deleteOne({'id': id}, function (result) {
21 | itemDao.deleteAllItemsInCanvas(id, function (data) {
22 | next(result);
23 | })
24 | });
25 | };
26 |
27 | fileDao.prototype.updateFileById = function (id,update,next) {
28 | this.updateOne({'id' : id},update,next);
29 | };
30 |
31 | fileDao.prototype.findManyFilesUnderAccount = function (query,user,next) {
32 | query.createUserId = user.id;
33 | this.findMany(query,next);
34 | };
35 |
36 | fileDao.prototype.findFileByIdUnderAccount = function (id,user,next) {
37 | var me = this;
38 | var query = {
39 | id : id
40 | };
41 | var partQuery = {
42 | canvasId : id,
43 | userId : user.id
44 | };
45 | participantsDao.findOne(partQuery, function (result) {
46 | //console.log(result.data);
47 | if(result.data[0]){ //该用户已参与此画板分享
48 | //打开此画板
49 | me.findOne(query, function (result) {
50 | if(result.data[0]){
51 | itemDao.findItemsInCanvas(id, function (itemsData) {
52 | if(itemsData.success){
53 | result.data[0].objects = itemsData.data;
54 | }
55 | next(result);
56 | })
57 | }else{
58 | next(result.data[0]);
59 | }
60 | });
61 | }else{
62 | console.log('无法打开');
63 | next(result.data[0]);
64 | }
65 | });
66 |
67 | };
68 |
69 | fileDao.prototype.findFileById = function (id,user,next) {
70 | var query = {
71 | id : id
72 | };
73 | this.findOne(query, function (result) {
74 | if(result.data[0]){
75 | itemDao.findItemsInCanvas(id, function (itemsData) {
76 | if(itemsData.success){
77 | result.data[0].objects = itemsData.data;
78 | }
79 | next(result);
80 | })
81 | }else{
82 | next(result.data[0]);
83 | }
84 | });
85 | };
86 |
87 | fileDao.prototype.findParticitantsById = function (canvasId,user,next) {
88 | var query = {
89 | canvasId : canvasId,
90 | userId : user.id
91 | };
92 | this.findOne(query, function (result) {
93 | next(result.data[0]);
94 | })
95 | };
96 |
97 | fileDao.prototype.saveParticitants = function (data,next) {
98 | this.insertUnpreOne(data,next);
99 | }
100 |
101 | module.exports = fileDao;
--------------------------------------------------------------------------------
/public/css/semantic/components/nag.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Nag
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Nag
15 | *******************************/
16 |
17 | .ui.nag {
18 | display: none;
19 | opacity: 0.95;
20 | position: relative;
21 | top: 0em;
22 | left: 0px;
23 | z-index: 999;
24 | min-height: 0em;
25 | width: 100%;
26 | margin: 0em;
27 | padding: 0.75em 1em;
28 | background: #555555;
29 | box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.2);
30 | font-size: 1rem;
31 | text-align: center;
32 | color: rgba(0, 0, 0, 0.87);
33 | border-radius: 0em 0em 0.28571429rem 0.28571429rem;
34 | -webkit-transition: 0.2s background ease;
35 | transition: 0.2s background ease;
36 | }
37 | a.ui.nag {
38 | cursor: pointer;
39 | }
40 | .ui.nag > .title {
41 | display: inline-block;
42 | margin: 0em 0.5em;
43 | color: #ffffff;
44 | }
45 | .ui.nag > .close.icon {
46 | cursor: pointer;
47 | opacity: 0.4;
48 | position: absolute;
49 | top: 50%;
50 | right: 1em;
51 | font-size: 1em;
52 | margin: -0.5em 0em 0em;
53 | color: #ffffff;
54 | -webkit-transition: opacity 0.2s ease;
55 | transition: opacity 0.2s ease;
56 | }
57 |
58 |
59 | /*******************************
60 | States
61 | *******************************/
62 |
63 |
64 | /* Hover */
65 | .ui.nag:hover {
66 | background: #555555;
67 | opacity: 1;
68 | }
69 | .ui.nag .close:hover {
70 | opacity: 1;
71 | }
72 |
73 |
74 | /*******************************
75 | Variations
76 | *******************************/
77 |
78 |
79 | /*--------------
80 | Static
81 | ---------------*/
82 |
83 | .ui.overlay.nag {
84 | position: absolute;
85 | display: block;
86 | }
87 |
88 | /*--------------
89 | Fixed
90 | ---------------*/
91 |
92 | .ui.fixed.nag {
93 | position: fixed;
94 | }
95 |
96 | /*--------------
97 | Bottom
98 | ---------------*/
99 |
100 | .ui.bottom.nags,
101 | .ui.bottom.nag {
102 | border-radius: 0.28571429rem 0.28571429rem 0em 0em;
103 | top: auto;
104 | bottom: 0em;
105 | }
106 |
107 | /*--------------
108 | White
109 | ---------------*/
110 |
111 | .ui.inverted.nags .nag,
112 | .ui.inverted.nag {
113 | background-color: #f3f4f5;
114 | color: rgba(0, 0, 0, 0.85);
115 | }
116 | .ui.inverted.nags .nag .close,
117 | .ui.inverted.nags .nag .title,
118 | .ui.inverted.nag .close,
119 | .ui.inverted.nag .title {
120 | color: rgba(0, 0, 0, 0.4);
121 | }
122 |
123 |
124 | /*******************************
125 | Groups
126 | *******************************/
127 |
128 | .ui.nags .nag {
129 | border-radius: 0em !important;
130 | }
131 | .ui.nags .nag:last-child {
132 | border-radius: 0em 0em 0.28571429rem 0.28571429rem;
133 | }
134 | .ui.bottom.nags .nag:last-child {
135 | border-radius: 0.28571429rem 0.28571429rem 0em 0em;
136 | }
137 |
138 |
139 | /*******************************
140 | Theme Overrides
141 | *******************************/
142 |
143 |
144 |
145 | /*******************************
146 | User Overrides
147 | *******************************/
148 |
149 |
--------------------------------------------------------------------------------
/public/css/semantic/components/loader.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Loader
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.loader{display:none;position:absolute;top:50%;left:50%;margin:0;text-align:center;z-index:1000;-webkit-transform:translateX(-50%) translateY(-50%);-ms-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%)}.ui.loader:before{position:absolute;content:'';top:0;left:50%;border-radius:500rem;border:.2em solid rgba(0,0,0,.1)}.ui.loader:after{position:absolute;content:'';top:0;left:50%;-webkit-animation:loader .6s linear;animation:loader .6s linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;border-radius:500rem;border-color:#767676 transparent transparent;border-style:solid;border-width:.2em;box-shadow:0 0 0 1px transparent}@-webkit-keyframes loader{from{-webkit-transform:rotate(0);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes loader{from{-webkit-transform:rotate(0);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.ui.loader:after,.ui.loader:before{width:2.2585em;height:2.2585em;margin:0 0 0 -1.12925em}.ui.mini.loader:after,.ui.mini.loader:before{width:1.2857em;height:1.2857em;margin:0 0 0 -.64285em}.ui.small.loader:after,.ui.small.loader:before{width:1.7142em;height:1.7142em;margin:0 0 0 -.8571em}.ui.large.loader:after,.ui.large.loader:before{width:4.5714em;height:4.5714em;margin:0 0 0 -2.2857em}.ui.dimmer .loader{display:block}.ui.dimmer .ui.loader{color:rgba(255,255,255,.9)}.ui.dimmer .ui.loader:before{border-color:rgba(255,255,255,.15)}.ui.dimmer .ui.loader:after{border-color:#fff transparent transparent}.ui.inverted.dimmer .ui.loader{color:rgba(0,0,0,.87)}.ui.inverted.dimmer .ui.loader:before{border-color:rgba(0,0,0,.1)}.ui.inverted.dimmer .ui.loader:after{border-color:#767676 transparent transparent}.ui.text.loader{width:auto!important;height:auto!important;text-align:center;font-style:normal}.ui.indeterminate.loader:after{-webkit-animation-direction:reverse;animation-direction:reverse;-webkit-animation-duration:1.2s;animation-duration:1.2s}.ui.loader.active,.ui.loader.visible{display:block}.ui.loader.disabled,.ui.loader.hidden{display:none}.ui.inverted.dimmer .ui.mini.loader,.ui.mini.loader{width:1.2857em;height:1.2857em;font-size:.71428571em}.ui.inverted.dimmer .ui.small.loader,.ui.small.loader{width:1.7142em;height:1.7142em;font-size:.92857143em}.ui.inverted.dimmer .ui.loader,.ui.loader{width:2.2585em;height:2.2585em;font-size:1em}.ui.inverted.dimmer .ui.loader.large,.ui.loader.large{width:4.5714em;height:4.5714em;font-size:1.14285714em}.ui.mini.text.loader{min-width:1.2857em;padding-top:1.99998571em}.ui.small.text.loader{min-width:1.7142em;padding-top:2.42848571em}.ui.text.loader{min-width:2.2585em;padding-top:2.97278571em}.ui.large.text.loader{min-width:4.5714em;padding-top:5.28568571em}.ui.inverted.loader{color:rgba(255,255,255,.9)}.ui.inverted.loader:before{border-color:rgba(255,255,255,.15)}.ui.inverted.loader:after{border-top-color:#fff}.ui.inline.loader{position:relative;vertical-align:middle;margin:0;left:0;top:0;-webkit-transform:none;-ms-transform:none;transform:none}.ui.inline.loader.active,.ui.inline.loader.visible{display:inline-block}.ui.centered.inline.loader.active,.ui.centered.inline.loader.visible{display:block;margin-left:auto;margin-right:auto}
--------------------------------------------------------------------------------
/public/css/semantic/components/image.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Image
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.image{position:relative;display:inline-block;vertical-align:middle;max-width:100%;background-color:transparent}img.ui.image{display:block}.ui.image img,.ui.image svg{display:block;max-width:100%;height:auto}.ui.hidden.image,.ui.hidden.images{display:none}.ui.disabled.image,.ui.disabled.images{cursor:default;opacity:.45}.ui.inline.image,.ui.inline.image img,.ui.inline.image svg{display:inline-block}.ui.top.aligned.image,.ui.top.aligned.image img,.ui.top.aligned.image svg,.ui.top.aligned.images .image{display:inline-block;vertical-align:top}.ui.middle.aligned.image,.ui.middle.aligned.image img,.ui.middle.aligned.image svg,.ui.middle.aligned.images .image{display:inline-block;vertical-align:middle}.ui.bottom.aligned.image,.ui.bottom.aligned.image img,.ui.bottom.aligned.image svg,.ui.bottom.aligned.images .image{display:inline-block;vertical-align:bottom}.ui.rounded.image,.ui.rounded.image>*,.ui.rounded.images .image,.ui.rounded.images .image>*{border-radius:.3125em}.ui.bordered.image img,.ui.bordered.image svg,.ui.bordered.images .image,.ui.bordered.images img,.ui.bordered.images svg,img.ui.bordered.image{border:1px solid rgba(0,0,0,.1)}.ui.circular.image,.ui.circular.images{overflow:hidden}.ui.circular.image,.ui.circular.image>*,.ui.circular.images .image,.ui.circular.images .image>*{border-radius:500rem}.ui.fluid.image,.ui.fluid.image img,.ui.fluid.image svg,.ui.fluid.images,.ui.fluid.images img,.ui.fluid.images svg{display:block;width:100%;height:auto}.ui.avatar.image,.ui.avatar.image img,.ui.avatar.image svg,.ui.avatar.images .image,.ui.avatar.images img,.ui.avatar.images svg{margin-right:.25em;display:inline-block;width:2em;height:2em;border-radius:500rem}.ui.spaced.image{display:inline-block!important;margin-left:.5em;margin-right:.5em}.ui[class*="left spaced"].image{margin-left:.5em;margin-right:0}.ui[class*="right spaced"].image{margin-left:0;margin-right:.5em}.ui.floated.image,.ui.floated.images{float:left;margin-right:1em;margin-bottom:1em}.ui.right.floated.image,.ui.right.floated.images{float:right;margin-right:0;margin-bottom:1em;margin-left:1em}.ui.floated.image:last-child,.ui.floated.images:last-child{margin-bottom:0}.ui.centered.image,.ui.centered.images{margin-left:auto;margin-right:auto}.ui.mini.image,.ui.mini.images .image,.ui.mini.images img,.ui.mini.images svg{width:35px;height:auto;font-size:.71428571rem}.ui.tiny.image,.ui.tiny.images .image,.ui.tiny.images img,.ui.tiny.images svg{width:80px;height:auto;font-size:.85714286rem}.ui.small.image,.ui.small.images .image,.ui.small.images img,.ui.small.images svg{width:150px;height:auto;font-size:.92857143rem}.ui.medium.image,.ui.medium.images .image,.ui.medium.images img,.ui.medium.images svg{width:300px;height:auto;font-size:1rem}.ui.large.image,.ui.large.images .image,.ui.large.images img,.ui.large.images svg{width:450px;height:auto;font-size:1.14285714rem}.ui.big.image,.ui.big.images .image,.ui.big.images img,.ui.big.images svg{width:600px;height:auto;font-size:1.28571429rem}.ui.huge.image,.ui.huge.images .image,.ui.huge.images img,.ui.huge.images svg{width:800px;height:auto;font-size:1.42857143rem}.ui.massive.image,.ui.massive.images .image,.ui.massive.images img,.ui.massive.images svg{width:960px;height:auto;font-size:1.71428571rem}.ui.images{font-size:0;margin:0 -.25rem}.ui.images .image,.ui.images img,.ui.images svg{display:inline-block;margin:0 .25rem .5rem}
--------------------------------------------------------------------------------
/public/css/semantic/components/site.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Site
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Page
15 | *******************************/
16 |
17 | @import url('https://fonts.googleapis.com/css?family=Lato:400,700,400italic,700italic&subset=latin');
18 | html,
19 | body {
20 | height: 100%;
21 | }
22 | html {
23 | font-size: 14px;
24 | }
25 | body {
26 | margin: 0px;
27 | padding: 0px;
28 | overflow-x: hidden;
29 | min-width: 320px;
30 | background: #ffffff;
31 | font-family: 'Lato', 'Helvetica Neue', Arial, Helvetica, sans-serif;
32 | font-size: 14px;
33 | line-height: 1.4285em;
34 | color: rgba(0, 0, 0, 0.87);
35 | font-smoothing: antialiased;
36 | }
37 |
38 |
39 | /*******************************
40 | Headers
41 | *******************************/
42 |
43 | h1,
44 | h2,
45 | h3,
46 | h4,
47 | h5 {
48 | font-family: 'Lato', 'Helvetica Neue', Arial, Helvetica, sans-serif;
49 | line-height: 1.2857em;
50 | margin: calc(2rem - 0.14285em ) 0em 1rem;
51 | font-weight: bold;
52 | padding: 0em;
53 | }
54 | h1 {
55 | min-height: 1rem;
56 | font-size: 2rem;
57 | }
58 | h2 {
59 | font-size: 1.714rem;
60 | }
61 | h3 {
62 | font-size: 1.28rem;
63 | }
64 | h4 {
65 | font-size: 1.071rem;
66 | }
67 | h5 {
68 | font-size: 1rem;
69 | }
70 | h1:first-child,
71 | h2:first-child,
72 | h3:first-child,
73 | h4:first-child,
74 | h5:first-child {
75 | margin-top: 0em;
76 | }
77 | h1:last-child,
78 | h2:last-child,
79 | h3:last-child,
80 | h4:last-child,
81 | h5:last-child {
82 | margin-bottom: 0em;
83 | }
84 |
85 |
86 | /*******************************
87 | Text
88 | *******************************/
89 |
90 | p {
91 | margin: 0em 0em 1em;
92 | line-height: 1.4285em;
93 | }
94 | p:first-child {
95 | margin-top: 0em;
96 | }
97 | p:last-child {
98 | margin-bottom: 0em;
99 | }
100 |
101 | /*-------------------
102 | Links
103 | --------------------*/
104 |
105 | a {
106 | color: #4183c4;
107 | text-decoration: none;
108 | }
109 | a:hover {
110 | color: #1e70bf;
111 | text-decoration: none;
112 | }
113 |
114 |
115 | /*******************************
116 | Highlighting
117 | *******************************/
118 |
119 |
120 | /* Site */
121 | ::-webkit-selection {
122 | background-color: #cce2ff;
123 | color: rgba(0, 0, 0, 0.87);
124 | }
125 | ::-moz-selection {
126 | background-color: #cce2ff;
127 | color: rgba(0, 0, 0, 0.87);
128 | }
129 | ::selection {
130 | background-color: #cce2ff;
131 | color: rgba(0, 0, 0, 0.87);
132 | }
133 |
134 | /* Form */
135 | textarea::-webkit-selection,
136 | input::-webkit-selection {
137 | background-color: rgba(100, 100, 100, 0.4);
138 | color: rgba(0, 0, 0, 0.87);
139 | }
140 | textarea::-moz-selection,
141 | input::-moz-selection {
142 | background-color: rgba(100, 100, 100, 0.4);
143 | color: rgba(0, 0, 0, 0.87);
144 | }
145 | textarea::selection,
146 | input::selection {
147 | background-color: rgba(100, 100, 100, 0.4);
148 | color: rgba(0, 0, 0, 0.87);
149 | }
150 |
151 |
152 | /*******************************
153 | Global Overrides
154 | *******************************/
155 |
156 |
157 |
158 | /*******************************
159 | Site Overrides
160 | *******************************/
161 |
162 |
--------------------------------------------------------------------------------
/public/css/semantic/components/feed.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Feed
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.feed{margin:1em 0}.ui.feed:first-child{margin-top:0}.ui.feed:last-child{margin-bottom:0}.ui.feed>.event{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;width:100%;padding:.21428571rem 0;margin:0;background:0 0;border-top:none}.ui.feed>.event:first-child{border-top:0;padding-top:0}.ui.feed>.event:last-child{padding-bottom:0}.ui.feed>.event>.label{display:block;-webkit-box-flex:0;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;width:2.5em;height:auto;-webkit-align-self:stretch;-ms-flex-item-align:stretch;align-self:stretch;text-align:left}.ui.feed>.event>.label .icon{opacity:1;font-size:1.5em;width:100%;padding:.25em;background:0 0;border:none;border-radius:none;color:rgba(0,0,0,.6)}.ui.feed>.event>.label img{width:100%;height:auto;border-radius:500rem}.ui.feed>.event>.label+.content{margin:.5em 0 .35714286em 1.14285714em}.ui.feed>.event>.content{display:block;-webkit-box-flex:1;-webkit-flex:1 1 auto;-ms-flex:1 1 auto;flex:1 1 auto;-webkit-align-self:stretch;-ms-flex-item-align:stretch;align-self:stretch;text-align:left;word-wrap:break-word}.ui.feed>.event:last-child>.content{padding-bottom:0}.ui.feed>.event>.content a{cursor:pointer}.ui.feed>.event>.content .date{margin:-.5rem 0 0;padding:0;font-weight:400;font-size:1em;font-style:normal;color:rgba(0,0,0,.4)}.ui.feed>.event>.content .summary{margin:0;font-size:1em;font-weight:700;color:rgba(0,0,0,.87)}.ui.feed>.event>.content .summary img{display:inline-block;width:auto;height:10em;margin:-.25em .25em 0 0;border-radius:.25em;vertical-align:middle}.ui.feed>.event>.content .user{display:inline-block;font-weight:700;margin-right:0;vertical-align:baseline}.ui.feed>.event>.content .user img{margin:-.25em .25em 0 0;width:auto;height:10em;vertical-align:middle}.ui.feed>.event>.content .summary>.date{display:inline-block;float:none;font-weight:400;font-size:.85714286em;font-style:normal;margin:0 0 0 .5em;padding:0;color:rgba(0,0,0,.4)}.ui.feed>.event>.content .extra{margin:.5em 0 0;background:0 0;padding:0;color:rgba(0,0,0,.87)}.ui.feed>.event>.content .extra.images img{display:inline-block;margin:0 .25em 0 0;width:6em}.ui.feed>.event>.content .extra.text{padding:0;border-left:none;font-size:1em;max-width:500px;line-height:1.4285em}.ui.feed>.event>.content .meta{display:inline-block;font-size:.85714286em;margin:.5em 0 0;background:0 0;border:none;border-radius:0;box-shadow:none;padding:0;color:rgba(0,0,0,.6)}.ui.feed>.event>.content .meta>*{position:relative;margin-left:.75em}.ui.feed>.event>.content .meta>:after{content:'';color:rgba(0,0,0,.2);top:0;left:-1em;opacity:1;position:absolute;vertical-align:top}.ui.feed>.event>.content .meta .like{color:'';-webkit-transition:.2s color ease;transition:.2s color ease}.ui.feed>.event>.content .meta .like:hover .icon{color:#ff2733}.ui.feed>.event>.content .meta .active.like .icon{color:#ef404a}.ui.feed>.event>.content .meta>:first-child{margin-left:0}.ui.feed>.event>.content .meta>:first-child::after{display:none}.ui.feed>.event>.content .meta a,.ui.feed>.event>.content .meta>.icon{cursor:pointer;opacity:1;color:rgba(0,0,0,.5);-webkit-transition:color .1s ease;transition:color .1s ease}.ui.feed>.event>.content .meta a:hover,.ui.feed>.event>.content .meta a:hover .icon,.ui.feed>.event>.content .meta>.icon:hover{color:rgba(0,0,0,.95)}.ui.small.feed{font-size:.92857143rem}.ui.feed{font-size:1rem}.ui.large.feed{font-size:1.14285714rem}
--------------------------------------------------------------------------------
/public/css/semantic/components/container.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Container
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Container
15 | *******************************/
16 |
17 |
18 | /* All Sizes */
19 | .ui.container {
20 | display: block;
21 | max-width: 100% !important;
22 | }
23 |
24 | /* Mobile */
25 | @media only screen and (max-width: 767px) {
26 | .ui.container {
27 | width: auto !important;
28 | margin-left: 1em !important;
29 | margin-right: 1em !important;
30 | }
31 | .ui.grid.container {
32 | width: auto !important;
33 | }
34 | .ui.relaxed.grid.container {
35 | width: auto !important;
36 | }
37 | .ui.very.relaxed.grid.container {
38 | width: auto !important;
39 | }
40 | }
41 |
42 | /* Tablet */
43 | @media only screen and (min-width: 768px) and (max-width: 991px) {
44 | .ui.container {
45 | width: 723px;
46 | margin-left: auto !important;
47 | margin-right: auto !important;
48 | }
49 | .ui.grid.container {
50 | width: calc( 723px + 2rem ) !important;
51 | }
52 | .ui.relaxed.grid.container {
53 | width: calc( 723px + 3rem ) !important;
54 | }
55 | .ui.very.relaxed.grid.container {
56 | width: calc( 723px + 5rem ) !important;
57 | }
58 | }
59 |
60 | /* Small Monitor */
61 | @media only screen and (min-width: 992px) and (max-width: 1199px) {
62 | .ui.container {
63 | width: 933px;
64 | margin-left: auto !important;
65 | margin-right: auto !important;
66 | }
67 | .ui.grid.container {
68 | width: calc( 933px + 2rem ) !important;
69 | }
70 | .ui.relaxed.grid.container {
71 | width: calc( 933px + 3rem ) !important;
72 | }
73 | .ui.very.relaxed.grid.container {
74 | width: calc( 933px + 5rem ) !important;
75 | }
76 | }
77 |
78 | /* Large Monitor */
79 | @media only screen and (min-width: 1200px) {
80 | .ui.container {
81 | width: 1127px;
82 | margin-left: auto !important;
83 | margin-right: auto !important;
84 | }
85 | .ui.grid.container {
86 | width: calc( 1127px + 2rem ) !important;
87 | }
88 | .ui.relaxed.grid.container {
89 | width: calc( 1127px + 3rem ) !important;
90 | }
91 | .ui.very.relaxed.grid.container {
92 | width: calc( 1127px + 5rem ) !important;
93 | }
94 | }
95 |
96 |
97 | /*******************************
98 | Types
99 | *******************************/
100 |
101 |
102 | /* Text Container */
103 | .ui.text.container {
104 | font-family: 'Lato', 'Helvetica Neue', Arial, Helvetica, sans-serif;
105 | max-width: 700px !important;
106 | line-height: 1.5;
107 | }
108 | .ui.text.container {
109 | font-size: 1.14285714rem;
110 | }
111 |
112 | /* Fluid */
113 | .ui.fluid.container {
114 | width: 100%;
115 | }
116 |
117 |
118 | /*******************************
119 | Variations
120 | *******************************/
121 |
122 | .ui[class*="left aligned"].container {
123 | text-align: left;
124 | }
125 | .ui[class*="center aligned"].container {
126 | text-align: center;
127 | }
128 | .ui[class*="right aligned"].container {
129 | text-align: right;
130 | }
131 | .ui.justified.container {
132 | text-align: justify;
133 | -webkit-hyphens: auto;
134 | -moz-hyphens: auto;
135 | -ms-hyphens: auto;
136 | hyphens: auto;
137 | }
138 |
139 |
140 | /*******************************
141 | Theme Overrides
142 | *******************************/
143 |
144 |
145 |
146 | /*******************************
147 | Site Overrides
148 | *******************************/
149 |
150 |
--------------------------------------------------------------------------------
/public/css/bootstrap-colorpicker.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * Bootstrap Colorpicker
3 | * http://mjolnic.github.io/bootstrap-colorpicker/
4 | *
5 | * Originally written by (c) 2012 Stefan Petre
6 | * Licensed under the Apache License v2.0
7 | * http://www.apache.org/licenses/LICENSE-2.0.txt
8 | *
9 | */.colorpicker-saturation{float:left;width:100px;height:100px;cursor:crosshair;background-image:url("../img/bootstrap-colorpicker/saturation.png")}.colorpicker-saturation i{position:absolute;top:0;left:0;display:block;width:5px;height:5px;margin:-4px 0 0 -4px;border:1px solid #000;-webkit-border-radius:5px;-moz-border-radius:5px;border-radius:5px}.colorpicker-saturation i b{display:block;width:5px;height:5px;border:1px solid #fff;-webkit-border-radius:5px;-moz-border-radius:5px;border-radius:5px}.colorpicker-hue,.colorpicker-alpha{float:left;width:15px;height:100px;margin-bottom:4px;margin-left:4px;cursor:row-resize}.colorpicker-hue i,.colorpicker-alpha i{position:absolute;top:0;left:0;display:block;width:100%;height:1px;margin-top:-1px;background:#000;border-top:1px solid #fff}.colorpicker-hue{background-image:url("../img/bootstrap-colorpicker/hue.png")}.colorpicker-alpha{display:none;background-image:url("../img/bootstrap-colorpicker/alpha.png")}.colorpicker-saturation,.colorpicker-hue,.colorpicker-alpha{background-size:contain}.colorpicker{top:0;left:0;z-index:2500;min-width:130px;padding:4px;margin-top:1px;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;*zoom:1}.colorpicker:before,.colorpicker:after{display:table;line-height:0;content:""}.colorpicker:after{clear:both}.colorpicker:before{position:absolute;top:-7px;left:6px;display:inline-block;border-right:7px solid transparent;border-bottom:7px solid #ccc;border-left:7px solid transparent;border-bottom-color:rgba(0,0,0,0.2);content:''}.colorpicker:after{position:absolute;top:-6px;left:7px;display:inline-block;border-right:6px solid transparent;border-bottom:6px solid #fff;border-left:6px solid transparent;content:''}.colorpicker div{position:relative}.colorpicker.colorpicker-with-alpha{min-width:140px}.colorpicker.colorpicker-with-alpha .colorpicker-alpha{display:block}.colorpicker-color{height:10px;margin-top:5px;clear:both;background-image:url("../img/bootstrap-colorpicker/alpha.png");background-position:0 100%}.colorpicker-color div{height:10px}.colorpicker-selectors{display:none;height:10px;margin-top:5px;clear:both}.colorpicker-selectors i{float:left;width:10px;height:10px;cursor:pointer}.colorpicker-selectors i+i{margin-left:3px}.colorpicker-element .input-group-addon i,.colorpicker-element .add-on i{display:inline-block;width:16px;height:16px;vertical-align:text-top;cursor:pointer}.colorpicker.colorpicker-inline{position:relative;z-index:auto;display:inline-block;float:none}.colorpicker.colorpicker-horizontal{width:110px;height:auto;min-width:110px}.colorpicker.colorpicker-horizontal .colorpicker-saturation{margin-bottom:4px}.colorpicker.colorpicker-horizontal .colorpicker-color{width:100px}.colorpicker.colorpicker-horizontal .colorpicker-hue,.colorpicker.colorpicker-horizontal .colorpicker-alpha{float:left;width:100px;height:15px;margin-bottom:4px;margin-left:0;cursor:col-resize}.colorpicker.colorpicker-horizontal .colorpicker-hue i,.colorpicker.colorpicker-horizontal .colorpicker-alpha i{position:absolute;top:0;left:0;display:block;width:1px;height:15px;margin-top:0;background:#fff;border:0}.colorpicker.colorpicker-horizontal .colorpicker-hue{background-image:url("../img/bootstrap-colorpicker/hue-horizontal.png")}.colorpicker.colorpicker-horizontal .colorpicker-alpha{background-image:url("../img/bootstrap-colorpicker/alpha-horizontal.png")}.colorpicker.colorpicker-hidden{display:none}.colorpicker.colorpicker-visible{display:block}.colorpicker-inline.colorpicker-visible{display:inline-block}.colorpicker-right:before{right:6px;left:auto}.colorpicker-right:after{right:7px;left:auto}.colorpicker-no-arrow:before{border-right:0;border-left:0}.colorpicker-no-arrow:after{border-right:0;border-left:0}
--------------------------------------------------------------------------------
/public/css/semantic/components/shape.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Shape
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Shape
15 | *******************************/
16 |
17 | .ui.shape {
18 | position: relative;
19 | vertical-align: top;
20 | display: inline-block;
21 | -webkit-perspective: 2000px;
22 | perspective: 2000px;
23 | -webkit-transition: -webkit-transform 0.6s ease-in-out, left 0.6s ease-in-out, width 0.6s ease-in-out, height 0.6s ease-in-out;
24 | transition: transform 0.6s ease-in-out, left 0.6s ease-in-out, width 0.6s ease-in-out, height 0.6s ease-in-out;
25 | }
26 | .ui.shape .sides {
27 | -webkit-transform-style: preserve-3d;
28 | transform-style: preserve-3d;
29 | }
30 | .ui.shape .side {
31 | opacity: 1;
32 | width: 100%;
33 | margin: 0em !important;
34 | -webkit-backface-visibility: hidden;
35 | backface-visibility: hidden;
36 | }
37 | .ui.shape .side {
38 | display: none;
39 | }
40 | .ui.shape .side * {
41 | -webkit-backface-visibility: visible !important;
42 | backface-visibility: visible !important;
43 | }
44 |
45 |
46 | /*******************************
47 | Types
48 | *******************************/
49 |
50 | .ui.cube.shape .side {
51 | min-width: 15em;
52 | height: 15em;
53 | padding: 2em;
54 | background-color: #e6e6e6;
55 | color: rgba(0, 0, 0, 0.87);
56 | box-shadow: 0px 0px 2px rgba(0, 0, 0, 0.3);
57 | }
58 | .ui.cube.shape .side > .content {
59 | width: 100%;
60 | height: 100%;
61 | display: table;
62 | text-align: center;
63 | -webkit-user-select: text;
64 | -moz-user-select: text;
65 | -ms-user-select: text;
66 | user-select: text;
67 | }
68 | .ui.cube.shape .side > .content > div {
69 | display: table-cell;
70 | vertical-align: middle;
71 | font-size: 2em;
72 | }
73 |
74 |
75 | /*******************************
76 | Variations
77 | *******************************/
78 |
79 | .ui.text.shape.animating .sides {
80 | position: static;
81 | }
82 | .ui.text.shape .side {
83 | white-space: nowrap;
84 | }
85 | .ui.text.shape .side > * {
86 | white-space: normal;
87 | }
88 |
89 |
90 | /*******************************
91 | States
92 | *******************************/
93 |
94 |
95 | /*--------------
96 | Loading
97 | ---------------*/
98 |
99 | .ui.loading.shape {
100 | position: absolute;
101 | top: -9999px;
102 | left: -9999px;
103 | }
104 |
105 | /*--------------
106 | Animating
107 | ---------------*/
108 |
109 | .ui.shape .animating.side {
110 | position: absolute;
111 | top: 0px;
112 | left: 0px;
113 | display: block;
114 | z-index: 100;
115 | }
116 | .ui.shape .hidden.side {
117 | opacity: 0.6;
118 | }
119 |
120 | /*--------------
121 | CSS
122 | ---------------*/
123 |
124 | .ui.shape.animating .sides {
125 | position: absolute;
126 | }
127 | .ui.shape.animating .sides {
128 | -webkit-transition: -webkit-transform 0.6s ease-in-out, left 0.6s ease-in-out, width 0.6s ease-in-out, height 0.6s ease-in-out;
129 | transition: transform 0.6s ease-in-out, left 0.6s ease-in-out, width 0.6s ease-in-out, height 0.6s ease-in-out;
130 | }
131 | .ui.shape.animating .side {
132 | -webkit-transition: opacity 0.6s ease-in-out;
133 | transition: opacity 0.6s ease-in-out;
134 | }
135 |
136 | /*--------------
137 | Active
138 | ---------------*/
139 |
140 | .ui.shape .active.side {
141 | display: block;
142 | }
143 |
144 |
145 | /*******************************
146 | Theme Overrides
147 | *******************************/
148 |
149 |
150 |
151 | /*******************************
152 | User Overrides
153 | *******************************/
154 |
155 |
--------------------------------------------------------------------------------
/public/css/semantic/components/embed.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Video
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Types
15 | *******************************/
16 |
17 | .ui.embed {
18 | position: relative;
19 | max-width: 100%;
20 | height: 0px;
21 | overflow: hidden;
22 | background: #dcddde;
23 | padding-bottom: 56.25%;
24 | }
25 |
26 | /*-----------------
27 | Embedded Content
28 | ------------------*/
29 |
30 | .ui.embed iframe,
31 | .ui.embed embed,
32 | .ui.embed object {
33 | position: absolute;
34 | border: none;
35 | width: 100%;
36 | height: 100%;
37 | top: 0px;
38 | left: 0px;
39 | margin: 0em;
40 | padding: 0em;
41 | }
42 |
43 | /*-----------------
44 | Embed
45 | ------------------*/
46 |
47 | .ui.embed > .embed {
48 | display: none;
49 | }
50 |
51 | /*--------------
52 | Placeholder
53 | ---------------*/
54 |
55 | .ui.embed > .placeholder {
56 | position: absolute;
57 | cursor: pointer;
58 | top: 0px;
59 | left: 0px;
60 | display: block;
61 | width: 100%;
62 | height: 100%;
63 | background-color: radial-gradient(transparent 45%, rgba(0, 0, 0, 0.3));
64 | }
65 |
66 | /*--------------
67 | Icon
68 | ---------------*/
69 |
70 | .ui.embed > .icon {
71 | cursor: pointer;
72 | position: absolute;
73 | top: 0px;
74 | left: 0px;
75 | width: 100%;
76 | height: 100%;
77 | z-index: 2;
78 | }
79 | .ui.embed > .icon:after {
80 | position: absolute;
81 | top: 0%;
82 | left: 0%;
83 | width: 100%;
84 | height: 100%;
85 | z-index: 3;
86 | content: '';
87 | background: -webkit-radial-gradient(transparent 45%, rgba(0, 0, 0, 0.3));
88 | background: radial-gradient(transparent 45%, rgba(0, 0, 0, 0.3));
89 | opacity: 0.5;
90 | -webkit-transition: opacity 0.5s ease;
91 | transition: opacity 0.5s ease;
92 | }
93 | .ui.embed > .icon:before {
94 | position: absolute;
95 | top: 50%;
96 | left: 50%;
97 | z-index: 4;
98 | -webkit-transform: translateX(-50%) translateY(-50%);
99 | -ms-transform: translateX(-50%) translateY(-50%);
100 | transform: translateX(-50%) translateY(-50%);
101 | color: #ffffff;
102 | font-size: 6rem;
103 | text-shadow: 0px 2px 10px rgba(34, 36, 38, 0.2);
104 | -webkit-transition: opacity 0.5s ease, color 0.5s ease;
105 | transition: opacity 0.5s ease, color 0.5s ease;
106 | z-index: 10;
107 | }
108 |
109 |
110 | /*******************************
111 | States
112 | *******************************/
113 |
114 |
115 | /*--------------
116 | Hover
117 | ---------------*/
118 |
119 | .ui.embed .icon:hover:after {
120 | background: -webkit-radial-gradient(transparent 45%, rgba(0, 0, 0, 0.3));
121 | background: radial-gradient(transparent 45%, rgba(0, 0, 0, 0.3));
122 | opacity: 1;
123 | }
124 | .ui.embed .icon:hover:before {
125 | color: #ffffff;
126 | }
127 |
128 | /*--------------
129 | Active
130 | ---------------*/
131 |
132 | .ui.active.embed > .icon,
133 | .ui.active.embed > .placeholder {
134 | display: none;
135 | }
136 | .ui.active.embed > .embed {
137 | display: block;
138 | }
139 |
140 |
141 | /*******************************
142 | Video Overrides
143 | *******************************/
144 |
145 |
146 |
147 | /*******************************
148 | Site Overrides
149 | *******************************/
150 |
151 |
152 |
153 | /*******************************
154 | Variations
155 | *******************************/
156 |
157 | .ui.square.embed {
158 | padding-bottom: 100%;
159 | }
160 | .ui[class*="4:3"].embed {
161 | padding-bottom: 75%;
162 | }
163 | .ui[class*="16:9"].embed {
164 | padding-bottom: 56.25%;
165 | }
166 | .ui[class*="21:9"].embed {
167 | padding-bottom: 42.85714286%;
168 | }
169 |
--------------------------------------------------------------------------------
/public/css/semantic/components/popup.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Popup
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.popup{display:none;position:absolute;top:0;right:0;min-width:-webkit-min-content;min-width:-moz-min-content;min-width:min-content;z-index:1900;border:1px solid #d4d4d5;line-height:1.4285em;max-width:250px;background:#fff;padding:.833em 1em;font-weight:400;font-style:normal;color:rgba(0,0,0,.87);border-radius:.28571429rem;box-shadow:0 2px 4px 0 rgba(34,36,38,.12),0 2px 10px 0 rgba(34,36,38,.08);margin:0}.ui.popup>.header{padding:0;font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;font-size:1.125em;line-height:1.2;font-weight:700}.ui.popup>.header+.content{padding-top:.5em}.ui.popup:before{position:absolute;content:'';width:.75em;height:.75em;background:#fff;-webkit-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg);z-index:2;box-shadow:1px 1px 0 0 #bababc}.ui.top.popup{margin:0 0 .75em}.ui.top.left.popup{-webkit-transform-origin:left bottom;-ms-transform-origin:left bottom;transform-origin:left bottom}.ui.top.center.popup{-webkit-transform-origin:center bottom;-ms-transform-origin:center bottom;transform-origin:center bottom}.ui.top.right.popup{-webkit-transform-origin:right bottom;-ms-transform-origin:right bottom;transform-origin:right bottom}.ui.left.center.popup{margin:0 .75em 0 0;-webkit-transform-origin:right 50%;-ms-transform-origin:right 50%;transform-origin:right 50%}.ui.right.center.popup{margin:0 0 0 .75em;-webkit-transform-origin:left 50%;-ms-transform-origin:left 50%;transform-origin:left 50%}.ui.bottom.popup{margin:.75em 0 0}.ui.bottom.left.popup{-webkit-transform-origin:left top;-ms-transform-origin:left top;transform-origin:left top}.ui.bottom.center.popup{-webkit-transform-origin:center top;-ms-transform-origin:center top;transform-origin:center top}.ui.bottom.right.popup{-webkit-transform-origin:right top;-ms-transform-origin:right top;transform-origin:right top;margin-right:0}.ui.bottom.center.popup:before{margin-left:-.325em;top:-.325em;left:50%;right:auto;bottom:auto;box-shadow:-1px -1px 0 0 #bababc}.ui.bottom.left.popup{margin-left:0}.ui.bottom.left.popup:before{top:-.325em;left:1em;right:auto;bottom:auto;margin-left:0;box-shadow:-1px -1px 0 0 #bababc}.ui.bottom.right.popup:before{top:-.325em;right:1em;bottom:auto;left:auto;margin-left:0;box-shadow:-1px -1px 0 0 #bababc}.ui.top.center.popup:before{top:auto;right:auto;bottom:-.325em;left:50%;margin-left:-.325em}.ui.top.left.popup{margin-left:0}.ui.top.left.popup:before{bottom:-.325em;left:1em;top:auto;right:auto;margin-left:0}.ui.top.right.popup{margin-right:0}.ui.top.right.popup:before{bottom:-.325em;right:1em;top:auto;left:auto;margin-left:0}.ui.left.center.popup:before{top:50%;right:-.325em;bottom:auto;left:auto;margin-top:-.325em;box-shadow:1px -1px 0 0 #bababc}.ui.right.center.popup:before{top:50%;left:-.325em;bottom:auto;right:auto;margin-top:-.325em;box-shadow:-1px 1px 0 0 #bababc}.ui.bottom.popup:before,.ui.left.center.popup:before,.ui.right.center.popup:before,.ui.top.popup:before{background:#fff}.ui.inverted.bottom.popup:before,.ui.inverted.left.center.popup:before,.ui.inverted.right.center.popup:before,.ui.inverted.top.popup:before{background:#1b1c1d}.ui.popup>.ui.grid:not(.padded){width:calc(100% + 1.75rem);margin:-.7rem -.875rem}.ui.loading.popup{display:block;visibility:hidden;z-index:-1}.ui.animating.popup,.ui.visible.popup{display:block}.ui.visible.popup{-webkit-transform:translateZ(0);transform:translateZ(0);-webkit-backface-visibility:hidden;backface-visibility:hidden}.ui.basic.popup:before{display:none}.ui.wide.popup{max-width:350px}.ui[class*="very wide"].popup{max-width:550px}@media only screen and (max-width:767px){.ui.wide.popup,.ui[class*="very wide"].popup{max-width:250px}}.ui.fluid.popup{width:100%;max-width:none}.ui.inverted.popup{background:#1b1c1d;color:#fff;border:none;box-shadow:none}.ui.inverted.popup .header{background-color:none;color:#fff}.ui.inverted.popup:before{background-color:#1b1c1d;box-shadow:none!important}.ui.flowing.popup{max-width:none}.ui.mini.popup{font-size:.71428571rem}.ui.tiny.popup{font-size:.85714286rem}.ui.small.popup{font-size:.92857143rem}.ui.popup{font-size:1rem}.ui.large.popup{font-size:1.14285714rem}.ui.huge.popup{font-size:1.42857143rem}
--------------------------------------------------------------------------------
/public/app_3th_js/forIE/respond.min.js:
--------------------------------------------------------------------------------
1 | /*! Respond.js v1.4.2: min/max-width media query polyfill
2 | * Copyright 2014 Scott Jehl
3 | * Licensed under MIT
4 | * http://j.mp/respondjs */
5 |
6 | !function(a){"use strict";a.matchMedia=a.matchMedia||function(a){var b,c=a.documentElement,d=c.firstElementChild||c.firstChild,e=a.createElement("body"),f=a.createElement("div");return f.id="mq-test-1",f.style.cssText="position:absolute;top:-100em",e.style.background="none",e.appendChild(f),function(a){return f.innerHTML='',c.insertBefore(e,d),b=42===f.offsetWidth,c.removeChild(e),{matches:b,media:a}}}(a.document)}(this),function(a){"use strict";function b(){v(!0)}var c={};a.respond=c,c.update=function(){};var d=[],e=function(){var b=!1;try{b=new a.XMLHttpRequest}catch(c){b=new a.ActiveXObject("Microsoft.XMLHTTP")}return function(){return b}}(),f=function(a,b){var c=e();c&&(c.open("GET",a,!0),c.onreadystatechange=function(){4!==c.readyState||200!==c.status&&304!==c.status||b(c.responseText)},4!==c.readyState&&c.send(null))},g=function(a){return a.replace(c.regex.minmaxwh,"").match(c.regex.other)};if(c.ajax=f,c.queue=d,c.unsupportedmq=g,c.regex={media:/@media[^\{]+\{([^\{\}]*\{[^\}\{]*\})+/gi,keyframes:/@(?:\-(?:o|moz|webkit)\-)?keyframes[^\{]+\{(?:[^\{\}]*\{[^\}\{]*\})+[^\}]*\}/gi,comments:/\/\*[^*]*\*+([^/][^*]*\*+)*\//gi,urls:/(url\()['"]?([^\/\)'"][^:\)'"]+)['"]?(\))/g,findStyles:/@media *([^\{]+)\{([\S\s]+?)$/,only:/(only\s+)?([a-zA-Z]+)\s?/,minw:/\(\s*min\-width\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/,maxw:/\(\s*max\-width\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/,minmaxwh:/\(\s*m(in|ax)\-(height|width)\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/gi,other:/\([^\)]*\)/g},c.mediaQueriesSupported=a.matchMedia&&null!==a.matchMedia("only all")&&a.matchMedia("only all").matches,!c.mediaQueriesSupported){var h,i,j,k=a.document,l=k.documentElement,m=[],n=[],o=[],p={},q=30,r=k.getElementsByTagName("head")[0]||l,s=k.getElementsByTagName("base")[0],t=r.getElementsByTagName("link"),u=function(){var a,b=k.createElement("div"),c=k.body,d=l.style.fontSize,e=c&&c.style.fontSize,f=!1;return b.style.cssText="position:absolute;font-size:1em;width:1em",c||(c=f=k.createElement("body"),c.style.background="none"),l.style.fontSize="100%",c.style.fontSize="100%",c.appendChild(b),f&&l.insertBefore(c,l.firstChild),a=b.offsetWidth,f?l.removeChild(c):c.removeChild(b),l.style.fontSize=d,e&&(c.style.fontSize=e),a=j=parseFloat(a)},v=function(b){var c="clientWidth",d=l[c],e="CSS1Compat"===k.compatMode&&d||k.body[c]||d,f={},g=t[t.length-1],p=(new Date).getTime();if(b&&h&&q>p-h)return a.clearTimeout(i),i=a.setTimeout(v,q),void 0;h=p;for(var s in m)if(m.hasOwnProperty(s)){var w=m[s],x=w.minw,y=w.maxw,z=null===x,A=null===y,B="em";x&&(x=parseFloat(x)*(x.indexOf(B)>-1?j||u():1)),y&&(y=parseFloat(y)*(y.indexOf(B)>-1?j||u():1)),w.hasquery&&(z&&A||!(z||e>=x)||!(A||y>=e))||(f[w.media]||(f[w.media]=[]),f[w.media].push(n[w.rules]))}for(var C in o)o.hasOwnProperty(C)&&o[C]&&o[C].parentNode===r&&r.removeChild(o[C]);o.length=0;for(var D in f)if(f.hasOwnProperty(D)){var E=k.createElement("style"),F=f[D].join("\n");E.type="text/css",E.media=D,r.insertBefore(E,g.nextSibling),E.styleSheet?E.styleSheet.cssText=F:E.appendChild(k.createTextNode(F)),o.push(E)}},w=function(a,b,d){var e=a.replace(c.regex.comments,"").replace(c.regex.keyframes,"").match(c.regex.media),f=e&&e.length||0;b=b.substring(0,b.lastIndexOf("/"));var h=function(a){return a.replace(c.regex.urls,"$1"+b+"$2$3")},i=!f&&d;b.length&&(b+="/"),i&&(f=1);for(var j=0;f>j;j++){var k,l,o,p;i?(k=d,n.push(h(a))):(k=e[j].match(c.regex.findStyles)&&RegExp.$1,n.push(RegExp.$2&&h(RegExp.$2))),o=k.split(","),p=o.length;for(var q=0;p>q;q++)l=o[q],g(l)||m.push({media:l.split("(")[0].match(c.regex.only)&&RegExp.$2||"all",rules:n.length-1,hasquery:l.indexOf("(")>-1,minw:l.match(c.regex.minw)&&parseFloat(RegExp.$1)+(RegExp.$2||""),maxw:l.match(c.regex.maxw)&&parseFloat(RegExp.$1)+(RegExp.$2||"")})}v()},x=function(){if(d.length){var b=d.shift();f(b.href,function(c){w(c,b.href,b.media),p[b.href]=!0,a.setTimeout(function(){x()},0)})}},y=function(){for(var b=0;b
2 |
3 |
4 |
5 |
6 | Login
7 |
8 |
9 |
13 |
14 |
15 |
16 |
17 |
登录 MultiDraw!
18 |
32 |
33 |
34 |
35 |
36 |
37 |
94 |
95 |
96 |
97 |
--------------------------------------------------------------------------------
/public/css/semantic/components/dimmer.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Dimmer
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Dimmer
15 | *******************************/
16 |
17 | .dimmable {
18 | position: relative;
19 | }
20 | .ui.dimmer {
21 | display: none;
22 | position: absolute;
23 | top: 0em !important;
24 | left: 0em !important;
25 | width: 100%;
26 | height: 100%;
27 | text-align: center;
28 | vertical-align: middle;
29 | background-color: rgba(0, 0, 0, 0.85);
30 | opacity: 0;
31 | line-height: 1;
32 | -webkit-animation-fill-mode: both;
33 | animation-fill-mode: both;
34 | -webkit-animation-duration: 0.5s;
35 | animation-duration: 0.5s;
36 | -webkit-transition: background-color 0.5s linear;
37 | transition: background-color 0.5s linear;
38 | -webkit-user-select: none;
39 | -moz-user-select: none;
40 | -ms-user-select: none;
41 | user-select: none;
42 | will-change: opacity;
43 | z-index: 1000;
44 | }
45 |
46 | /* Dimmer Content */
47 | .ui.dimmer > .content {
48 | width: 100%;
49 | height: 100%;
50 | display: table;
51 | -webkit-user-select: text;
52 | -moz-user-select: text;
53 | -ms-user-select: text;
54 | user-select: text;
55 | }
56 | .ui.dimmer > .content > * {
57 | display: table-cell;
58 | vertical-align: middle;
59 | color: #ffffff;
60 | }
61 |
62 | /* Loose Coupling */
63 | .ui.segment > .ui.dimmer {
64 | border-radius: inherit !important;
65 | }
66 |
67 |
68 | /*******************************
69 | States
70 | *******************************/
71 |
72 | .animating.dimmable:not(body),
73 | .dimmed.dimmable:not(body) {
74 | overflow: hidden;
75 | }
76 | .dimmed.dimmable > .ui.animating.dimmer,
77 | .dimmed.dimmable > .ui.visible.dimmer,
78 | .ui.active.dimmer {
79 | display: block;
80 | opacity: 1;
81 | }
82 | .ui.disabled.dimmer {
83 | width: 0 !important;
84 | height: 0 !important;
85 | }
86 |
87 |
88 | /*******************************
89 | Variations
90 | *******************************/
91 |
92 |
93 | /*--------------
94 | Page
95 | ---------------*/
96 |
97 | .ui.page.dimmer {
98 | position: fixed;
99 | -webkit-transform-style: '';
100 | transform-style: '';
101 | -webkit-perspective: 2000px;
102 | perspective: 2000px;
103 | -webkit-transform-origin: center center;
104 | -ms-transform-origin: center center;
105 | transform-origin: center center;
106 | }
107 | body.animating.in.dimmable,
108 | body.dimmed.dimmable {
109 | overflow: hidden;
110 | }
111 | body.dimmable > .dimmer {
112 | position: fixed;
113 | }
114 |
115 | /*--------------
116 | Blurring
117 | ---------------*/
118 |
119 | .blurring.dimmable > :not(.dimmer) {
120 | -webkit-filter: blur(0px) grayscale(0);
121 | filter: blur(0px) grayscale(0);
122 | -webkit-transition: 800ms -webkit-filter ease, 800ms filter ease;
123 | transition: 800ms filter ease;
124 | }
125 | .blurring.dimmed.dimmable > :not(.dimmer) {
126 | -webkit-filter: blur(5px) grayscale(0.7);
127 | filter: blur(5px) grayscale(0.7);
128 | }
129 |
130 | /* Dimmer Color */
131 | .blurring.dimmable > .dimmer {
132 | background-color: rgba(0, 0, 0, 0.6);
133 | }
134 | .blurring.dimmable > .inverted.dimmer {
135 | background-color: rgba(255, 255, 255, 0.6);
136 | }
137 |
138 | /*--------------
139 | Aligned
140 | ---------------*/
141 |
142 | .ui.dimmer > .top.aligned.content > * {
143 | vertical-align: top;
144 | }
145 | .ui.dimmer > .bottom.aligned.content > * {
146 | vertical-align: bottom;
147 | }
148 |
149 | /*--------------
150 | Inverted
151 | ---------------*/
152 |
153 | .ui.inverted.dimmer {
154 | background-color: rgba(255, 255, 255, 0.85);
155 | }
156 | .ui.inverted.dimmer > .content > * {
157 | color: #ffffff;
158 | }
159 |
160 | /*--------------
161 | Simple
162 | ---------------*/
163 |
164 |
165 | /* Displays without javascript */
166 | .ui.simple.dimmer {
167 | display: block;
168 | overflow: hidden;
169 | opacity: 1;
170 | width: 0%;
171 | height: 0%;
172 | z-index: -100;
173 | background-color: rgba(0, 0, 0, 0);
174 | }
175 | .dimmed.dimmable > .ui.simple.dimmer {
176 | overflow: visible;
177 | opacity: 1;
178 | width: 100%;
179 | height: 100%;
180 | background-color: rgba(0, 0, 0, 0.85);
181 | z-index: 1;
182 | }
183 | .ui.simple.inverted.dimmer {
184 | background-color: rgba(255, 255, 255, 0);
185 | }
186 | .dimmed.dimmable > .ui.simple.inverted.dimmer {
187 | background-color: rgba(255, 255, 255, 0.85);
188 | }
189 |
190 |
191 | /*******************************
192 | Theme Overrides
193 | *******************************/
194 |
195 |
196 |
197 | /*******************************
198 | User Overrides
199 | *******************************/
200 |
201 |
--------------------------------------------------------------------------------
/public/css/semantic/components/rating.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Rating
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 | !function(e,n,t,i){"use strict";e.fn.rating=function(n){var t,a=e(this),o=a.selector||"",r=(new Date).getTime(),s=[],l=arguments[0],c="string"==typeof l,u=[].slice.call(arguments,1);return a.each(function(){var g,m=e.isPlainObject(n)?e.extend(!0,{},e.fn.rating.settings,n):e.extend({},e.fn.rating.settings),d=m.namespace,f=m.className,v=m.metadata,p=m.selector,b=(m.error,"."+d),h="module-"+d,y=this,x=e(this).data(h),R=e(this),C=R.find(p.icon);g={initialize:function(){g.verbose("Initializing rating module",m),0===C.length&&g.setup.layout(),m.interactive?g.enable():g.disable(),g.set.rating(g.get.initialRating()),g.instantiate()},instantiate:function(){g.verbose("Instantiating module",m),x=g,R.data(h,g)},destroy:function(){g.verbose("Destroying previous instance",x),g.remove.events(),R.removeData(h)},refresh:function(){C=R.find(p.icon)},setup:{layout:function(){var n=g.get.maxRating(),t=e.fn.rating.settings.templates.icon(n);g.debug("Generating icon html dynamically"),R.html(t),g.refresh()}},event:{mouseenter:function(){var n=e(this);n.nextAll().removeClass(f.selected),R.addClass(f.selected),n.addClass(f.selected).prevAll().addClass(f.selected)},mouseleave:function(){R.removeClass(f.selected),C.removeClass(f.selected)},click:function(){var n=e(this),t=g.get.rating(),i=C.index(n)+1,a="auto"==m.clearable?1===C.length:m.clearable;a&&t==i?g.clearRating():g.set.rating(i)}},clearRating:function(){g.debug("Clearing current rating"),g.set.rating(0)},bind:{events:function(){g.verbose("Binding events"),R.on("mouseenter"+b,p.icon,g.event.mouseenter).on("mouseleave"+b,p.icon,g.event.mouseleave).on("click"+b,p.icon,g.event.click)}},remove:{events:function(){g.verbose("Removing events"),R.off(b)}},enable:function(){g.debug("Setting rating to interactive mode"),g.bind.events(),R.removeClass(f.disabled)},disable:function(){g.debug("Setting rating to read-only mode"),g.remove.events(),R.addClass(f.disabled)},get:{initialRating:function(){return R.data(v.rating)!==i?(R.removeData(v.rating),R.data(v.rating)):m.initialRating},maxRating:function(){return R.data(v.maxRating)!==i?(R.removeData(v.maxRating),R.data(v.maxRating)):m.maxRating},rating:function(){var e=C.filter("."+f.active).length;return g.verbose("Current rating retrieved",e),e}},set:{rating:function(e){var n=e-1>=0?e-1:0,t=C.eq(n);R.removeClass(f.selected),C.removeClass(f.selected).removeClass(f.active),e>0&&(g.verbose("Setting current rating to",e),t.prevAll().andSelf().addClass(f.active)),m.onRate.call(y,e)}},setting:function(n,t){if(g.debug("Changing setting",n,t),e.isPlainObject(n))e.extend(!0,m,n);else{if(t===i)return m[n];m[n]=t}},internal:function(n,t){if(e.isPlainObject(n))e.extend(!0,g,n);else{if(t===i)return g[n];g[n]=t}},debug:function(){m.debug&&(m.performance?g.performance.log(arguments):(g.debug=Function.prototype.bind.call(console.info,console,m.name+":"),g.debug.apply(console,arguments)))},verbose:function(){m.verbose&&m.debug&&(m.performance?g.performance.log(arguments):(g.verbose=Function.prototype.bind.call(console.info,console,m.name+":"),g.verbose.apply(console,arguments)))},error:function(){g.error=Function.prototype.bind.call(console.error,console,m.name+":"),g.error.apply(console,arguments)},performance:{log:function(e){var n,t,i;m.performance&&(n=(new Date).getTime(),i=r||n,t=n-i,r=n,s.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:y,"Execution Time":t})),clearTimeout(g.performance.timer),g.performance.timer=setTimeout(g.performance.display,500)},display:function(){var n=m.name+":",t=0;r=!1,clearTimeout(g.performance.timer),e.each(s,function(e,n){t+=n["Execution Time"]}),n+=" "+t+"ms",o&&(n+=" '"+o+"'"),a.length>1&&(n+=" ("+a.length+")"),(console.group!==i||console.table!==i)&&s.length>0&&(console.groupCollapsed(n),console.table?console.table(s):e.each(s,function(e,n){console.log(n.Name+": "+n["Execution Time"]+"ms")}),console.groupEnd()),s=[]}},invoke:function(n,a,o){var r,s,l,c=x;return a=a||u,o=y||o,"string"==typeof n&&c!==i&&(n=n.split(/[\. ]/),r=n.length-1,e.each(n,function(t,a){var o=t!=r?a+n[t+1].charAt(0).toUpperCase()+n[t+1].slice(1):n;if(e.isPlainObject(c[o])&&t!=r)c=c[o];else{if(c[o]!==i)return s=c[o],!1;if(!e.isPlainObject(c[a])||t==r)return c[a]!==i?(s=c[a],!1):!1;c=c[a]}})),e.isFunction(s)?l=s.apply(o,a):s!==i&&(l=s),e.isArray(t)?t.push(l):t!==i?t=[t,l]:l!==i&&(t=l),s}},c?(x===i&&g.initialize(),g.invoke(l)):(x!==i&&x.invoke("destroy"),g.initialize())}),t!==i?t:this},e.fn.rating.settings={name:"Rating",namespace:"rating",debug:!1,verbose:!1,performance:!0,initialRating:0,interactive:!0,maxRating:4,clearable:"auto",onRate:function(e){},error:{method:"The method you called is not defined",noMaximum:"No maximum rating specified. Cannot generate HTML automatically"},metadata:{rating:"rating",maxRating:"maxRating"},className:{active:"active",disabled:"disabled",selected:"selected",loading:"loading"},selector:{icon:".icon"},templates:{icon:function(e){for(var n=1,t="";e>=n;)t+='',n++;return t}}}}(jQuery,window,document);
--------------------------------------------------------------------------------
/routes/root.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/9/17.
3 | */
4 | var fileController = require('../app_modules/files_mgmt/fileController.js');
5 | var userController = require('../app_modules/users_mgmt/userController.js');
6 | var itemController = require('../app_modules/items_mgmt/itemController.js');
7 | var message = require('../app_modules/_utils/messageGenerator.js');
8 | var config = require('../config.json');
9 | module.exports = function(app){
10 | app.get('/board',function(req,res){
11 | if (req.session.userData) {
12 | if(req.query.id){
13 | res.render('canvas', {
14 | userName: req.session.userData.name,
15 | userId: req.session.userData.id,
16 | title:'MultiDraw'
17 | });
18 | }
19 | else{
20 | res.redirect('/center');
21 | }
22 | }else{
23 | res.redirect(config.loginUrl[config.runMode]);
24 | }
25 | });
26 |
27 | app.get('/new',function(req,res){
28 | if (req.session.userData) {
29 | res.render('index', {title: 'MultiDraw'});
30 | }else{
31 | res.redirect(config.loginUrl[config.runMode]);
32 | }
33 | });
34 |
35 | app.get('/', function (req,res) {
36 | res.redirect('/center');
37 | });
38 |
39 | app.get('/login',function(req,res){
40 | res.render('login',{title:'MultiDraw'});
41 | });
42 |
43 | app.get('/join',function(req,res){
44 | res.render('join',{title:'MultiDraw'});
45 | });
46 |
47 | app.get('/center', function (req,res) {
48 | console.log('center session',req.session.userData);
49 | if (req.session.userData) {
50 | res.render('center', {
51 | userName: req.session.userData.name,
52 | userId: req.session.userData.id,
53 | title:'MultiDraw'
54 | });
55 | }else{
56 | res.redirect(config.loginUrl[config.runMode]);
57 | }
58 | });
59 |
60 | app.post('/loginHandle',function(req,res){
61 | userController.isExist(req,res);
62 | });
63 |
64 | app.post('/signUpHandle',function(req,res){
65 | userController.addUser(req,res);
66 | });
67 |
68 | app.post('/userNameExist',function(req,res){
69 | userController.isUserNameExist(req,res);
70 | });
71 |
72 | app.get('/logout', function (req, res) {
73 | delete req.session.userData;
74 | res.redirect('/');
75 | });
76 |
77 | app.post('/saveFile',function(req,res){
78 | fileController.saveFile(req,res);
79 | });
80 |
81 | app.get('/loadAllFiles',function(req,res){
82 | fileController.loadAllFiles(req,res);
83 | });
84 |
85 | app.get('/loadUninvitedUsers',function(req,res){
86 | userController.loadUnParticipantUsers(req,res);
87 | });
88 | app.post('/addParticipants',function(req,res){
89 | userController.addParticipants(req,res);
90 | });
91 | app.get('/getParticipants',function(req,res){
92 | userController.getParticipants(req,res);
93 | });
94 | app.get('/removeParticipants',function(req,res){
95 | userController.removeParticipants(req,res);
96 | });
97 | app.post('/updateParticipants',function(req,res){
98 | userController.updateParticipants(req,res);
99 | });
100 | app.get('/recycleFiles', function (req,res) {
101 | fileController.recycleFiles(req,res);
102 | });
103 |
104 | app.get('/restoreFiles', function (req,res) {
105 | fileController.restoreFiles(req,res);
106 | });
107 |
108 | app.get('/deleteFiles', function (req,res) {
109 | fileController.deleteFiles(req,res);
110 | });
111 |
112 | app.get('/loadFile',function(req,res){
113 | fileController.loadFile(req,res);
114 | });
115 |
116 | app.post('/saveItem', function (req,res) {
117 | itemController.saveItem(req,res);
118 | });
119 |
120 | app.post('/updateItems', function (req,res) {
121 | itemController.updateItem(req,res);
122 | });
123 |
124 | app.post('/deleteItems', function (req,res) {
125 | itemController.deleteItem(req,res);
126 | });
127 |
128 | app.get('/renameFile',function(req,res){
129 | fileController.renameFile(req,res);
130 | });
131 |
132 |
133 |
134 | // catch 404 and forward to error handler
135 | app.use(function(req, res, next) {
136 | var err = new Error('Not Found');
137 | err.status = 404;
138 | next(err);
139 | });
140 |
141 | // error handlers
142 | // development error handler
143 | // will print stacktrace
144 | if (app.get('env') === 'development') {
145 | app.use(function(err, req, res, next) {
146 | res.status(err.status || 500);
147 | res.render('error', {
148 | message: err.message,
149 | error: err
150 | });
151 | });
152 | }
153 |
154 | // production error handler
155 | // no stacktraces leaked to user
156 | app.use(function(err, req, res, next) {
157 | res.status(err.status || 500);
158 | res.render('error', {
159 | message: err.message,
160 | error: {}
161 | });
162 | });
163 | return app;
164 | };
--------------------------------------------------------------------------------
/public/css/semantic/components/ad.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Ad
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2013 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Advertisement
15 | *******************************/
16 |
17 | .ui.ad {
18 | display: block;
19 | overflow: hidden;
20 | margin: 1em 0em;
21 | }
22 | .ui.ad:first-child {
23 | margin: 0em;
24 | }
25 | .ui.ad:last-child {
26 | margin: 0em;
27 | }
28 | .ui.ad iframe {
29 | margin: 0em;
30 | padding: 0em;
31 | border: none;
32 | overflow: hidden;
33 | }
34 |
35 | /*--------------
36 | Common
37 | ---------------*/
38 |
39 |
40 | /* Leaderboard */
41 | .ui.leaderboard.ad {
42 | width: 728px;
43 | height: 90px;
44 | }
45 |
46 | /* Medium Rectangle */
47 | .ui[class*="medium rectangle"].ad {
48 | width: 300px;
49 | height: 250px;
50 | }
51 |
52 | /* Large Rectangle */
53 | .ui[class*="large rectangle"].ad {
54 | width: 336px;
55 | height: 280px;
56 | }
57 |
58 | /* Half Page */
59 | .ui[class*="half page"].ad {
60 | width: 300px;
61 | height: 600px;
62 | }
63 |
64 | /*--------------
65 | Square
66 | ---------------*/
67 |
68 |
69 | /* Square */
70 | .ui.square.ad {
71 | width: 250px;
72 | height: 250px;
73 | }
74 |
75 | /* Small Square */
76 | .ui[class*="small square"].ad {
77 | width: 200px;
78 | height: 200px;
79 | }
80 |
81 | /*--------------
82 | Rectangle
83 | ---------------*/
84 |
85 |
86 | /* Small Rectangle */
87 | .ui[class*="small rectangle"].ad {
88 | width: 180px;
89 | height: 150px;
90 | }
91 |
92 | /* Vertical Rectangle */
93 | .ui[class*="vertical rectangle"].ad {
94 | width: 240px;
95 | height: 400px;
96 | }
97 |
98 | /*--------------
99 | Button
100 | ---------------*/
101 |
102 | .ui.button.ad {
103 | width: 120px;
104 | height: 90px;
105 | }
106 | .ui[class*="square button"].ad {
107 | width: 125px;
108 | height: 125px;
109 | }
110 | .ui[class*="small button"].ad {
111 | width: 120px;
112 | height: 60px;
113 | }
114 |
115 | /*--------------
116 | Skyscrapers
117 | ---------------*/
118 |
119 |
120 | /* Skyscraper */
121 | .ui.skyscraper.ad {
122 | width: 120px;
123 | height: 600px;
124 | }
125 |
126 | /* Wide Skyscraper */
127 | .ui[class*="wide skyscraper"].ad {
128 | width: 160px;
129 | }
130 |
131 | /*--------------
132 | Banners
133 | ---------------*/
134 |
135 |
136 | /* Banner */
137 | .ui.banner.ad {
138 | width: 468px;
139 | height: 60px;
140 | }
141 |
142 | /* Vertical Banner */
143 | .ui[class*="vertical banner"].ad {
144 | width: 120px;
145 | height: 240px;
146 | }
147 |
148 | /* Top Banner */
149 | .ui[class*="top banner"].ad {
150 | width: 930px;
151 | height: 180px;
152 | }
153 |
154 | /* Half Banner */
155 | .ui[class*="half banner"].ad {
156 | width: 234px;
157 | height: 60px;
158 | }
159 |
160 | /*--------------
161 | Boards
162 | ---------------*/
163 |
164 |
165 | /* Leaderboard */
166 | .ui[class*="large leaderboard"].ad {
167 | width: 970px;
168 | height: 90px;
169 | }
170 |
171 | /* Billboard */
172 | .ui.billboard.ad {
173 | width: 970px;
174 | height: 250px;
175 | }
176 |
177 | /*--------------
178 | Panorama
179 | ---------------*/
180 |
181 |
182 | /* Panorama */
183 | .ui.panorama.ad {
184 | width: 980px;
185 | height: 120px;
186 | }
187 |
188 | /*--------------
189 | Netboard
190 | ---------------*/
191 |
192 |
193 | /* Netboard */
194 | .ui.netboard.ad {
195 | width: 580px;
196 | height: 400px;
197 | }
198 |
199 | /*--------------
200 | Mobile
201 | ---------------*/
202 |
203 |
204 | /* Large Mobile Banner */
205 | .ui[class*="large mobile banner"].ad {
206 | width: 320px;
207 | height: 100px;
208 | }
209 |
210 | /* Mobile Leaderboard */
211 | .ui[class*="mobile leaderboard"].ad {
212 | width: 320px;
213 | height: 50px;
214 | }
215 |
216 |
217 | /*******************************
218 | Types
219 | *******************************/
220 |
221 |
222 | /* Mobile Sizes */
223 | .ui.mobile.ad {
224 | display: none;
225 | }
226 | @media only screen and (max-width: 767px) {
227 | .ui.mobile.ad {
228 | display: block;
229 | }
230 | }
231 |
232 |
233 | /*******************************
234 | Variations
235 | *******************************/
236 |
237 | .ui.centered.ad {
238 | margin-left: auto;
239 | margin-right: auto;
240 | }
241 | .ui.test.ad {
242 | position: relative;
243 | background: #545454;
244 | }
245 | .ui.test.ad:after {
246 | position: absolute;
247 | top: 50%;
248 | left: 50%;
249 | width: 100%;
250 | text-align: center;
251 | -webkit-transform: translateX(-50%) translateY(-50%);
252 | -ms-transform: translateX(-50%) translateY(-50%);
253 | transform: translateX(-50%) translateY(-50%);
254 | content: 'Ad';
255 | color: #ffffff;
256 | font-size: 1em;
257 | font-weight: bold;
258 | }
259 | .ui.mobile.test.ad:after {
260 | font-size: 0.85714286em;
261 | }
262 | .ui.test.ad[data-text]:after {
263 | content: attr(data-text);
264 | }
265 |
266 |
267 | /*******************************
268 | Theme Overrides
269 | *******************************/
270 |
271 |
272 |
273 | /*******************************
274 | User Variable Overrides
275 | *******************************/
276 |
277 |
--------------------------------------------------------------------------------
/public/css/semantic/components/nag.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Nag
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 | !function(e,o,t,n){"use strict";e.fn.nag=function(t){var i,s=e(this),a=s.selector||"",r=(new Date).getTime(),c=[],l=arguments[0],g="string"==typeof l,u=[].slice.call(arguments,1);return s.each(function(){{var s,d=e.isPlainObject(t)?e.extend(!0,{},e.fn.nag.settings,t):e.extend({},e.fn.nag.settings),m=(d.className,d.selector),f=d.error,p=d.namespace,h="."+p,b=p+"-module",v=e(this),y=(v.find(m.close),e(d.context?d.context:"body")),k=this,S=v.data(b);o.requestAnimationFrame||o.mozRequestAnimationFrame||o.webkitRequestAnimationFrame||o.msRequestAnimationFrame||function(e){setTimeout(e,0)}}s={initialize:function(){s.verbose("Initializing element"),v.on("click"+h,m.close,s.dismiss).data(b,s),d.detachable&&v.parent()[0]!==y[0]&&v.detach().prependTo(y),d.displayTime>0&&setTimeout(s.hide,d.displayTime),s.show()},destroy:function(){s.verbose("Destroying instance"),v.removeData(b).off(h)},show:function(){s.should.show()&&!v.is(":visible")&&(s.debug("Showing nag",d.animation.show),"fade"==d.animation.show?v.fadeIn(d.duration,d.easing):v.slideDown(d.duration,d.easing))},hide:function(){s.debug("Showing nag",d.animation.hide),"fade"==d.animation.show?v.fadeIn(d.duration,d.easing):v.slideUp(d.duration,d.easing)},onHide:function(){s.debug("Removing nag",d.animation.hide),v.remove(),d.onHide&&d.onHide()},dismiss:function(e){d.storageMethod&&s.storage.set(d.key,d.value),s.hide(),e.stopImmediatePropagation(),e.preventDefault()},should:{show:function(){return d.persist?(s.debug("Persistent nag is set, can show nag"),!0):s.storage.get(d.key)!=d.value.toString()?(s.debug("Stored value is not set, can show nag",s.storage.get(d.key)),!0):(s.debug("Stored value is set, cannot show nag",s.storage.get(d.key)),!1)}},get:{storageOptions:function(){var e={};return d.expires&&(e.expires=d.expires),d.domain&&(e.domain=d.domain),d.path&&(e.path=d.path),e}},clear:function(){s.storage.remove(d.key)},storage:{set:function(t,i){var a=s.get.storageOptions();if("localstorage"==d.storageMethod&&o.localStorage!==n)o.localStorage.setItem(t,i),s.debug("Value stored using local storage",t,i);else if("sessionstorage"==d.storageMethod&&o.sessionStorage!==n)o.sessionStorage.setItem(t,i),s.debug("Value stored using session storage",t,i);else{if(e.cookie===n)return void s.error(f.noCookieStorage);e.cookie(t,i,a),s.debug("Value stored using cookie",t,i,a)}},get:function(t,i){var a;return"localstorage"==d.storageMethod&&o.localStorage!==n?a=o.localStorage.getItem(t):"sessionstorage"==d.storageMethod&&o.sessionStorage!==n?a=o.sessionStorage.getItem(t):e.cookie!==n?a=e.cookie(t):s.error(f.noCookieStorage),("undefined"==a||"null"==a||a===n||null===a)&&(a=n),a},remove:function(t){var i=s.get.storageOptions();"localstorage"==d.storageMethod&&o.localStorage!==n?o.localStorage.removeItem(t):"sessionstorage"==d.storageMethod&&o.sessionStorage!==n?o.sessionStorage.removeItem(t):e.cookie!==n?e.removeCookie(t,i):s.error(f.noStorage)}},setting:function(o,t){if(s.debug("Changing setting",o,t),e.isPlainObject(o))e.extend(!0,d,o);else{if(t===n)return d[o];d[o]=t}},internal:function(o,t){if(e.isPlainObject(o))e.extend(!0,s,o);else{if(t===n)return s[o];s[o]=t}},debug:function(){d.debug&&(d.performance?s.performance.log(arguments):(s.debug=Function.prototype.bind.call(console.info,console,d.name+":"),s.debug.apply(console,arguments)))},verbose:function(){d.verbose&&d.debug&&(d.performance?s.performance.log(arguments):(s.verbose=Function.prototype.bind.call(console.info,console,d.name+":"),s.verbose.apply(console,arguments)))},error:function(){s.error=Function.prototype.bind.call(console.error,console,d.name+":"),s.error.apply(console,arguments)},performance:{log:function(e){var o,t,n;d.performance&&(o=(new Date).getTime(),n=r||o,t=o-n,r=o,c.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:k,"Execution Time":t})),clearTimeout(s.performance.timer),s.performance.timer=setTimeout(s.performance.display,500)},display:function(){var o=d.name+":",t=0;r=!1,clearTimeout(s.performance.timer),e.each(c,function(e,o){t+=o["Execution Time"]}),o+=" "+t+"ms",a&&(o+=" '"+a+"'"),(console.group!==n||console.table!==n)&&c.length>0&&(console.groupCollapsed(o),console.table?console.table(c):e.each(c,function(e,o){console.log(o.Name+": "+o["Execution Time"]+"ms")}),console.groupEnd()),c=[]}},invoke:function(o,t,a){var r,c,l,g=S;return t=t||u,a=k||a,"string"==typeof o&&g!==n&&(o=o.split(/[\. ]/),r=o.length-1,e.each(o,function(t,i){var a=t!=r?i+o[t+1].charAt(0).toUpperCase()+o[t+1].slice(1):o;if(e.isPlainObject(g[a])&&t!=r)g=g[a];else{if(g[a]!==n)return c=g[a],!1;if(!e.isPlainObject(g[i])||t==r)return g[i]!==n?(c=g[i],!1):(s.error(f.method,o),!1);g=g[i]}})),e.isFunction(c)?l=c.apply(a,t):c!==n&&(l=c),e.isArray(i)?i.push(l):i!==n?i=[i,l]:l!==n&&(i=l),c}},g?(S===n&&s.initialize(),s.invoke(l)):(S!==n&&S.invoke("destroy"),s.initialize())}),i!==n?i:this},e.fn.nag.settings={name:"Nag",debug:!1,verbose:!1,performance:!0,namespace:"Nag",persist:!1,displayTime:0,animation:{show:"slide",hide:"slide"},context:!1,detachable:!1,expires:30,domain:!1,path:"/",storageMethod:"cookie",key:"nag",value:"dismiss",error:{noCookieStorage:"$.cookie is not included. A storage solution is required.",noStorage:"Neither $.cookie or store is defined. A storage solution is required for storing state",method:"The method you called is not defined."},className:{bottom:"bottom",fixed:"fixed"},selector:{close:".close.icon"},speed:500,easing:"easeOutQuad",onHide:function(){}}}(jQuery,window,document);
--------------------------------------------------------------------------------
/public/css/semantic/components/item.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Item
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.items>.item{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin:1em 0;width:100%;min-height:0;background:0 0;padding:0;border:none;border-radius:0;box-shadow:none;-webkit-transition:box-shadow .1s ease;transition:box-shadow .1s ease;z-index:''}.ui.items>.item a{cursor:pointer}.ui.items{margin:1.5em 0}.ui.items:first-child{margin-top:0!important}.ui.items:last-child{margin-bottom:0!important}.ui.items>.item:after{display:block;content:' ';height:0;clear:both;overflow:hidden;visibility:hidden}.ui.items>.item:first-child{margin-top:0}.ui.items>.item:last-child{margin-bottom:0}.ui.items>.item>.image{position:relative;-webkit-box-flex:0;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;display:block;float:none;margin:0;padding:0;max-height:'';-webkit-align-self:top;-ms-flex-item-align:top;align-self:top}.ui.items>.item>.image>img{display:block;width:100%;height:auto;border-radius:.125rem;border:none}.ui.items>.item>.image:only-child>img{border-radius:0}.ui.items>.item>.content{display:block;-webkit-box-flex:1;-webkit-flex:1 1 auto;-ms-flex:1 1 auto;flex:1 1 auto;background:0 0;margin:0;padding:0;box-shadow:none;font-size:1em;border:none;border-radius:0}.ui.items>.item>.content:after{display:block;content:' ';height:0;clear:both;overflow:hidden;visibility:hidden}.ui.items>.item>.image+.content{min-width:0;width:auto;display:block;margin-left:0;-webkit-align-self:top;-ms-flex-item-align:top;align-self:top;padding-left:1.5em}.ui.items>.item>.content>.header{display:inline-block;margin:-.21425em 0 0;font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;font-weight:700;color:rgba(0,0,0,.85)}.ui.items>.item>.content>.header:not(.ui){font-size:1.28571429em}.ui.items>.item [class*="left floated"]{float:left}.ui.items>.item [class*="right floated"]{float:right}.ui.items>.item .content img{-webkit-align-self:middle;-ms-flex-item-align:middle;align-self:middle;width:''}.ui.items>.item .avatar img,.ui.items>.item img.avatar{width:'';height:'';border-radius:500rem}.ui.items>.item>.content>.description{margin-top:.6em;max-width:auto;font-size:1em;line-height:1.4285em;color:rgba(0,0,0,.87)}.ui.items>.item>.content p{margin:0 0 .5em}.ui.items>.item>.content p:last-child{margin-bottom:0}.ui.items>.item .meta{margin:.5em 0;font-size:1em;line-height:1em;color:rgba(0,0,0,.6)}.ui.items>.item .meta *{margin-right:.3em}.ui.items>.item .meta :last-child{margin-right:0}.ui.items>.item .meta [class*="right floated"]{margin-right:0;margin-left:.3em}.ui.items>.item>.content a:not(.ui){color:'';-webkit-transition:color .1s ease;transition:color .1s ease}.ui.items>.item>.content a:not(.ui):hover{color:''}.ui.items>.item>.content>a.header{color:rgba(0,0,0,.85)}.ui.items>.item>.content>a.header:hover{color:#1e70bf}.ui.items>.item .meta>a:not(.ui){color:rgba(0,0,0,.4)}.ui.items>.item .meta>a:not(.ui):hover{color:rgba(0,0,0,.87)}.ui.items>.item>.content .favorite.icon{cursor:pointer;opacity:.75;-webkit-transition:color .1s ease;transition:color .1s ease}.ui.items>.item>.content .favorite.icon:hover{opacity:1;color:#ffb70a}.ui.items>.item>.content .active.favorite.icon{color:#ffe623}.ui.items>.item>.content .like.icon{cursor:pointer;opacity:.75;-webkit-transition:color .1s ease;transition:color .1s ease}.ui.items>.item>.content .like.icon:hover{opacity:1;color:#ff2733}.ui.items>.item>.content .active.like.icon{color:#ff2733}.ui.items>.item .extra{display:block;position:relative;background:0 0;margin:.5rem 0 0;width:100%;padding:0;top:0;left:0;color:rgba(0,0,0,.4);box-shadow:none;-webkit-transition:color .1s ease;transition:color .1s ease;border-top:none}.ui.items>.item .extra>*{margin:.25rem .5rem .25rem 0}.ui.items>.item .extra>[class*="right floated"]{margin:.25rem 0 .25rem .5rem}.ui.items>.item .extra:after{display:block;content:' ';height:0;clear:both;overflow:hidden;visibility:hidden}.ui.items>.item>.image:not(.ui){width:175px}@media only screen and (min-width:768px) and (max-width:991px){.ui.items>.item{margin:1em 0}.ui.items>.item>.image:not(.ui){width:150px}.ui.items>.item>.image+.content{display:block;padding:0 0 0 1em}}@media only screen and (max-width:767px){.ui.items>.item{-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;margin:2em 0}.ui.items>.item>.image{display:block;margin-left:auto;margin-right:auto}.ui.items>.item>.image,.ui.items>.item>.image>img{max-width:100%!important;width:auto!important;max-height:250px!important}.ui.items>.item>.image+.content{display:block;padding:1.5em 0 0}}.ui.items>.item>.image+[class*="top aligned"].content{-webkit-align-self:flex-start;-ms-flex-item-align:start;align-self:flex-start}.ui.items>.item>.image+[class*="middle aligned"].content{-webkit-align-self:center;-ms-flex-item-align:center;align-self:center}.ui.items>.item>.image+[class*="bottom aligned"].content{-webkit-align-self:flex-end;-ms-flex-item-align:end;align-self:flex-end}.ui.relaxed.items>.item{margin:1.5em 0}.ui[class*="very relaxed"].items>.item{margin:2em 0}.ui.divided.items>.item{border-top:1px solid rgba(34,36,38,.15);margin:0;padding:1em 0}.ui.divided.items>.item:first-child{border-top:none;margin-top:0!important;padding-top:0!important}.ui.divided.items>.item:last-child{margin-bottom:0!important;padding-bottom:0!important}.ui.relaxed.divided.items>.item{margin:0;padding:1.5em 0}.ui[class*="very relaxed"].divided.items>.item{margin:0;padding:2em 0}.ui.items a.item:hover,.ui.link.items>.item:hover{cursor:pointer}.ui.items a.item:hover .content .header,.ui.link.items>.item:hover .content .header{color:#1e70bf}.ui.items>.item{font-size:1em}
--------------------------------------------------------------------------------
/public/css/semantic/components/visit.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.0.0 - Visit
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 | !function(e,t,i,n){"use strict";e.visit=e.fn.visit=function(i){var o,r=e(e.isFunction(this)?t:this),s=r.selector||"",a=(new Date).getTime(),c=[],u=arguments[0],l="string"==typeof u,d=[].slice.call(arguments,1);return r.each(function(){var g,m=e.isPlainObject(i)?e.extend(!0,{},e.fn.visit.settings,i):e.extend({},e.fn.visit.settings),f=m.error,p=m.namespace,v=p+"-module",h=e(this),b=e(),y=this,k=h.data(v);g={initialize:function(){m.count?g.store(m.key.count,m.count):m.id?g.add.id(m.id):m.increment&&"increment"!==l&&g.increment(),g.add.display(h),g.instantiate()},instantiate:function(){g.verbose("Storing instance of visit module",g),k=g,h.data(v,g)},destroy:function(){g.verbose("Destroying instance"),h.removeData(v)},increment:function(e){var t=g.get.count(),i=+t+1;e?g.add.id(e):(i>m.limit&&!m.surpass&&(i=m.limit),g.debug("Incrementing visits",i),g.store(m.key.count,i))},decrement:function(e){var t=g.get.count(),i=+t-1;e?g.remove.id(e):(g.debug("Removing visit"),g.store(m.key.count,i))},get:{count:function(){return+g.retrieve(m.key.count)||0},idCount:function(e){return e=e||g.get.ids(),e.length},ids:function(e){var t=[];return e=e||g.retrieve(m.key.ids),"string"==typeof e&&(t=e.split(m.delimiter)),g.verbose("Found visited ID list",t),t},storageOptions:function(e){var t={};return m.expires&&(t.expires=m.expires),m.domain&&(t.domain=m.domain),m.path&&(t.path=m.path),t}},has:{visited:function(t,i){var o=!1;return i=i||g.get.ids(),t!==n&&i&&e.each(i,function(e,i){i==t&&(o=!0)}),o}},set:{count:function(e){g.store(m.key.count,e)},ids:function(e){g.store(m.key.ids,e)}},reset:function(){g.store(m.key.count,0),g.store(m.key.ids,null)},add:{id:function(e){var t=g.retrieve(m.key.ids),i=t===n||""===t?e:t+m.delimiter+e;g.has.visited(e)?g.debug("Unique content already visited, not adding visit",e,t):e===n?g.debug("ID is not defined"):(g.debug("Adding visit to unique content",e),g.store(m.key.ids,i)),g.set.count(g.get.idCount())},display:function(t){var i=e(t);i.length>0&&!e.isWindow(i[0])&&(g.debug("Updating visit count for element",i),b=b.length>0?b.add(i):i)}},remove:{id:function(t){var i=g.get.ids(),o=[];t!==n&&i!==n&&(g.debug("Removing visit to unique content",t,i),e.each(i,function(e,i){i!==t&&o.push(i)}),o=o.join(m.delimiter),g.store(m.key.ids,o)),g.set.count(g.get.idCount())}},check:{limit:function(e){e=e||g.get.count(),m.limit&&(e>=m.limit&&(g.debug("Pages viewed exceeded limit, firing callback",e,m.limit),m.onLimit.call(y,e)),g.debug("Limit not reached",e,m.limit),m.onChange.call(y,e)),g.update.display(e)}},update:{display:function(e){e=e||g.get.count(),b.length>0&&(g.debug("Updating displayed view count",b),b.html(e))}},store:function(i,o){var r=g.get.storageOptions(o);if("localstorage"==m.storageMethod&&t.localStorage!==n)t.localStorage.setItem(i,o),g.debug("Value stored using local storage",i,o);else{if(e.cookie===n)return void g.error(f.noCookieStorage);e.cookie(i,o,r),g.debug("Value stored using cookie",i,o,r)}i==m.key.count&&g.check.limit(o)},retrieve:function(i,o){var r;return"localstorage"==m.storageMethod&&t.localStorage!==n?r=t.localStorage.getItem(i):e.cookie!==n?r=e.cookie(i):g.error(f.noCookieStorage),("undefined"==r||"null"==r||r===n||null===r)&&(r=n),r},setting:function(t,i){if(e.isPlainObject(t))e.extend(!0,m,t);else{if(i===n)return m[t];m[t]=i}},internal:function(t,i){return g.debug("Changing internal",t,i),i===n?g[t]:void(e.isPlainObject(t)?e.extend(!0,g,t):g[t]=i)},debug:function(){m.debug&&(m.performance?g.performance.log(arguments):(g.debug=Function.prototype.bind.call(console.info,console,m.name+":"),g.debug.apply(console,arguments)))},verbose:function(){m.verbose&&m.debug&&(m.performance?g.performance.log(arguments):(g.verbose=Function.prototype.bind.call(console.info,console,m.name+":"),g.verbose.apply(console,arguments)))},error:function(){g.error=Function.prototype.bind.call(console.error,console,m.name+":"),g.error.apply(console,arguments)},performance:{log:function(e){var t,i,n;m.performance&&(t=(new Date).getTime(),n=a||t,i=t-n,a=t,c.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:y,"Execution Time":i})),clearTimeout(g.performance.timer),g.performance.timer=setTimeout(g.performance.display,500)},display:function(){var t=m.name+":",i=0;a=!1,clearTimeout(g.performance.timer),e.each(c,function(e,t){i+=t["Execution Time"]}),t+=" "+i+"ms",s&&(t+=" '"+s+"'"),r.length>1&&(t+=" ("+r.length+")"),(console.group!==n||console.table!==n)&&c.length>0&&(console.groupCollapsed(t),console.table?console.table(c):e.each(c,function(e,t){console.log(t.Name+": "+t["Execution Time"]+"ms")}),console.groupEnd()),c=[]}},invoke:function(t,i,r){var s,a,c,u=k;return i=i||d,r=y||r,"string"==typeof t&&u!==n&&(t=t.split(/[\. ]/),s=t.length-1,e.each(t,function(i,o){var r=i!=s?o+t[i+1].charAt(0).toUpperCase()+t[i+1].slice(1):t;if(e.isPlainObject(u[r])&&i!=s)u=u[r];else{if(u[r]!==n)return a=u[r],!1;if(!e.isPlainObject(u[o])||i==s)return u[o]!==n?(a=u[o],!1):!1;u=u[o]}})),e.isFunction(a)?c=a.apply(r,i):a!==n&&(c=a),e.isArray(o)?o.push(c):o!==n?o=[o,c]:c!==n&&(o=c),a}},l?(k===n&&g.initialize(),g.invoke(u)):(k!==n&&k.invoke("destroy"),g.initialize())}),o!==n?o:this},e.fn.visit.settings={name:"Visit",debug:!1,verbose:!1,performance:!0,namespace:"visit",increment:!1,surpass:!1,count:!1,limit:!1,delimiter:"&",storageMethod:"localstorage",key:{count:"visit-count",ids:"visit-ids"},expires:30,domain:!1,path:"/",onLimit:function(){},onChange:function(){},error:{method:"The method you called is not defined",missingPersist:"Using the persist setting requires the inclusion of PersistJS",noCookieStorage:"The default storage cookie requires $.cookie to be included."}}}(jQuery,window,document);
--------------------------------------------------------------------------------
/public/css/semantic/components/message.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Message
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.message{position:relative;min-height:1em;margin:1em 0;background:#f8f8f9;padding:1em 1.5em;line-height:1.4285em;color:rgba(0,0,0,.87);-webkit-transition:opacity .1s ease,color .1s ease,background .1s ease,box-shadow .1s ease;transition:opacity .1s ease,color .1s ease,background .1s ease,box-shadow .1s ease;border-radius:.28571429rem;box-shadow:0 0 0 1px rgba(34,36,38,.22) inset,0 0 0 0 transparent}.ui.message:first-child{margin-top:0}.ui.message:last-child{margin-bottom:0}.ui.message .header{display:block;font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;font-weight:700;margin:-.14285em 0 0}.ui.message .header:not(.ui){font-size:1.14285714em}.ui.message p{opacity:.85;margin:.75em 0}.ui.message p:first-child{margin-top:0}.ui.message p:last-child{margin-bottom:0}.ui.message .header+p{margin-top:.25em}.ui.message .list:not(.ui){text-align:left;padding:0;opacity:.85;list-style-position:inside;margin:.5em 0 0}.ui.message .list:not(.ui):first-child{margin-top:0}.ui.message .list:not(.ui):last-child{margin-bottom:0}.ui.message .list:not(.ui) li{position:relative;list-style-type:none;margin:0 0 .3em 1em;padding:0}.ui.message .list:not(.ui) li:before{position:absolute;content:'•';left:-1em;height:100%;vertical-align:baseline}.ui.message .list:not(.ui) li:last-child{margin-bottom:0}.ui.message>.icon{margin-right:.6em}.ui.message>.close.icon{cursor:pointer;position:absolute;margin:0;top:.78575em;right:.5em;opacity:.7;-webkit-transition:opacity .1s ease;transition:opacity .1s ease}.ui.message>.close.icon:hover{opacity:1}.ui.message>:first-child{margin-top:0}.ui.message>:last-child{margin-bottom:0}.ui.dropdown .menu>.message{margin:0 -1px}.ui.visible.visible.visible.visible.message{display:block}.ui.icon.visible.visible.visible.visible.message{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex}.ui.hidden.hidden.hidden.hidden.message{display:none}.ui.compact.message{display:inline-block}.ui.attached.message{margin-bottom:-1px;border-radius:.28571429rem .28571429rem 0 0;box-shadow:0 0 0 1px rgba(34,36,38,.15) inset;margin-left:-1px;margin-right:-1px}.ui.attached+.ui.attached.message:not(.top):not(.bottom){margin-top:-1px;border-radius:0}.ui.bottom.attached.message{margin-top:-1px;border-radius:0 0 .28571429rem .28571429rem;box-shadow:0 0 0 1px rgba(34,36,38,.15) inset,0 1px 2px 0 rgba(34,36,38,.15)}.ui.bottom.attached.message:not(:last-child){margin-bottom:1em}.ui.attached.icon.message{width:auto}.ui.icon.message{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;width:100%;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}.ui.icon.message>.icon:not(.close){display:block;-webkit-box-flex:0;-webkit-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto;width:auto;line-height:1;vertical-align:middle;font-size:3em;opacity:.8}.ui.icon.message>.content{display:block;-webkit-box-flex:1;-webkit-flex:1 1 auto;-ms-flex:1 1 auto;flex:1 1 auto;vertical-align:middle}.ui.icon.message .icon:not(.close)+.content{padding-left:0}.ui.icon.message .circular.icon{width:1em}.ui.floating.message{box-shadow:0 0 0 1px rgba(34,36,38,.22) inset,0 2px 4px 0 rgba(34,36,38,.12),0 2px 10px 0 rgba(34,36,38,.08)}.ui.positive.message{background-color:#fcfff5;color:#2c662d}.ui.attached.positive.message,.ui.positive.message{box-shadow:0 0 0 1px #a3c293 inset,0 0 0 0 transparent}.ui.positive.message .header{color:#1a531b}.ui.negative.message{background-color:#fff6f6;color:#9f3a38}.ui.attached.negative.message,.ui.negative.message{box-shadow:0 0 0 1px #e0b4b4 inset,0 0 0 0 transparent}.ui.negative.message .header{color:#912d2b}.ui.info.message{background-color:#f8ffff;color:#276f86}.ui.attached.info.message,.ui.info.message{box-shadow:0 0 0 1px #a9d5de inset,0 0 0 0 transparent}.ui.info.message .header{color:#0e566c}.ui.warning.message{background-color:#fffaf3;color:#573a08}.ui.attached.warning.message,.ui.warning.message{box-shadow:0 0 0 1px #c9ba9b inset,0 0 0 0 transparent}.ui.warning.message .header{color:#794b02}.ui.error.message{background-color:#fff6f6;color:#9f3a38}.ui.attached.error.message,.ui.error.message{box-shadow:0 0 0 1px #e0b4b4 inset,0 0 0 0 transparent}.ui.error.message .header{color:#912d2b}.ui.success.message{background-color:#fcfff5;color:#2c662d}.ui.attached.success.message,.ui.success.message{box-shadow:0 0 0 1px #a3c293 inset,0 0 0 0 transparent}.ui.success.message .header{color:#1a531b}.ui.black.message,.ui.inverted.message{background-color:#1b1c1d;color:rgba(255,255,255,.9)}.ui.red.message{background-color:#ffe8e6;color:#db2828}.ui.red.message .header{color:#c82121}.ui.orange.message{background-color:#ffedde;color:#f2711c}.ui.orange.message .header{color:#e7640d}.ui.yellow.message{background-color:#fff8db;color:#b58105}.ui.yellow.message .header{color:#9c6f04}.ui.olive.message{background-color:#fbfdef;color:#8abc1e}.ui.olive.message .header{color:#7aa61a}.ui.green.message{background-color:#e5f9e7;color:#1ebc30}.ui.green.message .header{color:#1aa62a}.ui.teal.message{background-color:#e1f7f7;color:#10a3a3}.ui.teal.message .header{color:#0e8c8c}.ui.blue.message{background-color:#dff0ff;color:#2185d0}.ui.blue.message .header{color:#1e77ba}.ui.violet.message{background-color:#eae7ff;color:#6435c9}.ui.violet.message .header{color:#5a30b5}.ui.purple.message{background-color:#f6e7ff;color:#a333c8}.ui.purple.message .header{color:#922eb4}.ui.pink.message{background-color:#ffe3fb;color:#e03997}.ui.pink.message .header{color:#dd238b}.ui.brown.message{background-color:#f1e2d3;color:#a5673f}.ui.brown.message .header{color:#935b38}.ui.small.message{font-size:.92857143em}.ui.message{font-size:1em}.ui.large.message{font-size:1.14285714em}.ui.huge.message{font-size:1.42857143em}.ui.massive.message{font-size:1.71428571em}
--------------------------------------------------------------------------------
/public/css/semantic/components/search.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Search
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.search{position:relative}.ui.search>.prompt{margin:0;outline:0;-webkit-appearance:none;-webkit-tap-highlight-color:rgba(255,255,255,0);text-shadow:none;font-style:normal;font-weight:400;line-height:1.2142em;padding:.67861429em 1em;font-size:1em;background:#fff;border:1px solid rgba(34,36,38,.15);color:rgba(0,0,0,.87);box-shadow:0 0 0 0 transparent inset;-webkit-transition:background-color .1s ease,color .1s ease,box-shadow .1s ease,border-color .1s ease;transition:background-color .1s ease,color .1s ease,box-shadow .1s ease,border-color .1s ease}.ui.search .prompt{border-radius:500rem}.ui.search .prompt~.search.icon{cursor:pointer}.ui.search>.results{display:none;position:absolute;top:100%;left:0;-webkit-transform-origin:center top;-ms-transform-origin:center top;transform-origin:center top;background:#fff;margin-top:.5em;width:18em;border-radius:.28571429rem;box-shadow:0 2px 4px 0 rgba(34,36,38,.12),0 2px 10px 0 rgba(34,36,38,.08);border:1px solid #d4d4d5;z-index:998}.ui.search>.results>:first-child{border-radius:.28571429rem .28571429rem 0 0}.ui.search>.results>:last-child{border-radius:0 0 .28571429rem .28571429rem}.ui.search>.results .result{cursor:pointer;display:block;overflow:hidden;font-size:1em;padding:.85714286em 1.14285714em;color:rgba(0,0,0,.87);line-height:1.33;border-bottom:1px solid rgba(34,36,38,.1)}.ui.search>.results .result:last-child{border-bottom:none!important}.ui.search>.results .result .image{float:right;overflow:hidden;background:0 0;width:5em;height:3em;border-radius:.25em}.ui.search>.results .result .image img{display:block;width:auto;height:100%}.ui.search>.results .result .image+.content{margin:0 6em 0 0}.ui.search>.results .result .title{margin:-.14285em 0 0;font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;font-weight:700;font-size:1em;color:rgba(0,0,0,.85)}.ui.search>.results .result .description{margin-top:0;font-size:.92857143em;color:rgba(0,0,0,.4)}.ui.search>.results .result .price{float:right;color:#21ba45}.ui.search>.results>.message{padding:1em}.ui.search>.results>.message .header{font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;font-size:1rem;font-weight:700;color:rgba(0,0,0,.87)}.ui.search>.results>.message .description{margin-top:.25rem;font-size:1em;color:rgba(0,0,0,.87)}.ui.search>.results>.action{display:block;border-top:none;background:#f3f4f5;padding:.92857143em 1em;color:rgba(0,0,0,.87);font-weight:700;text-align:center}.ui.search>.prompt:focus{border-color:rgba(34,36,38,.35);background:#fff;color:rgba(0,0,0,.95)}.ui.loading.search .input>i.icon:before{position:absolute;content:'';top:50%;left:50%;margin:-.64285714em 0 0 -.64285714em;width:1.28571429em;height:1.28571429em;border-radius:500rem;border:.2em solid rgba(0,0,0,.1)}.ui.loading.search .input>i.icon:after{position:absolute;content:'';top:50%;left:50%;margin:-.64285714em 0 0 -.64285714em;width:1.28571429em;height:1.28571429em;-webkit-animation:button-spin .6s linear;animation:button-spin .6s linear;-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;border-radius:500rem;border-color:#767676 transparent transparent;border-style:solid;border-width:.2em;box-shadow:0 0 0 1px transparent}.ui.category.search>.results .category .result:hover,.ui.search>.results .result:hover{background:#f9fafb}.ui.search .action:hover{background:#e0e0e0}.ui.category.search>.results .category.active{background:#f3f4f5}.ui.category.search>.results .category.active>.name{color:rgba(0,0,0,.87)}.ui.category.search>.results .category .result.active,.ui.search>.results .result.active{position:relative;border-left-color:rgba(34,36,38,.1);background:#f3f4f5;box-shadow:none}.ui.search>.results .result.active .description,.ui.search>.results .result.active .title{color:rgba(0,0,0,.85)}.ui.search.selection .prompt{border-radius:.28571429rem}.ui.search.selection>.icon.input>.remove.icon{pointer-events:none;position:absolute;left:auto;opacity:0;color:'';top:0;right:0;-webkit-transition:color .1s ease,opacity .1s ease;transition:color .1s ease,opacity .1s ease}.ui.search.selection>.icon.input>.active.remove.icon{cursor:pointer;opacity:.8;pointer-events:auto}.ui.search.selection>.icon.input:not([class*="left icon"])>.icon~.remove.icon{right:1.85714em}.ui.search.selection>.icon.input>.remove.icon:hover{opacity:1;color:#db2828}.ui.category.search .results{width:28em}.ui.category.search>.results .category{background:#f3f4f5;box-shadow:none;border-bottom:1px solid rgba(34,36,38,.1);-webkit-transition:background .1s ease,border-color .1s ease;transition:background .1s ease,border-color .1s ease}.ui.category.search>.results .category:last-child{border-bottom:none}.ui.category.search>.results .category:first-child .name+.result{border-radius:0 .28571429rem 0 0}.ui.category.search>.results .category .result{background:#fff;margin-left:100px;border-left:1px solid rgba(34,36,38,.15);border-bottom:1px solid rgba(34,36,38,.1);-webkit-transition:background .1s ease,border-color .1s ease;transition:background .1s ease,border-color .1s ease;padding:.85714286em 1.14285714em}.ui.category.search>.results .category:last-child .result:last-child{border-radius:0 0 .28571429rem;border-bottom:none}.ui.category.search>.results .category>.name{width:100px;background:0 0;font-family:Lato,'Helvetica Neue',Arial,Helvetica,sans-serif;font-size:1em;float:1em;float:left;padding:.4em 1em;font-weight:700;color:rgba(0,0,0,.4)}.ui[class*="left aligned"].search>.results{right:auto;left:0}.ui[class*="right aligned"].search>.results{right:0;left:auto}.ui.fluid.search .results{width:100%}.ui.mini.search{font-size:.71428571em}.ui.small.search{font-size:.92857143em}.ui.search{font-size:1em}.ui.large.search{font-size:1.14285714em}.ui.big.search{font-size:1.28571429em}.ui.huge.search{font-size:1.42857143em}.ui.massive.search{font-size:1.71428571em}
--------------------------------------------------------------------------------
/public/css/semantic/components/video.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.0.0 - Video
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2014 Contributorss
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 | !function(e,o,t,n){"use strict";e.fn.video=function(t){{var a,i=e(this),r=i.selector||"",l=(new Date).getTime(),c=[],u=arguments[0],s="string"==typeof u,m=[].slice.call(arguments,1);o.requestAnimationFrame||o.mozRequestAnimationFrame||o.webkitRequestAnimationFrame||o.msRequestAnimationFrame||function(e){setTimeout(e,0)}}return i.each(function(){var d,p=e.isPlainObject(t)?e.extend(!0,{},e.fn.video.settings,t):e.extend({},e.fn.video.settings),f=p.selector,g=p.className,h=p.error,v=p.metadata,b=p.namespace,y=p.templates,w="."+b,x="module-"+b,F=(e(o),e(this)),C=F.find(f.placeholder),E=F.find(f.playButton),T=F.find(f.embed),A=this,P=F.data(x);d={initialize:function(){d.debug("Initializing video"),d.create(),F.on("click"+w,f.placeholder,d.play).on("click"+w,f.playButton,d.play),d.instantiate()},instantiate:function(){d.verbose("Storing instance of module",d),P=d,F.data(x,d)},create:function(){var e=F.data(v.image),o=y.video(e);F.html(o),d.refresh(),e||d.play(),d.debug("Creating html for video element",o)},destroy:function(){d.verbose("Destroying previous instance of video"),d.reset(),F.removeData(x).off(w)},refresh:function(){d.verbose("Refreshing selector cache"),C=F.find(f.placeholder),E=F.find(f.playButton),T=F.find(f.embed)},change:function(e,o,t){d.debug("Changing video to ",e,o,t),F.data(v.source,e).data(v.id,o).data(v.url,t),p.onChange()},reset:function(){d.debug("Clearing video embed and showing placeholder"),F.removeClass(g.active),T.html(" "),C.show(),p.onReset()},play:function(){d.debug("Playing video");var e=F.data(v.source)||!1,o=F.data(v.url)||!1,t=F.data(v.id)||!1;T.html(d.generate.html(e,t,o)),F.addClass(g.active),p.onPlay()},get:{source:function(e){return"string"!=typeof e?!1:-1!==e.search("youtube.com")?"youtube":-1!==e.search("vimeo.com")?"vimeo":!1},id:function(e){return e.match(p.regExp.youtube)?e.match(p.regExp.youtube)[1]:e.match(p.regExp.vimeo)?e.match(p.regExp.vimeo)[2]:!1}},generate:{html:function(e,o,t){d.debug("Generating embed html");var n;return e=e||p.source,o=o||p.id,e&&o||t?(e&&o||(e=d.get.source(t),o=d.get.id(t)),"vimeo"==e?n='':"youtube"==e&&(n='')):d.error(h.noVideo),n},url:function(e){var o=p.api?1:0,t="auto"===p.autoplay?F.data("image")!==n:p.autoplay,a=p.hd?1:0,i=p.showUI?1:0,r=p.showUI?0:1,l="";return"vimeo"==e&&(l="api="+o+"&title="+i+"&byline="+i+"&portrait="+i+"&autoplay="+t,p.color&&(l+="&color="+p.color)),"ustream"==e?(l="autoplay="+t,p.color&&(l+="&color="+p.color)):"youtube"==e&&(l="enablejsapi="+o+"&autoplay="+t+"&autohide="+r+"&hq="+a+"&modestbranding=1",p.color&&(l+="&color="+p.color)),l}},setting:function(o,t){if(d.debug("Changing setting",o,t),e.isPlainObject(o))e.extend(!0,p,o);else{if(t===n)return p[o];p[o]=t}},internal:function(o,t){if(e.isPlainObject(o))e.extend(!0,d,o);else{if(t===n)return d[o];d[o]=t}},debug:function(){p.debug&&(p.performance?d.performance.log(arguments):(d.debug=Function.prototype.bind.call(console.info,console,p.name+":"),d.debug.apply(console,arguments)))},verbose:function(){p.verbose&&p.debug&&(p.performance?d.performance.log(arguments):(d.verbose=Function.prototype.bind.call(console.info,console,p.name+":"),d.verbose.apply(console,arguments)))},error:function(){d.error=Function.prototype.bind.call(console.error,console,p.name+":"),d.error.apply(console,arguments)},performance:{log:function(e){var o,t,n;p.performance&&(o=(new Date).getTime(),n=l||o,t=o-n,l=o,c.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:A,"Execution Time":t})),clearTimeout(d.performance.timer),d.performance.timer=setTimeout(d.performance.display,500)},display:function(){var o=p.name+":",t=0;l=!1,clearTimeout(d.performance.timer),e.each(c,function(e,o){t+=o["Execution Time"]}),o+=" "+t+"ms",r&&(o+=" '"+r+"'"),i.length>1&&(o+=" ("+i.length+")"),(console.group!==n||console.table!==n)&&c.length>0&&(console.groupCollapsed(o),console.table?console.table(c):e.each(c,function(e,o){console.log(o.Name+": "+o["Execution Time"]+"ms")}),console.groupEnd()),c=[]}},invoke:function(o,t,i){var r,l,c,u=P;return t=t||m,i=A||i,"string"==typeof o&&u!==n&&(o=o.split(/[\. ]/),r=o.length-1,e.each(o,function(t,a){var i=t!=r?a+o[t+1].charAt(0).toUpperCase()+o[t+1].slice(1):o;if(e.isPlainObject(u[i])&&t!=r)u=u[i];else{if(u[i]!==n)return l=u[i],!1;if(!e.isPlainObject(u[a])||t==r)return u[a]!==n?(l=u[a],!1):(d.error(h.method,o),!1);u=u[a]}})),e.isFunction(l)?c=l.apply(i,t):l!==n&&(c=l),e.isArray(a)?a.push(c):a!==n?a=[a,c]:c!==n&&(a=c),l}},s?(P===n&&d.initialize(),d.invoke(u)):(P!==n&&P.invoke("destroy"),d.initialize())}),a!==n?a:this},e.fn.video.settings={name:"Video",namespace:"video",debug:!1,verbose:!1,performance:!0,metadata:{id:"id",image:"image",source:"source",url:"url"},source:!1,url:!1,id:!1,aspectRatio:16/9,onPlay:function(){},onReset:function(){},onChange:function(){},onPause:function(){},onStop:function(){},width:"auto",height:"auto",autoplay:"auto",color:"#442359",hd:!0,showUI:!1,api:!0,regExp:{youtube:/^(?:https?:\/\/)?(?:www\.)?(?:youtu\.be\/|youtube\.com\/(?:embed\/|v\/|watch\?v=|watch\?.+&v=))((\w|-){11})(?:\S+)?$/,vimeo:/http:\/\/(www\.)?vimeo.com\/(\d+)($|\/)/},error:{noVideo:"No video specified",method:"The method you called is not defined"},className:{active:"active"},selector:{embed:".embed",placeholder:".placeholder",playButton:".play"}},e.fn.video.settings.templates={video:function(e){var o="";return e&&(o+='
'),o+=''}}}(jQuery,window,document);
--------------------------------------------------------------------------------
/public/css/semantic/components/comment.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Comment
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */
11 |
12 |
13 | /*******************************
14 | Standard
15 | *******************************/
16 |
17 |
18 | /*--------------
19 | Comments
20 | ---------------*/
21 |
22 | .ui.comments {
23 | margin: 1.5em 0em;
24 | max-width: 650px;
25 | }
26 | .ui.comments:first-child {
27 | margin-top: 0em;
28 | }
29 | .ui.comments:last-child {
30 | margin-bottom: 0em;
31 | }
32 |
33 | /*--------------
34 | Comment
35 | ---------------*/
36 |
37 | .ui.comments .comment {
38 | position: relative;
39 | background: none;
40 | margin: 0.5em 0em 0em;
41 | padding: 0.5em 0em 0em;
42 | border: none;
43 | border-top: none;
44 | line-height: 1.2;
45 | }
46 | .ui.comments .comment:first-child {
47 | margin-top: 0em;
48 | padding-top: 0em;
49 | }
50 |
51 | /*--------------------
52 | Nested Comments
53 | ---------------------*/
54 |
55 | .ui.comments .comment .comments {
56 | margin: 0em 0em 0.5em 0.5em;
57 | padding: 1em 0em 1em 1em;
58 | }
59 | .ui.comments .comment .comments:before {
60 | position: absolute;
61 | top: 0px;
62 | left: 0px;
63 | }
64 | .ui.comments .comment .comments .comment {
65 | border: none;
66 | border-top: none;
67 | background: none;
68 | }
69 |
70 | /*--------------
71 | Avatar
72 | ---------------*/
73 |
74 | .ui.comments .comment .avatar {
75 | display: block;
76 | width: 2.5em;
77 | height: auto;
78 | float: left;
79 | margin: 0.2em 0em 0em;
80 | }
81 | .ui.comments .comment img.avatar,
82 | .ui.comments .comment .avatar img {
83 | display: block;
84 | margin: 0em auto;
85 | width: 100%;
86 | height: 100%;
87 | border-radius: 0.25rem;
88 | }
89 |
90 | /*--------------
91 | Content
92 | ---------------*/
93 |
94 | .ui.comments .comment > .content {
95 | display: block;
96 | }
97 |
98 | /* If there is an avatar move content over */
99 | .ui.comments .comment > .avatar ~ .content {
100 | margin-left: 3.5em;
101 | }
102 |
103 | /*--------------
104 | Author
105 | ---------------*/
106 |
107 | .ui.comments .comment .author {
108 | font-size: 1em;
109 | color: rgba(0, 0, 0, 0.87);
110 | font-weight: bold;
111 | }
112 | .ui.comments .comment a.author {
113 | cursor: pointer;
114 | }
115 | .ui.comments .comment a.author:hover {
116 | color: #1e70bf;
117 | }
118 |
119 | /*--------------
120 | Metadata
121 | ---------------*/
122 |
123 | .ui.comments .comment .metadata {
124 | display: inline-block;
125 | margin-left: 0.5em;
126 | color: rgba(0, 0, 0, 0.4);
127 | font-size: 0.875em;
128 | }
129 | .ui.comments .comment .metadata > * {
130 | display: inline-block;
131 | margin: 0em 0.5em 0em 0em;
132 | }
133 | .ui.comments .comment .metadata > :last-child {
134 | margin-right: 0em;
135 | }
136 |
137 | /*--------------------
138 | Comment Text
139 | ---------------------*/
140 |
141 | .ui.comments .comment .text {
142 | margin: 0.25em 0em 0.5em;
143 | font-size: 1em;
144 | word-wrap: break-word;
145 | color: rgba(0, 0, 0, 0.87);
146 | line-height: 1.3;
147 | }
148 |
149 | /*--------------------
150 | User Actions
151 | ---------------------*/
152 |
153 | .ui.comments .comment .actions {
154 | font-size: 0.875em;
155 | }
156 | .ui.comments .comment .actions a {
157 | cursor: pointer;
158 | display: inline-block;
159 | margin: 0em 0.75em 0em 0em;
160 | color: rgba(0, 0, 0, 0.4);
161 | }
162 | .ui.comments .comment .actions a:last-child {
163 | margin-right: 0em;
164 | }
165 | .ui.comments .comment .actions a.active,
166 | .ui.comments .comment .actions a:hover {
167 | color: rgba(0, 0, 0, 0.8);
168 | }
169 |
170 | /*--------------------
171 | Reply Form
172 | ---------------------*/
173 |
174 | .ui.comments > .reply.form {
175 | margin-top: 1em;
176 | }
177 | .ui.comments .comment .reply.form {
178 | width: 100%;
179 | margin-top: 1em;
180 | }
181 | .ui.comments .reply.form textarea {
182 | font-size: 1em;
183 | height: 12em;
184 | }
185 |
186 |
187 | /*******************************
188 | State
189 | *******************************/
190 |
191 | .ui.collapsed.comments,
192 | .ui.comments .collapsed.comments,
193 | .ui.comments .collapsed.comment {
194 | display: none;
195 | }
196 |
197 |
198 | /*******************************
199 | Variations
200 | *******************************/
201 |
202 |
203 | /*--------------------
204 | Threaded
205 | ---------------------*/
206 |
207 | .ui.threaded.comments .comment .comments {
208 | margin: -1.5em 0 -1em 1.25em;
209 | padding: 3em 0em 2em 2.25em;
210 | box-shadow: -1px 0px 0px rgba(34, 36, 38, 0.15);
211 | }
212 |
213 | /*--------------------
214 | Minimal
215 | ---------------------*/
216 |
217 | .ui.minimal.comments .comment .actions {
218 | opacity: 0;
219 | position: absolute;
220 | top: 0px;
221 | right: 0px;
222 | left: auto;
223 | -webkit-transition: opacity 0.2s ease;
224 | transition: opacity 0.2s ease;
225 | -webkit-transition-delay: 0.1s;
226 | transition-delay: 0.1s;
227 | }
228 | .ui.minimal.comments .comment > .content:hover > .actions {
229 | opacity: 1;
230 | }
231 |
232 | /*--------------------
233 | Sizes
234 | ---------------------*/
235 |
236 | .ui.small.comments {
237 | font-size: 0.9em;
238 | }
239 | .ui.comments {
240 | font-size: 1em;
241 | }
242 | .ui.large.comments {
243 | font-size: 1.1em;
244 | }
245 | .ui.huge.comments {
246 | font-size: 1.2em;
247 | }
248 |
249 |
250 | /*******************************
251 | Theme Overrides
252 | *******************************/
253 |
254 |
255 |
256 | /*******************************
257 | User Variable Overrides
258 | *******************************/
259 |
260 |
--------------------------------------------------------------------------------
/public/css/semantic/components/divider.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * # Semantic UI 2.1.7 - Divider
3 | * http://github.com/semantic-org/semantic-ui/
4 | *
5 | *
6 | * Copyright 2015 Contributors
7 | * Released under the MIT license
8 | * http://opensource.org/licenses/MIT
9 | *
10 | */.ui.divider{margin:1rem 0;line-height:1;height:0;font-weight:700;text-transform:uppercase;letter-spacing:.05em;color:rgba(0,0,0,.85);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent;font-size:1rem}.ui.divider:not(.vertical):not(.horizontal){border-top:1px solid rgba(34,36,38,.15);border-bottom:1px solid rgba(255,255,255,.1)}.ui.grid>.column+.divider,.ui.grid>.row>.column+.divider{left:auto}.ui.horizontal.divider{display:table;white-space:nowrap;height:auto;margin:'';overflow:hidden;line-height:1;text-align:center}.ui.horizontal.divider:after,.ui.horizontal.divider:before{content:'';display:table-cell;position:relative;top:50%;width:50%;background-repeat:no-repeat;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABaAAAAACCAYAAACuTHuKAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyFpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIChXaW5kb3dzKSIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDo1OThBRDY4OUNDMTYxMUU0OUE3NUVGOEJDMzMzMjE2NyIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDo1OThBRDY4QUNDMTYxMUU0OUE3NUVGOEJDMzMzMjE2NyI+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOjU5OEFENjg3Q0MxNjExRTQ5QTc1RUY4QkMzMzMyMTY3IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjU5OEFENjg4Q0MxNjExRTQ5QTc1RUY4QkMzMzMyMTY3Ii8+IDwvcmRmOkRlc2NyaXB0aW9uPiA8L3JkZjpSREY+IDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8+VU513gAAADVJREFUeNrs0DENACAQBDBIWLGBJQby/mUcJn5sJXQmOQMAAAAAAJqt+2prAAAAAACg2xdgANk6BEVuJgyMAAAAAElFTkSuQmCC)}.ui.horizontal.divider:before{background-position:right 1em top 50%}.ui.horizontal.divider:after{background-position:left 1em top 50%}.ui.vertical.divider{position:absolute;z-index:2;top:50%;left:50%;margin:0;padding:0;width:auto;height:50%;line-height:0;text-align:center;-webkit-transform:translateX(-50%);-ms-transform:translateX(-50%);transform:translateX(-50%)}.ui.vertical.divider:after,.ui.vertical.divider:before{position:absolute;left:50%;content:'';z-index:3;border-left:1px solid rgba(34,36,38,.15);border-right:1px solid rgba(255,255,255,.1);width:0;height:calc(100% - 1rem)}.ui.vertical.divider:before{top:-100%}.ui.vertical.divider:after{top:auto;bottom:0}@media only screen and (max-width:767px){.ui.grid .stackable.row .ui.vertical.divider,.ui.stackable.grid .ui.vertical.divider{display:table;white-space:nowrap;height:auto;margin:'';overflow:hidden;line-height:1;text-align:center;position:static;top:0;left:0;-webkit-transform:none;-ms-transform:none;transform:none}.ui.grid .stackable.row .ui.vertical.divider:after,.ui.grid .stackable.row .ui.vertical.divider:before,.ui.stackable.grid .ui.vertical.divider:after,.ui.stackable.grid .ui.vertical.divider:before{left:0;border-left:none;border-right:none;content:'';display:table-cell;position:relative;top:50%;width:50%;background-repeat:no-repeat}.ui.grid .stackable.row .ui.vertical.divider:before,.ui.stackable.grid .ui.vertical.divider:before{background-position:right 1em top 50%}.ui.grid .stackable.row .ui.vertical.divider:after,.ui.stackable.grid .ui.vertical.divider:after{background-position:left 1em top 50%}}.ui.divider>.icon{margin:0;font-size:1rem;height:1em;vertical-align:middle}.ui.hidden.divider{border-color:transparent!important}.ui.hidden.divider:after,.ui.hidden.divider:before{display:none}.ui.divider.inverted,.ui.horizontal.inverted.divider,.ui.vertical.inverted.divider{color:#fff}.ui.divider.inverted,.ui.divider.inverted:after,.ui.divider.inverted:before{border-top-color:rgba(34,36,38,.15)!important;border-left-color:rgba(34,36,38,.15)!important;border-bottom-color:rgba(255,255,255,.15)!important;border-right-color:rgba(255,255,255,.15)!important}.ui.fitted.divider{margin:0}.ui.clearing.divider{clear:both}.ui.section.divider{margin-top:2rem;margin-bottom:2rem}@media only screen and (max-width:767px){.ui.grid .stackable.row .ui.vertical.divider:after,.ui.grid .stackable.row .ui.vertical.divider:before,.ui.stackable.grid .ui.vertical.divider:after,.ui.stackable.grid .ui.vertical.divider:before{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABaAAAAACCAYAAACuTHuKAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyFpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIChXaW5kb3dzKSIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDo1OThBRDY4OUNDMTYxMUU0OUE3NUVGOEJDMzMzMjE2NyIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDo1OThBRDY4QUNDMTYxMUU0OUE3NUVGOEJDMzMzMjE2NyI+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOjU5OEFENjg3Q0MxNjExRTQ5QTc1RUY4QkMzMzMyMTY3IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjU5OEFENjg4Q0MxNjExRTQ5QTc1RUY4QkMzMzMyMTY3Ii8+IDwvcmRmOkRlc2NyaXB0aW9uPiA8L3JkZjpSREY+IDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8+VU513gAAADVJREFUeNrs0DENACAQBDBIWLGBJQby/mUcJn5sJXQmOQMAAAAAAJqt+2prAAAAAACg2xdgANk6BEVuJgyMAAAAAElFTkSuQmCC)}}
--------------------------------------------------------------------------------
/app_modules/AbstractDao.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Created by Eamonn on 2015/10/16.
3 | * CRUD in MongoDB
4 | */
5 | var dataSource = require('../app_db/dataSource.js');
6 | var uuid = require('node-uuid');
7 | var moment = require('moment');
8 | var message = require('./_utils/messageGenerator.js');
9 |
10 | var AbstractDao = function(collectionName,dbInstance){
11 | this.dataCollection = dataSource.getDB()?dataSource.getDB().collection(collectionName):dbInstance.collection(collectionName);
12 | };
13 |
14 | AbstractDao.prototype.prepareNewObj = function(obj){
15 | if(obj === undefined || obj === null){
16 | obj = {};
17 | }
18 | if(!obj.itemId) obj.id = uuid.v1(); // -> '6c84fb90-12c4-11e1-840d-7b25c5ee775a'
19 | obj.createTime = moment().format('YYYY-MM-DD HH:mm:ss');
20 | obj.lastModify = obj.createTime;
21 | return obj;
22 | };
23 |
24 | AbstractDao.prototype.insertOne = function(data,next){
25 | data = this.prepareNewObj(data);
26 | this.dataCollection.insertOne(data,function(err,result){
27 | if(err){
28 | next(message.genSimpFailedMsg(err.message, err.stack));
29 | }else{
30 | if(data.id)
31 | next(message.genSimpSuccessMsg(null, data.id));
32 | else
33 | next(message.genSimpSuccessMsg(null, data.itemId));
34 | }
35 | });
36 | };
37 |
38 | AbstractDao.prototype.insertUnpreOne = function (data,next) {
39 | this.dataCollection.insertOne(data,function(err,result){
40 | if(err){
41 | next(message.genSimpFailedMsg(err.message, err.stack));
42 | }else{
43 | next(message.genSimpSuccessMsg(null, data));
44 | }
45 | });
46 | };
47 |
48 | AbstractDao.prototype.insertMany = function(dataArr,next){
49 | var array = [];
50 | for(var i = 0; i.visible.content{position:absolute!important;top:0!important;left:0!important;z-index:3!important;-webkit-transition:all .5s ease .1s;transition:all .5s ease .1s}.ui.reveal>.hidden.content{position:relative!important;z-index:2!important}.ui.active.reveal .visible.content,.ui.reveal:hover .visible.content{z-index:4!important}.ui.slide.reveal{position:relative!important;overflow:hidden!important;white-space:nowrap}.ui.slide.reveal>.content{display:block;width:100%;float:left;margin:0;-webkit-transition:-webkit-transform .5s ease .1s;transition:transform .5s ease .1s}.ui.slide.reveal>.visible.content{position:relative!important}.ui.slide.reveal>.hidden.content{position:absolute!important;left:0!important;width:100%!important;-webkit-transform:translateX(100%)!important;-ms-transform:translateX(100%)!important;transform:translateX(100%)!important}.ui.slide.active.reveal>.visible.content,.ui.slide.reveal:hover>.visible.content{-webkit-transform:translateX(-100%)!important;-ms-transform:translateX(-100%)!important;transform:translateX(-100%)!important}.ui.slide.active.reveal>.hidden.content,.ui.slide.reveal:hover>.hidden.content,.ui.slide.right.reveal>.visible.content{-webkit-transform:translateX(0)!important;-ms-transform:translateX(0)!important;transform:translateX(0)!important}.ui.slide.right.reveal>.hidden.content{-webkit-transform:translateX(-100%)!important;-ms-transform:translateX(-100%)!important;transform:translateX(-100%)!important}.ui.slide.right.active.reveal>.visible.content,.ui.slide.right.reveal:hover>.visible.content{-webkit-transform:translateX(100%)!important;-ms-transform:translateX(100%)!important;transform:translateX(100%)!important}.ui.slide.right.active.reveal>.hidden.content,.ui.slide.right.reveal:hover>.hidden.content{-webkit-transform:translateX(0)!important;-ms-transform:translateX(0)!important;transform:translateX(0)!important}.ui.slide.up.reveal>.hidden.content{-webkit-transform:translateY(100%)!important;-ms-transform:translateY(100%)!important;transform:translateY(100%)!important}.ui.slide.up.active.reveal>.visible.content,.ui.slide.up.reveal:hover>.visible.content{-webkit-transform:translateY(-100%)!important;-ms-transform:translateY(-100%)!important;transform:translateY(-100%)!important}.ui.slide.up.active.reveal>.hidden.content,.ui.slide.up.reveal:hover>.hidden.content{-webkit-transform:translateY(0)!important;-ms-transform:translateY(0)!important;transform:translateY(0)!important}.ui.slide.down.reveal>.hidden.content{-webkit-transform:translateY(-100%)!important;-ms-transform:translateY(-100%)!important;transform:translateY(-100%)!important}.ui.slide.down.active.reveal>.visible.content,.ui.slide.down.reveal:hover>.visible.content{-webkit-transform:translateY(100%)!important;-ms-transform:translateY(100%)!important;transform:translateY(100%)!important}.ui.slide.down.active.reveal>.hidden.content,.ui.slide.down.reveal:hover>.hidden.content{-webkit-transform:translateY(0)!important;-ms-transform:translateY(0)!important;transform:translateY(0)!important}.ui.fade.reveal>.visible.content{opacity:1}.ui.fade.active.reveal>.visible.content,.ui.fade.reveal:hover>.visible.content{opacity:0}.ui.move.reveal{position:relative!important;overflow:hidden!important;white-space:nowrap}.ui.move.reveal>.content{display:block;float:left;margin:0;-webkit-transition:-webkit-transform .5s cubic-bezier(.175,.885,.32,1) .1s;transition:transform .5s cubic-bezier(.175,.885,.32,1) .1s}.ui.move.reveal>.visible.content{position:relative!important}.ui.move.reveal>.hidden.content{position:absolute!important;left:0!important;width:100%!important}.ui.move.active.reveal>.visible.content,.ui.move.reveal:hover>.visible.content{-webkit-transform:translateX(-100%)!important;-ms-transform:translateX(-100%)!important;transform:translateX(-100%)!important}.ui.move.right.active.reveal>.visible.content,.ui.move.right.reveal:hover>.visible.content{-webkit-transform:translateX(100%)!important;-ms-transform:translateX(100%)!important;transform:translateX(100%)!important}.ui.move.up.active.reveal>.visible.content,.ui.move.up.reveal:hover>.visible.content{-webkit-transform:translateY(-100%)!important;-ms-transform:translateY(-100%)!important;transform:translateY(-100%)!important}.ui.move.down.active.reveal>.visible.content,.ui.move.down.reveal:hover>.visible.content{-webkit-transform:translateY(100%)!important;-ms-transform:translateY(100%)!important;transform:translateY(100%)!important}.ui.rotate.reveal>.visible.content{-webkit-transition-duration:.5s;transition-duration:.5s;-webkit-transform:rotate(0);-ms-transform:rotate(0);transform:rotate(0)}.ui.rotate.reveal>.visible.content,.ui.rotate.right.reveal>.visible.content{-webkit-transform-origin:bottom right;-ms-transform-origin:bottom right;transform-origin:bottom right}.ui.rotate.active.reveal>.visible.conten,.ui.rotate.reveal:hover>.visible.content,.ui.rotate.right.active.reveal>.visible.content,.ui.rotate.right.reveal:hover>.visible.content{-webkit-transform:rotate(110deg);-ms-transform:rotate(110deg);transform:rotate(110deg)}.ui.rotate.left.reveal>.visible.content{-webkit-transform-origin:bottom left;-ms-transform-origin:bottom left;transform-origin:bottom left}.ui.rotate.left.active.reveal>.visible.content,.ui.rotate.left.reveal:hover>.visible.content{-webkit-transform:rotate(-110deg);-ms-transform:rotate(-110deg);transform:rotate(-110deg)}.ui.disabled.reveal:hover>.visible.visible.content{position:static!important;display:block!important;opacity:1!important;top:0!important;left:0!important;right:auto!important;bottom:auto!important;-webkit-transform:none!important;-ms-transform:none!important;transform:none!important}.ui.disabled.reveal:hover>.hidden.hidden.content{display:none!important}.ui.visible.reveal{overflow:visible}.ui.instant.reveal>.content{-webkit-transition-delay:0s!important;transition-delay:0s!important}.ui.reveal>.content{font-size:1rem!important}
--------------------------------------------------------------------------------
/public/css/bootstrap-colorpicker.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * Bootstrap Colorpicker
3 | * http://mjolnic.github.io/bootstrap-colorpicker/
4 | *
5 | * Originally written by (c) 2012 Stefan Petre
6 | * Licensed under the Apache License v2.0
7 | * http://www.apache.org/licenses/LICENSE-2.0.txt
8 | *
9 | */
10 |
11 | .colorpicker-saturation {
12 | float: left;
13 | width: 100px;
14 | height: 100px;
15 | cursor: crosshair;
16 | background-image: url("../img/bootstrap-colorpicker/saturation.png");
17 | }
18 |
19 | .colorpicker-saturation i {
20 | position: absolute;
21 | top: 0;
22 | left: 0;
23 | display: block;
24 | width: 5px;
25 | height: 5px;
26 | margin: -4px 0 0 -4px;
27 | border: 1px solid #000;
28 | -webkit-border-radius: 5px;
29 | -moz-border-radius: 5px;
30 | border-radius: 5px;
31 | }
32 |
33 | .colorpicker-saturation i b {
34 | display: block;
35 | width: 5px;
36 | height: 5px;
37 | border: 1px solid #fff;
38 | -webkit-border-radius: 5px;
39 | -moz-border-radius: 5px;
40 | border-radius: 5px;
41 | }
42 |
43 | .colorpicker-hue,
44 | .colorpicker-alpha {
45 | float: left;
46 | width: 15px;
47 | height: 100px;
48 | margin-bottom: 4px;
49 | margin-left: 4px;
50 | cursor: row-resize;
51 | }
52 |
53 | .colorpicker-hue i,
54 | .colorpicker-alpha i {
55 | position: absolute;
56 | top: 0;
57 | left: 0;
58 | display: block;
59 | width: 100%;
60 | height: 1px;
61 | margin-top: -1px;
62 | background: #000;
63 | border-top: 1px solid #fff;
64 | }
65 |
66 | .colorpicker-hue {
67 | background-image: url("../img/bootstrap-colorpicker/hue.png");
68 | }
69 |
70 | .colorpicker-alpha {
71 | display: none;
72 | background-image: url("../img/bootstrap-colorpicker/alpha.png");
73 | }
74 |
75 | .colorpicker-saturation,
76 | .colorpicker-hue,
77 | .colorpicker-alpha {
78 | background-size: contain;
79 | }
80 |
81 | .colorpicker {
82 | top: 0;
83 | left: 0;
84 | z-index: 2500;
85 | min-width: 130px;
86 | padding: 4px;
87 | margin-top: 1px;
88 | -webkit-border-radius: 4px;
89 | -moz-border-radius: 4px;
90 | border-radius: 4px;
91 | *zoom: 1;
92 | }
93 |
94 | .colorpicker:before,
95 | .colorpicker:after {
96 | display: table;
97 | line-height: 0;
98 | content: "";
99 | }
100 |
101 | .colorpicker:after {
102 | clear: both;
103 | }
104 |
105 | .colorpicker:before {
106 | position: absolute;
107 | top: -7px;
108 | left: 6px;
109 | display: inline-block;
110 | border-right: 7px solid transparent;
111 | border-bottom: 7px solid #ccc;
112 | border-left: 7px solid transparent;
113 | border-bottom-color: rgba(0, 0, 0, 0.2);
114 | content: '';
115 | }
116 |
117 | .colorpicker:after {
118 | position: absolute;
119 | top: -6px;
120 | left: 7px;
121 | display: inline-block;
122 | border-right: 6px solid transparent;
123 | border-bottom: 6px solid #ffffff;
124 | border-left: 6px solid transparent;
125 | content: '';
126 | }
127 |
128 | .colorpicker div {
129 | position: relative;
130 | }
131 |
132 | .colorpicker.colorpicker-with-alpha {
133 | min-width: 140px;
134 | }
135 |
136 | .colorpicker.colorpicker-with-alpha .colorpicker-alpha {
137 | display: block;
138 | }
139 |
140 | .colorpicker-color {
141 | height: 10px;
142 | margin-top: 5px;
143 | clear: both;
144 | background-image: url("../img/bootstrap-colorpicker/alpha.png");
145 | background-position: 0 100%;
146 | }
147 |
148 | .colorpicker-color div {
149 | height: 10px;
150 | }
151 |
152 | .colorpicker-selectors {
153 | display: none;
154 | height: 10px;
155 | margin-top: 5px;
156 | clear: both;
157 | }
158 |
159 | .colorpicker-selectors i {
160 | float: left;
161 | width: 10px;
162 | height: 10px;
163 | cursor: pointer;
164 | }
165 |
166 | .colorpicker-selectors i + i {
167 | margin-left: 3px;
168 | }
169 |
170 | .colorpicker-element .input-group-addon i,
171 | .colorpicker-element .add-on i {
172 | display: inline-block;
173 | width: 16px;
174 | height: 16px;
175 | vertical-align: text-top;
176 | cursor: pointer;
177 | }
178 |
179 | .colorpicker.colorpicker-inline {
180 | position: relative;
181 | z-index: auto;
182 | display: inline-block;
183 | float: none;
184 | }
185 |
186 | .colorpicker.colorpicker-horizontal {
187 | width: 110px;
188 | height: auto;
189 | min-width: 110px;
190 | }
191 |
192 | .colorpicker.colorpicker-horizontal .colorpicker-saturation {
193 | margin-bottom: 4px;
194 | }
195 |
196 | .colorpicker.colorpicker-horizontal .colorpicker-color {
197 | width: 100px;
198 | }
199 |
200 | .colorpicker.colorpicker-horizontal .colorpicker-hue,
201 | .colorpicker.colorpicker-horizontal .colorpicker-alpha {
202 | float: left;
203 | width: 100px;
204 | height: 15px;
205 | margin-bottom: 4px;
206 | margin-left: 0;
207 | cursor: col-resize;
208 | }
209 |
210 | .colorpicker.colorpicker-horizontal .colorpicker-hue i,
211 | .colorpicker.colorpicker-horizontal .colorpicker-alpha i {
212 | position: absolute;
213 | top: 0;
214 | left: 0;
215 | display: block;
216 | width: 1px;
217 | height: 15px;
218 | margin-top: 0;
219 | background: #ffffff;
220 | border: none;
221 | }
222 |
223 | .colorpicker.colorpicker-horizontal .colorpicker-hue {
224 | background-image: url("../img/bootstrap-colorpicker/hue-horizontal.png");
225 | }
226 |
227 | .colorpicker.colorpicker-horizontal .colorpicker-alpha {
228 | background-image: url("../img/bootstrap-colorpicker/alpha-horizontal.png");
229 | }
230 |
231 | .colorpicker.colorpicker-hidden {
232 | display: none;
233 | }
234 |
235 | .colorpicker.colorpicker-visible {
236 | display: block;
237 | }
238 |
239 | .colorpicker-inline.colorpicker-visible {
240 | display: inline-block;
241 | }
242 |
243 | .colorpicker-right:before {
244 | right: 6px;
245 | left: auto;
246 | }
247 |
248 | .colorpicker-right:after {
249 | right: 7px;
250 | left: auto;
251 | }
252 |
253 | .colorpicker-no-arrow:before {
254 | border-right: 0;
255 | border-left: 0;
256 | }
257 |
258 | .colorpicker-no-arrow:after {
259 | border-right: 0;
260 | border-left: 0;
261 | }
--------------------------------------------------------------------------------