54 Commits

Author SHA1 Message Date
boc-the-git
a062a4beaa
feat: Add the ability to flag a food as "on hand", to exclude from shopping list (#3777) 2024-06-28 15:16:04 +00:00
Michael Genson
4afb767375
feat: Open AI Recipe Scraper (#3690) 2024-06-07 11:45:50 +00:00
Jonathan Beaulieu
f4f2b863e0
feat: Add recipekeeper migration (#3642) 2024-05-31 09:58:04 +00:00
Michael Genson
ca26639525
feat: Data Management from Shopping List (#3603)
Co-authored-by: boc-the-git <3479092+boc-the-git@users.noreply.github.com>
2024-05-22 21:58:16 +00:00
Michael Genson
5c57b3dd1a
feat: OpenAI Ingredient Parsing (#3581) 2024-05-22 09:45:07 +00:00
Michael Genson
61becdbec7
chore: Remove Server Tasks (#3592) 2024-05-20 14:51:37 +00:00
Michael Genson
3807778e2f
feat: Recipe Actions (#3448)
Co-authored-by: boc-the-git <3479092+boc-the-git@users.noreply.github.com>
Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
2024-05-01 09:20:52 +02:00
Michael Genson
ec458a0a08
fix: Security Issues (#3530)
Co-authored-by: boc-the-git <3479092+boc-the-git@users.noreply.github.com>
2024-04-30 20:53:55 +00:00
Hayden
6bd5a82b92
rewrite logger to support custom config files (#3104) 2024-04-16 15:52:49 +00:00
Michael Genson
2a541f081a
feat: User-specific Recipe Ratings (#3345) 2024-04-11 21:28:43 -05:00
Kuchenpirat
a283828461
refactor: Sidebar UI (#3390)
* Refactor sidebar links in DefaultLayout.vue

* 🧹
2024-04-01 10:16:52 +02:00
Michael Genson
52c6fe34b2 remove potentially sensitive fields from group self 2024-03-15 19:50:39 +00:00
Michael Genson
63a362a48a
fix: Limit shopping list owners to current group (#3305)
* add route for getting group-only users

* add new api route to frontend

* update shopping list user getAll call

* tests

* fixed bad import

* replace UserOut with UserSummary

* fix params
2024-03-13 18:29:00 +00:00
Michael Genson
403038a5b2
feat: First Time Setup Wizard (#3204)
* extract user registration form into a composable

* added base wizard component

* added partial setup implementation

* removed unused attrs

* added setup bypass

* made setup page more readable

* add checkbox hints to autoform

* added common settings pages and initial submit logic

* bypass setup in demo

* add full name to user registration

* added fullname and pw handling to setup

* fixed wizard indentation

* added post-setup suggestions

* added tests for backend changes

* renamed Wizard to BaseWizard

* lint fixes

* pass hardcoded default password instead of backend nonsense

* removed old test

* fix e2e

* added setup skip to e2e testing for all admin users

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2024-03-11 13:28:54 +00:00
Hayden
5f6844eceb
feat: Login with OAuth via OpenID Connect (OIDC) (#3280)
* initial oidc implementation

* add dynamic scheme

* e2e test setup

* add caching

* fix

* try this

* add libldap-2.5 to runtime dependencies (#2849)

* New translations en-us.json (Norwegian) (#2851)

* New Crowdin updates (#2855)

* New translations en-us.json (Italian)

* New translations en-us.json (Norwegian)

* New translations en-us.json (Portuguese)

* fix

* remove cache

* cache yarn deps

* cache docker image

* cleanup action

* lint

* fix tests

* remove not needed variables

* run code gen

* fix tests

* add docs

* move code into custom scheme

* remove unneeded type

* fix oidc admin

* add more tests

* add better spacing on login page

* create auth providers

* clean up testing stuff

* type fixes

* add OIDC auth method to postgres enum

* add option to bypass login screen and go directly to iDP

* remove check so we can fallback to another auth method oauth fails

* Add provider name to be shown at the login screen

* add new properties to admin about api

* fix spec

* add a prompt to change auth method when changing password

* Create new auth section. Add more info on auth methods

* update docs

* run ruff

* update docs

* format

* docs gen

* formatting

* initialize logger in class

* mypy type fixes

* docs gen

* add models to get proper fields in docs and fix serialization

* validate id token before using it

* only request a mealie token on initial callback

* remove unused method

* fix unit tests

* docs gen

* check for valid idToken before getting token

* add iss to mealie token

* check to see if we already have a mealie token before getting one

* fix lock file

* update authlib

* update lock file

* add remember me environment variable

* add user group setting to allow only certain groups to log in

---------

Co-authored-by: Carter Mintey <cmintey8@gmail.com>
Co-authored-by: Carter <35710697+cmintey@users.noreply.github.com>
2024-03-10 13:51:36 -05:00
Michael Genson
8e5ea1df5e added "show all" toggle on list of shopping lists 2024-02-23 17:07:43 +00:00
Michael Genson
f42114e966
feat: Redirect Logged Out Users to Default Group, If It's Public (#2772)
* add default group slug to app info if public

* redirect public user to default group

* added tests

---------

Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
2024-02-07 07:53:55 -09:00
Hayden
8d8a101580
chore: code gen (#3012)
* code-gen

* remove old generator commands

* remove old docker stuff
2024-01-20 16:34:57 +00:00
Michael Genson
ca9f66ee24
feat: Remove OCR Support (#2838)
* remove ocr package

* remove tesseract

* remove OCR from app

* remove OCR from tests

* fix docs
2023-12-14 17:26:43 -09:00
Hayden
bc575ec5ae
feat: auto detect first login (#2722)
* 'hide' default email and password env variables

* first login API endpoint

* run code-generators

* frontend indicators for default username and pw

* remove old env variables from docs

* fix env set variable

* remove password from tests
2023-11-15 15:24:24 +00:00
Michael Genson
d440d51ffe
feat: plural foods and units, and aliases (#2674)
* added plural names and alias tables to foods/units

* updated models to include plural names and aliases

* updated parser to include plural and aliases

* fixed migrations

* fixed recursive models

* added plural abbreviation to migration

* updated parser and display prop

* update displays to use plurals

* fix display edgecase and remove print

* added/updated display tests

* fixed model bug and added parser tests

* added tests for aliases

* added new plural options to data management page

* removed unique constraint

* made base dialog more customizable

* added alias management to food and unit data pages

* removed unused awaits

* 🧹
2023-11-14 06:39:07 -09:00
Michael Genson
80968b02bb
feat: Remove Explore URLs and make the normal URLs public (#2632)
* add groupSlug to most routes

* fixed more routing issues

* fixed jank and incorrect routes

* remove public explore links

* remove unused groupSlug and explore routes

* nuked explore pages

* fixed public toolstore bug

* fixed various routes missing group slug

* restored public app header menu

* fix janky login redirect

* 404 recipe API call returns to login

* removed unused explore layout

* force redirect when using the wrong group slug

* fixed dead admin links

* removed unused middleware from earlier attempt

* 🧹

* improve cookbooks sidebar
fixed sidebar link not working
fixed sidebar link target
hide cookbooks header when there are none

* added group slug to user

* fix $auth typehints

* vastly simplified groupSlug logic

* allow logged-in users to view other groups

* fixed some edgecases that bypassed isOwnGroup

* fixed static home ref

* 🧹

* fixed redirect logic

* lint warning

* removed group slug from group and user pages
refactored all components to use route groupSlug or user group slug
moved some group pages to recipe pages

* fixed some bad types

* 🧹

* moved groupSlug routes under /g/groupSlug

* move /recipe/ to /r/

* fix backend url generation and metadata injection

* moved shopping lists to root/other route fixes

* changed shared from /recipes/ to /r/

* fixed 404 redirect not awaiting

* removed unused import

* fix doc links

* fix public recipe setting not affecting public API

* fixed backend tests

* fix nuxt-generate command

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-11-05 16:07:02 -09:00
Arsène Reymond
f7f8c51661
feat: update organization icons (#2668)
* front: update filters icons

* remove duplicate

---------

Co-authored-by: Michael Genson <71845777+michael-genson@users.noreply.github.com>
2023-10-25 15:08:58 +00:00
NullCosmos
f72fcc3031
feat: Implemented Plan to Eat migration (#2635)
Co-authored-by: Michael Genson <71845777+michael-genson@users.noreply.github.com>
2023-10-15 20:01:07 +00:00
Michael Genson
3e5596f898
fix: Home Doesn't Load For Non-Admin Users (#2556)
* added non-admin route for fetching current group

* simplified frontend group slug fetching

* exposed public link even if user can't invite

* 🧹
2023-09-19 09:06:39 -08:00
Grygon
9a04b11ee5
fix: #2534 - Add clearable ratings (#2541)
* Add clearable to RecipeRating, Fix #2534

* Make rating nullable

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-09-15 19:10:44 +00:00
Michael Genson
2c5e5a8421
feat: Public Recipe Browser (#2525)
* fixed incorrect var ref

* added public recipe pagination route

* refactored frontend public/explore API

* fixed broken public cards

* hid context menu from cards when public

* fixed public app header

* fixed random recipe

* added public food, category, tag, and tool routes

* not sure why I thought that would work

* added public organizer/foods stores

* disabled clicking on tags/categories

* added public link to profile page

* linting

* force a 404 if the group slug is missing or invalid

* oops

* refactored to fit sidebar into explore

* fixed invalid logic for app header

* removed most sidebar options from public

* added backend routes for public cookbooks

* added explore cookbook pages/apis

* codegen

* added backend tests

* lint

* fixes v-for keys

* I do not understand but sure why not

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-09-14 06:01:24 -08:00
Michael Genson
693608d59f
feat: cook timer (#2508)
* updated base button group

* added kitchen timer

* added missing icon

* usability tweaks

* for for menu rendering over app bar

* clean up types

* fix for mp3 loading, maybe?

* spooky linter fixes

* for real this time

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-08-23 09:31:23 -08:00
Michael Genson
d6e4829e6f
feat: Display Shopping List Item Recipe Refs (#2501)
* added recipe ref display to shopping list items

* added backend support for recipe notes

* added recipe note to item recipe ref display

* fixed note merge bug with 3+ notes

* tweak display

* lint

* updated alembic refs

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-08-21 09:18:37 -08:00
Michael Genson
2151451634
feat: Timeline Image Uploader Improvements (#2494)
* improved UI responsiveness and added image preview

* added global image cropper component

* added image cropper to last made dialog

* style tweaks

* added more specific text for creating event

* mopped up some slop

* renamed height and width vars

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-08-21 15:00:37 +00:00
Hayden
c60c63852b
chore: bump deps (#2513)
* bump dependencies

* run code-generator

* add direct dependency to text-unidecode

* fix dev dependencies group
2023-08-20 16:09:13 -08:00
Michael Genson
095edef95e
feat: Improve Public URL Readability (#2482)
* added support for group slugs

* modified frontend to use links with group slug

* fixed test refs

* unused import

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-08-20 10:38:46 -08:00
Michael Genson
dfe4942451
feat: Recipe Timeline Images (#2444)
* refactored recipe image paths/service

* added routes for updating/fetching timeline images

* make generate

* added event image upload and rendering

* switched update to patch to preserve timestamp

* added tests

* tweaked order of requests

* always reload events when opening the timeline

* re-arranged elements to make them look nicer

* delete files when timeline event is deleted
2023-08-06 09:49:30 -08:00
Michael Genson
0f896107f9
feat: Migrate from Tandoor (#2438)
* added tandoor migration to backend

* added tandoor migration to frontend

* updated tests

* ignore 0 amounts

* refactored ingredient display calculation

* fix parsing tandoor recipes with optional data

* generated frontend types

* fixed inconsistent default handling and from_orm

* removed unused imports
2023-07-23 09:52:09 -08:00
Jacob Corn
e1d3a247c7
feat: random sort option for front page (#2363)
* Add hook for random sorting

* Add random sorting to front page

* Add multiple tests for random sorting.

* Be extra sure that all recipes are returned.

* Too stable random. seed doesn't reach backend.

* add timestamp to useRecipeSearch

* Update randomization tests for timestamp seeding

* ruff cleanup

* pass timestamp separately in getAll

* remove debugging log items

* remove timestamp from address bar

* remove defaults from backend timestamps

* timestamp should be optional

* fix edge case: query without timestamp

* similar edge case: no timestamp in pagination

* ruff :/

* better edge case handling

* stabilize random search test w/more recipes

* better pagination seeding

* update pagination seed test

* remove redundant random/seed check

* Test for api routes to random sorting.

* please the typing gods

* hack to make query parameters throw correct exc

* ruff

* fix validator message typo

* black reformatting

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-05-29 16:56:20 -08:00
Michael Genson
fe17922bb8
Feature: Global Timeline (#2265)
* extended query filter to accept nested tables

* decoupled timeline api from recipe slug

* modified frontend to use simplified events api

* fixed nested loop index ghosting

* updated existing tests

* gave mypy a snack

* added tests for nested queries

* fixed "last made" render error

* decoupled recipe timeline from dialog

* removed unused props

* tweaked recipe get_all to accept ids

* created group global timeline
added new timeline page to sidebar
reformatted the recipe timeline
added vertical option to recipe card mobile

* extracted timeline item into its own component

* fixed apploader centering

* added paginated scrolling to recipe timeline

* added sort direction config
fixed infinite scroll on dialog
fixed hasMore var not resetting during instantiation

* added sort direction to user preferences

* updated API docs with new query filter feature

* better error tracing

* fix for recipe not found response

* simplified recipe crud route for slug/id
added test for fetching by slug/id

* made query filter UUID validation clearer

* moved timeline menu option below shopping lists

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
2023-04-25 09:46:00 -08:00
Michael Genson
3118b0e423
feat: Migrate from Copy Me That (#2212)
* implemented copymethat migration

* added migration tree

* added translation support

* genericized example jpgs

* added test data

* fixed test archive

* switched recipe create to service
added test for timeline event creation

* linting

* lxml go brrr
2023-03-12 12:37:24 -08:00
Carter
93eb2af087
feature: add password reset token endpoint to the admin panel (#2171)
* add password reset token endpoint to the admin panel

* add None check on token

* add localization message for passowrd reset link button
2023-03-12 12:33:36 -08:00
Sören
84d55eb920
fix: #2169 webhooks not firing (#2178)
* fix webhooks not firing due to missing session

* disable webhook test button because it doesnt do anything

* fix background task administration not working at all

* fix error in test
2023-02-26 10:27:22 -09:00
Sören
541cdc79aa
fix: 2148 infinite scroll on search (#2173)
* refactor recipe card section to use unified query construct

* rework search page so it uses lazy-loading of RecipeCardSection

* remove RecipeQuery again

* prettier reformatting

* remove recipes/all page

* remove max results setting from search

* fix typing issues
2023-02-26 10:20:26 -09:00
Carter
2e6ad5da8e
Feature: Add "Authentication Method" to allow existing users to sign in with LDAP (#2143)
* adds authentication method for users

* fix db migration with postgres

* tests for auth method

* update migration ids

* hide auth method on user creation form

* (docs): Added documentation for the new authentication method

* update migration

* add  to auto-form instead of having hidden fields
2023-02-26 10:12:16 -09:00
Michael Genson
fd03d468d4
Fix: Allow Last Made to be Updated on Locked Recipes (#2140)
* allow certain props to be updated on locked recipe

* pytest

* added "last_made" to hardcoded datetime fields

* refactored last made to its own route

* codegen/types

* updated pytest
2023-02-21 18:59:22 -09:00
Michael Genson
a6c46a7420
Feature: Shopping List Label Section Improvements (#2090)
* added backend for shopping list label config

* updated codegen

* refactored shopping list ops to service
removed unique contraint
removed label settings from main route/schema
added new route for label settings

* codegen

* made sure label settings output in position order

* implemented submenu for label order drag and drop

* removed redundant label and tweaked formatting

* added view by label to user preferences

* made items draggable within each label section

* moved reorder labels to its own button

* made dialog scrollable

* fixed broken model

* refactored labels to use a service
moved shopping list label logic to service
modified label seeder to use service

* added tests

* fix for first label missing the tag icon

* fixed wrong mapped type

* added statement to create existing relationships

* fix restore test, maybe
2023-02-21 18:58:41 -09:00
Michael Genson
5562effd66
feat: select ingredients to add to shopping List (#2136)
* added recipe ingredient override to backend

* pytest

* new dialog to filter recipe items added to list
2023-02-19 16:20:32 -09:00
Michael Genson
670907b563
feat: Print Preferences (#2131)
* added basic recipe print settings
added print settings dialog
refactored print view to live inside print container

* removed unwanted padding

* changed preferences layout
2023-02-19 15:37:18 -09:00
Hayden
71f8c1066a
feat: server side search (#2112) (#2117)
* feat: server side search API (#2112)

* refactor repository_recipes filter building

* add food filter to recipe repository page_all

* fix query type annotations

* working search

* add tests and make sure title matches are ordered correctly

* remove instruction matching again

* fix formatting and small issues

* fix another linting error

* make search test no rely on actual words

* fix failing postgres compiled query

* revise incorrectly ordered migration

* automatically extract latest migration version

* test migration orderes

* run type generators

* new search function

* wip: new search page

* sortable field options

* fix virtual scroll issue

* fix search casing bug

* finalize search filters/sorts

* remove old composable

* fix type errors

---------

Co-authored-by: Sören <fleshgolem@gmx.net>
2023-02-11 21:26:10 -09:00
Michael Genson
617cc1fdfb
Refactor Shopping List API (#2021)
* tidied up shopping list item models
redefined recipe refs and updated models
added calculated display attribute to unify shopping list item rendering
added validation to use a food's label if an item's label is null

* fixed schema reference

* refactored shopping list item service
route all operations through one central method to account for edgecases
return item collections for all operations to account for merging
consolidate recipe items before sending them to the shopping list

* made fractions prettier

* replaced redundant display text util

* fixed edgecase for zero quantity items on a recipe

* fix for pre-merging recipe ingredients

* fixed edgecase for merging create_items together

* fixed bug with merged updated items creating dupes

* added test for self-removing recipe ref

* update items are now merged w/ existing items

* refactored service to make it easier to read

* added a lot of tests

* made it so checked items are never merged

* fixed bug with dragging + re-ordering

* fix for postgres cascade issue

* added prevalidator to recipe ref to avoid db error
2023-01-28 15:45:02 -09:00
Michael Genson
c4eebaccca
Fix for shopping list recipe delete route (#1954)
* fixed broken types

* changed remove recipe route from delete to post
2022-12-30 22:09:22 -09:00
Michael Genson
46cc3898ab
feat: Improved Recipe Scaling Support and Shopping List Recipe Refactor (#1847)
* propogate scale changes to print view

* fixed incorrect variable reference

* refactored shopping list recipe routes
cleaned up existing logic
added support for recipe scaling

* updated current revision

* adding to shopping list respects UI recipe scale

* added field annotations

* added tests for recipe scaling

* made column nullable and set to 1 during migration
2022-12-30 13:47:35 -09:00
Michael Genson
4e8e2d7510
Feat/recipe timeline event UI (#1831)
* added new icons

* added timeline badge and dialog to action menu

* more icons

* implemented timeline dialog using temporary API

* added route for fetching all timeline events

* formalized API call and added mobile-friendly view

* cleaned tags

* improved last made UI for mobile

* added event context menu with placeholder methods

* adjusted default made this date
set time to 1 minute before midnight
adjusted display to properly interpret UTC

* fixed local date display

* implemented update/delete routes

* fixed formating for long subjects

* added api error handling

* made everything localizable

* fixed weird formatting

* removed unnecessary async

* combined mobile/desktop views w/ conditional attrs
2022-12-11 12:16:55 -09:00