@nextsparkjs/theme-default 0.1.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (333) hide show
  1. package/about/business.md +49 -0
  2. package/about/features.json +302 -0
  3. package/about/team.md +79 -0
  4. package/api/ai/chat/stream/route.ts +212 -0
  5. package/api/ai/orchestrator/route.ts +226 -0
  6. package/api/ai/single-agent/route.ts +291 -0
  7. package/api/ai/usage/route.ts +122 -0
  8. package/blocks/benefits/component.tsx +100 -0
  9. package/blocks/benefits/config.ts +11 -0
  10. package/blocks/benefits/examples.ts +85 -0
  11. package/blocks/benefits/fields.ts +156 -0
  12. package/blocks/benefits/schema.ts +33 -0
  13. package/blocks/cta-section/component.tsx +100 -0
  14. package/blocks/cta-section/config.ts +11 -0
  15. package/blocks/cta-section/examples.ts +41 -0
  16. package/blocks/cta-section/fields.ts +89 -0
  17. package/blocks/cta-section/index.ts +6 -0
  18. package/blocks/cta-section/schema.ts +32 -0
  19. package/blocks/cta-section/thumbnail.png +1 -0
  20. package/blocks/faq-accordion/component.tsx +156 -0
  21. package/blocks/faq-accordion/config.ts +11 -0
  22. package/blocks/faq-accordion/examples.ts +77 -0
  23. package/blocks/faq-accordion/fields.ts +119 -0
  24. package/blocks/faq-accordion/index.ts +6 -0
  25. package/blocks/faq-accordion/schema.ts +45 -0
  26. package/blocks/features-grid/component.tsx +112 -0
  27. package/blocks/features-grid/config.ts +11 -0
  28. package/blocks/features-grid/examples.ts +63 -0
  29. package/blocks/features-grid/fields.ts +97 -0
  30. package/blocks/features-grid/index.ts +6 -0
  31. package/blocks/features-grid/schema.ts +40 -0
  32. package/blocks/features-grid/thumbnail.png +1 -0
  33. package/blocks/hero/component.tsx +100 -0
  34. package/blocks/hero/config.ts +11 -0
  35. package/blocks/hero/examples.ts +35 -0
  36. package/blocks/hero/fields.ts +60 -0
  37. package/blocks/hero/index.ts +6 -0
  38. package/blocks/hero/schema.ts +32 -0
  39. package/blocks/hero/thumbnail.png +1 -0
  40. package/blocks/hero/thumbnail.png.txt +6 -0
  41. package/blocks/hero-with-form/component.tsx +232 -0
  42. package/blocks/hero-with-form/config.ts +11 -0
  43. package/blocks/hero-with-form/examples.ts +16 -0
  44. package/blocks/hero-with-form/fields.ts +207 -0
  45. package/blocks/hero-with-form/index.ts +6 -0
  46. package/blocks/hero-with-form/schema.ts +54 -0
  47. package/blocks/jumbotron/component.tsx +136 -0
  48. package/blocks/jumbotron/config.ts +11 -0
  49. package/blocks/jumbotron/examples.ts +36 -0
  50. package/blocks/jumbotron/fields.ts +202 -0
  51. package/blocks/jumbotron/index.ts +6 -0
  52. package/blocks/jumbotron/schema.ts +55 -0
  53. package/blocks/logo-cloud/component.tsx +154 -0
  54. package/blocks/logo-cloud/config.ts +11 -0
  55. package/blocks/logo-cloud/examples.ts +34 -0
  56. package/blocks/logo-cloud/fields.ts +133 -0
  57. package/blocks/logo-cloud/index.ts +6 -0
  58. package/blocks/logo-cloud/schema.ts +46 -0
  59. package/blocks/post-content/component.tsx +197 -0
  60. package/blocks/post-content/config.ts +11 -0
  61. package/blocks/post-content/examples.ts +33 -0
  62. package/blocks/post-content/fields.ts +165 -0
  63. package/blocks/post-content/index.ts +4 -0
  64. package/blocks/post-content/schema.ts +46 -0
  65. package/blocks/pricing-table/component.tsx +154 -0
  66. package/blocks/pricing-table/config.ts +11 -0
  67. package/blocks/pricing-table/examples.ts +96 -0
  68. package/blocks/pricing-table/fields.ts +161 -0
  69. package/blocks/pricing-table/index.ts +4 -0
  70. package/blocks/pricing-table/schema.ts +50 -0
  71. package/blocks/split-content/component.tsx +135 -0
  72. package/blocks/split-content/config.ts +11 -0
  73. package/blocks/split-content/examples.ts +38 -0
  74. package/blocks/split-content/fields.ts +198 -0
  75. package/blocks/split-content/index.ts +6 -0
  76. package/blocks/split-content/schema.ts +67 -0
  77. package/blocks/stats-counter/component.tsx +124 -0
  78. package/blocks/stats-counter/config.ts +11 -0
  79. package/blocks/stats-counter/examples.ts +61 -0
  80. package/blocks/stats-counter/fields.ts +134 -0
  81. package/blocks/stats-counter/index.ts +6 -0
  82. package/blocks/stats-counter/schema.ts +47 -0
  83. package/blocks/testimonials/component.tsx +114 -0
  84. package/blocks/testimonials/config.ts +11 -0
  85. package/blocks/testimonials/examples.ts +65 -0
  86. package/blocks/testimonials/fields.ts +105 -0
  87. package/blocks/testimonials/index.ts +6 -0
  88. package/blocks/testimonials/schema.ts +41 -0
  89. package/blocks/testimonials/thumbnail.png +1 -0
  90. package/blocks/text-content/component.tsx +97 -0
  91. package/blocks/text-content/config.ts +11 -0
  92. package/blocks/text-content/examples.ts +30 -0
  93. package/blocks/text-content/fields.ts +88 -0
  94. package/blocks/text-content/index.ts +6 -0
  95. package/blocks/text-content/schema.ts +30 -0
  96. package/blocks/text-content/thumbnail.png +1 -0
  97. package/blocks/timeline/component.tsx +267 -0
  98. package/blocks/timeline/config.ts +11 -0
  99. package/blocks/timeline/examples.ts +68 -0
  100. package/blocks/timeline/fields.ts +147 -0
  101. package/blocks/timeline/index.ts +6 -0
  102. package/blocks/timeline/schema.ts +49 -0
  103. package/blocks/video-hero/component.tsx +270 -0
  104. package/blocks/video-hero/config.ts +11 -0
  105. package/blocks/video-hero/examples.ts +24 -0
  106. package/blocks/video-hero/fields.ts +98 -0
  107. package/blocks/video-hero/index.ts +6 -0
  108. package/blocks/video-hero/schema.ts +39 -0
  109. package/components/ai-chat/ChatPanel.tsx +575 -0
  110. package/components/ai-chat/ConversationItem.tsx +266 -0
  111. package/components/ai-chat/ConversationSidebar.tsx +99 -0
  112. package/components/ai-chat/MarkdownRenderer.tsx +15 -0
  113. package/components/ai-chat/Message.tsx +42 -0
  114. package/components/ai-chat/MessageInput.tsx +49 -0
  115. package/components/ai-chat/MessageList.tsx +46 -0
  116. package/components/ai-chat/TypingIndicator.tsx +11 -0
  117. package/config/app.config.ts +367 -0
  118. package/config/billing.config.ts +349 -0
  119. package/config/dashboard.config.ts +506 -0
  120. package/config/dev.config.ts +104 -0
  121. package/config/features.config.ts +203 -0
  122. package/config/flows.config.ts +129 -0
  123. package/config/permissions.config.ts +245 -0
  124. package/config/theme.config.ts +74 -0
  125. package/docs/01-overview/01-introduction.md +335 -0
  126. package/docs/01-overview/02-customization.md +671 -0
  127. package/docs/02-features/01-components.md +155 -0
  128. package/docs/02-features/02-styling.md +139 -0
  129. package/docs/02-features/03-tasks-entity.md +407 -0
  130. package/docs/03-ai/01-overview.md +211 -0
  131. package/docs/03-ai/02-customization.md +436 -0
  132. package/entities/customers/customers.config.ts +75 -0
  133. package/entities/customers/customers.fields.ts +165 -0
  134. package/entities/customers/customers.service.ts +516 -0
  135. package/entities/customers/customers.types.ts +83 -0
  136. package/entities/customers/messages/en.json +66 -0
  137. package/entities/customers/messages/es.json +66 -0
  138. package/entities/customers/migrations/001_customers_table.sql +102 -0
  139. package/entities/customers/migrations/002_customers_metas.sql +92 -0
  140. package/entities/pages/messages/en.json +41 -0
  141. package/entities/pages/messages/es.json +41 -0
  142. package/entities/pages/migrations/001_pages_table.sql +112 -0
  143. package/entities/pages/migrations/002_pages_metas.sql +56 -0
  144. package/entities/pages/migrations/003_add_status.sql +50 -0
  145. package/entities/pages/pages-management.service.ts +610 -0
  146. package/entities/pages/pages.config.ts +94 -0
  147. package/entities/pages/pages.fields.ts +101 -0
  148. package/entities/pages/pages.service.ts +290 -0
  149. package/entities/pages/pages.types.ts +124 -0
  150. package/entities/posts/components/post-header.tsx +97 -0
  151. package/entities/posts/messages/en.json +55 -0
  152. package/entities/posts/messages/es.json +55 -0
  153. package/entities/posts/migrations/001_posts_table.sql +115 -0
  154. package/entities/posts/migrations/003_add_status.sql +44 -0
  155. package/entities/posts/migrations/004_entity_taxonomy_relations.sql +129 -0
  156. package/entities/posts/migrations/006_posts_metas.sql +56 -0
  157. package/entities/posts/posts.config.ts +101 -0
  158. package/entities/posts/posts.fields.ts +116 -0
  159. package/entities/posts/posts.service.ts +376 -0
  160. package/entities/posts/posts.types.ts +74 -0
  161. package/entities/tasks/messages/en.json +204 -0
  162. package/entities/tasks/messages/es.json +204 -0
  163. package/entities/tasks/migrations/001_tasks_table.sql +105 -0
  164. package/entities/tasks/migrations/002_task_metas.sql +85 -0
  165. package/entities/tasks/migrations/sample_data.json +77 -0
  166. package/entities/tasks/tasks.config.ts +79 -0
  167. package/entities/tasks/tasks.fields.ts +196 -0
  168. package/entities/tasks/tasks.service.ts +541 -0
  169. package/entities/tasks/tasks.types.ts +56 -0
  170. package/lib/hooks/useAiChat.ts +114 -0
  171. package/lib/hooks/useConversations.ts +376 -0
  172. package/lib/hooks/useOrchestratorChat.ts +122 -0
  173. package/lib/hooks/usePersistentChat.ts +315 -0
  174. package/lib/hooks/useStreamingChat.ts +127 -0
  175. package/lib/hooks/useTokenUsage.ts +63 -0
  176. package/lib/langchain/agents/customer-assistant.md +69 -0
  177. package/lib/langchain/agents/index.ts +61 -0
  178. package/lib/langchain/agents/orchestrator.md +59 -0
  179. package/lib/langchain/agents/page-assistant.md +85 -0
  180. package/lib/langchain/agents/single-agent.md +46 -0
  181. package/lib/langchain/agents/task-assistant.md +55 -0
  182. package/lib/langchain/config.ts +45 -0
  183. package/lib/langchain/handlers/customer-handler.ts +338 -0
  184. package/lib/langchain/handlers/page-handler.ts +232 -0
  185. package/lib/langchain/handlers/task-handler.ts +323 -0
  186. package/lib/langchain/langchain.config.ts +223 -0
  187. package/lib/langchain/observability.config.ts +30 -0
  188. package/lib/langchain/orchestrator.ts +562 -0
  189. package/lib/langchain/tools/customers.ts +176 -0
  190. package/lib/langchain/tools/index.ts +10 -0
  191. package/lib/langchain/tools/orchestrator.ts +92 -0
  192. package/lib/langchain/tools/pages.ts +289 -0
  193. package/lib/langchain/tools/tasks.ts +167 -0
  194. package/lib/scheduled-actions/billing.ts +149 -0
  195. package/lib/scheduled-actions/index.ts +170 -0
  196. package/lib/scheduled-actions/webhook.ts +231 -0
  197. package/lib/selectors.ts +197 -0
  198. package/messages/de/admin.json +219 -0
  199. package/messages/de/aiUsage.json +36 -0
  200. package/messages/de/buttons.json +19 -0
  201. package/messages/de/categories.json +35 -0
  202. package/messages/de/common.json +16 -0
  203. package/messages/de/dev.json +101 -0
  204. package/messages/de/docs.json +27 -0
  205. package/messages/de/entities.json +7 -0
  206. package/messages/de/features.json +119 -0
  207. package/messages/de/footer.json +22 -0
  208. package/messages/de/home.json +57 -0
  209. package/messages/de/index.ts +39 -0
  210. package/messages/de/mobileNav.json +13 -0
  211. package/messages/de/navigation.json +8 -0
  212. package/messages/de/observability.json +74 -0
  213. package/messages/de/posts.json +54 -0
  214. package/messages/de/pricing.json +102 -0
  215. package/messages/de/support.json +9 -0
  216. package/messages/de/teams.json +8 -0
  217. package/messages/en/admin.json +219 -0
  218. package/messages/en/aiUsage.json +36 -0
  219. package/messages/en/buttons.json +19 -0
  220. package/messages/en/categories.json +35 -0
  221. package/messages/en/common.json +16 -0
  222. package/messages/en/dev.json +106 -0
  223. package/messages/en/docs.json +27 -0
  224. package/messages/en/entities.json +7 -0
  225. package/messages/en/features.json +119 -0
  226. package/messages/en/footer.json +22 -0
  227. package/messages/en/home.json +57 -0
  228. package/messages/en/index.ts +39 -0
  229. package/messages/en/mobileNav.json +13 -0
  230. package/messages/en/navigation.json +8 -0
  231. package/messages/en/observability.json +74 -0
  232. package/messages/en/posts.json +54 -0
  233. package/messages/en/pricing.json +102 -0
  234. package/messages/en/support.json +9 -0
  235. package/messages/en/teams.json +8 -0
  236. package/messages/es/admin.json +219 -0
  237. package/messages/es/aiUsage.json +36 -0
  238. package/messages/es/buttons.json +19 -0
  239. package/messages/es/categories.json +35 -0
  240. package/messages/es/common.json +16 -0
  241. package/messages/es/dev.json +101 -0
  242. package/messages/es/docs.json +27 -0
  243. package/messages/es/entities.json +7 -0
  244. package/messages/es/features.json +119 -0
  245. package/messages/es/footer.json +22 -0
  246. package/messages/es/home.json +57 -0
  247. package/messages/es/index.ts +39 -0
  248. package/messages/es/mobileNav.json +13 -0
  249. package/messages/es/navigation.json +8 -0
  250. package/messages/es/observability.json +74 -0
  251. package/messages/es/posts.json +54 -0
  252. package/messages/es/pricing.json +102 -0
  253. package/messages/es/support.json +9 -0
  254. package/messages/es/teams.json +8 -0
  255. package/messages/fr/admin.json +219 -0
  256. package/messages/fr/aiUsage.json +36 -0
  257. package/messages/fr/buttons.json +19 -0
  258. package/messages/fr/categories.json +35 -0
  259. package/messages/fr/common.json +16 -0
  260. package/messages/fr/dev.json +101 -0
  261. package/messages/fr/docs.json +27 -0
  262. package/messages/fr/entities.json +7 -0
  263. package/messages/fr/features.json +119 -0
  264. package/messages/fr/footer.json +22 -0
  265. package/messages/fr/home.json +57 -0
  266. package/messages/fr/index.ts +39 -0
  267. package/messages/fr/mobileNav.json +13 -0
  268. package/messages/fr/navigation.json +8 -0
  269. package/messages/fr/observability.json +74 -0
  270. package/messages/fr/posts.json +54 -0
  271. package/messages/fr/pricing.json +102 -0
  272. package/messages/fr/support.json +9 -0
  273. package/messages/fr/teams.json +8 -0
  274. package/messages/it/admin.json +219 -0
  275. package/messages/it/aiUsage.json +36 -0
  276. package/messages/it/buttons.json +19 -0
  277. package/messages/it/categories.json +35 -0
  278. package/messages/it/common.json +16 -0
  279. package/messages/it/dev.json +101 -0
  280. package/messages/it/docs.json +27 -0
  281. package/messages/it/entities.json +7 -0
  282. package/messages/it/features.json +119 -0
  283. package/messages/it/footer.json +22 -0
  284. package/messages/it/home.json +57 -0
  285. package/messages/it/index.ts +39 -0
  286. package/messages/it/mobileNav.json +13 -0
  287. package/messages/it/navigation.json +8 -0
  288. package/messages/it/observability.json +74 -0
  289. package/messages/it/posts.json +54 -0
  290. package/messages/it/pricing.json +102 -0
  291. package/messages/it/support.json +9 -0
  292. package/messages/it/teams.json +8 -0
  293. package/messages/pt/admin.json +219 -0
  294. package/messages/pt/aiUsage.json +36 -0
  295. package/messages/pt/buttons.json +19 -0
  296. package/messages/pt/categories.json +35 -0
  297. package/messages/pt/common.json +16 -0
  298. package/messages/pt/dev.json +101 -0
  299. package/messages/pt/docs.json +27 -0
  300. package/messages/pt/entities.json +7 -0
  301. package/messages/pt/features.json +119 -0
  302. package/messages/pt/footer.json +22 -0
  303. package/messages/pt/home.json +57 -0
  304. package/messages/pt/index.ts +39 -0
  305. package/messages/pt/mobileNav.json +13 -0
  306. package/messages/pt/navigation.json +8 -0
  307. package/messages/pt/observability.json +74 -0
  308. package/messages/pt/posts.json +54 -0
  309. package/messages/pt/pricing.json +102 -0
  310. package/messages/pt/support.json +9 -0
  311. package/messages/pt/teams.json +8 -0
  312. package/migrations/089_add_editor_team_role.sql +39 -0
  313. package/migrations/090_demo_users_teams.sql +540 -0
  314. package/migrations/091_greek_teams_billing.sql +523 -0
  315. package/migrations/092_billing_sample_data.sql +774 -0
  316. package/migrations/093_pages_sample_data.sql +1158 -0
  317. package/migrations/094_posts_sample_data.sql +278 -0
  318. package/migrations/095_tasks_sample_data.sql +440 -0
  319. package/migrations/096_customers_sample_data.sql +358 -0
  320. package/migrations/097_scheduled_actions_sample_data.sql +111 -0
  321. package/package.json +22 -0
  322. package/public/docs/desktop-layout-example.png +0 -0
  323. package/styles/components.css +11 -0
  324. package/styles/globals.css +179 -0
  325. package/templates/(public)/blog/[slug]/page.tsx +65 -0
  326. package/templates/(public)/layout.tsx +25 -0
  327. package/templates/(public)/page.tsx +200 -0
  328. package/templates/(public)/support/page.tsx +321 -0
  329. package/templates/dashboard/(main)/agent-multi/page.tsx +63 -0
  330. package/templates/dashboard/(main)/agent-single/page.tsx +142 -0
  331. package/templates/dashboard/(main)/settings/ai-usage/page.tsx +157 -0
  332. package/templates/superadmin/ai-observability/[traceId]/page.tsx +27 -0
  333. package/templates/superadmin/ai-observability/page.tsx +17 -0
@@ -0,0 +1,278 @@
1
+ -- Migration: 094_posts_sample_data.sql
2
+ -- Description: Sample data for posts and taxonomies (categories)
3
+ -- Date: 2025-12-16
4
+ -- Updated: 2025-12-18 - Added 15 posts with post-content blocks for pagination testing
5
+
6
+ -- ============================================
7
+ -- SAMPLE TAXONOMIES (post_category type)
8
+ -- ============================================
9
+ INSERT INTO public.taxonomies (
10
+ id, type, slug, name, description, icon, color, "order", "isDefault", "isActive"
11
+ ) VALUES
12
+ ('cat-technology', 'post_category', 'technology', 'Technology', 'Posts about technology, software, and development', 'cpu', '#3B82F6', 1, false, true),
13
+ ('cat-tutorials', 'post_category', 'tutorials', 'Tutorials', 'Step-by-step guides and how-to articles', 'book-open', '#10B981', 2, false, true),
14
+ ('cat-news', 'post_category', 'news', 'News', 'Latest news and announcements', 'newspaper', '#F59E0B', 3, true, true),
15
+ ('cat-tips', 'post_category', 'tips-tricks', 'Tips & Tricks', 'Helpful tips and productivity hacks', 'lightbulb', '#8B5CF6', 4, false, true),
16
+ ('cat-design', 'post_category', 'design', 'Design', 'UI/UX and graphic design', 'palette', '#EC4899', 5, false, true),
17
+ ('cat-ai', 'post_category', 'inteligencia-artificial', 'Inteligencia Artificial', 'Posts about AI, machine learning and future technologies', 'brain', '#6366F1', 6, false, true),
18
+ ('cat-saas', 'post_category', 'saas', 'SaaS', 'Software as a Service insights and strategies', 'cloud', '#14B8A6', 7, false, true)
19
+ ON CONFLICT (id) DO NOTHING;
20
+
21
+ -- ============================================
22
+ -- SAMPLE POSTS (15 posts for pagination)
23
+ -- All with post-content block only (no post-hero)
24
+ -- ============================================
25
+ INSERT INTO public.posts (
26
+ id, "userId", "teamId", slug, title, excerpt, "featuredImage", blocks, locale, status
27
+ ) VALUES
28
+ -- Post 1: Welcome to Our Blog
29
+ (
30
+ 'a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d'::UUID,
31
+ 'usr-carlos-001',
32
+ 'team-everpoint-001',
33
+ 'welcome-to-our-blog',
34
+ 'Welcome to Our Blog',
35
+ 'Discover the latest insights, tutorials, and news from our team.',
36
+ 'https://images.unsplash.com/photo-1499750310107-5fef28a66643?w=800',
37
+ '[{"id":"content-1","blockSlug":"post-content","props":{"content":"<h2>Welcome to Everpoint Labs Blog</h2><p>We are excited to launch our new blog where we will share insights about technology, AI, and SaaS development. Stay tuned for regular updates!</p><p>Our team of experts will cover topics ranging from <strong>artificial intelligence</strong> to <strong>software architecture</strong> and everything in between.</p><h2>What to Expect</h2><ul><li>In-depth tutorials and guides</li><li>Industry news and analysis</li><li>Best practices and tips</li><li>Case studies from real projects</li></ul><p>Subscribe to our newsletter to never miss an update!</p>"}}]'::JSONB,
38
+ 'en',
39
+ 'published'
40
+ ),
41
+ -- Post 2: Getting Started with Next.js 15
42
+ (
43
+ 'b2c3d4e5-f6a7-5b6c-9d0e-1f2a3b4c5d6e'::UUID,
44
+ 'usr-carlos-001',
45
+ 'team-everpoint-001',
46
+ 'getting-started-with-nextjs',
47
+ 'Getting Started with Next.js 15',
48
+ 'Learn the fundamentals of Next.js 15 and build your first application.',
49
+ 'https://images.unsplash.com/photo-1555066931-4365d14bab8c?w=800',
50
+ '[{"id":"content-2","blockSlug":"post-content","props":{"content":"<h2>Introduction to Next.js 15</h2><p>Next.js 15 brings exciting new features including improved performance, better developer experience, and enhanced server components.</p><h2>Key Features</h2><ul><li><strong>Turbopack</strong>: Lightning-fast bundler for development</li><li><strong>Server Actions</strong>: Simplified data mutations</li><li><strong>Partial Prerendering</strong>: Best of static and dynamic</li></ul><h2>Getting Started</h2><p>To create a new Next.js 15 project, run:</p><pre><code>npx create-next-app@latest my-app</code></pre><p>This will scaffold a new project with all the latest features enabled by default.</p>"}}]'::JSONB,
51
+ 'en',
52
+ 'published'
53
+ ),
54
+ -- Post 3: TypeScript Best Practices
55
+ (
56
+ 'c3d4e5f6-a7b8-6c7d-0e1f-2a3b4c5d6e7f'::UUID,
57
+ 'usr-carlos-001',
58
+ 'team-everpoint-001',
59
+ 'typescript-best-practices',
60
+ 'TypeScript Best Practices in 2025',
61
+ 'Master TypeScript with these proven patterns and practices.',
62
+ 'https://images.unsplash.com/photo-1516116216624-53e697fedbea?w=800',
63
+ '[{"id":"content-3","blockSlug":"post-content","props":{"content":"<h2>TypeScript Best Practices</h2><p>TypeScript has become the standard for large-scale JavaScript applications. Here are the best practices for 2025.</p><h2>1. Use Strict Mode</h2><p>Always enable strict mode in your tsconfig.json:</p><pre><code>{\"compilerOptions\": {\"strict\": true}}</code></pre><h2>2. Prefer Interfaces Over Types</h2><p>Use interfaces for object shapes and types for unions and primitives.</p><h2>3. Avoid Any</h2><p>The <code>any</code> type defeats the purpose of TypeScript. Use <code>unknown</code> when the type is truly unknown.</p>"}}]'::JSONB,
64
+ 'en',
65
+ 'draft'
66
+ ),
67
+ -- Post 4: El Futuro de la IA
68
+ (
69
+ 'f82415da-56e9-4c15-a960-0a62a01b2274'::UUID,
70
+ 'usr-carlos-001',
71
+ 'team-everpoint-001',
72
+ 'futuro-inteligencia-artificial-2025',
73
+ 'El Futuro de la Inteligencia Artificial: Tendencias 2025',
74
+ 'Exploramos las tendencias más disruptivas en inteligencia artificial.',
75
+ 'https://images.unsplash.com/photo-1677442136019-21780ecad995?w=800',
76
+ '[{"id":"content-4","blockSlug":"post-content","props":{"content":"<h2>La Revolución de los Modelos Multimodales</h2><p>Los modelos de lenguaje han evolucionado más allá del texto. En 2025, los sistemas multimodales como GPT-4o y Claude pueden procesar imágenes, audio y video de manera nativa.</p><h2>Agentes Autónomos: El Próximo Salto</h2><p>Quizás la tendencia más transformadora es el surgimiento de <strong>agentes de IA autónomos</strong>. Estos agentes pueden:</p><ul><li>Planificar y ejecutar tareas complejas</li><li>Interactuar con APIs y herramientas externas</li><li>Tomar decisiones basadas en contexto</li></ul><blockquote><p>La IA no reemplazará a los programadores, pero los programadores que usen IA reemplazarán a los que no lo hagan.</p></blockquote>"}}]'::JSONB,
77
+ 'en',
78
+ 'published'
79
+ ),
80
+ -- Post 5: Building SaaS Products with AI
81
+ (
82
+ 'd4e5f6a7-b8c9-4d0e-9f1a-2b3c4d5e6f70'::UUID,
83
+ 'usr-carlos-001',
84
+ 'team-everpoint-001',
85
+ 'building-saas-products-with-ai',
86
+ 'Building SaaS Products with AI Integration',
87
+ 'How to leverage AI to create competitive SaaS products in 2025.',
88
+ 'https://images.unsplash.com/photo-1551288049-bebda4e38f71?w=800',
89
+ '[{"id":"content-5","blockSlug":"post-content","props":{"content":"<h2>AI-Powered SaaS: The New Standard</h2><p>In 2025, SaaS products without AI capabilities are at a significant disadvantage. Users expect intelligent features that save time and provide insights.</p><h2>Key AI Features for SaaS</h2><ul><li><strong>Smart Search</strong>: Semantic search that understands intent</li><li><strong>Automated Workflows</strong>: AI-triggered actions based on patterns</li><li><strong>Predictive Analytics</strong>: Forecasting based on historical data</li><li><strong>Natural Language Interfaces</strong>: Chat-based interactions</li></ul><h2>Implementation Strategy</h2><p>Start with high-impact, low-complexity features. Use APIs from providers like OpenAI, Anthropic, or open-source models.</p>"}}]'::JSONB,
90
+ 'en',
91
+ 'published'
92
+ ),
93
+ -- Post 6: Microservices vs Monolith
94
+ (
95
+ 'e5f6a7b8-c9d0-4e1f-a2b3-c4d5e6f7a8b9'::UUID,
96
+ 'usr-carlos-001',
97
+ 'team-everpoint-001',
98
+ 'microservices-vs-monolith-2025',
99
+ 'Microservices vs Monolith: What to Choose in 2025',
100
+ 'A practical guide to choosing the right architecture for your project.',
101
+ 'https://images.unsplash.com/photo-1558494949-ef010cbdcc31?w=800',
102
+ '[{"id":"content-6","blockSlug":"post-content","props":{"content":"<h2>The Architecture Debate Continues</h2><p>The microservices vs monolith debate has evolved. In 2025, the answer is nuanced: it depends on your team size, scale, and complexity.</p><h2>When to Choose Monolith</h2><ul><li>Small teams (< 10 developers)</li><li>Early-stage startups</li><li>Simple domain logic</li><li>Need for rapid iteration</li></ul><h2>When to Choose Microservices</h2><ul><li>Large teams with clear domain boundaries</li><li>Need for independent scaling</li><li>Multiple programming languages required</li><li>Complex, evolving domains</li></ul><h2>The Middle Ground: Modular Monolith</h2><p>Consider starting with a modular monolith that can be split later if needed.</p>"}}]'::JSONB,
103
+ 'en',
104
+ 'published'
105
+ ),
106
+ -- Post 7: Claude API Deep Dive
107
+ (
108
+ 'f6a7b8c9-d0e1-4f2a-b3c4-d5e6f7a8b9c0'::UUID,
109
+ 'usr-carlos-001',
110
+ 'team-everpoint-001',
111
+ 'claude-api-deep-dive',
112
+ 'Claude API Deep Dive: Building Intelligent Applications',
113
+ 'Everything you need to know about integrating Claude into your applications.',
114
+ 'https://images.unsplash.com/photo-1620712943543-bcc4688e7485?w=800',
115
+ '[{"id":"content-7","blockSlug":"post-content","props":{"content":"<h2>Introduction to Claude API</h2><p>Claude by Anthropic is one of the most capable AI assistants available. This guide covers everything from basic integration to advanced techniques.</p><h2>Getting Started</h2><pre><code>npm install @anthropic-ai/sdk</code></pre><h2>Basic Usage</h2><p>The Messages API is the primary way to interact with Claude:</p><pre><code>const response = await anthropic.messages.create({\n model: \"claude-sonnet-4-20250514\",\n max_tokens: 1024,\n messages: [{role: \"user\", content: \"Hello!\"}]\n});</code></pre><h2>Best Practices</h2><ul><li>Use system prompts for consistent behavior</li><li>Implement streaming for better UX</li><li>Handle rate limits gracefully</li></ul>"}}]'::JSONB,
116
+ 'en',
117
+ 'published'
118
+ ),
119
+ -- Post 8: SaaS Pricing Strategies
120
+ (
121
+ 'a7b8c9d0-e1f2-4a3b-c4d5-e6f7a8b9c0d1'::UUID,
122
+ 'usr-carlos-001',
123
+ 'team-everpoint-001',
124
+ 'saas-pricing-strategies-2025',
125
+ 'SaaS Pricing Strategies That Work in 2025',
126
+ 'Learn how to price your SaaS product for maximum growth and retention.',
127
+ 'https://images.unsplash.com/photo-1554224155-6726b3ff858f?w=800',
128
+ '[{"id":"content-8","blockSlug":"post-content","props":{"content":"<h2>The Art of SaaS Pricing</h2><p>Pricing is one of the most important decisions for a SaaS business. Get it wrong, and you leave money on the table or lose customers.</p><h2>Popular Pricing Models</h2><ul><li><strong>Per-seat</strong>: Scales with team size</li><li><strong>Usage-based</strong>: Pay for what you use</li><li><strong>Tiered</strong>: Good-better-best packages</li><li><strong>Hybrid</strong>: Combination of models</li></ul><h2>AI-Era Considerations</h2><p>With AI features, usage-based pricing is becoming more common due to the variable costs of API calls.</p><blockquote><p>Price based on value delivered, not cost incurred.</p></blockquote>"}}]'::JSONB,
129
+ 'en',
130
+ 'published'
131
+ ),
132
+ -- Post 9: React Server Components
133
+ (
134
+ 'b8c9d0e1-f2a3-4b4c-d5e6-f7a8b9c0d1e2'::UUID,
135
+ 'usr-carlos-001',
136
+ 'team-everpoint-001',
137
+ 'react-server-components-explained',
138
+ 'React Server Components Explained',
139
+ 'Understanding the paradigm shift in React development.',
140
+ 'https://images.unsplash.com/photo-1633356122544-f134324a6cee?w=800',
141
+ '[{"id":"content-9","blockSlug":"post-content","props":{"content":"<h2>What Are Server Components?</h2><p>React Server Components (RSC) represent a fundamental shift in how we build React applications. They run on the server and send only the rendered output to the client.</p><h2>Benefits</h2><ul><li><strong>Smaller bundles</strong>: Server-only code never reaches the client</li><li><strong>Direct backend access</strong>: Query databases without APIs</li><li><strong>Better performance</strong>: Less JavaScript to parse and execute</li></ul><h2>When to Use Client Components</h2><p>Use the \"use client\" directive when you need:</p><ul><li>Event handlers (onClick, onChange)</li><li>Browser APIs (localStorage, window)</li><li>React hooks (useState, useEffect)</li></ul>"}}]'::JSONB,
142
+ 'en',
143
+ 'published'
144
+ ),
145
+ -- Post 10: Database Design for SaaS
146
+ (
147
+ 'c9d0e1f2-a3b4-4c5d-e6f7-a8b9c0d1e2f3'::UUID,
148
+ 'usr-carlos-001',
149
+ 'team-everpoint-001',
150
+ 'database-design-multi-tenant-saas',
151
+ 'Database Design for Multi-Tenant SaaS',
152
+ 'Best practices for designing scalable multi-tenant databases.',
153
+ 'https://images.unsplash.com/photo-1544383835-bda2bc66a55d?w=800',
154
+ '[{"id":"content-10","blockSlug":"post-content","props":{"content":"<h2>Multi-Tenancy Approaches</h2><p>Choosing the right multi-tenancy strategy is crucial for SaaS applications. Here are the main approaches:</p><h2>1. Shared Database, Shared Schema</h2><p>All tenants share tables with a tenant_id column. Simple but requires careful RLS policies.</p><h2>2. Shared Database, Separate Schemas</h2><p>Each tenant gets their own schema. Better isolation but more complex migrations.</p><h2>3. Separate Databases</h2><p>Complete isolation but highest operational overhead.</p><h2>Row-Level Security</h2><p>PostgreSQL RLS is essential for shared schema approaches:</p><pre><code>CREATE POLICY tenant_isolation ON items\n USING (tenant_id = current_setting(''app.tenant_id''));</code></pre>"}}]'::JSONB,
155
+ 'en',
156
+ 'published'
157
+ ),
158
+ -- Post 11: AI Agents Architecture
159
+ (
160
+ 'd0e1f2a3-b4c5-4d6e-f7a8-b9c0d1e2f3a4'::UUID,
161
+ 'usr-carlos-001',
162
+ 'team-everpoint-001',
163
+ 'ai-agents-architecture-patterns',
164
+ 'AI Agents Architecture: Design Patterns for 2025',
165
+ 'How to design and build reliable AI agent systems.',
166
+ 'https://images.unsplash.com/photo-1485827404703-89b55fcc595e?w=800',
167
+ '[{"id":"content-11","blockSlug":"post-content","props":{"content":"<h2>The Rise of AI Agents</h2><p>AI agents are autonomous systems that can plan, reason, and execute tasks. Building reliable agents requires careful architecture.</p><h2>Core Components</h2><ul><li><strong>Planner</strong>: Breaks down goals into steps</li><li><strong>Executor</strong>: Runs individual actions</li><li><strong>Memory</strong>: Stores context and history</li><li><strong>Tools</strong>: External capabilities (APIs, code execution)</li></ul><h2>Design Patterns</h2><h3>ReAct Pattern</h3><p>Interleave reasoning and action: Think → Act → Observe → Repeat</p><h3>Plan-and-Execute</h3><p>Create full plan first, then execute sequentially.</p>"}}]'::JSONB,
168
+ 'en',
169
+ 'published'
170
+ ),
171
+ -- Post 12: Authentication Best Practices
172
+ (
173
+ 'e1f2a3b4-c5d6-4e7f-a8b9-c0d1e2f3a4b5'::UUID,
174
+ 'usr-carlos-001',
175
+ 'team-everpoint-001',
176
+ 'authentication-best-practices-2025',
177
+ 'Authentication Best Practices for Modern Web Apps',
178
+ 'Secure your applications with these proven authentication strategies.',
179
+ 'https://images.unsplash.com/photo-1555949963-aa79dcee981c?w=800',
180
+ '[{"id":"content-12","blockSlug":"post-content","props":{"content":"<h2>Authentication in 2025</h2><p>Security threats evolve constantly. Here are the current best practices for authentication.</p><h2>Key Recommendations</h2><ul><li><strong>Use established libraries</strong>: Better Auth, Auth.js, Clerk</li><li><strong>Implement MFA</strong>: SMS is weak, use TOTP or passkeys</li><li><strong>Secure sessions</strong>: HttpOnly cookies, short expiration</li><li><strong>Rate limiting</strong>: Prevent brute force attacks</li></ul><h2>Passkeys: The Future</h2><p>Passkeys eliminate passwords entirely using public-key cryptography. They are phishing-resistant and more user-friendly.</p>"}}]'::JSONB,
181
+ 'en',
182
+ 'published'
183
+ ),
184
+ -- Post 13: Prompt Engineering
185
+ (
186
+ 'f2a3b4c5-d6e7-4f8a-b9c0-d1e2f3a4b5c6'::UUID,
187
+ 'usr-carlos-001',
188
+ 'team-everpoint-001',
189
+ 'prompt-engineering-advanced-techniques',
190
+ 'Advanced Prompt Engineering Techniques',
191
+ 'Master the art of crafting effective prompts for AI models.',
192
+ 'https://images.unsplash.com/photo-1676299081847-824916de030a?w=800',
193
+ '[{"id":"content-13","blockSlug":"post-content","props":{"content":"<h2>Beyond Basic Prompting</h2><p>Effective prompt engineering can dramatically improve AI output quality. Here are advanced techniques.</p><h2>Techniques</h2><h3>Chain of Thought</h3><p>Ask the model to think step by step before answering.</p><h3>Few-Shot Learning</h3><p>Provide examples of desired input-output pairs.</p><h3>Role Prompting</h3><p>Assign a specific persona or expertise to the model.</p><h2>System Prompts</h2><p>Use system prompts to establish consistent behavior:</p><pre><code>You are an expert software architect. Always consider scalability, security, and maintainability in your recommendations.</code></pre>"}}]'::JSONB,
194
+ 'en',
195
+ 'published'
196
+ ),
197
+ -- Post 14: Monitoring SaaS Applications
198
+ (
199
+ 'a3b4c5d6-e7f8-4a9b-c0d1-e2f3a4b5c6d7'::UUID,
200
+ 'usr-carlos-001',
201
+ 'team-everpoint-001',
202
+ 'monitoring-saas-applications',
203
+ 'Monitoring SaaS Applications: A Complete Guide',
204
+ 'Set up comprehensive monitoring for your SaaS product.',
205
+ 'https://images.unsplash.com/photo-1551288049-bebda4e38f71?w=800',
206
+ '[{"id":"content-14","blockSlug":"post-content","props":{"content":"<h2>Why Monitoring Matters</h2><p>In SaaS, downtime directly impacts revenue and customer trust. Comprehensive monitoring is essential.</p><h2>The Four Golden Signals</h2><ul><li><strong>Latency</strong>: Time to serve requests</li><li><strong>Traffic</strong>: Request volume</li><li><strong>Errors</strong>: Rate of failed requests</li><li><strong>Saturation</strong>: Resource utilization</li></ul><h2>Recommended Stack</h2><ul><li><strong>Metrics</strong>: Prometheus + Grafana</li><li><strong>Logs</strong>: Loki or DataDog</li><li><strong>Traces</strong>: OpenTelemetry</li><li><strong>Alerts</strong>: PagerDuty or OpsGenie</li></ul>"}}]'::JSONB,
207
+ 'en',
208
+ 'published'
209
+ ),
210
+ -- Post 15: Future of SaaS in AI Era
211
+ (
212
+ 'b4c5d6e7-f8a9-4b0c-d1e2-f3a4b5c6d7e8'::UUID,
213
+ 'usr-carlos-001',
214
+ 'team-everpoint-001',
215
+ 'future-of-saas-ai-era',
216
+ 'The Future of SaaS in the AI Era',
217
+ 'How AI is reshaping the SaaS landscape and what it means for founders.',
218
+ 'https://images.unsplash.com/photo-1451187580459-43490279c0fa?w=800',
219
+ '[{"id":"content-15","blockSlug":"post-content","props":{"content":"<h2>SaaS is Evolving</h2><p>The traditional SaaS model is being disrupted by AI. Products that once required dozens of features can now be replaced by a well-prompted AI agent.</p><h2>Emerging Trends</h2><ul><li><strong>AI-Native Products</strong>: Built around AI from day one</li><li><strong>Vertical AI</strong>: Deep expertise in specific domains</li><li><strong>Agent Marketplaces</strong>: Ecosystems of specialized AI agents</li><li><strong>Usage-Based Pricing</strong>: Pay per AI operation</li></ul><h2>Opportunities for Founders</h2><p>The barrier to entry has lowered, but the bar for quality has risen. Success requires:</p><ul><li>Deep domain expertise</li><li>Excellent user experience</li><li>Reliable, fast AI infrastructure</li></ul><blockquote><p>The next unicorns will be AI-native SaaS companies built by small teams.</p></blockquote>"}}]'::JSONB,
220
+ 'en',
221
+ 'published'
222
+ )
223
+ ON CONFLICT (id) DO UPDATE SET
224
+ blocks = EXCLUDED.blocks,
225
+ excerpt = EXCLUDED.excerpt,
226
+ "featuredImage" = EXCLUDED."featuredImage";
227
+
228
+ -- ============================================
229
+ -- SAMPLE POST-TAXONOMY RELATIONS
230
+ -- Using generic entity_taxonomy_relations table
231
+ -- ============================================
232
+ INSERT INTO public.entity_taxonomy_relations ("entityType", "entityId", "taxonomyId", "order")
233
+ VALUES
234
+ -- Post 1: Welcome
235
+ ('posts', 'a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d', 'cat-news', 1),
236
+ -- Post 2: Next.js
237
+ ('posts', 'b2c3d4e5-f6a7-5b6c-9d0e-1f2a3b4c5d6e', 'cat-tutorials', 1),
238
+ ('posts', 'b2c3d4e5-f6a7-5b6c-9d0e-1f2a3b4c5d6e', 'cat-technology', 2),
239
+ -- Post 3: TypeScript
240
+ ('posts', 'c3d4e5f6-a7b8-6c7d-0e1f-2a3b4c5d6e7f', 'cat-technology', 1),
241
+ ('posts', 'c3d4e5f6-a7b8-6c7d-0e1f-2a3b4c5d6e7f', 'cat-tips', 2),
242
+ -- Post 4: AI Future
243
+ ('posts', 'f82415da-56e9-4c15-a960-0a62a01b2274', 'cat-ai', 1),
244
+ ('posts', 'f82415da-56e9-4c15-a960-0a62a01b2274', 'cat-technology', 2),
245
+ -- Post 5: SaaS + AI
246
+ ('posts', 'd4e5f6a7-b8c9-4d0e-9f1a-2b3c4d5e6f70', 'cat-saas', 1),
247
+ ('posts', 'd4e5f6a7-b8c9-4d0e-9f1a-2b3c4d5e6f70', 'cat-ai', 2),
248
+ -- Post 6: Architecture
249
+ ('posts', 'e5f6a7b8-c9d0-4e1f-a2b3-c4d5e6f7a8b9', 'cat-technology', 1),
250
+ ('posts', 'e5f6a7b8-c9d0-4e1f-a2b3-c4d5e6f7a8b9', 'cat-tips', 2),
251
+ -- Post 7: Claude API
252
+ ('posts', 'f6a7b8c9-d0e1-4f2a-b3c4-d5e6f7a8b9c0', 'cat-ai', 1),
253
+ ('posts', 'f6a7b8c9-d0e1-4f2a-b3c4-d5e6f7a8b9c0', 'cat-tutorials', 2),
254
+ -- Post 8: SaaS Pricing
255
+ ('posts', 'a7b8c9d0-e1f2-4a3b-c4d5-e6f7a8b9c0d1', 'cat-saas', 1),
256
+ ('posts', 'a7b8c9d0-e1f2-4a3b-c4d5-e6f7a8b9c0d1', 'cat-tips', 2),
257
+ -- Post 9: RSC
258
+ ('posts', 'b8c9d0e1-f2a3-4b4c-d5e6-f7a8b9c0d1e2', 'cat-technology', 1),
259
+ ('posts', 'b8c9d0e1-f2a3-4b4c-d5e6-f7a8b9c0d1e2', 'cat-tutorials', 2),
260
+ -- Post 10: Database
261
+ ('posts', 'c9d0e1f2-a3b4-4c5d-e6f7-a8b9c0d1e2f3', 'cat-saas', 1),
262
+ ('posts', 'c9d0e1f2-a3b4-4c5d-e6f7-a8b9c0d1e2f3', 'cat-technology', 2),
263
+ -- Post 11: AI Agents
264
+ ('posts', 'd0e1f2a3-b4c5-4d6e-f7a8-b9c0d1e2f3a4', 'cat-ai', 1),
265
+ ('posts', 'd0e1f2a3-b4c5-4d6e-f7a8-b9c0d1e2f3a4', 'cat-technology', 2),
266
+ -- Post 12: Auth
267
+ ('posts', 'e1f2a3b4-c5d6-4e7f-a8b9-c0d1e2f3a4b5', 'cat-technology', 1),
268
+ ('posts', 'e1f2a3b4-c5d6-4e7f-a8b9-c0d1e2f3a4b5', 'cat-tips', 2),
269
+ -- Post 13: Prompt Engineering
270
+ ('posts', 'f2a3b4c5-d6e7-4f8a-b9c0-d1e2f3a4b5c6', 'cat-ai', 1),
271
+ ('posts', 'f2a3b4c5-d6e7-4f8a-b9c0-d1e2f3a4b5c6', 'cat-tutorials', 2),
272
+ -- Post 14: Monitoring
273
+ ('posts', 'a3b4c5d6-e7f8-4a9b-c0d1-e2f3a4b5c6d7', 'cat-saas', 1),
274
+ ('posts', 'a3b4c5d6-e7f8-4a9b-c0d1-e2f3a4b5c6d7', 'cat-technology', 2),
275
+ -- Post 15: Future SaaS
276
+ ('posts', 'b4c5d6e7-f8a9-4b0c-d1e2-f3a4b5c6d7e8', 'cat-saas', 1),
277
+ ('posts', 'b4c5d6e7-f8a9-4b0c-d1e2-f3a4b5c6d7e8', 'cat-ai', 2)
278
+ ON CONFLICT ("entityType", "entityId", "taxonomyId") DO NOTHING;