Skip to content

Commit

Permalink
fix bugs of design assistant
Browse files Browse the repository at this point in the history
  • Loading branch information
Tharanidk committed Feb 28, 2025
1 parent 95cbbac commit 6d0faaa
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ const AlertDialog: React.FC<AlertDialogProps> = ({loading = false, taskStatus, s
variant="contained"
onClick={handleCreate}
sx={{ marginRight: '10px', minWidth: '120px', height: '35px', display: 'flex', gap:1, alignItems: 'center'}}
disabled={loading || taskStatus == ''}
disabled={loading || taskStatus === '' || spec === ''}
>
{intl.formatMessage({
id: 'Apis.Create.Default.APICreateDefault.create.btn',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,13 @@
* specific language governing permissions and limitations
* under the License.
*/
import React, { useEffect, useState } from 'react';
import { FormattedMessage, useIntl } from 'react-intl';
import Accordion from '@mui/material/Accordion';
import AccordionSummary from '@mui/material/AccordionSummary';
import AccordionDetails from '@mui/material/AccordionDetails';
import Tooltip from '@mui/material/Tooltip';
import Grid from '@mui/material/Grid';
import CheckCircleIcon from '@mui/icons-material/CheckCircle';
import DangerousIcon from '@mui/icons-material/Dangerous';
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';
import React, { useState } from 'react';
import { useIntl } from 'react-intl';
import AccountCircleIcon from '@mui/icons-material/AccountCircle';
import Box from '@mui/material/Box';
import { styled, alpha } from '@mui/material/styles';
import { CircularProgress, Typography } from '@mui/material';
import { Typography } from '@mui/material';
import xmlFormat from 'xml-formatter';
import Utils from 'AppData/Utils';
import CustomizedAccordions from './CustomizedAccordions';
import Button from '@mui/material/Button';
import AutoAwesomeIcon from '@mui/icons-material/AutoAwesome';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable */
/*
* Copyright (c) 2025, WSO2 LLC. (http://www.wso2.org) All Rights Reserved.
*
Expand All @@ -24,12 +23,6 @@ import { app } from 'Settings';
import { isRestricted } from 'AppData/AuthManager';
import { styled } from '@mui/material/styles';

const PREFIX = 'DesignAssistantMenu';

const classes = {
root: `${PREFIX}-root`,
};

const StyledBox = styled(Box)(({ theme }) => ({
[`&`]: {
display: 'flex',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ function TopMenu(props) {
/>
</APICreateMenu>
)}
{/* Button to Create API with AI */}
{!query && !isAPIProduct && (
<Button

Check failure on line 196 in portals/publisher/src/main/webapp/source/src/app/components/Apis/Listing/components/TopMenu.jsx

View workflow job for this annotation

GitHub Actions / build-carbon

Expected indentation of 24 spaces but found 20
variant='contained'

Check failure on line 197 in portals/publisher/src/main/webapp/source/src/app/components/Apis/Listing/components/TopMenu.jsx

View workflow job for this annotation

GitHub Actions / build-carbon

Expected indentation of 28 spaces but found 24
color='primary'

Check failure on line 198 in portals/publisher/src/main/webapp/source/src/app/components/Apis/Listing/components/TopMenu.jsx

View workflow job for this annotation

GitHub Actions / build-carbon

Expected indentation of 28 spaces but found 24
Expand All @@ -210,7 +210,8 @@ function TopMenu(props) {
src={`${app.context}/site/public/images/ai/DesignAssistant.svg`}
style={{ marginLeft: 8, width: 15, height: 15 }}
/>
</Button>
</Button>
)}
</div>
{showToggle && (
<Box height={32} m='auto' mr={8}>
Expand Down

0 comments on commit 6d0faaa

Please sign in to comment.