From 749c3236f86ba9a816dabf2e7fe8b59ce3094478 Mon Sep 17 00:00:00 2001 From: sambit sahoo Date: Thu, 17 Sep 2020 09:25:09 +0530 Subject: [PATCH] release v0.3.0 --- src/components/Context.vue | 13 ++++-------- src/components/Sidebar.vue | 41 ++++++++++++++++++-------------------- src/store/index.js | 2 +- src/views/Board.vue | 11 +++++----- src/views/Home.vue | 2 +- src/views/User.vue | 3 +++ sw.js | 2 +- 7 files changed, 35 insertions(+), 39 deletions(-) diff --git a/src/components/Context.vue b/src/components/Context.vue index 95ad2b6..749440c 100644 --- a/src/components/Context.vue +++ b/src/components/Context.vue @@ -7,13 +7,6 @@
  • Delete Board
  • - @@ -26,7 +19,7 @@ export default { name: "Context", props: ["command"], computed: { - ...mapGetters({ user: "giveUser" }), + ...mapGetters({ user: "giveUser", boards: "boards" }), }, methods: { close() { @@ -36,7 +29,9 @@ export default { db.ref(`/Users/${this.user.data.uid}/Boards/${this.command.key}`) .remove() .then(() => { - /* if() */ + if (this.$route.fullPath !== "/boards") { + this.$router.push({ path: "/boards" }); + } }); this.$emit("close-context"); }, diff --git a/src/components/Sidebar.vue b/src/components/Sidebar.vue index 9252b35..e1d533d 100644 --- a/src/components/Sidebar.vue +++ b/src/components/Sidebar.vue @@ -30,9 +30,9 @@ @@ -115,7 +114,7 @@ export default { left: event.pageX, top: event.pageY, }; - setTimeout(() => { + setTimeout(() => { this.isTooltip = false; }, 1000); }, @@ -220,7 +219,7 @@ $secondary-light: #e1e1ff; .hamburger-inner::before, .hamburger-inner::after { width: 28px; - height: 2.5px; + height: 2px; background-color: $primary; border-radius: 2px; position: absolute; @@ -234,10 +233,10 @@ $secondary-light: #e1e1ff; display: block; } .hamburger-inner::before { - top: -5.5px; + top: -5px; } .hamburger-inner::after { - bottom: -5.5px; + bottom: -5px; } .is-active { left: 150px; @@ -249,10 +248,10 @@ $secondary-light: #e1e1ff; transform: rotate(-180deg); } .hamburger--arrowturn.is-active .hamburger-inner::before { - transform: translate3d(8px, 0, 0) rotate(40deg) scale(0.7, 1); + transform: translate3d(8px, 0, 0) rotate(35deg) scale(0.7, 1); } .hamburger--arrowturn.is-active .hamburger-inner::after { - transform: translate3d(8px, 0, 0) rotate(-40deg) scale(0.7, 1); + transform: translate3d(8px, 0, 0) rotate(-35deg) scale(0.7, 1); } // ** Sidebar styles @@ -271,7 +270,7 @@ $secondary-light: #e1e1ff; left: 0; background-color: $secondary; overflow-x: hidden; - a { + a:not(.user-link) { cursor: pointer; padding: 6px 8px 6px 16px; display: block; @@ -355,23 +354,21 @@ $secondary-light: #e1e1ff; .side-user { display: flex; flex-direction: row; + align-items: center; + align-content: flex-start; + justify-content: center; + color: $primary !important; .u-l { + flex: 0 0 20%; + max-width: 20%; padding: 0 5px; - text-align: left; - flex: 0 0 25%; - max-width: 25%; - img { - max-width: 100%; - width: 100%; - border-radius: 5px !important; - } + border-radius: 5px !important; } .u-r { + flex: 0 0 78%; + max-width: 78%; font-size: 16px; padding: 0 5px; - text-align: left; - flex: 0 0 75%; - max-width: 75%; } } diff --git a/src/store/index.js b/src/store/index.js index 626712a..c8ddc91 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -20,7 +20,7 @@ export default new Vuex.Store({ state.user.data = data; }, Boards: (state, uid) => { - db.ref(`/Users/${uid}/Boards/`).on("value", (snap) => { + db.ref(`/Users/${uid}/Boards`).on("value", (snap) => { state.boards = []; snap.forEach((csnap) => { if (!state.boards.find((el) => el.key === csnap.key)) { diff --git a/src/views/Board.vue b/src/views/Board.vue index 3776601..eb9f707 100644 --- a/src/views/Board.vue +++ b/src/views/Board.vue @@ -4,10 +4,9 @@

    { this.editor.save().then((data) => { const head = document.getElementById("init_head"); - /* this.boardMeta.name = data.blocks[0].data.text; */ if (data === undefined) { db.ref( `/Users/${this.user.data.uid}/Boards/${this.$route.params._slug}` @@ -144,14 +142,14 @@ export default { }); } else { db.ref( - `/Users/${this.user.data.uid}/Boards/${this.$route.params._slug}` + `Users/${this.user.data.uid}/Boards/${this.$route.params._slug}` ) .update({ meta: { name: head.innerText, stamp: Date.now(), }, - data: this.tempdata, + data: data, }) .then(() => { this.isSaved = true; @@ -160,6 +158,9 @@ export default { id: this.$route.params._slug, status: this.upStatus, }); + }) + .catch((err) => { + console.log(err); }); } }); diff --git a/src/views/Home.vue b/src/views/Home.vue index a5b5966..e1cc06b 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -20,7 +20,7 @@ Peace ☮✌🏼


    -

    Current v2.3.0.alpha

    +

    Current v0.3.0.alpha

    diff --git a/src/views/User.vue b/src/views/User.vue index 7794482..4021f70 100644 --- a/src/views/User.vue +++ b/src/views/User.vue @@ -100,4 +100,7 @@ a { max-width: 100%; border-radius: 10000px !important; } +.row { + align-items: center; +} diff --git a/sw.js b/sw.js index 55773c1..aa9a64d 100644 --- a/sw.js +++ b/sw.js @@ -2,7 +2,7 @@ workbox.core.setCacheNameDetails({ prefix: "d4" }); //Change this value every time before you build -const LATEST_VERSION = "v2.0.4"; +const LATEST_VERSION = "v2.0.5"; self.addEventListener("activate", (event) => { console.log(`%c ${LATEST_VERSION} `, "background: #ddd; color: #0000ff"); if (caches) {