diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index b24af2cdbd63..f6b43c067294 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -227,7 +227,7 @@ OR - SVG or image uses transparent sections that change with the background color to work with either theme. -[Example of SVG file with transparent sections](https://github.com/layer5io/layer5/blob/master/src/assets/images/kanvas/icon-only/kanvas-icon.svg) +[Example of SVG file with transparent sections](https://github.com/layer5io/layer5/blob/master/src/assets/images/kanvas/icon-only/kanvas-icon-color.svg) [Example of image file with transparent sections](https://github.com/layer5io/layer5/blob/master/src/assets/images/app/projects/meshery-logo-light.webp) @@ -403,7 +403,7 @@ Badges are a great way of highlighting the area of contribution by any given com - Docker Extension - Docs - Meshery Catalog -- Kanvas +- Kanvas - Landscape - ImageHub - Meshery diff --git a/src/assets/brand/kanvas-brand-kit.zip b/src/assets/brand/kanvas-brand-kit.zip new file mode 100644 index 000000000000..99e69096cdb8 Binary files /dev/null and b/src/assets/brand/kanvas-brand-kit.zip differ diff --git a/src/assets/images/kanvas/horizontal/kanvas-horizontal-color.png b/src/assets/images/kanvas/horizontal/kanvas-horizontal-color.png index cd92997fc832..1181c066efdc 100644 Binary files a/src/assets/images/kanvas/horizontal/kanvas-horizontal-color.png and b/src/assets/images/kanvas/horizontal/kanvas-horizontal-color.png differ diff --git a/src/assets/images/kanvas/horizontal/kanvas-horizontal-color.svg b/src/assets/images/kanvas/horizontal/kanvas-horizontal-color.svg index 06a8d46404b3..d152413e26f7 100644 --- a/src/assets/images/kanvas/horizontal/kanvas-horizontal-color.svg +++ b/src/assets/images/kanvas/horizontal/kanvas-horizontal-color.svg @@ -3,39 +3,35 @@ - - - - + + + + - + - - - - - - + + + + + + \ No newline at end of file diff --git a/src/assets/images/kanvas/horizontal/kanvas-horizontal-partial-color.png b/src/assets/images/kanvas/horizontal/kanvas-horizontal-partial-color.png index ed0306bc92f9..f14f8054c734 100644 Binary files a/src/assets/images/kanvas/horizontal/kanvas-horizontal-partial-color.png and b/src/assets/images/kanvas/horizontal/kanvas-horizontal-partial-color.png differ diff --git a/src/assets/images/kanvas/horizontal/kanvas-horizontal-partial-color.svg b/src/assets/images/kanvas/horizontal/kanvas-horizontal-partial-color.svg index 209257002300..b6a40624d0d2 100644 --- a/src/assets/images/kanvas/horizontal/kanvas-horizontal-partial-color.svg +++ b/src/assets/images/kanvas/horizontal/kanvas-horizontal-partial-color.svg @@ -3,35 +3,35 @@ - - - - + + + + - - + + - + - - - - - - + + + + + + \ No newline at end of file diff --git a/src/assets/images/kanvas/icon-only/kanvas-icon-color.png b/src/assets/images/kanvas/icon-only/kanvas-icon-color.png index ad90f49f11e9..94a8e124696e 100644 Binary files a/src/assets/images/kanvas/icon-only/kanvas-icon-color.png and b/src/assets/images/kanvas/icon-only/kanvas-icon-color.png differ diff --git a/src/assets/images/kanvas/icon-only/kanvas-icon-color.svg b/src/assets/images/kanvas/icon-only/kanvas-icon-color.svg index 3b8c37373880..80226d79285b 100644 --- a/src/assets/images/kanvas/icon-only/kanvas-icon-color.svg +++ b/src/assets/images/kanvas/icon-only/kanvas-icon-color.svg @@ -3,18 +3,18 @@ - - - - - - + + + + + + \ No newline at end of file diff --git a/src/assets/images/kanvas/icon-only/kanvas-icon.svg b/src/assets/images/kanvas/icon-only/kanvas-icon.svg deleted file mode 100644 index c51b6d9bb9cf..000000000000 --- a/src/assets/images/kanvas/icon-only/kanvas-icon.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/src/assets/images/kanvas/icon-only/kanvas-icon.webp b/src/assets/images/kanvas/icon-only/kanvas-icon.webp deleted file mode 100644 index 690578b0acf3..000000000000 Binary files a/src/assets/images/kanvas/icon-only/kanvas-icon.webp and /dev/null differ diff --git a/src/assets/images/kanvas/stacked/kanvas-stacked-color.png b/src/assets/images/kanvas/stacked/kanvas-stacked-color.png new file mode 100644 index 000000000000..a985d28043d0 Binary files /dev/null and b/src/assets/images/kanvas/stacked/kanvas-stacked-color.png differ diff --git a/src/assets/images/kanvas/stacked/kanvas-stacked-color.svg b/src/assets/images/kanvas/stacked/kanvas-stacked-color.svg index da182882e776..cae5b1b6dbe3 100644 --- a/src/assets/images/kanvas/stacked/kanvas-stacked-color.svg +++ b/src/assets/images/kanvas/stacked/kanvas-stacked-color.svg @@ -3,15 +3,15 @@ - - - - + + + + - + \ No newline at end of file diff --git a/src/collections/integrations/kong-mesh/index.mdx b/src/collections/integrations/kong-mesh/index.mdx index 361887e71b1b..a831cbf1328a 100644 --- a/src/collections/integrations/kong-mesh/index.mdx +++ b/src/collections/integrations/kong-mesh/index.mdx @@ -332,6 +332,12 @@ components: [ "colorIcon": "icons/components/mesh-multi-zone-service/icons/color/mesh-multi-zone-service-color.svg", "whiteIcon": "icons/components/mesh-multi-zone-service/icons/white/mesh-multi-zone-service-white.svg", "description": "", +}, +{ +"name": "mesh-tls", +"colorIcon": "icons/components/mesh-tls/icons/color/mesh-tls-color.svg", +"whiteIcon": "icons/components/mesh-tls/icons/white/mesh-tls-white.svg", +"description": "", }] featureList: [ "Built on top of Envoy with 50+ observability charts out of the box, you can collect metrics, traces and logs of all L4-L7 traffic.", diff --git a/src/collections/integrations/kubernetes/icons/components/persistent-volume/icons/white/persistent-volume-white.svg b/src/collections/integrations/kubernetes/icons/components/persistent-volume/icons/white/persistent-volume-white.svg index 2ed4db357583..e3ed82147324 100644 --- a/src/collections/integrations/kubernetes/icons/components/persistent-volume/icons/white/persistent-volume-white.svg +++ b/src/collections/integrations/kubernetes/icons/components/persistent-volume/icons/white/persistent-volume-white.svg @@ -1,3 +1,3 @@ - + diff --git a/src/collections/integrations/meshery-core/icons/components/pen-terminal/icons/color/pen-terminal-color.svg b/src/collections/integrations/meshery-core/icons/components/pen-terminal/icons/color/pen-terminal-color.svg index 05bc4b31a3a9..367744d04583 100644 --- a/src/collections/integrations/meshery-core/icons/components/pen-terminal/icons/color/pen-terminal-color.svg +++ b/src/collections/integrations/meshery-core/icons/components/pen-terminal/icons/color/pen-terminal-color.svg @@ -1,3 +1,11 @@ - - + + + + + + + + + + diff --git a/src/collections/integrations/meshery-core/icons/components/pen-terminal/icons/white/pen-terminal-white.svg b/src/collections/integrations/meshery-core/icons/components/pen-terminal/icons/white/pen-terminal-white.svg index b29670dc82e6..367744d04583 100644 --- a/src/collections/integrations/meshery-core/icons/components/pen-terminal/icons/white/pen-terminal-white.svg +++ b/src/collections/integrations/meshery-core/icons/components/pen-terminal/icons/white/pen-terminal-white.svg @@ -1,3 +1,11 @@ - - + + + + + + + + + + diff --git a/src/collections/integrations/meshery-core/icons/components/picture/icons/color/picture-color.svg b/src/collections/integrations/meshery-core/icons/components/picture/icons/color/picture-color.svg index 05bc4b31a3a9..12cd9fbb1587 100644 --- a/src/collections/integrations/meshery-core/icons/components/picture/icons/color/picture-color.svg +++ b/src/collections/integrations/meshery-core/icons/components/picture/icons/color/picture-color.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/src/collections/integrations/meshery-core/icons/components/picture/icons/white/picture-white.svg b/src/collections/integrations/meshery-core/icons/components/picture/icons/white/picture-white.svg index b29670dc82e6..12cd9fbb1587 100644 --- a/src/collections/integrations/meshery-core/icons/components/picture/icons/white/picture-white.svg +++ b/src/collections/integrations/meshery-core/icons/components/picture/icons/white/picture-white.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/src/pages/community/members.js b/src/pages/community/members.js index edfdf5b3794b..a1572acd392e 100644 --- a/src/pages/community/members.js +++ b/src/pages/community/members.js @@ -26,7 +26,7 @@ import uiuxrIcon from "../../assets/images/uiuxr/uiuxr.svg"; import docsIcon from "../../assets/images/docs/docs.svg"; import dockerExtensionIcon from "../../assets/images/docker-extension/docker-extension-meshery-logo.svg"; import mesheryCatalogIcon from "../../assets/images/meshery/meshery-catalog.svg"; -import kanvasIcon from "../../assets/images/kanvas/icon-only/kanvas-icon.svg"; +import kanvasIcon from "../../assets/images/kanvas/icon-only/kanvas-icon-color.svg"; /** * Array containing a list of categories to be shown in the dropdown. * The map function in the end wraps the label property with a component. diff --git a/src/pages/projects/sistent/components/link/code.js b/src/pages/projects/sistent/components/link/code.js new file mode 100644 index 000000000000..06eae83ec9a3 --- /dev/null +++ b/src/pages/projects/sistent/components/link/code.js @@ -0,0 +1,8 @@ +import React from "react"; +import { LinkCode } from "../../../../../sections/Projects/Sistent/components/link/code"; + +const LinkCodePage = () => { + return ; +}; + +export default LinkCodePage; \ No newline at end of file diff --git a/src/pages/projects/sistent/components/link/guidance.js b/src/pages/projects/sistent/components/link/guidance.js new file mode 100644 index 000000000000..b9efe9988519 --- /dev/null +++ b/src/pages/projects/sistent/components/link/guidance.js @@ -0,0 +1,8 @@ +import React from "react"; +import { LinkGuidancePage } from "../../../../../sections/Projects/Sistent/components/link/guidance"; + +const LinkGuidance = () => { + return ; +}; + +export default LinkGuidance; \ No newline at end of file diff --git a/src/pages/projects/sistent/components/link/index.js b/src/pages/projects/sistent/components/link/index.js new file mode 100644 index 000000000000..2e2f14e7f001 --- /dev/null +++ b/src/pages/projects/sistent/components/link/index.js @@ -0,0 +1,8 @@ +import React from "react"; +import SistentLink from "../../../../../sections/Projects/Sistent/components/link/index"; + +const SistentButtonPage = () => { + return ; +}; + +export default SistentButtonPage; \ No newline at end of file diff --git a/src/sections/Community/Handbook/recognition.js b/src/sections/Community/Handbook/recognition.js index 0765b51329dd..fe372dc4580c 100644 --- a/src/sections/Community/Handbook/recognition.js +++ b/src/sections/Community/Handbook/recognition.js @@ -16,7 +16,7 @@ import TocPagination from "../../../components/handbook-navigation/TocPagination import IntraPage from "../../../components/handbook-navigation/intra-page"; import uiuxrLogo from "../../../assets/images/uiuxr/uiuxr.svg"; import writersLogo from "../../../assets/images/writer-program/writer-program-badge.svg"; -import kanvasLogo from "../../../assets/images/kanvas/icon-only/kanvas-icon.svg"; +import kanvasLogo from "../../../assets/images/kanvas/icon-only/kanvas-icon-color.svg"; import MesheryCatalogLogo from "../../../assets/images/meshery/meshery-catalog.svg"; import DocsLogo from "../../../assets/images/docs/docs.svg"; import ApplicationPioneerLogo from "../../../assets/images/application-pioneer/application-pioneer.svg"; diff --git a/src/sections/Community/Handbook/repository.js b/src/sections/Community/Handbook/repository.js index af770b6a1af1..d6411e86bbc7 100644 --- a/src/sections/Community/Handbook/repository.js +++ b/src/sections/Community/Handbook/repository.js @@ -12,7 +12,7 @@ import meshery from "../../../assets/images/meshery/icon-only/meshery-logo-light import servicemeshpattern from "../../../assets/images/service-mesh-patterns/service-mesh-pattern.svg"; import TocPagination from "../../../components/handbook-navigation/TocPagination"; import IntraPage from "../../../components/handbook-navigation/intra-page"; -import Kanvas from "../../../assets/images/kanvas/icon-only/kanvas-icon.svg"; +import Kanvas from "../../../assets/images/kanvas/icon-only/kanvas-icon-color.svg"; import { Link } from "gatsby"; diff --git a/src/sections/Community/Handbook/security-vulnerabilities.js b/src/sections/Community/Handbook/security-vulnerabilities.js index 451d507b0dc2..f911d81af9bc 100644 --- a/src/sections/Community/Handbook/security-vulnerabilities.js +++ b/src/sections/Community/Handbook/security-vulnerabilities.js @@ -10,7 +10,7 @@ import MeshSync from "../../../assets/images/meshsync/meshsync.svg"; import servicemeshperformance from "../../../assets/images/service-mesh-performance/icon/smp-dark.svg"; import meshery from "../../../assets/images/meshery/icon-only/meshery-logo-light.svg"; import servicemeshpattern from "../../../assets/images/service-mesh-patterns/service-mesh-pattern.svg"; -import Kanvas from "../../../assets/images/kanvas/icon-only/kanvas-icon.svg"; +import Kanvas from "../../../assets/images/kanvas/icon-only/kanvas-icon-color.svg"; const SecurityVulnerabilitiesPage = () => { return ( diff --git a/src/sections/Community/Member-single/index.js b/src/sections/Community/Member-single/index.js index e418acc8cefd..31ab829daea4 100644 --- a/src/sections/Community/Member-single/index.js +++ b/src/sections/Community/Member-single/index.js @@ -22,7 +22,7 @@ import writerIcon from "../../../assets/images/writer-program/writer-program-bad import docsLogo from "../../../assets/images/docs/docs.svg"; import mesheryCatalogLogo from "../../../assets/images/meshery/meshery-catalog.svg"; import dockerExtensionLogo from "../../../assets/images/docker-extension/docker-extension-meshery-logo.svg"; -import KanvasLogo from "../../../assets/images/kanvas/icon-only/kanvas-icon.svg"; +import KanvasLogo from "../../../assets/images/kanvas/icon-only/kanvas-icon-color.svg"; import Button from "../../../reusecore/Button"; import { ReactComponent as TwitterIcon } from "../../../assets/images/socialIcons/twitter.svg"; diff --git a/src/sections/General/Navigation/index.js b/src/sections/General/Navigation/index.js index 011881f680ab..808523911eee 100644 --- a/src/sections/General/Navigation/index.js +++ b/src/sections/General/Navigation/index.js @@ -9,7 +9,7 @@ import { useStyledDarkMode } from "../../../theme/app/useStyledDarkMode"; import axios from "axios"; // import smp_dark_text from "../../../assets/images/service-mesh-performance/stacked/smp-dark-text.svg"; // import smp_light_text from "../../../assets/images/service-mesh-performance/stacked/smp-light-text.svg"; -import kanvas_dark from "../../..//assets/images/kanvas/icon-only/kanvas-icon.svg"; +import kanvas_dark from "../../../assets/images/kanvas/icon-only/kanvas-icon-white.svg"; import meshery from "../../../assets/images/meshery/icon-only/meshery-logo-light.svg"; import Data from "./utility/menu-items.js"; import ScrollspyMenu from "./utility/ScrollspyMenu.js"; diff --git a/src/sections/Home/Projects-home/index.js b/src/sections/Home/Projects-home/index.js index 7b2b3c303ad8..22c90d5e38df 100644 --- a/src/sections/Home/Projects-home/index.js +++ b/src/sections/Home/Projects-home/index.js @@ -14,7 +14,7 @@ const Projects = () => { const projectImage2_dark = "../../../assets/images/app/projects/smp.webp"; const projectImage3 = "../../../assets/images/app/projects/meshery-logo-light.webp"; const projectImage4 = "../../../assets/images/app/projects/nighthawk-logo.webp"; - const kanvasLogo = "../../../assets/images/kanvas/icon-only/kanvas-icon.svg"; + const kanvasLogo = "../../../assets/images/kanvas/icon-only/kanvas-icon-color.svg"; if (!didLoad){ return null; } diff --git a/src/sections/Products/index.js b/src/sections/Products/index.js index 0bea8f1810b6..656fa5b706bf 100644 --- a/src/sections/Products/index.js +++ b/src/sections/Products/index.js @@ -10,7 +10,7 @@ import codicon from "./images/codicon_extensions.svg"; import mesheryLogo from "../../assets/images/meshery/icon-only/meshery-logo-light.svg"; import cloudicon from "./images/cloud.svg"; import layer5 from "../../assets/images/layer5/5 icon/svg/light/5-light-no-trim.svg"; -import kanvas from "../../assets/images/kanvas/icon-only/kanvas-icon.svg"; +import kanvas from "../../assets/images/kanvas/icon-only/kanvas-icon-color.svg"; import comingSoon from "./icons/coming-soon.webp"; import { useStyledDarkMode } from "../../theme/app/useStyledDarkMode"; import PlanCard from "../../components/PlanCard"; diff --git a/src/sections/Projects/Project-grid/index.js b/src/sections/Projects/Project-grid/index.js index 3759ed57bef3..c2ae3569265e 100644 --- a/src/sections/Projects/Project-grid/index.js +++ b/src/sections/Projects/Project-grid/index.js @@ -16,7 +16,7 @@ import smp_light from "../../../assets/images/service-mesh-performance/icon/smp- import patterns from "../../../assets/images/service-mesh-patterns/service-mesh-pattern.svg"; import L5gray from "../../../assets/images/layer5/5 icon/svg/gray/5-gray-60.svg"; import nighthawk from "../../../assets/images/nighthawk/icon-only/SVG/nighthawk-logo.svg"; -import kanvas from "../../../assets/images/kanvas/icon-only/kanvas-icon.svg"; +import kanvas from "../../../assets/images/kanvas/icon-only/kanvas-icon-color.svg"; import catalog from "../../../assets/images/catalog-icon/catalog.svg"; import sistent from "../../../assets/images/sistent/sistent-logo.svg"; import SoSpecial from "../../Home/So-Special-Section"; diff --git a/src/sections/Projects/Sistent/components/button/code-block.js b/src/sections/Projects/Sistent/components/button/code-block.js index b3e4945c40e5..2a7463d6ceec 100644 --- a/src/sections/Projects/Sistent/components/button/code-block.js +++ b/src/sections/Projects/Sistent/components/button/code-block.js @@ -1,5 +1,6 @@ import React, { useState } from "react"; import Code from "../../../../../components/CodeBlock"; + export const CodeBlock = ({ name, code }) => { const [showCode, setShowCode] = useState(false); const onChange = () => { diff --git a/src/sections/Projects/Sistent/components/index.js b/src/sections/Projects/Sistent/components/index.js index fa716d565a50..ca05b2d29792 100644 --- a/src/sections/Projects/Sistent/components/index.js +++ b/src/sections/Projects/Sistent/components/index.js @@ -50,7 +50,15 @@ const componentsData = [ description: "The TextField component is a versatile input field used to capture user input in forms and user interfaces.", url: "/projects/sistent/components/text-field", - } + }, + { + id: 7, + name: "Link", + description: + "Links are essential and integral components of an interface. They are primarily used for navigation, guiding users to the next step in a journey or redirecting them to relevant sections or pages.", + url: "/projects/sistent/components/link", + }, + ]; const SistentComponents = () => { diff --git a/src/sections/Projects/Sistent/components/link/code.js b/src/sections/Projects/Sistent/components/link/code.js new file mode 100644 index 000000000000..2096cd6fd8f8 --- /dev/null +++ b/src/sections/Projects/Sistent/components/link/code.js @@ -0,0 +1,261 @@ +import React from "react"; +import { navigate } from "gatsby"; +import { useLocation } from "@reach/router"; + +import { SistentThemeProvider, Link } from "@layer5/sistent"; +import { CodeBlock } from "../button/code-block"; +// import { FaArrowRight } from "@react-icons/all-files/fa/FaArrowRight"; +import { SistentLayout } from "../../sistent-layout"; + +import TabButton from "../../../../../reusecore/Button"; +import { useStyledDarkMode } from "../../../../../theme/app/useStyledDarkMode"; + +const codes = [ + ` + + Simple Link + + `, + + ` + + Colored Link + + `, + + ` + + Underlined Link + + +`, + + ` + + Customized Link + + `, + + ` + + Visit Secure Link + + ` +]; + +export const LinkCode = () => { + const location = useLocation(); + const { isDark } = useStyledDarkMode(); + + return ( + +
+ +

Link

+
+

+

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

+ Links are fundamental components in web navigation, allowing users to move between different pages or resources. Their design and implementation are crucial for creating a seamless browsing experience. +

+ +

Simple Link

+
+

The link can be presented in a simple format, primarily as underlined text that serves as a gateway to navigate users to other pages or resources, without any prominent styling or buttons attached to it.

+
+
+ + + Simple Link + + +
+ +
+ +

Customized Links

+
+

+ Customized Links enhance user experience by adapting their design and behavior to match the app’s theme. They can include personalized styles, hover effects, or icons, ensuring both visual consistency and improved usability across the website. +

+ +

Colored Link

+

+ Colored Links can help draw attention to key areas of a page. They are styled with custom colors to stand out and indicate their importance, enhancing navigation and usability. +

+
+
+ + + Colored Link + + +
+ +
+ +

Underlined Link

+

+ Underlined Links, often referred to as ghost buttons, are styled primarily with text without any fills or borders. They utilize specific text styling and color to signify different states, making them easily identifiable and enhancing user navigation. +

+
+
+ + + Underlined Link + + +
+ +
+ +

Customized Link

+

+ Customized Links allow for distinct text styles and presentations that can enhance the user experience. By leveraging different styling properties, these links can be tailored to fit the design aesthetics of your application while maintaining functionality. +

+
+
+ + + Customized Link + + +
+ +
+ +

Security Considerations

+
+

+ When utilizing links we should use them with the target="_blank" attribute, it's essential to implement rel="noopener" or rel="noreferrer" to enhance security and user privacy +

+
+
+ + + Visit Secure Link + + +
+ +
+
+
+ + ); +}; diff --git a/src/sections/Projects/Sistent/components/link/guidance.js b/src/sections/Projects/Sistent/components/link/guidance.js new file mode 100644 index 000000000000..e07030a91889 --- /dev/null +++ b/src/sections/Projects/Sistent/components/link/guidance.js @@ -0,0 +1,154 @@ +import React from "react"; +import { navigate } from "gatsby"; +import { useLocation } from "@reach/router"; +import { Row } from "../../../../../reusecore/Layout"; +import { SistentThemeProvider, Link, ExternalLinkIcon } from "@layer5/sistent"; +import { SistentLayout } from "../../sistent-layout"; + +import TabButton from "../../../../../reusecore/Button"; +import StyledButton from "../../../../../reusecore/Button"; +import { useStyledDarkMode } from "../../../../../theme/app/useStyledDarkMode"; + +export const LinkGuidancePage = () => { + const location = useLocation(); + const { isDark } = useStyledDarkMode(); + + return ( + +
+ +

Link

+
+

+ A link component is a navigational element that directs users to another page or section within an application. +

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

+ Links are fundamental components in web navigation, allowing users to move between different pages or resources. Their design and implementation are crucial for creating a seamless browsing experience. +

+ +

Function

+
+

+ Links too have a lot many functions as: +

+

Navigation Links

+

+ These links help users navigate through a website, directing them to important sections or related content. They should be easily accessible and clearly labeled to enhance usability. +

+ + + + Navigate to Layer 5 + + + +

Call to Action (CTA) Links

+

+ CTA links encourage users to take specific actions, such as signing up for a newsletter or downloading a resource. They should stand out visually to attract user attention and drive engagement. +

+ + + + + Get Started + + + + +

External Links

+

+ These links direct users to external websites. It’s important to provide clear indicators (like icons or different styles) that these links lead to external content, which helps users manage their navigation expectations. +

+ + + (e.target.style.textDecoration = "underline")} + onMouseLeave={(e) => (e.target.style.textDecoration = "none")} + > + Visit External Resource + + + + + +

Labeling

+
+

+ Link labels are vital for communicating the action associated with the link. Labels should be concise, informative, and use action-oriented language (e.g., "Download Report," "Learn More") to guide users effectively. +

+

Case Style

+

+ Consistency in the case style of link text improves readability and enhances the overall aesthetic of the website. Using a uniform style, such as sentence case or title case, contributes to a more professional appearance. +

+

Font Weight

+

+ The weight of the font in link text can signify importance and attract user attention. A bolder font can indicate a primary action, while a lighter font may denote secondary options. Legibility is essential for ensuring that links are easy to read. +

+

Text Decoration

+

+ Links typically use underlines to distinguish them from regular text. However, it’s important to maintain the underline for accessibility and usability, as users often associate underlined text with clickable links. Consider hover effects to provide visual feedback. +

+
+
+
+ ); +}; diff --git a/src/sections/Projects/Sistent/components/link/index.js b/src/sections/Projects/Sistent/components/link/index.js new file mode 100644 index 000000000000..41cc740295e1 --- /dev/null +++ b/src/sections/Projects/Sistent/components/link/index.js @@ -0,0 +1,186 @@ +import React from "react"; +import { navigate } from "gatsby"; +import { useLocation } from "@reach/router"; + +import { SistentThemeProvider, Link } 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 SistentLink = () => { + const location = useLocation(); + const { isDark } = useStyledDarkMode(); + + return ( + +
+ +

Link

+
+

+ A link component is a navigational element that directs users to another page or section within an application. + +

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

+ Links are essential and integral components of an interface. They are primarily used for navigation, guiding users to the next step in a journey or redirecting them to relevant sections or pages. Links can be paired with other elements to create cohesive designs, enhancing the digital experience by providing smooth transitions and interaction cues. +

+ +

Types of Links

+
+

+ Links in an interface serve as vital elements for navigation and interaction. Multiple types of links are available to establish hierarchy, provide visual prominence, and enhance flexibility, guiding users towards their goals efficiently. With distinct styling and behaviors, links can help streamline user flows and create a cohesive user experience. +

+

Simple Links

+

+ Basic anchor links with customizable colors and typography styles that inherit properties from the Typography component. This allows flexibility in styling with options like various text sizes or variants. +

+ + + + Simple Link + + + + +

Customized Links

+

+ The links can be customized in the below mentioned way +

+

1. Color

+

Nomally the color of Sistent Link is green , but on adding styling properties, You can customize link colors with predefined values such as primary, secondary, error, success, warning, info, or inherit existing text colors like Blue, Red. +

+ + + + Customized Link 1 + + + + +

2. Underlining

+

+ Also known as ghost buttons, text buttons are mostly just what the + name implies; they are buttons without fills or borders which might + just have a specific text styling and color to denote different + states for easier identification. +

+ + + + Customized Link 2 + + + + + +

3. Variants

+

+ Links can have various text styles using the different styling property +

+ + + + Customized Link 3 + + + + + +

Security

+
+

+ When using target="_blank" with links, it's crucial to include + rel="noopener" or rel="noreferrer" for security reasons: +

+
    +
  • Prevent Access: rel="noopener" prevents the new page from accessing the + window.opener property, securing your original page from potential malicious redirects.
  • +
  • Avoid Referer Leakage: rel="noreferrer" not only blocks the new page's + access to your original page but also stops the Referer header from being sent, protecting user privacy.
  • +
  • Security Risk Mitigation: Using these attributes reduces the risk of phishing attacks + and ensures that your site maintains control over its navigation and data.
  • +
+

+ By following these practices, you can enhance the security of your web application and protect your users. +

+ + + +

Optimized Rendering of Links Using

+
+ +

+ useMemo is a React hook that helps optimize the rendering of link components by memorizing computed values, which prevents unnecessary re-renders. +

+
+
+
+ ); +}; + +export default SistentLink; diff --git a/src/theme/app/THEME.md b/src/theme/app/THEME.md index 4bcc224ab4d6..cf550d9dd3a7 100644 --- a/src/theme/app/THEME.md +++ b/src/theme/app/THEME.md @@ -87,7 +87,7 @@ OR - SVG or image uses transparent sections that change with the background color to work with either theme. -[Example of SVG file with transparent sections](https://github.com/layer5io/layer5/blob/master/src/assets/images/kanvas/icon-only/kanvas-icon.svg) +[Example of SVG file with transparent sections](https://github.com/layer5io/layer5/blob/master/src/assets/images/kanvas/icon-only/kanvas-icon-color.svg) [Example of image file with transparent sections](https://github.com/layer5io/layer5/blob/master/src/assets/images/app/projects/meshery-logo-light.webp)