Skip to content

Commit 18948ab

Browse files
committed
chore: update DS version to stable
1 parent cb374d6 commit 18948ab

File tree

95 files changed

+547
-385
lines changed

Some content is hidden

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

95 files changed

+547
-385
lines changed

examples/plugins/todo-example/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"@strapi/strapi": "workspace:*"
2828
},
2929
"dependencies": {
30-
"@strapi/design-system": "2.0.0-rc.30",
30+
"@strapi/design-system": "2.0.1",
3131
"@strapi/icons": "2.0.0-rc.30",
3232
"eslint": "8.50.0",
3333
"react": "^18.0.0",

packages/core/admin/admin/src/components/tests/SearchInput.test.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ describe('SearchInput', () => {
2525

2626
await user.click(getByRole('button', { name: 'Search' }));
2727

28-
expect(getByRole('textbox', { name: 'Search label' })).toBeInTheDocument();
28+
expect(getByRole('searchbox', { name: 'Search label' })).toBeInTheDocument();
2929
});
3030

3131
it('should push value to query params', async () => {
@@ -44,7 +44,7 @@ describe('SearchInput', () => {
4444

4545
await user.click(getByRole('button', { name: 'Search' }));
4646

47-
await user.type(getByRole('textbox', { name: 'Search label' }), 'michka');
47+
await user.type(getByRole('searchbox', { name: 'Search label' }), 'michka');
4848

4949
await user.keyboard('[Enter]');
5050

@@ -71,15 +71,15 @@ describe('SearchInput', () => {
7171

7272
await user.click(getByRole('button', { name: 'Search' }));
7373

74-
await user.type(getByRole('textbox', { name: 'Search label' }), 'michka');
74+
await user.type(getByRole('searchbox', { name: 'Search label' }), 'michka');
7575

7676
await user.keyboard('[Enter]');
7777

7878
expect(new URLSearchParams(getByRole('listitem').textContent ?? '').has('_q')).toBe(true);
7979

8080
await user.click(getByRole('button', { name: 'Clear' }));
8181

82-
expect(getByRole('textbox', { name: 'Search label' })).toHaveValue('');
82+
expect(getByRole('searchbox', { name: 'Search label' })).toHaveValue('');
8383

8484
expect(new URLSearchParams(getByRole('listitem').textContent ?? '').has('_q')).toBe(false);
8585
});
@@ -102,7 +102,7 @@ describe('SearchInput', () => {
102102
// Open the search input
103103
await user.click(getByRole('button', { name: 'Search' }));
104104

105-
const textbox = getByRole('textbox', { name: 'Search label' });
105+
const textbox = getByRole('searchbox', { name: 'Search label' });
106106
expect(textbox).toBeInTheDocument();
107107

108108
// Type the value if any
@@ -117,9 +117,9 @@ describe('SearchInput', () => {
117117
// Check visibility
118118
await waitFor(() => {
119119
if (expectedToBeInDocument) {
120-
expect(getByRole('textbox', { name: 'Search label' })).toBeInTheDocument();
120+
expect(getByRole('searchbox', { name: 'Search label' })).toBeInTheDocument();
121121
} else {
122-
expect(queryByRole('textbox', { name: 'Search label' })).not.toBeInTheDocument();
122+
expect(queryByRole('searchbox', { name: 'Search label' })).not.toBeInTheDocument();
123123
}
124124
});
125125
});

packages/core/admin/admin/src/pages/Auth/components/Register.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -481,7 +481,13 @@ const Register = ({ hasAdmin }: RegisterProps) => {
481481
type: 'checkbox' as const,
482482
},
483483
].map(({ size, ...field }) => (
484-
<Grid.Item key={field.name} col={size} direction="column" alignItems="stretch">
484+
<Grid.Item
485+
key={field.name}
486+
xs={12}
487+
m={size}
488+
direction="column"
489+
alignItems="stretch"
490+
>
485491
<InputRenderer {...field} />
486492
</Grid.Item>
487493
))}

packages/core/admin/admin/src/pages/Home/HomePage.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ const HomePageCE = () => {
229229
canResize,
230230
}) => (
231231
<React.Fragment key={widget.uid}>
232-
<Grid.Item col={widgetWidth} s={12}>
232+
<Grid.Item col={widgetWidth} xs={12}>
233233
<WidgetRoot
234234
uid={widget.uid}
235235
title={widget.title}

packages/core/admin/admin/src/pages/ProfilePage.tsx

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,14 @@ const PasswordSection = () => {
294294
].map((row, index) => (
295295
<Grid.Root key={index} gap={5}>
296296
{row.map(({ size, ...field }) => (
297-
<Grid.Item key={field.name} col={size} direction="column" alignItems="stretch">
297+
<Grid.Item
298+
key={field.name}
299+
xs={12}
300+
m={6}
301+
col={size}
302+
direction="column"
303+
alignItems="stretch"
304+
>
298305
<InputRenderer {...field} />
299306
</Grid.Item>
300307
))}
@@ -416,7 +423,14 @@ const PreferencesSection = ({ localeNames }: PreferencesSectionProps) => {
416423
type: 'enumeration' as const,
417424
},
418425
].map(({ size, ...field }) => (
419-
<Grid.Item key={field.name} col={size} direction="column" alignItems="stretch">
426+
<Grid.Item
427+
key={field.name}
428+
xs={12}
429+
m={6}
430+
col={size}
431+
direction="column"
432+
alignItems="stretch"
433+
>
420434
<InputRenderer {...field} />
421435
</Grid.Item>
422436
))}
@@ -481,7 +495,14 @@ const UserInfoSection = () => {
481495
type: 'string' as const,
482496
},
483497
].map(({ size, ...field }) => (
484-
<Grid.Item key={field.name} col={size} direction="column" alignItems="stretch">
498+
<Grid.Item
499+
key={field.name}
500+
xs={12}
501+
m={6}
502+
col={size}
503+
direction="column"
504+
alignItems="stretch"
505+
>
485506
<InputRenderer {...field} />
486507
</Grid.Item>
487508
))}

packages/core/admin/admin/src/pages/Settings/pages/ApiTokens/EditView/components/ActionBoundRoutes.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ export const ActionBoundRoutes = () => {
1414

1515
return (
1616
<Grid.Item
17+
xs={12}
18+
m={5}
1719
col={5}
1820
background="neutral150"
1921
paddingTop={6}

packages/core/admin/admin/src/pages/Settings/pages/ApiTokens/EditView/components/CollapsableContentType.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,8 @@ export const CollapsableContentType = ({
115115
controller?.actions.map((action) => {
116116
return (
117117
<Grid.Item
118-
col={6}
118+
xs={12}
119+
s={6}
119120
key={action.actionId}
120121
direction="column"
121122
alignItems="stretch"

packages/core/admin/admin/src/pages/Settings/pages/ApiTokens/EditView/components/FormApiTokenContainer.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,23 +91,23 @@ export const FormApiTokenContainer = ({
9191
})}
9292
</Typography>
9393
<Grid.Root gap={5}>
94-
<Grid.Item key="name" col={6} xs={12} direction="column" alignItems="stretch">
94+
<Grid.Item key="name" m={6} xs={12} direction="column" alignItems="stretch">
9595
<TokenName
9696
error={errors['name']}
9797
value={values['name']}
9898
canEditInputs={canEditInputs}
9999
onChange={onChange}
100100
/>
101101
</Grid.Item>
102-
<Grid.Item key="description" col={6} xs={12} direction="column" alignItems="stretch">
102+
<Grid.Item key="description" m={6} xs={12} direction="column" alignItems="stretch">
103103
<TokenDescription
104104
error={errors['description']}
105105
value={values['description']}
106106
canEditInputs={canEditInputs}
107107
onChange={onChange}
108108
/>
109109
</Grid.Item>
110-
<Grid.Item key="lifespan" col={6} xs={12} direction="column" alignItems="stretch">
110+
<Grid.Item key="lifespan" m={6} xs={12} direction="column" alignItems="stretch">
111111
<LifeSpanInput
112112
isCreating={isCreating}
113113
error={errors['lifespan']}
@@ -117,7 +117,7 @@ export const FormApiTokenContainer = ({
117117
/>
118118
</Grid.Item>
119119

120-
<Grid.Item key="type" col={6} xs={12} direction="column" alignItems="stretch">
120+
<Grid.Item key="type" m={6} xs={12} direction="column" alignItems="stretch">
121121
<TokenTypeSelect
122122
value={values['type']}
123123
error={errors['type']}

packages/core/admin/admin/src/pages/Settings/pages/ApiTokens/EditView/components/Permissions.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ export const Permissions = ({ ...props }) => {
1515
return (
1616
<Grid.Root gap={0} shadow="filterShadow" hasRadius background="neutral0">
1717
<Grid.Item
18+
xs={12}
1819
col={7}
1920
paddingTop={6}
2021
paddingBottom={6}

packages/core/admin/admin/src/pages/Settings/pages/ApplicationInfo/ApplicationInfoPage.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ const ApplicationInfoPage = () => {
172172
</Typography>
173173

174174
<Grid.Root gap={5} tag="dl">
175-
<Grid.Item col={6} s={12} direction="column" alignItems="start">
175+
<Grid.Item col={6} xs={12} direction="column" alignItems="start">
176176
<Typography variant="sigma" textColor="neutral600" tag="dt">
177177
{formatMessage({
178178
id: 'Settings.application.strapiVersion',
@@ -194,7 +194,7 @@ const ApplicationInfoPage = () => {
194194
)}
195195
</Flex>
196196
</Grid.Item>
197-
<Grid.Item col={6} s={12} direction="column" alignItems="start">
197+
<Grid.Item col={6} xs={12} direction="column" alignItems="start">
198198
<Typography variant="sigma" textColor="neutral600" tag="dt">
199199
{formatMessage({
200200
id: 'Settings.application.edition-title',
@@ -221,7 +221,7 @@ const ApplicationInfoPage = () => {
221221
</Flex>
222222
</Grid.Item>
223223

224-
<Grid.Item col={6} s={12} direction="column" alignItems="start">
224+
<Grid.Item col={6} xs={12} direction="column" alignItems="start">
225225
<Typography variant="sigma" textColor="neutral600" tag="dt">
226226
{formatMessage({
227227
id: 'Settings.application.node-version',
@@ -261,7 +261,7 @@ const ApplicationInfoPage = () => {
261261
)}
262262
</Typography>
263263
<Grid.Root paddingTop={4} gap={4}>
264-
<Grid.Item col={6} s={12} direction="column" alignItems="stretch">
264+
<Grid.Item col={6} xs={12} direction="column" alignItems="stretch">
265265
<LogoInput
266266
canUpdate={canUpdate}
267267
customLogo={logos.menu.custom}
@@ -277,7 +277,7 @@ const ApplicationInfoPage = () => {
277277
onChangeLogo={handleChangeLogo('menu')}
278278
/>
279279
</Grid.Item>
280-
<Grid.Item col={6} s={12} direction="column" alignItems="stretch">
280+
<Grid.Item col={6} xs={12} direction="column" alignItems="stretch">
281281
<LogoInput
282282
canUpdate={canUpdate}
283283
customLogo={logos.auth.custom}

0 commit comments

Comments
 (0)