chore: harmonized all button sizes in settings (#21457)

This commit is contained in:
Lucas Boilly 2024-09-25 03:18:18 -05:00 committed by GitHub
parent 55dabf6295
commit 927824c76d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 4 additions and 8 deletions

View File

@ -11,6 +11,7 @@ import {
TextInput,
Typography,
} from '@strapi/design-system';
import { Check } from '@strapi/icons';
import { format } from 'date-fns';
import { Formik, Form, FormikHelpers } from 'formik';
import { useIntl } from 'react-intl';
@ -197,14 +198,13 @@ const CreatePage = () => {
handleReset();
permissionsRef.current?.resetForm();
}}
size="L"
>
{formatMessage({
id: 'app.components.Button.reset',
defaultMessage: 'Reset',
})}
</Button>
<Button type="submit" loading={isSubmitting} size="L">
<Button type="submit" loading={isSubmitting} startIcon={<Check />}>
{formatMessage({
id: 'global.save',
defaultMessage: 'Save',

View File

@ -1,6 +1,7 @@
import * as React from 'react';
import { Box, Button, Flex, Main } from '@strapi/design-system';
import { Check } from '@strapi/icons';
import { Formik, FormikHelpers } from 'formik';
import { useIntl } from 'react-intl';
import { Navigate, useMatch } from 'react-router-dom';
@ -191,9 +192,9 @@ const EditPage = () => {
<Flex gap={2}>
<Button
type="submit"
startIcon={<Check />}
disabled={role.code === 'strapi-super-admin'}
loading={isSubmitting}
size="L"
>
{formatMessage({
id: 'global.save',

View File

@ -191,7 +191,6 @@ const EditPage = () => {
startIcon={<Check />}
loading={isSubmitting}
type="submit"
size="L"
>
{formatMessage({ id: 'global.save', defaultMessage: 'Save' })}
</Button>

View File

@ -98,7 +98,6 @@ const WebhookForm = ({
variant="tertiary"
startIcon={<Publish />}
disabled={isCreating || isTriggering}
size="L"
>
{formatMessage({
id: 'Settings.webhooks.trigger',
@ -108,7 +107,6 @@ const WebhookForm = ({
<Button
startIcon={<Check />}
type="submit"
size="L"
disabled={!modified}
loading={isSubmitting}
>

View File

@ -144,7 +144,6 @@ export const SingleSignOnPage = () => {
loading={isSubmitting}
startIcon={<Check />}
type="submit"
size="L"
>
{formatMessage({
id: 'global.save',

View File

@ -335,7 +335,6 @@ const EditPage = () => {
<Button
startIcon={<Check />}
type="submit"
size="M"
disabled={!modified || isSubmitting || values.stages.length === 0}
// if the confirm dialog is open the loading state is on
// the confirm button already