fix: API_URL not defined in shuttle/admin views + fix shuttle card image display

This commit is contained in:
2026-02-26 11:46:37 -05:00
parent 86726e3dfc
commit ba7631dc9c
6 changed files with 19 additions and 41 deletions

View File

@ -4,6 +4,8 @@ import { useRouter } from 'vue-router';
import { SUPABASE_URL } from '@/supabase'; import { SUPABASE_URL } from '@/supabase';
import axios from 'axios'; import axios from 'axios';
const API_URL = import.meta.env.VITE_API_URL || 'http://localhost:8000';
const router = useRouter(); const router = useRouter();
const isLoading = ref(false); const isLoading = ref(false);
const showMessage = ref({ text: '', type: '' }); const showMessage = ref({ text: '', type: '' });
@ -524,6 +526,15 @@ async function saveShuttle() {
background: #101820; background: #101820;
} }
.shuttle-card-bg {
position: absolute;
inset: 0;
width: 100%;
height: 100%;
object-fit: cover;
z-index: 0;
}
.shuttle-card-preview::before { .shuttle-card-preview::before {
content: ""; content: "";
position: absolute; position: absolute;

View File

@ -7,6 +7,8 @@ import { SUPABASE_URL } from '@/supabase'
import type { Business, Coupon } from '@/types' import type { Business, Coupon } from '@/types'
import FavoriteButton from '@/components/FavoriteButton.vue' import FavoriteButton from '@/components/FavoriteButton.vue'
const API_URL = import.meta.env.VITE_API_URL || 'http://localhost:8000';
const route = useRoute() const route = useRoute()
const router = useRouter() const router = useRouter()
const business = ref<Business | null>(null) const business = ref<Business | null>(null)

View File

@ -6,6 +6,8 @@ import { SUPABASE_URL } from '@/supabase'
import type { Coupon } from '@/types' import type { Coupon } from '@/types'
import FavoriteButton from '@/components/FavoriteButton.vue' import FavoriteButton from '@/components/FavoriteButton.vue'
const API_URL = import.meta.env.VITE_API_URL || 'http://localhost:8000';
const { t } = useI18n() const { t } = useI18n()
const couponStore = useCouponStore() const couponStore = useCouponStore()

View File

@ -5,6 +5,8 @@ import { useI18n } from 'vue-i18n'
import { useFavoritesStore } from '@/stores/favorites' import { useFavoritesStore } from '@/stores/favorites'
import { SUPABASE_URL } from '@/supabase' import { SUPABASE_URL } from '@/supabase'
const API_URL = import.meta.env.VITE_API_URL || 'http://localhost:8000';
const { t } = useI18n() const { t } = useI18n()
const router = useRouter() const router = useRouter()
const favoritesStore = useFavoritesStore() const favoritesStore = useFavoritesStore()

View File

@ -8,6 +8,8 @@ import { useAuthStore } from '@/stores/auth'
import { SUPABASE_URL } from '@/supabase' import { SUPABASE_URL } from '@/supabase'
import type { Coupon, Business, Shuttle } from '@/types' import type { Coupon, Business, Shuttle } from '@/types'
const API_URL = import.meta.env.VITE_API_URL || 'http://localhost:8000';
const route = useRoute() const route = useRoute()
const authStore = useAuthStore() const authStore = useAuthStore()

View File

@ -860,12 +860,6 @@ function getShiftLabel(shift: string) {
.btn-whatsapp .material-icons { font-size: 20px; } .btn-whatsapp .material-icons { font-size: 20px; }
/* Original Styles */ /* Original Styles */
.taxi-view {
min-height: 100vh;
position: relative;
padding: 0 0 150px; /* Aumentado para evitar solapamiento con BottomNav */
}
.taxi-view { .taxi-view {
min-height: 100vh; min-height: 100vh;
position: relative; position: relative;
@ -879,41 +873,6 @@ function getShiftLabel(shift: string) {
border: 1px solid var(--border-color); border: 1px solid var(--border-color);
} }
/* SHUTTLE CARD PREMIUM CON FONDO */
.shuttle-card {
border-radius: 20px;
overflow: hidden;
border: 1px solid var(--border-color);
background-size: cover;
background-position: center;
position: relative;
min-height: 160px;
display: flex;
flex-direction: column;
transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
cursor: pointer;
}
.shuttle-card::before {
content: "";
position: absolute;
inset: 0;
/* Gradiente más fuerte para mejor contraste sobre cualquier imagen */
background: linear-gradient(
to top,
rgba(0,0,0,0.92) 0%,
rgba(0,0,0,0.65) 50%,
rgba(0,0,0,0.45) 100%
);
z-index: 0;
}
.shuttle-main-info, .shuttle-details {
position: relative;
z-index: 1;
padding: 20px;
}
.header-main { .header-main {
padding: 24px 16px; padding: 24px 16px;
text-align: center; text-align: center;