@@ -18,8 +19,11 @@
From 3bfef2fa0a11cf223dc1cee7a30dc0f0aeec339b Mon Sep 17 00:00:00 2001
From: Alexis <35.alexis.pele@gmail.com>
Date: Fri, 19 Mar 2021 17:34:04 +0100
Subject: [PATCH 04/12] Changed the text on home
---
src/views/Home.vue | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/views/Home.vue b/src/views/Home.vue
index f6e4435..42970ba 100644
--- a/src/views/Home.vue
+++ b/src/views/Home.vue
@@ -3,11 +3,11 @@
Full Skies
- L'application Full Skies explore les cieux à votre place !
+ Explorez les cieux et le système solaire avec Full Skies !
Embarquez pour un voyage stellaire ; destination : le système solaire et
- ses astres.
+ ses astres si proches.
From b97de9e5083bd8685b32f9fa4b054cc304323baf Mon Sep 17 00:00:00 2001
From: Alexis <35.alexis.pele@gmail.com>
Date: Fri, 19 Mar 2021 17:34:22 +0100
Subject: [PATCH 05/12] Fixed the default value of CelestialsFilters.vue
---
src/components/celestials/CelestialFilters.vue | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/components/celestials/CelestialFilters.vue b/src/components/celestials/CelestialFilters.vue
index 0b2bc00..d3f3050 100644
--- a/src/components/celestials/CelestialFilters.vue
+++ b/src/components/celestials/CelestialFilters.vue
@@ -71,7 +71,7 @@ export default defineComponent({
data() {
return {
filters: {
- all: false,
+ all: true,
planets: false,
moons: false,
stars: false,
From bb62d38e6bef678b30681ce3e9241a8ff0959e3c Mon Sep 17 00:00:00 2001
From: Alexis <35.alexis.pele@gmail.com>
Date: Fri, 19 Mar 2021 17:35:24 +0100
Subject: [PATCH 06/12] Changed "celestes" to "astres"
---
src/components/Navbar.vue | 4 ++--
src/router/index.ts | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/components/Navbar.vue b/src/components/Navbar.vue
index 7eeee35..aaada17 100644
--- a/src/components/Navbar.vue
+++ b/src/components/Navbar.vue
@@ -23,8 +23,8 @@ export default defineComponent({
link: "/"
},
{
- text: "Célestes",
- link: "/celestes"
+ text: "Astres",
+ link: "/astres"
},
{
text: "À propos",
diff --git a/src/router/index.ts b/src/router/index.ts
index 7087f20..d6f1be3 100644
--- a/src/router/index.ts
+++ b/src/router/index.ts
@@ -19,12 +19,12 @@ const routes: Array
= [
component: About
},
{
- path: "/celestes",
+ path: "/astres",
name: "CelesteAll",
component: Celestials
},
{
- path: "/celestes/:slug",
+ path: "/astres/:slug",
name: "CelesteSingle",
component: Celestial,
props: true
From e4c6861c061b3fb97623aa30ff34116e4b5f9606 Mon Sep 17 00:00:00 2001
From: Alexis <35.alexis.pele@gmail.com>
Date: Fri, 19 Mar 2021 23:03:54 +0100
Subject: [PATCH 07/12] Added store favourites
---
src/components/celestials/CelestialCard.vue | 72 +++++++++++++++++++--
src/store/index.ts | 9 ++-
src/views/celestials/Celestial.vue | 10 ---
3 files changed, 72 insertions(+), 19 deletions(-)
diff --git a/src/components/celestials/CelestialCard.vue b/src/components/celestials/CelestialCard.vue
index 4d61454..84e7d12 100644
--- a/src/components/celestials/CelestialCard.vue
+++ b/src/components/celestials/CelestialCard.vue
@@ -42,6 +42,15 @@
+
-
- Détails
-
+ favorite
+
@@ -89,6 +99,8 @@
@@ -121,8 +147,18 @@ export default defineComponent({
.card-icon {
display: block;
position: absolute;
- top: 0;
+ top: 20px;
+ bottom: 20px;
+ left: 0;
right: 0;
+ user-select: none;
+ pointer-events: none;
+ opacity: 4%;
+ img {
+ height: 100%;
+ width: 100%;
+ z-index: -1;
+ }
}
> * {
@@ -135,6 +171,30 @@ export default defineComponent({
flex: 1 1 auto;
min-height: 30px;
}
+
+ .card-info {
+ position: absolute;
+ top: 0;
+ right: 0;
+ }
+
+ .card-actions {
+ color: #afafaf;
+ .favourite {
+ .icon {
+ color: #afafaf;
+ }
+ &.active {
+ .icon {
+ position: relative;
+ display: inline-block;
+ will-change: font-size;
+ animation: toggleFavHeart 0.6s cubic-bezier(0.17, 0.89, 0.32, 1.49);
+ animation-fill-mode: forwards;
+ }
+ }
+ }
+ }
}
}
diff --git a/src/store/index.ts b/src/store/index.ts
index 765e2f0..82f088d 100644
--- a/src/store/index.ts
+++ b/src/store/index.ts
@@ -3,6 +3,7 @@ import { createStore } from "vuex";
export default createStore({
state: () => ({
user: {
+ avatarUrl: "",
favourites: Array<{ id: string }>()
}
}),
@@ -12,7 +13,7 @@ export default createStore({
return state.user.favourites.length;
},
// Returns true if celestial is fav
- isAlreadyFav: state => (celestialId: string) => {
+ isFav: state => (celestialId: string) => {
return state.user.favourites.find(fav => fav.id === celestialId);
}
},
@@ -21,13 +22,15 @@ export default createStore({
state.user.favourites.push({ id: celestialId });
},
removeFav: (state, celestialId: string) => {
- state.user.favourites = state.user.favourites.filter(fav => fav.id != celestialId);
+ state.user.favourites = state.user.favourites.filter(
+ fav => fav.id != celestialId
+ );
}
},
actions: {
toggleFav: ({ commit, getters }, celestialId: string) => {
// If the celestial is not faved
- if (!getters.isAlreadyFav(celestialId)) {
+ if (!getters.isFav(celestialId)) {
// ... favs it
commit("addFav", celestialId);
} else {
diff --git a/src/views/celestials/Celestial.vue b/src/views/celestials/Celestial.vue
index 50cb7cc..02c8dda 100644
--- a/src/views/celestials/Celestial.vue
+++ b/src/views/celestials/Celestial.vue
@@ -8,7 +8,6 @@
@@ -19,8 +18,6 @@
From 6784667b92d2ce309ec75d892755407a18e71814 Mon Sep 17 00:00:00 2001
From: Alexis <35.alexis.pele@gmail.com>
Date: Fri, 19 Mar 2021 23:04:14 +0100
Subject: [PATCH 08/12] Fixed a bg pane bug and added material icons fonts
---
src/assets/scss/_animations.scss | 11 +++++++++++
src/assets/scss/_fonts.scss | 1 +
src/assets/scss/_global.scss | 15 ++++++++++++++-
3 files changed, 26 insertions(+), 1 deletion(-)
diff --git a/src/assets/scss/_animations.scss b/src/assets/scss/_animations.scss
index 601de22..db14edc 100644
--- a/src/assets/scss/_animations.scss
+++ b/src/assets/scss/_animations.scss
@@ -1,3 +1,14 @@
+@keyframes toggleFavHeart {
+ 0%, 20% {
+ color: #d01d35;
+ transform: scale(1.2);
+ }
+ 100% {
+ color: #d01d35;
+ transform: scale(1);
+ }
+}
+
@keyframes fadeInBg {
from {
opacity: 0;
diff --git a/src/assets/scss/_fonts.scss b/src/assets/scss/_fonts.scss
index 2e45106..0f8698c 100644
--- a/src/assets/scss/_fonts.scss
+++ b/src/assets/scss/_fonts.scss
@@ -1 +1,2 @@
+@import url('https://fonts.googleapis.com/icon?family=Material+Icons|Material+Icons+Round');
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Poppins:wght@400;600;700;800;900&display=swap');
\ No newline at end of file
diff --git a/src/assets/scss/_global.scss b/src/assets/scss/_global.scss
index c55b6cb..8da6a8e 100644
--- a/src/assets/scss/_global.scss
+++ b/src/assets/scss/_global.scss
@@ -66,6 +66,18 @@ a {
}
}
+button {
+ &.no-style {
+ padding: 0;
+ background: none;
+ border: none;
+ cursor: pointer;
+ &:focus {
+ outline: none;
+ }
+ }
+}
+
hr {
border-color: rgba($white, .2);
}
@@ -140,13 +152,14 @@ hr {
width: 100%;
background-size: cover;
background-attachment: fixed;
+ background-repeat: no-repeat;
z-index: -1;
opacity: 33%;
pointer-events: none;
}
&.bg-fade-in {
&:after {
- width: 120vw;
+ background-size: 120vw;
opacity: 0;
animation: fadeInBg 2s ease-out 0s 1 forwards,
paneBgAround 35s ease-in-out 0s infinite forwards;
From bbc4744eed19225b43b88de956319f8523a36f45 Mon Sep 17 00:00:00 2001
From: Alexis <35.alexis.pele@gmail.com>
Date: Sat, 20 Mar 2021 00:03:04 +0100
Subject: [PATCH 09/12] Added toast style and comp
---
src/App.vue | 5 ++-
src/assets/scss/_animations.scss | 9 +++++
src/assets/scss/_variables.scss | 10 +++++
src/components/toast/ToastCard.vue | 61 ++++++++++++++++++++++++++++
src/components/toast/ToastsList.vue | 63 +++++++++++++++++++++++++++++
5 files changed, 147 insertions(+), 1 deletion(-)
create mode 100644 src/components/toast/ToastCard.vue
create mode 100644 src/components/toast/ToastsList.vue
diff --git a/src/App.vue b/src/App.vue
index d10ed83..04fe9b4 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -4,16 +4,19 @@
+