Skip to content

Commit

Permalink
adds direction to navigation
Browse files Browse the repository at this point in the history
  • Loading branch information
jake-figma committed Jun 15, 2024
1 parent 35ced8e commit 803e58f
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/ui/Navigation/Navigation.figma.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,22 @@ import { figma } from "@figma/code-connect";
import { Navigation, NavigationItem } from "./Navigation";

figma.connect(Navigation, "<FIGMA_URL_NAVIGATION>", {
props: { children: figma.children("Navigation Item") },
example: ({ children }) => <Navigation>{children}</Navigation>,
props: {
children: figma.children("Navigation Item"),
direction: figma.enum("Direction", {
Row: "row",
Column: "column",
}),
},
example: ({ children, direction }) => (
<Navigation direction={direction}>{children}</Navigation>
),
});

figma.connect(NavigationItem, "<FIGMA_URL_NAVIGATION_ITEM>", {
props: {
text: figma.string("Text"),

isSelected: figma.enum("State", {
On: true,
Off: undefined,
Expand Down

0 comments on commit 803e58f

Please sign in to comment.