页面反馈
关键原则
– 编写简洁且技术性的响应,附带准确的 TypeScript 示例。
– 使用函数式和声明式编程,避免使用类。
– 优先选择迭代和模块化而非重复。
– 使用描述性变量名,搭配助动词(例如:isLoading、hasError)。
– 目录使用小写字母加短横线(例如:components/auth-wizard)。
– 优先使用具名导出组件。
– 使用接收对象、返回对象(RORO)模式。
JavaScript/TypeScript
– 对于纯函数使用“function”关键字,省略分号。
– 所有代码使用 TypeScript,优先使用接口而非类型。
– 文件结构:导出组件、子组件、帮助函数、静态内容、类型。
– 在条件语句中避免不必要的花括号。
– 对于单行条件语句,省略花括号。
– 对简单的条件语句使用简洁的单行语法(例如:if (condition) doSomething())。
错误处理与验证
– 优先考虑错误处理和边界情况:
– 在函数开始处处理错误和边界情况。
– 对于错误情况使用早期返回,避免深层嵌套的 if 语句。
– 为提高可读性,将正常路径放在函数末尾。
– 避免不必要的 else 语句;改用 if-return 模式。
– 使用保护条款(guard clauses)早期处理预条件和无效状态。
– 实施适当的错误日志记录和用户友好的错误信息。
– 考虑使用自定义错误类型或错误工厂以实现一致的错误处理。
AI SDK
– 使用 Vercel AI SDK UI 实现流式聊天 UI。
– 使用 Vercel AI SDK Core 与语言模型交互。
– 使用 Vercel AI SDK RSC 和 Stream Helpers 进行流传输和生成辅助。
– 对 AI 响应和模型切换实施适当的错误处理。
– 实施当 AI 模型不可用时的备用机制。
– 优雅地处理速率限制和配额超限情况。
– 当 AI 交互失败时,向用户提供清晰的错误信息。
– 在发送到 AI 模型之前,对用户消息实施适当的输入清理。
– 使用环境变量存储 API 密钥和敏感信息。
React/Next.js
– 使用函数组件和 TypeScript 接口。
– 使用声明式 JSX。
– 对于组件使用 function 而不是 const。
– 使用 Shadcn UI、Radix 和 Tailwind CSS 进行组件和样式设计。
– 使用 Tailwind CSS 实现响应式设计。
– 采用移动优先的方法进行响应式设计。
– 将静态内容和接口放在文件末尾。
– 将静态内容的变量放在渲染函数之外。
– 尽量减少 'use client'、'useEffect' 和 'setState' 的使用,优先使用 React Server Components(RSC)。
– 使用 Zod 进行表单验证。
– 用 Suspense 包裹客户端组件并设定后备内容。
– 为非关键组件实现动态加载。
– 优化图像:使用 WebP 格式,提供尺寸数据,懒加载。
– 将预期错误建模为返回值:在 Server Actions 中避免使用 try/catch 来处理预期错误。
– 对于未预期的错误使用错误边界:使用 error.tsx 和 global-error.tsx 文件实现错误边界。
– 使用 useActionState 结合 react-hook-form 进行表单验证。
– 在 services/ 目录中的代码始终抛出用户友好的错误,便于捕捉并显示给用户。
– 对所有服务器操作使用 next-safe-action。
– 实现类型安全的服务器操作及适当验证。
– 优雅地处理错误并返回适当响应。
Supabase 和 GraphQL
– 使用 Supabase 客户端进行数据库交互和实时订阅。
– 实施行级安全(RLS)策略以实现精细的访问控制。
– 使用 Supabase Auth 进行用户身份验证和管理。
– 利用 Supabase Storage 进行文件上传和管理。
– 在需要时使用 Supabase Edge Functions 进行无服务器 API 端点。
– 使用生成的 GraphQL 客户端(Genql)进行类型安全的 API 交互。
– 优化 GraphQL 查询,只获取必要数据。
– 使用 Genql 查询高效获取大型数据集。
– 使用 Supabase RLS 和策略实施适当的身份验证和授权。
关键约定
1. 依赖 Next.js App Router 进行状态更改和路由。
2. 优先考虑 Web Vitals(LCP、CLS、FID)。
3. 尽量减少 'use client' 的使用:
– 优先使用服务器组件和 Next.js SSR 功能。
– 仅在小组件中使用 'use client' 进行 Web API 访问。
– 避免在数据获取或状态管理中使用 'use client'。
4. 遵循单体仓库结构:
– 将共享代码放在 'packages' 目录中。
– 将应用特定的代码放在 'apps' 目录中。
5. 使用 Taskfile 命令进行开发和部署任务。
6. 遵循定义的数据库架构,并使用枚举表来处理预定义值。
命名约定
– 布尔值:使用助动词如 'does'、'has'、'is' 和 'should'(例如:isDisabled、hasError)。
– 文件名:使用小写字母加短横线(例如:auth-wizard.tsx)。
– 文件扩展名:根据需要使用 .config.ts、.test.ts、.context.tsx、.type.ts、.hook.ts。
组件结构
– 将组件拆分为更小的部分,减少 props。
– 提供微型文件夹结构的建议。
– 使用组合构建复杂组件。
– 按顺序声明:组件声明、样式组件(如有)、TypeScript 类型。
数据获取与状态管理
– 尽可能使用 React Server Components 进行数据获取。
– 实施预加载模式以防止瀑布效应。
– 利用 Supabase 进行实时数据同步和状态管理。
– 在适当时使用 Vercel KV 存储聊天历史、速率限制和会话存储。
样式设计
– 使用 Tailwind CSS 进行样式设计,遵循实用优先的原则。
– 利用 Class Variance Authority(CVA)管理组件变种。
测试
– 为实用函数和钩子实现单元测试。
– 对复杂组件和页面使用集成测试。
– 为关键用户流程实施端到端测试。
– 使用 Supabase 本地开发测试数据库交互。
可访问性
– 确保界面可通过键盘导航。
– 为组件实施适当的 ARIA 标签和角色。
– 确保颜色对比度达到 WCAG 标准以提高可读性。
文档
– 对复杂逻辑提供清晰简洁的注释。
– 对函数和组件使用 JSDoc 注释,以改善 IDE 智能提示。
– 保持 README 文件更新,包括设置说明和项目概述。
– 在使用时记录 Supabase 架构、RLS 策略和 Edge Functions。
请参考 Next.js 文档获取数据获取、渲染和路由的最佳实践,以及 Vercel AI SDK 文档和 OpenAI/Anthropic API 指导,以获得 AI 集成的最佳实践。
Key Principles
– Write concise, technical responses with accurate TypeScript examples.
– Use functional, declarative programming. Avoid classes.
– Prefer iteration and modularization over duplication.
– Use descriptive variable names with auxiliary verbs (e.g., isLoading, hasError).
– Use lowercase with dashes for directories (e.g., components/auth-wizard).
– Favor named exports for components.
– Use the Receive an Object, Return an Object (RORO) pattern.
JavaScript/TypeScript
– Use "function" keyword for pure functions. Omit semicolons.
– Use TypeScript for all code. Prefer interfaces over types.
– File structure: Exported component, subcomponents, helpers, static content, types.
– Avoid unnecessary curly braces in conditional statements.
– For single-line statements in conditionals, omit curly braces.
– Use concise, one-line syntax for simple conditional statements (e.g., if (condition) doSomething()).
Error Handling and Validation
– Prioritize error handling and edge cases:
– Handle errors and edge cases at the beginning of functions.
– Use early returns for error conditions to avoid deeply nested if statements.
– Place the happy path last in the function for improved readability.
– Avoid unnecessary else statements; use if-return pattern instead.
– Use guard clauses to handle preconditions and invalid states early.
– Implement proper error logging and user-friendly error messages.
– Consider using custom error types or error factories for consistent error handling.
AI SDK
– Use the Vercel AI SDK UI for implementing streaming chat UI.
– Use the Vercel AI SDK Core to interact with language models.
– Use the Vercel AI SDK RSC and Stream Helpers to stream and help with the generations.
– Implement proper error handling for AI responses and model switching.
– Implement fallback mechanisms for when an AI model is unavailable.
– Handle rate limiting and quota exceeded scenarios gracefully.
– Provide clear error messages to users when AI interactions fail.
– Implement proper input sanitization for user messages before sending to AI models.
– Use environment variables for storing API keys and sensitive information.
React/Next.js
– Use functional components and TypeScript interfaces.
– Use declarative JSX.
– Use function, not const, for components.
– Use Shadcn UI, Radix, and Tailwind CSS for components and styling.
– Implement responsive design with Tailwind CSS.
– Use mobile-first approach for responsive design.
– Place static content and interfaces at file end.
– Use content variables for static content outside render functions.
– Minimize 'use client', 'useEffect', and 'setState'. Favor React Server Components (RSC).
– Use Zod for form validation.
– Wrap client components in Suspense with fallback.
– Use dynamic loading for non-critical components.
– Optimize images: WebP format, size data, lazy loading.
– Model expected errors as return values: Avoid using try/catch for expected errors in Server Actions.
– Use error boundaries for unexpected errors: Implement error boundaries using error.tsx and global-error.tsx files.
– Use useActionState with react-hook-form for form validation.
– Code in services/ dir always throw user-friendly errors that can be caught and shown to the user.
– Use next-safe-action for all server actions.
– Implement type-safe server actions with proper validation.
– Handle errors gracefully and return appropriate responses.
Supabase and GraphQL
– Use the Supabase client for database interactions and real-time subscriptions.
– Implement Row Level Security (RLS) policies for fine-grained access control.
– Use Supabase Auth for user authentication and management.
– Leverage Supabase Storage for file uploads and management.
– Use Supabase Edge Functions for serverless API endpoints when needed.
– Use the generated GraphQL client (Genql) for type-safe API interactions with Supabase.
– Optimize GraphQL queries to fetch only necessary data.
– Use Genql queries for fetching large datasets efficiently.
– Implement proper authentication and authorization using Supabase RLS and Policies.
Key Conventions
1. Rely on Next.js App Router for state changes and routing.
2. Prioritize Web Vitals (LCP, CLS, FID).
3. Minimize 'use client' usage:
– Prefer server components and Next.js SSR features.
– Use 'use client' only for Web API access in small components.
– Avoid using 'use client' for data fetching or state management.
4. Follow the monorepo structure:
– Place shared code in the 'packages' directory.
– Keep app-specific code in the 'apps' directory.
5. Use Taskfile commands for development and deployment tasks.
6. Adhere to the defined database schema and use enum tables for predefined values.
Naming Conventions
– Booleans: Use auxiliary verbs such as 'does', 'has', 'is', and 'should' (e.g., isDisabled, hasError).
– Filenames: Use lowercase with dash separators (e.g., auth-wizard.tsx).
– File extensions: Use .config.ts, .test.ts, .context.tsx, .type.ts, .hook.ts as appropriate.
Component Structure
– Break down components into smaller parts with minimal props.
– Suggest micro folder structure for components.
– Use composition to build complex components.
– Follow the order: component declaration, styled components (if any), TypeScript types.
Data Fetching and State Management
– Use React Server Components for data fetching when possible.
– Implement the preload pattern to prevent waterfalls.
– Leverage Supabase for real-time data synchronization and state management.
– Use Vercel KV for chat history, rate limiting, and session storage when appropriate.
Styling
– Use Tailwind CSS for styling, following the Utility First approach.
– Utilize the Class Variance Authority (CVA) for managing component variants.
Testing
– Implement unit tests for utility functions and hooks.
– Use integration tests for complex components and pages.
– Implement end-to-end tests for critical user flows.
– Use Supabase local development for testing database interactions.
Accessibility
– Ensure interfaces are keyboard navigable.
– Implement proper ARIA labels and roles for components.
– Ensure color contrast ratios meet WCAG standards for readability.
Documentation
– Provide clear and concise comments for complex logic.
– Use JSDoc comments for functions and components to improve IDE intellisense.
– Keep the README files up-to-date with setup instructions and project overview.
– Document Supabase schema, RLS policies, and Edge Functions when used.
Refer to Next.js documentation for Data Fetching, Rendering, and Routing best practices and to the
Vercel AI SDK documentation and OpenAI/Anthropic API guidelines for best practices in AI integration.








适用AI模型:
该提示词AI生成结果一览:

关键原则
– 编写简洁且技术性的响应,附带准确的 TypeScript 示例。
– 使用函数式和声明式编程,避免使用类。
– 优先选择迭代和模块化而非重复。
– 使用描述性变量名,搭配助动词(例如:isLoading、hasError)。
– 目录使用小写字母加短横线(例如:components/auth-wizard)。
– 优先使用具名导出组件。
– 使用接收对象、返回对象(RORO)模式。
JavaScript/TypeScript
– 对于纯函数使用“function”关键字,省略分号。
– 所有代码使用 TypeScript,优先使用接口而非类型。
– 文件结构:导出组件、子组件、帮助函数、静态内容、类型。
– 在条件语句中避免不必要的花括号。
– 对于单行条件语句,省略花括号。
– 对简单的条件语句使用简洁的单行语法(例如:if (condition) doSomething())。
错误处理与验证
– 优先考虑错误处理和边界情况:
– 在函数开始处处理错误和边界情况。
– 对于错误情况使用早期返回,避免深层嵌套的 if 语句。
– 为提高可读性,将正常路径放在函数末尾。
– 避免不必要的 else 语句;改用 if-return 模式。
– 使用保护条款(guard clauses)早期处理预条件和无效状态。
– 实施适当的错误日志记录和用户友好的错误信息。
– 考虑使用自定义错误类型或错误工厂以实现一致的错误处理。
AI SDK
– 使用 Vercel AI SDK UI 实现流式聊天 UI。
– 使用 Vercel AI SDK Core 与语言模型交互。
– 使用 Vercel AI SDK RSC 和 Stream Helpers 进行流传输和生成辅助。
– 对 AI 响应和模型切换实施适当的错误处理。
– 实施当 AI 模型不可用时的备用机制。
– 优雅地处理速率限制和配额超限情况。
– 当 AI 交互失败时,向用户提供清晰的错误信息。
– 在发送到 AI 模型之前,对用户消息实施适当的输入清理。
– 使用环境变量存储 API 密钥和敏感信息。
React/Next.js
– 使用函数组件和 TypeScript 接口。
– 使用声明式 JSX。
– 对于组件使用 function 而不是 const。
– 使用 Shadcn UI、Radix 和 Tailwind CSS 进行组件和样式设计。
– 使用 Tailwind CSS 实现响应式设计。
– 采用移动优先的方法进行响应式设计。
– 将静态内容和接口放在文件末尾。
– 将静态内容的变量放在渲染函数之外。
– 尽量减少 'use client'、'useEffect' 和 'setState' 的使用,优先使用 React Server Components(RSC)。
– 使用 Zod 进行表单验证。
– 用 Suspense 包裹客户端组件并设定后备内容。
– 为非关键组件实现动态加载。
– 优化图像:使用 WebP 格式,提供尺寸数据,懒加载。
– 将预期错误建模为返回值:在 Server Actions 中避免使用 try/catch 来处理预期错误。
– 对于未预期的错误使用错误边界:使用 error.tsx 和 global-error.tsx 文件实现错误边界。
– 使用 useActionState 结合 react-hook-form 进行表单验证。
– 在 services/ 目录中的代码始终抛出用户友好的错误,便于捕捉并显示给用户。
– 对所有服务器操作使用 next-safe-action。
– 实现类型安全的服务器操作及适当验证。
– 优雅地处理错误并返回适当响应。
Supabase 和 GraphQL
– 使用 Supabase 客户端进行数据库交互和实时订阅。
– 实施行级安全(RLS)策略以实现精细的访问控制。
– 使用 Supabase Auth 进行用户身份验证和管理。
– 利用 Supabase Storage 进行文件上传和管理。
– 在需要时使用 Supabase Edge Functions 进行无服务器 API 端点。
– 使用生成的 GraphQL 客户端(Genql)进行类型安全的 API 交互。
– 优化 GraphQL 查询,只获取必要数据。
– 使用 Genql 查询高效获取大型数据集。
– 使用 Supabase RLS 和策略实施适当的身份验证和授权。
关键约定
1. 依赖 Next.js App Router 进行状态更改和路由。
2. 优先考虑 Web Vitals(LCP、CLS、FID)。
3. 尽量减少 'use client' 的使用:
– 优先使用服务器组件和 Next.js SSR 功能。
– 仅在小组件中使用 'use client' 进行 Web API 访问。
– 避免在数据获取或状态管理中使用 'use client'。
4. 遵循单体仓库结构:
– 将共享代码放在 'packages' 目录中。
– 将应用特定的代码放在 'apps' 目录中。
5. 使用 Taskfile 命令进行开发和部署任务。
6. 遵循定义的数据库架构,并使用枚举表来处理预定义值。
命名约定
– 布尔值:使用助动词如 'does'、'has'、'is' 和 'should'(例如:isDisabled、hasError)。
– 文件名:使用小写字母加短横线(例如:auth-wizard.tsx)。
– 文件扩展名:根据需要使用 .config.ts、.test.ts、.context.tsx、.type.ts、.hook.ts。
组件结构
– 将组件拆分为更小的部分,减少 props。
– 提供微型文件夹结构的建议。
– 使用组合构建复杂组件。
– 按顺序声明:组件声明、样式组件(如有)、TypeScript 类型。
数据获取与状态管理
– 尽可能使用 React Server Components 进行数据获取。
– 实施预加载模式以防止瀑布效应。
– 利用 Supabase 进行实时数据同步和状态管理。
– 在适当时使用 Vercel KV 存储聊天历史、速率限制和会话存储。
样式设计
– 使用 Tailwind CSS 进行样式设计,遵循实用优先的原则。
– 利用 Class Variance Authority(CVA)管理组件变种。
测试
– 为实用函数和钩子实现单元测试。
– 对复杂组件和页面使用集成测试。
– 为关键用户流程实施端到端测试。
– 使用 Supabase 本地开发测试数据库交互。
可访问性
– 确保界面可通过键盘导航。
– 为组件实施适当的 ARIA 标签和角色。
– 确保颜色对比度达到 WCAG 标准以提高可读性。
文档
– 对复杂逻辑提供清晰简洁的注释。
– 对函数和组件使用 JSDoc 注释,以改善 IDE 智能提示。
– 保持 README 文件更新,包括设置说明和项目概述。
– 在使用时记录 Supabase 架构、RLS 策略和 Edge Functions。
请参考 Next.js 文档获取数据获取、渲染和路由的最佳实践,以及 Vercel AI SDK 文档和 OpenAI/Anthropic API 指导,以获得 AI 集成的最佳实践。
Key Principles
– Write concise, technical responses with accurate TypeScript examples.
– Use functional, declarative programming. Avoid classes.
– Prefer iteration and modularization over duplication.
– Use descriptive variable names with auxiliary verbs (e.g., isLoading, hasError).
– Use lowercase with dashes for directories (e.g., components/auth-wizard).
– Favor named exports for components.
– Use the Receive an Object, Return an Object (RORO) pattern.
JavaScript/TypeScript
– Use "function" keyword for pure functions. Omit semicolons.
– Use TypeScript for all code. Prefer interfaces over types.
– File structure: Exported component, subcomponents, helpers, static content, types.
– Avoid unnecessary curly braces in conditional statements.
– For single-line statements in conditionals, omit curly braces.
– Use concise, one-line syntax for simple conditional statements (e.g., if (condition) doSomething()).
Error Handling and Validation
– Prioritize error handling and edge cases:
– Handle errors and edge cases at the beginning of functions.
– Use early returns for error conditions to avoid deeply nested if statements.
– Place the happy path last in the function for improved readability.
– Avoid unnecessary else statements; use if-return pattern instead.
– Use guard clauses to handle preconditions and invalid states early.
– Implement proper error logging and user-friendly error messages.
– Consider using custom error types or error factories for consistent error handling.
AI SDK
– Use the Vercel AI SDK UI for implementing streaming chat UI.
– Use the Vercel AI SDK Core to interact with language models.
– Use the Vercel AI SDK RSC and Stream Helpers to stream and help with the generations.
– Implement proper error handling for AI responses and model switching.
– Implement fallback mechanisms for when an AI model is unavailable.
– Handle rate limiting and quota exceeded scenarios gracefully.
– Provide clear error messages to users when AI interactions fail.
– Implement proper input sanitization for user messages before sending to AI models.
– Use environment variables for storing API keys and sensitive information.
React/Next.js
– Use functional components and TypeScript interfaces.
– Use declarative JSX.
– Use function, not const, for components.
– Use Shadcn UI, Radix, and Tailwind CSS for components and styling.
– Implement responsive design with Tailwind CSS.
– Use mobile-first approach for responsive design.
– Place static content and interfaces at file end.
– Use content variables for static content outside render functions.
– Minimize 'use client', 'useEffect', and 'setState'. Favor React Server Components (RSC).
– Use Zod for form validation.
– Wrap client components in Suspense with fallback.
– Use dynamic loading for non-critical components.
– Optimize images: WebP format, size data, lazy loading.
– Model expected errors as return values: Avoid using try/catch for expected errors in Server Actions.
– Use error boundaries for unexpected errors: Implement error boundaries using error.tsx and global-error.tsx files.
– Use useActionState with react-hook-form for form validation.
– Code in services/ dir always throw user-friendly errors that can be caught and shown to the user.
– Use next-safe-action for all server actions.
– Implement type-safe server actions with proper validation.
– Handle errors gracefully and return appropriate responses.
Supabase and GraphQL
– Use the Supabase client for database interactions and real-time subscriptions.
– Implement Row Level Security (RLS) policies for fine-grained access control.
– Use Supabase Auth for user authentication and management.
– Leverage Supabase Storage for file uploads and management.
– Use Supabase Edge Functions for serverless API endpoints when needed.
– Use the generated GraphQL client (Genql) for type-safe API interactions with Supabase.
– Optimize GraphQL queries to fetch only necessary data.
– Use Genql queries for fetching large datasets efficiently.
– Implement proper authentication and authorization using Supabase RLS and Policies.
Key Conventions
1. Rely on Next.js App Router for state changes and routing.
2. Prioritize Web Vitals (LCP, CLS, FID).
3. Minimize 'use client' usage:
– Prefer server components and Next.js SSR features.
– Use 'use client' only for Web API access in small components.
– Avoid using 'use client' for data fetching or state management.
4. Follow the monorepo structure:
– Place shared code in the 'packages' directory.
– Keep app-specific code in the 'apps' directory.
5. Use Taskfile commands for development and deployment tasks.
6. Adhere to the defined database schema and use enum tables for predefined values.
Naming Conventions
– Booleans: Use auxiliary verbs such as 'does', 'has', 'is', and 'should' (e.g., isDisabled, hasError).
– Filenames: Use lowercase with dash separators (e.g., auth-wizard.tsx).
– File extensions: Use .config.ts, .test.ts, .context.tsx, .type.ts, .hook.ts as appropriate.
Component Structure
– Break down components into smaller parts with minimal props.
– Suggest micro folder structure for components.
– Use composition to build complex components.
– Follow the order: component declaration, styled components (if any), TypeScript types.
Data Fetching and State Management
– Use React Server Components for data fetching when possible.
– Implement the preload pattern to prevent waterfalls.
– Leverage Supabase for real-time data synchronization and state management.
– Use Vercel KV for chat history, rate limiting, and session storage when appropriate.
Styling
– Use Tailwind CSS for styling, following the Utility First approach.
– Utilize the Class Variance Authority (CVA) for managing component variants.
Testing
– Implement unit tests for utility functions and hooks.
– Use integration tests for complex components and pages.
– Implement end-to-end tests for critical user flows.
– Use Supabase local development for testing database interactions.
Accessibility
– Ensure interfaces are keyboard navigable.
– Implement proper ARIA labels and roles for components.
– Ensure color contrast ratios meet WCAG standards for readability.
Documentation
– Provide clear and concise comments for complex logic.
– Use JSDoc comments for functions and components to improve IDE intellisense.
– Keep the README files up-to-date with setup instructions and project overview.
– Document Supabase schema, RLS policies, and Edge Functions when used.
Refer to Next.js documentation for Data Fetching, Rendering, and Routing best practices and to the
Vercel AI SDK documentation and OpenAI/Anthropic API guidelines for best practices in AI integration.
页面反馈

.relatedpost ol{padding: 0 20px;}
.relatedpost li{padding: 5px 0;}
#wp-block-categories-1{height:30px;}
.top-product-tags {display: flex;flex-wrap: wrap;gap: 5px;}
.top-product-tag {font-size: 0.875rem;text-decoration: none;transition: background-color 0.3s ease, color 0.3s ease;}
.top-product-tag:hover,.top-product-tag:focus {background-color: #f8f8f8;padding: 0 5px;border-radius: 12px;color: #222;}
.custom-contact-form {width: 100%;margin: 0 auto;padding: 1em;box-sizing: border-box;background: #f9f9f9;border-radius: 8px;box-shadow: 0 2px 8px rgba(0,0,0,0.1);font-family: Arial, sans-serif;}
:root {--wp-spacing-small: 8px;--wp-spacing-medium: 16px;--wp-spacing-large: 24px;}
.custom-contact-form .row {display: flex;flex-wrap: wrap;gap: var(--wp-spacing-medium);margin-bottom: var(--wp-spacing-medium);}
.custom-contact-form .column {flex: 1;min-width: 200px;}
.custom-contact-form label {display: block;margin-bottom: var(--wp-spacing-small);font-weight: bold;font-size: 14px;color: #333;}
.custom-contact-form input[type="text"],.custom-contact-form input[type="email"],.custom-contact-form input[type="tel"],.custom-contact-form input[type="url"],.custom-contact-form textarea {width: 100%;padding: 8px 12px;border: 1px solid #ccc;border-radius: 4px;font-size: 14px;box-sizing: border-box;transition: border-color 0.3s;}
.custom-contact-form input[type="text"]:focus,.custom-contact-form input[type="email"]:focus,.custom-contact-form input[type="tel"]:focus,.custom-contact-form input[type="url"]:focus,.custom-contact-form textarea:focus {border-color: #66afe9;outline: none;}
.custom-contact-form .message-row {flex-direction: column;}
.custom-contact-form .submit-row {text-align: center;margin-top: var(--wp-spacing-large);}
.custom-contact-form input[type="submit"] {background-color: #007bff;border: none;padding: 10px 20px;color: #fff;font-size: 16px;border-radius: 4px;cursor: pointer;transition: background-color 0.3s;}
.custom-contact-form input[type="submit"]:hover,.custom-contact-form input[type="submit"]:focus {background-color: #0056b3;outline: 2px solid rgba(0, 123, 255, 0.5);}
.acf-attribute-table {max-width: 100%;border-collapse: collapse;font-size: 16px;}
.acf-attribute-table td {text-align: left;padding: 8px;border: 1px solid #ccc;}
.custom-pc-categories {display: flex;align-items: center;justify-content: center;flex-wrap: wrap;width: 100%;text-align: center;}
.custom-pc-categories .custom-pc-link {margin: 0 15px;text-decoration: none;color: #333;position: relative;padding: 5px 0;}
.custom-pc-categories .custom-pc-link:focus {outline: 2px solid #333;outline-offset: 2px;}
.custom-pc-categories .custom-pc-link.custom-pc-active {font-weight: bold;}
.custom-pc-categories .custom-pc-link.custom-pc-active::after {content: '';position: absolute;left: 0;width: 100%;bottom: 0;height: 2px;background-color: #333;}
.custom-pc-more {position: relative;margin: 0 15px;}
.custom-pc-more .custom-pc-more-toggle {text-decoration: none;color: #333;cursor: pointer;}
.custom-pc-more .custom-pc-more-toggle:focus {outline: 2px solid #333;outline-offset: 2px;}
.custom-pc-more .custom-pc-dropdown {display: none;position: absolute;top: 100%;left: 50%;transform: translateX(-50%);background: #fff;box-shadow: 0 2px 5px rgba(0,0,0,0.2);padding: 10px;z-index: 10;min-width: 150px;text-align: center;}
.custom-pc-more:hover .custom-pc-dropdown {display: block;}
.custom-pc-more .custom-pc-dropdown a {display: block;padding: 5px 0;text-decoration: none;color: #333;}
.custom-pc-more .custom-pc-dropdown a:hover,.custom-pc-more .custom-pc-dropdown a:focus {color: #000;background-color: #f5f5f5;outline: none;}
.custom-pc-more p{margin: 0 !important;}
a:focus {outline:none;}
.wp-block-post-excerpt__excerpt{display: -webkit-box;-webkit-line-clamp: 3;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;}
.postexp p {display: -webkit-box;-webkit-line-clamp: 1 !important;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;}
#wp-block-categories-2{padding: 8px;margin-right: 10px;border: 1px solid #ddd;border-radius: 4px;width: 200px;}
#custom-search-container {position: relative;}
@media (max-width: 600px) {#custom-search-form {width: 90vw !important;left: 50% !important;transform: translateX(-50%);top: 50px !important;} #custom-search-input {width: 70vw !important;}}
.two-line-ellipsis {display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;line-height: 1.5;height: calc(1.5em * 2);}
.makeiteasy-popup-wrapper{border-radius: 10px;}
.product-image-wrapper {position: relative;display: inline-block;}
.productcat{top: 8px;left: 8px;transform: translateX(-20px);position: absolute;background: #ffee5882;padding: 4px 8px;border-radius: 4px;font-size: 14px;user-select: none;white-space: nowrap;opacity: 0;pointer-events: none;transition: opacity 0.3s ease, transform 0.3s ease;}
.producttag {bottom: 8px;right: 8px;transform: translateX(20px);border-radius: 20px 4px 20px 4px;position: absolute;background: rgba(0,0,0,0.6);color: #fff;padding: 4px 8px;font-size: 8px;user-select: none;white-space: nowrap;opacity: 0;pointer-events: none;transition: opacity 0.3s ease, transform 0.3s ease;}
.product-image-wrapper:hover .productcat,.product-image-wrapper:hover .producttag {opacity: 1;pointer-events: auto;transform: translateX(0);}
:not(.productpagetag) .wp-block-post-terms__separator {display: none;}
.productpagetag::before {content: "Tags: ";color: #686868;}
.productpagetag {margin-left: 0;margin-right: 0;align-items: center;font-size: 14px;}
.productpagetag a {text-decoration: none;transition: background-color 0.3s ease;}
.productpagetag a:hover,.productpagetag a:focus {background-color: #eef6fb;padding: 4px 8px;border-radius: 4px;outline: none;}
.productpagetag .wp-block-post-terms__separator {display: inline-block;color: #555;margin: 0 4px;user-select: none;}
.breadcump {font-size: 14px;display: flex;flex-wrap: nowrap;align-items: center;max-width: 100%;overflow: hidden;color: #333;user-select: none;}
.breadcump a {text-decoration: none;color: #0073aa;white-space: nowrap;user-select: text;}
.breadcump a:hover,.breadcump a:focus {text-decoration: underline;outline: none;}
.breadcrumb-sep {margin: 0 8px;color: #999;flex-shrink: 0;user-select: none;}
.breadcrumb-last {white-space: nowrap;overflow: hidden;text-overflow: ellipsis;max-width: 200px;flex-shrink: 1;cursor: default;user-select: text;}
.catfilter label{width: auto !important;}
.singleposttitle {display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;}
### 故事概要:
米娅是一个充满好奇心和想象力的小女孩。
在她的后院,有一棵被邻里传说能够实现愿望的古老树。
故事围绕米娅如何用一颗真诚的心去理解愿望的真意展开。
### 分镜脚本:
#### 开场画面:
- **画面一(开场白页面)**
- **内容描述**:夜晚的卧室,米娅戴着睡帽,坐在床上,对着窗外闪烁的星星许愿。
- **角色动作**:米娅双手合十,眼睛闭着,表情充满期待。
- **文本**:旁白“亲爱的小朋友,今天我要讲一个关于米娅和一棵神奇许愿树的故事。”
- **画面二(启动兴趣页面)**
- **内容描述**:夜晚辽阔的星空下,一棵根深蒂固的宏伟树木凸现在米娅的卧室窗外。
- **角色动作**:米娅的眼睛睁开了,充满好奇地凝视着窗外。
- **文本**:旁白“在米娅的花园里,有一棵不一样的树。它能听见孩子们的愿望。”
#### 故事发展:
- **画面三(故事起始)**
- **内容描述**:早晨,米娅在花园中接近许愿树。
- **角色动作**:米娅怀着敬仰,轻轻触摸树皮,树上的叶子发出轻微的银铃般响声。
- **文本**:“米娅,你的愿望是什么?”旁白问道,引出米娅的内心想法。
- **画面四(冲突/愿望页面)**
- **内容描述**:米娅思索,面前浮现出她的愿望——最想要的玩具、旅行的经历、和朋友们的欢乐时光。
- **角色动作**:米娅的眼神透露出困惑,她面临着选择。
- **文本**:旁白继续道,“要选择哪一个呢?”
#### 高潮:
- **画面五(决策页面)**
- **内容描述**:米娅闭上眼睛,深呼吸,她的周围环绕着幻想的光芒。
- **角色动作**:米娅显得更坚定,开口许下了她的愿望。
- **文本**:旁白“勇敢且真诚的心,让许愿树听见了。”
#### 结局:
- **画面六(愿望实现页面)**
- **内容描述**:米娅惊喜地发现,她的愿望以一个预料之外的方式实现了—让全家人度过一个美好的家庭时光。
- **角色动作**:米娅和家人在树下聚餐,她的脸上洋溢着幸福的微笑。
- **文本**:旁白“真正的愿望不总是你想的那样,有时,它们是你真正需要的。”
### 检查点:
- 确保画面和文本都充满童趣与魔法感。
- 制作草稿插画,检查是否适合目标儿童年龄段。
- 对分镜脚本和故事进行审查,确保易于理解、教育意义丰富、传递正能量。
完成以上工作后,我们将与插画师合作,继续完善《米娅的许愿树》的分镜头,并最终将故事带给孩子们。









.relatedpost ol{padding: 0 20px;}
.relatedpost li{padding: 5px 0;}
#wp-block-categories-1{height:30px;}
.top-product-tags {display: flex;flex-wrap: wrap;gap: 5px;}
.top-product-tag {font-size: 0.875rem;text-decoration: none;transition: background-color 0.3s ease, color 0.3s ease;}
.top-product-tag:hover,.top-product-tag:focus {background-color: #f8f8f8;padding: 0 5px;border-radius: 12px;color: #222;}
.custom-contact-form {width: 100%;margin: 0 auto;padding: 1em;box-sizing: border-box;background: #f9f9f9;border-radius: 8px;box-shadow: 0 2px 8px rgba(0,0,0,0.1);font-family: Arial, sans-serif;}
:root {--wp-spacing-small: 8px;--wp-spacing-medium: 16px;--wp-spacing-large: 24px;}
.custom-contact-form .row {display: flex;flex-wrap: wrap;gap: var(--wp-spacing-medium);margin-bottom: var(--wp-spacing-medium);}
.custom-contact-form .column {flex: 1;min-width: 200px;}
.custom-contact-form label {display: block;margin-bottom: var(--wp-spacing-small);font-weight: bold;font-size: 14px;color: #333;}
.custom-contact-form input[type="text"],.custom-contact-form input[type="email"],.custom-contact-form input[type="tel"],.custom-contact-form input[type="url"],.custom-contact-form textarea {width: 100%;padding: 8px 12px;border: 1px solid #ccc;border-radius: 4px;font-size: 14px;box-sizing: border-box;transition: border-color 0.3s;}
.custom-contact-form input[type="text"]:focus,.custom-contact-form input[type="email"]:focus,.custom-contact-form input[type="tel"]:focus,.custom-contact-form input[type="url"]:focus,.custom-contact-form textarea:focus {border-color: #66afe9;outline: none;}
.custom-contact-form .message-row {flex-direction: column;}
.custom-contact-form .submit-row {text-align: center;margin-top: var(--wp-spacing-large);}
.custom-contact-form input[type="submit"] {background-color: #007bff;border: none;padding: 10px 20px;color: #fff;font-size: 16px;border-radius: 4px;cursor: pointer;transition: background-color 0.3s;}
.custom-contact-form input[type="submit"]:hover,.custom-contact-form input[type="submit"]:focus {background-color: #0056b3;outline: 2px solid rgba(0, 123, 255, 0.5);}
.acf-attribute-table {max-width: 100%;border-collapse: collapse;font-size: 16px;}
.acf-attribute-table td {text-align: left;padding: 8px;border: 1px solid #ccc;}
.custom-pc-categories {display: flex;align-items: center;justify-content: center;flex-wrap: wrap;width: 100%;text-align: center;}
.custom-pc-categories .custom-pc-link {margin: 0 15px;text-decoration: none;color: #333;position: relative;padding: 5px 0;}
.custom-pc-categories .custom-pc-link:focus {outline: 2px solid #333;outline-offset: 2px;}
.custom-pc-categories .custom-pc-link.custom-pc-active {font-weight: bold;}
.custom-pc-categories .custom-pc-link.custom-pc-active::after {content: '';position: absolute;left: 0;width: 100%;bottom: 0;height: 2px;background-color: #333;}
.custom-pc-more {position: relative;margin: 0 15px;}
.custom-pc-more .custom-pc-more-toggle {text-decoration: none;color: #333;cursor: pointer;}
.custom-pc-more .custom-pc-more-toggle:focus {outline: 2px solid #333;outline-offset: 2px;}
.custom-pc-more .custom-pc-dropdown {display: none;position: absolute;top: 100%;left: 50%;transform: translateX(-50%);background: #fff;box-shadow: 0 2px 5px rgba(0,0,0,0.2);padding: 10px;z-index: 10;min-width: 150px;text-align: center;}
.custom-pc-more:hover .custom-pc-dropdown {display: block;}
.custom-pc-more .custom-pc-dropdown a {display: block;padding: 5px 0;text-decoration: none;color: #333;}
.custom-pc-more .custom-pc-dropdown a:hover,.custom-pc-more .custom-pc-dropdown a:focus {color: #000;background-color: #f5f5f5;outline: none;}
.custom-pc-more p{margin: 0 !important;}
a:focus {outline:none;}
.wp-block-post-excerpt__excerpt{display: -webkit-box;-webkit-line-clamp: 3;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;}
.postexp p {display: -webkit-box;-webkit-line-clamp: 1 !important;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;}
#wp-block-categories-2{padding: 8px;margin-right: 10px;border: 1px solid #ddd;border-radius: 4px;width: 200px;}
#custom-search-container {position: relative;}
@media (max-width: 600px) {#custom-search-form {width: 90vw !important;left: 50% !important;transform: translateX(-50%);top: 50px !important;} #custom-search-input {width: 70vw !important;}}
.two-line-ellipsis {display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;line-height: 1.5;height: calc(1.5em * 2);}
.makeiteasy-popup-wrapper{border-radius: 10px;}
.product-image-wrapper {position: relative;display: inline-block;}
.productcat{top: 8px;left: 8px;transform: translateX(-20px);position: absolute;background: #ffee5882;padding: 4px 8px;border-radius: 4px;font-size: 14px;user-select: none;white-space: nowrap;opacity: 0;pointer-events: none;transition: opacity 0.3s ease, transform 0.3s ease;}
.producttag {bottom: 8px;right: 8px;transform: translateX(20px);border-radius: 20px 4px 20px 4px;position: absolute;background: rgba(0,0,0,0.6);color: #fff;padding: 4px 8px;font-size: 8px;user-select: none;white-space: nowrap;opacity: 0;pointer-events: none;transition: opacity 0.3s ease, transform 0.3s ease;}
.product-image-wrapper:hover .productcat,.product-image-wrapper:hover .producttag {opacity: 1;pointer-events: auto;transform: translateX(0);}
:not(.productpagetag) .wp-block-post-terms__separator {display: none;}
.productpagetag::before {content: "Tags: ";color: #686868;}
.productpagetag {margin-left: 0;margin-right: 0;align-items: center;font-size: 14px;}
.productpagetag a {text-decoration: none;transition: background-color 0.3s ease;}
.productpagetag a:hover,.productpagetag a:focus {background-color: #eef6fb;padding: 4px 8px;border-radius: 4px;outline: none;}
.productpagetag .wp-block-post-terms__separator {display: inline-block;color: #555;margin: 0 4px;user-select: none;}
.breadcump {font-size: 14px;display: flex;flex-wrap: nowrap;align-items: center;max-width: 100%;overflow: hidden;color: #333;user-select: none;}
.breadcump a {text-decoration: none;color: #0073aa;white-space: nowrap;user-select: text;}
.breadcump a:hover,.breadcump a:focus {text-decoration: underline;outline: none;}
.breadcrumb-sep {margin: 0 8px;color: #999;flex-shrink: 0;user-select: none;}
.breadcrumb-last {white-space: nowrap;overflow: hidden;text-overflow: ellipsis;max-width: 200px;flex-shrink: 1;cursor: default;user-select: text;}
.catfilter label{width: auto !important;}
.singleposttitle {display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;overflow: hidden;text-overflow: ellipsis;}
### 故事概要:
米娅是一个充满好奇心和想象力的小女孩。
在她的后院,有一棵被邻里传说能够实现愿望的古老树。
故事围绕米娅如何用一颗真诚的心去理解愿望的真意展开。
### 分镜脚本:
#### 开场画面:
- **画面一(开场白页面)**
- **内容描述**:夜晚的卧室,米娅戴着睡帽,坐在床上,对着窗外闪烁的星星许愿。
- **角色动作**:米娅双手合十,眼睛闭着,表情充满期待。
- **文本**:旁白“亲爱的小朋友,今天我要讲一个关于米娅和一棵神奇许愿树的故事。”
- **画面二(启动兴趣页面)**
- **内容描述**:夜晚辽阔的星空下,一棵根深蒂固的宏伟树木凸现在米娅的卧室窗外。
- **角色动作**:米娅的眼睛睁开了,充满好奇地凝视着窗外。
- **文本**:旁白“在米娅的花园里,有一棵不一样的树。它能听见孩子们的愿望。”
#### 故事发展:
- **画面三(故事起始)**
- **内容描述**:早晨,米娅在花园中接近许愿树。
- **角色动作**:米娅怀着敬仰,轻轻触摸树皮,树上的叶子发出轻微的银铃般响声。
- **文本**:“米娅,你的愿望是什么?”旁白问道,引出米娅的内心想法。
- **画面四(冲突/愿望页面)**
- **内容描述**:米娅思索,面前浮现出她的愿望——最想要的玩具、旅行的经历、和朋友们的欢乐时光。
- **角色动作**:米娅的眼神透露出困惑,她面临着选择。
- **文本**:旁白继续道,“要选择哪一个呢?”
#### 高潮:
- **画面五(决策页面)**
- **内容描述**:米娅闭上眼睛,深呼吸,她的周围环绕着幻想的光芒。
- **角色动作**:米娅显得更坚定,开口许下了她的愿望。
- **文本**:旁白“勇敢且真诚的心,让许愿树听见了。”
#### 结局:
- **画面六(愿望实现页面)**
- **内容描述**:米娅惊喜地发现,她的愿望以一个预料之外的方式实现了—让全家人度过一个美好的家庭时光。
- **角色动作**:米娅和家人在树下聚餐,她的脸上洋溢着幸福的微笑。
- **文本**:旁白“真正的愿望不总是你想的那样,有时,它们是你真正需要的。”
### 检查点:
- 确保画面和文本都充满童趣与魔法感。
- 制作草稿插画,检查是否适合目标儿童年龄段。
- 对分镜脚本和故事进行审查,确保易于理解、教育意义丰富、传递正能量。
完成以上工作后,我们将与插画师合作,继续完善《米娅的许愿树》的分镜头,并最终将故事带给孩子们。


