diff --git a/.gitignore b/.gitignore index 2dba698..a38974d 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,9 @@ pids *.seed *.pid.lock .env + +# exclude everything +staticFiles/* + +# exception to the rule +!staticFiles/assets/ \ No newline at end of file diff --git a/client/package.json b/client/package.json index e48bb97..554e97d 100644 --- a/client/package.json +++ b/client/package.json @@ -1,5 +1,5 @@ { - "name": "client", + "name": "solidscribe", "version": "0.1.0", "private": true, "scripts": { @@ -8,19 +8,21 @@ }, "dependencies": { "axios": "^0.20.0", - "core-js": "^3.8.3", + "core-js": "^3.6.5", "es6-promise": "^4.2.8", "fomantic-ui-css": "^2.8.7", - "vue": "^2.6.14", - "vue-router": "^3.5.1", - "vuex": "^3.6.2" + "vue": "^2.6.11", + "vue-router": "^3.2.0", + "vuex": "^3.4.0" }, "devDependencies": { - "@vue/cli-plugin-babel": "~5.0.0", - "@vue/cli-plugin-router": "~5.0.0", - "@vue/cli-plugin-vuex": "~5.0.0", - "@vue/cli-service": "~5.0.0", - "vue-template-compiler": "^2.6.14" + "@vue/cli-plugin-babel": "~4.5.0", + "@vue/cli-plugin-router": "~4.5.0", + "@vue/cli-plugin-vuex": "~4.5.0", + "@vue/cli-service": "~4.5.0", + "node-sass": "^4.12.0", + "sass-loader": "^8.0.2", + "vue-template-compiler": "^2.6.11" }, "browserslist": [ "> 1%", diff --git a/client/public/index.html b/client/public/index.html index 3e5a139..93052cf 100644 --- a/client/public/index.html +++ b/client/public/index.html @@ -1,17 +1,69 @@ - + - - - <%= htmlWebpackPlugin.options.title %> + + + + + + + + + Solid Scribe - An easy, encrypted Note App + -
+
+ + + +
+ +

Solid Scribe

+

An easy, encrypted Note App

+

Loading...

+
+ +
+

Solid Scribe

+

A note application that respects your privacy.

+

Take notes with a clean editor that works on desktop or mobile.

+

Search notes, links and files to find what you need.

+

Accessable everywhere.

+

Categorize notes with tags.

+

Share data with fellow users.

+

Encrypt notes for additional security.

+ This site requires Javascipt to run. +
+ +
- + \ No newline at end of file diff --git a/client/src/assets/semantic-helper.css b/client/src/assets/semantic-helper.css index 64942dc..d178483 100644 --- a/client/src/assets/semantic-helper.css +++ b/client/src/assets/semantic-helper.css @@ -164,7 +164,7 @@ div.ui.basic.green.label { border-color: var(--dark_border_color) !important; } /*Overwrites for modifiable theme color */ -i.green.icon.icon.icon.icon { +i.green.icon.icon.icon.icon, i.green.icon.icon.icon.icon.icon { color: var(--main-accent); } .button { diff --git a/client/src/components/GlobalSiteMenu.vue b/client/src/components/GlobalSiteMenu.vue index 2fcc41e..d0bd2bf 100644 --- a/client/src/components/GlobalSiteMenu.vue +++ b/client/src/components/GlobalSiteMenu.vue @@ -329,8 +329,8 @@ diff --git a/client/src/pages/CycletrackingPage.vue b/client/src/pages/CycletrackingPage.vue index 82e51bc..9a4de7e 100644 --- a/client/src/pages/CycletrackingPage.vue +++ b/client/src/pages/CycletrackingPage.vue @@ -121,9 +121,6 @@

Metric Tracking Beta - - -
@@ -136,16 +133,16 @@
- + - + Modified - + Saving - + Saved
@@ -309,10 +306,10 @@
-
+ Calendar Explanation -
+
1 @@ -410,6 +407,12 @@
If you do get pregnant, your body needs the lining — that’s why your period stops during pregnancy. Your period comes back when you’re not pregnant anymore.
+
+ Delete all data. Can not be undone. + + + +
@@ -703,7 +706,7 @@ }, fetchCycleData(){ - axios.post('/api/cycle-tracking/get') + axios.post('/api/metric-tracking/get') .then(({ data }) => { if(data.hasOwnProperty("text")){ @@ -744,7 +747,7 @@ // 0 blank, 1 modified, 2 saving, 3 saved this.saving = 2 // Working this.totalEntries = Object.keys(this.cycleData).length - axios.post('/api/cycle-tracking/save', { cycleData:appData }) + axios.post('/api/metric-tracking/save', { cycleData:appData }) .then(response => { // { this.$bus.$emit('notification', 'Data Saved') } this.saving = 3 //Saved @@ -755,7 +758,7 @@ .catch(error => { this.$bus.$emit('notification', error) }) }, deleteData(){ - axios.post('/api/cycle-tracking/save', { cycleData:'' }) + axios.post('/api/metric-tracking/save', { cycleData:'' }) .then(response => { { this.$bus.$emit('notification', 'Data Deleted') } this.fetchCycleData() diff --git a/client/src/router/index.js b/client/src/router/index.js index 0e85534..a35b480 100644 --- a/client/src/router/index.js +++ b/client/src/router/index.js @@ -117,9 +117,9 @@ export default new Router({ }, // Cycle Tracking { - path: '/cycletrack', - name: 'Cycle Tracking', - meta: {title:'Cycle Tracking'}, + path: '/metrictrack', + name: 'Metric Tracking', + meta: {title:'Metric Tracking'}, component: () => import(/* webpackChunkName: "CycletrackingPage" */ '@/pages/CycletrackingPage') }, ] diff --git a/client/vue.config.js b/client/vue.config.js deleted file mode 100644 index 910e297..0000000 --- a/client/vue.config.js +++ /dev/null @@ -1,4 +0,0 @@ -const { defineConfig } = require('@vue/cli-service') -module.exports = defineConfig({ - transpileDependencies: true -}) diff --git a/server/index.js b/server/index.js index 22f4d36..43b1c6c 100644 --- a/server/index.js +++ b/server/index.js @@ -319,8 +319,8 @@ var quickNote = require('@routes/quicknoteController') app.use('/api/quick-note', quickNote) //cycle tracking endpoint -var cycleTracking = require('@routes/cycletrackingController') -app.use('/api/cycle-tracking', cycleTracking) +var metricTracking = require('@routes/metrictrackingController') +app.use('/api/metric-tracking', metricTracking) //Output running status app.listen(ports.express, () => { diff --git a/server/models/CycleTracking.js b/server/models/MetricTracking.js similarity index 79% rename from server/models/CycleTracking.js rename to server/models/MetricTracking.js index 8773699..910090e 100644 --- a/server/models/CycleTracking.js +++ b/server/models/MetricTracking.js @@ -2,10 +2,10 @@ let db = require('@config/database') let Note = require('@models/Note') -let CycleTracking = module.exports = {} +let MetricTracking = module.exports = {} -CycleTracking.get = (userId, masterKey) => { +MetricTracking.get = (userId, masterKey) => { return new Promise((resolve, reject) => { db.promise() @@ -25,7 +25,7 @@ CycleTracking.get = (userId, masterKey) => { } else { //Or create a new note let finalId = null - return Note.create(userId, 'Cycle Tracking', '', masterKey) + return Note.create(userId, 'Metric Tracking', '', masterKey) .then(insertedId => { finalId = insertedId db.promise().query('UPDATE note SET quick_note = 2 WHERE id = ? AND user_id = ?',[insertedId, userId]) @@ -47,12 +47,12 @@ CycleTracking.get = (userId, masterKey) => { }) } -CycleTracking.save = (userId, cycleData, masterKey) => { +MetricTracking.save = (userId, cycleData, masterKey) => { return new Promise((resolve, reject) => { let finalId = null - CycleTracking.get(userId, masterKey) + MetricTracking.get(userId, masterKey) .then(noteObject => { return Note.update(userId, noteObject.id, cycleData, noteObject.title, noteObject.color, noteObject.pinned, noteObject.archived, null, masterKey) diff --git a/server/routes/cycletrackingController.js b/server/routes/metrictrackingController.js similarity index 74% rename from server/routes/cycletrackingController.js rename to server/routes/metrictrackingController.js index 1efb797..da84262 100644 --- a/server/routes/cycletrackingController.js +++ b/server/routes/metrictrackingController.js @@ -1,11 +1,11 @@ // -// /api/cycle-tracking +// /api/metric-tracking // var express = require('express') var router = express.Router() -let CycleTracking = require('@models/CycleTracking'); +let MetricTracking = require('@models/MetricTracking'); let userId = null let masterKey = null @@ -27,13 +27,13 @@ router.use(function setUserId (req, res, next) { //Get quick note text router.post('/get', function (req, res) { - CycleTracking.get(userId, masterKey) + MetricTracking.get(userId, masterKey) .then( data => res.send(data) ) }) //Push text to quick note router.post('/save', function (req, res) { - CycleTracking.save(userId, req.body.cycleData, masterKey) + MetricTracking.save(userId, req.body.cycleData, masterKey) .then( data => res.send(data) ) }) diff --git a/staticFiles/.gitignore b/staticFiles/.gitignore deleted file mode 100644 index 6ea6a2f..0000000 --- a/staticFiles/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -* -*/ -!.gitignore -!assets diff --git a/staticFiles/assets/logo.svg b/staticFiles/assets/logo.svg new file mode 100644 index 0000000..c68a2e1 --- /dev/null +++ b/staticFiles/assets/logo.svg @@ -0,0 +1,19 @@ + + + + + + + image/svg+xml + + + + + + + + + + + + \ No newline at end of file diff --git a/staticFiles/assets/manifest.json b/staticFiles/assets/manifest.json new file mode 100644 index 0000000..d9072b2 --- /dev/null +++ b/staticFiles/assets/manifest.json @@ -0,0 +1,24 @@ +{ + "theme_color":"#000", + "background_color": "#000", + "description": "Take Notes", + "display": "standalone", + "icons": [ + { + "src": "/api/static/assets/logo.png", + "sizes": "496x496", + "type": "image/png", + "purpose": "any" + }, + { + "src": "/api/static/assets/maskable_icon.png", + "sizes": "826x826", + "type": "image/png", + "purpose": "maskable" + } + ], + "name": "Solid Scribe", + "short_name": "Solid Scribe", + "start_url": "/#/notes", + "author":"Max" +} \ No newline at end of file diff --git a/staticFiles/assets/marketing/favicon.ico b/staticFiles/assets/marketing/favicon.ico new file mode 100644 index 0000000..7ef9058 Binary files /dev/null and b/staticFiles/assets/marketing/favicon.ico differ diff --git a/staticFiles/assets/marketing/logo.svg b/staticFiles/assets/marketing/logo.svg new file mode 100644 index 0000000..c68a2e1 --- /dev/null +++ b/staticFiles/assets/marketing/logo.svg @@ -0,0 +1,19 @@ + + + + + + + image/svg+xml + + + + + + + + + + + + \ No newline at end of file diff --git a/staticFiles/assets/marketing/manifest.json b/staticFiles/assets/marketing/manifest.json new file mode 100644 index 0000000..d9072b2 --- /dev/null +++ b/staticFiles/assets/marketing/manifest.json @@ -0,0 +1,24 @@ +{ + "theme_color":"#000", + "background_color": "#000", + "description": "Take Notes", + "display": "standalone", + "icons": [ + { + "src": "/api/static/assets/logo.png", + "sizes": "496x496", + "type": "image/png", + "purpose": "any" + }, + { + "src": "/api/static/assets/maskable_icon.png", + "sizes": "826x826", + "type": "image/png", + "purpose": "maskable" + } + ], + "name": "Solid Scribe", + "short_name": "Solid Scribe", + "start_url": "/#/notes", + "author":"Max" +} \ No newline at end of file diff --git a/staticFiles/assets/marketing/maskable_icon.png b/staticFiles/assets/marketing/maskable_icon.png new file mode 100644 index 0000000..77eb26e Binary files /dev/null and b/staticFiles/assets/marketing/maskable_icon.png differ diff --git a/staticFiles/assets/maskable_icon.png b/staticFiles/assets/maskable_icon.png new file mode 100644 index 0000000..77eb26e Binary files /dev/null and b/staticFiles/assets/maskable_icon.png differ