@nextblock-cms/db 0.2.26 → 0.2.28

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 (86) hide show
  1. package/package.json +1 -1
  2. package/supabase/config.toml +1 -1
  3. package/supabase/migrations/00000000000014_seed_homepage_blocks.sql +23 -10
  4. package/supabase/migrations/20250513194738_setup_roles_and_profiles.sql +0 -41
  5. package/supabase/migrations/20250513194910_auto_create_profile_trigger.sql +0 -48
  6. package/supabase/migrations/20250513194916_rls_for_profiles.sql +0 -85
  7. package/supabase/migrations/20250514125634_fix_recursive_rls_policies.sql +0 -51
  8. package/supabase/migrations/20250514143016_setup_languages_table.sql +0 -66
  9. package/supabase/migrations/20250514171549_create_pages_table.sql +0 -73
  10. package/supabase/migrations/20250514171550_create_posts_table.sql +0 -61
  11. package/supabase/migrations/20250514171552_create_media_table.sql +0 -45
  12. package/supabase/migrations/20250514171553_create_blocks_table.sql +0 -54
  13. package/supabase/migrations/20250514171615_create_navigation_table.sql +0 -56
  14. package/supabase/migrations/20250514171627_rls_policies_for_content_tables.sql +0 -70
  15. package/supabase/migrations/20250515194800_add_translation_group_id.sql +0 -39
  16. package/supabase/migrations/20250520171900_add_translation_group_to_nav_items.sql +0 -21
  17. package/supabase/migrations/20250521143933_seed_homepage_and_nav.sql +0 -52
  18. package/supabase/migrations/20250523145833_add_feature_image_to_posts.sql +0 -8
  19. package/supabase/migrations/20250523151737_add_rls_to_media_table.sql +0 -18
  20. package/supabase/migrations/20250526110400_add_image_dimensions_to_media.sql +0 -14
  21. package/supabase/migrations/20250526153321_optimize_rls_policies.sql +0 -188
  22. package/supabase/migrations/20250526172513_resolve_select_policy_overlaps.sql +0 -96
  23. package/supabase/migrations/20250526172853_resolve_remaining_rls_v5.sql +0 -107
  24. package/supabase/migrations/20250526173538_finalize_rls_cleanup_v7.sql +0 -110
  25. package/supabase/migrations/20250526174710_separate_write_policies_v8.sql +0 -147
  26. package/supabase/migrations/20250526175359_fix_languages_select_rls_v9.sql +0 -81
  27. package/supabase/migrations/20250526182940_fix_nav_read_policy_v10.sql +0 -27
  28. package/supabase/migrations/20250526183239_fix_posts_read_rls_v11.sql +0 -59
  29. package/supabase/migrations/20250526183746_fix_media_select_rls_v12.sql +0 -39
  30. package/supabase/migrations/20250526184205_consolidate_content_read_rls_v13.sql +0 -61
  31. package/supabase/migrations/20250526185854_optimize_indexes.sql +0 -47
  32. package/supabase/migrations/20250526190900_debug_blocks_rls.sql +0 -56
  33. package/supabase/migrations/20250526191217_consolidate_blocks_select_rls.sql +0 -79
  34. package/supabase/migrations/20250526192822_fix_handle_languages_update_search_path.sql +0 -32
  35. package/supabase/migrations/20250527150500_fix_blocks_rls_policy.sql +0 -54
  36. package/supabase/migrations/20250602150602_add_blur_data_url_to_media.sql +0 -4
  37. package/supabase/migrations/20250602150959_add_variants_to_media.sql +0 -4
  38. package/supabase/migrations/20250618124000_create_get_my_claim_function.sql +0 -5
  39. package/supabase/migrations/20250618124100_create_logos_table.sql +0 -29
  40. package/supabase/migrations/20250618130000_fix_linter_warnings.sql +0 -58
  41. package/supabase/migrations/20250618151500_revert_storage_rls.sql +0 -6
  42. package/supabase/migrations/20250619084800_reinstate_storage_rls.sql +0 -13
  43. package/supabase/migrations/20250619092430_widen_logo_insert_policy.sql +0 -6
  44. package/supabase/migrations/20250619093122_fix_get_my_claim_volatility.sql +0 -5
  45. package/supabase/migrations/20250619104249_consolidated_logo_rls_fix.sql +0 -56
  46. package/supabase/migrations/20250619110700_fix_logo_rls_again.sql +0 -59
  47. package/supabase/migrations/20250619113200_add_file_path_to_media.sql +0 -4
  48. package/supabase/migrations/20250619124100_fix_rls_performance_warnings.sql +0 -74
  49. package/supabase/migrations/20250619195500_create_site_settings_table.sql +0 -28
  50. package/supabase/migrations/20250619201500_add_anon_read_to_site_settings.sql +0 -7
  51. package/supabase/migrations/20250619202000_add_is_active_to_languages.sql +0 -5
  52. package/supabase/migrations/20250620085700_fix_site_settings_write_rls.sql +0 -27
  53. package/supabase/migrations/20250620095500_fix_profiles_read_rls.sql +0 -11
  54. package/supabase/migrations/20250620100000_use_security_definer_for_rls.sql +0 -39
  55. package/supabase/migrations/20250620130000_add_public_read_to_logos.sql +0 -4
  56. package/supabase/migrations/20250708091700_create_translations_table.sql +0 -55
  57. package/supabase/migrations/20250708093403_seed_translations_table.sql +0 -20
  58. package/supabase/migrations/20250708110600_fix_translations_rls_policies.sql +0 -11
  59. package/supabase/migrations/20250708112300_add_new_translations.sql +0 -9
  60. package/supabase/migrations/20250709120000_create_revisions_tables.sql +0 -109
  61. package/supabase/migrations/20251001113000_add_folder_to_media.sql +0 -14
  62. package/supabase/migrations/20251112113736_fix_search_path_functions.sql +0 -74
  63. package/supabase/migrations/20251112124444_fix_rls_performance.sql +0 -63
  64. package/supabase/migrations/20251112125935_fix_combined_policies.sql +0 -194
  65. package/supabase/migrations/20251112132146_fix_foreign_key_indexes.sql +0 -21
  66. package/supabase/migrations/20251112132525_cleanup_unused_indexes.sql +0 -10
  67. package/supabase/migrations/20251112132822_fix_final_indexes.sql +0 -14
  68. package/supabase/migrations/20251112140000_scaffold_foundational_content.sql +0 -108
  69. package/supabase/migrations/20251112141000_seed_homepage_blocks.sql +0 -653
  70. package/supabase/migrations/20251112142000_seed_how_it_works_post_blocks.sql +0 -100
  71. package/supabase/migrations/20251112143000_seed_additional_translations.sql +0 -102
  72. package/supabase/migrations/20251112145000_grant_public_schema_usage.sql +0 -6
  73. package/supabase/migrations/20251112145500_grant_select_on_public_tables.sql +0 -19
  74. package/supabase/migrations/20251117093000_add_admin_created_flag.sql +0 -21
  75. package/supabase/migrations/20251117103000_relax_profile_username_constraint.sql +0 -6
  76. package/supabase/migrations/20251117110000_relax_profiles_site_settings_rls_for_signup.sql +0 -20
  77. package/supabase/migrations/20251117112000_fix_handle_new_user_role_enum.sql +0 -45
  78. package/supabase/migrations/20251117113000_cleanup_rls_duplicates.sql +0 -20
  79. package/supabase/migrations/20251117200000_media_service_role_insert.sql +0 -14
  80. package/supabase/migrations/20251117201500_media_service_role_select.sql +0 -11
  81. package/supabase/migrations/20251117203000_media_admin_writer_select.sql +0 -11
  82. package/supabase/migrations/20251117204500_fix_media_permissions.sql +0 -43
  83. package/supabase/migrations/20251126100000_seed_site_logo.sql +0 -33
  84. package/supabase/migrations/20251126133000_fix_blocks_rls.sql +0 -49
  85. package/supabase/migrations/20251127110000_fix_blocks_visibility_for_missing_profiles.sql +0 -23
  86. package/supabase/migrations/20251127120000_fix_duplicate_rls_policies.sql +0 -36
@@ -1,653 +0,0 @@
1
- -- supabase/migrations/20251112141000_seed_homepage_blocks.sql
2
- -- Populates the English Home page with structured blocks sourced from the landing page brief.
3
-
4
- DO $seed$
5
- DECLARE
6
- v_en_lang_id BIGINT;
7
- v_home_page_id BIGINT;
8
- v_blog_page_id BIGINT;
9
- BEGIN
10
- SELECT id INTO v_en_lang_id
11
- FROM public.languages
12
- WHERE code = 'en'
13
- LIMIT 1;
14
-
15
- IF v_en_lang_id IS NULL THEN
16
- RAISE EXCEPTION 'English language (code = en) not found. Run the language seed migration first.';
17
- END IF;
18
-
19
- SELECT id INTO v_home_page_id
20
- FROM public.pages
21
- WHERE slug = 'home'
22
- AND language_id = v_en_lang_id
23
- ORDER BY created_at DESC
24
- LIMIT 1;
25
-
26
- IF v_home_page_id IS NULL THEN
27
- RAISE EXCEPTION 'Published English Home page not found. Run the page/post seed migration first.';
28
- END IF;
29
-
30
- SELECT id INTO v_blog_page_id
31
- FROM public.pages
32
- WHERE slug = 'articles'
33
- AND language_id = v_en_lang_id
34
- ORDER BY created_at DESC
35
- LIMIT 1;
36
-
37
- IF v_blog_page_id IS NULL THEN
38
- RAISE EXCEPTION 'Published English Articles page not found. Run the page/post seed migration first.';
39
- END IF;
40
-
41
- DELETE FROM public.blocks
42
- WHERE page_id = v_home_page_id;
43
-
44
- DELETE FROM public.blocks
45
- WHERE page_id = v_blog_page_id;
46
-
47
- INSERT INTO public.blocks (page_id, language_id, block_type, content, "order")
48
- VALUES
49
- (
50
- v_home_page_id,
51
- v_en_lang_id,
52
- 'hero',
53
- $${
54
- "container_type": "container",
55
- "background": {
56
- "type": "gradient",
57
- "gradient": {
58
- "type": "linear",
59
- "direction": "135deg",
60
- "stops": [
61
- { "color": "#020817", "position": 0 },
62
- { "color": "#0f172a", "position": 50 },
63
- { "color": "#1e293b", "position": 100 }
64
- ]
65
- }
66
- },
67
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 2 },
68
- "column_gap": "xl",
69
- "vertical_alignment": "center",
70
- "padding": { "top": "xl", "bottom": "xl" },
71
- "column_blocks": [
72
- [
73
- {
74
- "block_type": "text",
75
- "content": {
76
- "html_content": "<h1 class='text-5xl md:text-6xl font-extrabold tracking-tight text-white text-center leading-tight'>Build <span class='relative inline-block mx-1 group'><span class='absolute inset-0 bg-gradient-to-r from-blue-600 to-cyan-400 translate-y-1 md:translate-y-2 transform -skew-x-12 rounded-sm shadow-lg group-hover:skew-x-0 transition-transform duration-300 ease-out'></span><span class='relative text-white italic px-1'>Blazing-Fast</span></span><br class='md:hidden' /> Websites.</h1>"
77
- }
78
- },
79
- {
80
- "block_type": "text",
81
- "content": {
82
- "html_content": "<p class='text-xl text-slate-300 text-center max-w-3xl mx-auto mt-4 leading-relaxed'>NextBlock is the open-source, developer-first Next.js CMS that merges 100% Lighthouse scores with a powerful visual block editor.</p>"
83
- }
84
- },
85
- {
86
- "block_type": "button",
87
- "content": {
88
- "text": "Get Started",
89
- "url": "/article/how-nextblock-works",
90
- "variant": "default",
91
- "size": "lg"
92
- }
93
- },
94
- {
95
- "block_type": "button",
96
- "content": {
97
- "text": "View on GitHub",
98
- "url": "https://github.com/Webman-Dev/nextblock-monorepo",
99
- "variant": "outline",
100
- "size": "lg"
101
- }
102
- },
103
- {
104
- "block_type": "text",
105
- "content": {
106
- "html_content": "<div class='flex flex-wrap justify-center gap-6 text-sm uppercase tracking-wide text-slate-400 mt-8'><a href='https://github.com/Webman-Dev' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>GitHub</a><a href='https://x.com/NextBlockCMS' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>X</a><a href='https://www.linkedin.com/in/nextblock/' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>LinkedIn</a><a href='https://dev.to/nextblockcms' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>Dev.to</a><a href='https://www.npmjs.com/~nextblockcms' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>npm</a></div>"
107
- }
108
- }
109
- ],
110
- [
111
- {
112
- "block_type": "text",
113
- "content": {
114
- "html_content": "<div class='p-10 border border-white/10 rounded-3xl bg-white/5 backdrop-blur-xl shadow-2xl relative overflow-hidden group'><div class='absolute inset-0 bg-gradient-to-br from-blue-500/10 to-purple-500/10 opacity-0 group-hover:opacity-100 transition-opacity duration-500'></div><div class='relative z-10'><p class='text-xs text-white uppercase tracking-widest font-semibold mb-2'>Why teams switch</p><p class='text-3xl font-bold text-white mb-2'>100% Lighthouse</p><p class='text-base text-slate-300 mb-6'>Edge-rendered marketing sites, launches, and docs with uncompromising performance.</p><ul class='space-y-3 text-sm text-slate-200'><li><span class='text-blue-400 mr-2'>✓</span> Next.js 16 with ISR and edge caching</li><li><span class='text-blue-400 mr-2'>✓</span> Supabase auth, data, and storage</li><li><span class='text-blue-400 mr-2'>✓</span> Notion-style block editor powered by Tiptap</li></ul><div class='mt-6 rounded-2xl overflow-hidden border border-white/10 shadow-lg'><img src='/images/NBcover.webp' alt='Nextblock cover showcasing dashboards and blocks' class='w-full h-auto object-cover transform group-hover:scale-105 transition-transform duration-700' /></div></div></div>"
115
- }
116
- }
117
- ]
118
- ]
119
- }$$::jsonb,
120
- 0
121
- ),
122
- (
123
- v_home_page_id,
124
- v_en_lang_id,
125
- 'section',
126
- $${
127
- "container_type": "container",
128
- "background": { "type": "none" },
129
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 1 },
130
- "column_gap": "lg",
131
- "padding": { "top": "xl", "bottom": "xl" },
132
- "column_blocks": [
133
- [
134
- {
135
- "block_type": "heading",
136
- "content": {
137
- "level": 2,
138
- "text_content": "Key Features: The Three Pillars of NextBlock",
139
- "textAlign": "center"
140
- }
141
- },
142
- {
143
- "block_type": "text",
144
- "content": {
145
- "html_content": "<p class='text-lg text-slate-600 dark:text-slate-400 text-center max-w-3xl mx-auto'>NextBlock is a holistic platform that unites performance, editorial experience, and developer control so every stakeholder delivers their best work.</p>"
146
- }
147
- },
148
- {
149
- "block_type": "text",
150
- "content": {
151
- "html_content": "<div class='grid gap-8 md:grid-cols-3 mt-12'><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 backdrop-blur-sm hover:bg-slate-100 dark:hover:bg-white/10 transition-colors duration-300'><div class='w-12 h-12 rounded-xl flex items-center justify-center mb-6'><svg class='w-6 h-6' fill='none' stroke='currentColor' viewBox='0 0 24 24'><path stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M13 10V3L4 14h7v7l9-11h-7z'></path></svg></div><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>Built for Speed.</h3><p class='text-sm text-slate-600 dark:text-slate-400 leading-relaxed'>Architected for 100% Lighthouse scores with global delivery and near-instant FCP.</p><ul class='mt-6 space-y-3 text-sm text-slate-600 dark:text-slate-400'><li><strong class='text-slate-800 dark:text-slate-200'>Edge Caching & ISR:</strong> Serve pages worldwide.</li><li><strong class='text-slate-800 dark:text-slate-200'>Critical CSS:</strong> Inline styles to eliminate blocking.</li><li><strong class='text-slate-800 dark:text-slate-200'>Image Opt:</strong> AVIF & blurred placeholders.</li></ul></div><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 backdrop-blur-sm hover:bg-slate-100 dark:hover:bg-white/10 transition-colors duration-300'><div class='w-12 h-12 rounded-xl flex items-center justify-center mb-6'><svg class='w-6 h-6' fill='none' stroke='currentColor' viewBox='0 0 24 24'><path stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z'></path></svg></div><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>Editor-First Experience.</h3><p class='text-sm text-slate-600 dark:text-slate-400 leading-relaxed'>A low-code, Notion-style block editor empowers teams to ship pages without engineering help.</p><ul class='mt-6 space-y-3 text-sm text-slate-600 dark:text-slate-400'><li><strong class='text-slate-800 dark:text-slate-200'>Notion-Style:</strong> Slash commands & drag-and-drop.</li><li><strong class='text-slate-800 dark:text-slate-200'>Bilingual:</strong> Manage locales from one interface.</li><li><strong class='text-slate-800 dark:text-slate-200'>History:</strong> Restore any version with a click.</li></ul></div><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-gradient-to-br from-blue-50 to-purple-50 dark:from-blue-600/20 dark:to-purple-600/20 backdrop-blur-sm hover:from-blue-100 hover:to-purple-100 dark:hover:from-blue-600/30 dark:hover:to-purple-600/30 transition-colors duration-300'><div class='w-12 h-12 bg-white/50 dark:bg-white/10 rounded-xl flex items-center justify-center mb-6'><svg class='w-6 h-6 text-slate-900 dark:text-white' fill='none' stroke='currentColor' viewBox='0 0 24 24'><path stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 11H5m14 0a2 2 0 012 2v6a2 2 0 01-2 2H5a2 2 0 01-2-2v-6a2 2 0 012-2m14 0V9a2 2 0 00-2-2M5 11V9a2 2 0 012-2m0 0V5a2 2 0 012-2h6a2 2 0 012 2v2M7 7h10'></path></svg></div><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>Infinitely Extensible.</h3><p class='text-sm text-slate-700 dark:text-slate-200 leading-relaxed'>Open-source control with a clean Nx monorepo and a typed SDK for limitless customization.</p><ul class='mt-6 space-y-3 text-sm text-slate-700 dark:text-slate-200'><li><strong class='text-slate-900 dark:text-white'>Open Source:</strong> Own the code & data forever.</li><li><strong class='text-slate-900 dark:text-white'>Nx Monorepo:</strong> Scale confidently.</li><li><strong class='text-slate-900 dark:text-white'>Developer SDK:</strong> Scaffold blocks in minutes.</li></ul></div></div>"
152
- }
153
- }
154
- ]
155
- ]
156
- }$$::jsonb,
157
- 1
158
- ),
159
- (
160
- v_home_page_id,
161
- v_en_lang_id,
162
- 'section',
163
- $${
164
- "container_type": "container",
165
- "background": {
166
- "type": "gradient",
167
- "gradient": {
168
- "type": "linear",
169
- "direction": "180deg",
170
- "stops": [
171
- { "color": "#0f172a", "position": 0 },
172
- { "color": "#020817", "position": 100 }
173
- ]
174
- }
175
- },
176
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 1 },
177
- "column_gap": "lg",
178
- "padding": { "top": "xl", "bottom": "xl" },
179
- "column_blocks": [
180
- [
181
- {
182
- "block_type": "text",
183
- "content": {
184
- "html_content": "<h2 class='text-3xl md:text-4xl font-bold text-white text-center mb-6'>Built with the Best.</h2>"
185
- }
186
- },
187
- {
188
- "block_type": "text",
189
- "content": {
190
- "html_content": "<p class='text-slate-400 text-center max-w-2xl mx-auto'>Every layer of NextBlock leans on proven developer-first technology so the platform feels familiar, performant, and trustworthy from day one.</p><div class='grid grid-cols-2 sm:grid-cols-4 lg:grid-cols-8 gap-4 mt-10 text-sm font-semibold text-center text-white'><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Next.js</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>React</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Supabase</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Tailwind</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>shadcn/ui</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Tiptap</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Vercel</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Nx</div></div>"
191
- }
192
- },
193
- {
194
- "block_type": "text",
195
- "content": {
196
- "html_content": "<h2 class='text-3xl md:text-4xl font-bold text-white text-center mb-6 mt-16'>Powerful for Developers. Intuitive for Editors.</h2>"
197
- }
198
- },
199
- {
200
- "block_type": "text",
201
- "content": {
202
- "html_content": "<div class='grid md:grid-cols-2 gap-8 mt-10 text-white'><div class='p-8 rounded-3xl border border-white/10 bg-white/5 backdrop-blur-sm'><h3 class='text-xl font-bold mb-6 text-blue-400'>For Content Creators</h3><ul class='space-y-4 text-sm text-slate-300'><li><strong class='text-white block mb-1'>Intuitive Block Editor</strong>Drag-and-drop layouts with a Notion-like interface.</li><li><strong class='text-white block mb-1'>Rich Content Blocks</strong>Deploy heroes, galleries, testimonials, and more in one click.</li><li><strong class='text-white block mb-1'>Effortless Media Management</strong>Organize assets with folders, tags, and bulk actions.</li><li><strong class='text-white block mb-1'>Worry-Free Revisions</strong>Automatic version history with instant restore.</li></ul></div><div class='p-8 rounded-3xl border border-white/10 bg-gradient-to-br from-white/5 to-white/[0.02] backdrop-blur-sm'><h3 class='text-xl font-bold mb-6 text-purple-400'>For Developers</h3><ul class='space-y-4 text-sm text-slate-300'><li><strong class='text-white block mb-1'>Next.js 16 Core</strong>Server Components, ISR, and Edge Functions ready out of the box.</li><li><strong class='text-white block mb-1'>Supabase Integration</strong>Postgres, auth, storage, and real-time APIs without glue code.</li><li><strong class='text-white block mb-1'>Monorepo Ready</strong>Nx-powered dev experience for scalable architectures.</li><li><strong class='text-white block mb-1'>Extensible Block SDK</strong>Ship fully typed custom blocks and widgets.</li></ul></div></div>"
203
- }
204
- }
205
- ]
206
- ]
207
- }$$::jsonb,
208
- 2
209
- ),
210
- (
211
- v_home_page_id,
212
- v_en_lang_id,
213
- 'section',
214
- $${
215
- "container_type": "container",
216
- "background": { "type": "none" },
217
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 1 },
218
- "column_gap": "lg",
219
- "padding": { "top": "xl", "bottom": "xl" },
220
- "column_blocks": [
221
- [
222
- {
223
- "block_type": "heading",
224
- "content": {
225
- "level": 2,
226
- "text_content": "More Than a CMS. An Ecosystem.",
227
- "textAlign": "center"
228
- }
229
- },
230
- {
231
- "block_type": "text",
232
- "content": {
233
- "html_content": "<p class='text-slate-600 dark:text-slate-400 text-center max-w-3xl mx-auto'>NextBlock is building a sustainable open-core roadmap so the platform grows with your business.</p>"
234
- }
235
- },
236
- {
237
- "block_type": "text",
238
- "content": {
239
- "html_content": "<div class='grid md:grid-cols-2 gap-6 mt-10'><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:border-blue-500/30 transition-colors'><p class='text-xs uppercase tracking-wide text-blue-600 dark:text-blue-400 mb-2 font-bold'>Coming Soon</p><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>NextBlock Commerce</h3><p class='text-sm text-slate-600 dark:text-slate-400'>Transform your site into a composable storefront. The premium module ships product management, seamless Stripe payments, and e-commerce blocks that drop directly into the editor.</p></div><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:border-purple-500/30 transition-colors'><p class='text-xs uppercase tracking-wide text-purple-600 dark:text-purple-400 mb-2 font-bold'>Build the Future</p><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>Plugin & Block Marketplace</h3><p class='text-sm text-slate-600 dark:text-slate-400'>A community-driven marketplace invites developers to publish and monetize custom blocks, themes, and plugins—turning NextBlock into an extensible ecosystem.</p></div></div>"
240
- }
241
- },
242
- {
243
- "block_type": "heading",
244
- "content": {
245
- "level": 2,
246
- "text_content": "Join Our Community.",
247
- "textAlign": "center"
248
- }
249
- },
250
- {
251
- "block_type": "text",
252
- "content": {
253
- "html_content": "<p class='text-slate-600 dark:text-slate-400 text-center max-w-3xl mx-auto'>NextBlock is being built in the open. Star the repo, share feedback, and help define the future of performance-first content management.</p>"
254
- }
255
- },
256
- {
257
- "block_type": "text",
258
- "content": {
259
- "html_content": "<div class='grid gap-4 md:grid-cols-3 mt-10 text-sm'><a class='p-6 rounded-2xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:bg-slate-100 dark:hover:bg-white/10 transition-all hover:scale-[1.02]' href='https://github.com/Webman-Dev' target='_blank' rel='noopener noreferrer'><strong class='block text-base text-slate-900 dark:text-white mb-1'>GitHub</strong><span class='text-slate-600 dark:text-slate-400'>Star the repo & contribute</span></a><a class='p-6 rounded-2xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:bg-slate-100 dark:hover:bg-white/10 transition-all hover:scale-[1.02]' href='https://x.com/NextBlockCMS' target='_blank' rel='noopener noreferrer'><strong class='block text-base text-slate-900 dark:text-white mb-1'>X (Twitter)</strong><span class='text-slate-600 dark:text-slate-400'>Follow updates & announcements</span></a><a class='p-6 rounded-2xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:bg-slate-100 dark:hover:bg-white/10 transition-all hover:scale-[1.02]' href='https://dev.to/nextblockcms' target='_blank' rel='noopener noreferrer'><strong class='block text-base text-slate-900 dark:text-white mb-1'>Dev.to</strong><span class='text-slate-600 dark:text-slate-400'>Read technical deep dives</span></a></div>"
260
- }
261
- }
262
- ]
263
- ]
264
- }$$::jsonb,
265
- 3
266
- ),
267
- (
268
- v_home_page_id,
269
- v_en_lang_id,
270
- 'section',
271
- $${
272
- "container_type": "container",
273
- "background": {
274
- "type": "gradient",
275
- "gradient": {
276
- "type": "linear",
277
- "direction": "180deg",
278
- "stops": [
279
- { "color": "#020817", "position": 0 },
280
- { "color": "#0f172a", "position": 100 }
281
- ]
282
- }
283
- },
284
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 1 },
285
- "column_gap": "lg",
286
- "padding": { "top": "xl", "bottom": "xl" },
287
- "column_blocks": [
288
- [
289
- {
290
- "block_type": "text",
291
- "content": {
292
- "html_content": "<h2 class='text-3xl md:text-4xl font-bold text-center text-white mb-4'>Have Questions?</h2>"
293
- }
294
- },
295
- {
296
- "block_type": "text",
297
- "content": {
298
- "html_content": "<p class='text-center text-lg text-slate-300 max-w-2xl mx-auto mb-8'>NextBlock partners with early adopters to co-build features, sponsor modules, and shape the product direction.</p>"
299
- }
300
- },
301
- {
302
- "block_type": "button",
303
- "content": {
304
- "text": "Get in Touch",
305
- "url": "mailto:hello@nextblockcms.com",
306
- "variant": "default",
307
- "size": "lg"
308
- }
309
- }
310
- ]
311
- ]
312
- }$$::jsonb,
313
- 4
314
- );
315
-
316
- INSERT INTO public.blocks (page_id, language_id, block_type, content, "order")
317
- VALUES
318
- (
319
- v_blog_page_id,
320
- v_en_lang_id,
321
- 'hero',
322
- $${
323
- "container_type": "container",
324
- "background": {
325
- "type": "gradient",
326
- "gradient": {
327
- "type": "linear",
328
- "direction": "135deg",
329
- "stops": [
330
- { "color": "#020817", "position": 0 },
331
- { "color": "#1e293b", "position": 100 }
332
- ]
333
- }
334
- },
335
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 2 },
336
- "column_gap": "lg",
337
- "padding": { "top": "xl", "bottom": "xl" },
338
- "column_blocks": [
339
- [
340
- {
341
- "block_type": "text",
342
- "content": {
343
- "html_content": "<p class='text-sm uppercase tracking-[0.3em] text-blue-400 font-bold text-center md:text-left mb-4'>The Nextblock Journal</p>"
344
- }
345
- },
346
- {
347
- "block_type": "text",
348
- "content": {
349
- "html_content": "<h2 class='text-4xl md:text-5xl font-bold text-white text-center md:text-left mb-6'>Deep dives into performance, DX, and visual editing.</h2>"
350
- }
351
- },
352
- {
353
- "block_type": "text",
354
- "content": {
355
- "html_content": "<p class='text-slate-300 text-lg max-w-xl mx-auto md:mx-0 text-center md:text-left leading-relaxed'>Explore architectural walkthroughs, Supabase recipes, and block editor experiments written by the Nextblock core team.</p>"
356
- }
357
- },
358
- {
359
- "block_type": "button",
360
- "content": {
361
- "text": "Explore Articles",
362
- "url": "/articles#latest",
363
- "variant": "default",
364
- "size": "lg"
365
- }
366
- },
367
- {
368
- "block_type": "button",
369
- "content": {
370
- "text": "Subscribe for Updates",
371
- "url": "https://github.com/Webman-Dev/nextblock-monorepo/discussions",
372
- "variant": "outline",
373
- "size": "lg"
374
- }
375
- }
376
- ],
377
- [
378
- {
379
- "block_type": "text",
380
- "content": {
381
- "html_content": "<div class='h-full flex items-center justify-center rounded-3xl overflow-hidden border border-white/10 bg-white/5 shadow-2xl p-4 backdrop-blur-sm'><img src='/images/developer.webp' alt='Developer working with the Nextblock stack' class='w-full object-cover rounded-2xl shadow-lg' style='max-width: 400px;' /></div>"
382
- }
383
- }
384
- ]
385
- ]
386
- }$$::jsonb,
387
- 0
388
- ),
389
- (
390
- v_blog_page_id,
391
- v_en_lang_id,
392
- 'posts_grid',
393
- $${
394
- "postsPerPage": 6,
395
- "columns": 3,
396
- "showPagination": true,
397
- "title": "Latest Deep Dives"
398
- }$$::jsonb,
399
- 1
400
- );
401
-
402
- DELETE FROM public.navigation_items
403
- WHERE menu_key = 'HEADER'
404
- AND language_id = v_en_lang_id;
405
-
406
- INSERT INTO public.navigation_items (language_id, menu_key, label, url, "order", page_id)
407
- VALUES
408
- (v_en_lang_id, 'HEADER', 'Home', '/', 0, v_home_page_id),
409
- (v_en_lang_id, 'HEADER', 'Articles', '/articles', 1, v_blog_page_id);
410
- END;
411
- $seed$;
412
-
413
- SELECT id AS home_page_id
414
- FROM public.pages
415
- WHERE slug = 'home'
416
- AND language_id = (SELECT id FROM public.languages WHERE code = 'en' LIMIT 1)
417
- ORDER BY created_at DESC
418
- LIMIT 1;
419
-
420
- SELECT id AS blog_page_id
421
- FROM public.pages
422
- WHERE slug = 'articles'
423
- AND language_id = (SELECT id FROM public.languages WHERE code = 'en' LIMIT 1)
424
- ORDER BY created_at DESC
425
- LIMIT 1;
426
-
427
- -- Seed French blocks for Accueil and Articles
428
- DO $seed_fr$
429
- DECLARE
430
- v_fr_lang_id BIGINT;
431
- v_home_page_fr_id BIGINT;
432
- v_blog_page_fr_id BIGINT;
433
- BEGIN
434
- SELECT id INTO v_fr_lang_id FROM public.languages WHERE code = 'fr' LIMIT 1;
435
- IF v_fr_lang_id IS NULL THEN
436
- RAISE EXCEPTION 'French language (code = fr) not found. Run the language seed migration first.';
437
- END IF;
438
-
439
- SELECT id INTO v_home_page_fr_id FROM public.pages WHERE slug = 'accueil' AND language_id = v_fr_lang_id ORDER BY created_at DESC LIMIT 1;
440
- SELECT id INTO v_blog_page_fr_id FROM public.pages WHERE slug = 'articles' AND language_id = v_fr_lang_id ORDER BY created_at DESC LIMIT 1;
441
-
442
- IF v_home_page_fr_id IS NULL THEN
443
- RAISE EXCEPTION 'French home page not found.';
444
- END IF;
445
- IF v_blog_page_fr_id IS NULL THEN
446
- RAISE EXCEPTION 'French articles page not found.';
447
- END IF;
448
-
449
- DELETE FROM public.blocks WHERE page_id IN (v_home_page_fr_id, v_blog_page_fr_id);
450
-
451
- DELETE FROM public.navigation_items
452
- WHERE menu_key = 'HEADER'
453
- AND language_id = v_fr_lang_id;
454
-
455
- INSERT INTO public.navigation_items (language_id, menu_key, label, url, "order", page_id)
456
- VALUES
457
- (v_fr_lang_id, 'HEADER', 'Accueil', '/accueil', 0, v_home_page_fr_id),
458
- (v_fr_lang_id, 'HEADER', 'Articles', '/articles', 1, v_blog_page_fr_id);
459
-
460
- INSERT INTO public.blocks (page_id, language_id, block_type, content, "order")
461
- VALUES
462
- (
463
- v_home_page_fr_id,
464
- v_fr_lang_id,
465
- 'hero',
466
- $${
467
- "container_type": "container",
468
- "background": {
469
- "type": "gradient",
470
- "gradient": {
471
- "type": "linear",
472
- "direction": "135deg",
473
- "stops": [
474
- { "color": "#020817", "position": 0 },
475
- { "color": "#0f172a", "position": 50 },
476
- { "color": "#1e293b", "position": 100 }
477
- ]
478
- }
479
- },
480
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 2 },
481
- "column_gap": "xl",
482
- "padding": { "top": "xl", "bottom": "xl" },
483
- "column_blocks": [
484
- [
485
- { "block_type": "text", "content": { "html_content": "<h1 class='text-5xl md:text-6xl font-bold tracking-tight text-white text-center drop-shadow-lg'>Créez des sites <span class='text-transparent bg-clip-text bg-gradient-to-r from-blue-400 to-cyan-400'>Ultra-Rapides</span>.</h1>" } },
486
- { "block_type": "text", "content": { "html_content": "<p class='text-xl text-slate-300 text-center max-w-3xl mx-auto mt-4 leading-relaxed'>NextBlock est le CMS Next.js open-source alliant scores Lighthouse parfaits et éditeur visuel puissant.</p>" } },
487
- { "block_type": "button", "content": { "text": "Commencer", "url": "/article/comment-nextblock-fonctionne", "variant": "default", "size": "lg" } },
488
- { "block_type": "button", "content": { "text": "Voir sur GitHub", "url": "https://github.com/Webman-Dev/nextblock-monorepo", "variant": "outline", "size": "lg" } },
489
- { "block_type": "text", "content": { "html_content": "<div class='flex flex-wrap justify-center gap-6 text-sm uppercase tracking-wide text-slate-400 mt-8'><a href='https://github.com/Webman-Dev' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>GitHub</a><a href='https://x.com/NextBlockCMS' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>X</a><a href='https://www.linkedin.com/in/nextblock/' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>LinkedIn</a><a href='https://dev.to/nextblockcms' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>Dev.to</a><a href='https://www.npmjs.com/~nextblockcms' target='_blank' rel='noopener noreferrer' class='hover:text-white transition-colors'>npm</a></div>" } }
490
- ],
491
- [
492
- { "block_type": "text", "content": { "html_content": "<div class='p-10 border border-white/10 rounded-3xl bg-white/5 backdrop-blur-xl shadow-2xl relative overflow-hidden group'><div class='absolute inset-0 bg-gradient-to-br from-blue-500/10 to-purple-500/10 opacity-0 group-hover:opacity-100 transition-opacity duration-500'></div><div class='relative z-10'><p class='text-xs text-white uppercase tracking-widest font-semibold mb-2'>Pourquoi migrer</p><p class='text-3xl font-bold text-white mb-2'>100% Lighthouse</p><p class='text-base text-slate-300 mb-6'>Sites marketing et docs rendus à l'edge avec des performances irréprochables.</p><ul class='space-y-3 text-sm text-slate-200'><li><span class='text-blue-400 mr-2'>✓</span> Next.js 16 avec ISR et cache edge</li><li><span class='text-blue-400 mr-2'>✓</span> Supabase pour l'auth, les données et le stockage</li><li><span class='text-blue-400 mr-2'>✓</span> Éditeur de blocs type Notion sur Tiptap</li></ul><div class='mt-6 rounded-2xl overflow-hidden border border-white/10 shadow-lg'><img src='/images/NBcover.webp' alt='Couverture Nextblock avec tableaux de bord et blocs' class='w-full h-auto object-cover transform group-hover:scale-105 transition-transform duration-700' /></div></div></div>" } }
493
- ]
494
- ]
495
- }$$::jsonb,
496
- 0
497
- ),
498
- (
499
- v_home_page_fr_id,
500
- v_fr_lang_id,
501
- 'section',
502
- $${
503
- "container_type": "container",
504
- "background": { "type": "none" },
505
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 1 },
506
- "column_gap": "lg",
507
- "padding": { "top": "xl", "bottom": "xl" },
508
- "column_blocks": [
509
- [
510
- { "block_type": "heading", "content": { "level": 2, "text_content": "Fonctionnalités clés : les trois piliers de NextBlock", "textAlign": "center" } },
511
- { "block_type": "text", "content": { "html_content": "<p class='text-lg text-slate-600 dark:text-slate-400 text-center max-w-3xl mx-auto'>NextBlock unifie performances, expérience éditoriale et contrôle développeur pour que chaque équipe livre son meilleur travail.</p>" } },
512
- { "block_type": "text", "content": { "html_content": "<div class='grid gap-8 md:grid-cols-3 mt-12'><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 backdrop-blur-sm hover:bg-slate-100 dark:hover:bg-white/10 transition-colors duration-300'><div class='w-12 h-12 rounded-xl flex items-center justify-center mb-6'><svg class='w-6 h-6 text-blue-600 dark:text-blue-400' fill='none' stroke='currentColor' viewBox='0 0 24 24'><path stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M13 10V3L4 14h7v7l9-11h-7z'></path></svg></div><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>Vitesse Extrême.</h3><p class='text-sm text-slate-600 dark:text-slate-400 leading-relaxed'>Pensé pour des scores Lighthouse parfaits avec une diffusion mondiale.</p><ul class='mt-6 space-y-3 text-sm text-slate-600 dark:text-slate-400'><li><strong class='text-slate-800 dark:text-slate-200'>Edge Caching:</strong> Servez vos pages partout.</li><li><strong class='text-slate-800 dark:text-slate-200'>Critical CSS:</strong> Styles en ligne pour éviter les blocages.</li><li><strong class='text-slate-800 dark:text-slate-200'>Images Opt:</strong> AVIF et placeholders floutés.</li></ul></div><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 backdrop-blur-sm hover:bg-slate-100 dark:hover:bg-white/10 transition-colors duration-300'><div class='w-12 h-12 rounded-xl flex items-center justify-center mb-6'><svg class='w-6 h-6 text-purple-600 dark:text-purple-400' fill='none' stroke='currentColor' viewBox='0 0 24 24'><path stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z'></path></svg></div><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>Expérience Éditeur.</h3><p class='text-sm text-slate-600 dark:text-slate-400 leading-relaxed'>Un éditeur façon Notion pour publier sans dépendre des développeurs.</p><ul class='mt-6 space-y-3 text-sm text-slate-600 dark:text-slate-400'><li><strong class='text-slate-800 dark:text-slate-200'>Visuel:</strong> Héros, galeries, témoignages.</li><li><strong class='text-slate-800 dark:text-slate-200'>Média:</strong> Dossiers, tags et actions groupées.</li><li><strong class='text-slate-800 dark:text-slate-200'>Historique:</strong> Restauration complète.</li></ul></div><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-gradient-to-br from-blue-50 to-purple-50 dark:from-blue-600/20 dark:to-purple-600/20 backdrop-blur-sm hover:from-blue-100 hover:to-purple-100 dark:hover:from-blue-600/30 dark:hover:to-purple-600/30 transition-colors duration-300'><div class='w-12 h-12 rounded-xl flex items-center justify-center mb-6'><svg class='w-6 h-6 text-slate-900 dark:text-white' fill='none' stroke='currentColor' viewBox='0 0 24 24'><path stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 11H5m14 0a2 2 0 012 2v6a2 2 0 01-2 2H5a2 2 0 01-2-2v-6a2 2 0 012-2m14 0V9a2 2 0 00-2-2M5 11V9a2 2 0 012-2m0 0V5a2 2 0 012-2h6a2 2 0 012 2v2M7 7h10'></path></svg></div><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>Extensible à l'Infini.</h3><p class='text-sm text-slate-700 dark:text-slate-200 leading-relaxed'>Un socle Next.js + Supabase modulaire, extensible et auto-hébergeable.</p><ul class='mt-6 space-y-3 text-sm text-slate-700 dark:text-slate-200'><li><strong class='text-slate-900 dark:text-white'>SDK de blocs:</strong> Composants typés.</li><li><strong class='text-slate-900 dark:text-white'>CLI:</strong> Générez modules en minutes.</li><li><strong class='text-slate-900 dark:text-white'>Monorepo Nx:</strong> Dépendances maintenables.</li></ul></div></div>" } }
513
- ]
514
- ]
515
- }$$::jsonb,
516
- 1
517
- ),
518
- (
519
- v_home_page_fr_id,
520
- v_fr_lang_id,
521
- 'section',
522
- $${
523
- "container_type": "container",
524
- "background": {
525
- "type": "gradient",
526
- "gradient": {
527
- "type": "linear",
528
- "direction": "180deg",
529
- "stops": [
530
- { "color": "#0f172a", "position": 0 },
531
- { "color": "#020817", "position": 100 }
532
- ]
533
- }
534
- },
535
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 1 },
536
- "column_gap": "lg",
537
- "padding": { "top": "xl", "bottom": "xl" },
538
- "column_blocks": [
539
- [
540
- { "block_type": "text", "content": { "html_content": "<h2 class='text-3xl md:text-4xl font-bold text-white text-center mb-6'>Conçu avec les meilleurs outils.</h2>" } },
541
- { "block_type": "text", "content": { "html_content": "<p class='text-slate-400 text-center max-w-2xl mx-auto'>Chaque couche de NextBlock repose sur des technologies éprouvées pour offrir une expérience familière, performante et fiable.</p><div class='grid grid-cols-2 sm:grid-cols-4 lg:grid-cols-8 gap-4 mt-10 text-sm font-semibold text-center text-white'><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Next.js</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>React</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Supabase</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Tailwind</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>shadcn/ui</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Tiptap</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Vercel</div><div class='p-4 rounded-2xl border border-white/10 bg-white/5 hover:bg-white/10 transition-colors'>Nx</div></div>" } },
542
- { "block_type": "text", "content": { "html_content": "<h2 class='text-3xl md:text-4xl font-bold text-white text-center mb-6 mt-16'>Puissant pour les développeurs. Intuitif pour les éditeurs.</h2>" } },
543
- { "block_type": "text", "content": { "html_content": "<div class='grid md:grid-cols-2 gap-8 mt-10 text-white'><div class='p-8 rounded-3xl border border-white/10 bg-white/5 backdrop-blur-sm'><h3 class='text-xl font-bold mb-6 text-blue-400'>Pour les créateurs</h3><ul class='space-y-4 text-sm text-slate-300'><li><strong class='text-white block mb-1'>Éditeur de blocs</strong>Glisser-déposer façon Notion.</li><li><strong class='text-white block mb-1'>Blocs riches</strong>Héros, galeries, témoignages.</li><li><strong class='text-white block mb-1'>Médiathèque</strong>Dossiers, tags et actions groupées.</li><li><strong class='text-white block mb-1'>Versions sécurisées</strong>Historique et restauration instantanée.</li></ul></div><div class='p-8 rounded-3xl border border-white/10 bg-gradient-to-br from-white/5 to-white/[0.02] backdrop-blur-sm'><h3 class='text-xl font-bold mb-6 text-purple-400'>Pour les développeurs</h3><ul class='space-y-4 text-sm text-slate-300'><li><strong class='text-white block mb-1'>Next.js 16</strong>Server Components, ISR et Edge prêts à l'emploi.</li><li><strong class='text-white block mb-1'>Supabase</strong>Postgres, auth, stockage, temps réel.</li><li><strong class='text-white block mb-1'>Monorepo Nx</strong>Dépendances lisibles et centrales.</li><li><strong class='text-white block mb-1'>SDK de blocs</strong>Widgets typés et extensibles.</li></ul></div></div>" } }
544
- ]
545
- ]
546
- }$$::jsonb,
547
- 2
548
- ),
549
- (
550
- v_home_page_fr_id,
551
- v_fr_lang_id,
552
- 'section',
553
- $${
554
- "container_type": "container",
555
- "background": { "type": "none" },
556
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 1 },
557
- "column_gap": "lg",
558
- "padding": { "top": "xl", "bottom": "xl" },
559
- "column_blocks": [
560
- [
561
- { "block_type": "heading", "content": { "level": 2, "text_content": "Plus qu'un CMS. Un écosystème.", "textAlign": "center" } },
562
- { "block_type": "text", "content": { "html_content": "<p class='text-slate-600 dark:text-slate-400 text-center max-w-3xl mx-auto'>NextBlock construit une feuille de route open-core durable qui évolue avec votre activité.</p>" } },
563
- { "block_type": "text", "content": { "html_content": "<div class='grid md:grid-cols-2 gap-6 mt-10'><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:border-blue-500/30 transition-colors'><p class='text-xs uppercase tracking-wide text-blue-600 dark:text-blue-400 mb-2 font-bold'>Bientôt</p><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>NextBlock Commerce</h3><p class='text-sm text-slate-600 dark:text-slate-400'>Transformez votre site en vitrine composable. Module premium avec gestion produits, paiement Stripe et blocs e-commerce prêts à l'emploi.</p></div><div class='p-10 rounded-3xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:border-purple-500/30 transition-colors'><p class='text-xs uppercase tracking-wide text-purple-600 dark:text-purple-400 mb-2 font-bold'>Construisez le futur</p><h3 class='text-xl font-bold text-slate-900 dark:text-white mb-3'>Marketplace de plugins & blocs</h3><p class='text-sm text-slate-600 dark:text-slate-400'>Une marketplace communautaire pour publier et monétiser blocs, thèmes et plugins — pour un écosystème extensible.</p></div></div>" } },
564
- { "block_type": "heading", "content": { "level": 2, "text_content": "Rejoignez la communauté.", "textAlign": "center" } },
565
- { "block_type": "text", "content": { "html_content": "<p class='text-slate-600 dark:text-slate-400 text-center max-w-3xl mx-auto'>NextBlock se construit en public. Ajoutez une étoile, partagez vos retours et façonnez l'avenir du CMS orienté performance.</p>" } },
566
- { "block_type": "text", "content": { "html_content": "<div class='grid gap-4 md:grid-cols-3 mt-10 text-sm'><a class='p-6 rounded-2xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:bg-slate-100 dark:hover:bg-white/10 transition-all hover:scale-[1.02]' href='https://github.com/Webman-Dev' target='_blank' rel='noopener noreferrer'><strong class='block text-base text-slate-900 dark:text-white mb-1'>GitHub</strong><span class='text-slate-600 dark:text-slate-400'>Ajoutez une étoile & contribuez</span></a><a class='p-6 rounded-2xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:bg-slate-100 dark:hover:bg-white/10 transition-all hover:scale-[1.02]' href='https://x.com/NextBlockCMS' target='_blank' rel='noopener noreferrer'><strong class='block text-base text-slate-900 dark:text-white mb-1'>X (Twitter)</strong><span class='text-slate-600 dark:text-slate-400'>Suivez les annonces</span></a><a class='p-6 rounded-2xl border border-slate-200 dark:border-white/10 bg-slate-50 dark:bg-white/5 hover:bg-slate-100 dark:hover:bg-white/10 transition-all hover:scale-[1.02]' href='https://dev.to/nextblockcms' target='_blank' rel='noopener noreferrer'><strong class='block text-base text-slate-900 dark:text-white mb-1'>Dev.to</strong><span class='text-slate-600 dark:text-slate-400'>Lisez nos articles techniques</span></a></div>" } }
567
- ]
568
- ]
569
- }$$::jsonb,
570
- 3
571
- ),
572
- (
573
- v_home_page_fr_id,
574
- v_fr_lang_id,
575
- 'section',
576
- $${
577
- "container_type": "container",
578
- "background": {
579
- "type": "gradient",
580
- "gradient": {
581
- "type": "linear",
582
- "direction": "180deg",
583
- "stops": [
584
- { "color": "#020817", "position": 0 },
585
- { "color": "#0f172a", "position": 100 }
586
- ]
587
- }
588
- },
589
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 1 },
590
- "column_gap": "lg",
591
- "padding": { "top": "xl", "bottom": "xl" },
592
- "column_blocks": [
593
- [
594
- { "block_type": "heading", "content": { "level": 2, "text_content": "Des questions ?", "textAlign": "center" } },
595
- { "block_type": "text", "content": { "html_content": "<p class='text-center text-base text-slate-300 max-w-2xl mx-auto'>NextBlock co-construit avec des partenaires : fonctionnalités, modules sponsorisés et direction produit.</p>" } },
596
- { "block_type": "button", "content": { "text": "Nous contacter", "url": "mailto:hello@nextblockcms.com", "variant": "default", "size": "lg" } }
597
- ]
598
- ]
599
- }$$::jsonb,
600
- 4
601
- );
602
-
603
- INSERT INTO public.blocks (page_id, language_id, block_type, content, "order")
604
- VALUES
605
- (
606
- v_blog_page_fr_id,
607
- v_fr_lang_id,
608
- 'hero',
609
- $${
610
- "container_type": "container",
611
- "background": {
612
- "type": "gradient",
613
- "gradient": {
614
- "type": "linear",
615
- "direction": "135deg",
616
- "stops": [
617
- { "color": "#020817", "position": 0 },
618
- { "color": "#1e293b", "position": 100 }
619
- ]
620
- }
621
- },
622
- "responsive_columns": { "mobile": 1, "tablet": 1, "desktop": 2 },
623
- "column_gap": "lg",
624
- "padding": { "top": "xl", "bottom": "xl" },
625
- "column_blocks": [
626
- [
627
- { "block_type": "text", "content": { "html_content": "<p class='text-sm uppercase tracking-[0.3em] text-blue-400 font-bold text-center md:text-left mb-4'>Le journal Nextblock</p>" } },
628
- { "block_type": "text", "content": { "html_content": "<h2 class='text-4xl md:text-5xl font-bold text-white text-center md:text-left mb-6'>Plongées dans la performance, l''expérience dev et l''édition visuelle.</h2>" } },
629
- { "block_type": "text", "content": { "html_content": "<p class='text-lg max-w-xl mx-auto md:mx-0 text-center md:text-left text-slate-300 leading-relaxed'>Walkthroughs d''architecture, recettes Supabase et expérimentations éditeur écrits par l''équipe Nextblock.</p>" } },
630
- { "block_type": "button", "content": { "text": "Explorer les articles", "url": "/articles#latest", "variant": "default", "size": "lg" } },
631
- { "block_type": "button", "content": { "text": "S''abonner aux mises à jour", "url": "https://github.com/Webman-Dev/nextblock-monorepo/discussions", "variant": "outline", "size": "lg" } }
632
- ],
633
- [
634
- { "block_type": "text", "content": { "html_content": "<div class='rounded-3xl overflow-hidden border border-white/10 bg-white/5 shadow-2xl p-4 backdrop-blur-sm'><img src='/images/developer.webp' alt='Développeur travaillant avec la stack Nextblock' class='w-full object-cover rounded-2xl shadow-lg' style='max-width: 400px;' /></div>" } }
635
- ]
636
- ]
637
- }$$::jsonb,
638
- 0
639
- ),
640
- (
641
- v_blog_page_fr_id,
642
- v_fr_lang_id,
643
- 'posts_grid',
644
- $${
645
- "postsPerPage": 6,
646
- "columns": 3,
647
- "showPagination": true,
648
- "title": "Derniers articles"
649
- }$$::jsonb,
650
- 1
651
- );
652
- END;
653
- $seed_fr$;