Commit Graph

67 Commits

Author SHA1 Message Date
Zaid Marzguioui
61ff48cb73 Initial state for GitNexus analysis 2026-03-29 19:44:57 +02:00
Giancarlo Buomprisco
7ebff31475 Next.js Supabase V3 (#463)
Version 3 of the kit:
- Radix UI replaced with Base UI (using the Shadcn UI patterns)
- next-intl replaces react-i18next
- enhanceAction deprecated; usage moved to next-safe-action
- main layout now wrapped with [locale] path segment
- Teams only mode
- Layout updates
- Zod v4
- Next.js 16.2
- Typescript 6
- All other dependencies updated
- Removed deprecated Edge CSRF
- Dynamic Github Action runner
2026-03-24 13:40:38 +08:00
gbuomprisco
4912e402a3 Revert "Unify workspace dropdowns; Update layouts (#458)"
This reverts commit 4bc8448a1d.
2026-03-11 14:47:47 +08:00
Giancarlo Buomprisco
4bc8448a1d Unify workspace dropdowns; Update layouts (#458)
Unified Account and Workspace drop-downs; Layout updates, now header lives within the PageBody component; Sidebars now use floating variant
2026-03-11 14:45:42 +08:00
Giancarlo Buomprisco
9033155fcd Add OTP sign-in option + Account Linking (#276)
* feat(accounts): allow linking email password
* feat(auth): add OTP sign-in
* refactor(accounts): remove 'sonner' dependency and update toast imports
* feat(supabase): enable analytics and configure database seeding
* feat(auth): update email templates and add OTP template
* feat(auth): add last sign in method hints
* feat(config): add devIndicators position to bottom-right
* feat(auth): implement comprehensive last authentication method tracking tests
2025-06-13 17:47:35 +08:00
Giancarlo Buomprisco
fc2fda595a Snyk report fixes + offcanvas sidebar fix (#263)
Refactor:
- Improved consistency and robustness by standardizing file encoding arguments from 'utf-8' to 'utf8' across various file read/write operations.
- Simplified status mapping logic in billing components and services by replacing switch statements with direct mapping objects for clearer and more maintainable code.
- Enhanced type conversion and error handling in billing and internationalization components for improved reliability.
- Updated sorting logic in team member tables for more predictable member ordering.
- Improved error logging with sanitized output to prevent formatting issues.
- Adjusted environment variable whitelisting to use a more flexible matching pattern.
- Fix variables for sidebar style handling

Style:
- Refined spacing and layout in account selector and sidebar header components for better visual consistency.
2025-06-01 20:10:39 +08:00
Giancarlo Buomprisco
2a157e8baa 134 improvement add a button that allows closing the sidebar (#135)
* Enhance sidebar navigation and layout configuration

- Added support for configurable sidebar collapsed style
- Updated layout components to use new sidebar configuration
- Added environment variable for sidebar trigger display
- Simplified page header and navigation components
- Improved sidebar responsiveness and user experience

* Refactor admin account page layout and action buttons

- Moved action buttons from sidebar to PageHeader for both personal and team account pages
- Updated button variants and styling for better visual hierarchy
- Improved spacing and layout of account page components
- Added border to PageHeader for better visual separation

* Update version updater dialog styling

- Replaced `space-x-4` with `gap-x-2` for better spacing
- Wrapped translation text in a `span` for improved layout
- Maintained consistent icon and text alignment in dialog title

* Refactor sidebar state management and configuration

- Simplified sidebar context and removed minimized state
- Updated layout components to use new sidebar open/closed state
- Modified sidebar navigation to handle collapsed state dynamically
- Added environment variable for sidebar trigger and collapsed style
- Improved sidebar responsiveness and rendering logic

* Remove sidebar configuration and environment variables

- Simplified sidebar context by removing `minimized` state in components
- Updated account selector components to use simplified sidebar state
- Removed unused helper functions in sidebar implementation
2025-02-04 09:45:16 +08:00
Giancarlo Buomprisco
8e051664b8 Dependencies: Updated packages, run linter autofix (#84) 2024-11-26 15:21:07 +08:00
gbuomprisco
afe1ca43cc Fix NEXT_PUBLIC_ENABLE_TEAM_ACCOUNTS in Zod error description 2024-11-19 11:32:46 +08:00
gbuomprisco
3fad846821 Run Prettier's automated formatting over the codebase. 2024-11-08 14:35:30 +08:00
Giancarlo Buomprisco
14c2220904 Update Shadcn Sidebar (#73)
Migrated Sidebar to use Shadcn UI's
2024-10-25 15:43:34 +08:00
Giancarlo Buomprisco
b2c27eb25b Sidebar: make it possible to set the sidebar as collapsed (#72)
* Sidebar: make it possible to set the sidebar as collapsed
2024-10-14 17:31:18 +08:00
gbuomprisco
2fe8fc0231 Revert hard coded setting 2024-10-12 04:38:00 +02:00
gbuomprisco
f2b74a9c7e MFA: display meaningful errors 2024-10-12 04:35:03 +02:00
gbuomprisco
eba782a11d Minor adjustments 2024-09-09 10:22:34 +02:00
gbuomprisco
106d6ec9fa Specify environment variable required in Zod message 2024-09-06 19:47:06 +02:00
gbuomprisco
babdecb78f Refactor code and update dependencies
Rearranged imports for better organization and readability across multiple files. Updated the `react-i18next` dependency to version 15.0.1 in various `package.json` files. Adjusted formatting in multiple TypeScript files to ensure code style consistency.
2024-08-11 12:04:49 +02:00
Giancarlo Buomprisco
e696f1aed0 Design Updates: Breadcrumbs, Empty State, new Charts and new colors
Design Updates: Breadcrumbs, Empty State, new Charts and new colors

* Add Breadcrumb component to UI package

* Add AppBreadcrumbs for improved navigation: Replaced static text descriptions with the new AppBreadcrumbs component across multiple pages to enhance navigation. Addressed an issue with Supabase client warnings by temporarily suppressing getSession warnings. Also made minor UI adjustments, including adjustments to heading styles and layout features.

* Enhance UI styling and configuration settings: Updated various UI components and global styles to improve styling consistency and responsiveness.

* Update global styles and adjust padding: Updated several CSS variables for improved color accuracy and appearance. Added padding to admin account page body for better layout consistency.

* Refactor UI components and adjust styling: Replaced Heading tags in Plan Picker with span for consistency. Added active and hover states to buttons in the sidebar. Refined background, layout styling, and color schemes across various components. Removed sidebar case in Page component switch statement.

* Add Chart Components and Integrate into Dashboard: Introduced `recharts` library and created `Chart` components. Updated dashboard to use the new components and enhanced UI/UX with descriptions and restructured cards.
* Enhance dashboard demo UI layout: Refactor the layout by adjusting flex properties and spacing classes to improve component alignment. Update dummy data generation and Figure font size for better visual consistency.

* Update localization keys for navigation labels: Changed localization keys for tab labels to use 'routes' prefix for consistency. Adjusted corresponding component references and added missing keys for routes. This ensures better organization and uniformity in the code.

* Add EmptyState component and enhance account handling: Introduced a new EmptyState component for UI consistency and updated JSON locales with 'account' route. Modified HomeAddAccountButton to accept className prop and refactored HomeAccountsListEmptyState to use the new EmptyState component. Updated navigation config to align labels in locales.

* Add locale support and enhance currency formatting: This commit introduces locale-based currency formatting across billing components by utilizing the `useTranslation` hook to fetch the current language. It also refactors the `formatCurrency` function to accept an object parameter for better readability and reusability.

* Fix typo in devDependencies section of template generator: Corrected a syntax error in `package.json.hbs` template affecting the `@kit/tsconfig` entry. The change ensures that the dependency is properly defined and prevents potential issues during package management.

* Update heading levels and add tracking-tight class in auth shell: Changed Heading components from level 4 to level 5 and added the 'tracking-tight' class in multiple auth-related pages. This improves visual consistency and better aligns the typography across the application.
2024-08-04 23:25:28 +08:00
gbuomprisco
84f838d3a1 Add feature flag for team account deletion
Updated the team account settings page to support a new feature flag for enabling team deletion. Only the primary user can delete the account if this feature is enabled. Also, corrected the required error message in feature-flags.config.ts file for more clarity.
2024-07-22 19:14:48 +02:00
Giancarlo Buomprisco
a75f7c576d Add terms and conditions checkbox to sign-up methods (#45)
A checkbox has been added for user acceptance of terms and conditions during sign-up. This change includes adding a new adjustable flag in the configuration to control the display of the checkbox. A new file "terms-and-conditions-form-field.tsx" is added to handle the checkbox UI part. Also, localization support has been added for the feature.
2024-07-12 14:32:02 +08:00
gbuomprisco
6b48778753 Add version updater feature
Added a version updater component that frequently checks for updates to the app and alerts the user if necessary. This requires a new route, config changes, and additional UI resources. A new feature flag 'enableVersionUpdater' has been added in the feature-flags.config.ts file to toggle this feature.
2024-06-22 20:21:08 +08:00
giancarlo
26b2eed60d Update pricing table to exclude flat line items
The pricing table component now filters out flat line items as they do not require further explanation. Consequently, changes have been made to the billing sample configuration file, turning a previously metered item into a flat one for clearer demonstration of usage.
2024-06-02 12:22:52 +07:00
giancarlo
2c52a06536 Update pricing table and billing configuration
Updated the pricing table component to display all line items for a plan, removed condition to exclude primary plan. Adjusted the type of a billing package in the sample configuration to be "metered" instead of "flat". Made related changes in line-item-details component to handle the changes in billing type and to fix the layout.
2024-06-01 15:59:39 +07:00
Giancarlo Buomprisco
4e50094808 Fix upsert billing (#24)
This commit updates the product_id and variant_id in both the subscription_items and order_items in the billing tests. Updates also include adding new checks to verify these changes. Changes are reflected in corresponding SQL files for personal and team billing subscriptions/orders tests.
2024-05-15 11:08:19 +07:00
giancarlo
9baee90eec Update configuration settings and improve notifications
This commit updates the configuration settings and improves the notification functionality by filtering out duplicate notifications. It also includes changes to feature flag data types and removed dependencies in `package.json`, alongside updates to `pnpm-lock.yaml`.
2024-05-01 12:13:19 +07:00
giancarlo
19aa40493f Remove redundant files and update pnpm lockfile 2024-04-30 22:16:38 +07:00
giancarlo
820ed1f56b Add notifications feature and update feature flags
This update includes creating new files for the notifications feature along with adding two feature flags for enabling notifications and realtime notifications. All the code and package dependencies required for the notifications functionality have been added. The 'pnpm-lock.yaml' has also been updated due to the inclusion of new package dependencies.
2024-04-29 18:12:30 +07:00
giancarlo
0c6bdaa9e4 Update validation message for URL configuration
The commit updates the validation error message in the chat web app configuration. The new message indicates a scenario where a user has provided the URL using http instead of https during a production build, increasing clarity by hinting at possible misconfigurations due to incorrect protocol use.
2024-04-28 13:25:32 +07:00
giancarlo
448fee01c4 Add language priority feature flag
This commit adds a new 'languagePriority' key to the feature flags configuration. It determines whether to use user's preferred language or the application's default language. Adjustments to the language selection process according to new flag have been made in the 'createInstance' function in 'i18n.server.ts'. Additionally, updates have been made to 'README.md' and '.env' files to reflect these changes.
2024-04-23 22:51:45 +07:00
giancarlo
6814cc7089 Fix linting 2024-04-23 00:15:41 +08:00
giancarlo
70da6ef1fa Adjusted Per seat billing and added example to the sample schema 2024-04-22 22:48:02 +08:00
giancarlo
8e1d7ad1f5 Refactor admin dashboard loader and update translations
The admin-dashboard.loader file was refactored to use a newly created AdminDashboardService. This service encapsulates the logic for fetching dashboard data. Translations related to account settings, privacy policy, terms of service, and cookie policy were updated for better readability. Changes also include minor reorganizing of code files for clearer structure.
2024-04-22 20:30:21 +08:00
giancarlo
c2bc9c5ed2 Update captchaTokenSiteKey validation in auth.config
Changed the captchaTokenSiteKey configuration in auth.config.ts. Previously, it could only accept strings of minimum length 1 but now, it is modified to accept any length string, including an empty string.
2024-04-15 19:21:40 +08:00
giancarlo
b0fe19e73e Update feature flags and related environment variables
The code has been adjusted to update the description and requirement error messages of the feature flags. Additionally, the related environment variables used in feature flags have been renamed for better consistency and clarity. This helps in better identification and usage of these feature flags.
2024-04-15 17:16:50 +08:00
giancarlo
4e305bf8c9 Update UI, improve E2E tests and modify trial period configuration
The code changes incorporate UI updates for better usability and user experience. E2E test scripts(in `user-billing.spec.ts` and `team-billing.spec.ts`) were also updated for improved efficiency and accuracy, primarily replacing 'Active' status check with 'Trial'. Changes have been made in the trialDays configuration, with the term 'trialPeriod' now replaced by 'trialDays' across different components. Notably, a new error handling case is included in `lemon-squeezy-billing-strategy.service.ts` for failed subscription cancellation attempts.
2024-04-15 01:18:27 +08:00
giancarlo
a549d2d08f Add detailed error messages for missing environment variables
The commit adds detailed error messages for missing environment variables across different configuration files. It updates the zod schema validations in different files, such as feature-flags.config.ts, personal-accounts-server-actions.ts, and others to provide more informative error messages when environment variables are not provided.
2024-04-14 18:50:09 +08:00
giancarlo
d078e0021c Add end-to-end tests for user and team billing features
This commit introduces end-to-end tests for the user and team billing features. It also enhances existing billing configurations, logging, and error handling mechanisms. Refactoring has been done to simplify the code and make it more readable. Adjustments have also been made in the visual aspects of some components. The addition of these tests will help ensure the reliability of the billing features.
2024-04-14 17:15:04 +08:00
giancarlo
5ecf0e97da Update dependencies and environment for web app
Upgraded '@makerkit/data-loader-supabase-nextjs' to version 1.1.0 and replaced 'autoprefixer' with a newer version. Added new scripts to 'packages.json' and '.env.test' file for test environment. The changes also include removal of unnecessary 'eslint' dependencies and modifications for 'postcss' related dependencies.
2024-04-13 03:05:51 +08:00
giancarlo
f729bf6077 Removed shamefully-hoist and updated all packages to respect that 2024-04-10 01:45:03 +08:00
giancarlo
ab1e90f093 Update Billing Provider and Refactor Pricing UI
Updated the billing provider in the environment configuration to use 'stripe' instead of 'lemon-squeezy'. Multiple changes were also made to UI components related to pricing, including better data handling for different billing tiers and enhanced visualization of selected options. These revisions aim to both enhance the user experience and ensure compatibility with the new billing provider.
2024-04-07 18:12:45 +08:00
giancarlo
1e23ee2783 Replace 'base' line item type with 'flat'
This commit updates all instances of 'base' line item type to 'flat'. It modifies the BillingIntervalSchema, the validation rules for one-time plans, and the function to get the primary line item for a plan. Furthermore, it adjusts the display and filtering of line items in the pricing table component and the plan picker component. The SQL migration script and the sample billing configuration are also updated to reflect this change.
2024-04-07 17:34:47 +08:00
giancarlo
0002ac6255 Refactor billing imports, reorganize package scripts and improve action structure
Deleted unnecessary schema files and reorganized their imports into more logical order. Modified the package script structure to align more accurately with standard conventions. Also refactored the team-billing.service file to improve action structure, making it easier to understand and edit. Furthermore, upgraded various dependencies, reflecting their new versions in the lockfile.
2024-04-07 12:47:29 +08:00
giancarlo
0a9c1f35c6 Add captcha support to authentication features
The update includes the implementation of captcha support during the sign-in and sign-up process for user accounts. The process ensures a better level of security against bot-based attacks. Also, the code has been refactored to separate error and success alerts and unnecessary useEffect hooks have been removed. Moreover, some logic concerning the authentication rendering has been simplified.
2024-04-07 10:56:33 +08:00
giancarlo
a1d86d2b7d Added tiers to billing config and related UI 2024-04-06 11:41:50 +08:00
giancarlo
9492b035a0 Update billing schema and enhance configuration display
Updated the billing schema to include a more descriptive line item and an optional tiers element. Also, billing configuration was refactored and displayed more prominently in the UI. The plan feature listing now utilizes checkmarks to denote each feature and the product details are more clearly displayed.
2024-04-05 19:23:03 +08:00
giancarlo
eb43059fda Update billing provider and related adjustments
This commit switches the billing provider from Stripe to Lemon Squeezy. It also includes necessary modifications in the web app, billing gateway, and database to accommodate this change. Additionally, updates have been made to the checkout process, billing strategy, and relevant services and components.
2024-04-02 14:31:53 +08:00
giancarlo
d24cf8427f Refactor billing system and enhance logging
Updated the billing system's schema to change 'storeId' to a string type, and improved the cleanliness and readability of the code. Enhanced the logging system within the billing service for better tracking and debugging. In line with these changes, added corresponding error pages in the client side to handle any errors.
2024-04-02 12:19:09 +08:00
giancarlo
84a4b45bcd Update billing system to support single and recurring payments
This update modifies the billing system to properly handle both single and recurring payment plans. Logic is introduced to determine whether the selected plan is recurring or a one-time payment and adjust the interface accordingly. The naming of some components and variables has been changed to more accurately reflect their purpose. Additionally, a
2024-04-01 20:58:26 +08:00
giancarlo
248ab7ef72 Update translations and add trial eligibility in plan picker
Added translations in "plan-picker" for better localization support. Introduced a new functionality to check trial eligibility where existing customers can't start a trial. Removed unnecessary billing line items like 'per-seat' and 'metered'. Also, made significant changes in multiple files to align with the updated internationalization best practices. The changes aim to make application more user-friendly across different locales and provide accurate trial period conditions.
2024-03-31 17:46:39 +08:00
giancarlo
ba92e14363 Add detailed plan info and additional subscription types
Implemented detailed pricing information for various subscription types in the plan-picker component. Two additional subscription types, 'per-seat' and 'metered', have been added to the billing configuration, providing more flexibility for customers to choose different billing methods that suit their needs. The billing schema has also been refined to allow plans without a 'base' line item.
2024-03-31 15:47:20 +08:00