Skip to content

Commit b39bde5

Browse files
authored
Merge pull request #10891 from marmelab/headless-doc-content
[Doc] Initialize headless docs content based on RA docs
2 parents 8f255d1 + 6f3f824 commit b39bde5

File tree

226 files changed

+25545
-738
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

226 files changed

+25545
-738
lines changed

docs/ReferenceFieldBase.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ It uses `dataProvider.getMany()` instead of `dataProvider.getOne()` [for perform
7070
| `empty` | Optional | `ReactNode` | - | What to render when the field has no value or when the reference is missing |
7171
| `offline` | Optional | `ReactNode` | - | What to render when there is no network connectivity when loading the record |
7272
| `queryOptions` | Optional | [`UseQuery Options`](https://tanstack.com/query/v5/docs/react/reference/useQuery) | `{}` | `react-query` client options |
73+
| `record` | Optional | `RaRecord` | - | The current record |
7374
| `sortBy` | Optional | `string | Function` | `source` | Name of the field to use for sorting when used in a Datagrid |
7475

7576
## `children`

docs_headless/astro.config.mjs

Lines changed: 159 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import rehypeAstroRelativeMarkdownLinks from 'astro-rehype-relative-markdown-lin
1414
export default defineConfig({
1515
integrations: [
1616
starlight({
17-
title: 'React Admin Headless',
17+
title: 'ra-core',
1818
customCss: ['./src/styles/global.css'],
1919
favicon: '/favicon.ico',
2020
social: [
@@ -25,37 +25,169 @@ export default defineConfig({
2525
},
2626
],
2727
sidebar: [
28+
{
29+
label: 'Getting Started',
30+
slug: 'getting-started',
31+
},
2832
{
2933
label: 'Guides & Concepts',
3034
items: [
31-
// Each item here is one entry in the navigation menu.
32-
{
33-
label: 'General Concepts',
34-
slug: 'guides/architecture',
35-
},
36-
{
37-
label: 'Data Fetching',
38-
slug: 'guides/datafetchingguide',
39-
},
40-
{
41-
label: 'CRUD pages',
42-
slug: 'guides/crud',
43-
attrs: {
44-
class: 'flex items-center',
45-
},
46-
badge: {
47-
text: '',
48-
variant: 'default',
49-
class: 'ee-badge',
50-
},
51-
},
35+
'architecture',
36+
'datafetchingguide',
37+
'crud',
38+
'forms',
39+
'securityguide',
40+
'routing',
41+
'translation',
42+
'store',
43+
'features',
44+
],
45+
},
46+
{
47+
label: 'App Configuration',
48+
items: ['coreadmin', 'resource', 'customroutes'],
49+
},
50+
{
51+
label: 'Data Fetching',
52+
items: [
53+
'dataproviders',
54+
'actions',
55+
'dataproviderlist',
56+
'dataproviderwriting',
57+
'fetchjson',
58+
'usecreate',
59+
'usedataprovider',
60+
'usedelete',
61+
'usedeletemany',
62+
'usegetlist',
63+
'usegetmany',
64+
'usegetmanyreference',
65+
'usegetone',
66+
'useinfinitegetlist',
67+
'useupdate',
68+
'useupdatemany',
69+
'withlifecyclecallbacks',
70+
],
71+
},
72+
{
73+
label: 'Security',
74+
items: [
75+
'authentication',
76+
'authproviderlist',
77+
'authproviderwriting',
78+
'permissions',
79+
'authenticated',
80+
'canaccess',
81+
'useauthenticated',
82+
'useauthprovider',
83+
'useauthstate',
84+
'usecanaccess',
85+
'usegetidentity',
86+
'uselogin',
87+
'uselogout',
88+
'usepermissions',
89+
'addrefreshauthtoauthprovider',
90+
'addrefreshauthtodataprovider',
91+
],
92+
},
93+
{
94+
label: 'List Page',
95+
items: [
96+
'listtutorial',
97+
'filteringtutorial',
98+
'listbase',
99+
'infinitelistbase',
100+
'listiterator',
101+
'filterliveform',
102+
'withlistcontext',
103+
'uselist',
104+
'uselistcontext',
105+
'uselistcontroller',
106+
'useunselect',
107+
'useunselectall',
108+
],
109+
},
110+
{
111+
label: 'Creation & Edition Pages',
112+
items: [
113+
'edittutorial',
114+
'validation',
115+
'createbase',
116+
'editbase',
117+
'form',
118+
'usecreatecontext',
119+
'usecreatecontroller',
120+
'useeditcontext',
121+
'useeditcontroller',
122+
'userecordfromlocation',
123+
'useregistermutationmiddleware',
124+
'usesavecontext',
125+
'useunique',
126+
],
127+
},
128+
{
129+
label: 'Show Page',
130+
items: ['showbase', 'useshowcontext', 'useshowcontroller'],
131+
},
132+
{
133+
label: 'Common',
134+
items: [
135+
'withrecord',
136+
'usegetrecordid',
137+
'usenotify',
138+
'userecordcontext',
139+
'useredirect',
140+
'userefresh',
141+
],
142+
},
143+
{
144+
label: 'Fields',
145+
items: [
146+
'fields',
147+
'fieldsforrelationships',
148+
'referencearrayfieldbase',
149+
'referencefieldbase',
150+
'referencemanycountbase',
151+
'referencemanyfieldbase',
152+
'referenceonefieldbase',
153+
'usefieldvalue',
154+
],
155+
},
156+
{
157+
label: 'Inputs',
158+
items: ['inputs', 'useinput'],
159+
},
160+
{
161+
label: 'Preferences',
162+
items: [
163+
'usestore',
164+
'useremovefromstore',
165+
'useresetstore',
166+
'usestorecontext',
167+
],
168+
},
169+
{
170+
label: 'I18N Provider & Translations',
171+
items: [
172+
'translationsetup',
173+
'translationlocales',
174+
'translationtranslating',
175+
'translationwriting',
176+
'translate',
177+
'uselocalestate',
178+
'usetranslate',
179+
],
180+
},
181+
{
182+
label: 'Other Components & Hooks',
183+
items: [
184+
'recordrepresentation',
185+
'usegetrecordrepresentation',
52186
],
53187
},
54188
{
55-
label: 'Reference',
56-
autogenerate: {
57-
directory: 'reference',
58-
},
189+
label: 'Recipes',
190+
items: ['caching', 'unittesting'],
59191
},
60192
],
61193
components: {
@@ -76,6 +208,7 @@ export default defineConfig({
76208
{
77209
base: '/ra-core/',
78210
collectionBase: false,
211+
trailingSlash: 'always',
79212
},
80213
],
81214
],
602 KB
Binary file not shown.
189 KB
Binary file not shown.
121 KB
Binary file not shown.
26 KB
Binary file not shown.
37.7 KB
Binary file not shown.
68.8 KB
Binary file not shown.
Binary file not shown.
File renamed without changes.

0 commit comments

Comments
 (0)