Skip to content

Commit

Permalink
Merge pull request #41 from JustalK/pre-dev
Browse files Browse the repository at this point in the history
[FEATURE] Adding personnal projects
  • Loading branch information
JustalK committed Nov 3, 2020
2 parents 639bbc4 + 5895b9f commit b718799
Show file tree
Hide file tree
Showing 25 changed files with 271 additions and 81 deletions.
Binary file modified design/intro.xcf
Binary file not shown.
30 changes: 15 additions & 15 deletions dev/index.js

Large diffs are not rendered by default.

Binary file added documentation/imgs/project/api.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified documentation/imgs/project/home.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added documentation/imgs/project/portfolio.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 5 additions & 4 deletions readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
![Alt text](documentation/imgs/project/home.jpg?raw=true "pornhub api")
![Alt text](documentation/imgs/project/portfolio.jpg?raw=true "PORTFOLIO-PORTFOLIO")

![Last version](https://img.shields.io/github/v/tag/justalk/portfolio.svg?style=flat-square)
[![Travis](https://img.shields.io/travis/com/justalk/portfolio.svg?style=flat-square)](https://travis-ci.com/github/JustalK/portfolio)
Expand All @@ -16,9 +16,6 @@ For the project to work properly on your computer, you need to have on your mach

1. A machine with node installed :
https://nodejs.org/en/download/
```
MongoDB
```

2. A working Mongo database : https://docs.mongodb.com/manual/installation/
```
Expand Down Expand Up @@ -61,9 +58,13 @@ $ npm run watch-server
The project can be access at the port 8080 by default :
http://localhost:8080/

![Alt text](documentation/imgs/project/home.jpg?raw=true "PORTFOLIO-HOME")

The documentation of the API (`swagger`) can be access at this url :
http://localhost:8080/api/documentation/index.html

![Alt text](documentation/imgs/project/api.jpg?raw=true "PORTFOLIO-PORTFOLIO")

## Server

For running the server with the last build :
Expand Down
164 changes: 140 additions & 24 deletions seeding/datas/articles/articles.js

Large diffs are not rendered by default.

15 changes: 15 additions & 0 deletions seeding/datas/images/images.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,5 +117,20 @@ module.exports = [
id: mongoose.Types.ObjectId("5f9d88d3faed1e8c4dc00024"),
name: "Onarto",
path: "./assets/imgs/onarto/intro.jpg"
},
{
id: mongoose.Types.ObjectId("5f9d88d3faed1e8c4dc00025"),
name: "Pornhub API",
path: "./assets/imgs/pornhub/intro.jpg"
},
{
id: mongoose.Types.ObjectId("5f9d88d3faed1e8c4dc00026"),
name: "Anime API",
path: "./assets/imgs/anime-api/intro.jpg"
},
{
id: mongoose.Types.ObjectId("5f9d88d3faed1e8c4dc00027"),
name: "COVID19PH API",
path: "./assets/imgs/covid19ph-api/intro.jpg"
}
]
56 changes: 56 additions & 0 deletions seeding/datas/tags/tags.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@
const mongoose = require('mongoose');

module.exports = [
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5871"),
name: "Professional projects"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5872"),
name: "Personal projects"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5873"),
name: "Vue.js"
Expand Down Expand Up @@ -34,5 +42,53 @@ module.exports = [
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5880"),
name: "PhpMyAdmin"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5881"),
name: "Ava"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5882"),
name: "Swagger"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5883"),
name: "Webpack"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5884"),
name: "LESS"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5885"),
name: "Chai"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5886"),
name: "jQuery"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5887"),
name: "Bootstrap"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5888"),
name: "From scratch"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5889"),
name: "Code Igniter"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5890"),
name: "Selenium"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5891"),
name: "SQL Server"
},
{
id: mongoose.Types.ObjectId("5f95461688489acdd8ee5892"),
name: "ESLint"
}
]
9 changes: 5 additions & 4 deletions server/libs/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,14 @@ module.exports = {
filters[key] = value;
},
add_tags_filter: (filters, key, value) => {
if (module.exports.is_value_exist(value)) {
module.exports.add_filter(filters, key, { $all: value });
}
module.exports.check_and_add_name_filter(filters, key, value, { $all: value });
},
add_name_filter: (filters, key, value) => {
module.exports.check_and_add_name_filter(filters, key, value, { $eq: value });
},
check_and_add_name_filter: (filters, key, value, operators) => {
if (module.exports.is_value_exist(value)) {
module.exports.add_filter(filters, key, { $eq: value });
module.exports.add_filter(filters, key, operators);
}
}
};
6 changes: 4 additions & 2 deletions server/routes/apps.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@ const express = require('express');
const routes = express.Router();

routes.route('/').get(async (request, response) => {
const app = { name: process.env.API_NAME, status: 'RUNNING' };
response.json(app);
response.json({
name: process.env.API_NAME,
status: 'RUNNING'
});
});

module.exports = routes;
3 changes: 1 addition & 2 deletions server/routes/contacts.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ const services = require('../services/' + filename)(dbs);

// Return the list of all the articles
routes.route('/my-identity').get(async (request, response) => {
const datas = await services.get_my_identity();
response.json(datas);
response.json(await services.get_my_identity());
});

module.exports = routes;
3 changes: 1 addition & 2 deletions server/routes/tags.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ const services = require('../services/' + filename)(dbs);

// Return the list of all the articles
routes.route('/').get(async (request, response) => {
const datas = await services.get_all();
response.json(datas);
response.json(await services.get_all());
});

module.exports = routes;
Binary file added src/assets/imgs/anime-api/intro.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/imgs/covid19ph-api/intro.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/imgs/pornhub/intro.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/assets/imgs/portfolio/intro.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 7 additions & 3 deletions src/assets/less/informations.less
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
@import (reference) "libs/mixins.less";

.informations {
height: 234px;

& > h1 {
padding-top: 50px;
height: 50px;
Expand All @@ -14,11 +12,17 @@
font-size: 2.5em;
}

& > span {
& span:nth-child(2) {
margin-top: 20px;
height: 50px;
text-align: justify;
line-height: 25px;
font-size: 1.2em;
}

& span:nth-child(4) {
margin-top: 20px;
height: 25px;
margin-bottom: 25px;
}
}
1 change: 1 addition & 0 deletions src/assets/less/libs/constants.less
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
@background-transparent-opaque: #0d1b29;
@background-shadow: #000;
@background-arrow-slider: #20a8fd;
@background-text-animation: #0a2234;
@text-color: #61C3FF;
@text-color-white: #FFF;
@text-color-less-dark: darken(@text-color, 20%);
Expand Down
6 changes: 0 additions & 6 deletions src/assets/less/portfolio.less
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,6 @@
margin: auto;
position: relative;

& > span {
margin-top: 20px;
height: 25px;
margin-bottom: 25px;
}

&::before,
&::after {
content: ' ';
Expand Down
5 changes: 3 additions & 2 deletions src/assets/less/tags.less
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,16 @@

.tags {
padding: 10px 0 0 0;
overflow: hidden;
display: flex;
align-items: normal;
flex-wrap: wrap;

&-tag {
font-family: 'Lato-Bold', sans-serif;
font-size: 0.8em;
.transition(all 0.5s cubic-bezier(0.8, 0, 0.25, 1));

display: block !important;
float: left;
padding: 10px;
margin-right: 10px;
margin-bottom: 10px;
Expand Down
2 changes: 1 addition & 1 deletion src/assets/less/text.less
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
right: 0;
height: 100%;
width: 100%;
background: @text-color;
background: @background-text-animation;
.transition(all 0.5s cubic-bezier(0.8, 0, 0.25, 1) 1s);
}

Expand Down
6 changes: 6 additions & 0 deletions src/components/informations.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
<components_tags
:tags="this.tags"
@new_tags_selected="new_tags_selected" />
<components_text
:text="this.help" />
</div>
</template>
<script>
Expand All @@ -32,6 +34,10 @@ export default {
tags: {
type: Array,
required: true
},
help: {
type: String,
required: true
}
},
methods: {
Expand Down
20 changes: 9 additions & 11 deletions src/helper/utils.js
Original file line number Diff line number Diff line change
@@ -1,25 +1,23 @@
module.exports = {
add_class_to_elements(selector, newclass) {
module.exports.add_class_to_elements_increase(selector, newclass, 0, 0);
},
add_class_to_elements_increase(selector, newclass, min, increase) {
class_to_elements_increase(selector, newclass, min, increase, fc) {
const elements = [...document.querySelectorAll(selector)];
elements.map((element, index) => {
setTimeout(() => {
module.exports.add_class_to_element(element, newclass);
fc(element, newclass);
}, min + index * increase);
})
},
add_class_to_elements(selector, newclass) {
module.exports.add_class_to_elements_increase(selector, newclass, 0, 0);
},
add_class_to_elements_increase(selector, newclass, min, increase) {
module.exports.class_to_elements_increase(selector, newclass, min, increase, module.exports.add_class_to_element);
},
remove_class_to_elements(selector, newclass) {
module.exports.remove_class_to_elements_increase(selector, newclass, 0, 0);
},
remove_class_to_elements_increase(selector, newclass, min, increase) {
const elements = [...document.querySelectorAll(selector)];
elements.map((element, index) => {
setTimeout(() => {
module.exports.remove_class_to_element(element, newclass);
}, min + index * increase);
})
module.exports.class_to_elements_increase(selector, newclass, min, increase, module.exports.remove_class_to_element);
},
add_class_to_element_delay(selector, newclass, delay) {
setTimeout(() => {
Expand Down
7 changes: 2 additions & 5 deletions src/pages/portfolio.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,8 @@
:description="description"
:tags="tags"
:title="title"
:help="help"
@filter="filter" />
<components_text
:text="this.help" />
<components_sliders
:projects="projects"
:are_projects_loading="are_projects_loading"
Expand All @@ -22,16 +21,14 @@ import pubs from '../components/pubs';
import sliders from '../components/sliders';
import back from '../components/main/back';
import api from '../services/api';
import text from '../components/main/text';
import utils from '../helper/utils.js';
export default {
components: {
components_informations: informations,
components_sliders: sliders,
components_pubs: pubs,
components_back: back,
components_text: text
components_back: back
},
data: () => {
return {
Expand Down

0 comments on commit b718799

Please sign in to comment.