one-click-accessibility/modules/scanner/assets/js/components/resolved-message/index.js
VasylD f0dce2793e
[APP-1923][APP-1924] manage remediations, global remediations (#424)
* [APP-1923] change remediation management (#411)

* [APP-1988] Add tabs

* [APP-1988][APP-1989] add tabs, remove menu item

* [APP-1988][APP-1989] add tabs, remove menu item

* [APP-1992] add empty state and tab navigation

* [APP-1993][APP-1994] Change view for manage AI fixes, change delete confirmation modal

* [APP-1996] add view for alt text fixes

* [APP-1996] add edit for alt text fixes

* [APP-1996] add edit for alt text fixes

* [APP-1996] add edit for alt text fixes

* [APP-1996] add edit for alt text fixes

* [APP-1996] add edit for alt text fixes

* [APP-1995] Color contrast form

* [APP-2001] add global remediation logic (#415)

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2001] add global remediation logic

* [APP-2003] add disable across scans (#418)

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* [APP-2003] add disable across scans

* add logs

* add logs

* add logs

* remove logs

* remove logs

* remove logs

* remove logs

* remove logs

* remove logs

* remove logs

* remove logs

* remove logs

* remove logs

* change to theme value

* change to theme value

* change to theme value

* change to theme value

* add edit mode

* add edit mode

* add edit mode
2025-11-10 16:25:45 +07:00

66 lines
1.8 KiB
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import Button from '@elementor/ui/Button';
import Typography from '@elementor/ui/Typography';
import { BLOCKS, ROOT_ID } from '@ea11y-apps/scanner/constants';
import { useScannerWizardContext } from '@ea11y-apps/scanner/context/scanner-wizard-context';
import { useTabsContext } from '@ea11y-apps/scanner/context/tabs-context';
import { ResolvedImage } from '@ea11y-apps/scanner/images';
import {
ResolvedButtonsBox,
StateContainer,
} from '@ea11y-apps/scanner/styles/app.styles';
import { closeWidget } from '@ea11y-apps/scanner/utils/close-widget';
import { __ } from '@wordpress/i18n';
export const ResolvedMessage = () => {
const { remediations } = useScannerWizardContext();
const { tabsProps } = useTabsContext();
const handleChangeTab = (event) => {
tabsProps.onChange(event, BLOCKS.management);
};
const onClose = () => {
const widget = document.getElementById(ROOT_ID);
closeWidget(widget);
};
return (
<StateContainer sx={{ px: 4 }}>
<ResolvedImage />
<Typography variant="subtitle1" as="h3" align="center">
{__('Youre all set!', 'pojo-accessibility')}
</Typography>
<Typography variant="body2" align="center" color="text.secondary">
{__(
'This page is now issuefree. View all scans to track your progress, or review the fixes you just made.',
'pojo-accessibility',
)}
</Typography>
<ResolvedButtonsBox>
{remediations?.length > 0 && (
<Button
size="small"
variant="outlined"
color="secondary"
onClick={handleChangeTab}
>
{__('Review fixes', 'pojo-accessibility')}
</Button>
)}
<Button
href={window?.ea11yScannerData?.dashboardUrl}
size="small"
variant="contained"
color="info"
onClick={onClose}
>
{__('View all scans', 'pojo-accessibility')}
</Button>
</ResolvedButtonsBox>
</StateContainer>
);
};