File tree Expand file tree Collapse file tree 2 files changed +42
-7
lines changed Expand file tree Collapse file tree 2 files changed +42
-7
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,34 @@ import Logo from "@assets/GraphScript.png";
1212import "./style.css" ;
1313
1414export function Hero ( ) {
15+ const actions = [
16+ {
17+ name : "Get Ecosystem" ,
18+ icon : Trees ,
19+ href : "https://github.com/GraphScript-Labs/" ,
20+ } ,
21+ {
22+ name : "GSAM Compiler" ,
23+ icon : Drill ,
24+ href : "https://github.com/GraphScript-Labs/gsam-compiler" ,
25+ } ,
26+ {
27+ name : "Online Editor" ,
28+ icon : ToolCase ,
29+ href : "https://graphscript-labs.github.io/editor" ,
30+ } ,
31+ {
32+ name : "Documentation" ,
33+ icon : LibraryBig ,
34+ href : "https://graphscript-labs.github.io/docs" ,
35+ } ,
36+ {
37+ name : "Open Source" ,
38+ icon : FolderGit2 ,
39+ href : "https://github.com/GraphScript-Labs" ,
40+ } ,
41+ ] ;
42+
1543 return ( < >
1644 < div className = "hero" >
1745 < div className = "content" >
@@ -26,11 +54,13 @@ export function Hero() {
2654 </ div >
2755 </ div >
2856 < div className = "actions" >
29- < HeroCard name = "Get Ecosystem" icon = { Trees } />
30- < HeroCard name = "GSAM Compiler" icon = { Drill } />
31- < HeroCard name = "Online Editor" icon = { ToolCase } />
32- < HeroCard name = "Documentation" icon = { LibraryBig } />
33- < HeroCard name = "Source Code" icon = { FolderGit2 } />
57+ {
58+ actions . map ( ( action , index ) => < HeroCard
59+ key = { index }
60+ { ...action }
61+ />
62+ )
63+ }
3464 </ div >
3565 </ div >
3666 </ > ) ;
Original file line number Diff line number Diff line change 11import { MoveUpRight } from "lucide-react" ;
22import "./style.css" ;
33
4- export function HeroCard ( { name, icon } ) {
4+ export function HeroCard ( { name, icon, href } ) {
55 const CardIcon = icon ;
66
7+ const openLink = ( ) => {
8+ if ( ! href ) return ;
9+ window . open ( href , "_blank" ) ;
10+ } ;
11+
712 return ( < >
8- < div className = "hero-card" >
13+ < div className = "hero-card" onClick = { openLink } >
914 < div className = "hero-card-icon-container" >
1015 < CardIcon className = "hero-card-icon" />
1116 </ div >
You can’t perform that action at this time.
0 commit comments