Commit Graph

11 Commits

Author SHA1 Message Date
vincanger
7d36c8f0b1 Refactor file upload and toast notifications (#472)
* Refactor file upload and toast notifications

Replaces react-hot-toast with a custom toast system using @radix-ui/react-toast, updating all usages and adding new UI components for toast and dialog. Refactors file upload to use a two-step process: first generating an S3 upload URL, then adding the file to the database, and adds file deletion support with confirmation dialog and S3 cleanup. Updates Prisma schema, removes unused fields, and cleans up navigation and admin settings page.

* Enforce file upload limit and update dependencies on opensaas-sh

Added a check to restrict users to 2 file uploads in the demo, with a new helper function and error handling. Updated navigation items, improved landing page content, and removed unused dependencies (react-hot-toast). Added @radix-ui/react-toast, updated testimonials, and made minor content and code improvements.

* update tests

* Improve file deletion error handling and cleanup

Refactors file deletion to delete the database record before attempting S3 deletion, ensuring the file is removed from the app even if S3 deletion fails. Adds error logging for failed S3 deletions to aid in manual cleanup. Also simplifies error handling in the file upload page and removes unused imports in the demo app page.

* Add credit check and S3 file existence validation

Added logic to decrement user credits or throw an error if out of credits in the AI demo app. Updated file upload operations to validate file existence in S3 before adding to the database, and implemented S3 file existence check utility. Minor UI and code improvements included.

* Update s3Utils.ts

* update app_diff

* fix diff

* Update deletions

* Improve toast UI, error handling, and credit messaging

Updated toast action hover style and icon spacing for better UI consistency. Enhanced error handling in file deletion to display specific error messages. Refined credit/subscription error message in GPT response operation for clarity and removed redundant credit decrement logic.

* Refactor file upload validation and error handling

Replaces error state management with toast notifications for file upload errors and success. Refactors file type validation to use a new ALLOWED_FILE_TYPES_CONST and type AllowedFileTypes. Updates validation logic to throw errors instead of returning error objects, and simplifies type handling across file upload modules.

* Refactor file upload to use s3Key and add cleanup job

Replaces the 'key' field with 's3Key' for file storage references throughout the codebase and database schema. Updates all related logic, types, and API contracts to use 's3Key'. Adds a scheduled job to delete old files from S3 and the database. Cleans up file type validation constants and improves consistency in file upload and download operations.

* add orphaned file clean up

* remove s3 cleanup job from template

removed but added suggestion to docs.

* Update SettingsPage.tsx

* prettier format

* Update  UI, remove unused files

Updated README with deployment and demo details. Removed unused App.tsx and package-lock.json files. Modified Main.css, NavBar constants, file uploading logic, file upload operations, and landing page content sections for improved UI and functionality.

* remove pricing page from isMarketingPage
2025-10-15 12:01:08 +02:00
Mihovil Ilakovac
09ea4ee982 Updates for Wasp 0.17.0 (#448)
Co-authored-by: Filip Sodić <filip.sodic@fer.hr>
2025-07-10 16:16:19 +02:00
vincanger
5c1ec767df update migrations and docs 2025-02-20 10:55:37 +01:00
vincanger
98dcc43eb8 fix migration issue 2024-11-26 19:52:58 +01:00
vincanger
85fcc8be96 small migration and error fix 2024-11-19 10:24:42 +01:00
vincanger
a8654e3d64 Improve Nav Bar & use Wasp Link components (#311)
* fix Links and Nav Bar

* update app_diff

* Update NavBar.tsx

* use react-router-dom instead of wasp router

* fix app_diff

* use Wasp Router Link where necessary

* Update NavBar.tsx
2024-11-15 16:13:25 +01:00
vincanger
3bb78654d8 Use webp over png and lazy load images (#314)
* use webp and lazy load images

* fix hero

* update app_diff

* fix app_diff

* fix head

* remove async decoding
2024-11-12 13:38:06 +01:00
vincanger
94a6b8f645 Upgrade v0.14 (#232)
* Create schema.prisma

* update admin pages

* update app_diff

* Update e2e-tests.yml

* update docs & rename hook

* Update schema.prisma

* update app_diff

* add discord auth and app_diff

* update docs

* Update template/app/src/auth/userSignupFields.ts

Co-authored-by: Martin Šošić <Martinsos@users.noreply.github.com>

* move landing page

* update .env.vault

* Update e2e-tests.yml

---------

Co-authored-by: Martin Šošić <Martinsos@users.noreply.github.com>
2024-07-16 12:01:03 +02:00
vincanger
10b7596f1d create updated app_diff (#207)
* create updated app_diff

* fix requested changes
2024-07-02 17:36:49 +02:00
vincanger
602aad0f75 add cookie consent banner and tests (#163)
* add cookie consent banner and tests

* update docs and app_diff

* Create .env.client.diff

* Update main.wasp.diff

* add migrattion_lock diff again

* small typo fixes
2024-06-06 16:27:37 +02:00
Martin Šošić
04553cd60c All in dirs (#154)
* Split the project into template and opensaas-sh (demo app (diff) + docs).

* fix
2024-06-04 13:24:32 +02:00