├── .gitignore
├── README-es.md
├── README.md
└── frontend
├── .bowerrc
├── bower.json
├── config
├── .jshintrc
├── functions.js
├── local.js
├── path.js
├── plugins.js
└── tasks
│ ├── gulp_bower.js
│ ├── gulp_clean.js
│ ├── gulp_copy.js
│ ├── gulp_css.js
│ ├── gulp_fonts.js
│ ├── gulp_html.js
│ ├── gulp_icons.js
│ ├── gulp_js.js
│ ├── gulp_mocha.js
│ ├── gulp_server.js
│ ├── gulp_sprites.js
│ └── gulp_watch.js
├── gulpfile.js
├── package.json
├── source
├── fonts
│ ├── Helvetica
│ │ ├── Helvetica-webfont.eot
│ │ ├── Helvetica-webfont.otf
│ │ ├── Helvetica-webfont.svg
│ │ ├── Helvetica-webfont.ttf
│ │ └── Helvetica-webfont.woff
│ ├── Icons
│ │ ├── Icons-webfont.eot
│ │ ├── Icons-webfont.svg
│ │ ├── Icons-webfont.ttf
│ │ └── Icons-webfont.woff
│ ├── IndyPimp
│ │ ├── IndyPimp-webfont.eot
│ │ ├── IndyPimp-webfont.svg
│ │ ├── IndyPimp-webfont.ttf
│ │ └── IndyPimp-webfont.woff
│ └── _template
│ │ └── fonts.styl
├── icons
│ ├── _template
│ │ └── icons.styl
│ ├── uEA01-calendar.svg
│ └── uEA02-pointer.svg
├── images
│ ├── _sprite
│ │ ├── _template
│ │ │ └── stylus.template.handlebars
│ │ ├── diagram1.png
│ │ └── insert3.png
│ ├── favicon.ico
│ ├── main_sprite.png
│ └── plugins
│ │ └── fancybox
│ │ ├── blank.gif
│ │ ├── chosen-sprite.png
│ │ ├── chosen-sprite@2x.png
│ │ ├── fancybox_loading.gif
│ │ ├── fancybox_loading@2x.gif
│ │ ├── fancybox_overlay.png
│ │ ├── fancybox_sprite.png
│ │ ├── fancybox_sprite@2x.png
│ │ └── glide-arrows.png
├── scripts
│ ├── libs
│ │ └── utils.coffee
│ └── sections
│ │ └── home
│ │ └── inicio.coffee
├── styles
│ ├── _config
│ │ └── variables.styl
│ ├── _partials
│ │ ├── includes
│ │ │ ├── animations.styl
│ │ │ ├── buttons.styl
│ │ │ ├── forms.styl
│ │ │ ├── icons.styl
│ │ │ ├── normalize.styl
│ │ │ └── utilities.styl
│ │ ├── layout
│ │ │ ├── footer.styl
│ │ │ └── header.styl
│ │ ├── mixins
│ │ │ ├── main_sprite.styl
│ │ │ └── mixins.styl
│ │ └── plugins
│ │ │ └── fancybox.styl
│ ├── layout
│ │ ├── fonts.styl
│ │ ├── ie.styl
│ │ └── layout.styl
│ └── sections
│ │ └── index.styl
└── views
│ ├── _config
│ └── variables.jade
│ ├── _partials
│ ├── includes
│ │ ├── footer_scripts.jade
│ │ ├── head.jade
│ │ └── head_scripts.jade
│ ├── layout
│ │ ├── footer.jade
│ │ └── header.jade
│ ├── mixins
│ │ ├── ie.jade
│ │ └── mixins.jade
│ └── views
│ │ ├── home
│ │ └── index.jade
│ │ └── layout.jade
│ └── index.jade
└── tests
├── mocha
└── sections
│ └── home
│ └── test_default.js
└── selenium
└── test_cases
├── dictionary.js
├── main.js
└── postulante
├── con_sesion
└── mi_cuenta.js
└── sin_sesion
└── login.js
/.gitignore:
--------------------------------------------------------------------------------
1 | frontend/node_modules
2 | frontend/static_files/fonts/iconFonts
3 | public/
--------------------------------------------------------------------------------
/README-es.md:
--------------------------------------------------------------------------------
1 | # Flux
2 | **Haciendo el flujo de trabajo frontend más facil**
3 |
4 |
5 | ## ¿Qué es Flux?
6 |
7 | Flux es un conjunto de tareas desarrolladas con gulp para facilitar el flujo de trabajo FrontEnd. Estas tareas involucran a los precompiladores como jade, stylus y coffescript, integrados con distintos paquetes de node y a una estructura de carpetas para mantener el orden.
8 |
9 | ## Tareas Principales
10 |
11 | Tarea | Descripción
12 | ---------------- | ---
13 | **gulp clean** | Tarea para eliminar js, css, fuentes e imagenes previmanete compilados.
14 | **gulp copy** | Tarea para copiar fuentes e imagenes desde la carpeta base frontend.
15 | **gulp css** | Tarea para compilar css a partir de archivos stylus.
16 | **gulp html** | Tarea para compilar html a partir archivos jade.
17 | **gulp js** | Tarea para compilar javascript a partir de archivos coffee.
18 | **gulp sprites** | Tarea para compilar archivos *.png a una imagen de sprites.
19 | **gulp fonts** | Tarea para generar css a partir de archivos de fuentes (eot, ttf, woff, svg).
20 | **gulp icons** | Tarea para generar fuente de iconos a partir de iconos en svg.
21 | **gulp watch** | Tarea para escuchar cualquier modificación que se en los archivos coffee, stylus, jade y compilarlos automáticamente.
22 | **gulp bower** | Tarea para manipular plugins instalados por bower.
23 |
24 | ## Instalación
25 |
26 | ### Instalando las dependencias.
27 |
28 | #### Instalar npm y nodejs en linux
29 | ```
30 | sudo apt-get update
31 | sudo apt-get install nodejs
32 | sudo apt-get install npm
33 | ```
34 |
35 | #### Instalar gulp de forma global
36 | ```
37 | sudo npm install -g gulp
38 | ```
39 |
40 | #### Instalar bower de forma global
41 | ```
42 | sudo npm install -g bower
43 | ```
44 |
45 | #### Ingresamos a la carpeta Frontend.
46 |
47 | Absolutamente todas la fuentes del desarrollo Frontend deberían agregarse/modificarse en la carpeta frontend.
48 |
49 | ```
50 | cd frontend/
51 | ```
52 |
53 | ### Instalando todas las dependencias locales de nuestro proyecto
54 | Una vez situado en la carpeta frontend, debemos instalar todas las dependencias que se encuentran en el archivo **package.json**.
55 | ```
56 | npm install
57 | ```
58 | > **Nota:**
59 | > Si pide permisos ejecutar con **sudo**
60 |
61 | #### Ejecutar todas las tareas
62 | Utilizando este comando en la consola ejecutará el archivo **gulpfile.js**.
63 | ```
64 | gulp
65 | ```
66 | > **Nota:**
67 | > También se puede ejecutar las [tareas](#todas_las_tareas) en forma independiente
68 |
69 | #### Instalar librerías con bower
70 | ```
71 | bower install
72 | ```
73 | #### Ejecutar watchers
74 | ```
75 | gulp watch
76 | ```
77 | Al ejecutar esta tarea, automáticamente se abrirá una página por defecto de bienvenida, donde se muestra el logo de frontendLabs.
78 | > **Nota:**
79 | > - El servidor con cual se trabaja se ha realizado con Express.js
80 | > - Por defecto la ruta es: http://localhost:3000/
81 | > - Se puede configurar las url editando el archivo **server.js**, ubicado en la ruta `/frontend/config/server.js`
82 |
83 | > También se puede acceder a cualquier ruta del proyecto y por defecto se ha establecido una pagina en blanco mediante la ruta:
84 | > http://localhost:3000/postulante/home/index
85 |
86 | ## Documentación
87 |
88 | - [Documentación en inglés](README.md)
89 |
90 |
91 |
92 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Flux
2 |
3 | Flux is a set of tasks developed with Gulp to make your front-end workflow easier. These tasks involve the compilation of files written with Jade, Stylus and Coffeescript pre-processors integrated with different node packages in an organized folder structure.
4 |
5 | ## Main tasks
6 |
7 | Task | Description
8 | ---------------- | ---
9 | **gulp clean** | Task to delete js, css, font and image files previously compiled.
10 | **gulp copy** | Task to copy fonts and images from the `flux/frontend/` folder
11 | **gulp css** | Task to compile `*.styl` files to `*.css`.
12 | **gulp html** | Task to compile `*.jade` files to `*.html`.
13 | **gulp js** | Task to compile `*.coffee` files to `*.js`.
14 | **gulp sprites** | Task to generate a spritesheet from `*.png` image files.
15 | **gulp fonts** | Task to generate a css stylesheet from font files (`*.eot`, `*.ttf`, `*.woff`, `*.svg`).
16 | **gulp icons** | Tast to generate an icon font from `*.svg` images.
17 | **gulp watch** | Task to listen for any changes made in the `*.coffee`, `*.styl`, `*.jade` files and compile them automatically.
18 | **gulp bower** | Task to manage plugins installed with Bower.
19 |
20 | ## Installation
21 |
22 | ### Installing dependencies
23 |
24 | #### Install npm and nodejs in linux
25 | ```
26 | sudo apt-get update
27 | sudo apt-get install nodejs
28 | sudo apt-get install npm
29 | ```
30 |
31 | #### Install gulp globally
32 | ```
33 | sudo npm install -g gulp
34 | ```
35 |
36 | #### Install bower globally
37 | ```
38 | sudo npm install -g bower
39 | ```
40 |
41 | #### Working folder
42 |
43 | All the front-end source files have to be added/modified in the `frontend/` folder.
44 |
45 | ```
46 | cd frontend/
47 | ```
48 |
49 | ### Installing all the local dependencies for our project
50 | Once you are in the `frontend/` folder install all the dependencies located in the **package.json** file.
51 | ```
52 | npm install
53 | ```
54 | > **Note:**
55 | > If you need permissions add **sudo** at the beginning.
56 |
57 | #### Run all the tasks
58 | This command in the console will execute all the default tasks contained in the **gulpfile.js** file.
59 | ```
60 | gulp
61 | ```
62 | > **Note:**
63 | > You can also run gulp [name-of-the-task] individually.
64 |
65 | #### Install libraries with bower
66 | ```
67 | bower install
68 | ```
69 | #### Run watchers
70 | ```
71 | gulp watch
72 | ```
73 | This task will automatically open a browser window with the default welcome page where you can see the [frontendlabs](http://frontendlabs.io) logo.
74 | > **Note:**
75 | > - We're using a server made with Express.js
76 | > - The default route is: http://localhost:3000/
77 | > - You can configure the url by editing the **server.js** file, which is located in `/frontend/config/server.js`
78 |
79 | > You can also access any project route. By default you can find a blank page in the following route `http://localhost:3000/postulante/home/index`
80 |
81 | ## Documentation
82 |
83 | - [Documentación en español](README-es.md)
84 |
85 |
--------------------------------------------------------------------------------
/frontend/.bowerrc:
--------------------------------------------------------------------------------
1 | {
2 | "directory": "../public/js/libs/"
3 | }
--------------------------------------------------------------------------------
/frontend/bower.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "flux",
3 | "version": "2.0.0",
4 | "homepage": "https://github.com/frontend-labs/flux",
5 | "author": "FrontEnd Labs",
6 | "description": "Flujo de tareas para FrontEnd",
7 | "license": "MIT",
8 | "ignore": [
9 | "**/.*",
10 | "node_modules",
11 | "bower_components",
12 | "test",
13 | "tests"
14 | ],
15 | "devDependencies": {
16 | "jquery": "1.11.3",
17 | "yosonjs": "~0.0.16-alpha",
18 | "selectivizr": "~1.0.2",
19 | "html5shiv": "~3.7.2"
20 | },
21 | "preen": {
22 | "jquery": ["dist/*.js"],
23 | "yosonjs": ["build/*.js"],
24 | "selectivizr": ["*.js"],
25 | "html5shiv": ["dist/*.js"]
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/frontend/config/.jshintrc:
--------------------------------------------------------------------------------
1 | {
2 | "node": false,
3 | "undef": true,
4 | "browser": true,
5 | "globals": {
6 | "spyOnEvent": false,
7 | "spyOn": false,
8 | "define": false,
9 | "require": true,
10 | "setTimeout": false,
11 | "describe": false,
12 | "beforeEach": false,
13 | "afterEach": false,
14 | "setFixtures": false,
15 | "expect": false,
16 | "it": false,
17 | "xit": false
18 | },
19 | "sub": true,
20 | "predef" : [
21 | "module",
22 | "FB",
23 | "twttr",
24 | "gapi",
25 | "yOSON",
26 | "$",
27 | "jQuery",
28 | "_",
29 | "log",
30 | "colorLog",
31 | "console",
32 | "warn",
33 | "echo",
34 | "debug",
35 | "success",
36 | "notice",
37 | "Cookie",
38 | "tmp",
39 | "browser",
40 | "gMap",
41 | "trackAnalytics",
42 | "google",
43 | "GMaps",
44 | "alert",
45 | "isInternetExplorer"
46 | ],
47 | "eqeqeq" : false, // esto es el casi el diablo, hay que ponerle false
48 | "eqnull" : false, // esto es el casi el diablo, hay que ponerle false
49 | "loopfunc" : false, // esto es el diablo, hay que ponerle false
50 | "smarttabs" : false //Mixed spaces and tabs
51 | }
52 |
--------------------------------------------------------------------------------
/frontend/config/functions.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Contiene todos las funciones globales de las tareas gulp
3 | *
4 | * @module Functions
5 | * @extends Plugins
6 | * @author Victor Sandoval
7 | */
8 |
9 | var Plugins = require('./plugins');
10 | var Functions = {
11 | errorHandler : function(error){
12 | var colorRed = Plugins.util.colors.red;
13 | Plugins.notifier.notify({
14 | title : 'Error en la tarea: ' + error.plugin,
15 | message : error.message
16 | });
17 | Plugins.util.log(
18 | '\n',
19 | colorRed('----------------------------'),'\n',
20 | colorRed(' Error en la tarea: ' + error.plugin), '\n',
21 | colorRed('----------------------------'), '\n',
22 | error.message, '\n',
23 | colorRed('----------------------------')
24 | );
25 | this.emit('end');
26 | },
27 | successHandler : function(){
28 | Plugins.notifier.notify({
29 | title : 'Compilación completa',
30 | message : 'Tarea terminada'
31 | });
32 | },
33 | isProduction : function (){
34 | flag = true;
35 | if(Plugins.util.env.dev){
36 | flag = false;
37 | }
38 | return flag;
39 | },
40 | isGzip : function (){
41 | flag = false;
42 | if(Plugins.util.env.gzip){
43 | flag = true;
44 | }
45 | return flag;
46 | }
47 | }
48 |
49 | module.exports = Functions;
--------------------------------------------------------------------------------
/frontend/config/local.js:
--------------------------------------------------------------------------------
1 | var Local = {}
2 | Local["PORT"] = 9080;
3 | Local["BASE_HOST"] = "http://localhost:" + Local["PORT"] + "/"
4 |
5 | module.exports = Local;
--------------------------------------------------------------------------------
/frontend/config/path.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Contiene todas las rutas del proyecto
3 | *
4 | * @module Path
5 | * @author Victor Sandoval
6 | */
7 |
8 | var Path = {base : {}, frontend : {}, dest : {}};
9 |
10 | /**
11 | * Ruta base del proyecto
12 | * @property base
13 | * @type String
14 | */
15 | Path.base = __dirname + '/../..';
16 |
17 | /**
18 | * Ruta base de la carpeta frontend
19 | * @property base
20 | * @type String
21 | */
22 | Path.frontend.base = Path.base + '/frontend';
23 |
24 | Path.frontend.config = Path.frontend.base + '/config';
25 | Path.frontend.source = Path.frontend.base + '/source';
26 | Path.frontend.tests = Path.frontend.base + '/tests';
27 |
28 | Path.frontend.scripts = Path.frontend.source + '/scripts';
29 | Path.frontend.views = Path.frontend.source + '/views';
30 | Path.frontend.styles = Path.frontend.source + '/styles';
31 | Path.frontend.temporals = Path.frontend.source + '/tmp';
32 | Path.frontend.fonts = Path.frontend.source + '/fonts';
33 | Path.frontend.icons = Path.frontend.source + '/icons';
34 | Path.frontend.images = Path.frontend.source + '/images';
35 |
36 | /**
37 | * Ruta base donde se cargará el servidor express
38 | * @property serverFiles
39 | * @type String
40 | */
41 | Path.dest.serverFiles = Path.base + '/public';
42 |
43 | /**
44 | * Ruta de los archivos estáticos (js, css, imagenes y fuentes)
45 | * @property serverFiles
46 | * @type String
47 | */
48 | Path.dest.static = '';
49 |
50 | //-----------------------------------------------------------------------
51 | Path.dest.css = Path.dest.serverFiles + Path.dest.static + '/css';
52 | Path.dest.js = Path.dest.serverFiles + Path.dest.static + '/js';
53 | Path.dest.img = Path.dest.serverFiles + Path.dest.static + '/images';
54 | Path.dest.fonts = Path.dest.serverFiles + Path.dest.static + '/fonts';
55 | Path.dest.html = Path.dest.serverFiles + Path.dest.static + '/views';
56 | //-----------------------------------------------------------------------
57 |
58 | module.exports = Path;
--------------------------------------------------------------------------------
/frontend/config/plugins.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Contiene todos los plugins de las tareas gulp
3 | *
4 | * @module Plugins
5 | * @author Victor Sandoval
6 | */
7 |
8 | var Plugins = {
9 | // Plugins globales
10 | if : require("gulp-if"),
11 | runSequence : require("run-sequence"),
12 | recursiveConcat : require("gulp-recursive-concat"),
13 | notifier : require("node-notifier"),
14 | util : require("gulp-util"),
15 | gzip : require("gulp-gzip"),
16 | // Plugins mocha
17 | replace : require("gulp-replace"),
18 | es : require("event-stream"),
19 | mocha : require("gulp-mocha"),
20 | fs : require("fs"),
21 | path : require("path"),
22 | // Plugins gulp clean
23 | del : require("del"),
24 | // Plugins gulp copy
25 | imagemin : require("gulp-imagemin"),
26 | imageminPNG : require("imagemin-optipng"),
27 | imageminJPG : require("imagemin-jpegtran"),
28 | imageminSVG : require("imagemin-svgo"),
29 | // Plugins gulp css
30 | stylus : require("gulp-stylus"),
31 | urlVersion : require("gulp-css-url-versioner"),
32 | rupture : require("rupture"),
33 | postcss : require("gulp-postcss"),
34 | csswring : require("csswring"),
35 | autoprefixer : require("autoprefixer"),
36 | lost : require("lost"),
37 | // Plugins gulp sprite
38 | spritesmith : require("gulp.spritesmith"),
39 | // Plugins gulp fonts
40 | consolidate : require("gulp-consolidate"),
41 | // Plugins gulp jade
42 | jade : require("gulp-jade"),
43 | jadeInheritance : require("jade-inheritance"),
44 | rename : require("gulp-rename"),
45 | // Plugins gulp icons
46 | iconfont : require("gulp-iconfont"),
47 | // Plugins gulp js
48 | coffee : require("gulp-coffee"),
49 | uglify : require("gulp-uglify"),
50 | jshint : require("gulp-jshint"),
51 | complexity : require("gulp-complexity"),
52 | // Plugins gulp watch
53 | browserSync : require("browser-sync"),
54 | express : require("express"),
55 | // Plugins gulp bower
56 | bower : require("gulp-bower"),
57 | preen : require("preen")
58 | }
59 |
60 | module.exports = Plugins;
61 |
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_bower.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para manejar librerias de bower
3 | *
4 | * @module Task (gulp bower)
5 | * @extends Gulp
6 | * @extends Plugins
7 | * @author Victor Sandoval
8 | */
9 |
10 | function Task(gulp, pathFiles, plugins, functions){
11 | var runTasks = function () {
12 |
13 | /**
14 | * Tarea para instalar las librerías de bower
15 | * (gulp bower:install)
16 | */
17 | gulp.task("bower:install", function(cb) {
18 | return plugins.bower({
19 | cmd: "update",
20 | directory: pathFiles.dest.js + "/libs"
21 | })
22 | });
23 |
24 | /**
25 | * Tarea para filtrar archivos de las librerías de bower
26 | * (gulp bower:filter)
27 | *
28 | * Se puede especificar que solo traiga los js de las librería a descargar
29 | * y estas se deben listar en el objeto {} "preen", dentro de archivo bower.json
30 | */
31 | gulp.task("bower:filter", function(cb) {
32 | return plugins.preen.preen({
33 | directory: pathFiles.dest.js + "/libs"
34 | }, cb);
35 | });
36 |
37 | /**
38 | * Tarea para comprimir librerias a gzip
39 | * (gulp bower:gzip)
40 | */
41 | gulp.task("bower:gzip", function(cb) {
42 | return gulp.src(pathFiles.dest.js + "/libs/**/*.*")
43 | .pipe(plugins.if(functions.isGzip, plugins.gzip({ append: false })))
44 | .pipe(gulp.dest(pathFiles.dest.js + "/libs"))
45 | });
46 |
47 | /**
48 | * Tarea principal
49 | * (gulp bower)
50 | */
51 | gulp.task("bower", function(cb){
52 | plugins.runSequence("bower:install", "bower:filter", "bower:gzip", cb)
53 | });
54 | }
55 |
56 | return {
57 | run : runTasks
58 | }
59 | }
60 |
61 | module.exports = Task;
62 |
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_clean.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para eliminar o limpiar los archivos generados por las tareas gulp
3 | *
4 | * @module Task (gulp clean)
5 | * @extends Gulp
6 | * @extends Path
7 | * @extends Plugins
8 | * @author Victor Sandoval
9 | */
10 |
11 | function Task(gulp, pathFiles, plugins, functions){
12 | var runTasks = function () {
13 | /**
14 | * Tarea para limpiar imagenes
15 | * (gulp clean:img)
16 | */
17 | gulp.task("clean:img", function (cb) {
18 | return plugins.del([pathFiles.dest.img], { force: true }, cb);
19 | });
20 |
21 | /**
22 | * Tarea para limpiar fuentes
23 | * (gulp clean:fonts)
24 | */
25 | gulp.task("clean:fonts", function (cb) {
26 | return plugins.del([pathFiles.dest.fonts], { force: true }, cb);
27 | });
28 |
29 | /**
30 | * Tarea para limpiar archivos js
31 | * (gulp clean:js)
32 | */
33 | gulp.task("clean:js", function (cb) {
34 | return plugins.del([pathFiles.dest.js], { force: true }, cb);
35 | });
36 |
37 | /**
38 | * Tarea para limpiar archivos css
39 | * (gulp clean:css)
40 | */
41 | gulp.task("clean:css", function (cb) {
42 | return plugins.del([pathFiles.dest.css], { force: true }, cb);
43 | });
44 |
45 | /**
46 | * Tarea principal
47 | * (gulp clean)
48 | */
49 | gulp.task("clean", function(cb){
50 | plugins.runSequence("clean:img", "clean:fonts", "clean:js", "clean:css", cb);
51 | });
52 | }
53 |
54 | return {
55 | run : runTasks
56 | }
57 | }
58 |
59 | module.exports = Task;
60 |
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_copy.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para copiar archivos de la carpeta frontend a la carpeta pública
3 | *
4 | * @module Task (gulp copy)
5 | * @extends Gulp
6 | * @extends Path
7 | * @extends Plugins
8 | * @author Victor Sandoval
9 | */
10 |
11 | function Task(gulp, pathFiles, plugins, functions){
12 | //----------------------------------------------------
13 | var pathCopyImgFiles = [
14 | pathFiles.frontend.images + '/**/**/*.*',
15 | '!' + pathFiles.frontend.images + '/_**/**/*.*',
16 | '!' + pathFiles.frontend.images + '/**/_**/*.*',
17 | '!' + pathFiles.frontend.images + '/**/**/_*.*'
18 | ]
19 | var pathCopyFontsFiles = [
20 | pathFiles.frontend.fonts + '/**/*.*',
21 | '!' + pathFiles.frontend.fonts + '/_**/*.*'
22 | ]
23 | //----------------------------------------------------
24 |
25 | var runTasks = function () {
26 | /**
27 | * Tarea para copiar imagenes
28 | * (gulp copy:img)
29 | */
30 | gulp.task('copy:img', function() {
31 | return gulp.src(pathCopyImgFiles, { base : pathFiles.frontend.source })
32 | .pipe(plugins.if(functions.isProduction, plugins.imagemin({
33 | verbose: true,
34 | plugins: [
35 | plugins.imageminPNG({optimizationLevel: 3}),
36 | plugins.imageminJPG({progressive: true}),
37 | plugins.imageminSVG()
38 | ]
39 | })))
40 | .pipe(plugins.if(functions.isGzip, plugins.gzip({ append: false })))
41 | .pipe(gulp.dest(pathFiles.dest.serverFiles + pathFiles.dest.static));
42 | });
43 |
44 | /**
45 | * Tarea para copiar sprites de imagenes
46 | * (gulp copy:img:sprites)
47 | */
48 | gulp.task('copy:img:sprites', function() {
49 | return gulp.src(pathFiles.frontend.images + '/*_sprite.png', { base : pathFiles.frontend.source })
50 | .pipe(plugins.if(functions.isGzip, plugins.gzip({ append: false })))
51 | .pipe(gulp.dest(pathFiles.dest.serverFiles + pathFiles.dest.static));
52 | });
53 |
54 | /**
55 | * Tarea para copiar fuentes
56 | * (gulp copy:fonts)
57 | */
58 | gulp.task('copy:fonts', function() {
59 | return gulp.src(pathCopyFontsFiles, { base : pathFiles.frontend.source })
60 | .pipe(plugins.if(functions.isGzip, plugins.gzip({ append: false })))
61 | .pipe(gulp.dest(pathFiles.dest.serverFiles + pathFiles.dest.static));
62 | });
63 |
64 | /**
65 | * Tarea para copiar librerías javascript con extensión *.js
66 | * (gulp copy:js:libs)
67 | *
68 | * Hay casos donde las librerías que no están registradas en bower, se deben copian al proyecto
69 | * con extensión .js (debido a que genera problemas al transformar a sintaxis coffee)
70 | */
71 | gulp.task('copy:js:libs', function () {
72 | return gulp.src(pathFiles.frontend.scripts + '/libs/*.js')
73 | .pipe(plugins.if(functions.isProduction, plugins.uglify({
74 | mangle : false,
75 | compress: {
76 | drop_console: true
77 | }
78 | })))
79 | .pipe(plugins.if(functions.isGzip, plugins.gzip({ append: false })))
80 | .pipe(gulp.dest(pathFiles.dest.js + '/libs'));
81 | });
82 |
83 | /**
84 | * Tarea principal
85 | * (gulp copy)
86 | */
87 | gulp.task('copy', function (cb) {
88 | plugins.runSequence('copy:img', 'copy:img:sprites', 'copy:fonts', 'copy:js:libs', cb);
89 | });
90 | }
91 |
92 | return {
93 | run : runTasks
94 | }
95 | }
96 |
97 |
98 | module.exports = Task;
99 |
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_css.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para compilar archivos .styl
3 | *
4 | * @module Task (gulp css)
5 | * @extends Gulp
6 | * @extends Path
7 | * @extends Plugins
8 | * @extends Functions
9 | * @author Victor Sandoval
10 | */
11 |
12 | function Task(gulp, pathFiles, plugins, functions){
13 |
14 | var pathStylesFiles = [
15 | pathFiles.frontend.styles + '/**/*.styl',
16 | '!' + pathFiles.frontend.styles + '/_**/**/*.styl'
17 | ]
18 | var processors = [
19 | plugins.autoprefixer(),
20 | plugins.lost()
21 | ];
22 |
23 | var runTasks = function () {
24 | /**
25 | * Tarea usada por el gulp watch
26 | * (gulp css)
27 | *
28 | * Utiliza plugins como
29 | * Rupture : Proporciona mixins para los breakpoints en css
30 | * Lost : Proporciona mixins para un sistema de grillas
31 | * PostCSS : Proporciona superpoderes a CSS
32 | * CSSWring : Plugin de PostCSS para minificar el css con la rutas mapeadas
33 | * Autoprefixer : Plugin para agregar prefijos para los diferentes motores de navegador
34 | */
35 | gulp.task('css', function () {
36 | if (functions.isProduction()) {
37 | processors.push(plugins.csswring)
38 | }
39 | return gulp.src(pathStylesFiles)
40 | .pipe(plugins.stylus({
41 | use: [plugins.rupture()]
42 | }))
43 | .on('error', functions.errorHandler)
44 | .pipe(plugins.postcss(processors))
45 | .pipe(plugins.urlVersion({lastcommit: true}))
46 | .pipe(plugins.if(functions.isGzip, plugins.gzip({ append: false })))
47 | .pipe(gulp.dest(pathFiles.dest.css))
48 | .on('end', functions.successHandler);
49 | });
50 |
51 |
52 | /**
53 | * Tarea principal
54 | * (gulp css:all)
55 | */
56 | gulp.task('css:all', function(cb) {
57 | plugins.runSequence('clean:css', 'css', cb);
58 | });
59 | }
60 |
61 | return {
62 | run : runTasks
63 | }
64 | }
65 |
66 | module.exports = Task;
67 |
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_fonts.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea Tarea para generar css de las fuentes
3 | *
4 | * @module Task (gulp fonts)
5 | * @extends Gulp
6 | * @extends Path
7 | * @extends Plugins
8 | * @author Victor Sandoval
9 | */
10 |
11 | function Task(gulp, pathFiles, plugins, functions){
12 | var runTasks = function () {
13 | /**
14 | * Tarea para generar archivo .styl de las fuentes
15 | * (gulp fonts:compile)
16 | */
17 | gulp.task('fonts:compile', function(cb){
18 | var dirList = []
19 | plugins.fs.readdirSync(pathFiles.frontend.fonts + "/").forEach(function(file){
20 | if(/^[^_]*$/g.test(file)){
21 | dirList.push(file)
22 | }
23 | });
24 | return gulp.src(pathFiles.frontend.fonts + '/_template/fonts.styl')
25 | .pipe(plugins.consolidate('lodash', { dirList: dirList }))
26 | .pipe(gulp.dest(pathFiles.frontend.styles + '/layout'));
27 | });
28 |
29 | /**
30 | * Tarea principal
31 | * (gulp fonts)
32 | */
33 | gulp.task('fonts', function(cb) {
34 | plugins.runSequence('fonts:compile', 'css', 'copy:fonts', cb);
35 | });
36 | }
37 |
38 | return {
39 | run : runTasks
40 | }
41 | }
42 |
43 | module.exports = Task;
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_html.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para compilar archivos .jade
3 | *
4 | * @module Task (gulp html)
5 | * @extends Gulp
6 | * @extends Path
7 | * @extends Plugins
8 | * @extends Functions
9 | * @author Victor Sandoval
10 | */
11 | function Task(gulp, pathFiles, plugins, functions){
12 |
13 | var pathJadeFiles = [
14 | pathFiles.frontend.views + '/*.jade',
15 | '!' + pathFiles.frontend.views + '/_**/**/*.jade'
16 | ]
17 |
18 | var fn = {
19 | compiler: function (pathSrc){
20 | return gulp.src(pathSrc, { base : pathFiles.frontend.views })
21 | .pipe(plugins.jade({
22 | pretty: !functions.isProduction(),
23 | locals: {
24 | baseUrl : "/",
25 | staticUrl : "/",
26 | elementUrl: "/",
27 | version : new Date().getTime()
28 | }
29 | }))
30 | .on('error', functions.errorHandler)
31 | .pipe(plugins.rename({ extname: ".phtml" }))
32 | .pipe(gulp.dest(pathFiles.dest.html))
33 | .on('end', functions.successHandler);
34 | },
35 | filter: function (inheritanceFiles){
36 | var path = [];
37 | inheritanceFiles.forEach(function(file) {
38 | // Filtro los archivos _*.jade para no ser compilados
39 | if (!/^_.+$/g.test(file)) {
40 | path.push(pathFiles.frontend.views + '/' + file);
41 | }
42 | });
43 | return path;
44 | }
45 | }
46 |
47 | /**
48 | * Tarea principal
49 | * (gulp html)
50 | */
51 | var runTasks = function(){
52 | gulp.task('html', function() {
53 | return fn.compiler(pathJadeFiles);
54 | });
55 | }
56 |
57 | var watcher = function(chunk){
58 | var options = { basedir: pathFiles.frontend.views };
59 | var inheritance = new plugins.jadeInheritance(chunk.path, options.basedir, options);
60 |
61 | fn.compiler(fn.filter(inheritance.files));
62 | plugins.browserSync.reload;
63 | }
64 |
65 | return {
66 | run : runTasks,
67 | watcher: watcher
68 | }
69 | }
70 |
71 | module.exports = Task;
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_icons.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para compilar iconos en .svg a fuente de iconos
3 | *
4 | * @module Task (gulp icons)
5 | * @extends Gulp
6 | * @extends Path
7 | * @extends Plugins
8 | * @author Victor Sandoval
9 | */
10 |
11 | function Task(gulp, pathFiles, plugins, functions){
12 | var runTasks = function () {
13 | var runTimestamp = Math.round(Date.now()/1000);
14 | /**
15 | * Tarea para compilar iconos .svg
16 | * (gulp icons:compile)
17 | *
18 | * Genera un archivo .styl y archivos de fuentes .eot .svg .ttf .woff
19 | */
20 | gulp.task('icons:compile', function(){
21 | return gulp.src(pathFiles.frontend.icons + '/*.svg')
22 | .pipe(plugins.iconfont({
23 | normalize: true,
24 | prependUnicode: true,
25 | fontName: 'Icons-webfont',
26 | formats: ['ttf', 'eot', 'woff', 'svg'],
27 | timestamp: runTimestamp
28 | }))
29 | .on('glyphs', function(codepoints, options) {
30 | gulp.src(pathFiles.frontend.icons + '/_template/icons.styl') //Template
31 | .pipe(plugins.consolidate('lodash', {
32 | glyphs: codepoints,
33 | fontName: options.fontName
34 | }))
35 | .pipe(gulp.dest(pathFiles.frontend.styles + '/_partials/includes'));
36 | })
37 | .pipe(gulp.dest(pathFiles.frontend.fonts + '/Icons'));
38 | });
39 |
40 | /**
41 | * Tarea principal
42 | * (gulp icons)
43 | */
44 | gulp.task('icons', function(cb) {
45 | plugins.runSequence('icons:compile', 'fonts:compile', 'css', 'copy:fonts', cb);
46 | });
47 | }
48 |
49 | return {
50 | run : runTasks
51 | }
52 | }
53 |
54 | module.exports = Task;
55 |
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_js.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para compilar y validar archivos .coffee
3 | *
4 | * @module Task (gulp js)
5 | * @extends Gulp
6 | * @extends Path
7 | * @extends Plugins
8 | * @extends Functions
9 | * @author Victor Sandoval
10 | */
11 |
12 | function Task(gulp, pathFiles, plugins, functions) {
13 | var fn = {
14 | compiler: function(pathSrc, pathdest, enabledRecursive){
15 | return gulp.src(pathSrc)
16 | .pipe(plugins.if(enabledRecursive, plugins.recursiveConcat({ extname: '.js' })))
17 | .pipe(plugins.coffee({ bare: true }))
18 | .pipe(plugins.jshint(pathFiles.frontend.config + '/.jshintrc'))
19 | .pipe(plugins.jshint.reporter('jshint-stylish'))
20 | .pipe(plugins.jshint.reporter('fail'))
21 | .on('error', functions.errorHandler)
22 | .pipe(plugins.if(functions.isProduction, plugins.uglify({
23 | mangle : true,
24 | compress: {
25 | drop_console: true
26 | }
27 | })))
28 | .pipe(plugins.if(functions.isGzip, plugins.gzip({ append: false })))
29 | .pipe(gulp.dest(pathdest))
30 | .on('end', functions.successHandler);
31 | }
32 | }
33 |
34 | var runTasks = function () {
35 | /**
36 | * Tarea para compilar archivos (.coffee) de librerías usadas para el proyecto
37 | * (gulp js:compile:libs)
38 | */
39 | gulp.task('js:compile:libs', function () {
40 | return gulp.src(pathFiles.frontend.scripts + '/libs/**/*.coffee', { base : pathFiles.frontend.scripts })
41 | .pipe(plugins.coffee({bare: true}).on('error', functions.errorHandler))
42 | .pipe(plugins.if(functions.isProduction, plugins.uglify({
43 | mangle : true,
44 | compress: {
45 | drop_console: false
46 | }
47 | })))
48 | .pipe(plugins.if(functions.isGzip, plugins.gzip({ append: false })))
49 | .pipe(gulp.dest(pathFiles.dest.js));
50 | });
51 |
52 | /**
53 | * Tarea para compilar archivos (.coffee) de los modulos del proyecto
54 | * (gulp js:concat)
55 | */
56 | gulp.task('js:compile', function () {
57 | return fn.compiler(pathFiles.frontend.scripts + '/sections/**/*.coffee', pathFiles.dest.js + '/sections', true)
58 | });
59 |
60 | /**
61 | * Tarea para validar complejidad de código en los modulos js
62 | * (gulp js:complexity)
63 | */
64 | gulp.task('js:complexity', function () {
65 | return gulp.src(pathFiles.frontend.scripts + '/sections/**/*.coffee')
66 | .pipe(plugins.coffee({ bare: true }))
67 | .pipe(plugins.complexity());
68 | });
69 |
70 | /**
71 | * Tarea usada por el gulp watch
72 | * (gulp js)
73 | */
74 | gulp.task('js', function (cb) {
75 | plugins.runSequence('js:compile:libs', 'js:compile', cb);
76 | });
77 |
78 | /**
79 | * Tarea principal
80 | * (gulp js:all)
81 | */
82 | gulp.task('js:all', function (cb) {
83 | plugins.runSequence('clean:js', 'js:compile:libs', 'js:compile', 'copy:js:libs', cb);
84 | });
85 | };
86 |
87 | var watcher = function(chunk){
88 | /*var basePath = plugins.path.dirname(chunk.path);
89 | var parentPath = basePath + "/*.coffee";
90 | var pathRelative = plugins.path.relative(pathFiles.frontend.scripts, basePath);
91 | var enabledRecursive = true;
92 |
93 | if (plugins.path.dirname(pathRelative) === "libs") {
94 | enabledRecursive = false;
95 | parentPath = chunk.path;
96 | }
97 |
98 | fn.compiler(parentPath, pathFiles.dest.js + '/' + pathRelative, enabledRecursive);
99 | plugins.browserSync.reload;*/
100 | }
101 |
102 | return {
103 | run : runTasks,
104 | watcher: watcher
105 | };
106 | }
107 |
108 | module.exports = Task;
109 |
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_mocha.js:
--------------------------------------------------------------------------------
1 | /*!!
2 | *
3 | * Tarea para realizar pruebas unitarias
4 | *
5 | * tarea principal: gulp mocha
6 | */
7 |
8 | function Task(gulp, pathFiles, plugins, functions) {
9 | require('coffee-script/register')
10 |
11 | var onlyModule, testAll, onlyModule, _controller, _module, ubication = '';
12 | var coffee_files_replaced = [];
13 | var coffee_path_files = [];
14 |
15 | // ================ FUNCTIONS ================
16 |
17 | var getCoffeeFilesFrom = function(directory){
18 | var files = [];
19 | var objFiles = {}
20 | var getFiles = function(obj, dir){
21 | plugins.fs.readdirSync(dir).forEach(function(file){
22 | if (plugins.fs.statSync(plugins.path.join(dir, file)).isDirectory()){
23 | obj[file] = {};
24 | getFiles(obj[file], plugins.path.join(dir, file));
25 | } else if (/\.coffee$/.test(file)) {
26 | file = plugins.path.basename(file, '.coffee');
27 | currentPath = plugins.path.join(dir, file)+'.coffee';
28 | files.push(currentPath);
29 | objFiles[currentPath] = file ;
30 | }
31 | });
32 | return {'array': files, 'key': objFiles};
33 | };
34 | return getFiles({}, directory)
35 | }
36 | var getPaths = function(path, all, ubication){
37 | var finalPath = path + '/modules/';
38 | if(!all){
39 | finalPath = finalPath + ubication.join('/') + '/' ;
40 | }
41 | return finalPath;
42 | }
43 | var getPathTests = function(path, all, ubication){
44 | var basePath = path.frontend.tests + '/mocha/';
45 | if(!all){
46 | basePath = basePath + ubication.join('/');
47 | }
48 | finalPath = [basePath + '*.js', basePath + '**/*.js'];
49 | return finalPath;
50 | }
51 | var tellMeWhatIamTesting = function(all, ubication){
52 | if(!all){
53 | console.log('=> Se ejecutan las pruebas de ' + ubication.join('/'));
54 | }else{
55 | console.log('=> Se ejecutan todas las pruebas');
56 | }
57 | }
58 |
59 | var runTasks = function () {
60 | gulp.task('mocha:params', function(){
61 | //Actualizo los valores de las variables acorde a lo solicitado
62 | _controller = "";
63 | _module = "";
64 | testAll = "";
65 |
66 | //Defino la ubicacion con ayuda de las variables
67 | ubication = onlyModule ? [_module]: [_module, _controller];
68 |
69 | //Busco la ubicación de los coffeescripts a ser testeados
70 | var path_coffee = getPaths(pathFiles.frontend.scripts, testAll, ubication);
71 | coffee_path_files = getCoffeeFilesFrom(path_coffee);
72 |
73 | //Indico que pruebas seran ejecutadas
74 | tellMeWhatIamTesting(testAll, ubication);
75 | return
76 | });
77 |
78 | gulp.task('mocha:replace', function(){
79 | //Reemplaza cada archivo
80 | var streams = coffee_path_files['array'].map(function(file) {
81 | tmpFile = pathFiles.frontend.temporals;
82 | coffee_files_replaced.push(tmpFile + '/' + coffee_path_files['key'][file] + '.coffee')
83 | return gulp.src(file)
84 | .pipe(gulp.dest(tmpFile));
85 | });
86 | return plugins.es.merge.apply(plugins.es, streams);
87 | });
88 |
89 | gulp.task('mocha:unit', function() {
90 | //Busco la ubicacion de las pruebas
91 | var path_test = getPathTests(pathFiles, testAll, ubication);
92 |
93 | //Utilidades globales para las pruebas
94 | global.expect = require('chai').expect;
95 | global.jsdom = require("jsdom").jsdom;
96 | global.$ = require('jquery')(jsdom().parentWindow);
97 | global.yOSON = require(pathFiles.dest.js + '/libs/yosonjs/build/yoson-min.js'); // Proximament un require('yoson')
98 |
99 | document = {}
100 |
101 | //Se testean los archivos
102 | return gulp.src(path_test, {read: false})
103 | .pipe(plugins.mocha({
104 | reporter: '',
105 | require: coffee_files_replaced
106 | }));
107 | });
108 |
109 | gulp.task('mocha:clean', function (cb) {
110 | return plugins.del(pathFiles.frontend.temporals, { force: true }, cb);
111 | });
112 |
113 | gulp.task('mocha', function(cb) {
114 | return plugins.runSequence('mocha:params', 'mocha:replace', 'mocha:unit', 'mocha:clean', cb);
115 | });
116 |
117 | gulp.task('test:functional', function(){
118 | return gulp.src(pathFiles.frontend.tests + '/webdriver/main.js')
119 | .pipe(plugins.mocha());
120 | })
121 | }
122 |
123 | return {
124 | run : runTasks
125 | }
126 | }
127 |
128 | module.exports = Task;
129 |
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_server.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para ejecutar el servidor express
3 | *
4 | * @module Task (gulp server)
5 | * @extends Gulp
6 | * @extends Plugins
7 | * @author Victor Sandoval
8 | */
9 |
10 | function Task(gulp, pathFiles, plugins, functions, local){
11 |
12 | var setGlobalVariables = function (req){
13 | var oP = {};
14 | oP.version = new Date().getTime();
15 | oP.section = req.params.section;
16 | oP.baseUrl = "http://" + req.headers.host;
17 | oP.staticUrl = oP.baseUrl + pathFiles.dest.static + "/";
18 | oP.elementUrl = oP.baseUrl;
19 | return oP;
20 | };
21 |
22 | var runTasks = function () {
23 | /**
24 | * Tarea principal
25 | * (gulp server)
26 | */
27 | gulp.task('server', function () {
28 | var app = plugins.express();
29 |
30 | app.set('view engine', 'jade');
31 | app.set('views', pathFiles.dest.serverFiles);
32 | app.use(plugins.express.static(pathFiles.dest.serverFiles));
33 |
34 | app.get("/:section", function(req, res) {
35 | var jadeGlobals = setGlobalVariables(req);
36 | res.render(pathFiles.frontend.views + "/" + jadeGlobals.section, jadeGlobals);
37 | });
38 |
39 | app.get("/", function(req, res) {
40 | var jadeGlobals = setGlobalVariables(req);
41 | jadeGlobals.section = "index";
42 | res.render(pathFiles.frontend.views + "/" + jadeGlobals.section, jadeGlobals);
43 | });
44 |
45 | app.listen(local.PORT);
46 |
47 | //ps -ax | grep node
48 | //60778 ?? 0:00.62 /usr/local/bin/node abc.js
49 | //kill -9 60778
50 | });
51 | }
52 |
53 | return {
54 | run : runTasks
55 | }
56 | }
57 |
58 | module.exports = Task;
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_sprites.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para generar archivo sprite de imagenes png
3 | *
4 | * @module Task (gulp sprites)
5 | * @extends Gulp
6 | * @extends Path
7 | * @extends Plugins
8 | * @author Victor Sandoval
9 | */
10 |
11 | function Task(gulp, pathFiles, plugins, functions){
12 |
13 | var runTasks = function () {
14 | /**
15 | * Tarea para compilar archivos png y tranformarlos a un sprite
16 | * (gulp sprites:compile)
17 | *
18 | * Genera un archivo img y un .styl
19 | */
20 | gulp.task('sprites:compile', function () {
21 | var spriteData = gulp.src(pathFiles.frontend.images + '/_sprite/main_sprite/*.png')
22 | .pipe(plugins.spritesmith({
23 | algorithm: 'binary-tree',
24 | imgPath: '../../../img/main_sprite.png',
25 | imgName: 'main_sprite.png',
26 | cssName: 'main_sprite.styl'
27 | }));
28 |
29 | // Genera archivo sprite
30 | var imgStream = spriteData.img.pipe(gulp.dest(pathFiles.frontend.images + '/'));
31 |
32 | // Genera archivo .styl
33 | var cssStream = spriteData.css.pipe(gulp.dest(pathFiles.frontend.styles + '/_partials/mixins'));
34 | return spriteData;
35 | });
36 |
37 | /**
38 | * Tarea principal
39 | * (gulp sprites)
40 | */
41 | gulp.task('sprites', function (cb) {
42 | plugins.runSequence('sprites:compile', 'copy:img:sprites', 'css', cb);
43 | });
44 | }
45 |
46 | return {
47 | run : runTasks
48 | }
49 | }
50 |
51 | module.exports = Task;
--------------------------------------------------------------------------------
/frontend/config/tasks/gulp_watch.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Tarea para ejecutar el servidor express y el watcher
3 | *
4 | * @module Task (gulp watch)
5 | * @extends Gulp
6 | * @extends Plugins
7 | * @author Victor Sandoval
8 | */
9 |
10 | function Task(gulp, pathFiles, plugins, functions, local){
11 | var runTasks = function (objWatchers) {
12 | /**
13 | * Tarea para ejecutar el browserSync, una vez ejecutada la tarea nodemon
14 | * (gulp browserSync)
15 | */
16 | gulp.task('browserSync', function () {
17 | plugins.browserSync({
18 | proxy: local.BASE_HOST
19 | });
20 | });
21 |
22 | /**
23 | * Tarea principal
24 | * (gulp watch)
25 | */
26 |
27 | //gulp.task('watch', function () {
28 | gulp.task('watch', ['server', 'browserSync'], function () {
29 | gulp.watch([pathFiles.frontend.views + '/**/*.jade'], objWatchers.html);
30 | gulp.watch([pathFiles.frontend.styles + '/**/*.styl'], ['css', plugins.browserSync.reload]);
31 | gulp.watch([pathFiles.frontend.scripts + '/**/*.coffee'], ['js', plugins.browserSync.reload]);
32 | });
33 | }
34 |
35 | return {
36 | run : runTasks
37 | }
38 |
39 | }
40 |
41 | module.exports = Task;
42 |
--------------------------------------------------------------------------------
/frontend/gulpfile.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Archivo de configuración de gulp
3 | *
4 | * @extends Gulp
5 | * @extends Local
6 | * @extends PathFiles
7 | * @extends Plugins
8 | * @extends Functions
9 | * @extends Task
10 | * @author Victor Sandoval
11 | */
12 |
13 | var gulp = require('gulp'),
14 | local = require('./config/local'),
15 | pathFiles = require('./config/path'),
16 | plugins = require('./config/plugins'),
17 | functions = require('./config/functions'),
18 | runTask = function (nameTask){
19 | return require("./config/tasks/" + nameTask)(gulp, pathFiles, plugins, functions, local);
20 | };
21 |
22 | /**
23 | * Ejecutando tareas
24 | */
25 | runTask("gulp_clean").run();
26 | runTask("gulp_copy").run();
27 | runTask("gulp_sprites").run();
28 | runTask("gulp_fonts").run();
29 | runTask("gulp_icons").run();
30 | runTask("gulp_bower").run();
31 | runTask("gulp_mocha").run();
32 | runTask("gulp_server").run();
33 | runTask("gulp_js").run();
34 | runTask("gulp_css").run();
35 |
36 | /**
37 | * Tareas para el watcher de HTML
38 | */
39 | var taskHTML = runTask("gulp_html");
40 | taskHTML.run();
41 |
42 | runTask("gulp_watch").run({
43 | html: taskHTML.watcher
44 | });
45 |
46 | /**
47 | * Tarea por defecto de Gulp
48 | */
49 | gulp.task('default', function(cb){
50 | plugins.runSequence('clean', 'icons:compile', 'fonts:compile', 'css', 'js', 'html', 'copy', 'bower', cb)
51 | });
--------------------------------------------------------------------------------
/frontend/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "flux",
3 | "version": "2.1.0",
4 | "description": "Flujo de tareas para FrontEnd",
5 | "license": "ISC",
6 | "author": "FrontEnd Labs",
7 | "devDependencies": {
8 | "autoprefixer": "^6.1.1",
9 | "browser-sync": "^2.7.6",
10 | "chai": "^3.0.0",
11 | "chai-http": "~3.0.0",
12 | "csswring": "^5.0.0",
13 | "del": "^2.2.0",
14 | "event-stream": "^3.3.1",
15 | "express": "^4.12.3",
16 | "gulp": "^3.8.11",
17 | "gulp-bower": "0.0.13",
18 | "gulp-coffee": "^2.3.1",
19 | "gulp-complexity": "^0.3.0",
20 | "gulp-consolidate": "^0.2.0",
21 | "gulp-css-url-versioner": "^1.1.1",
22 | "gulp-gzip": "^1.4.0",
23 | "gulp-iconfont": "^8.0.0",
24 | "gulp-if": "^2.0.1",
25 | "gulp-imagemin": "^3.0.1",
26 | "gulp-jade": "^1.0.1",
27 | "gulp-jshint": "^2.0.1",
28 | "gulp-mocha": "^2.1.2",
29 | "gulp-param": "^1.0.3",
30 | "gulp-postcss": "^6.0.1",
31 | "gulp-recursive-concat": "0.2.0",
32 | "gulp-rename": "^1.2.2",
33 | "gulp-replace": "^0.5.3",
34 | "gulp-stylus": "^2.0.2",
35 | "gulp-uglify": "^1.2.0",
36 | "gulp-util": "^3.0.5",
37 | "gulp.spritesmith": "^6.2.1",
38 | "imagemin-jpegtran": "^5.0.2",
39 | "imagemin-optipng": "^5.1.0",
40 | "imagemin-pngquant": "^5.0.0",
41 | "imagemin-svgo": "^5.1.0",
42 | "it-each": "~0.3.1",
43 | "jade-inheritance": "^0.2.1",
44 | "jeet": "^6.1.2",
45 | "jquery": "^3.0.0",
46 | "jsdom": "^9.2.1",
47 | "jshint": "^2.9.2",
48 | "jshint-stylish": "^2.0.0",
49 | "lodash": "^4.13.1",
50 | "lost": "~6.8.0",
51 | "node-notifier": "^4.2.3",
52 | "preen": "^1.2.0",
53 | "run-sequence": "^1.1.0",
54 | "rupture": "^0.6.1",
55 | "webdriverio": "~4.1.1"
56 | },
57 | "engines": {
58 | "node": "5.12.0",
59 | "npm": "2.5.1"
60 | },
61 | "scripts": {
62 | "test": "echo \"Error: no test specified\" && exit 1",
63 | "start": "gulp"
64 | }
65 | }
66 |
--------------------------------------------------------------------------------
/frontend/source/fonts/Helvetica/Helvetica-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/Helvetica/Helvetica-webfont.eot
--------------------------------------------------------------------------------
/frontend/source/fonts/Helvetica/Helvetica-webfont.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/Helvetica/Helvetica-webfont.otf
--------------------------------------------------------------------------------
/frontend/source/fonts/Helvetica/Helvetica-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/Helvetica/Helvetica-webfont.ttf
--------------------------------------------------------------------------------
/frontend/source/fonts/Helvetica/Helvetica-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/Helvetica/Helvetica-webfont.woff
--------------------------------------------------------------------------------
/frontend/source/fonts/Icons/Icons-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/Icons/Icons-webfont.eot
--------------------------------------------------------------------------------
/frontend/source/fonts/Icons/Icons-webfont.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
19 |
--------------------------------------------------------------------------------
/frontend/source/fonts/Icons/Icons-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/Icons/Icons-webfont.ttf
--------------------------------------------------------------------------------
/frontend/source/fonts/Icons/Icons-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/Icons/Icons-webfont.woff
--------------------------------------------------------------------------------
/frontend/source/fonts/IndyPimp/IndyPimp-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/IndyPimp/IndyPimp-webfont.eot
--------------------------------------------------------------------------------
/frontend/source/fonts/IndyPimp/IndyPimp-webfont.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
1650 |
--------------------------------------------------------------------------------
/frontend/source/fonts/IndyPimp/IndyPimp-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/IndyPimp/IndyPimp-webfont.ttf
--------------------------------------------------------------------------------
/frontend/source/fonts/IndyPimp/IndyPimp-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/fonts/IndyPimp/IndyPimp-webfont.woff
--------------------------------------------------------------------------------
/frontend/source/fonts/_template/fonts.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Font Styles
3 | * @module fonts
4 | **/
5 | @require '../_config/variables'
6 | <% _.each(dirList, function(fontName) { %>
7 | @font-face
8 | font-family "<%= fontName %>"
9 | src url($fontPath + "<%=fontName%>/<%=fontName%>-webfont.eot")
10 | src url($fontPath + "<%=fontName%>/<%=fontName%>-webfont.eot?#iefix") format("embedded-opentype"), \
11 | url($fontPath + "<%=fontName%>/<%=fontName%>-webfont.woff") format("woff"), \
12 | url($fontPath + "<%=fontName%>/<%=fontName%>-webfont.ttf") format("truetype"), \
13 | url($fontPath + "<%=fontName%>/<%=fontName%>-webfont.svg#<%=fontName%>") format("svg");
14 | font-style normal
15 | font-weight normal
16 | <% }); %>
17 |
--------------------------------------------------------------------------------
/frontend/source/icons/_template/icons.styl:
--------------------------------------------------------------------------------
1 | .icon
2 | -webkit-font-smoothing antialiased
3 | display inline-block
4 | font-family "<%= fontName %>"
5 | font-size inherit
6 | font-style normal
7 | font-variant normal
8 | font-weight normal
9 | line-height 1
10 | text-decoration inherit
11 | text-transform none
12 | vertical-align middle
13 |
14 | <% _.each(glyphs, function(glyph) { %>
15 | .icon_<%= glyph.name %>:before
16 | content "\<%= glyph.unicode.toString(16).toUpperCase() %>"
17 | <% }); %>
18 |
--------------------------------------------------------------------------------
/frontend/source/icons/uEA01-calendar.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
56 |
--------------------------------------------------------------------------------
/frontend/source/icons/uEA02-pointer.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
40 |
--------------------------------------------------------------------------------
/frontend/source/images/_sprite/_template/stylus.template.handlebars:
--------------------------------------------------------------------------------
1 | {
2 | // Default options
3 | 'functions': true,
4 | 'variableNameTransforms': ['underscored']
5 | }
6 |
7 | {{#block "sprites-comment"}}
8 | /*
9 | Stylus variables are information about icon's compiled state, stored under its original file name
10 |
11 | .icon-home {
12 | width: $icon_home_width;
13 | }
14 |
15 | The large array-like variables contain all information about a single icon
16 | $icon_home = x y offset_x offset_y width height total_width total_height image_path;
17 |
18 | At the bottom of this section, we provide information about the spritesheet itself
19 | $spritesheet = width height image $spritesheet_sprites;
20 | */
21 | {{/block}}
22 | {{#block "sprites"}}
23 | {{#each sprites}}
24 | ${{strings.name_name}} = '{{name}}';
25 | ${{strings.name_x}} = {{px.x}};
26 | ${{strings.name_y}} = {{px.y}};
27 | ${{strings.name_offset_x}} = {{px.offset_x}};
28 | ${{strings.name_offset_y}} = {{px.offset_y}};
29 | ${{strings.name_width}} = {{px.width}};
30 | ${{strings.name_height}} = {{px.height}};
31 | ${{strings.name_total_width}} = {{px.total_width}};
32 | ${{strings.name_total_height}} = {{px.total_height}};
33 | ${{strings.name_image}} = $imgPath + '{{{escaped_image}}}';
34 | ${{strings.name}} = ${{strings.name_x}} ${{strings.name_y}} ${{strings.name_offset_x}} ${{strings.name_offset_y}} ${{strings.name_width}} ${{strings.name_height}} ${{strings.name_total_width}} ${{strings.name_total_height}} ${{strings.name_image}} ${{strings.name_name}};
35 | {{/each}}
36 | {{/block}}
37 | {{#block "spritesheet"}}
38 | ${{spritesheet_info.strings.name_width}} = {{spritesheet.px.width}};
39 | ${{spritesheet_info.strings.name_height}} = {{spritesheet.px.height}};
40 | ${{spritesheet_info.strings.name_image}} = $imgPath + '{{{spritesheet.escaped_image}}}';
41 | ${{spritesheet_info.strings.name_sprites}} ={{#each sprites}} ${{strings.name}}{{/each}};
42 | ${{spritesheet_info.strings.name}} = ${{spritesheet_info.strings.name_width}} ${{spritesheet_info.strings.name_height}} ${{spritesheet_info.strings.name_image}} ${{spritesheet_info.strings.name_sprites}};
43 | {{/block}}
44 |
45 | {{#block "sprite-functions-comment"}}
46 | {{#if options.functions}}
47 | /*
48 | The provided mixins are intended to be used with the array-like variables
49 |
50 | .icon-home {
51 | spriteWidth($icon_home)
52 | }
53 |
54 | .icon-email {
55 | sprite($icon_email)
56 | }
57 | */
58 | {{/if}}
59 | {{/block}}
60 | {{#block "sprite-functions"}}
61 | {{#if options.functions}}
62 | spriteWidth($sprite) {
63 | width: $sprite[4];
64 | }
65 |
66 | spriteHeight($sprite) {
67 | height: $sprite[5];
68 | }
69 |
70 | spritePosition($sprite) {
71 | background-position: $sprite[2] $sprite[3];
72 | }
73 |
74 | spriteImage($sprite) {
75 | background-image: url($sprite[8]);
76 | }
77 |
78 | sprite($sprite) {
79 | spriteImage($sprite)
80 | spritePosition($sprite)
81 | spriteWidth($sprite)
82 | spriteHeight($sprite)
83 | }
84 | {{/if}}
85 | {{/block}}
86 |
87 | {{#block "spritesheet-functions-comment"}}
88 | {{#if options.functions}}
89 | /*
90 | The `sprites` mixin generates identical output to the CSS template
91 | but can be overridden inside of Stylus
92 |
93 | This must be run when you have at least 2 sprites.
94 | If run with a single sprite, then there will be reference errors.
95 |
96 | sprites($spritesheet_sprites);
97 | */
98 | {{/if}}
99 | {{/block}}
100 | {{#block "spritesheet-functions"}}
101 | {{#if options.functions}}
102 | sprites($sprites) {
103 | for $sprite in $sprites {
104 | $sprite_name = $sprite[9];
105 | .{$sprite_name} {
106 | sprite($sprite);
107 | }
108 | }
109 | }
110 | {{/if}}
111 | {{/block}}
112 |
--------------------------------------------------------------------------------
/frontend/source/images/_sprite/diagram1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/_sprite/diagram1.png
--------------------------------------------------------------------------------
/frontend/source/images/_sprite/insert3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/_sprite/insert3.png
--------------------------------------------------------------------------------
/frontend/source/images/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/favicon.ico
--------------------------------------------------------------------------------
/frontend/source/images/main_sprite.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/main_sprite.png
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/blank.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/blank.gif
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/chosen-sprite.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/chosen-sprite.png
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/chosen-sprite@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/chosen-sprite@2x.png
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/fancybox_loading.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/fancybox_loading.gif
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/fancybox_loading@2x.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/fancybox_loading@2x.gif
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/fancybox_overlay.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/fancybox_overlay.png
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/fancybox_sprite.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/fancybox_sprite.png
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/fancybox_sprite@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/fancybox_sprite@2x.png
--------------------------------------------------------------------------------
/frontend/source/images/plugins/fancybox/glide-arrows.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/images/plugins/fancybox/glide-arrows.png
--------------------------------------------------------------------------------
/frontend/source/scripts/libs/utils.coffee:
--------------------------------------------------------------------------------
1 | ###
2 | Utils
3 | ###
4 |
5 | window.log = () ->
6 | enviroment = () ->
7 | return /(local\.|dev\.|localhost)/gi.test(document.domain)
8 |
9 | if (typeof (console) != "undefined" && enviroment())
10 | if (typeof (console.log.apply) != "undefined")
11 | console.log.apply(console, arguments)
12 | return
13 | else
14 | console.log(Array.prototype.slice.call(arguments))
15 | return
16 | return
17 |
18 |
19 | Cookie =
20 | create: (c, d, e) ->
21 | a = ""
22 | if e
23 | b = new Date()
24 | b.setTime b.getTime() + (e * 24 * 60 * 60 * 1000)
25 | a = "; expires=" + b.toGMTString()
26 | else
27 | a = ""
28 |
29 | #document.cookie = c + "=" + d + a + "; path=/application/busqueda/";
30 | document.cookie = c + "=" + d + a + "; path=/"
31 | this
32 |
33 | read: (b) ->
34 | e = b + "="
35 | a = document.cookie.split(";")
36 | d = 0
37 |
38 | while d < a.length
39 | f = a[d]
40 | f = f.substring(1, f.length) while f.charAt(0) is " "
41 | return f.substring(e.length, f.length) if f.indexOf(e) is 0
42 | d++
43 | null
44 |
45 | del: (a) ->
46 | @create a, "", -1
47 |
48 | ## Browser
49 | browser = (->
50 | a = ((d) ->
51 | d = d.toLowerCase()
52 | e = /(chrome)[ \/]([\w.]+)/.exec(d)
53 | g = /(webkit)[ \/]([\w.]+)/.exec(d)
54 | f = /(opera)(?:.*version|)[ \/]([\w.]+)/.exec(d)
55 | i = /(msie) ([\w.]+)/.exec(d)
56 | c = /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(d)
57 | h = e or g or f or i or d.indexOf("compatible") < 0 and c or []
58 | brw: h[1] or ""
59 | ver: h[2] or "0"
60 | )(navigator.userAgent)
61 | b = {}
62 | if a.brw
63 | b[a.brw] = true
64 | b.version = a.ver
65 | if b.chrome
66 | b.webkit = true
67 | else
68 | b.safari = true if b.webkit
69 | b
70 | )()
71 |
72 | if (browser.msie)
73 | #var ieNum = parseInt(browser.version);
74 | #$("html").addClass("lt-ie"+ ieNum);
75 | switch browser.version
76 | when '8.0'
77 | $('body').addClass('lt-ie8')
78 | break
79 | when '9.0'
80 | $('body').addClass('lt-ie9')
81 | break
82 |
83 | ##--------------------------------------------------------------------
84 | class Utils
85 |
86 | Utils.prototype.colorLog = (msg, color)->
87 | log("%c" + msg, "color:" + color + ";font-weight:bold")
88 | return
89 |
--------------------------------------------------------------------------------
/frontend/source/scripts/sections/home/inicio.coffee:
--------------------------------------------------------------------------------
1 | fn =
2 | greeting: (language)->
3 | languages =
4 | 'es': 'Hola'
5 | 'en': 'Hello'
6 | 'fr': 'Bonjour'
7 | return languages[language]
8 |
9 |
--------------------------------------------------------------------------------
/frontend/source/styles/_config/variables.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Config
3 | * @class Config
4 | */
5 |
6 | /* Paths */
7 | $imgPath = '/images/'
8 | $fontPath = '/fonts/'
9 |
10 | /* font family variables */
11 | $familyDefault = 'Helvetica' ,'arial', 'sans-serif'
12 | $familyPrimary = 'IndyPimp' ,'arial', 'sans-serif'
13 | $basefont = 14px
14 | $tabletfont = 13px
15 | $mobilefont = 15px
16 |
17 | $debug = false
18 |
19 | /* Color variables */
20 | $green = #6ad934
21 |
22 | /* Disableds*/
23 |
24 |
25 |
26 |
27 | /* Layout variables */
28 | $wrapperWidth = 960px
29 | $gutterWrapper = 0px
30 | $wrapperRupture = $wrapperWidth - $gutterWrapper*2
31 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/includes/animations.styl:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/frontend-labs/flux/6b32fdbacc1cdb55c8706be5001b27750a93aedb/frontend/source/styles/_partials/includes/animations.styl
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/includes/buttons.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Buttons
3 | * @module buttons
4 | */
5 |
6 | .btn
7 | border none
8 | border-radius 4px
9 | color black
10 | display inline-block
11 | font-family $familyPrimary
12 | line-height 36px
13 | padding 0 13px
14 | position relative
15 | text-align center
16 | vertical-align top
17 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/includes/forms.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Forms
3 | * @module forms
4 | */
5 |
6 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/includes/icons.styl:
--------------------------------------------------------------------------------
1 | .icon
2 | -webkit-font-smoothing antialiased
3 | display inline-block
4 | font-family "Icons-webfont"
5 | font-size inherit
6 | font-style normal
7 | font-variant normal
8 | font-weight normal
9 | line-height 1
10 | text-decoration inherit
11 | text-transform none
12 | vertical-align middle
13 |
14 |
15 | .icon_calendar:before
16 | content "\"
17 |
18 | .icon_pointer:before
19 | content "\"
20 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/includes/normalize.styl:
--------------------------------------------------------------------------------
1 | /* normalize.css v3.0.2 | MIT License | git.io/normalize */
2 |
3 | /**
4 | * 1. Set default font family to sans-serif.
5 | * 2. Prevent iOS text size adjust after orientation change, without disabling
6 | * user zoom.
7 | */
8 |
9 | html
10 | font-family: sans-serif // 1
11 | -ms-text-size-adjust: 100% // 2
12 | -webkit-text-size-adjust: 100% // 2
13 |
14 | /**
15 | * Remove default margin.
16 | */
17 |
18 | body
19 | margin: 0
20 |
21 | /* HTML5 display definitions
22 | ========================================================================== */
23 |
24 | /**
25 | * Correct `block` display not defined for any HTML5 element in IE 8/9.
26 | * Correct `block` display not defined for `details` or `summary` in IE 10/11
27 | * and Firefox.
28 | * Correct `block` display not defined for `main` in IE 11.
29 | */
30 |
31 | article,
32 | aside,
33 | details,
34 | figcaption,
35 | figure,
36 | footer,
37 | header,
38 | hgroup,
39 | main,
40 | menu,
41 | nav,
42 | section,
43 | summary
44 | display: block
45 |
46 | /**
47 | * 1. Correct `inline-block` display not defined in IE 8/9.
48 | * 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.
49 | */
50 |
51 | audio,
52 | canvas,
53 | progress,
54 | video
55 | display: inline-block // 1
56 | vertical-align: baseline // 2
57 |
58 | /**
59 | * Prevent modern browsers from displaying `audio` without controls.
60 | * Remove excess height in iOS 5 devices.
61 | */
62 |
63 | audio:not([controls])
64 | display: none
65 | height: 0
66 |
67 | /**
68 | * Address `[hidden]` styling not present in IE 8/9/10.
69 | * Hide the `template` element in IE, Safari, and Firefox < 22.
70 | */
71 |
72 | [hidden],
73 | template
74 | display: none
75 |
76 | /* Links
77 | ========================================================================== */
78 |
79 | /**
80 | * 1. Remove the gray background color from active links in IE 10.
81 | * 2. Improve readability when focused and also mouse hovered in all browsers.
82 | */
83 |
84 | a
85 | background-color: transparent // 1
86 | &:active,
87 | &:hover
88 | outline: 0 // 2
89 |
90 | /* Text-level semantics
91 | ========================================================================== */
92 |
93 | /**
94 | * Address styling not present in IE 8/9/10/11, Safari, and Chrome.
95 | */
96 |
97 | abbr[title]
98 | border-bottom: 1px dotted
99 |
100 | /**
101 | * Address style set to `bolder` in Firefox 4+, Safari, and Chrome.
102 | */
103 |
104 | b,
105 | strong
106 | font-weight: bold
107 |
108 | /**
109 | * Address styling not present in Safari and Chrome.
110 | */
111 |
112 | dfn
113 | font-style: italic
114 |
115 | /**
116 | * Address variable `h1` font-size and margin within `section` and `article`
117 | * contexts in Firefox 4+, Safari, and Chrome.
118 | */
119 |
120 | h1
121 | font-size: 2em
122 | margin: 0.67em 0
123 |
124 | /**
125 | * Address styling not present in IE 8/9.
126 | */
127 |
128 | mark
129 | background: #ff0
130 | color: #000
131 |
132 | /**
133 | * Address inconsistent and variable font size in all browsers.
134 | */
135 |
136 | small
137 | font-size: 80%
138 |
139 | /**
140 | * Prevent `sub` and `sup` affecting `line-height` in all browsers.
141 | */
142 |
143 | sub,
144 | sup
145 | font-size: 75%
146 | line-height: 0
147 | position: relative
148 | vertical-align: baseline
149 |
150 | sup
151 | top: -0.5em
152 |
153 | sub
154 | bottom: -0.25em
155 |
156 | /* Embedded content
157 | ========================================================================== */
158 |
159 | /**
160 | * Remove border when inside `a` element in IE 8/9/10.
161 | */
162 |
163 | img
164 | border: 0
165 |
166 | /**
167 | * Correct overflow not hidden in IE 9/10/11.
168 | */
169 |
170 | svg:not(:root)
171 | overflow: hidden
172 |
173 | /* Grouping content
174 | ========================================================================== */
175 |
176 | /**
177 | * Address margin not present in IE 8/9 and Safari.
178 | */
179 |
180 | figure
181 | margin: 1em 40px
182 |
183 | /**
184 | * Address differences between Firefox and other browsers.
185 | */
186 |
187 | hr
188 | -moz-box-sizing: content-box
189 | box-sizing: content-box
190 | height: 0
191 |
192 | /**
193 | * Contain overflow in all browsers.
194 | */
195 |
196 | pre
197 | overflow: auto
198 |
199 | /**
200 | * Address odd `em`-unit font size rendering in all browsers.
201 | */
202 |
203 | code,
204 | kbd,
205 | pre,
206 | samp
207 | font-family: monospace, monospace
208 | font-size: 1em
209 |
210 | /* Forms
211 | ========================================================================== */
212 |
213 | /**
214 | * Known limitation: by default, Chrome and Safari on OS X allow very limited
215 | * styling of `select`, unless a `border` property is set.
216 | */
217 |
218 | /**
219 | * 1. Correct color not being inherited.
220 | * Known issue: affects color of disabled elements.
221 | * 2. Correct font properties not being inherited.
222 | * 3. Address margins set differently in Firefox 4+, Safari, and Chrome.
223 | */
224 |
225 | button,
226 | input,
227 | optgroup,
228 | select,
229 | textarea
230 | color: inherit // 1
231 | font: inherit // 2
232 | margin: 0 // 3
233 |
234 | /**
235 | * Address `overflow` set to `hidden` in IE 8/9/10/11.
236 | */
237 |
238 | button
239 | overflow: visible
240 |
241 | /**
242 | * Address inconsistent `text-transform` inheritance for `button` and `select`.
243 | * All other form control elements do not inherit `text-transform` values.
244 | * Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera
245 | * Correct `select` style inheritance in Firefox.
246 | */
247 |
248 | button,
249 | select
250 | text-transform: none
251 |
252 | /**
253 | * 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
254 | * and `video` controls.
255 | * 2. Correct inability to style clickable `input` types in iOS.
256 | * 3. Improve usability and consistency of cursor style between image-type
257 | * `input` and others.
258 | */
259 |
260 | button,
261 | html input[type="button"], // 1
262 | input[type="reset"],
263 | input[type="submit"]
264 | -webkit-appearance: button // 2
265 | cursor: pointer // 3
266 |
267 | /**
268 | * Re-set default cursor for disabled elements.
269 | */
270 |
271 | button[disabled],
272 | html input[disabled]
273 | cursor: default
274 |
275 | /**
276 | * Remove inner padding and border in Firefox 4+.
277 | */
278 |
279 | button::-moz-focus-inner,
280 | input::-moz-focus-inner
281 | border: 0
282 | padding: 0
283 |
284 | /**
285 | * Address Firefox 4+ setting `line-height` on `input` using `!important` in
286 | * the UA stylesheet.
287 | */
288 |
289 | input
290 | line-height: normal
291 |
292 | /**
293 | * It's recommended that you don't attempt to style these elements.
294 | * Firefox's implementation doesn't respect box-sizing, padding, or width.
295 | *
296 | * 1. Address box sizing set to `content-box` in IE 8/9/10.
297 | * 2. Remove excess padding in IE 8/9/10.
298 | */
299 |
300 | input[type="checkbox"],
301 | input[type="radio"]
302 | box-sizing: border-box // 1
303 | padding: 0 // 2
304 |
305 | /**
306 | * Fix the cursor style for Chrome's increment/decrement buttons. For certain
307 | * `font-size` values of the `input`, it causes the cursor style of the
308 | * decrement button to change from `default` to `text`.
309 | */
310 |
311 | input[type="number"]::-webkit-inner-spin-button,
312 | input[type="number"]::-webkit-outer-spin-button
313 | height: auto
314 |
315 | /**
316 | * 1. Address `appearance` set to `searchfield` in Safari and Chrome.
317 | * 2. Address `box-sizing` set to `border-box` in Safari and Chrome
318 | * (include `-moz` to future-proof).
319 | */
320 |
321 | input[type="search"]
322 | -webkit-appearance: textfield // 1
323 | -moz-box-sizing: content-box
324 | -webkit-box-sizing: content-box // 2
325 | box-sizing: content-box
326 |
327 | /**
328 | * Remove inner padding and search cancel button in Safari and Chrome on OS X.
329 | * Safari (but not Chrome) clips the cancel button when the search input has
330 | * padding (and `textfield` appearance).
331 | */
332 |
333 | input[type="search"]::-webkit-search-cancel-button,
334 | input[type="search"]::-webkit-search-decoration
335 | -webkit-appearance: none
336 |
337 | /**
338 | * Define consistent border, margin, and padding.
339 | */
340 |
341 | fieldset
342 | border 0
343 | margin 0
344 | padding 0
345 |
346 | /**
347 | * 1. Correct `color` not being inherited in IE 8/9/10/11.
348 | * 2. Remove padding so people aren't caught out if they zero out fieldsets.
349 | */
350 |
351 | legend
352 | border: 0 // 1
353 | padding: 0 // 2
354 |
355 | /**
356 | * Remove default vertical scrollbar in IE 8/9/10/11.
357 | */
358 |
359 | textarea
360 | overflow: auto
361 |
362 | /**
363 | * Don't inherit the `font-weight` (applied by a rule above).
364 | * NOTE: the default cannot safely be changed in Chrome and Safari on OS X.
365 | */
366 |
367 | optgroup
368 | font-weight: bold
369 |
370 | /* Tables
371 | ========================================================================== */
372 |
373 | /**
374 | * Remove most spacing between table cells.
375 | */
376 |
377 | table
378 | border-collapse: collapse
379 | border-spacing: 0
380 |
381 | td,
382 | th
383 | padding: 0
384 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/includes/utilities.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Resources
3 | * @module resources
4 | */
5 |
6 | /*
7 | * --------------------------------------
8 | * Main
9 | * --------------------------------------
10 | */
11 | *
12 | box-sizing border-box
13 | -webkit-box-sizing border-box
14 | -moz-box-sizing border-box
15 |
16 | html
17 | font-size $basefont
18 | min-width $wrapperWidth + 20px
19 |
20 | body
21 | font-family $familyDefault
22 | margin 0
23 | padding 0
24 | -webkit-text-size-adjust 100%
25 |
26 | /*
27 | * --------------------------------------
28 | * Aligns Classes
29 | * --------------------------------------
30 | */
31 | .align_right
32 | text-align right
33 | .align_left
34 | text-align left
35 | .align_center
36 | text-align center
37 |
38 | /*
39 | * --------------------------------------
40 | * Margins Classes
41 | * --------------------------------------
42 | */
43 | .mt10
44 | margin-top 10px
45 | .mt20
46 | margin-top 20px
47 | .mb10
48 | margin-bottom 10px
49 | .mb20
50 | margin-bottom 20px
51 | .mb40
52 | margin-bottom 40px
53 |
54 | /*
55 | * --------------------------------------
56 | * Contents Classes
57 | * --------------------------------------
58 | */
59 | .hide
60 | display none
61 | .center_box
62 | position relative
63 | center($wrapperWidth)
64 | padding 0 $gutterWrapper
65 | .center_image
66 | position relative
67 | img
68 | bottom 0
69 | left 0
70 | margin auto
71 | position absolute
72 | right 0
73 | top 0
74 | .row
75 | cf()
76 |
77 | /*
78 | * --------------------------------------
79 | * Others Classes
80 | * --------------------------------------
81 | */
82 | .rotate180
83 | transform rotate(180deg)
84 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/layout/footer.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Layout
3 | * @module layout
4 | * @class footer
5 | */
6 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/layout/header.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Layout
3 | * @module layout
4 | * @class header
5 | */
6 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/mixins/main_sprite.styl:
--------------------------------------------------------------------------------
1 | /*
2 | Stylus variables are information about icon's compiled state, stored under its original file name
3 |
4 | .icon-home {
5 | width: $icon_home_width;
6 | }
7 |
8 | The large array-like variables contain all information about a single icon
9 | $icon_home = x y offset_x offset_y width height total_width total_height image_path;
10 |
11 | At the bottom of this section, we provide information about the spritesheet itself
12 | $spritesheet = width height image $spritesheet_sprites;
13 | */
14 | $diagram1_name = 'diagram1';
15 | $diagram1_x = 0px;
16 | $diagram1_y = 0px;
17 | $diagram1_offset_x = 0px;
18 | $diagram1_offset_y = 0px;
19 | $diagram1_width = 64px;
20 | $diagram1_height = 64px;
21 | $diagram1_total_width = 128px;
22 | $diagram1_total_height = 64px;
23 | $diagram1_image = $imgPath + 'main_sprite.png';
24 | $diagram1 = $diagram1_x $diagram1_y $diagram1_offset_x $diagram1_offset_y $diagram1_width $diagram1_height $diagram1_total_width $diagram1_total_height $diagram1_image $diagram1_name;
25 | $insert3_name = 'insert3';
26 | $insert3_x = 64px;
27 | $insert3_y = 0px;
28 | $insert3_offset_x = -64px;
29 | $insert3_offset_y = 0px;
30 | $insert3_width = 64px;
31 | $insert3_height = 64px;
32 | $insert3_total_width = 128px;
33 | $insert3_total_height = 64px;
34 | $insert3_image = $imgPath + 'main_sprite.png';
35 | $insert3 = $insert3_x $insert3_y $insert3_offset_x $insert3_offset_y $insert3_width $insert3_height $insert3_total_width $insert3_total_height $insert3_image $insert3_name;
36 | $spritesheet_width = 128px;
37 | $spritesheet_height = 64px;
38 | $spritesheet_image = $imgPath + 'main_sprite.png';
39 | $spritesheet_sprites = $diagram1 $insert3;
40 | $spritesheet = $spritesheet_width $spritesheet_height $spritesheet_image $spritesheet_sprites;
41 |
42 | /*
43 | The provided mixins are intended to be used with the array-like variables
44 |
45 | .icon-home {
46 | spriteWidth($icon_home)
47 | }
48 |
49 | .icon-email {
50 | sprite($icon_email)
51 | }
52 | */
53 | spriteWidth($sprite) {
54 | width: $sprite[4];
55 | }
56 |
57 | spriteHeight($sprite) {
58 | height: $sprite[5];
59 | }
60 |
61 | spritePosition($sprite) {
62 | background-position: $sprite[2] $sprite[3];
63 | }
64 |
65 | spriteImage($sprite) {
66 | background-image: url($sprite[8]);
67 | }
68 |
69 | sprite($sprite) {
70 | spriteImage($sprite)
71 | spritePosition($sprite)
72 | spriteWidth($sprite)
73 | spriteHeight($sprite)
74 | }
75 |
76 | /*
77 | The `sprites` mixin generates identical output to the CSS template
78 | but can be overridden inside of Stylus
79 |
80 | This must be run when you have at least 2 sprites.
81 | If run with a single sprite, then there will be reference errors.
82 |
83 | sprites($spritesheet_sprites);
84 | */
85 | sprites($sprites) {
86 | for $sprite in $sprites {
87 | $sprite_name = $sprite[9];
88 | .{$sprite_name} {
89 | sprite($sprite);
90 | }
91 | }
92 | }
93 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/mixins/mixins.styl:
--------------------------------------------------------------------------------
1 |
2 | /**
3 | * Mixins
4 | * @class Mixins
5 | */
6 |
7 |
8 | /* Units conversion */
9 | // example usage
10 | // em(20px)
11 | // em(16px, 20px) // Optional second parameter: redefines basefont size
12 |
13 | font_em(size, parentFontSize = 0)
14 | if parentFontSize == 0
15 | font-size round(( size / $basefont )em , 3)
16 | else
17 | font-size round(( size / parentFontSize )em , 3)
18 |
19 | rem_tmp($list)
20 | $max = length(arguments)
21 | for $i in (0..$max - 1)
22 | $list[$i] = round(( arguments[$i] / $basefont )rem , 3)
23 | return $list
24 |
25 | rem($list)
26 | $max = length(arguments)
27 | for $i in (0..$max - 1)
28 | $list[$i] = arguments[$i]
29 | return $list
30 |
31 | px_to_rem_font(size1, size2, family)
32 | //s1 = round(( size1 / $basefont )rem , 3)
33 | //s2 = round(( size2 / $basefont )rem , 3)
34 | //return s1\/s2 family
35 | return (size1)px \/ (size2)px family
36 |
37 |
38 | pxper(size, parent = $wrapperWidth)
39 | return round((size / parent * 100)%, 2)
40 |
41 |
--------------------------------------------------------------------------------
/frontend/source/styles/_partials/plugins/fancybox.styl:
--------------------------------------------------------------------------------
1 | .fancybox-wrap,
2 | .fancybox-skin,
3 | .fancybox-outer,
4 | .fancybox-inner,
5 | .fancybox-image,
6 | .fancybox-wrap iframe,
7 | .fancybox-wrap object,
8 | .fancybox-nav,
9 | .fancybox-nav span,
10 | .fancybox-tmp
11 | padding 0
12 | margin 0
13 | border 0
14 | outline none
15 | vertical-align top
16 |
17 | .fancybox-wrap
18 | position absolute
19 | top 0
20 | left 0
21 | z-index 8020
22 |
23 | .fancybox-skin
24 | position relative
25 | background #fff
26 | color #444
27 | text-shadow none
28 | border-radius 4px
29 |
30 | .fancybox-opened
31 | z-index 8030
32 | .fancybox-title
33 | visibility visible
34 |
35 | .fancybox-outer, .fancybox-inner
36 | position relative
37 |
38 | .fancybox-inner
39 | overflow hidden
40 |
41 | .fancybox-type-iframe
42 | .fancybox-inner
43 | -webkit-overflow-scrolling touch
44 |
45 | .fancybox-error
46 | color #444
47 | font 14px\/20px 'Helvetica Neue',Helvetica,Arial,sans-serif
48 | margin 0
49 | padding 15px
50 | white-space nowrap
51 |
52 | .fancybox-image, .fancybox-iframe
53 | display block
54 | width 100%
55 | height 100%
56 |
57 | .fancybox-image
58 | max-width 100%
59 | max-height 100%
60 |
61 | #fancybox-loading
62 | position fixed
63 | top 50%
64 | left 50%
65 | margin-top -22
66 | margin-left -22
67 | opacity 0.8
68 | cursor pointer
69 | z-index 8060
70 | background-color #fff
71 | border-radius 50%
72 | box-shadow 0 2px 6px rgba(0, 0, 0, 0.1)
73 | div
74 | width 44px
75 | height 44px
76 | background url($imgPath+'plugins/fancybox_loading.gif') center center no-repeat
77 | background-size 24px 24px
78 | border-radius 50%
79 | .fancybox-close
80 | position absolute
81 | sprite($close_modal)
82 | cursor pointer
83 | z-index 8040
84 | top 7px
85 | right 7px
86 | &:hover
87 | opacity 0.7
88 | .fancybox-nav
89 | position absolute
90 | top 0
91 | width 40%
92 | height 100%
93 | cursor pointer
94 | text-decoration none
95 | background transparent url($imgPath+'plugins/blank.gif')
96 | -webkit-tap-highlight-color rgba(0,0,0,0)
97 | z-index 8040
98 | span
99 | position absolute
100 | top 50%
101 | margin-top -18px
102 | cursor pointer
103 | z-index 8040
104 | visibility hidden
105 | &:hover
106 | span
107 | visibility visible
108 |
109 | .fancybox-prev
110 | left 0
111 | span
112 | left 10px
113 | sprite($ico_arrow_left)
114 |
115 | .fancybox-next
116 | right 0
117 | span
118 | right 10px
119 | sprite($ico_arrow_right)
120 |
121 | .fancybox-tmp
122 | position absolute
123 | top -99999px
124 | left -99999px
125 | visibility hidden
126 | max-width 99999px
127 | max-height 99999px
128 | overflow visible !important
129 |
130 | .fancybox-lock
131 | overflow hidden !important
132 | width auto
133 | body
134 | overflow hidden !important
135 | .fancybox-overlay
136 | overflow auto
137 | overflow-y scroll
138 |
139 | .fancybox-lock-test
140 | overflow-y hidden !important
141 |
142 | .fancybox-overlay
143 | position absolute
144 | top 0
145 | left 0
146 | overflow hidden
147 | display none
148 | z-index 8010
149 | background url($imgPath+'plugins/fancybox_overlay.png')
150 |
151 | .fancybox-overlay-fixed
152 | position fixed
153 | bottom 0
154 | right 0
155 |
156 | .fancybox-title
157 | visibility hidden
158 | font normal 13px\/20px 'Helvetica Neue',Helvetica,Arial,sans-serif
159 | position relative
160 | text-shadow none
161 | z-index 8050
162 |
163 | .fancybox-title-float-wrap
164 | position absolute
165 | bottom 0
166 | right 50%
167 | margin-bottom -35px
168 | z-index 8050
169 | text-align center
170 | .child
171 | display inline-block
172 | margin-right -100%
173 | padding 2px 20px
174 | background transparent
175 | background rgba(0, 0, 0, 0.8)
176 | border-radius 15px
177 | text-shadow 0 1px 2px #222
178 | color #FFF
179 | font-weight bold
180 | line-height 24px
181 | white-space nowrap
182 |
183 | .fancybox-title-outside-wrap
184 | position relative
185 | margin-top 10px
186 | color #fff
187 |
188 | .fancybox-title-inside-wrap
189 | padding-top 10px
190 |
191 | .fancybox-title-over-wrap
192 | position absolute
193 | bottom 0
194 | left 0
195 | color #fff
196 | padding 10px
197 | background #000
198 | background rgba(0, 0, 0, .8)
199 |
200 | @media only screen and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min--moz-device-pixel-ratio: 1.5), only screen and (min-device-pixel-ratio: 1.5)
201 | #fancybox-loading, .fancybox-prev span, .fancybox-next span
202 | background-image url($imgPath+'plugins/fancybox_sprite@2x.png')
203 | background-size 44px 152px
--------------------------------------------------------------------------------
/frontend/source/styles/layout/fonts.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Font Styles
3 | * @module fonts
4 | **/
5 | @require '../_config/variables'
6 |
7 | @font-face
8 | font-family "Helvetica"
9 | src url($fontPath + "Helvetica/Helvetica-webfont.eot")
10 | src url($fontPath + "Helvetica/Helvetica-webfont.eot?#iefix") format("embedded-opentype"), \
11 | url($fontPath + "Helvetica/Helvetica-webfont.woff") format("woff"), \
12 | url($fontPath + "Helvetica/Helvetica-webfont.ttf") format("truetype"), \
13 | url($fontPath + "Helvetica/Helvetica-webfont.svg#Helvetica") format("svg");
14 | font-style normal
15 | font-weight normal
16 |
17 | @font-face
18 | font-family "Icons"
19 | src url($fontPath + "Icons/Icons-webfont.eot")
20 | src url($fontPath + "Icons/Icons-webfont.eot?#iefix") format("embedded-opentype"), \
21 | url($fontPath + "Icons/Icons-webfont.woff") format("woff"), \
22 | url($fontPath + "Icons/Icons-webfont.ttf") format("truetype"), \
23 | url($fontPath + "Icons/Icons-webfont.svg#Icons") format("svg");
24 | font-style normal
25 | font-weight normal
26 |
27 | @font-face
28 | font-family "IndyPimp"
29 | src url($fontPath + "IndyPimp/IndyPimp-webfont.eot")
30 | src url($fontPath + "IndyPimp/IndyPimp-webfont.eot?#iefix") format("embedded-opentype"), \
31 | url($fontPath + "IndyPimp/IndyPimp-webfont.woff") format("woff"), \
32 | url($fontPath + "IndyPimp/IndyPimp-webfont.ttf") format("truetype"), \
33 | url($fontPath + "IndyPimp/IndyPimp-webfont.svg#IndyPimp") format("svg");
34 | font-style normal
35 | font-weight normal
36 |
--------------------------------------------------------------------------------
/frontend/source/styles/layout/ie.styl:
--------------------------------------------------------------------------------
1 | /*
2 | * Solo para version IE
3 | * @module ie
4 | */
5 | @require '../_config/variables'
6 | @require '../_partials/mixins/*'
7 |
8 | //.lt-ie8
9 | //.lt-ie9
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/frontend/source/styles/layout/layout.styl:
--------------------------------------------------------------------------------
1 | /*
2 | *
3 | * @module layout
4 | */
5 |
6 | @require '../_config/variables'
7 | @require '../_partials/includes/normalize'
8 | @require '../_partials/includes/utilities'
9 | @require '../_partials/includes/animations'
10 | @require '../_partials/includes/buttons'
11 | @require '../_partials/includes/icons'
12 | @require '../_partials/includes/forms'
13 | @require '../_partials/layout/*'
14 | @require '../_partials/mixins/*'
15 | @require '../_partials/plugins/*'
16 |
--------------------------------------------------------------------------------
/frontend/source/styles/sections/index.styl:
--------------------------------------------------------------------------------
1 | @require '../_config/variables'
2 | @require '../_partials/mixins/*'
3 |
4 | body
5 | background #404041
6 | font-family 'Roboto', cursive
7 |
8 | .welcome
9 | position absolute
10 | top 0
11 | bottom 0
12 | left 0
13 | right 0
14 | width 300px
15 | height 300px
16 | margin auto
17 |
18 | h1
19 | border-top 1px solid #696969
20 | text-align center
21 | color #9B9B9B
22 | font-weight normal
--------------------------------------------------------------------------------
/frontend/source/views/_config/variables.jade:
--------------------------------------------------------------------------------
1 | - var page = {}
2 | - page.charset = 'utf-8'
3 | - page.lang = 'es'
4 | - page.url = baseUrl
5 | - page.static_url = staticUrl
6 | - page.elements_url = elementUrl
7 | - page.title = 'Welcome'
8 | - page.description = ''
9 | - page.keywords = ''
10 | - page.author = 'FrontEnd Labs'
11 | - page.name = 'Name of page'
12 | - page.viewport = 'width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0'
13 | - page.robots = 'index,follow'
14 | - page.version = '?' + version
15 | - page.img = page.static_url + 'img/logo_fb.png' + page.version
16 | - page.favicon = page.static_url + 'favicon.ico' + page.version
17 |
18 | - page.og = {}
19 | - page.og.title = 'myPage.com'
20 | - page.og.type = baseUrl
21 | - page.og.image_width = '250'
22 | - page.og.image_height = '250'
23 | - page.og.image_type = 'image/jpg'
24 | - page.og.image = page.static_url + 'img/logo_fb.png' + page.version
25 |
26 | - page.dc = {}
27 | - page.dc.contributor = 'myPage.com'
28 | - page.dc.creator = 'myPage.com'
29 | - page.dc.publisher = 'Publisher'
30 |
31 | - page.geo = {}
32 | - page.geo.placename = 'Cercado de Lima'
33 | - page.geo.position = '-12.0478;-77.0622'
34 | - page.geo.region = 'PE-LIM'
35 | - page.geo.ICBM = '-12.0478, -77.0622'
36 |
37 | - page.ga = 'UA-111111'
--------------------------------------------------------------------------------
/frontend/source/views/_partials/includes/footer_scripts.jade:
--------------------------------------------------------------------------------
1 |
2 | script(src="#{page.static_url}js/libs/jquery/dist/jquery.min.js#{page.version}", type="text/javascript")
3 | script(src="#{page.static_url}js/libs/utils.js#{page.version}", type="text/javascript")
4 | script(src="#{page.static_url}js/sections/home/home.js#{page.version}", type="text/javascript")
--------------------------------------------------------------------------------
/frontend/source/views/_partials/includes/head.jade:
--------------------------------------------------------------------------------
1 | head
2 | meta(charset='#{page.charset}')
3 | meta(http-equiv='X-UA-Compatible', content='IE=edge,chrome=1')
4 | meta(name='language', content='#{page.lang}')
5 | title #{page.title}
6 | meta(name='title', content='#{page.title}')
7 | meta(name='description', content='#{page.description}')
8 | meta(name='author', content='#{page.author}')
9 | meta(name='DC.Title', content='#{page.title}')
10 | meta(name='DC.Contributor', content='#{page.dc.contributor}')
11 | meta(name='DC.Creator', content='#{page.dc.creator}')
12 | meta(name='DC.Description', content='#{page.description}')
13 | meta(name='DC.Language', content='#{page.lang}')
14 | meta(name='DC.Publisher', content='#{page.dc.publisher}')
15 | meta(name='geo.placename', content='#{page.geo.placename}')
16 | meta(name='geo.position', content='#{page.geo.position}')
17 | meta(name='geo.region', content='#{page.geo.region}')
18 | meta(name='ICBM', content='#{page.geo.ICBM}')
19 | meta(name='viewport', content='#{page.viewport}')
20 | meta(name='robots', content='#{page.robots}')
21 | meta(name='keywords', content='#{page.keywords}')
22 | meta(property='og:description', content='#{page.description}')
23 | meta(property='og:image', content='#{page.og.image}')
24 | meta(property='og:image:height', content='#{page.og.image_height}')
25 | meta(property='og:image:type', content='#{page.og.image_type}')
26 | meta(property='og:image:width', content='#{page.og.image_width}')
27 | meta(property='og:site_name', content='#{page.name}')
28 | meta(property='og:title', content='#{page.og.title}')
29 | meta(property='og:type', content='#{page.og.type}')
30 | meta(property='og:url', content='#{page.url}')
31 |
32 | link(href='#{page.static_url}css/layout/fonts.css#{page.version}', media='all', rel='stylesheet', type='text/css')
33 | link(href='#{page.static_url}css/layout/layout.css#{page.version}', media='all', rel='stylesheet', type='text/css')
34 | link(href='#{page.static_url}css/sections/#{section}.css#{page.version}', media='all', rel='stylesheet', type='text/css')
35 |
36 | link(href='#{page.static_url}images/favicon.ico#{page.version}', rel='icon', type='image/vnd.microsoft.icon')
37 | link(href='#{page.static_url}images/favicon.ico#{page.version}', rel='shortcut icon', type='image/vnd.microsoft.icon')
38 | link(href='#{page.static_url}images/favicon.ico#{page.version}', rel='shortcut icon', type='image/x-icon')
39 | link(href='#{page.og.image}', rel='image_src', type='image/jpeg')
40 |
41 | link(href='http://fonts.googleapis.com/css?family=Roboto:100', rel='stylesheet', type='text/css')
42 | +ie('if lte IE 9')
43 | link(href='#{page.static_url}css/ie/ie.css#{page.version}', media='all', rel='stylesheet', type='text/css')
44 | script(src="#{page.static_url}js/libs/selectivizr/selectivizr.js#{page.version}")
45 | script(src="#{page.static_url}js/libs/html5shiv/dist/html5shiv.min.js#{page.version}")
46 |
--------------------------------------------------------------------------------
/frontend/source/views/_partials/includes/head_scripts.jade:
--------------------------------------------------------------------------------
1 | script(type="text/javascript").
2 | (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
3 | (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
4 | m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
5 | })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
6 | ga('create', '#{page.ga}', 'auto');
7 | ga('require', 'displayfeatures');
8 | ga('send', 'pageview');
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/frontend/source/views/_partials/layout/footer.jade:
--------------------------------------------------------------------------------
1 | footer
2 |
3 |
--------------------------------------------------------------------------------
/frontend/source/views/_partials/layout/header.jade:
--------------------------------------------------------------------------------
1 | header
2 |
3 |
4 |
--------------------------------------------------------------------------------
/frontend/source/views/_partials/mixins/ie.jade:
--------------------------------------------------------------------------------
1 | //-
2 | Mixins for IE
3 |
4 | mixin ie(condition, content)
5 | |
8 |
9 | mixin html(condition, content)
10 | - if (typeof condition !== "undefined"){
11 | +ie(condition)
12 | html(class="#{content}", lang="#{page.lang}", xmlns:og="http://ogp.me/ns#", xmlns:fb="http://ogp.me/ns/fb#")
13 | - }
14 |
15 | mixin htmlIe()
16 | +html('if IE 7', 'ie7')
17 | +html('if IE 8', 'ie8')
18 | +html('if IE 9', 'ie9')
19 |
--------------------------------------------------------------------------------
/frontend/source/views/_partials/mixins/mixins.jade:
--------------------------------------------------------------------------------
1 | //-
2 | Mixins
3 |
4 | include ie.jade
5 |
--------------------------------------------------------------------------------
/frontend/source/views/_partials/views/home/index.jade:
--------------------------------------------------------------------------------
1 | div.welcome
2 | svg(version="1.1", xmlns="http://www.w3.org/2000/svg", xmlns:xlink="http://www.w3.org/1999/xlink", x="0px", y="0px", width="300px", height="300px", viewbox="0 0 100 100", enable-background="new 0 0 100 100", xml:space="preserve")
3 | g
4 | path(fill="#FFFFFF", d="M68.076,68.561c0.135-0.496,0.246-1.004,0.346-1.516c-0.541,0.41-1.092,0.826-1.648,1.248\
5 | C67.268,68.293,67.701,68.391,68.076,68.561z")
6 | path(fill="#FFFFFF", d="M63.832,70.983c0.02-0.187,0.055-0.37,0.104-0.546c-1.412,1.063-2.797,2.108-4.068,3.069\
7 | C61.199,72.678,62.492,71.792,63.832,70.983z")
8 | path(fill="#FFFFFF", d="M63.936,70.438c0.943-0.713,1.898-1.433,2.838-2.145c-0.002,0-0.002,0-0.002,0\
9 | C65.195,68.293,64.256,69.266,63.936,70.438z")
10 | g
11 | g
12 | circle(fill="#DBD83D", cx="43.619", cy="11.122", r="2.791")
13 | circle(fill="#DBD83D", cx="49.922", cy="11.454", r="1.822")
14 | circle(fill="#DBD83D", cx="49.922", cy="19.102", r="4.188")
15 | g
16 | polygon(fill="#2FAEC8", points="39.641,24.271 43.514,24.271 43.514,29.516 ")
17 | path(fill="#2FAEC8", d="M43.168,41.048c-0.088,0.018-0.248,0-0.23-0.109c-0.285-4.908-0.857-11.445-1.352-16.36\
18 | c-0.021-0.103-0.01-0.158,0.119-0.184c1.25-0.264,3.09,0.006,3.053,0.571c-0.076,4.137-0.117,9.693-0.473,15.634\
19 | c-0.004,0.132-0.686,0.355-1.074,0.438L43.168,41.048z")
20 | polygon(fill="#2FAEC8", points="61.295,24.271 57.424,24.271 57.424,29.516 ")
21 | path(fill="#2FAEC8", d="M57.725,41.039c-0.389-0.082-1.072-0.305-1.074-0.438c-0.357-5.941-0.396-11.498-0.471-15.634\
22 | c-0.041-0.565,1.801-0.835,3.053-0.571c0.129,0.026,0.139,0.082,0.117,0.184c-0.492,4.915-1.068,11.452-1.352,16.36\
23 | c0.018,0.109-0.145,0.127-0.229,0.109L57.725,41.039z")
24 | path(fill="#DBD83D", d="M46.801,75.41c2.355-0.162,4.551-0.266,6.662-0.309c0.074-0.156,0.176-0.298,0.303-0.423\
25 | c2.932-3.33,8.059-9.6,11.754-14.236c-1.033-1.419-2.49-3.381-4.266-5.743c-0.668,0.203-1.393,0.445-2.152,0.697\
26 | c-4.066,1.346-9.639,3.193-17.334,3.193c-1.809,0-3.672-0.104-5.545-0.311c-0.586,0.791-1.125,1.522-1.592,2.163\
27 | c3.693,4.632,8.816,10.902,11.795,14.278C46.555,74.848,46.727,75.078,46.801,75.41z")
28 | g
29 | path(fill="#2FAEC8", d="M22.961,60.988c0-0.21,0.105-0.625,0.416-0.936c4.047-3.839,15.15-13.49,18.988-17.017\
30 | c0.209-0.103,0.313-0.103,0.414,0c0.729,0.83,1.039,1.349,0.623,1.867c-3.215,4.15-9.025,11.83-11.725,15.566\
31 | c3.633,4.566,9.131,11.31,12.244,14.841c0.416,0.413,0.104,1.034-0.414,1.761c-0.105,0.107-0.207,0.207-0.416,0\
32 | c-3.943-3.113-15.875-11.932-19.818-15.149c-0.207-0.207-0.313-0.519-0.313-0.831V60.988z")
33 | path(fill="#2FAEC8", d="M77.188,61.09c0,0.313-0.104,0.624-0.311,0.831C72.934,65.139,61,73.957,57.059,77.07\
34 | c-0.209,0.207-0.313,0.107-0.416,0c-0.518-0.727-0.832-1.348-0.416-1.761c3.113-3.531,8.611-10.274,12.246-14.841\
35 | c-2.699-3.736-8.51-11.416-11.727-15.566c-0.416-0.518-0.104-1.038,0.623-1.867c0.104-0.103,0.207-0.103,0.414,0\
36 | c3.84,3.527,14.943,13.178,18.99,17.017c0.311,0.311,0.414,0.726,0.414,0.936V61.09z")
37 | g
38 | g
39 | path(fill="#FFFFFF", d="M9.293,84.391h0.843v-0.437c0-0.989,0.185-1.702,0.553-2.144c0.369-0.441,0.896-0.664,1.583-0.664\
40 | c0.686,0,1.258,0.094,1.717,0.281l-0.346,1.574c-0.186-0.071-0.353-0.115-0.498-0.133c-0.146-0.016-0.297-0.021-0.452-0.021\
41 | c-0.302,0-0.493,0.117-0.577,0.35c-0.084,0.234-0.125,0.631-0.125,1.193h1.325v1.653H11.99v6.143h-1.854v-6.143H9.293V84.391z")
42 | path(fill="#FFFFFF", d="M17.682,86.23c-0.25-0.094-0.479-0.141-0.687-0.141c-0.28,0-0.522,0.078-0.725,0.234\
43 | c-0.203,0.154-0.341,0.373-0.413,0.654v5.208h-1.855v-7.796h1.419l0.219,0.936h0.062c0.135-0.343,0.33-0.611,0.586-0.803\
44 | c0.254-0.192,0.547-0.289,0.88-0.289c0.249,0,0.493,0.053,0.733,0.156L17.682,86.23z")
45 | path(fill="#FFFFFF", d="M18.291,88.288c0-1.382,0.27-2.411,0.81-3.087c0.541-0.676,1.295-1.014,2.261-1.014\
46 | c1.039,0,1.814,0.344,2.324,1.029c0.508,0.686,0.764,1.711,0.764,3.071c0,1.394-0.271,2.425-0.811,3.095\
47 | c-0.541,0.671-1.3,1.008-2.277,1.008C19.314,92.391,18.291,91.021,18.291,88.288z M20.207,88.288c0,0.78,0.09,1.384,0.266,1.81\
48 | c0.178,0.426,0.473,0.64,0.889,0.64c0.396,0,0.689-0.186,0.881-0.554c0.192-0.369,0.289-1.001,0.289-1.896\
49 | c0-0.8-0.088-1.408-0.266-1.823c-0.176-0.416-0.478-0.625-0.904-0.625c-0.363,0-0.646,0.186-0.85,0.555\
50 | C20.31,86.764,20.207,87.395,20.207,88.288z")
51 | path(fill="#FFFFFF", d="M29.375,92.187v-4.74c0-0.571-0.066-0.972-0.201-1.2c-0.137-0.229-0.364-0.344-0.687-0.344\
52 | c-0.271,0-0.505,0.084-0.702,0.25c-0.197,0.167-0.338,0.375-0.421,0.625v5.409H25.51v-7.796h1.48l0.218,0.904h0.048\
53 | c0.187-0.302,0.441-0.559,0.764-0.771c0.322-0.214,0.744-0.32,1.264-0.32c0.311,0,0.589,0.047,0.833,0.141\
54 | c0.245,0.093,0.45,0.247,0.616,0.461c0.166,0.213,0.291,0.498,0.374,0.857c0.083,0.357,0.124,0.803,0.124,1.332v5.192H29.375z")
55 | path(fill="#FFFFFF", d="M31.902,84.391h0.857v-1.466l1.855-0.577v2.043h1.513v1.653h-1.513v3.397c0,0.449,0.045,0.764,0.133,0.951\
56 | s0.246,0.281,0.475,0.281c0.156,0,0.297-0.016,0.422-0.047c0.125-0.03,0.259-0.077,0.404-0.139l0.234,1.479\
57 | c-0.229,0.115-0.494,0.21-0.795,0.29c-0.302,0.077-0.618,0.115-0.952,0.115c-0.591,0-1.036-0.171-1.333-0.514\
58 | c-0.295-0.343-0.443-0.92-0.443-1.73v-4.085h-0.857V84.391z")
59 | path(fill="#FFFFFF", d="M42.317,91.609c-0.261,0.229-0.614,0.417-1.061,0.563c-0.448,0.145-0.915,0.219-1.403,0.219\
60 | c-0.541,0-1.006-0.095-1.396-0.282s-0.708-0.457-0.958-0.811c-0.251-0.353-0.436-0.782-0.555-1.286s-0.179-1.078-0.179-1.724\
61 | c0-1.403,0.278-2.438,0.833-3.11c0.557-0.67,1.328-1.006,2.316-1.006c0.332,0,0.654,0.051,0.967,0.148\
62 | c0.312,0.098,0.589,0.265,0.834,0.5c0.243,0.233,0.441,0.545,0.592,0.934c0.151,0.391,0.228,0.882,0.228,1.475\
63 | c0,0.229-0.014,0.473-0.04,0.732s-0.066,0.541-0.117,0.842h-3.788c0.021,0.645,0.155,1.139,0.405,1.482\
64 | c0.25,0.342,0.648,0.514,1.201,0.514c0.332,0,0.636-0.053,0.912-0.156c0.275-0.104,0.484-0.213,0.631-0.327L42.317,91.609z\
65 | M39.885,85.763c-0.396,0-0.691,0.159-0.889,0.476S38.684,87,38.652,87.571h2.152c0.031-0.593-0.031-1.042-0.188-1.349\
66 | C40.462,85.917,40.217,85.763,39.885,85.763z")
67 | path(fill="#FFFFFF", d="M47.587,92.187v-4.74c0-0.571-0.067-0.972-0.202-1.2s-0.364-0.344-0.686-0.344\
68 | c-0.271,0-0.506,0.084-0.701,0.25c-0.199,0.167-0.34,0.375-0.422,0.625v5.409h-1.855v-7.796h1.481l0.218,0.904h0.047\
69 | c0.188-0.302,0.441-0.559,0.764-0.771c0.323-0.214,0.742-0.32,1.264-0.32c0.312,0,0.589,0.047,0.834,0.141\
70 | c0.244,0.093,0.449,0.247,0.615,0.461c0.166,0.213,0.292,0.498,0.375,0.857c0.084,0.357,0.124,0.803,0.124,1.332v5.192H47.587z")
71 | path(fill="#FFFFFF", d="M56.318,89.441c0,0.438,0.005,0.874,0.017,1.311c0.011,0.436,0.051,0.92,0.124,1.45h-1.311L54.9,91.298\
72 | h-0.063c-0.354,0.729-0.973,1.093-1.856,1.093c-0.79,0-1.411-0.313-1.862-0.938c-0.453-0.623-0.679-1.637-0.679-3.039\
73 | c0-1.372,0.244-2.414,0.733-3.127c0.487-0.712,1.217-1.068,2.182-1.068c0.25,0,0.457,0.016,0.625,0.047\
74 | c0.166,0.031,0.327,0.084,0.482,0.156v-3.15h1.855V89.441z M53.42,90.689c0.279,0,0.502-0.07,0.669-0.211\
75 | c0.167-0.139,0.291-0.345,0.374-0.615v-3.68c-0.104-0.094-0.22-0.161-0.35-0.203c-0.131-0.04-0.301-0.063-0.508-0.063\
76 | c-0.415,0-0.727,0.188-0.936,0.561c-0.207,0.376-0.313,1.041-0.313,1.997c0,0.718,0.087,1.265,0.258,1.646\
77 | C52.787,90.5,53.055,90.689,53.42,90.689z")
78 | path(fill="#01B0CC", d="M59.108,90.331c0,0.364,0.05,0.624,0.148,0.78c0.099,0.155,0.237,0.232,0.413,0.232\
79 | c0.218,0,0.475-0.057,0.766-0.171l0.107,0.905c-0.135,0.082-0.323,0.15-0.568,0.203c-0.244,0.051-0.465,0.076-0.662,0.076\
80 | c-0.396,0-0.714-0.121-0.959-0.365c-0.243-0.244-0.367-0.673-0.367-1.287v-9.434h1.122V90.331z")
81 | path(fill="#01B0CC", d="M61.463,84.859c0.303-0.188,0.669-0.334,1.1-0.438c0.432-0.104,0.887-0.156,1.365-0.156\
82 | c0.437,0,0.787,0.065,1.053,0.195c0.264,0.13,0.473,0.307,0.622,0.529c0.152,0.224,0.251,0.479,0.298,0.764\
83 | c0.047,0.287,0.07,0.586,0.07,0.898c0,0.623-0.016,1.23-0.041,1.823c-0.027,0.593-0.039,1.153-0.039,1.685\
84 | c0,0.395,0.012,0.762,0.039,1.099c0.025,0.339,0.078,0.658,0.149,0.959H65.2l-0.272-0.92h-0.063\
85 | c-0.154,0.271-0.38,0.505-0.681,0.702c-0.298,0.197-0.7,0.296-1.208,0.296c-0.555,0-1.014-0.195-1.369-0.585\
86 | c-0.355-0.391-0.533-0.928-0.533-1.613c0-0.447,0.074-0.821,0.225-1.123c0.148-0.301,0.361-0.545,0.633-0.732\
87 | c0.273-0.188,0.6-0.32,0.977-0.398c0.375-0.077,0.795-0.117,1.258-0.117c0.104,0,0.207,0,0.31,0s0.213,0.006,0.326,0.016\
88 | c0.031-0.322,0.046-0.607,0.046-0.857c0-0.592-0.088-1.008-0.262-1.246c-0.176-0.239-0.496-0.359-0.959-0.359\
89 | c-0.288,0-0.603,0.045-0.943,0.133c-0.34,0.088-0.623,0.199-0.848,0.336L61.463,84.859z M64.816,88.631\
90 | c-0.103-0.009-0.205-0.018-0.308-0.023c-0.103-0.005-0.207-0.007-0.31-0.007c-0.245,0-0.486,0.021-0.723,0.062\
91 | c-0.238,0.042-0.447,0.115-0.633,0.219c-0.186,0.105-0.332,0.244-0.438,0.421c-0.11,0.177-0.163,0.401-0.163,0.671\
92 | c0,0.416,0.101,0.738,0.301,0.967s0.459,0.344,0.777,0.344c0.433,0,0.767-0.104,1.003-0.313c0.235-0.207,0.4-0.436,0.492-0.685\
93 | V88.631z")
94 | path(fill="#01B0CC", d="M67.779,81.271H68.9v3.712h0.047c0.428-0.52,0.992-0.78,1.701-0.78c0.799,0,1.398,0.316,1.801,0.951\
95 | c0.4,0.635,0.6,1.638,0.6,3.01c0,1.403-0.268,2.447-0.803,3.134s-1.293,1.028-2.27,1.028c-0.479,0-0.915-0.054-1.309-0.164\
96 | c-0.395-0.108-0.691-0.236-0.889-0.381V81.271z M68.9,91.049c0.146,0.082,0.325,0.147,0.538,0.194\
97 | c0.214,0.047,0.438,0.071,0.679,0.071c0.541,0,0.97-0.258,1.286-0.773c0.317-0.514,0.476-1.306,0.476-2.377\
98 | c0-0.447-0.029-0.851-0.086-1.209c-0.056-0.357-0.146-0.667-0.264-0.928c-0.119-0.26-0.275-0.459-0.468-0.6\
99 | c-0.194-0.141-0.425-0.211-0.694-0.211c-0.374,0-0.684,0.112-0.929,0.334c-0.243,0.225-0.423,0.529-0.538,0.914V91.049z")
100 | path(fill="#01B0CC", d="M74.42,90.908c0.207,0.125,0.455,0.231,0.742,0.32c0.285,0.087,0.578,0.132,0.88,0.132\
101 | c0.343,0,0.634-0.086,0.873-0.259c0.239-0.172,0.358-0.452,0.358-0.84c0-0.323-0.072-0.59-0.217-0.799\
102 | c-0.146-0.209-0.331-0.396-0.555-0.564c-0.223-0.168-0.465-0.32-0.725-0.461c-0.26-0.14-0.502-0.309-0.725-0.504\
103 | c-0.224-0.197-0.408-0.43-0.553-0.701c-0.146-0.269-0.219-0.61-0.219-1.023c0-0.664,0.179-1.164,0.537-1.5\
104 | c0.359-0.337,0.865-0.506,1.521-0.506c0.426,0,0.793,0.039,1.105,0.117s0.582,0.185,0.811,0.32l-0.295,0.935\
105 | c-0.199-0.104-0.428-0.189-0.688-0.257c-0.26-0.068-0.524-0.102-0.794-0.102c-0.375,0-0.647,0.078-0.819,0.234\
106 | c-0.173,0.155-0.256,0.399-0.256,0.732c0,0.26,0.07,0.48,0.218,0.663c0.144,0.182,0.329,0.349,0.552,0.499\
107 | c0.226,0.15,0.467,0.303,0.727,0.461c0.26,0.154,0.502,0.338,0.725,0.552c0.223,0.213,0.408,0.468,0.553,0.764\
108 | c0.146,0.297,0.221,0.669,0.221,1.115c0,0.291-0.049,0.567-0.143,0.827c-0.093,0.26-0.234,0.485-0.428,0.678\
109 | c-0.191,0.193-0.432,0.346-0.717,0.46c-0.287,0.114-0.623,0.171-1.007,0.171c-0.457,0-0.853-0.044-1.185-0.131\
110 | c-0.332-0.088-0.614-0.207-0.843-0.352L74.42,90.908z")
111 | path(fill="#D5DF33", d="M79.504,91.485c0-0.292,0.07-0.509,0.211-0.655c0.139-0.146,0.33-0.219,0.568-0.219\
112 | s0.43,0.072,0.569,0.219c0.142,0.146,0.212,0.363,0.212,0.655c0,0.301-0.07,0.524-0.212,0.671\
113 | c-0.14,0.145-0.331,0.217-0.569,0.217s-0.43-0.072-0.568-0.217C79.574,92.01,79.504,91.786,79.504,91.485z")
114 | path(fill="#D5DF33", d="M82.217,82.02c0-0.249,0.069-0.451,0.21-0.605c0.141-0.158,0.325-0.235,0.554-0.235\
115 | c0.229,0,0.418,0.075,0.57,0.227c0.15,0.149,0.225,0.355,0.225,0.614c0,0.25-0.074,0.445-0.225,0.585\
116 | c-0.152,0.142-0.341,0.212-0.57,0.212c-0.229,0-0.413-0.072-0.554-0.219S82.217,82.26,82.217,82.02z M82.42,84.391h1.121v7.796\
117 | H82.42V84.391z")
118 | path(fill="#D5DF33", d="M85.271,88.288c0-1.403,0.242-2.435,0.725-3.095c0.485-0.66,1.174-0.99,2.068-0.99\
119 | c0.955,0,1.66,0.338,2.111,1.014c0.453,0.676,0.68,1.699,0.68,3.071c0,1.415-0.245,2.449-0.734,3.104\
120 | c-0.488,0.655-1.174,0.981-2.057,0.981c-0.957,0-1.661-0.338-2.113-1.013C85.5,90.684,85.271,89.66,85.271,88.288z M86.441,88.288\
121 | c0,0.458,0.029,0.874,0.086,1.247c0.057,0.375,0.152,0.697,0.281,0.969c0.131,0.27,0.299,0.48,0.508,0.631\
122 | c0.207,0.149,0.457,0.226,0.748,0.226c0.54,0,0.944-0.241,1.215-0.726c0.271-0.482,0.406-1.266,0.406-2.347\
123 | c0-0.446-0.029-0.859-0.086-1.239c-0.059-0.379-0.152-0.705-0.281-0.975c-0.13-0.27-0.299-0.479-0.505-0.631\
124 | c-0.209-0.15-0.46-0.227-0.749-0.227c-0.53,0-0.933,0.244-1.209,0.732C86.58,86.438,86.441,87.219,86.441,88.288z")
125 | h1
126 | | Flux 2.0
--------------------------------------------------------------------------------
/frontend/source/views/_partials/views/layout.jade:
--------------------------------------------------------------------------------
1 | include ../../_config/variables.jade
2 | include ../mixins/mixins.jade
3 | doctype html
4 | //-+htmlIe()
5 | html(lang="#{page.lang}", xmlns:og="http://ogp.me/ns#" xmlns:fb="http://ogp.me/ns/fb#")
6 | include ../includes/head.jade
7 | include ../includes/head_scripts.jade
8 | body
9 | include ../layout/header.jade
10 | //- -- --
11 | block content
12 | //- -- --
13 | include ../layout/footer.jade
14 | include ../includes/footer_scripts.jade
15 |
--------------------------------------------------------------------------------
/frontend/source/views/index.jade:
--------------------------------------------------------------------------------
1 | extends _partials/views/layout.jade
2 | block content
3 | include _partials/views/home/index.jade
--------------------------------------------------------------------------------
/frontend/tests/mocha/sections/home/test_default.js:
--------------------------------------------------------------------------------
1 | describe('test_default', function(){
2 |
3 | describe("#greeting()", function () {
4 | it('should say hello when I speak in english', function () {
5 | expect(functions.fn.greeting("en")).eql("Hello");
6 | })
7 | it('should say hola when I speak in spanish', function () {
8 | expect(functions.fn.greeting("es")).eql("Hola");
9 | })
10 | it('should say bonjour when I speak in french', function () {
11 | expect(functions.fn.greeting("fr")).eql("Bonjour");
12 | })
13 | })
14 |
15 | });
16 |
--------------------------------------------------------------------------------
/frontend/tests/selenium/test_cases/dictionary.js:
--------------------------------------------------------------------------------
1 | data = {}
2 | data.url_base = 'http://local.aptituxxxs.pe/'
3 | data.user = {
4 | name: 'Carlo',
5 | email: 'carlos@gmail.com',
6 | password: '123465'
7 | }
8 | data.form_login = {
9 | txtUser: '#frmUserLogIn #txtUser',
10 | txtPassword: '#frmUserLogIn #txtPasswordLogin'
11 | }
12 | data.mi_cuenta = {
13 | message_box: '.message_box span',
14 | title: 'h2.skill_category'
15 | }
16 | data.mi_cuenta.form_user_registration = {
17 | btnSave: '#frmUserRegistration .btn_save',
18 | }
19 | module.exports = data
20 |
--------------------------------------------------------------------------------
/frontend/tests/selenium/test_cases/main.js:
--------------------------------------------------------------------------------
1 | var webdriverio = require('webdriverio');
2 |
3 | client = {};
4 | client = webdriverio.remote({ desiredCapabilities: {browserName: 'firefox'} });
5 | data = require('./dictionary'),
6 | chai = require('chai'),
7 | assert = chai.assert,
8 | expect = chai.expect;
9 |
10 | function fnImportTest(name, path) {
11 | describe(name, function () {
12 | require(path);
13 | });
14 | };
15 |
16 | describe('Pruebas Funcionales', function(){
17 |
18 | this.timeout(99999999);
19 |
20 | before(function(done){
21 | client.init(done);
22 | });
23 |
24 | fnImportTest("Postulante - Sin sesion", './postulante/sin_sesion/login');
25 | fnImportTest("Postulante - Con sesion", './postulante/con_sesion/mi_cuenta');
26 |
27 | after(function(done) {
28 | client.end(done);
29 | });
30 | });
--------------------------------------------------------------------------------
/frontend/tests/selenium/test_cases/postulante/con_sesion/mi_cuenta.js:
--------------------------------------------------------------------------------
1 | describe('Mi Cuenta', function(){
2 | it('Mis Datos Personales',function(done) {
3 | var myForm = data.mi_cuenta.form_user_registration;
4 | client
5 | .url(data.url_base + '/mi-cuenta/mis-datos-personales')
6 | .getText(data.mi_cuenta.title).then(function(value){
7 | expect(value).to.equal('Datos Personales')
8 | })
9 | .click(myForm.btnSave)
10 | .isEnabled(myForm.btnSave).then(function(isEnabled){
11 | expect(isEnabled).to.be.false;
12 | })
13 | .waitForVisible(data.mi_cuenta.message_box, 50000)
14 | .getText(data.mi_cuenta.message_box).then(function(value){
15 | expect(value).to.equal('Los datos fueron actualizados correctamente')
16 | })
17 | .call(done);
18 | });
19 |
20 | it('Ubicación',function(done) {
21 | client
22 | .url(data.url_base + '/mi-cuenta/mi-ubicacion')
23 | .getText(data.mi_cuenta.title).then(function(value){
24 | expect(value).to.equal('Ubicación')
25 | })
26 | .setValue(data.form_login.txtUser, data.user.email)
27 | .click('#frmLocation .btn_save')
28 | .isEnabled('#frmUserRegistration .btn_save').then(function(isEnabled){
29 | expect(isEnabled).to.be.false;
30 | })
31 | .waitForVisible('.message_box span', 50000)
32 | .getText('.message_box span').then(function(value){
33 | expect(value).to.equal('Los datos fueron actualizados correctamente')
34 | })
35 | .call(done);
36 | });
37 | /*
38 | it('Experiencia',function(done) {
39 | client
40 | .url(data.url_base + '/mi-cuenta/mis-experiencias')
41 | .getText(data.mi_cuenta.title).then(function(value){
42 | expect(value).to.equal('Experiencias')
43 | })
44 | .setValue(data.form_login.txtUser, data.user.email)
45 | .click('#frmLocation .btn_save')
46 | .isEnabled('#frmUserRegistration .btn_save').then(function(isEnabled){
47 | expect(isEnabled).to.be.false;
48 | })
49 | .waitForVisible('.message_box span', 50000)
50 | .getText('.message_box span').then(function(value){
51 | expect(value).to.equal('Los datos fueron actualizados correctamente')
52 | })
53 | .call(done);
54 | });
55 |
56 | */
57 |
58 | });
59 |
--------------------------------------------------------------------------------
/frontend/tests/selenium/test_cases/postulante/sin_sesion/login.js:
--------------------------------------------------------------------------------
1 | it('Inicio de Session',function(done) {
2 | client
3 | .url(data.url_base)
4 | .click('.login_init')
5 | .getCssProperty('#modalLoginUser', 'display').then(function(display){
6 | expect(display.value).to.equal('block')
7 | })
8 | .setValue(data.form_login.txtUser, data.user.email)
9 | .getValue(data.form_login.txtUser).then(function(email) {
10 | expect(email).to.equal(data.user.email)
11 | })
12 | .setValue(data.form_login.txtPassword, data.user.password)
13 | .getValue(data.form_login.txtPassword).then(function(password) {
14 | expect(password).to.equal(data.user.password)
15 | })
16 | .click('#frmUserLogIn .btn_tertiary')
17 | .waitForExist('.profile_wrapper', 50000)
18 | .getText('.name_profile').then(function(value){
19 | expect(value).to.equal(data.user.name + ',')
20 | })
21 | .call(done);
22 | });
--------------------------------------------------------------------------------