-
Notifications
You must be signed in to change notification settings - Fork 109
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[#111]: Backport changes from ecosystem #161
Conversation
✅ Deploy Preview for spectacular-dragon-c1015c ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think code is ok for now though i have a few comments (don't need to change for them). Big thing missing is a bit of docs. I can do this quickly.
@@ -1,5 +1,5 @@ | |||
const config = { | |||
title: 'Flowershow', | |||
navbarTitle: { version: true }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
surely navbarTitle
is something like:
{
title: 'Flowershow',
logo: ...
version: 'Alpha'
}
@@ -14,6 +14,36 @@ function GitHubIcon(props) { | |||
); | |||
} | |||
|
|||
function NavbarTitle() { | |||
// include option to define different text from title (if needed) in config | |||
const title = siteConfig.navbarTitle?.text || siteConfig.title |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Personally, i would be strict and say if you use navbarTitle you have to set title in their too i.e. this is:
if (navbarTitle) {
use stuff from navbarTitle
} else {
use siteConfig.title
}
Why? Explicitness is better than magic!
Backport changes to flowershow after ecosystem upgrade
Tasks from #111
This PR adds changes in User config (for version), Navbar title, Dark/Light theme switcher, Search component and flowershow image assets.
Tasks
_flowershow
folder in public with images (logo and theme icon)Addrevert changesnavbarTitle
object insiteConfig.js
specific to flowershow stuff (title text, version, logo, etc)components/Nav,js
to render site title based off config valuesconfig.js
and properties can be set in optionalnavbarTitle
fortext [String]
,logo [Boolean]
andversion [Boolean]
handle SEO title for both cases inrevert to previous configpages/_app.js
env.development
file with test values to render search component in development modetheme.default
is an empty stringurl_path
in.contentlayer.config.js
to avoid conflicts if anyNotes
Searchbar component may not render in preview deploy as env variables will not be loaded. The searchbar rendering relies on having all three required algolia configs to be defined (ie. appId, apiKey and indexName)This worksupgrade.sh
package needs to be updated to remove.env.development
file