Skip to content

Commit 8f09dca

Browse files
Add Library Pages in NavBar (#443)
* Add Library Pages in NavBar * Address review comments * Update docs/resources/projects/libraries.md --------- Co-authored-by: Pooja Bhaumik <[email protected]>
1 parent c333684 commit 8f09dca

File tree

2 files changed

+46
-3
lines changed

2 files changed

+46
-3
lines changed
Binary file not shown.

docs/resources/projects/libraries.md

Lines changed: 46 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -253,17 +253,17 @@ You can easily upgrade to newer versions of the libraries as they become availab
253253

254254
## Library Pages
255255

256-
You can also add and manage pages within a library, making it easy to reuse those pages across multiple projects. These pages function like any regular project page in your app; they support navigation, parameters, state management, and transitions.
256+
When you publish a library, all the pages included in the library become available for use in the consumer project. These pages function like any regular project page in your app; they support navigation, parameters, state management, and transitions.
257257

258-
Including pages with libraries offers a modular approach to development, making it ideal for large teams and complex, multi-feature apps. For example, instead of recreating common flows like onboarding and payment flows, you can build them in a library once and use them wherever needed.
258+
Library Pages offers a modular approach to development, making it ideal for large teams and complex, multi-feature apps. For example, instead of recreating common flows like onboarding and payment flows, you can build them in a library once and use them wherever needed.
259259

260260
:::tip[Possible Use Cases]
261261
- **Super Apps** like Gojek and Uber with distinct modules such as ride booking, shopping, and payments. Each module can be developed as a separate library and imported into a single main project.
262262
- **Enterprise Apps** with isolated user journeys for different roles, such as admin and customer. Each role-based flow can be built as its own library and integrated into the core app as needed.
263263
- **White-labeled Apps** that share common onboarding flows can benefit from libraries. The onboarding process can be built once as a library and reused across all branded versions of the app.
264264
:::
265265

266-
The library author selects which pages to include and publishes the library. When users import or update the library, they can override the default route names to prevent conflicts between the library and their project. Library pages then appear in navigation actions just like any regular page.
266+
When users import or update the library, they can override the default route names to prevent conflicts between the library and their project. Library pages then appear in navigation actions just like any regular page.
267267

268268
<div style={{
269269
position: 'relative',
@@ -291,7 +291,50 @@ The library author selects which pages to include and publishes the library. Whe
291291
</div>
292292
<p></p>
293293

294+
### Library Pages in NavBar
294295

296+
Library pages can also be used in the NavBar, allowing users to add reusable flows into the app’s primary navigation structure. For example, in a Super App, you can import ride booking, food delivery, or payment pages from separate libraries and add them directly to the bottom navigation, giving users quick access to each module.
297+
298+
:::tip
299+
Want to learn more about building modular Super Apps using libraries? Check out our [**blog post**](https://blog.flutterflow.io/scaling-super-apps-modular-architecture-with-flutterflow-libraries/).
300+
:::
301+
302+
To display a library page on the NavBar, navigate to **Project Dependencies > FlutterFlow Libraries**, then click on **Pages** for the relevant library to open its details. In the list of pages, locate the desired page and click **Nav Bar Settings**, then enable **Show on NavBar**. You can also customize additional settings, such as label and icon, as needed.
303+
304+
To confirm, go to the **Nav Bar & App Bar** section, where you’ll see the library page listed as part of the NavBar items.
305+
306+
:::info
307+
NavBar settings for regular pages are available directly within the Page Settings panel in the builder. However, for Library pages, these settings are managed through the Library Details dialog.
308+
309+
![NavBar-settings-for-regular-and-library-page](imgs/NavBar-settings-for-regular-and-library-page.avif)
310+
:::
311+
312+
313+
<div style={{
314+
position: 'relative',
315+
paddingBottom: 'calc(56.67989417989418% + 41px)', // Keeps the aspect ratio and additional padding
316+
height: 0,
317+
width: '100%'}}>
318+
<iframe
319+
src="https://demo.arcade.software/BDac382RQTHTKFhtZcsc?embed&show_copy_link=true"
320+
title=""
321+
style={{
322+
position: 'absolute',
323+
top: 0,
324+
left: 0,
325+
width: '100%',
326+
height: '100%',
327+
colorScheme: 'light'
328+
}}
329+
frameborder="0"
330+
loading="lazy"
331+
webkitAllowFullScreen
332+
mozAllowFullScreen
333+
allowFullScreen
334+
allow="clipboard-write">
335+
</iframe>
336+
</div>
337+
<p></p>
295338

296339
## Library Values
297340

0 commit comments

Comments
 (0)