diff --git a/src/pages/projects/sistent/components/divider/code.js b/src/pages/projects/sistent/components/divider/code.js
new file mode 100644
index 000000000000..5a2a00856249
--- /dev/null
+++ b/src/pages/projects/sistent/components/divider/code.js
@@ -0,0 +1,8 @@
+import React from "react";
+import { DividerCode } from "../../../../../sections/Projects/Sistent/components/divider/code";
+
+const DividerCodePage = () => {
+ return
+ {"Lorem ipsum dolor sit amet, consectetur adipiscing elit."} +
+); + +const codes = [ + `+ The Divider component adds a subtle line to separate content + sections, supporting horizontal/vertical orientation and + customizable alignment for text or icons. Ideal for enhancing layout + clarity. +
+ ++ The Divider component supports three variants: fullWidth (default), + inset, and middle. +
+
+ The flexItem
prop allows the Divider to function
+ properly within a flex container, ensuring it aligns with other flex
+ items seamlessly.
+
+ The Divider component supports two orientations: horizontal and + vertical. Each orientation serves different layout needs and + enhances the visual structure of your content. +
++ The Divider component supports two orientations: horizontal and + vertical. Each orientation serves different layout needs and + enhances the visual structure of your content. +
++ The Divider component provides a visual separation between content + areas, improving readability and structure in your layouts. +
+ +The Divider component supports three variants:
+The Divider can be oriented horizontally or vertically:
+
+ When using the Divider in a flex container, set the{" "}
+ flexItem
prop. This ensures proper alignment and sizing
+ relative to other flex items.
+
+ The Divider is announced by screen readers, ensuring users with
+ assistive technologies can navigate your layout effectively. If the
+ Divider is purely decorative, consider using{" "}
+ aria-hidden="true"
.
+
Here are a few scenarios where you might use the Divider:
++ {"Lorem ipsum dolor sit amet, consectetur adipiscing elit."} +
+); + +const SistentDivider = () => { + const location = useLocation(); + const { isDark } = useStyledDarkMode(); + + return ( ++ The Divider component adds a subtle line to separate content sections, + supporting horizontal/vertical orientation and customizable alignment + for text or icons. Ideal for enhancing layout clarity. +
++ The Divider component provides a simple line to visually separate + content sections, enhancing readability and hierarchy in layouts. It + supports customization options such as orientation (horizontal or + vertical), variants (fullWidth, inset, and middle), and flexible + alignment of text or icons. Perfect for cleanly segmenting elements + in lists, cards, or flex containers, the Divider is accessible and + can be styled to fit various design needs. +
+ +Prop | +Type | +Default Value | +Description | +
---|---|---|---|
variant | +string | +"fullWidth" | ++ Defines the style of the divider. Can be "fullWidth", + "inset", or "middle". "fullWidth" is the default and takes + the full width of its container. + | +
orientation | +string | +"horizontal" | ++ Specifies the divider's orientation. It can be + "horizontal" or "vertical". Default is "horizontal". + | +
component | +elementType | ++ | + Specifies the component type for the divider. It can be + set to any valid HTML element, such as "li" to use the + divider within lists. Default is "div". + | +
sx | +object | +{} | ++ A custom style prop to modify the divider's appearance, + such as color, height, or margin. Accepts a style object. + | +
role | +string | +"separator" | ++ Sets the ARIA role for accessibility purposes, generally + set as "separator" to indicate the divider's role. + | +
flexItem | +boolean | +false | ++ If true, applies the divider as a flex item, adjusting it + within a flexbox layout. Default is false. + | +
Here are ways to use the Divider component effectively:
+orientation
{" "}
+ to horizontal
(default) or vertical
for
+ versatile layouts.
+ variant="inset"
for a more subtle divider.
+ textAlign="left"
, center
, or{" "}
+ right
for labeled dividers.
+ flexItem
,
+ the Divider integrates seamlessly in flex layouts.
+ + The Divider component supports three variants: fullWidth (default), + inset, and middle. +
+
+ The flexItem
prop allows the Divider to function
+ properly within a flex container, ensuring it aligns with other flex
+ items seamlessly.
+
+ The Divider component supports two orientations: horizontal and + vertical. Each orientation serves different layout needs and + enhances the visual structure of your content. +
++ This is the default orientation of the Divider. It is used to + separate content sections horizontally, making it ideal for + creating clear distinctions between different blocks of + information, such as headings and paragraphs or between card + elements. A horizontal divider typically spans the full width of + its container, effectively guiding the user eye through the + layout. +
+ ++ The vertical orientation is useful in scenarios where you want to + separate items or components side by side, such as in a flex + container or sidebar. This orientation helps to create visual + breaks between closely related elements, enhancing readability and + organization. A vertical divider can be particularly effective in + navigation menus or grouped items where you want to maintain a + compact layout. +
+
+ Use the textAlign
prop to align elements that are
+ wrapped by the Divider.
+
+ Due to its implicit role of separator, the Divider, which is a
+ `hr`
element, will be announced by screen readers as a
+ "Horizontal Splitter" (or vertical, if you're using the orientation
+ prop). If you're using it as a purely stylistic element, we
+ recommend setting aria-hidden="true" which will make screen readers
+ bypass it.
+
+ If you're using the Divider to wrap other elements, such as text or
+ chips, we recommend changing its rendered element to a plain
+ `div`
+ using the component prop, and setting role="presentation". This
+ ensures that it's not announced by screen readers while still
+ preserving the semantics of the elements inside it.
+