Added paste button and touched up some styles
This commit is contained in:
parent
d94b8c90fc
commit
77cd95fdcb
@ -931,3 +931,13 @@ i.green.icon.icon.icon.icon {
|
|||||||
opacity: 0;
|
opacity: 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.shade {
|
||||||
|
position: fixed;
|
||||||
|
top: 0;
|
||||||
|
bottom: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
background-color: rgba(0,0,0,0.7);
|
||||||
|
z-index: 1000;
|
||||||
|
}
|
@ -113,6 +113,7 @@
|
|||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
.button-fix {
|
.button-fix {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
float: left;
|
||||||
}
|
}
|
||||||
.hover-row:hover {
|
.hover-row:hover {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
@ -543,7 +543,7 @@ export default {
|
|||||||
'#00b5ad', //Teal
|
'#00b5ad', //Teal
|
||||||
'#2185d0', //Blue
|
'#2185d0', //Blue
|
||||||
'#7128b9', //Violet
|
'#7128b9', //Violet
|
||||||
'#a333c8', // "Purple"
|
'#a333c8', //Purple
|
||||||
'#e03997', //Pink
|
'#e03997', //Pink
|
||||||
'#db2828', //Red
|
'#db2828', //Red
|
||||||
'#f2711c', //Orange
|
'#f2711c', //Orange
|
||||||
|
@ -27,7 +27,9 @@
|
|||||||
v-on:tagClick="tagId => toggleTagFilter(tagId)"
|
v-on:tagClick="tagId => toggleTagFilter(tagId)"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<span>
|
<paste-button />
|
||||||
|
|
||||||
|
<span class="ui grey text text-fix">
|
||||||
Active Sessions {{ $store.getters.getActiveSessions }}
|
Active Sessions {{ $store.getters.getActiveSessions }}
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
@ -38,8 +40,6 @@
|
|||||||
<span v-if="!titleView">
|
<span v-if="!titleView">
|
||||||
<i class="list icon"></i> List
|
<i class="list icon"></i> List
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@ -176,6 +176,7 @@
|
|||||||
'attachment-display': require('@/components/AttachmentDisplayCard').default,
|
'attachment-display': require('@/components/AttachmentDisplayCard').default,
|
||||||
'tag-display':require('@/components/TagDisplayComponent.vue').default,
|
'tag-display':require('@/components/TagDisplayComponent.vue').default,
|
||||||
'loading-icon':require('@/components/LoadingIconComponent.vue').default,
|
'loading-icon':require('@/components/LoadingIconComponent.vue').default,
|
||||||
|
'paste-button':require('@/components/PasteButton.vue').default,
|
||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
@ -809,6 +810,11 @@
|
|||||||
</script>
|
</script>
|
||||||
<style type="text/css" scoped>
|
<style type="text/css" scoped>
|
||||||
|
|
||||||
|
.text-fix {
|
||||||
|
padding: 8px 0 0 15px;
|
||||||
|
display: inline-block;
|
||||||
|
color: var(--menu-accent);
|
||||||
|
}
|
||||||
.detail {
|
.detail {
|
||||||
float: right;
|
float: right;
|
||||||
}
|
}
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
|
const fs = require('fs')
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
pwa: {
|
pwa: {
|
||||||
name: 'SolidScribe',
|
name: 'SolidScribe',
|
||||||
@ -13,6 +15,10 @@ module.exports = {
|
|||||||
disableHostCheck: true,
|
disableHostCheck: true,
|
||||||
proxy: 'http://localhost:8081',
|
proxy: 'http://localhost:8081',
|
||||||
public: 'marvin.local',
|
public: 'marvin.local',
|
||||||
|
https: {
|
||||||
|
key: fs.readFileSync('./certs/192.168.1.164+4-key.pem'),
|
||||||
|
cert: fs.readFileSync('./certs/192.168.1.164+4.pem'),
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
}
|
}
|
@ -442,6 +442,10 @@ Note.update = (userId, noteId, noteText, noteTitle, color, pinned, archived, has
|
|||||||
})
|
})
|
||||||
.then((rows, fields) => {
|
.then((rows, fields) => {
|
||||||
|
|
||||||
|
if(!rows[0] || !rows[0][0] || !rows[0][0]['note_raw_text_id']){
|
||||||
|
return reject(false)
|
||||||
|
}
|
||||||
|
|
||||||
const textId = rows[0][0]['note_raw_text_id']
|
const textId = rows[0][0]['note_raw_text_id']
|
||||||
let salt = rows[0][0]['salt']
|
let salt = rows[0][0]['salt']
|
||||||
let snippetSalt = rows[0][0]['snippet_salt']
|
let snippetSalt = rows[0][0]['snippet_salt']
|
||||||
@ -658,6 +662,9 @@ Note.delete = (userId, noteId, masterKey = null) => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Returns noteData
|
||||||
|
//
|
||||||
Note.get = (userId, noteId, masterKey) => {
|
Note.get = (userId, noteId, masterKey) => {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
|
|
||||||
|
@ -13,11 +13,14 @@ QuickNote.get = (userId, masterKey) => {
|
|||||||
SELECT note.id FROM note WHERE quick_note = 1 AND user_id = ? LIMIT 1`, [userId])
|
SELECT note.id FROM note WHERE quick_note = 1 AND user_id = ? LIMIT 1`, [userId])
|
||||||
.then((rows, fields) => {
|
.then((rows, fields) => {
|
||||||
|
|
||||||
//Quick Note is set, return note text
|
//Quick Note is set, return note object
|
||||||
if(rows[0][0] != undefined){
|
if(rows[0][0] != undefined){
|
||||||
|
|
||||||
let noteId = rows[0][0].id
|
let noteId = rows[0][0].id
|
||||||
return resolve({'noteId':noteId})
|
const note = Note.get(userId, noteId, masterKey)
|
||||||
|
.then(noteData => {
|
||||||
|
return resolve(noteData)
|
||||||
|
})
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
//Or create a new note and get the id
|
//Or create a new note and get the id
|
||||||
@ -81,7 +84,7 @@ QuickNote.update = (userId, pushText, masterKey) => {
|
|||||||
.replace(/&[#A-Za-z0-9]+;/g,'') //Rip out all HTML entities
|
.replace(/&[#A-Za-z0-9]+;/g,'') //Rip out all HTML entities
|
||||||
.replace(/<[^>]+>/g, '') //Rip out all HTML tags
|
.replace(/<[^>]+>/g, '') //Rip out all HTML tags
|
||||||
|
|
||||||
//Turn links into actual linx
|
//Turn links into actual link
|
||||||
clean = QuickNote.makeUrlLink(clean)
|
clean = QuickNote.makeUrlLink(clean)
|
||||||
|
|
||||||
if(clean == ''){ clean = ' ' }
|
if(clean == ''){ clean = ' ' }
|
||||||
@ -114,7 +117,7 @@ QuickNote.update = (userId, pushText, masterKey) => {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
.then( saveResults => {
|
.then( saveResults => {
|
||||||
return resolve(true)
|
return resolve(saveResults)
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user