0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-05-07 18:48:39 +00:00

Add /embed endpoint

This duplicates the share endpoint. It uses the Share Page template
with a boolean for share vs embed to toggle displaying the navbar
and toolbar.

Added a showToolbar property to brewRender to toggle... showing
the toolbar.
This commit is contained in:
David Bolack
2026-02-06 18:01:53 -06:00
parent fabd280efa
commit f16c8b7663
4 changed files with 55 additions and 36 deletions
+2 -1
View File
@@ -61,7 +61,8 @@ const Homebrew = (props)=>{
<div className={`homebrew${(config.deployment || config.local) ? ' deployment' : ''}`} style={backgroundObject()}>
<Routes>
<Route path='/edit/:id' element={<WithRoute el={EditPage} brew={brew} userThemes={userThemes}/>} />
<Route path='/share/:id' element={<WithRoute el={SharePage} brew={brew} />} />
<Route path='/share/:id' element={<WithRoute el={SharePage} brew={brew} share={true} />} />
<Route path='/embed/:id' element={<WithRoute el={SharePage} brew={brew} share={false} />} />
<Route path='/new/:id' element={<WithRoute el={NewPage} brew={brew} userThemes={userThemes}/>} />
<Route path='/new' element={<WithRoute el={NewPage} userThemes={userThemes}/> } />
<Route path='/user/:username' element={<WithRoute el={UserPage} brews={brews} />} />