diff --git a/apps/website/pages/components/alert/code.tsx b/apps/website/pages/components/alert/code.tsx
new file mode 100644
index 0000000000..d0f75530b5
--- /dev/null
+++ b/apps/website/pages/components/alert/code.tsx
@@ -0,0 +1,19 @@
+import Head from "next/head";
+import type { ReactElement } from "react";
+import AlertPageLayout from "screens/components/alert/AlertPageLayout";
+import AlertCodePage from "screens/components/alert/code/AlertCodePage";
+
+const Code = () => {
+ return (
+ <>
+
+ Alert Code — Halstack Design System
+
+
+ >
+ );
+};
+
+Code.getLayout = (page: ReactElement) => {page};
+
+export default Code;
diff --git a/apps/website/pages/components/alert/index.tsx b/apps/website/pages/components/alert/index.tsx
index 8ababce366..a4781141d7 100644
--- a/apps/website/pages/components/alert/index.tsx
+++ b/apps/website/pages/components/alert/index.tsx
@@ -1,7 +1,7 @@
import Head from "next/head";
import type { ReactElement } from "react";
import AlertPageLayout from "screens/components/alert/AlertPageLayout";
-import AlertCodePage from "screens/components/alert/code/AlertCodePage";
+import AlertOverviewPage from "screens/components/alert/overview/AlertOverviewPage";
const Index = () => {
return (
@@ -9,13 +9,11 @@ const Index = () => {
Alert — Halstack Design System
-
+
>
);
};
-Index.getLayout = function getLayout(page: ReactElement) {
- return {page};
-};
+Index.getLayout = (page: ReactElement) => {page};
export default Index;
diff --git a/apps/website/pages/components/alert/specifications.tsx b/apps/website/pages/components/alert/specifications.tsx
deleted file mode 100644
index afbc1da802..0000000000
--- a/apps/website/pages/components/alert/specifications.tsx
+++ /dev/null
@@ -1,21 +0,0 @@
-import Head from "next/head";
-import type { ReactElement } from "react";
-import AlertPageLayout from "screens/components/alert/AlertPageLayout";
-import AlertSpecsPage from "screens/components/alert/specs/AlertSpecsPage";
-
-const Specifications = () => {
- return (
- <>
-
- Alert Specs — Halstack Design System
-
-
- >
- );
-};
-
-Specifications.getLayout = function getLayout(page: ReactElement) {
- return {page};
-};
-
-export default Specifications;
diff --git a/apps/website/pages/components/alert/usage.tsx b/apps/website/pages/components/alert/usage.tsx
deleted file mode 100644
index 2f28321624..0000000000
--- a/apps/website/pages/components/alert/usage.tsx
+++ /dev/null
@@ -1,21 +0,0 @@
-import Head from "next/head";
-import type { ReactElement } from "react";
-import AlertPageLayout from "screens/components/alert/AlertPageLayout";
-import AlertUsagePage from "screens/components/alert/usage/AlertUsagePage";
-
-const Usage = () => {
- return (
- <>
-
- Alert Usage — Halstack Design System
-
-
- >
- );
-};
-
-Usage.getLayout = function getLayout(page: ReactElement) {
- return {page};
-};
-
-export default Usage;
diff --git a/apps/website/screens/components/alert/AlertPageLayout.tsx b/apps/website/screens/components/alert/AlertPageLayout.tsx
index bdaf827c25..12bfe4ac93 100644
--- a/apps/website/screens/components/alert/AlertPageLayout.tsx
+++ b/apps/website/screens/components/alert/AlertPageLayout.tsx
@@ -6,9 +6,8 @@ import { ReactNode } from "react";
const AlertPageHeading = ({ children }: { children: ReactNode }) => {
const tabs = [
- { label: "Code", path: "/components/alert" },
- { label: "Usage", path: "/components/alert/usage" },
- { label: "Specifications", path: "/components/alert/specifications" },
+ { label: "Overview", path: "/components/alert" },
+ { label: "Code", path: "/components/alert/code" },
];
return (
@@ -17,11 +16,9 @@ const AlertPageHeading = ({ children }: { children: ReactNode }) => {
- Alert messages are meant to provide contextual feedback about important changes in the interface. They are
- used to convey essential information to the user, ensuring that critical updates or warnings are immediately
- noticeable.
+ Alert messages are meant to provide contextual feedback about important changes in the interface.
-
+
{children}
diff --git a/apps/website/screens/components/alert/code/AlertCodePage.tsx b/apps/website/screens/components/alert/code/AlertCodePage.tsx
index 4fcb17c975..a7a26fb7f8 100644
--- a/apps/website/screens/components/alert/code/AlertCodePage.tsx
+++ b/apps/website/screens/components/alert/code/AlertCodePage.tsx
@@ -160,15 +160,13 @@ const sections = [
},
];
-const AlertCodePage = () => {
- return (
-
-
-
-
-
-
- );
-};
+const AlertCodePage = () => (
+
+
+
+
+
+
+);
export default AlertCodePage;
diff --git a/apps/website/screens/components/alert/usage/AlertUsagePage.tsx b/apps/website/screens/components/alert/overview/AlertOverviewPage.tsx
similarity index 59%
rename from apps/website/screens/components/alert/usage/AlertUsagePage.tsx
rename to apps/website/screens/components/alert/overview/AlertOverviewPage.tsx
index 764f6a3d37..700c296c96 100644
--- a/apps/website/screens/components/alert/usage/AlertUsagePage.tsx
+++ b/apps/website/screens/components/alert/overview/AlertOverviewPage.tsx
@@ -11,116 +11,168 @@ import QuickNavContainerLayout from "@/common/QuickNavContainerLayout";
import DocFooter from "@/common/DocFooter";
import HeaderDescriptionCell from "@/common/HeaderDescriptionCell";
import Image from "@/common/Image";
-import banner from "./images/alert_banner.png";
-import modal from "./images/alert_modal.png";
-import inline from "./images/alert_inline.png";
+import anatomy from "./images/alert_anatomy.png";
+import banner from "./examples/banner";
+import dialog from "./examples/dialog";
+import inline from "./examples/inline";
import Link from "next/link";
import Code from "@/common/Code";
+import Example from "@/common/example/Example";
const sections = [
{
- title: "Usage",
+ title: "Introduction",
+ content: (
+ <>
+
+ Halstack's Alert component is designed to provide clear and accessible feedback to users, ensuring important
+ messages stand out within an interface. It supports different variants—info, success, warning, and
+ error—allowing teams to communicate various levels of urgency effectively. With options for dismissibility and
+ customizable content, it adapts to different use cases while maintaining consistency. Its structured design
+ enhances readability and ensures a non-intrusive yet noticeable presence.
+
+ >
+ ),
+ },
+ {
+ title: "Anatomy",
+ content: (
+ <>
+
+
+
+ Container: the structural wrapper that holds all elements of the alert, defining its size,
+ background, and layout while ensuring proper visibility within the interface.
+
+
+ Icon: a visual indicator that reinforces the alert's purpose (e.g., info, success, warning,
+ error) and helps users quickly identify the type of message
+
+
+ Title: a short, bolded text that provides a concise summary of the alert's content, making
+ it easy for users to grasp its importance at a glance.
+
+
+ Description: the detailed text within the alert that provides context or additional
+ information about the message, ensuring clarity for the user.
+
+
+ Divider: a subtle separator that visually organizes the alert's content, enhancing
+ readability and distinguishing the pagination element from the closable action.
+
+
+ Pagination: a navigation element that allows users to browse multiple alerts within the
+ same container, useful for managing sequential or grouped notifications.
+
+
+ Actions: interactive buttons placed within the alert that enable users to take relevant
+ actions in response to the message, such as dismissing, acknowledging, or navigating to further details.
+
+
+ >
+ ),
+ },
+ {
+ title: "Key interactions and features",
content: (
<>
The key characteristics of our alert component are the following:
- Visibility: alerts should be positioned in a place where it can attract the user's eye
+ Visibility: alerts should be positioned in a place where it can attract the user's eye
without too much effort, as it will convey critical messages about the system or important features.
- Concise: alert messages should use clear and straight-to-the-point language that conveys
+ Concise: alert messages should use clear and straight-to-the-point language that conveys
the message without unnecessary information, avoiding ambiguity or irrelevant details that could distract or
confuse the user.
- Relevance: the content displayed on the alert must be directly relevant to the users task
+ Relevance: the content displayed on the alert must be directly relevant to the users task
or system state.
- Actionability: the component provides clear and straightforward actions for the user to
+ Actionability: the component provides clear and straightforward actions for the user to
take in response to it, such as retrying, seeing details or dismissing the alert.
- Persistence: alerts should remain visible long enough for users to read and understand
+ Persistence: alerts should remain visible long enough for users to read and understand
them, but not so long as to become an annoyance. Allow users to dismiss alerts once they have acknowledged
them.
- Sequential display: only one alert must be visible at a time. If multiple alerts are
+ Sequential display: only one alert must be visible at a time. If multiple alerts are
triggered, subsequent alerts wait until the current alert is dismissed before appearing. This behavior
prevents alert stacking and ensures users address each alert individually.
>
),
- subSections: [
- {
- title: "Semantic alerts",
- content: (
- <>
-
- Depending on the message that the alert is showcasing, we can find four different semantic meanings of the
- component:
-
-
-
-
-
Semantic
- Description
-
-
-
-
-
-
- Information
-
-
-
- Informational messages are used exclusively to assist the user with directional or explanatory text
- about a complex or seldom used process.
-
-
-
-
-
- Warning
-
-
-
- Alert or warning messages should be displayed when there is a potential obstacle in completing a
- process as intended.
-
-
-
-
-
- Error
-
-
-
- Error messages convey a critical system problem that requires user and/or technical intervention to
- correct.
-
-
-
-
-
- Success
-
-
-
- Success messages should be used to assure user that a system calculation or data submission was
- completed correctly.
-
-
-
-
- >
- ),
- },
- ],
+ },
+ {
+ title: "Semantic modes",
+ content: (
+ <>
+
+ Depending on the message that the alert is showcasing, we can find four different semantic meanings of the
+ component:
+
+
+
+
+
Type
+ Description
+
+
+
+
+
+
+ Information
+
+
+
+ Informational messages are used exclusively to assist the user with directional or explanatory text
+ about a complex or seldom used process.
+
+
+
+
+
+ Warning
+
+
+
+ Alert or warning messages should be displayed when there is a potential obstacle in completing a process
+ as intended.
+
+
+
+
+
+ Error
+
+
+
+ Error messages convey a critical system problem that requires user and/or technical intervention to
+ correct.
+
+
+
+
+
+ Success
+
+
+
+ Success messages should be used to assure user that a system calculation or data submission was
+ completed correctly.
+
+
+
+
+ >
+ ),
},
{
title: "Variants",
@@ -135,15 +187,15 @@ const sections = [
),
subSections: [
{
- title: "Banner alert",
+ title: "Alert banner",
content: (
<>
- Displayed always below the header of the site, the banner alert is used for critical system or
+ Displayed always bellow the header of the site, the Alert banner is used for critical system or
application messages. These alerts are actionable, meaning the user can interact with the message to
resolve the issue directly from the alert itself. However, closing the message is not considered an action
and is mandatory, as the message remains visible and cannot be dismissed until addressed. Additionally, if
- there are multiple critical system messages, the banner alert allows pagination between them, ensuring
+ there are multiple critical system messages, the Alert banner allows pagination between them, ensuring
that users can manage and resolve all critical issues systematically.
@@ -151,59 +203,59 @@ const sections = [
- System disruption notification: informing users about a critical system disruption that
+ System disruption notification: informing users about a critical system disruption that
requires immediate attention, with an option to view more details or contact support.
- Security breach alert: warning users of a potential security breach, with actions to
+ Security breach alert: warning users of a potential security breach, with actions to
change passwords or review account activity.
- Critical update required: notifying users that a crucial software update is available
+ Critical update required: notifying users that a crucial software update is available
and needs to be installed to continue using the application safely.
- Payment failure notification: informing users that a recent payment has failed and
+ Payment failure notification: informing users that a recent payment has failed and
providing options to retry the payment or update billing information.
-
+
>
),
},
{
- title: "Modal alert",
+ title: "Alert dialog",
content: (
<>
- The modal alert displays important information that demands immediate user attention. It is presented with
- an overlay that blocks the rest of the interface, ensuring that the user addresses the alert before
- proceeding. Similar to other variants, the modal alert allows up to two actions, excluding the mandatory
+ The Alert dialog displays important information that demands immediate user attention. It is presented
+ with an overlay that blocks the rest of the interface, ensuring that the user addresses the alert before
+ proceeding. Similar to other variants, the Dialog Alert allows up to two actions, excluding the mandatory
close action. This variant ensures that critical information is not overlooked by requiring the user to
- interact with the modal to continue using the application.
+ interact with the dialog to continue using the application.
Use cases:
- Data loss warning: informing users that unsaved changes will be lost if they proceed
+ Data loss warning: informing users that unsaved changes will be lost if they proceed
with an action, with options to save changes or discard them.
- Permission request: requesting user permission for access to sensitive data or device
+ Permission request: requesting user permission for access to sensitive data or devide
features, with actions to grant or deny permission.
- Policy renewal reminder: notifying users that a client's insurance policy is about to
+ Policy renewal reminder: notifying users that a client's insurance policy is about to
expire, with options to renew the policy or contact support for assistance.
- Important policy update: alerting users to important changes in the terms of service or
+ Important policy update: alerting users to important changes in the terms of service or
privacy policy, requiring them to acknowledge the update before continuing.
-
+
>
),
},
@@ -212,40 +264,39 @@ const sections = [
content: (
<>
- The inline alert is displayed in a non-modal manner and is typically used within other components (such as
- within a card, table, or container). These alerts provide contextual feedback related to the component
- they are embedded in, informing the user about the status of an action. Like other alert variants, Inline
- alerts can include up to two actions, and the close action is optional. They also support pagination for
- scenarios where multiple related alerts need to be managed.
+ The Inline alert is displayed in a non-modal manner and is typically used within other components (such as
+ within a card, table, or container). These alerts Alert provide contextual feedback related to the
+ component they are embedded in, informing the user about the status of an action. Like other alert
+ variants, Inline alerts can include up to two actions, and the close action is optional. They also support
+ pagination for scenarios where multiple related alerts need to be managed.
Use cases:
- Failed API: displaying an error message within a table indicating that there was an
+ Failed API: displaying an error message within a table indicating that there was an
error fetching data from the API.
- Pending documents to be uploaded: informing the user that some documents are pending to
+ Pending documents to be uploaded: informing the user that some documents are pending to
be uploaded, with action to cancel the upload.
- Unsaved policy changes: warning users that the changes applied to a certain policy will
+ Unsaved policy changes: warning users that the changes applied to a certain policy will
be lost if they proceed to the next page, with actions to save changes or continue.
- Document upload reminder: alerting users within a policy details page that required
+ Document upload reminder: alerting users within a policy details page that required
documents are missing, with actions to upload the documents or get assistance.
-
+
>
),
},
],
},
-
{
title: "Best practices",
subSections: [
@@ -269,10 +320,10 @@ const sections = [
Alerts cannot be displayed in a stacked manner. Make sure to prioritize alerts that compete at the same
- level so the user will assess the most important one first.
+ level so the user will assess the most important one first
- Only use alerts for critical messages that require immediate attention from the user. Overusing the
+ Only use alerts for critical messages that requires immediate attention from the user. Overusing the
component can desensitize users to their importance and increase the cognitive load.
@@ -291,7 +342,7 @@ const sections = [
Visit our{" "}
-
+
Best practices for button labels
{" "}
section from our Button component to tailor the best label for each button to make labels consistent and
@@ -324,28 +375,28 @@ const sections = [
),
},
{
- title: "Best practices of each variant",
+ title: "Variant-specific best practices",
subSections: [
{
- title: "Banner alert",
+ title: "Alert banner",
content: (
- Position and visibility: banner alerts must always be placed on top of the interface,
+ Position and visibility: alert banners must always be placed on top of the interface,
right below the header of the application. This is particularly important for system-wide alerts that
impact the user's ability to interact with the application.
- Navigation: if multiple critical alerts exist, enable the option to paginate them so
+ Navigation: if multiple critical alerts exist, enable the option to paginate them so
they can assess each message one by one, in priority order.
- Persistence: keep the banner alert visible until the issue is resolved. Users should
+ Persistence: keep the Alert banner visible until the issue is resolved. Users should
not be able to dismiss it without taking action. This ensures that critical issues are addressed and
not overlooked. The persistent nature of the banner reinforces the importance of the alert.
- Clarity: use the description of the alert to briefly explain the issue, but avoid
+ Clarity: use the description of the alert to briefly explain the issue, but avoid
overloading the user with unnecessary descriptions. If further details are needed to fully understand
or assess the alert, provide a button to see the details on a separate screen.
@@ -353,23 +404,23 @@ const sections = [
),
},
{
- title: "Modal alert",
+ title: "Alert dialog",
content: (
<>
- Immediate action: use modal alert for issues that need the user’s immediate
+ Immediate action: use Alert dialog for issues that need the user's immediate
attention and action. Ensure they cannot proceed without addressing the alert. This prevents users
from ignoring critical messages and helps in timely resolution of issues.
- Clear actions: if actions are needed (besides the close action), ensure these
- actions are accurate to resolve the issue, such as “Save changes” or “View details”. Actions should
+ Clear actions: if actions are needed (besides the close action), ensure these
+ actions are accurate to resolve the issue, such as "Save changes" or "View details". Actions should
be easy to understand and immediately executable, guiding the user through the necessary steps to
resolve the alert.
- Accurate focus: each modal alert must focus on a single important message to avoid
+ Accurate focus: each dialog alert must focus on a single important message to avoid
overwhelming the user. Avoid combining multiple issues in one alert, as it can cause confusion and
reduce the effectiveness of the alert.
@@ -383,21 +434,21 @@ const sections = [
<>
- Placement: place inline alerts near the relevant content or component to provide
+ Placement: place Inline alerts near the relevant content or component to provide
immediate and contextual feedback. This helps users associate the alert with the specific action or
data that it relates to, making it more intuitive to understand and act upon.
- Non-intrusive: ensure inline alerts do not disrupt the user’s workflow but are
+ Non-intrusive: ensure Inline alerts do not disrupt the user's workflow but are
noticeable enough to provide the necessary feedback.
- Dismissive alerts: allow users to close the inline alert if it is not critical to
+ Dismissive alerts: allow users to close the Inline alert if it is not critical to
keep it visible at all times. This gives users control over their interface and prevents frustration
from persistent alerts.
- Multiple alerts handling: if multiple inline alerts are necessary, allow users to
+ Multiple alerts handling: if multiple Inline Alerts are necessary, allow users to
navigate through them. This can be achieved through the navigation option built within the
component.
@@ -411,15 +462,15 @@ const sections = [
},
];
-const AlertUsagePage = () => {
+const AlertOverviewPage = () => {
return (
-
+
);
};
-export default AlertUsagePage;
+export default AlertOverviewPage;
diff --git a/apps/website/screens/components/alert/overview/examples/banner.ts b/apps/website/screens/components/alert/overview/examples/banner.ts
new file mode 100644
index 0000000000..0ef1699d30
--- /dev/null
+++ b/apps/website/screens/components/alert/overview/examples/banner.ts
@@ -0,0 +1,67 @@
+import { DxcAlert, DxcFlex, DxcInset } from "@dxc-technology/halstack-react";
+
+const code = `() => {
+ const messagesSuccess = [
+ { text: "Your document has been saved successfully." },
+ { text: "Second text." }
+ ];
+ const messagesInformation = [
+ { text: "Your document has been auto-saved." },
+ { text: "Second text." }
+ ];
+ const messagesWarning = [
+ { text: "You have unsaved changes in your document." },
+ { text: "Second text." }
+ ];
+ const messagesError = [
+ { text: "We encountered an issue while saving your file." },
+ { text: "Second text." }
+ ];
+
+ return (
+
+
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="success"
+ title="Success"
+ />
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="info"
+ title="Information"
+ />
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="warning"
+ title="Warning"
+ />
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="error"
+ title="Error"
+ />
+
+
+ );
+}`;
+
+const scope = {
+ DxcAlert,
+ DxcInset,
+ DxcFlex,
+};
+
+export default { code, scope };
diff --git a/apps/website/screens/components/alert/overview/examples/dialog.ts b/apps/website/screens/components/alert/overview/examples/dialog.ts
new file mode 100644
index 0000000000..4e2b4c54cb
--- /dev/null
+++ b/apps/website/screens/components/alert/overview/examples/dialog.ts
@@ -0,0 +1,88 @@
+import { DxcAlert, DxcButton, DxcFlex, DxcInset } from "@dxc-technology/halstack-react";
+import { useState } from "react";
+
+const code = `() => {
+ const [loadDialog, setLoadDialog] = useState(0);
+
+ const messagesSuccess = [
+ { text: "Your document has been saved successfully.", onClose : () => {setLoadDialog(0)} },
+ { text: "You can continue editing your document or navigate to other sections.", onClose : () => {setLoadDialog(0)} }
+ ];
+ const messagesInformation = [
+ { text: "Your document has been auto-saved.", onClose : () => {setLoadDialog(0)} },
+ { text: "You can continue working without worry, as all changes are being saved automatically. This feature ensure that your progress is preserved even if your forget to save manually. Feel free to review the auto-save settings in your account preferences.", onClose : () => {setLoadDialog(0)} }
+ ];
+ const messagesWarning = [
+ { text: "You have unsaved changes in your document.", onClose : () => {setLoadDialog(0)} },
+ { text: "If you navigate away from this page, you will lose any changes you have made. Please save your work to avoid losing any progress. Consider reviewing your changes before saving.", onClose : () => {setLoadDialog(0)} }
+ ];
+ const messagesError = [
+ { text: "We encountered an issue while saving your file.", onClose : () => {setLoadDialog(0)} },
+ { text: "You have unsaved changes in your document. If you navigate away from this page, you will lose any changes you have made. Please save your work to avoid losing any progress. Consider reviewing your changes before saving.", onClose : () => {setLoadDialog(0)} }
+ ];
+
+ return (
+
+
+ setLoadDialog(1)} />
+ setLoadDialog(2)} />
+ setLoadDialog(3)} />
+ setLoadDialog(4)} />
+
+ {loadDialog !== 0 && (
+
+ {loadDialog === 1 && (
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="success"
+ title="Success"
+ />
+ )}
+ {loadDialog === 2 && (
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="info"
+ title="Information"
+ />
+ )}
+ {loadDialog === 3 && (
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="warning"
+ title="Warning"
+ />
+ )}
+ {loadDialog === 4 && (
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="error"
+ title="Error"
+ />
+ )}
+
+ )}
+
+ );
+}`;
+
+const scope = {
+ DxcAlert,
+ DxcInset,
+ DxcFlex,
+ DxcButton,
+ useState,
+};
+
+export default { code, scope };
diff --git a/apps/website/screens/components/alert/overview/examples/inline.ts b/apps/website/screens/components/alert/overview/examples/inline.ts
new file mode 100644
index 0000000000..3ba0c20b5b
--- /dev/null
+++ b/apps/website/screens/components/alert/overview/examples/inline.ts
@@ -0,0 +1,63 @@
+import { DxcAlert, DxcFlex, DxcInset } from "@dxc-technology/halstack-react";
+
+const code = `() => {
+ const messagesSuccess = [
+ { text: "You can continue editing your document or navigate to other sections. If yo need to do further changes, feel free to do so at any time. Remember your changes are saved automatically." },
+ { text: "Second text" }
+ ];
+ const messagesInformation = [
+ { text: "Your document has been auto-saved. You can continue working without worry, as all changes are being saved automatically. This feature ensure that your progress is preserved even if your forget to save manually. Feel free to review the auto-save settings in your account preferences." },
+ { text: "Second text" }
+ ];
+ const messagesWarning = [
+ { text: "You have unsaved changes in your document. If you navigate away from this page, you will lose any changes you have made. Please save your work to avoid losing any progress. Consider reviewing your changes before saving." },
+ { text: "Second text" }
+ ];
+ const messagesError = [
+ { text: "We encountered an issue while saving your file. You have unsaved changes in your document. If you navigate away from this page, you will lose any changes you have made. Please save your work to avoid losing any progress. Consider reviewing your changes before saving." },
+ { text: "Second text" }
+ ];
+
+ return (
+
+
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="success"
+ title="Success"
+ />
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="info"
+ title="Information"
+ />
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="warning"
+ title="Warning"
+ />
+ {} }}
+ secondaryAction={{ label: "Secondary action", onClick: () => {} }}
+ semantic="error"
+ title="Error"
+ />
+
+
+ );
+}`;
+
+const scope = {
+ DxcAlert,
+ DxcInset,
+ DxcFlex,
+};
+
+export default { code, scope };
diff --git a/apps/website/screens/components/alert/overview/images/alert_anatomy.png b/apps/website/screens/components/alert/overview/images/alert_anatomy.png
new file mode 100644
index 0000000000..3bc0d1a41f
Binary files /dev/null and b/apps/website/screens/components/alert/overview/images/alert_anatomy.png differ
diff --git a/apps/website/screens/components/alert/specs/AlertSpecsPage.tsx b/apps/website/screens/components/alert/specs/AlertSpecsPage.tsx
deleted file mode 100644
index 6a087054e2..0000000000
--- a/apps/website/screens/components/alert/specs/AlertSpecsPage.tsx
+++ /dev/null
@@ -1,332 +0,0 @@
-import Image from "@/common/Image";
-import { DxcLink, DxcBulletedList, DxcFlex, DxcTable } from "@dxc-technology/halstack-react";
-import QuickNavContainer from "@/common/QuickNavContainer";
-import QuickNavContainerLayout from "@/common/QuickNavContainerLayout";
-import Code from "@/common/Code";
-import DocFooter from "@/common/DocFooter";
-import Figure from "@/common/Figure";
-import AlertAnatomyImage from "./images/alert_anatomy.png";
-import BannerAlertSpecsImage from "./images/alert_banner_specs.png";
-import InlineAlertSpecsImage from "./images/alert_inline_specs.png";
-import ModalAlertSpecsImage from "./images/alert_modal_specs.png";
-
-const sections = [
- {
- title: "Specifications",
- content: (
- <>
-
-
-
-
-
-
-
-
-
- >
- ),
- },
-
- {
- title: "Anatomy",
- content: (
- <>
-
-
- Container
- Icon
- Title
- Pagination
- Divider
- Close action icon
- Buttons
- Description
-
- >
- ),
- },
- {
- title: "Design tokens",
- subSections: [
- {
- title: "Color",
- content: (
-
-
-