-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add banner to dev to indicate it is a dev site (#3147)
- Loading branch information
Fran McDade
authored and
Fran McDade
committed
Nov 8, 2024
1 parent
616db52
commit 1c9ea35
Showing
9 changed files
with
39 additions
and
2 deletions.
There are no files selected for viewing
3 changes: 3 additions & 0 deletions
3
components/Layout/components/Header/content/developmentModeBanner.mdx
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,3 @@ | ||
<Banner {...props}> | ||
<span>This is a development site. To view the production site, please visit https://anvilproject.org/.</span> | ||
</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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default as DevelopmentModeBanner } from "./developmentModeBanner.mdx"; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { MDXComponents } from "mdx/types"; | ||
import * as C from "./components"; | ||
import { Link } from "./components/common/Link/link"; | ||
|
||
export function useMDXComponents(components: MDXComponents): MDXComponents { | ||
return { | ||
...components, | ||
Banner: C.Banner, | ||
a: Link, | ||
}; | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
15 changes: 15 additions & 0 deletions
15
site-config/anvil-portal/dev/announcements/announcements.ts
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,15 @@ | ||
import { ALERT_PROPS } from "@databiosphere/findable-ui/lib/components/common/Banner/constants"; | ||
import { | ||
ComponentConfig, | ||
ComponentsConfig, | ||
} from "@databiosphere/findable-ui/lib/config/entities"; | ||
import * as MDX from "../../../../components/Layout/components/Header/content"; | ||
|
||
export const announcements: ComponentsConfig = [ | ||
{ | ||
component: MDX.DevelopmentModeBanner, | ||
props: { | ||
...ALERT_PROPS, | ||
}, | ||
} as ComponentConfig<typeof MDX.DevelopmentModeBanner>, | ||
]; |
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