Merge pull request 'added fixes for rollup build error' (#20) from rollup-fixes into main
Reviewed-on: #20
This commit is contained in:
commit
3590a3200e
15 changed files with 1326 additions and 1561 deletions
|
@ -15,7 +15,6 @@
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
const supportsHEVC = ref(false);
|
const supportsHEVC = ref(false);
|
||||||
const props = defineProps(["showQuote"]);
|
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
const isSafari = /^((?!chrome|android).)*safari/i.test(navigator.userAgent);
|
const isSafari = /^((?!chrome|android).)*safari/i.test(navigator.userAgent);
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
import placeholderPoster from "assets/img/poster-placeholder.svg";
|
import placeholderPoster from "assets/img/poster-placeholder.svg";
|
||||||
|
|
||||||
const imgRef = ref<HTMLImageElement | null>(null);
|
const imgRef = ref<HTMLImageElement | null>(null);
|
||||||
const props = defineProps(["image"]);
|
const props = defineProps<{ image: string }>();
|
||||||
|
|
||||||
const handleImageError = function (event: Event) {
|
const handleImageError = function (event: Event) {
|
||||||
(event.target as HTMLImageElement).classList.remove("lazyload");
|
(event.target as HTMLImageElement).classList.remove("lazyload");
|
||||||
|
|
|
@ -32,7 +32,7 @@
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import type { MovieList } from "~/types/movielist";
|
import type { MovieList } from "~/types/movielist";
|
||||||
|
|
||||||
const lists = defineModel<MovieList[]>("lists", { default: [] });
|
const lists = ref<MovieList[]>([]);
|
||||||
|
|
||||||
const addList = async function () {
|
const addList = async function () {
|
||||||
let config = useRuntimeConfig();
|
let config = useRuntimeConfig();
|
||||||
|
|
|
@ -26,7 +26,7 @@ const loading = ref(false);
|
||||||
const emit = defineEmits<{
|
const emit = defineEmits<{
|
||||||
(e: "show-modal", movie: Movie): void;
|
(e: "show-modal", movie: Movie): void;
|
||||||
}>();
|
}>();
|
||||||
const movies = defineModel<Movie[]>("movie_list", { default: [] });
|
const movies = ref<Movie[]>([]);
|
||||||
|
|
||||||
const showModal = (movie: Movie) => {
|
const showModal = (movie: Movie) => {
|
||||||
emit("show-modal", movie);
|
emit("show-modal", movie);
|
||||||
|
|
|
@ -28,12 +28,17 @@ import { useCookie } from "#app";
|
||||||
import type { Schedule } from "~/types/schedule";
|
import type { Schedule } from "~/types/schedule";
|
||||||
import { $fetch } from "ofetch";
|
import { $fetch } from "ofetch";
|
||||||
|
|
||||||
const showings = defineModel<Showing[]>("showings", { default: [] });
|
const showings = ref<Showing[]>([]);
|
||||||
const previous_showings = defineModel<Showing[]>("previous_showings", {
|
const previous_showings = ref<Showing[]>([]);
|
||||||
default: [],
|
|
||||||
});
|
|
||||||
const got_previous = ref(false);
|
const got_previous = ref(false);
|
||||||
const months = [
|
|
||||||
|
onMounted(() => {
|
||||||
|
getShowings();
|
||||||
|
});
|
||||||
|
|
||||||
|
const formatDate = function (date_string: string) {
|
||||||
|
let parsed_date = new Date(Date.parse(date_string));
|
||||||
|
const months = [
|
||||||
"January",
|
"January",
|
||||||
"February",
|
"February",
|
||||||
"March",
|
"March",
|
||||||
|
@ -46,14 +51,7 @@ const months = [
|
||||||
"October",
|
"October",
|
||||||
"November",
|
"November",
|
||||||
"December",
|
"December",
|
||||||
];
|
];
|
||||||
|
|
||||||
onMounted(() => {
|
|
||||||
getShowings();
|
|
||||||
});
|
|
||||||
|
|
||||||
const formatDate = function (date_string: string) {
|
|
||||||
let parsed_date = new Date(Date.parse(date_string));
|
|
||||||
let month = months[parsed_date.getMonth()];
|
let month = months[parsed_date.getMonth()];
|
||||||
|
|
||||||
return `${month} ${parsed_date.getDate()}, ${parsed_date.getFullYear()}`;
|
return `${month} ${parsed_date.getDate()}, ${parsed_date.getFullYear()}`;
|
||||||
|
|
|
@ -27,7 +27,9 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
const props = defineProps(["movie"]);
|
import type { Movie } from "~/types/movie";
|
||||||
|
|
||||||
|
const props = defineProps<{ movie: Movie }>();
|
||||||
const emits = defineEmits(["closeModal"]);
|
const emits = defineEmits(["closeModal"]);
|
||||||
|
|
||||||
const schedule = function (e: Event) {
|
const schedule = function (e: Event) {
|
||||||
|
|
|
@ -34,10 +34,11 @@
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import type { MovieList } from "~/types/movielist";
|
import type { MovieList } from "~/types/movielist";
|
||||||
|
import type { Movie } from "~/types/movie";
|
||||||
|
|
||||||
const props = defineProps(["movie"]);
|
const props = defineProps<{ movie: Movie }>();
|
||||||
const list_id = ref(0);
|
const list_id = ref(0);
|
||||||
const lists = defineModel<MovieList[]>("lists", { default: [] });
|
const lists = ref<MovieList[]>(new Array<MovieList>());
|
||||||
const emit = defineEmits<{
|
const emit = defineEmits<{
|
||||||
(e: "close-modal"): void;
|
(e: "close-modal"): void;
|
||||||
}>();
|
}>();
|
||||||
|
|
|
@ -35,8 +35,9 @@
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import ScheduleMovie from "~/components/forms/ScheduleMovie.vue";
|
import ScheduleMovie from "~/components/forms/ScheduleMovie.vue";
|
||||||
|
import type { Movie } from "~/types/movie";
|
||||||
|
|
||||||
const props = defineProps(["movie", "updating"]);
|
defineProps<{ movie: Movie; updating: boolean }>();
|
||||||
const emits = defineEmits(["close-modal", "update-movie"]);
|
const emits = defineEmits(["close-modal", "update-movie"]);
|
||||||
const logged_in = ref(false);
|
const logged_in = ref(false);
|
||||||
|
|
||||||
|
|
2780
src/package-lock.json
generated
2780
src/package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -21,5 +21,8 @@
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"lazysizes": "^5.3.2"
|
"lazysizes": "^5.3.2"
|
||||||
|
},
|
||||||
|
"overrides": {
|
||||||
|
"rollup": "4.44.2"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -58,7 +58,7 @@ import type { Movie } from "~/types/movie";
|
||||||
import Modal from "~/components/common/ui/Modal.vue";
|
import Modal from "~/components/common/ui/Modal.vue";
|
||||||
import { logout } from "~/composables/logout";
|
import { logout } from "~/composables/logout";
|
||||||
|
|
||||||
const modal_movie = defineModel<Movie>("#movie-modal");
|
const modal_movie = ref<Movie | null>(null);
|
||||||
|
|
||||||
const movie_modal = ref<InstanceType<typeof Modal> | null>(null);
|
const movie_modal = ref<InstanceType<typeof Modal> | null>(null);
|
||||||
const current_view = ref("search");
|
const current_view = ref("search");
|
||||||
|
@ -72,7 +72,7 @@ const showModal = function (movie: Movie) {
|
||||||
};
|
};
|
||||||
const toggleDisplay = function (element_id: string) {
|
const toggleDisplay = function (element_id: string) {
|
||||||
if (element_id === current_view.value) return;
|
if (element_id === current_view.value) return;
|
||||||
let tabs = ["search", "showings", "lists"];
|
const tabs = ["search", "showings", "lists"];
|
||||||
|
|
||||||
tabs.forEach((value) => {
|
tabs.forEach((value) => {
|
||||||
if (value === element_id) {
|
if (value === element_id) {
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
@update-movie="updateMovie(modal_movie)"
|
@update-movie="updateMovie(modal_movie)"
|
||||||
></ShowMovie>
|
></ShowMovie>
|
||||||
</Modal>
|
</Modal>
|
||||||
<h2 class="text-xl font-bold pb-5">{{ list.name }}</h2>
|
<h2 class="text-xl font-bold pb-5">{{ list?.name }}</h2>
|
||||||
<div
|
<div
|
||||||
v-if="movies.length > 1 && !loading"
|
v-if="movies.length > 1 && !loading"
|
||||||
class="grid grid-cols-2 rounded movie-card neon-border p-5"
|
class="grid grid-cols-2 rounded movie-card neon-border p-5"
|
||||||
|
@ -91,13 +91,11 @@ import MoviePoster from "~/components/MoviePoster.vue";
|
||||||
import ScrollToTop from "~/components/common/navigation/ScrollToTop.vue";
|
import ScrollToTop from "~/components/common/navigation/ScrollToTop.vue";
|
||||||
|
|
||||||
const list_id = ref(0);
|
const list_id = ref(0);
|
||||||
const list = defineModel<MovieList>("movie_list", { default: [] });
|
const list = ref<MovieList | null>(null);
|
||||||
const loading = ref(true);
|
const loading = ref(true);
|
||||||
const modal_movie: Ref<Movie | null> = ref(null);
|
const modal_movie: Ref<Movie | null> = ref(null);
|
||||||
const movies = defineModel<Movie[] | []>("movies", {
|
const movies = ref<Movie[]>(new Array<Movie>());
|
||||||
default: [],
|
const filtered_movies = ref<Movie[]>(new Array<Movie>());
|
||||||
});
|
|
||||||
const filtered_movies = defineModel<Movie[]>("filtered_movies");
|
|
||||||
const movie_query = ref("");
|
const movie_query = ref("");
|
||||||
const logged_in = ref(false);
|
const logged_in = ref(false);
|
||||||
const hide_scheduled = ref(false);
|
const hide_scheduled = ref(false);
|
||||||
|
@ -119,7 +117,7 @@ const getList = async function (list_id: number) {
|
||||||
})
|
})
|
||||||
.then((data) => {
|
.then((data) => {
|
||||||
list.value = data;
|
list.value = data;
|
||||||
movies.value = data?.movies || [];
|
movies.value = data?.movies || new Array<Movie>();
|
||||||
filtered_movies.value = movies.value;
|
filtered_movies.value = movies.value;
|
||||||
loading.value = false;
|
loading.value = false;
|
||||||
})
|
})
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
import type { MovieList } from "~/types/movielist";
|
import type { MovieList } from "~/types/movielist";
|
||||||
import { useCookie } from "#app";
|
import { useCookie } from "#app";
|
||||||
|
|
||||||
const lists = defineModel<MovieList[]>("movie_list", { default: [] });
|
const lists = ref<MovieList[]>(new Array<MovieList>());
|
||||||
const loading = ref(true);
|
const loading = ref(true);
|
||||||
|
|
||||||
const updateLists = async function () {
|
const updateLists = async function () {
|
||||||
|
@ -47,7 +47,7 @@ const updateLists = async function () {
|
||||||
headers: headers,
|
headers: headers,
|
||||||
})
|
})
|
||||||
.then((data) => {
|
.then((data) => {
|
||||||
lists.value = data || [];
|
lists.value = data || new Array<MovieList>();
|
||||||
loading.value = false;
|
loading.value = false;
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
|
|
|
@ -74,33 +74,22 @@ import type { Schedule } from "~/types/schedule";
|
||||||
import { $fetch } from "ofetch";
|
import { $fetch } from "ofetch";
|
||||||
import { useCookie } from "#app";
|
import { useCookie } from "#app";
|
||||||
|
|
||||||
const schedule = defineModel<Schedule>("schedule");
|
const schedule = ref<Schedule>();
|
||||||
const past_showings = defineModel<Showing[]>("past_showings", {
|
const past_showings = ref<Showing[]>(new Array<Showing>());
|
||||||
default: [],
|
|
||||||
});
|
|
||||||
const loading = ref(true);
|
const loading = ref(true);
|
||||||
const loadingPrevious = ref(false);
|
const loadingPrevious = ref(false);
|
||||||
const got_previous = ref(false);
|
const got_previous = ref(false);
|
||||||
const months = [
|
|
||||||
"January",
|
|
||||||
"February",
|
|
||||||
"March",
|
|
||||||
"April",
|
|
||||||
"May",
|
|
||||||
"June",
|
|
||||||
"July",
|
|
||||||
"August",
|
|
||||||
"September",
|
|
||||||
"October",
|
|
||||||
"November",
|
|
||||||
"December",
|
|
||||||
];
|
|
||||||
|
|
||||||
const formatDate = function (date_string: string) {
|
const formatDate = function (date_string: string) {
|
||||||
let date = new Date(date_string);
|
let date = new Date(date_string);
|
||||||
let month = months[date.getMonth()];
|
//let month = months[date.getMonth()];
|
||||||
|
|
||||||
return `${month} ${date.getDate()}, ${date.getFullYear()}`;
|
//return `${month} ${date.getDate()}, ${date.getFullYear()}`;
|
||||||
|
return new Intl.DateTimeFormat("en-US", {
|
||||||
|
month: "long",
|
||||||
|
day: "numeric",
|
||||||
|
year: "numeric",
|
||||||
|
}).format(date);
|
||||||
};
|
};
|
||||||
|
|
||||||
const getSchedule = async function (previous = false) {
|
const getSchedule = async function (previous = false) {
|
||||||
|
|
|
@ -4,7 +4,7 @@ import type { UserProfile } from "~/types/userProfile";
|
||||||
|
|
||||||
const config = useRuntimeConfig();
|
const config = useRuntimeConfig();
|
||||||
|
|
||||||
const profile = defineModel<UserProfile>("profile");
|
const profile = ref<UserProfile | null>(null);
|
||||||
const loading = ref(true);
|
const loading = ref(true);
|
||||||
|
|
||||||
const getProfile = async function () {
|
const getProfile = async function () {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue