Skip to content

Commit

Permalink
#74 (style) - Clean styles for actionsCardButton (Like, favorites, wa…
Browse files Browse the repository at this point in the history
…tch later) + add components for card speaker
  • Loading branch information
robinlopez authored and fcamblor committed Aug 27, 2024
1 parent 7e94358 commit b1db052
Show file tree
Hide file tree
Showing 6 changed files with 316 additions and 116 deletions.
27 changes: 27 additions & 0 deletions mobile/src/components/speaker-card/SpeakerLikeButton.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<template>
<!-- TODO Dev Btn -->
<ion-button class="btnActionCard" :class="{ 'btnActionCard': true, '_is-active': true }" :aria-label="LL.Like_Speaker()">
<span class="btnActionCard-group">
<ion-icon class="btnActionCard-group-icon" v-if="true" aria-hidden="true" src="/assets/icons/line/heart-line.svg"></ion-icon>
<ion-icon class="btnActionCard-group-icon" v-if="false" aria-hidden="true" src="/assets/icons/solid/heart.svg"></ion-icon>
<ion-label class="btnActionCard-group-nb" v-if="true">-</ion-label>
</span>
</ion-button>
</template>

<script setup lang="ts">
import {typesafeI18n} from "@/i18n/i18n-vue";
const { LL } = typesafeI18n()
</script>

<style scoped lang="scss">
.btnActionCard {
&._is-active {
--background: var(--voxxrin-event-theme-colors-primary-hex);
--color: var(--voxxrin-event-theme-colors-primary-contrast-hex);
border-left: 1px solid var(--app-primary-shade);
--border-radius: 0 0 8px 0 !important;
}
}
</style>
94 changes: 94 additions & 0 deletions mobile/src/components/speaker-card/SpeakerResumeTalk.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
<template>
<!-- TODO Dev Resume Card -->
<ion-item class="talkResumeCard">
<span class="talkResumeCard-line"></span>
<div class="talkResumeCard-content">
<ion-text class="talkResumeCard-content-description">
Unlocking the Secrets of the Devoxx Mobile App: A Deep Dive into Open Source PWA with Vue and Firebase
</ion-text>
<div class="talkResumeCard-footer">
<ion-badge class="trackBadge">
<div class="trackBadge-content">
<ion-icon src="/assets/icons/solid/tag.svg"></ion-icon>JAVA
</div>
</ion-badge>
<div class="avatarContainer">
<div class="avatarGroup" v-if="true">
<div class="avatarItem">
<ion-thumbnail class="avatar _small">
<img v-if="false" :src="speaker.photoUrl" @error="handle404OnSpeakerThumbnail($event.target as HTMLImageElement)" />
<img v-if="true" :src="baseUrl+'assets/images/svg/avatar-shadow.svg'" />
</ion-thumbnail>
</div>
</div>
<div class="avatarInfos _small">
<ion-text class="avatarInfos-title">Conference</ion-text>
<ion-text class="avatarInfos-subTitle" v-if="true">
(+X Speaker(s))
</ion-text>
</div>
</div>
</div>
</div>
</ion-item>
</template>

<script setup lang="ts">
import {typesafeI18n} from "@/i18n/i18n-vue";
import {IonBadge, IonThumbnail} from "@ionic/vue";
const { LL } = typesafeI18n()
const baseUrl = import.meta.env.BASE_URL;
</script>

<style lang="scss" scoped>
.talkResumeCard {
--padding-start: 0;
--inner-padding-top: var(--app-gutters-medium);
--inner-padding-bottom: var(--app-gutters-medium);
padding: 0;
&:last-child {
--border-style: none;
--inner-padding-bottom: 0;
}
&-line {
height: 100%;
min-width: 2px;
margin-right: var(--app-gutters-medium);
border-radius: 4px;
background: var(--app-primary);
}
&-content {
flex: 1;
display: flex;
flex-direction: column;
align-items: center;
gap: var(--app-gutters-medium);
&-description {
width: 100%;
font-size: 14px;
line-height: 1.2;
color: var(--app-primary);
}
}
&-footer {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
.avatarContainer {
gap: var(--app-gutters);
}
.avatarInfos {
justify-content: end;
}
}
}
</style>
21 changes: 0 additions & 21 deletions mobile/src/components/talk-card/ScheduleTalk.vue
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,6 @@ const theme = {
}
//* States card talk *//
&._is-highlighted {
border : {
top: 2px solid var(--app-primary);
Expand Down Expand Up @@ -380,27 +379,7 @@ const theme = {
.talkCard-footer {
border-color: var(--app-primary-shade);
/* TODO RLZ: move it to a proper place in talk actions components */
:deep(.btnActionCard) { border-color: var(--app-primary-shade);}
}
}
//* TODO - Start - Delete when btn is component *//
//* Change style type actions *//
ion-button {
&.btn-watchLater {
--background: var(--voxxrin-event-theme-colors-secondary-hex);
--color: var(--voxxrin-event-theme-colors-secondary-contrast-hex);
border-left: 1px solid var(--voxxrin-event-theme-colors-secondary-hex);
}
&.btn-feedbackSelect {
--background: var(--voxxrin-event-theme-colors-primary-hex);
--color: var(--voxxrin-event-theme-colors-primary-contrast-hex);
border-left: 1px solid var(--voxxrin-event-theme-colors-primary-hex);
}
//* END - Delete when btn is component *//
}
}
Expand Down
8 changes: 8 additions & 0 deletions mobile/src/styles/components/_avatar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@
color: var(--app-primary);
font-size: 16px;
line-height: 1.2;

@media (prefers-color-scheme: dark) {
color: var(--app-white);
}
}

&-subTitle {
Expand All @@ -64,6 +68,10 @@
align-items: center;
gap: var(--app-gutters-tiny);
font-weight: 500;

@media (prefers-color-scheme: dark) {
color: var(--app-whit-90);
}
}
}
}
56 changes: 37 additions & 19 deletions mobile/src/styles/vendors/ionic/customs/_custom-ion-buttons.scss
Original file line number Diff line number Diff line change
Expand Up @@ -103,28 +103,46 @@ ion-button {
}
}
}
}

/* TODO RLZ: move it to a proper place in talk actions components */
&.btnActionCard {
height: 100% !important;
min-height: 55px !important;
width: 58px !important;
margin: 0;
--border-radius: 0;
--background: rgba(white, 0.5);
--color: var(--app-primary);
border-left: 1px solid var(--app-grey-line);
font-size: 22px;
--padding-start: 0;
--padding-end: 0;
--background-activated-opacity: 0.1;
--background-hover-opacity: 0.1;
--box-shadow: none;
.btnActionCard {
height: 100% !important;
min-height: 55px !important;
width: 58px !important;
margin: 0;
--border-radius: 0;
--background: rgba(white, 0.5);
--color: var(--app-primary);
border-left: 1px solid var(--app-grey-line);
font-size: 22px;
--padding-start: 0;
--padding-end: 0;
--background-activated-opacity: 0.1;
--background-hover-opacity: 0.1;
--box-shadow: none;

&.button-solid {
@media (prefers-color-scheme: dark) {
--background: rgba(white, 0.2);
--color: var(--app-white);
border-left: 1px solid var(--app-line-contrast);
border-color: var(--app-line-contrast);
--background: transparent;
color: var(--app-white);
}
}

.btnActionCard-group {
display: flex;
flex-direction: column;
align-items: center;
row-gap: 2px;

&-icon {
position: relative;
font-size: 26px;
}

&-nb {
font-size: 14px !important;
font-weight: 700;
}
}
}
Expand Down
Loading

0 comments on commit b1db052

Please sign in to comment.