Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
105 commits
Select commit Hold shift + click to select a range
f0fdd4c
Fix: Expose contexts in DataTable loading and empty states
dreglad Feb 1, 2026
8d9b5c4
Fix ArrayInput root error display on conditional mount
WiXSL Mar 19, 2026
91c8f11
Fix ArrayInput subscribe typing
WiXSL Mar 19, 2026
75517d9
Fix ArrayInput state typing
WiXSL Mar 19, 2026
c4d471e
Update packages/ra-ui-materialui/src/input/ArrayInput/ArrayInput.stor…
WiXSL Mar 20, 2026
756d0cf
Update react-hook-form to 7.72.0
WiXSL Mar 23, 2026
8e62836
Use subscribe submit state in ArrayInput
WiXSL Mar 23, 2026
791e742
Fix FilterLiveForm types for RHF 7.72.0
WiXSL Mar 23, 2026
1710f8c
Refine ArrayInput story and spec
WiXSL Mar 23, 2026
9a95888
Fix ArrayInput spec lint
WiXSL Mar 23, 2026
6398977
Limit test workflow token permissions
WiXSL Mar 31, 2026
a508374
Escape backslashes in escapePath
WiXSL Mar 31, 2026
a3d7895
Fix RichTextField code scanning issues
WiXSL Mar 31, 2026
3054296
Avoid ReDoS in FormDataConsumer source detection
WiXSL Mar 31, 2026
e8417d9
Merge pull request #11223 from marmelab/fix-test-workflow-permissions
slax57 Mar 31, 2026
92b4c55
Merge pull request #11226 from marmelab/fix-escape-path-escaping
slax57 Mar 31, 2026
4e4e898
Merge pull request #11225 from marmelab/fix-rich-text-field-code-scan…
slax57 Mar 31, 2026
b039b06
Address review comment on array source check
WiXSL Mar 31, 2026
39f924b
Merge pull request #11224 from marmelab/fix-form-data-consumer-redos
slax57 Mar 31, 2026
8f3e3cd
Merge remote-tracking branch 'origin/master' into arrayinput-onchange…
slax57 Apr 1, 2026
1607b9c
yarn dedupe
slax57 Apr 1, 2026
ff5fd3f
exclude exported inner component from stories
slax57 Apr 1, 2026
f19351d
Merge pull request #11195 from marmelab/arrayinput-onchange-validation
slax57 Apr 1, 2026
5a4f235
Bump lodash-es from 4.17.23 to 4.18.1
dependabot[bot] Apr 2, 2026
fb3fc13
Merge pull request #11228 from marmelab/dependabot/npm_and_yarn/lodas…
slax57 Apr 2, 2026
d4ecaf8
Avoid prototype-polluting assignments in local data providers
WiXSL Mar 31, 2026
78398c4
Use splice for local data provider updates
WiXSL Mar 31, 2026
7a165e5
Guard local data provider mutations against missing ids
WiXSL Mar 31, 2026
581824a
Simplify local data provider resource guard
WiXSL Mar 31, 2026
4324ddd
Format local data provider resource guards
WiXSL Mar 31, 2026
244dc5a
better type
ThieryMichel Apr 1, 2026
6fb4155
code review
ThieryMichel Apr 2, 2026
3592005
update Agents.md
ThieryMichel Apr 2, 2026
546c62e
Bump lodash from 4.17.23 to 4.18.1
dependabot[bot] Apr 2, 2026
7245371
update test
ThieryMichel Apr 3, 2026
de4689c
revert dataprovider
ThieryMichel Apr 3, 2026
fa98b0c
add more tests
ThieryMichel Apr 3, 2026
6c2c632
revert unrelated change
ThieryMichel Apr 3, 2026
612dbf6
dedupe lodash
slax57 Apr 3, 2026
73b0971
Merge pull request #11229 from marmelab/dependabot/npm_and_yarn/lodas…
slax57 Apr 3, 2026
a93706d
Merge pull request #11227 from marmelab/fix-local-data-provider-proto…
ThieryMichel Apr 3, 2026
8ca85c8
Bump defu from 6.1.4 to 6.1.6
dependabot[bot] Apr 4, 2026
ed85f34
Merge pull request #11230 from marmelab/dependabot/npm_and_yarn/defu-…
fzaninotto Apr 5, 2026
354731a
Bump vite from 7.3.1 to 7.3.2
dependabot[bot] Apr 6, 2026
5f505e7
Merge pull request #11234 from marmelab/dependabot/npm_and_yarn/vite-…
fzaninotto Apr 7, 2026
13b7667
test: cover empty state with permanent filters
terminalchai Apr 8, 2026
5f07fa6
Bump axios from 1.13.6 to 1.15.0
dependabot[bot] Apr 12, 2026
b49f652
fix: Prevent duplicate IDs in FieldToggle when multiple column picker…
Yashrajsingh2001 Apr 12, 2026
33db516
Merge pull request #11237 from marmelab/dependabot/npm_and_yarn/axios…
fzaninotto Apr 15, 2026
c3b3e70
Bump follow-redirects from 1.15.11 to 1.16.0
dependabot[bot] Apr 15, 2026
995d8dd
Merge pull request #11240 from marmelab/dependabot/npm_and_yarn/follo…
fzaninotto Apr 15, 2026
5221ea8
Merge pull request #11238 from Yashrajsingh2001/fix/field-toggle-dupl…
fzaninotto Apr 17, 2026
326e1b9
v5.14.6
fzaninotto Apr 21, 2026
2d8dcf6
Update changelog for version 5.14.6
fzaninotto Apr 21, 2026
0b1ed97
Bump dompurify from 3.3.2 to 3.4.0
dependabot[bot] Apr 21, 2026
ef95fad
Merge pull request #11245 from marmelab/dependabot/npm_and_yarn/dompu…
fzaninotto Apr 21, 2026
29fdb3e
Merge pull request #11235 from terminalchai/fix/list-empty-permanent-…
fzaninotto Apr 28, 2026
5ad5778
Fix typos in the RichTextInput docs (#11250)
fengfeng-zi Apr 29, 2026
58db0e5
Bump ip-address from 10.1.0 to 10.2.0
dependabot[bot] May 7, 2026
e023736
Merge pull request #11251 from marmelab/dependabot/npm_and_yarn/ip-ad…
fzaninotto May 7, 2026
e6bddad
Bump axios from 1.15.0 to 1.16.0
dependabot[bot] May 7, 2026
835716e
Merge pull request #11252 from marmelab/dependabot/npm_and_yarn/axios…
fzaninotto May 7, 2026
c0ace97
Bump postcss from 8.5.6 to 8.5.14
dependabot[bot] May 7, 2026
6d1197a
Merge pull request #11253 from marmelab/dependabot/npm_and_yarn/postc…
fzaninotto May 7, 2026
45b47f7
fix: Update AutocompleteInput immediately when re-selecting the same …
May 8, 2026
f71707e
Bump fast-uri from 3.1.0 to 3.1.2
dependabot[bot] May 8, 2026
0a71bdb
Merge pull request #11255 from marmelab/dependabot/npm_and_yarn/fast-…
fzaninotto May 9, 2026
14e887e
Bump @babel/plugin-transform-modules-systemjs from 7.29.0 to 7.29.4
dependabot[bot] May 9, 2026
fe80bf3
Merge pull request #11256 from marmelab/dependabot/npm_and_yarn/babel…
fzaninotto May 9, 2026
1e22cd3
Bump systeminformation from 5.31.1 to 5.31.6
dependabot[bot] May 13, 2026
c94506e
Bump devalue from 5.6.4 to 5.8.1
dependabot[bot] May 14, 2026
ba76aad
Merge pull request #11260 from marmelab/dependabot/npm_and_yarn/deval…
fzaninotto May 15, 2026
ea35487
Bump astro from 5.18.1 to 6.1.10
dependabot[bot] May 15, 2026
9be13cb
Fix(AutocompleteInput): do not open autocomplete options when shouldR…
jonathanarnault May 18, 2026
2647119
[typeScript] Fix ArrayField doesn't accept a label prop
fzaninotto May 18, 2026
b197442
Merge pull request #11264 from marmelab/fix-array-field
fzaninotto May 18, 2026
588e54f
Merge pull request #11258 from marmelab/dependabot/npm_and_yarn/syste…
fzaninotto May 18, 2026
cb320e2
Apply review
jonathanarnault May 18, 2026
6e0c663
Merge pull request #11263 from marmelab/fix/3166-autocomplete-suggest…
fzaninotto May 18, 2026
898d81b
v5.14.7
fzaninotto May 18, 2026
93ff911
Update changelog for version 5.14.7
fzaninotto May 18, 2026
d3d656f
Add missing mention
fzaninotto May 18, 2026
2fa3ac6
test: Add story for AutocompleteInput re-selection with filterSelecte…
May 18, 2026
e227990
test: Use FilterSelectedOptionsFalse story in AutocompleteInput spec
May 18, 2026
52dec3f
Fix(ArrayInput): display validation error when validation is performe…
jonathanarnault May 19, 2026
827e5be
WPO
fzaninotto May 20, 2026
dfb6d7a
WPO: fix critical path
fzaninotto May 20, 2026
b1d8537
use swap font
fzaninotto May 20, 2026
c4dd022
Bump @tootallnate/once from 2.0.0 to 2.0.1
dependabot[bot] May 22, 2026
d029caf
Do not index old versions
fzaninotto May 22, 2026
b3af0f3
Merge pull request #11267 from marmelab/dependabot/npm_and_yarn/toota…
fzaninotto May 27, 2026
01b4c01
Bump tmp from 0.2.5 to 0.2.6
dependabot[bot] May 27, 2026
2daf09a
Merge pull request #11269 from marmelab/dependabot/npm_and_yarn/tmp-0…
fzaninotto May 27, 2026
210cad6
ignore vercel build on branches
fzaninotto May 28, 2026
1b355a4
Merge pull request #11265 from marmelab/fix/3167-wizard-form
fzaninotto May 28, 2026
15c6b39
Fix docs_headless dependencies for Astro 6
Copilot May 28, 2026
7f01cb3
Update docs_headless Astro integrations for v6
Copilot May 28, 2026
5786231
Merge pull request #11259 from marmelab/dependabot/npm_and_yarn/astro…
fzaninotto May 28, 2026
6c819c2
Merge pull request #11254 from smeng9/fix/autocomplete-input-reselect…
fzaninotto May 28, 2026
3d98dc9
Fix tests
fzaninotto May 28, 2026
73d0bbb
Merge pull request #11144 from dreglad/ra-core_DataTableBase-contexts
fzaninotto May 28, 2026
8e36f84
Update Node.js version to 22 in deploy headless docs workflow
fzaninotto May 28, 2026
b3b2f2c
[TypeScript] Fix compilation with react-hook-form 7.72.0
fzaninotto Jun 9, 2026
b6dd624
Merge pull request #11273 from marmelab/react-hook-form-7-72
fzaninotto Jun 9, 2026
13f405a
feat: Add emptyText prop to SelectArrayInput
Gdhanush-13 Jun 16, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/deploy-doc-headless.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- name: ⚙️ Setup node
uses: actions/setup-node@v4
with:
node-version: 20
node-version: 22
cache: yarn

- name: ⚙️ Setup git
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ on:
- '*'
pull_request:

permissions:
contents: read

jobs:
typecheck:
runs-on: ubuntu-latest
Expand Down
4 changes: 3 additions & 1 deletion Agents.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ React-admin is a comprehensive frontend framework for building B2B and admin app
- No children inspection — violates React patterns (exception: Datagrid)
- No features achievable in pure React — keep the API surface small
- No comments when code is self-explanatory
- No dead code — trust your preconditions. Don't guard against conditions that prior code already prevents
- DRY — don't duplicate knowledge. Coincidental code similarity is not duplication. Only deduplicate when the same decision or fact is expressed in multiple places. Code that looks alike but could evolve independently should stay separate

## Codebase Organization

Expand Down Expand Up @@ -83,4 +85,4 @@ Every new feature or API change must be documented.
make lint # ESLint checks
make typecheck # TypeScript type checking
make prettier # Prettier formatting
```
```
31 changes: 31 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,36 @@
# Changelog

## 5.14.7

* Fix `AutocompleteInput` does not open autocomplete options when `shouldRenderSuggestions` returns false ([#11263](https://github.com/marmelab/react-admin/pull/11263)) ([jonathanarnault](https://github.com/jonathanarnault))
* [Doc] Fix typos in the `RichTextInput` docs ([#11250](https://github.com/marmelab/react-admin/pull/11250)) ([fengfeng-zi](https://github.com/fengfeng-zi))
* [TypeScript] Fix `ArrayField` doesn't accept a label prop ([#11264](https://github.com/marmelab/react-admin/pull/11264)) ([fzaninotto](https://github.com/fzaninotto))
* [Chore] Add tests to cover `List` empty state with permanent filters ([#11235](https://github.com/marmelab/react-admin/pull/11235)) ([terminalchai](https://github.com/terminalchai))
* Bump devalue from 5.6.4 to 5.8.1 ([#11260](https://github.com/marmelab/react-admin/pull/11260)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump systeminformation from 5.31.1 to 5.31.6 ([#11258](https://github.com/marmelab/react-admin/pull/11258)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump @babel/plugin-transform-modules-systemjs from 7.29.0 to 7.29.4 ([#11256](https://github.com/marmelab/react-admin/pull/11256)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump fast-uri from 3.1.0 to 3.1.2 ([#11255](https://github.com/marmelab/react-admin/pull/11255)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump postcss from 8.5.6 to 8.5.14 ([#11253](https://github.com/marmelab/react-admin/pull/11253)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump axios from 1.15.0 to 1.16.0 ([#11252](https://github.com/marmelab/react-admin/pull/11252)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump ip-address from 10.1.0 to 10.2.0 ([#11251](https://github.com/marmelab/react-admin/pull/11251)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump dompurify from 3.3.2 to 3.4.0 ([#11245](https://github.com/marmelab/react-admin/pull/11245)) ([dependabot[bot]](https://github.com/apps/dependabot))

## 5.14.6

* Fix possible prototype-polluting assignments in local data providers ([#11227](https://github.com/marmelab/react-admin/pull/11227)) ([WiXSL](https://github.com/WiXSL))
* Fix duplicate IDs in `<FieldToggle>` when multiple column pickers are present ([#11238](https://github.com/marmelab/react-admin/pull/11238)) ([Yashrajsingh2001](https://github.com/Yashrajsingh2001))
* Fix incomplete string escaping in `escapePath` ([#11226](https://github.com/marmelab/react-admin/pull/11226)) ([WiXSL](https://github.com/WiXSL))
* Fix `<FormDataConsumer>` to avoid ReDoS in source detection ([#11224](https://github.com/marmelab/react-admin/pull/11224)) ([WiXSL](https://github.com/WiXSL))
* Fix `<RichTextField>` tag-stripping feature is polynomial and does not strip unfinished tags ([#11225](https://github.com/marmelab/react-admin/pull/11225)) ([WiXSL](https://github.com/WiXSL))
* Fix `<ArrayInput>` shows validation error on mount when `mode="onChange"` ([#11195](https://github.com/marmelab/react-admin/pull/11195)) ([WiXSL](https://github.com/WiXSL))
* Bump follow-redirects from 1.15.11 to 1.16.0 ([#11240](https://github.com/marmelab/react-admin/pull/11240)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump axios from 1.13.6 to 1.15.0 ([#11237](https://github.com/marmelab/react-admin/pull/11237)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump vite from 7.3.1 to 7.3.2 ([#11234](https://github.com/marmelab/react-admin/pull/11234)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump defu from 6.1.4 to 6.1.6 ([#11230](https://github.com/marmelab/react-admin/pull/11230)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump lodash from 4.17.23 to 4.18.1 ([#11229](https://github.com/marmelab/react-admin/pull/11229)) ([dependabot[bot]](https://github.com/apps/dependabot))
* Bump lodash-es from 4.17.23 to 4.18.1 ([#11228](https://github.com/marmelab/react-admin/pull/11228)) ([dependabot[bot]](https://github.com/apps/dependabot))
* [chore] Restrict test workflow token permissions ([#11223](https://github.com/marmelab/react-admin/pull/11223)) ([WiXSL](https://github.com/WiXSL))

## 5.14.5

* Add ArrayFieldBase component ([#11191](https://github.com/marmelab/react-admin/pull/11191)) ([WiXSL](https://github.com/WiXSL))
Expand Down
4 changes: 2 additions & 2 deletions docs/RichTextInput.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,9 @@ export const MyEditorOptions = {

## `toolbar`

The `<RichTextInput>` component has a `toolbar` prop that accepts a `ReactNode`. But default, it uses the `<RichTextInputToolbar>` component.
The `<RichTextInput>` component has a `toolbar` prop that accepts a `ReactNode`. By default, it uses the `<RichTextInputToolbar>` component.

You can leverage the `tollbar` prop to change the buttons size:
You can leverage the `toolbar` prop to change the buttons size:

```jsx
import { Edit, SimpleForm, TextInput } from 'react-admin';
Expand Down
20 changes: 20 additions & 0 deletions docs/SelectArrayInput.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ The form value for the source must be an array of the selected values, e.g.
| `create` | Optional | `Element` | - | A React Element to render when users want to create a new choice |
| `createLabel` | Optional | `string` &#124; `ReactNode` | `ra.action. create` | The label for the menu item allowing users to create a new choice. Used when the filter is empty |
| `disableValue` | Optional | `string` | 'disabled' | The custom field name used in `choices` to disable some choices |
| `emptyText` | Optional | `string` &#124; `ReactNode` | - | Text to display when no choice is selected |
| `InputLabelProps` | Optional | `Object` | - | Props to pass to the underlying `<InputLabel>` element |
| `onCreate` | Optional | `Function` | - | A function called with the current filter value when users choose to create a new choice. |
| `options` | Optional | `Object` | - | Props to pass to the underlying `<SelectInput>` element |
Expand Down Expand Up @@ -111,6 +112,25 @@ You can also use an array of objects with different properties for the label and
]} optionValue="_id" optionText="label" />
```

## `emptyText`

You can customize the text displayed when no choice is selected using the `emptyText` prop:

```jsx
const channelChoices = [
{id: "email", name: "Email"},
{id: "push", name: "Push Notification"},
];

<SelectArrayInput source="channels" choices={channelChoices} emptyText="All Channels" />
```

The `emptyText` prop also accepts React elements:

```jsx
<SelectArrayInput source="channels" choices={channelChoices} emptyText={<i>All Channels</i>} />
```

The choices are translated by default, so you can use translation identifiers as choices:

```jsx
Expand Down
79 changes: 72 additions & 7 deletions docs/_layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
<head>
<title>React-admin - {{ page.title }}</title>
<meta charset="UTF-8" />
{% if page.dir contains "doc" %}
<meta name="robots" content="noindex" />
{% endif %}
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<meta name="description" content="{{ page.description }}" />
Expand All @@ -15,6 +18,9 @@
rel="canonical"
href="{{ page.name | replace: '.md', '.html' | relative_url }}"
/>
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link rel="preconnect" href="https://assets.brevo.com" crossorigin />
<link rel="preconnect" href="https://www.youtube-nocookie.com" />
<link
rel="stylesheet"
href="{{ '/css/materialize.min.css' | relative_url }}"
Expand All @@ -23,32 +29,89 @@
rel="stylesheet"
href="{{ '/css/style-v22.css' | relative_url }}"
/>
<link rel="stylesheet" href="{{ '/css/syntax.css' | relative_url }}" />
<link rel="stylesheet" href="{{ '/css/prism.css' | relative_url }}" />
<link rel="stylesheet" href="{{ '/css/tocbot.css' | relative_url }}" />
<link
rel="stylesheet"
href="https://fonts.googleapis.com/icon?family=Material+Icons"
href="{{ '/css/syntax.css' | relative_url }}"
media="print"
onload="this.media='all'"
/>
<link
rel="stylesheet"
href="{{ '/css/prism.css' | relative_url }}"
media="print"
onload="this.media='all'"
/>
<link
rel="stylesheet"
href="{{ '/css/tocbot.css' | relative_url }}"
media="print"
onload="this.media='all'"
/>
<link
rel="stylesheet"
href="https://fonts.googleapis.com/icon?family=Material+Icons&amp;display=swap"
media="print"
onload="this.media='all'"
/>
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/@docsearch/css@3"
media="print"
onload="this.media='all'"
/>
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/tocbot/4.12.0/tocbot.css"
integrity="sha512-2kqK5bWDwdrluTn6Wkj+jgiwyzvAHLirVp08Kz7kN5I8PWQ0tUtEMxfhyWDCrnws91BJ9PfrUy6ImfA7Qb22TA=="
crossorigin="anonymous"
referrerpolicy="no-referrer"
media="print"
onload="this.media='all'"
/>
<link
rel="stylesheet"
href="{{ '/css/docsearch.css' | relative_url }}"
media="print"
onload="this.media='all'"
/>
<noscript>
<link
rel="stylesheet"
href="{{ '/css/syntax.css' | relative_url }}"
/>
<link
rel="stylesheet"
href="{{ '/css/prism.css' | relative_url }}"
/>
<link
rel="stylesheet"
href="{{ '/css/tocbot.css' | relative_url }}"
/>
<link
rel="stylesheet"
href="https://fonts.googleapis.com/icon?family=Material+Icons&amp;display=swap"
/>
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/@docsearch/css@3"
/>
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/tocbot/4.12.0/tocbot.css"
/>
<link
rel="stylesheet"
href="{{ '/css/docsearch.css' | relative_url }}"
/>
<link
rel="stylesheet"
href="{{ '/css/newsletter.css' | relative_url }}"
/>
</noscript>
<!-- Newsletter form -->
<style>
@font-face {
font-display: block;
font-display: swap;
font-family: Roboto;
src:
url(https://assets.brevo.com/font/Roboto/Latin/normal/normal/7529907e9eaf8ebb5220c5f9850e3811.woff2)
Expand All @@ -58,7 +121,7 @@
}

@font-face {
font-display: fallback;
font-display: swap;
font-family: Roboto;
font-weight: 600;
src:
Expand All @@ -69,7 +132,7 @@
}

@font-face {
font-display: fallback;
font-display: swap;
font-family: Roboto;
font-weight: 700;
src:
Expand Down Expand Up @@ -100,6 +163,8 @@
<link
rel="stylesheet"
href="{{ '/css/newsletter.css' | relative_url }}"
media="print"
onload="this.media='all'"
/>
</head>

Expand Down
25 changes: 20 additions & 5 deletions docs/js/ra-doc-exec.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
/* global Prism */
import { transpileModule } from 'https://esm.sh/typescript@5.7.3';
import * as prettier from 'https://esm.sh/prettier@3.5.1/standalone';
import * as babel from 'https://esm.sh/prettier@3.5.1/plugins/babel';
import { marked } from 'https://esm.sh/marked@15.0.7';

export const showTip = async () => {
const tipContainer = document.getElementById('tip-container');
const tipElement = document.getElementById('tip');
if (!tipElement) return;

const [tips, features] = await Promise.all([
const [{ marked }, tips, features] = await Promise.all([
import('https://esm.sh/marked@15.0.7'),
getContents('./assets/tips.md_ignore'),
getContents('./assets/features.md_ignore'),
]);
Expand Down Expand Up @@ -94,7 +91,25 @@ const applyPreferredLanguage = async () => {
);
};

let transpilerPromise;
const loadTranspiler = () => {
if (!transpilerPromise) {
transpilerPromise = Promise.all([
import('https://esm.sh/typescript@5.7.3'),
import('https://esm.sh/prettier@3.5.1/standalone'),
import('https://esm.sh/prettier@3.5.1/plugins/babel'),
]).then(([ts, prettier, babel]) => ({
transpileModule: ts.transpileModule,
prettier,
babel,
}));
}
return transpilerPromise;
};

const transpileToJS = async tsCode => {
const { transpileModule, prettier, babel } = await loadTranspiler();

const transpilation = transpileModule(
// Ensure blank lines are preserved
tsCode.replace(/\n\n/g, '\n/** THIS_IS_A_NEWLINE **/'),
Expand Down
14 changes: 7 additions & 7 deletions docs_headless/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@
"astro": "astro"
},
"dependencies": {
"@astrojs/mdx": "^4.3.5",
"@astrojs/react": "^4.3.1",
"@astrojs/starlight": "^0.35.3",
"@astrojs/starlight-tailwind": "^4.0.1",
"@astrojs/mdx": "^5.0.6",
"@astrojs/react": "^5.0.6",
"@astrojs/starlight": "^0.39.2",
"@astrojs/starlight-tailwind": "^5.0.0",
"@expressive-code/plugin-collapsible-sections": "^0.41.3",
"@tailwindcss/vite": "^4.1.11",
"@types/react": "^19.1.8",
"@types/react-dom": "^19.1.6",
"astro": "^5.13.7",
"astro-expressive-code": "^0.41.3",
"astro-rehype-relative-markdown-links": "^0.18.1",
"astro": "^6.1.10",
"astro-expressive-code": "^0.42.0",
"astro-rehype-relative-markdown-links": "^0.19.0",
"expressive-code-fullscreen": "^1.0.0",
"react": "^18.3.1",
"react-dom": "^18.3.1",
Expand Down
2 changes: 1 addition & 1 deletion examples/crm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"clsx": "^2.1.1",
"date-fns": "^3.6.0",
"fakerest": "^4.1.3",
"lodash": "~4.17.5",
"lodash": "~4.18.1",
"papaparse": "^5.4.1",
"ra-data-simple-rest": "^5.3.0",
"react": "^18.3.1",
Expand Down
4 changes: 2 additions & 2 deletions examples/data-generator/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "data-generator-retail",
"version": "5.14.5",
"version": "5.14.7",
"homepage": "https://github.com/marmelab/react-admin/tree/master/examples/data-generator",
"bugs": "https://github.com/marmelab/react-admin/issues",
"license": "MIT",
Expand All @@ -17,7 +17,7 @@
"date-fns": "^3.6.0"
},
"devDependencies": {
"ra-core": "^5.14.5",
"ra-core": "^5.14.7",
"typescript": "^5.1.3",
"zshy": "^0.5.0"
},
Expand Down
18 changes: 9 additions & 9 deletions examples/simple/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "simple",
"version": "5.14.5",
"version": "5.14.7",
"private": true,
"type": "module",
"scripts": {
Expand All @@ -16,16 +16,16 @@
"@tanstack/react-query-devtools": "^5.90.2",
"fakerest": "^4.1.3",
"jsonexport": "^3.2.0",
"lodash": "~4.17.5",
"ra-data-fakerest": "^5.14.5",
"ra-i18n-polyglot": "^5.14.5",
"ra-input-rich-text": "^5.14.5",
"ra-language-english": "^5.14.5",
"ra-language-french": "^5.14.5",
"lodash": "~4.18.1",
"ra-data-fakerest": "^5.14.7",
"ra-i18n-polyglot": "^5.14.7",
"ra-input-rich-text": "^5.14.7",
"ra-language-english": "^5.14.7",
"ra-language-french": "^5.14.7",
"react": "^18.3.1",
"react-admin": "^5.14.5",
"react-admin": "^5.14.7",
"react-dom": "^18.3.1",
"react-hook-form": "^7.65.0",
"react-hook-form": "^7.72.0",
"react-router": "^6.28.1",
"react-router-dom": "^6.28.1"
},
Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"packages": ["examples/data-generator", "examples/simple", "packages/*"],
"version": "5.14.5",
"version": "5.14.7",
"npmClient": "yarn",
"$schema": "node_modules/lerna/schemas/lerna-schema.json"
}
Loading