Skip to content
Snippets Groups Projects
Commit f1c427ea authored by Adam Procter's avatar Adam Procter
Browse files

0.1.19

updated to mobile (previously list view)
fixed IPFS support for media
updated packages
Slightly out of sync with Master now which I will need to address 
parent 67a292ee
No related branches found
No related tags found
No related merge requests found
# 0.1.19
_13th July 2020_
### Changes
- List view has be renamed mobile view and works better on smaller devices. Allow for quick capture of ideas whislt using a smaller screen (not perfect but better than before)
### Fixed
- IPFS Media is working (updated code for 0.49.0)
# 0.1.18
_2nd July 2020_
......
{
"name": "nodenogg.in",
"version": "0.1.18",
"version": "0.1.19",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
......
......@@ -9,12 +9,12 @@
ref="fileInput"
@change="onFileSelected"
/>
<!-- <h1>{{ status }}</h1>
<h1>{{ status }}</h1>
<h2>ID: {{ id }}</h2>
<h2>Agent version: {{ agentVersion }}</h2> -->
<!--
<h2>Agent version: {{ agentVersion }}</h2>
<button type="button" @click="saveIPFS">Upload</button>
<button type="button" @click="getIPFS">Get IPFS</button> -->
<button type="button" @click="getIPFS">Get IPFS</button>
<!-- {{ uploadready }} -->
<textarea id="ipfshash" v-model="copytext"></textarea>
<div class="btn-row">
......@@ -103,13 +103,8 @@ export default {
async saveIPFS() {
try {
for await (const result of node.add(this.selectedFile)) {
//console.log(result.cid.string)
this.fileContents = result
// console.log(this.fileContents.path)
// node.swarm.peers().then((a) => console.log(a))
this.fileContents = await node.add(this.selectedFile)
this.getIPFS()
}
} catch (err) {
// Set error status text.
this.status = `Error: ${err}`
......@@ -153,7 +148,7 @@ export default {
</script>
<style lang="css" scoped>
.fileInput {
/* .fileInput {
display: none;
}
......@@ -163,5 +158,5 @@ textarea {
height: 0px;
width: 0px;
padding: 0px;
}
} */
</style>
......@@ -112,6 +112,11 @@ export default {
</script>
<style scoped>
nav {
display: none;
}
@media (min-width: 450px) {
nav {
position: fixed;
......@@ -142,4 +147,5 @@ button {
button.active {
background: rgb(30, 30, 30);
}
}
</style>
......@@ -133,7 +133,7 @@ export default {
if (!this.interaction.origin) {
return
}
// console.log('touch')
//console.log(e.touches.length)
e.preventDefault()
const isPinchAction =
e.touches.length == 2 && this.interaction.origin.points.length > 1
......
......@@ -13,6 +13,11 @@ export const routes = [
name: 'Home',
component: Home,
},
{
path: '/mobile',
name: 'Mobile',
component: List,
},
{
path: '/about',
name: 'About',
......@@ -22,11 +27,6 @@ export const routes = [
component: () =>
import(/* webpackChunkName: "about" */ '../views/About.vue'),
},
{
path: '/list',
name: 'List Test',
component: List,
},
// {
// path: '/test',
......
......@@ -2,7 +2,6 @@
<div id="listwrapper">
<!-- <div v-for="(posvalue, index) in configPositions" v-bind:key="index"> -->
<h1 class="mobile">Your nodes - list mode</h1>
<h2>Testing Only</h2>
<!-- <OffLine
v-for="value in myNodes"
v-bind:key="value.node_id"
......@@ -10,10 +9,39 @@
v-bind:nodetext="value.node_text"
@editTrue="(e) => editTrue(e)"
/> -->
<div v-if="clientset">
<div class="btn-row">
<BaseButton class="new" buttonClass="action" @click="addNode()"
>Create Node</BaseButton
>
</div>
<form>
<!-- <div v-if="posvalue.read_mode == false"> -->
<div
v-for="value in myNodes.slice().reverse()"
v-bind:key="value.node_id"
>
<textarea
@focus="editTrue(true)"
@blur="editTrue(false)"
autofocus
@input="editNode"
v-model="value.node_text"
:id="nodeid"
ref="nodetext"
placeholder="Idea goes here!"
></textarea>
</div>
</form>
</div>
<!-- // onboarding for list view -->
<div v-else>
<form>
<div>
<p id="nodeid" :inner-html.prop="nodetext1 | marked"></p>
<div v-if="name == false">
<input
type="text"
v-model.trim="clientid"
......@@ -31,11 +59,16 @@
>
</div>
</div>
<div v-else>
<h4>Saved</h4>
</div>
</div>
</form>
<form>
<div>
<p id="nodeid" :inner-html.prop="nodetext2 | marked"></p>
<div v-if="microcosm == false">
<input
type="text"
v-model.trim="localmicrocosm"
......@@ -48,40 +81,19 @@
@blur="editTrue(false)"
/>
<div class="btn-row">
<BaseButton buttonClass="special" @click="createMicrocosm(), letsGo()"
<BaseButton
buttonClass="special"
@click="createMicrocosm(), letsGo()"
>Create Microcosm</BaseButton
>
</div>
</div>
</form>
<div class="btn-row">
<BaseButton class="new" buttonClass="action" @click="addNode()"
>Create Node</BaseButton
>
<div v-else>
<h4>Loading...</h4>
</div>
<form>
<!-- <div v-if="posvalue.read_mode == false"> -->
<div
v-for="value in myNodes.slice().reverse()"
v-bind:key="value.node_id"
>
<textarea
@focus="editTrue(true)"
@blur="editTrue(false)"
autofocus
@input="editNode"
v-model="value.node_text"
:id="nodeid"
ref="nodetext"
placeholder="Idea goes here!"
></textarea>
</div>
<!-- </div> -->
<!-- <div v-if="posvalue.read_mode == true">
<p class="read" :id="nodeid" :inner-html.prop="nodetext | marked"></p>
</div> -->
</form>
</div>
<ModeToolbar />
</div>
......@@ -108,9 +120,10 @@ export default {
offline: false,
nodetext1:
'## What shall we call you ? 💥 \n First we need to connect this device to your ideas. This name is what allows you to create and edit your nodes and can be anything you like and this name is always anonymous.',
nodetext2:
'## Start those engines ! 🏎 \n Now you can create your own microcosm to store your ideas and ask people to join you, either just tell them the name of the microcosm or share the alpha.nodenogg.in URL and add the ending; </br><em><b>/microcosm/nameofyourmicrocosm</b></em>',
name: false,
microcosm: false,
}
},
......@@ -145,6 +158,7 @@ export default {
this.createMicrocosm()
this.setClient()
this.letsGo()
this.clientset = 'true'
}
},
......@@ -165,13 +179,16 @@ export default {
createMicrocosm() {
this.$store.dispatch('createMicrocosm', this.localmicrocosm)
localStorage.setItem('mylastMicrocosm', this.localmicrocosm)
this.microcosm = true
},
setClient() {
this.$store.dispatch('setClient', this.clientid),
localStorage.setItem('myNNClient', this.clientid)
this.name = true
},
letsGo() {
this.clientset = !this.clientset
this.$emit('clientAdded')
},
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment