diff --git a/src/sections/Projects/Sistent/components/card/code.js b/src/sections/Projects/Sistent/components/card/code.js index e69de29bb2d1..dc4b41af0fd6 100644 --- a/src/sections/Projects/Sistent/components/card/code.js +++ b/src/sections/Projects/Sistent/components/card/code.js @@ -0,0 +1,259 @@ +import React from "react"; +import { navigate } from "gatsby"; +import { useLocation } from "@reach/router"; + +import { SistentThemeProvider, Card, CardActions, CardContent, CardHeader, CardMedia , Typography, Box, Button } from "@layer5/sistent"; +import { CodeBlock } from "../button/code-block"; +import { SistentLayout } from "../../sistent-layout"; + +import MesheryLogo from "../../../../../assets/images/meshery/meshery-logo-light-text-side.webp"; +import KanvasLogo from "../../../../../assets/images/kanvas/icon-only/kanvas-icon-color.png"; + +import TabButton from "../../../../../reusecore/Button"; +import { useStyledDarkMode } from "../../../../../theme/app/useStyledDarkMode"; + +const codes = [ + `const cardOutlined = ( + + + + Company Spotlight + + + Layer5 + + Platform + + Empowering engineers with cloud-native management solutions. + + + + + + + ); + + {cardOutlined} + `, + + `const cardMainAction1 = ( + + + + + + Meshery + + + Meshery is an open-source cloud-native management platform. + + + + + ); + + {cardMainAction1} + `, + + ` + const cardMainAction2 = ( + + + + + + Kanvas + + + Kanvas is a collaborative design tool. + + + + + + + + ); + + {cardMainAction2} + `, +]; + +const CardCode = () => { + const location = useLocation(); + const { isDark } = useStyledDarkMode(); + + const cardOutlined = ( + + + + Company Spotlight + + + Layer5 + + Platform + + Empowering engineers with cloud-native management solutions. + + + + + + + ); + + const cardMainAction1 = ( + + + + + + Meshery + + + Meshery is an open-source cloud-native management platform designed to help users manage, monitor, and optimize the performance of service meshes and their workloads. + + + + + ); + + const cardMainAction2 = ( + + + + + + Kanvas + + + Kanvas is a collaborative design tool that allows users to create, edit, and manage visual assets seamlessly within a shared workspace. + + + + + + + + ); + + return ( + +
+ +

Card

+
+

The Card component is a UI element used to encapsulate information or actions related to a single topic, typically in a visually separated, easily digestible format. It often includes elements like images, text, and buttons to present content and enable quick interactions without navigating away from the card.

+
+ navigate("/projects/sistent/components/card")} + title="Overview" + /> + + navigate("/projects/sistent/components/card/guidance") + } + title="Guidance" + /> + + navigate("/projects/sistent/components/card/code") + } + title="Code" + /> +
+
+

+ A card often lets users interact with its entire surface to trigger its main function, whether it’s expanding, navigating to another screen, or activating some other behavior. +

+ +

Oultined Card Example

+
+

+ An outlined card is a variation of the standard card component, often used to provide a lighter, more minimalist design. Instead of a solid background or shadow, an outlined card uses a border to define its boundaries, giving it a cleaner and more refined appearance. +

+
+
+ + {cardOutlined} + +
+ +
+ +
+ +

Main Action Cards

+
+

+ This type of interactive card is well-suited for use in applications where quick access to more information or actions is important, such as dashboards, or product catalogs. For example, ont the website, users can tap anywhere on the card to open the full product page. +

+
+
+ + {cardMainAction1} + +
+ +
+
+

+ Cards can also include secondary actions, which should be positioned away from the primary action area to avoid unintentional interaction conflicts. +

+
+
+ + {cardMainAction2} + +
+ +
+
+
+
+ ); +}; + +export default CardCode; diff --git a/src/sections/Projects/Sistent/components/card/guidance.js b/src/sections/Projects/Sistent/components/card/guidance.js index e69de29bb2d1..42ba83ecb926 100644 --- a/src/sections/Projects/Sistent/components/card/guidance.js +++ b/src/sections/Projects/Sistent/components/card/guidance.js @@ -0,0 +1,197 @@ +import React from "react"; +import { navigate } from "gatsby"; +import { useLocation } from "@reach/router"; +import { Row } from "../../../../../reusecore/Layout"; +import { SistentThemeProvider, Card, CardActions, CardContent, CardHeader, CardMedia , Typography, Box, Button } from "@layer5/sistent"; +import { SistentLayout } from "../../sistent-layout"; +import MesheryLogo from "../../../../../assets/images/meshery/meshery-logo-light-text-side.webp"; +import KanvasLogo from "../../../../../assets/images/kanvas/icon-only/kanvas-icon-color.png"; + +import TabButton from "../../../../../reusecore/Button"; +import { useStyledDarkMode } from "../../../../../theme/app/useStyledDarkMode"; + +const CardGuidance = () => { + const location = useLocation(); + const { isDark } = useStyledDarkMode(); + + const cardOutlined = ( + + + + Company Spotlight + + + Layer5 + + Platform + + Empowering engineers with cloud-native management solutions. + + + + + + + ); + + const cardMainAction1 = ( + + + + + + Meshery + + + Meshery is an open-source cloud-native management platform designed to help users manage, monitor, and optimize the performance of service meshes and their workloads. + + + + + ); + + const cardMainAction2 = ( + + + + + + Kanvas + + + Kanvas is a collaborative design tool that allows users to create, edit, and manage visual assets seamlessly within a shared workspace. + + + + + + + + ); + + return ( + +
+ +

Card

+
+

+ The Card component is a UI element used to encapsulate information or actions related to a single topic, + typically in a visually separated, easily digestible format. It often includes elements like images, text, + and buttons to present content and enable quick interactions without navigating away from the card. +

+
+ navigate("/projects/sistent/components/card")} + title="Overview" + /> + + navigate("/projects/sistent/components/card/guidance") + } + title="Guidance" + /> + + navigate("/projects/sistent/components/card/code") + } + title="Code" + /> +
+
+

+ For proper application, these cards can be used for different purposes to enable easier and consistent combination when guiding users across digital experiences. +

+ + +

Function

+
+ +

The Card Component serves various functions:

+ +

Oultined Card

+

+ Outlined cards are ideal for use in layouts that benefit from a subtle, modern look, such as in settings with light backgrounds where visual clarity is important. They’re perfect for showcasing items like product listings, profiles, or dashboard summaries, as the minimal border keeps the focus on the content without adding visual weight.

+ + + {cardOutlined} + + + +

Main Action Cards

+

+ This type of interactive card is well-suited for use in applications where quick access to more information or actions is important, such as dashboards, or product catalogs. For example, ont the website, users can tap anywhere on the card to open the full product page. +

+ + + {cardMainAction1} + + + +

+ In usage, cards can incorporate secondary actions, like sharing, bookmarking, or viewing additional details, which are typically placed separately from the main action area. This separation prevents accidental taps or clicks, allowing users to clearly distinguish between the primary function of the card (like opening a detailed view) and other supporting actions. +

+ + + {cardMainAction2} + + + + +

Labeling

+
+

+ For card components, clear labeling helps define the purpose and hierarchy of each card, making it easier for users to understand the content at a glance. Labels, like titles or category tags, can indicate the main topic or action associated with each card, improving navigation and usability within a grid of multiple cards. +

+ +

Hierarchy and Visual Cues

+

+ Cards benefit from a clear hierarchy, using typography, spacing, and color to guide users through the content. For instance, a card title in bold or larger text immediately draws attention, while secondary information is displayed with subdued colors. +

+ +

Interactivity and Feedback

+

+ Cards often use hover effects, shadow adjustments, or subtle animations to indicate interactivity. This feedback helps users identify clickable areas or interactive elements within the card, providing a more engaging experience. +

+ +

Consistency in Style and Layout

+

+ Cards should maintain a consistent style throughout an interface to ensure a unified look and feel. Consistency in aspects like font sizes, padding, border radii, and color schemes helps cards blend naturally into the overall UI design, improving readability and making interactions feel intuitive across different screens or sections. +

+ +
+
+
+ ); +}; + +export default CardGuidance; diff --git a/src/sections/Projects/Sistent/components/card/index.js b/src/sections/Projects/Sistent/components/card/index.js index e69de29bb2d1..90cf07b6fad4 100644 --- a/src/sections/Projects/Sistent/components/card/index.js +++ b/src/sections/Projects/Sistent/components/card/index.js @@ -0,0 +1,181 @@ +import React from "react"; +import { navigate } from "gatsby"; +import { useLocation } from "@reach/router"; +import MesheryLogo from "../../../../../assets/images/meshery/meshery-logo-light-text-side.webp"; +import KanvasLogo from "../../../../../assets/images/kanvas/icon-only/kanvas-icon-color.png"; + +import { SistentThemeProvider, Card, CardActions, CardContent, CardHeader, CardMedia , Typography, Box, Button } from "@layer5/sistent"; +import TabButton from "../../../../../reusecore/Button"; +import { SistentLayout } from "../../sistent-layout"; +import { Row } from "../../../../../reusecore/Layout"; +import { useStyledDarkMode } from "../../../../../theme/app/useStyledDarkMode"; + +const SistentCard = () => { + const location = useLocation(); + const { isDark } = useStyledDarkMode(); + + const bull = ( + + • + + ); + + const cardOutlined = ( + + + + Company Spotlight + + + Layer5 + + Platform + + Empowering engineers with cloud-native management solutions. + + + + + + + ); + + const cardMainAction1 = ( + + + + + + Meshery + + + Meshery is an open-source cloud-native management platform designed to help users manage, monitor, and optimize the performance of service meshes and their workloads. + + + + + ); + + const cardMainAction2 = ( + + + + + + Kanvas + + + Kanvas is a collaborative design tool that allows users to create, edit, and manage visual assets seamlessly within a shared workspace. + + + + + + + + ); + return ( + +
+ +

Card

+
+

The Card component is a UI element used to encapsulate information or actions related to a single topic, typically in a visually separated, easily digestible format. It often includes elements like images, text, and buttons to present content and enable quick interactions without navigating away from the card. + +

+
+ navigate("/projects/sistent/components/card")} + title="Overview" + /> + + navigate("/projects/sistent/components/card/guidance") + } + title="Guidance" + /> + + navigate("/projects/sistent/components/card/code") + } + title="Code" + /> +
+
+

+ The card component is a versatile UI element commonly used in web and mobile applications. It's designed to showcase content in a clean, concise, and visually organized manner. Typically, a card groups related information, making it easy for users to digest and interact with. It often includes an image or icon, title, description, and actionable buttons or links, all contained within a defined boundary that makes it visually distinct. +

+ +

Types of Cards

+
+

+

+

Outlined

+

+ An outlined card is a variation of the standard card component, often used to provide a lighter, more minimalist design. Instead of a solid background or shadow, an outlined card uses a border to define its boundaries, giving it a cleaner and more refined appearance. +

+ + + {cardOutlined} + + + +

Main Action

+

1. A card often lets users interact with its entire surface to trigger its main function, whether it’s expanding, navigating to another screen, or activating some other behavior.

+ + + {cardMainAction1} + + + +

+ 2. Cards can also include secondary actions, which should be positioned away from the primary action area to avoid unintentional interaction conflicts. +

+ + + {cardMainAction2} + + + +

+ NOTE: Cards may offer multiple actions, UI elements, and an overflow menu, but it’s important to exercise restraint, as they are primarily designed to serve as entry points to deeper and more comprehensive content. +

+
+
+
+ ); +}; + +export default SistentCard; diff --git a/src/sections/Projects/Sistent/components/content.js b/src/sections/Projects/Sistent/components/content.js index 388e34486f06..45ce8275c89d 100644 --- a/src/sections/Projects/Sistent/components/content.js +++ b/src/sections/Projects/Sistent/components/content.js @@ -95,6 +95,14 @@ const componentsData = [ url: "/projects/sistent/components/backdrop", src: "/backdrop", }, + { + id: 13, + name: "Card", + description: + "Cards are surfaces that showcase content and actions centered around a specific topic.", + url: "/projects/sistent/components/card", + src: "/card", + }, ]; module.exports = { componentsData }; \ No newline at end of file