1
0
Fork 0
mirror of https://github.com/mealie-recipes/mealie.git synced 2025-08-05 13:35:23 +02:00

Merge branch 'mealie-next' into fixes/ui-improvements

This commit is contained in:
boc-the-git 2023-11-25 20:53:49 +11:00 committed by GitHub
commit 6cec7f6dcd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
31 changed files with 151 additions and 112 deletions

View file

@ -142,7 +142,7 @@ export default defineComponent({
},
},
setup(props) {
const { $auth, $vuetify } = useContext();
const { $auth } = useContext();
const route = useRoute();
const groupSlug = computed(() => route.value.params.groupSlug || $auth.user?.groupSlug || "");
const { isOwnGroup } = useLoggedInState();
@ -168,8 +168,8 @@ export default defineComponent({
const isSame = JSON.stringify(props.recipe) === JSON.stringify(originalRecipe.value);
if (isEditMode.value && !isSame && props.recipe?.slug !== undefined) {
const save = window.confirm(
"You have unsaved changes. Do you want to save before leaving?\n\nOkay to save, Cancel to discard changes."
);
i18n.tc("general.unsaved-changes"),
);
if (save) {
await api.recipes.updateOne(props.recipe.slug, props.recipe);
@ -247,6 +247,7 @@ export default defineComponent({
/** =============================================================
* View Preferences
*/
const { $vuetify, i18n } = useContext();
const landscape = computed(() => {
const preferLandscape = props.recipe.settings.landscapeView;