odoro 1.0.1 → 1.0.3
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.
- package/README.md +73 -0
- package/dist/build-KI7IEVRJ.js +4 -0
- package/dist/{chunk-R6PMAMXA.js → chunk-2EE5QUCW.js} +16 -3
- package/dist/{chunk-CJIUP7A3.js → chunk-FJYUQALD.js} +1 -1
- package/dist/cli.js +4 -4
- package/dist/{create-LTT3SAWT.js → create-VUSKHXBN.js} +109 -65
- package/dist/index.js +2 -2
- package/dist/{package-LK46RV2I.js → package-2JOBLFXE.js} +3 -2
- package/dist/registry/index.d.ts +2 -2
- package/dist/{server-ATGFRVSW.js → server-DXOQAPVX.js} +1 -1
- package/package.json +3 -2
- package/templates/react-ts/_variantes/avec-moteur/src/{sections/Fond.tsx → fond.tsx} +13 -13
- package/templates/react-ts/_variantes/sans-libs/src/App.tsx +363 -23
- package/templates/{react-ts-server/_variantes/sans-libs/client/src/sections/Fond.tsx → react-ts/_variantes/sans-libs/src/fond.tsx} +1 -1
- package/templates/react-ts/_variantes/sans-libs/src/styles.css +115 -38
- package/templates/react-ts/_variantes/sans-routeur/src/App.tsx +427 -22
- package/templates/react-ts/index.html +11 -0
- package/templates/react-ts/public/favicon.svg +2 -3
- package/templates/react-ts/src/App.tsx +585 -57
- package/templates/{react-ts-server/client/src/sections/Fond.tsx → react-ts/src/fond.tsx} +9 -9
- package/templates/react-ts/src/router.tsx +72 -0
- package/templates/react-ts-server/_variantes/avec-moteur/client/src/{sections/Fond.tsx → fond.tsx} +13 -13
- package/templates/react-ts-server/_variantes/sans-libs/client/src/App.tsx +363 -23
- package/templates/{react-ts/_variantes/sans-libs/src/sections/Fond.tsx → react-ts-server/_variantes/sans-libs/client/src/fond.tsx} +1 -1
- package/templates/react-ts-server/_variantes/sans-libs/client/src/styles.css +115 -38
- package/templates/react-ts-server/_variantes/sans-routeur/client/src/App.tsx +427 -22
- package/templates/react-ts-server/client/index.html +11 -0
- package/templates/react-ts-server/client/public/favicon.svg +2 -3
- package/templates/react-ts-server/client/src/App.tsx +585 -57
- package/templates/{react-ts/src/sections/Fond.tsx → react-ts-server/client/src/fond.tsx} +9 -9
- package/templates/react-ts-server/client/src/router.tsx +72 -0
- package/dist/build-GIPMPYJ3.js +0 -4
- package/templates/react-ts/_variantes/sans-libs/src/composants/Marque.tsx +0 -37
- package/templates/react-ts/_variantes/sans-libs/src/sections/Cloture.tsx +0 -60
- package/templates/react-ts/_variantes/sans-libs/src/sections/Hero.tsx +0 -92
- package/templates/react-ts/_variantes/sans-libs/src/sections/Piliers.tsx +0 -44
- package/templates/react-ts/src/composants/Marque.tsx +0 -50
- package/templates/react-ts/src/routes/About.tsx +0 -43
- package/templates/react-ts/src/routes/Home.tsx +0 -28
- package/templates/react-ts/src/routes/NotFound.tsx +0 -14
- package/templates/react-ts/src/sections/Cloture.tsx +0 -69
- package/templates/react-ts/src/sections/Hero.tsx +0 -119
- package/templates/react-ts/src/sections/Piliers.tsx +0 -68
- package/templates/react-ts-server/_variantes/sans-libs/client/src/composants/Marque.tsx +0 -37
- package/templates/react-ts-server/_variantes/sans-libs/client/src/sections/Cloture.tsx +0 -60
- package/templates/react-ts-server/_variantes/sans-libs/client/src/sections/Hero.tsx +0 -92
- package/templates/react-ts-server/_variantes/sans-libs/client/src/sections/Piliers.tsx +0 -44
- package/templates/react-ts-server/client/src/composants/Marque.tsx +0 -50
- package/templates/react-ts-server/client/src/routes/About.tsx +0 -43
- package/templates/react-ts-server/client/src/routes/Home.tsx +0 -28
- package/templates/react-ts-server/client/src/routes/NotFound.tsx +0 -14
- package/templates/react-ts-server/client/src/sections/Cloture.tsx +0 -69
- package/templates/react-ts-server/client/src/sections/Hero.tsx +0 -119
- package/templates/react-ts-server/client/src/sections/Piliers.tsx +0 -68
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Le hero : la promesse, l'installation, et la fenetre du produit.
|
|
3
|
-
*
|
|
4
|
-
* ## Le dessin est celui d'odoro.dev
|
|
5
|
-
*
|
|
6
|
-
* Meme typographie — un titre serre, une phrase de soutien plus claire —,
|
|
7
|
-
* memes pastilles de faits, meme fenetre de navigateur posee sous le pli. Un
|
|
8
|
-
* projet qui demarre ressemble donc a ce qu'il peut devenir, au lieu de partir
|
|
9
|
-
* d'une page blanche qu'il faudra jeter.
|
|
10
|
-
*
|
|
11
|
-
* ## Ce qui n'y est pas
|
|
12
|
-
*
|
|
13
|
-
* Aucun composant du registre. Le hero se contente de ce que les bibliotheques
|
|
14
|
-
* apportent : les classes, `Reveal` et `Stagger`. C'est ce qui lui permet
|
|
15
|
-
* d'exister quel que soit ce qui a ete coche a la creation.
|
|
16
|
-
*
|
|
17
|
-
* @module
|
|
18
|
-
*/
|
|
19
|
-
|
|
20
|
-
import { Reveal, Stagger } from '@odoro-cli/libs/motion'
|
|
21
|
-
import { buttonClasses } from '@odoro-cli/libs/ui'
|
|
22
|
-
import type { ReactElement } from 'react'
|
|
23
|
-
|
|
24
|
-
import { Signe } from '@/composants/Marque'
|
|
25
|
-
|
|
26
|
-
/** Quatre faits, pas quatre slogans. */
|
|
27
|
-
const FAITS = ['Zero configuration', 'Theme clair et sombre', 'Mouvement reduit respecte']
|
|
28
|
-
|
|
29
|
-
/** Ce que la fenetre montre : une page en quelques lignes. */
|
|
30
|
-
const EXTRAIT = `export function Accueil() {
|
|
31
|
-
return (
|
|
32
|
-
<Reveal>
|
|
33
|
-
<h1 className="o-text-6xl o-font-bold">
|
|
34
|
-
Votre premiere page.
|
|
35
|
-
</h1>
|
|
36
|
-
</Reveal>
|
|
37
|
-
)
|
|
38
|
-
}`
|
|
39
|
-
|
|
40
|
-
/**
|
|
41
|
-
* Une fenetre de navigateur miniature.
|
|
42
|
-
*
|
|
43
|
-
* Les trois pastilles sont decoratives : elles disent « navigateur » sans rien
|
|
44
|
-
* ajouter a ce qu'un lecteur d'ecran doit entendre.
|
|
45
|
-
*/
|
|
46
|
-
function Fenetre(): ReactElement {
|
|
47
|
-
return (
|
|
48
|
-
<div className="o-overflow-hidden o-rounded-2xl o-border-w-1 o-border-zinc-200 dark:o-border-zinc-800 o-bg-zinc-50 dark:o-bg-zinc-900 o-shadow-2xl">
|
|
49
|
-
<div className="o-flex o-items-center o-gap-2 o-border-b o-border-zinc-200 dark:o-border-zinc-800 o-px-4 o-py-2.5">
|
|
50
|
-
<span className="o-flex o-gap-1.5" aria-hidden="true">
|
|
51
|
-
<span className="o-size-2.5 o-rounded-full o-bg-zinc-300 dark:o-bg-zinc-700" />
|
|
52
|
-
<span className="o-size-2.5 o-rounded-full o-bg-zinc-300 dark:o-bg-zinc-700" />
|
|
53
|
-
<span className="o-size-2.5 o-rounded-full o-bg-zinc-300 dark:o-bg-zinc-700" />
|
|
54
|
-
</span>
|
|
55
|
-
<span className="o-ml-2 o-font-mono o-text-xs o-text-zinc-400">src/routes/Home.tsx</span>
|
|
56
|
-
</div>
|
|
57
|
-
<pre className="o-m-0 o-overflow-x-auto o-p-5 o-font-mono o-text-xs o-leading-relaxed o-text-zinc-600 dark:o-text-zinc-300">
|
|
58
|
-
{EXTRAIT}
|
|
59
|
-
</pre>
|
|
60
|
-
</div>
|
|
61
|
-
)
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
/** Le hero de la page d'accueil. */
|
|
65
|
-
export function Hero(): ReactElement {
|
|
66
|
-
return (
|
|
67
|
-
<section className="o-relative o-px-6 o-pb-20 o-pt-24 md:o-pt-32">
|
|
68
|
-
<div className="o-mx-auto o-w-full o-max-w-5xl">
|
|
69
|
-
<Reveal>
|
|
70
|
-
<span className="o-inline-flex o-items-center o-gap-2 o-whitespace-nowrap o-rounded-full o-border-w-1 o-border-brand-500/30 o-bg-brand-500/10 o-px-3 o-py-1 o-text-xs o-font-medium o-text-brand-600 dark:o-text-brand-400">
|
|
71
|
-
<Signe />
|
|
72
|
-
Genere par odoro create
|
|
73
|
-
</span>
|
|
74
|
-
|
|
75
|
-
<h1 className="o-mt-6 o-max-w-3xl o-text-5xl o-font-bold o-tracking-tight md:o-text-6xl">
|
|
76
|
-
Votre premiere page,{' '}
|
|
77
|
-
<span className="o-text-brand-500">deja vivante</span>.
|
|
78
|
-
</h1>
|
|
79
|
-
|
|
80
|
-
<p className="o-mt-5 o-max-w-xl o-text-lg o-text-zinc-500 dark:o-text-zinc-400">
|
|
81
|
-
Le routeur, les animations et le systeme de style viennent de la meme
|
|
82
|
-
librairie. Modifiez cette page : elle se recharge sans perdre son etat.
|
|
83
|
-
</p>
|
|
84
|
-
</Reveal>
|
|
85
|
-
|
|
86
|
-
<Stagger step={70} className="o-mt-8 o-flex o-flex-wrap o-items-center o-gap-3">
|
|
87
|
-
<a href="#piliers" className={`o-no-underline ${buttonClasses({ tone: 'primary' })}`}>
|
|
88
|
-
Voir ce qui est inclus
|
|
89
|
-
</a>
|
|
90
|
-
<a
|
|
91
|
-
href="https://odoro.dev/docs"
|
|
92
|
-
className={`o-no-underline ${buttonClasses({ tone: 'secondary' })}`}
|
|
93
|
-
target="_blank"
|
|
94
|
-
rel="noreferrer"
|
|
95
|
-
>
|
|
96
|
-
Documentation
|
|
97
|
-
</a>
|
|
98
|
-
</Stagger>
|
|
99
|
-
|
|
100
|
-
<Stagger step={60} className="o-mt-6 o-flex o-flex-wrap o-gap-2">
|
|
101
|
-
{FAITS.map((fait) => (
|
|
102
|
-
<span
|
|
103
|
-
key={fait}
|
|
104
|
-
className="o-rounded-full o-border-w-1 o-border-zinc-200 dark:o-border-zinc-800 o-px-3 o-py-1 o-text-xs o-text-zinc-500 dark:o-text-zinc-400"
|
|
105
|
-
>
|
|
106
|
-
{fait}
|
|
107
|
-
</span>
|
|
108
|
-
))}
|
|
109
|
-
</Stagger>
|
|
110
|
-
|
|
111
|
-
<Reveal>
|
|
112
|
-
<div className="o-mt-14">
|
|
113
|
-
<Fenetre />
|
|
114
|
-
</div>
|
|
115
|
-
</Reveal>
|
|
116
|
-
</div>
|
|
117
|
-
</section>
|
|
118
|
-
)
|
|
119
|
-
}
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Trois piliers : ce que le projet a deja sous la main.
|
|
3
|
-
*
|
|
4
|
-
* Les cartes s'ecrivent avec la meme grammaire que sur odoro.dev — bordure
|
|
5
|
-
* fine, coin arrondi, titre serre, phrase en gris — pour qu'ajouter une section
|
|
6
|
-
* plus tard ne demande pas d'inventer un style.
|
|
7
|
-
*
|
|
8
|
-
* @module
|
|
9
|
-
*/
|
|
10
|
-
|
|
11
|
-
import { Stagger } from '@odoro-cli/libs/motion'
|
|
12
|
-
import type { ReactElement } from 'react'
|
|
13
|
-
|
|
14
|
-
/** Un pilier : un numero, un titre, une phrase. */
|
|
15
|
-
interface Pilier {
|
|
16
|
-
readonly titre: string
|
|
17
|
-
readonly texte: string
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
const PILIERS: readonly Pilier[] = [
|
|
21
|
-
{
|
|
22
|
-
titre: 'Routeur',
|
|
23
|
-
texte:
|
|
24
|
-
'Segments dynamiques, routes imbriquees, chargement paresseux et transitions de page.',
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
titre: 'Animations',
|
|
28
|
-
texte:
|
|
29
|
-
"Une couche mince sur le moteur du navigateur. Le mouvement reduit est respecte d'office.",
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
titre: 'Styles',
|
|
33
|
-
texte:
|
|
34
|
-
'Des jetons en source de verite, une feuille statique, aucun scan a l execution.',
|
|
35
|
-
},
|
|
36
|
-
]
|
|
37
|
-
|
|
38
|
-
/** La section des piliers. */
|
|
39
|
-
export function Piliers(): ReactElement {
|
|
40
|
-
return (
|
|
41
|
-
<section id="piliers" className="o-border-t o-border-zinc-200 dark:o-border-zinc-800 o-px-6 o-py-20">
|
|
42
|
-
<div className="o-mx-auto o-w-full o-max-w-5xl">
|
|
43
|
-
<h2 className="o-text-sm o-font-semibold o-uppercase o-tracking-widest o-text-zinc-400">
|
|
44
|
-
Ce qui est deja la
|
|
45
|
-
</h2>
|
|
46
|
-
|
|
47
|
-
<Stagger step={90} className="o-mt-8 o-grid o-gap-4 md:o-grid-cols-3">
|
|
48
|
-
{PILIERS.map((pilier, index) => (
|
|
49
|
-
<article
|
|
50
|
-
key={pilier.titre}
|
|
51
|
-
className="o-rounded-xl o-border-w-1 o-border-zinc-200 dark:o-border-zinc-800 o-bg-white dark:o-bg-zinc-900 o-p-6"
|
|
52
|
-
>
|
|
53
|
-
<span className="o-font-mono o-text-xs o-text-brand-500">
|
|
54
|
-
{String(index + 1).padStart(2, '0')}
|
|
55
|
-
</span>
|
|
56
|
-
<h3 className="o-mt-3 o-text-lg o-font-semibold o-tracking-tight">
|
|
57
|
-
{pilier.titre}
|
|
58
|
-
</h3>
|
|
59
|
-
<p className="o-mt-2 o-text-sm o-text-zinc-500 dark:o-text-zinc-400">
|
|
60
|
-
{pilier.texte}
|
|
61
|
-
</p>
|
|
62
|
-
</article>
|
|
63
|
-
))}
|
|
64
|
-
</Stagger>
|
|
65
|
-
</div>
|
|
66
|
-
</section>
|
|
67
|
-
)
|
|
68
|
-
}
|