This repository has been archived by the owner on Oct 21, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: add build mode banner * fix: ts import
- Loading branch information
Showing
6 changed files
with
118 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import type { Meta, StoryObj } from "@storybook/react"; | ||
|
||
import Banner from "."; | ||
|
||
const meta: Meta<typeof Banner> = { | ||
component: Banner, | ||
}; | ||
|
||
export default meta; | ||
type Story = StoryObj<typeof Banner>; | ||
|
||
export const Example: Story = { | ||
args: {}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
import { useNavigationContext } from "@/contexts/NavigationContext"; | ||
import { Box, Flex, Text, CloseButton } from "@chakra-ui/react"; | ||
|
||
const Banner = () => { | ||
const { isBannerVisible, setIsBannerVisible } = useNavigationContext(); | ||
|
||
if (!isBannerVisible) { | ||
return null; | ||
} | ||
|
||
return ( | ||
<Box bg="orange.100" borderRadius={12} p={4} mb={"32px"}> | ||
<Flex justifyContent="space-between"> | ||
<Flex gap={"10px"}> | ||
<Flex | ||
alignItems="center" | ||
justifyContent="center" | ||
borderRadius={8} | ||
w={"40px"} | ||
h={"40px"} | ||
background={"white"} | ||
flexShrink={0} | ||
> | ||
<Text style={{ fontSize: 25 }}>🚧</Text> | ||
</Flex> | ||
<Box> | ||
<Text fontWeight="bold" color="orange.500"> | ||
WELCOME! KARDINAL IS STILL IN BUILD MODE | ||
</Text> | ||
<Text fontSize="sm" color={"gray.700"}> | ||
The features you see in the UI might differ from the CLI, we're | ||
currently working towards feature parity. <br /> If you have | ||
comments or suggestions, please{" "} | ||
<Text | ||
as="a" | ||
textDecoration="underline" | ||
cursor="pointer" | ||
href="https://github.com/kurtosis-tech/kardinal/issues" | ||
target="_blank" | ||
> | ||
open a github issue | ||
</Text>{" "} | ||
or{" "} | ||
<Text | ||
as="a" | ||
textDecoration="underline" | ||
cursor="pointer" | ||
href="mailto:[email protected]" | ||
> | ||
reach out via email | ||
</Text>{" "} | ||
and help us shape the product! | ||
</Text> | ||
</Box> | ||
</Flex> | ||
<CloseButton | ||
size="sm" | ||
onClick={() => { | ||
setIsBannerVisible(false); | ||
}} | ||
color="orange.500" | ||
/> | ||
</Flex> | ||
</Box> | ||
); | ||
}; | ||
|
||
export default Banner; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters