Commit Graph

13 Commits

Author SHA1 Message Date
giancarlo
eaa163935b Upgrade multiple dependencies
Updated several dependencies that mainly include '@manypkg/cli', '@supabase/supabase-js', 'edge-csrf', 'i18next', '@types/react', 'autoprefixer', 'supabase', and '@sentry/nextjs'. This is a general dependencies update for performance and security improvements, bug fixes, and newer features. The commit also includes changes to '@babel/types' inside dependencies of several packages.
2024-04-16 15:03:41 +08:00
giancarlo
7f11905fc1 Improve tree shaking and dynamic loading, fix translations in production build. Moved i18n settings to the application's side. 2024-04-13 12:43:02 +08:00
giancarlo
f6800d3763 Update dependency versions across multiple packages
A broad range of dependency versions have been updated in numerous packages. This includes updates to major libraries such as supabase-js, react, i18next and multiple typescript definitions. The version specifier has been standardized for some packages to maintain consistency.
2024-04-13 02:13:11 +08:00
giancarlo
510356441c Update package versions for lucide-react and react-query
This commit updates the versions of the 'lucide-react' and '@tanstack/react-query' dependencies across various packages. It also removes the step to install Playwright Browsers in the GitHub workflow. Updating these versions ensures that we are using the latest features and bug fixes of these libraries. This change could potentially improve the functionality, compatibility, and security of our application.
2024-04-11 16:13:14 +08:00
giancarlo
5adfb3edac Refactor account deletion process and improve invitation functionalities
The account deletion process has been refactored to send account deletion emails from the AccountWebhooksService instead of from the deletePersonalAccount service. This has resulted in the addition of the AccountWebhooksService and modification of the seeds.sql file to trigger a webhook after account deletion. Along with this, the account invitation functionalities within the accountInvitations service have been considerably enhanced, making it much clearer and easier to use.
2024-04-09 16:26:50 +08:00
giancarlo
9fca45c2de Replace Logger with getLogger and update next version
This commit replaces the use of Logger with getLogger in various parts of the code to handle logging. The Logger has been replaced with getLogger, which assists in getting logs in an asynchronous manner. In addition to this, it updates the next version in pnpm-lock.yaml from next@14.2.0-canary.61 to next@14.2.0-canary.62 and various other dependencies. Also made minor annotations and comments to the function 'isBrowser' and 'formatCurrency' in the 'utils.ts' file.
2024-04-08 12:23:15 +08:00
giancarlo
220a23e185 Implement updateSubscription feature and refactor billing services
This commit introduces the updateSubscription method to the BillingStrategyProviderService, ensuring that subscriptions can be updated within the billing core. Additionally, a refactor has been applied to the BillingGatewayFactoryService and stripe-billing-strategy.service to improve error handling and the robustness of subscription updates. Logging in the webhook route has been adjusted for clarity and the data model has been enhanced.
2024-04-04 20:15:12 +08:00
giancarlo
35ef90b4f8 Update Supabase dependency, delete cookie handling, create logger
Updated Supabase dependency across multiple packages from "^2.41.1" to "^2.42.0". Removed files handling sidebar state and theme cookies. Created a new Logger interface for managing log messages in the shared package. Enhanced the middleware to track accounts membership webhook payload. Minor adjustments were also made in multiple package.json files.
2024-04-03 23:59:41 +08:00
giancarlo
2dc2c6461e Implement error handling and adjust import paths
This commit introduces error handling in the 'database-webhook-handler.service.ts' to log and rethrow errors when processing webhooks. It also adjusts the import paths for ContentlayerClient and WordpressClient in 'create-cms-client.ts'. Method names in 'database-webhook-router.service.ts' have been updated for clarity.
2024-04-02 16:03:11 +08:00
giancarlo
6149f6a313 Update package dependencies and refactor peer dependencies
Updated various package dependencies including "next", "turbo" and "@kit" packages. Moved some dependencies to devDependencies for better project structure. This aims to optimize the dependency graph, reduce unnecessary installation of packages, and enhance the overall development environment.
2024-04-02 11:13:57 +08:00
giancarlo
aa12ecd5a2 Refactor API code and simplify billing display
The code in the webhook API has been refactored to move the DatabaseWebhookHandlerService instance out of the POST function scope. Furthermore, the display of renewal plan details on the billing page has been simplified and certain parts deemed superfluous have been removed. Numerous types and interfaces in the database.types.ts file have also been corrected and formatted for consistency and improved readability.
2024-03-31 15:13:44 +08:00
giancarlo
2c0c616a2d Rename component files and update code dependencies
Numerous component files have been renamed for better organization and readability. This includes changing 'app' to 'account-layout' in various instances and 'organization' to 'team' to ensure consistency across code. Additionally, dependencies within codes have been updated in line with the renaming. The pull request also includes a minor update to the pnpm-lock file, reflecting the latest version of Next.js.
2024-03-31 01:05:32 +08:00
giancarlo
e158ff28d8 Improve and update billing flow
This commit updates various components in the billing flow due to a new schema that supports multiple line items per plan. The added flexibility rendered 'line-items-mapper.ts' redundant, which has been removed. Additionally, webhooks have been created for handling account membership insertions and deletions, as well as handling subscription deletions when an account is deleted. This message also introduces a new service to handle sending out invitation emails. Lastly, the validation of the billing provider has been improved for increased security and stability.
2024-03-30 14:51:16 +08:00