Commit Graph

343 Commits

Author SHA1 Message Date
javayhu
91f1d59b7c chore: add images for blocks 2025-03-30 20:51:28 +08:00
javayhu
1eb5b9cffe refactor: update default font and enhance localization
- Replaced font imports in the layout and font index files to use Noto and Bricolage fonts for improved typography.
- Updated global CSS variables to reflect the new font settings.
- Enhanced author introduction in English and Chinese localization files with a greeting emoji for better user engagement.
- Adjusted heading styles in the About page for consistency.
2025-03-30 14:58:12 +08:00
javayhu
d9451b7a74 fix: fix build error 2025-03-30 14:12:53 +08:00
javayhu
516cd70bba fix: update reading time display and enhance localization
- Changed the comment for average reading speed in content-collections.ts for clarity.
- Added a new translation key for reading time in English and Chinese localization files.
- Updated the BlogPostPage to utilize the new translation key for displaying estimated reading time, improving user experience and localization support.
2025-03-30 14:09:34 +08:00
javayhu
29ed01182e refactor: update prose styling in blog and custom pages
- Changed the prose class to prose-neutral in blog post and custom page components for improved typography consistency.
- Added a comment in the blog post page to clarify the necessity of the prose class for MDX styling.
- Enhanced the table of contents component with line-clamp for better text handling.
2025-03-30 13:34:31 +08:00
javayhu
e704153010 fix: update image tag in MDX files for consistency
- Replaced <Image> component with <img> tag in multiple MDX files to standardize image rendering.
- Updated alt text in the Chinese blog post for improved accessibility.
2025-03-30 13:27:41 +08:00
javayhu
08fee6d1ec refactor: streamline MDX handling and enhance content collections
- Replaced the custom Mdx component with MDXContent from @content-collections/mdx/react for improved MDX processing.
- Updated content handling in various legal and blog pages to directly use the transformed body from content collections.
- Introduced estimated reading time calculation in the posts collection for better user experience.
- Added a new mdx.css file for consistent styling across MDX components.
- Removed the obsolete shared mdx-component file to reduce redundancy.
2025-03-30 13:27:30 +08:00
javayhu
c3a774e1cb fix: update docs & optimize docs layout & pages
- Translated the title and paragraphs in multiple .mdx files from Chinese to English for consistency and clarity.
- Adjusted the layout.tsx to change the font class for improved typography.
- Enhanced the Providers component with detailed comments for better understanding of the provider structure.
2025-03-30 10:34:49 +08:00
javayhu
584d3faa1a refactor: move docs RootProvider to LocaleLayout Providers 2025-03-30 10:28:57 +08:00
javayhu
5b7dae6586 fix: fix code style inside and outside pre 2025-03-30 10:02:33 +08:00
javayhu
16926cdaf1 refactor: enhance contact and waitlist form components with transition handling
- Replaced isSubmitting state with useTransition for improved form submission handling in ContactFormCard and WaitlistFormCard components.
- Updated form submission logic to handle errors more effectively and provide user feedback through toast notifications.
- Adjusted button states to reflect pending submissions, enhancing user experience during form interactions.
- Modified styling in mdx-component to use 'text-primary' for anchor elements, ensuring consistent theming across the application.
2025-03-30 00:50:15 +08:00
javayhu
26c89575d8 refactor: restructure mode and theme translations for improved organization
- Updated English and Chinese translation files to nest mode-related entries for better clarity.
- Adjusted components to utilize the new translation structure, enhancing accessibility and maintainability.
- Ensured consistent usage of translation keys across ModeSwitcher and ThemeSelector components.
2025-03-30 00:32:07 +08:00
javayhu
f26442f611 feat: update theme structure and enhance newsletter functionality
- Refactored theme-related translations in English and Chinese to a nested structure for better organization.
- Updated the default theme in the configuration to "default" for consistency.
- Enhanced the WaitlistPage and Newsletter components with improved descriptions and error handling.
- Integrated the NewsletterCard component into the BlogPostPage for better user engagement.
- Adjusted the ThemeSelector to utilize the new translation structure for theme names.
- Improved styling and layout in the NewsletterForm for a better user experience.
2025-03-30 00:29:41 +08:00
javayhu
92ffc545de feat: enhance mdx-component with pre context and style adjustments
- Introduced PreContext to track whether the code component is inside a pre element, improving styling logic.
- Updated heading components (h3, h4, h5, h6) to use 'font-medium' instead of 'font-semibold' for consistent typography.
- Adjusted code component styling to conditionally apply background based on context, enhancing visual clarity.
2025-03-29 22:54:58 +08:00
javayhu
88202b7cc9 feat: update documentation and enhance internationalization support
- Commented out the <Cards> component in index.mdx and introduction.mdx for clarity.
- Added new translation entries for "homepage" and "title" in both English and Chinese message files.
- Refactored layout.tsx to include a new baseOptions configuration for improved layout management and theme support.
- Integrated ModeSwitcher and Logo components into the layout for enhanced user experience.
- Updated page.tsx to prepare for potential Mdx component integration.
2025-03-29 22:36:22 +08:00
javayhu
34ffcc989e feat: implement theme switcher & intl and support theme config
- Added new mode switcher components for both horizontal and dropdown layouts to facilitate theme toggling.
- Updated translation files to include new theme-related entries in English and Chinese.
- Refactored existing components to replace ThemeSwitcher with ModeSwitcher for consistency.
- Introduced new themes in the configuration and updated the theme selector to utilize translations for theme names.
- Enhanced global styles to support new themes and ensure proper application across the project.
2025-03-29 22:15:00 +08:00
javayhu
42c2460718 feat: update logo & favicon images
- Updated ISSUES.md to reflect a new issue regarding page layout shifting when navigating between docs and the homepage.
- Changed permissions for several image files to ensure proper access and usage.
- Added new SVG files for enhanced iconography in the project.
2025-03-29 21:20:45 +08:00
javayhu
8374ec9564 fix: enable TailwindIndicator in locale layout and update login button cursor style
- Un-commented the TailwindIndicator component in layout.tsx to ensure it is rendered for styling purposes.
- Updated the login button in login-form.tsx to include a cursor-pointer class for better user experience when hovering over the button.
2025-03-29 17:37:31 +08:00
javayhu
de37908d05 feat: add translations for DocsPage in English and Chinese
- Introduced new translation entries for the DocsPage, including Table of Contents, search functionality, last update information, and pagination controls in both English and Chinese.
- Refactored layout.tsx to utilize dynamic translations from the message files, enhancing internationalization support and maintainability.
2025-03-29 16:28:37 +08:00
javayhu
5c96b83455 feat: update locale handling in docs layout
- Refactored the locales array in layout.tsx to dynamically generate language options from LOCALE_LIST for improved maintainability and consistency with internationalization practices.
- Removed hardcoded locale entries to streamline the code and enhance flexibility in supporting additional languages.
2025-03-29 16:22:04 +08:00
javayhu
9366ac60f2 fix: fix search Chinese not work in docs
- Added a guideline to use `pnpm` as the default package manager in TypeScript best practices.
- Refactored the search API route to improve readability by simplifying the mapping of pages to search indexes.
- Wrapped the GET handler with locale detection from the referer header and ensured the locale parameter is passed to the search API for better internationalization support.
2025-03-29 16:12:59 +08:00
javayhu
4fe8d78099 feat: add generateStaticParams in docs page
- Added generateStaticParams function in page.tsx to support dynamic locale and slug parameters for improved routing.
- Included console logging in the search API route for better debugging and visibility of search index data.
2025-03-29 14:42:28 +08:00
javayhu
83f5760126 feat: enhance documentation and internationalization support
- Updated content-collections.ts to clarify usage for Fumadocs.
- Added new ISSUES.md file to track known issues.
- Introduced @orama/orama and @orama/tokenizers dependencies in package.json for improved search functionality.
- Enhanced search API route to support internationalization and custom tokenizers for Chinese.
- Added new introduction and documentation files in both English and Chinese.
- Removed outdated test.mdx file to streamline documentation.
- Improved error handling and metadata generation in page.tsx for better user experience.
2025-03-29 14:30:29 +08:00
javayhu
02af1c7512
Merge pull request #15 from MkSaaSHQ/docs
feat: docs support theme and i18n
2025-03-29 12:33:30 +08:00
javayhu
c15980b32a feat: update documentation and enhance internationalization support
- Updated documentation links in content-collections.ts for accuracy.
- Modified index.mdx and test.mdx files to improve content structure and clarity.
- Added new Chinese documentation file (index.zh.mdx) to support localization.
- Enhanced layout.tsx to include translations for English and Chinese.
- Updated page.tsx to handle locale parameters for improved routing.
- Refactored source.ts to streamline imports and maintain consistency.
2025-03-29 12:32:25 +08:00
javayhu
c81447e2ef feat: implement new documentation layout and enhance middleware
- Added a new layout configuration for documentation with internationalization support.
- Created a dedicated DocsRootLayout and associated providers for better structure.
- Updated middleware to refine route handling for documentation.
- Removed outdated layout configurations and components to streamline the codebase.
- Enhanced localization support for documentation in English and Chinese.
2025-03-29 11:39:44 +08:00
javayhu
1445f6a5f4
Merge pull request #14 from MkSaaSHQ/docs
feat: support docs powered by fuma docs
2025-03-27 00:12:16 +08:00
javayhu
45d46082f2 feat: add documentation structure and enhance content collections
- Introduced new content collections for documentation and metadata using Fumadocs.
- Created initial documentation files and layout for the docs section.
- Updated routing and middleware to support the new docs structure.
- Enhanced localization support by adding new entries for documentation in English and Chinese.
- Implemented a new API route for search functionality within the documentation.
2025-03-27 00:09:13 +08:00
javayhu
23aa0f179e refactor: streamline locale handling in components
- Removed unnecessary checks in locale handling functions across NavUser, LocaleSelector, and LocaleSwitcher components to simplify the code.
- Adjusted padding in NavbarMobile component for improved layout consistency and user experience.
2025-03-26 21:45:06 +08:00
javayhu
7211e6981c refactor: update page structure and enhance layout consistency
- Changed import path for Pricing component in HomePage to utilize the new preview structure.
- Adjusted layout in ContactPage and WaitlistPage by adding bottom padding for improved spacing.
- Modified HeroSection component to enhance layout with consistent padding.
- Cleaned up commented-out code in BlockPreview and Navbar components for better readability and maintainability.
2025-03-26 10:00:31 +08:00
javayhu
f1b1789207 feat: enhance locale handling and add new blocks route
- Added a new route for blocks to improve navigation structure.
- Fixed locale inconsistency in BlocksNav component by removing custom locale handling.
- Implemented checks in locale selector components to prevent unnecessary locale updates.
- Updated comments to reflect changes and improve code clarity.
2025-03-26 00:52:08 +08:00
javayhu
c9e4b7eb0b refactor: update import paths and enhance HomePage structure
- Replaced imports in HomePage component to utilize new preview paths for better organization.
- Updated Features and Pricing components to align with the new structure.
- Wrapped CallToAction component in a div for improved layout consistency.
- Commented out unused HeroHeader in the HeroSection component for clarity.
2025-03-26 00:32:51 +08:00
javayhu
91b2bdb4ac fix: update Chinese translations and enhance blocks navigation
- Updated Chinese translations in zh.json to include spaces between words and components for improved readability.
- Enhanced BlocksNav component to correctly handle locale from URL parameters, ensuring accurate navigation across different locales.
- Commented out unused imports in blocks.ts for clarity and to prevent confusion.
2025-03-26 00:27:19 +08:00
javayhu
87bb54b7c5 refactor: reorganize BlockCategoryPageProps interface and enhance BlockPreview component
- Moved BlockCategoryPageProps interface definition to improve code structure.
- Refactored BlockPreview component to utilize useCopyToClipboard hook for better clipboard functionality.
- Cleaned up commented-out code and improved readability in the BlockPreview component.
2025-03-26 00:04:18 +08:00
javayhu
af94ab6dd0 feat: update navigation and add new block components
- Disabled development indicators in next.config.ts for cleaner output.
- Updated English and Chinese message files to include new block titles for logo, login, signup, and contact sections.
- Refactored routes to include new paths for login, signup, and contact blocks.
- Introduced new layout and page components for marketing sections, including logo cloud and various call-to-action pages.
- Enhanced blocks navigation component to utilize updated paths and improve user experience.
2025-03-25 23:57:51 +08:00
javayhu
aefe37068b fix: fix build error caused by DualModeImage 2025-03-25 00:51:48 +08:00
javayhu
762760545d refactor: add category layout and block preview components & move to blocks folder
- Introduced a new layout for category pages to enhance navigation and organization of blocks.
- Added a block preview component to display various UI blocks dynamically based on category.
- Updated routes to reflect the new structure for hero blocks.
- Refactored existing hero section components to utilize the new block structure for improved modularity.
2025-03-25 00:49:10 +08:00
javayhu
25433c0570 refactor: restructure marketing sections and components to sections folder
- Updated import paths for marketing components to a new directory structure under 'sections'.
- Removed the deprecated features page and replaced it with a new structure for content and sections.
- Added new sections for call-to-action, content, FAQs, features, hero, pricing, stats, and testimonials to enhance the marketing layout.
- Introduced multiple new components for better organization and modularity in the marketing section.
2025-03-25 00:46:12 +08:00
javayhu
d9e885416a refactor: optimize code format for nsui components
- Updated import statements across multiple files to use consistent semicolon usage.
- Enhanced component structure by ensuring proper formatting and return statements.
- Improved readability and maintainability of the codebase by adhering to coding standards.
2025-03-25 00:43:31 +08:00
javayhu
cc0f17f722 feat: add NSUI components and support preview
- Added Cloudinary as an allowed image domain in next.config.ts for image optimization.
- Included new dependencies: react-use-measure and use-media in package.json for enhanced UI responsiveness.
- Introduced a service worker for caching iframe content to improve performance.
- Added multiple new block components and layouts for enhanced UI features and organization.
- Implemented utility functions and motion primitives for improved animations and effects.
2025-03-25 00:40:22 +08:00
javayhu
ef740e23db feat: add authentication checks to checkout and customer portal actions
- Integrated authentication session validation in createCheckoutAction and createPortalAction to ensure only authorized users can create sessions.
- Enhanced unsubscribeNewsletterAction with similar authentication checks for improved security and user feedback.
2025-03-24 23:54:59 +08:00
javayhu
bf4f296fe1 feat: update drizzle configuration and dependencies for Neon integration
- Updated drizzle configuration to use the Neon HTTP driver for improved compatibility with Next.js.
- Added @neondatabase/serverless package to package.json for serverless database support.
- Modified database connection logic to utilize the new Neon client.
- Removed deprecated customer creation method in StripeProvider for cleaner code.
2025-03-24 10:14:49 +08:00
javayhu
acb468fd36 feat: add customerId to user table as additionalFields 2025-03-24 09:48:14 +08:00
javayhu
a7d2ddef1a feat: enhance Stripe payment provider with customer management and error handling
- Added functionality to create or get a Stripe customer based on email, improving user experience during checkout.
- Implemented robust error handling for updating user records with customer IDs.
- Updated README to reflect new actions for creating checkout sessions and customer portal sessions.
2025-03-24 01:09:21 +08:00
javayhu
c577cbc933 feat: add column customerId in user table 2025-03-24 00:22:21 +08:00
javayhu
ff06d4dfec feat: implement newsletter and payment actions with improved error handling
- Added actions for checking newsletter subscription status, subscribing, and unsubscribing.
- Introduced actions for creating checkout and customer portal sessions with validation.
- Replaced deprecated newsletter actions in components with new implementations.
- Enhanced error handling and logging for all new actions to improve user feedback.
2025-03-23 17:06:51 +08:00
javayhu
a6e2ee698a refactor: update site metadata and translations
- Renamed "Site" to "Metadata" in translation files for clarity.
- Updated the title, tagline, and description in both English and Chinese translations to reflect the new branding.
- Adjusted references in various components to use the updated metadata structure.
- Removed the obsolete site.webmanifest file and updated the manifest path in the metadata construction.
2025-03-23 15:37:38 +08:00
javayhu
7cf3a5afe8
Merge pull request #13 from javayhu/main
fix: fix shadcnui calendar component after upgrade react-day-picker
2025-03-23 15:36:18 +08:00
javayhu
15dab2549a fix: fix shadcnui calendar component after upgrade react-day-picker 2025-03-23 15:34:32 +08:00
javayhu
c4d6bb5d70 refactor: upgrade react-day-picker to version 9.6.3 2025-03-23 07:58:10 +08:00