@donotdev/cli 0.0.30 → 0.0.32

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 (35) hide show
  1. package/dependencies-matrix.json +14 -18
  2. package/dist/bin/commands/agent-setup.js +2 -2
  3. package/dist/bin/commands/build.js +19 -14
  4. package/dist/bin/commands/bump.js +424 -187
  5. package/dist/bin/commands/cacheout.js +19 -14
  6. package/dist/bin/commands/coach.js +19 -14
  7. package/dist/bin/commands/create-app.js +19 -14
  8. package/dist/bin/commands/create-project.js +19 -14
  9. package/dist/bin/commands/db.js +20 -3711
  10. package/dist/bin/commands/deploy.js +19 -14
  11. package/dist/bin/commands/dev.js +19 -14
  12. package/dist/bin/commands/doctor.js +19 -14
  13. package/dist/bin/commands/emu.js +19 -14
  14. package/dist/bin/commands/format.js +19 -14
  15. package/dist/bin/commands/get-demo.js +19 -14
  16. package/dist/bin/commands/make-admin.js +19 -14
  17. package/dist/bin/commands/preview.js +19 -14
  18. package/dist/bin/commands/seed.js +20 -3711
  19. package/dist/bin/commands/setup-cicd.js +19 -14
  20. package/dist/bin/commands/setup.js +19 -14
  21. package/dist/bin/commands/staging.js +19 -14
  22. package/dist/bin/commands/sync-secrets.js +19 -14
  23. package/dist/bin/commands/type-check.js +19 -14
  24. package/dist/bin/commands/wai.js +19 -14
  25. package/dist/bin/dndev.js +1 -1
  26. package/dist/bin/donotdev.js +1 -1
  27. package/dist/index.js +19 -14
  28. package/package.json +1 -1
  29. package/templates/app-next/src/globals.css.example +3 -2
  30. package/templates/app-next/src/pages/HomePage.tsx.example +1 -1
  31. package/templates/app-vite/src/pages/HomePage.tsx.example +1 -1
  32. package/templates/root-consumer/guides/dndev/COMPONENTS_ATOMIC.md.example +3 -3
  33. package/templates/root-consumer/guides/dndev/COMPONENTS_UI.md.example +1 -6
  34. package/templates/root-consumer/guides/wai-way/page_patterns.md.example +70 -34
  35. package/templates/app-demo/stats.html.example +0 -4949
@@ -15,7 +15,7 @@
15
15
  | [Pricing](#pricing) | Plan comparison | PricingTable, Section |
16
16
  | [Settings](#settings) | User preferences | Section, form components |
17
17
  | [Profile](#profile) | User profile display/edit | Section, Card, Avatar |
18
- | [Detail Page](#detail-page) | Single item display (non-edit) | Section, Card, Grid |
18
+ | [Detail Page](#detail-page) | Single item display (non-edit) | Section (bleed), ImageGallery, Card, Grid |
19
19
  | [Analytics](#analytics) | Charts and metrics | Section, Grid, Card, charts |
20
20
 
21
21
  ---
@@ -26,7 +26,8 @@
26
26
 
27
27
  ```tsx
28
28
  import { useEffect, useState } from 'react';
29
- import { PageContainer, Loader, useNavigate } from '@donotdev/ui';
29
+ import { Spinner } from '@donotdev/components';
30
+ import { PageContainer, useNavigate } from '@donotdev/ui';
30
31
  import { Section, Card, Grid, Stack, Button, Text, Badge } from '@donotdev/components';
31
32
  import type { PageMeta } from '@donotdev/core';
32
33
  import { ChartBar, Plus, ArrowRight } from 'lucide-react';
@@ -65,7 +66,7 @@ export default function DashboardPage() {
65
66
  {/* KPI Cards */}
66
67
  <Section title="Overview" gridCols={[1, 2, 3, 3]}>
67
68
  <Card variant="glass" title="Total Items">
68
- {loading ? <Loader /> : (
69
+ {loading ? <Spinner overlay /> : (
69
70
  <Text level="h2">{metrics?.totalItems ?? 0}</Text>
70
71
  )}
71
72
  </Card>
@@ -94,7 +95,7 @@ export default function DashboardPage() {
94
95
  - Quick actions at top (cards with onClick)
95
96
  - KPI cards in grid
96
97
  - Alert/attention sections with actions
97
- - Loading states with `<Loader />`
98
+ - Loading states with `<Spinner overlay />`
98
99
 
99
100
  ---
100
101
 
@@ -243,7 +244,7 @@ export default function CarPage() {
243
244
 
244
245
  ```tsx
245
246
  import { PageContainer, useNavigate } from '@donotdev/ui';
246
- import { HeroSection, Section, Card, Grid, Button } from '@donotdev/components';
247
+ import { HeroSection, Section, CallToAction, Card, Grid, Button } from '@donotdev/components';
247
248
  import type { PageMeta } from '@donotdev/core';
248
249
  import { Home } from 'lucide-react';
249
250
 
@@ -260,18 +261,17 @@ export default function HomePage() {
260
261
 
261
262
  return (
262
263
  <PageContainer>
264
+ {/* Hero with background image — bleed for full-viewport-width */}
263
265
  <HeroSection
266
+ bleed
267
+ backgroundImage="/images/hero.jpg"
264
268
  title="Your App Name"
265
269
  subtitle="One-line value proposition"
266
- primaryAction={{
267
- label: "Get Started",
268
- onClick: () => navigate('/signup'),
269
- }}
270
- secondaryAction={{
271
- label: "Learn More",
272
- onClick: () => navigate('/about'),
273
- }}
274
- />
270
+ fullHeight
271
+ >
272
+ <Button onClick={() => navigate('/signup')}>Get Started</Button>
273
+ <Button variant="outline" onClick={() => navigate('/about')}>Learn More</Button>
274
+ </HeroSection>
275
275
 
276
276
  <Section title="Features">
277
277
  <Grid cols={[1, 2, 3, 3]} gap="large">
@@ -298,23 +298,24 @@ export default function HomePage() {
298
298
  </Grid>
299
299
  </Section>
300
300
 
301
- <Section>
302
- <Card variant="primary" align="center">
303
- <Text level="h2">Ready to get started?</Text>
304
- <Button size="large" onClick={() => navigate('/signup')}>
305
- Start Free Trial
306
- </Button>
307
- </Card>
308
- </Section>
301
+ {/* Full-width CTA with background image */}
302
+ <CallToAction
303
+ bleed
304
+ backgroundImage="/images/cta-bg.jpg"
305
+ title="Ready to get started?"
306
+ subtitle="Start your free trial today"
307
+ primaryAction={<Button onClick={() => navigate('/signup')}>Start Free Trial</Button>}
308
+ />
309
309
  </PageContainer>
310
310
  );
311
311
  }
312
312
  ```
313
313
 
314
314
  **Key patterns:**
315
- - `HeroSection` at top with CTAs
315
+ - `HeroSection bleed backgroundImage` at top for immersive hero banner
316
316
  - Feature grid with `Card` components
317
- - Final CTA section
317
+ - `CallToAction bleed backgroundImage` for full-width CTA with image
318
+ - `Section bleed` for any full-width content (galleries, maps, videos)
318
319
  - HARDCODE strings first, i18n later
319
320
 
320
321
  ---
@@ -366,7 +367,7 @@ export default function PricingPage() {
366
367
 
367
368
  return (
368
369
  <PageContainer>
369
- <Section title="Choose Your Plan" align="center">
370
+ <Section title="Choose Your Plan" textAlign="center">
370
371
  <PricingTable plans={plans} />
371
372
  </Section>
372
373
  </PageContainer>
@@ -518,8 +519,10 @@ export default function ProfilePage() {
518
519
 
519
520
  ```tsx
520
521
  import { useEffect, useState } from 'react';
521
- import { PageContainer, Loader, useNavigate } from '@donotdev/ui';
522
+ import { Spinner } from '@donotdev/components';
523
+ import { PageContainer, useNavigate } from '@donotdev/ui';
522
524
  import { Section, Card, Grid, Stack, Text, Button, Badge } from '@donotdev/components';
525
+ import { ImageGallery } from '@donotdev/components';
523
526
  import { useCrud } from '@donotdev/crud';
524
527
  import { productEntity } from 'entities/product';
525
528
  import type { PageMeta } from '@donotdev/core';
@@ -546,18 +549,20 @@ export default function ProductDetailPage() {
546
549
  }
547
550
  }, [id, get]);
548
551
 
549
- if (loading) return <PageContainer><Loader /></PageContainer>;
552
+ if (loading) return <PageContainer><Spinner overlay /></PageContainer>;
550
553
  if (!product) return <PageContainer><Text>Product not found</Text></PageContainer>;
551
554
 
552
555
  return (
553
556
  <PageContainer>
557
+ {/* Full-width image gallery — bleed breaks out of content constraints */}
558
+ {product.images?.length > 0 && (
559
+ <Section bleed>
560
+ <ImageGallery images={product.images} />
561
+ </Section>
562
+ )}
563
+
554
564
  <Section>
555
565
  <Grid cols={[1, 1, 2, 2]} gap="large">
556
- {/* Image */}
557
- <Card>
558
- <img src={product.image} alt={product.name} />
559
- </Card>
560
-
561
566
  {/* Details */}
562
567
  <Stack direction="column">
563
568
  <Text level="h1">{product.name}</Text>
@@ -583,7 +588,8 @@ export default function ProductDetailPage() {
583
588
 
584
589
  ```tsx
585
590
  import { useEffect, useState } from 'react';
586
- import { PageContainer, Loader } from '@donotdev/ui';
591
+ import { Spinner } from '@donotdev/components';
592
+ import { PageContainer } from '@donotdev/ui';
587
593
  import { Section, Card, Grid, Stack, Text } from '@donotdev/components';
588
594
  import type { PageMeta } from '@donotdev/core';
589
595
  import { TrendingUp } from 'lucide-react';
@@ -604,7 +610,7 @@ export default function AnalyticsPage() {
604
610
  fetchAnalytics().then(setData).finally(() => setLoading(false));
605
611
  }, []);
606
612
 
607
- if (loading) return <PageContainer><Loader /></PageContainer>;
613
+ if (loading) return <PageContainer><Spinner overlay /></PageContainer>;
608
614
 
609
615
  return (
610
616
  <PageContainer>
@@ -675,6 +681,36 @@ export const meta: PageMeta = {
675
681
 
676
682
  ---
677
683
 
684
+ ## Full-Width Bleed (Breakthrough)
685
+
686
+ **When content needs to span the full viewport width**, use the `bleed` prop on Section, HeroSection, or CallToAction. This breaks out of `PageContainer` content constraints — no manual CSS needed.
687
+
688
+ ```tsx
689
+ // Image gallery spanning full width (real estate, car listings, etc.)
690
+ <Section bleed>
691
+ <ImageGallery images={listing.images} />
692
+ </Section>
693
+
694
+ // Hero banner with background image
695
+ <HeroSection bleed backgroundImage="/hero.jpg" title="Welcome" fullHeight>
696
+ <Button>Get Started</Button>
697
+ </HeroSection>
698
+
699
+ // CTA with background image
700
+ <CallToAction bleed backgroundImage="/cta.jpg" title="Join Us" primaryAction={<Button>Sign Up</Button>} />
701
+
702
+ // Any content — map, video, testimonial wall
703
+ <Section bleed>
704
+ <MyMapComponent />
705
+ </Section>
706
+ ```
707
+
708
+ **How it works:** CSS `width: 100vw; margin-inline: calc(50% - 50vw)` — works at any nesting depth.
709
+
710
+ **`backgroundImage` prop** (HeroSection, CallToAction only): Adds a cover image with a dark gradient overlay (`::before` pseudo-element) so text remains readable. Text automatically turns white.
711
+
712
+ ---
713
+
678
714
  ## Usage
679
715
 
680
716
  1. **Find pattern** that matches your page type