B
Bonzai 2
Web Parts

Document Portal

Full-featured document search with typeahead suggestions, popular searches, favourites, and multiple view modes.

DocumentsFeature Parity: 85%

Get Document Portal Working in 3 Steps

15-30 minutes

Prerequisites

  • Bonzai 2 package installed on your site
  • Documents in a SharePoint library (indexed by search)
1

Add the web part to a full-width section

Edit the page, add a full-width section, click + and search for "Document Portal".

2

Configure result source (optional)

Open the property pane and set the Result Source to a specific search result source, or leave empty for default.

3

Enable favourites and previews

Toggle on "Show Favourite Documents" and "Show Document Previews" for the full experience, then publish.

When to Use This Web Part

Use this when you need to...

  • Create a dedicated document search center
  • Enable users to find documents across multiple libraries
  • Provide document filtering by type, author, date, or custom metadata
  • Allow users to bookmark frequently accessed documents
  • Build a department-specific document repository page

Best page locations

  • Document Center page — dedicated full-page experience
  • Department landing page — filtered to department documents
  • Knowledge base page — searchable documentation library
  • Policies page — regulatory and policy documents

Consider alternatives when...

  • Displaying a fixed list of specific documents — use Documents Rollup
  • Showing recent documents only — use Documents Rollup with date filter
  • Simple file list without search — use Documents Table

Related web parts:

Documents Rollupsimple document list or cardsDocuments Tabletabular view without searchFavourite Documentsbookmarked documents only

Step-by-Step Configuration

1

Create a new page for your Document Portal

Go to Site Pages, create a new page named "Document Center" or "Documents". Use a single-column layout for best results.

Document Portal works best as the main content on a dedicated page.

2

Add a full-width section

In edit mode, add a new section with a full-width layout. This gives the portal maximum space.
3

Add the Document Portal web part

Click the + button, search for "Document Portal", and add it to the full-width section.
4

Configure the Result Source (optional)

Open the property pane and set the Result Source to a specific SharePoint search result source name or ID, or leave empty for the default search.

Result sources control which content is searched. Ask your admin for available result source names.

5

Configure typeahead display fields

Set "Typeahead Display Fields" to configure what appears in search suggestions. Format: "Label:ManagedProperty;Label2:Property2".
6

Choose the default view

Select "Default View" as List or Grid to control how search results display.
7

Enable favourite documents

Toggle "Show Favourite Documents" to display a favourites section where users can see their bookmarked documents.
8

Set items per page

Configure how many documents appear per page using the "Items Per Page" slider (10-100).
9

Publish and test search

Save and publish. Test by searching for known documents and verifying results appear correctly.

Common Configurations

Copy these ready-to-use configurations:

Company Document Center

Full-featured search for all company documents

Best for: Dedicated document search page
Configuration
titleDocument Center
defaultViewlist
showFavouriteDocumentsOn
showDocumentPreviewsOn
showPopularSearchesOn
itemsPerPage30

Department Documents

Using a specific result source for a team

Best for: Team or department page
Configuration
titleHR Documents
resultSourceHR Documents Result Source
defaultViewgrid
showFavouriteDocumentsOn
itemsPerPage20

Policy Repository

Filtered to policy documents with search filters

Best for: Compliance and policy pages
Configuration
titlePolicies & Procedures
resultSourcePolicies
showFavouriteDocumentsOn
showDocumentPreviewsOn
sortOrdername

My Documents Quick Access

Favourites-focused for personal bookmarks

Best for: Personal dashboard pages
Configuration
titleMy Documents
showFavouriteDocumentsOn
enableWildcardSearchOn
itemsPerPage15

Best Practices

Allow time for search indexing

Newly uploaded documents may take 15-30 minutes to appear in search results. SharePoint search crawls content periodically, not in real-time.

Use specific search scopes for performance

Narrowing the search scope to a specific site or library improves query speed and gives users more relevant results.

Add metadata for better refinement

Documents with rich metadata (document type, department, project) enable more useful refinement filters. Encourage content owners to tag documents.

Verify permissions before publishing

Document Portal respects SharePoint permissions. Users will only see documents they have access to. Test with a regular user account before launch.

Troubleshooting

Still need help? Contact Bonzai Support


Reference

Technical details for developers and advanced users.

FavouriteDocuments List Schema (optional)

The favourites section stores bookmarks in a SharePoint list named FavouriteDocuments. Create this list only if you enable "Show Favourite Documents".

  1. Create a list named FavouriteDocuments in the same site.
  2. Add the required columns below.
  3. Ensure users have Contribute permissions to save favourites.
ColumnTypeRequiredNotes
TitleSingle line of textYesDocument title
DocumentPathHyperlinkYesDocument URL
DocumentIdSingle line of textYesSearch DocId / UniqueId
FileExtensionSingle line of textYesFile extension (e.g., pdf, docx)
AddedDateDate/TimeYesSaved when favourite is added

Related Components

Document Portal works with companion components:

  • Favourite Documents: User bookmarks for documents (integrated into Document Portal)
  • Documents Rollup: For displaying a fixed list of documents without search
  • Documents Table: For tabular document display

Property Pane Configuration

Site Selection

PropertyTypeDescription
siteSelectionModeDropdownSelect from available sites (picker) or enter a site URL manually
selectedSiteUrlDropdownSite dropdown (picker mode, loaded via Microsoft Graph)
siteUrlTextManual site URL (manual mode, optional)

Search Settings

PropertyTypeDescription
resultSourceTextSharePoint Search result source name/ID (optional)
searchLabelOptionDropdownPreset search placeholder option (or Custom)
searchLabelTextCustom placeholder text (used when searchLabelOption = custom)
enableWildcardSearchToggleEnable wildcard search (*term*)
typeaheadFieldsMulti-selectManaged properties shown in typeahead suggestions
typeaheadDisplayFieldsText (Multiline)Legacy/fallback format: "Label:ManagedProperty;Label2:Property2"
searchFilterFieldsMulti-selectManaged properties available as filters/refiners
searchFiltersText (Multiline)Legacy/fallback filter configuration
itemsPerPageSlider (10-100)Number of results per page

Display Settings

PropertyTypeDescription
defaultViewDropdownDefault view mode: List or Grid
listViewColumnsMulti-selectManaged properties shown as columns in List view
listViewDisplayPropertiesText (Multiline)Legacy/fallback list columns format: "Label:ManagedProperty;..."
gridViewColumnsMulti-selectManaged properties shown as fields in Grid view
gridViewDisplayPropertiesText (Multiline)Legacy/fallback grid format: "Label:ManagedProperty;..."
visibleMetadataFieldsMulti-selectWhich metadata fields appear on each result
showMetadataChipsToggleShow metadata chips on results
showSortDropDownToggleShow sort dropdown to users
sortOrderDropdownDefault sort: Relevance, Date, or Name
showViewToggleToggleShow the List/Grid view toggle (disabled in Search-only mode)
showFiltersPanelToggleShow the filters panel when refiners exist (disabled in Search-only mode)
trimDuplicatesToggleRemove duplicate results from search

Features

PropertyTypeDescription
searchOnlyModeToggleMinimal UI preset (hides some end-user controls)
showResultsToggleShow search results section
showPopularSearchesToggleShow popular searches section
showFavouriteDocumentsToggleShow favourite documents section
favouriteDocumentsLabelTextLabel for the favourites section
showCustomDocumentLinksToggleShow a custom links section above/beside results
customDocumentLinksLabelTextLabel for the custom links section
customDocumentLinksCollection DataManually managed custom document links
showDocumentPreviewsToggleEnable document preview functionality

Title & Navigation

PropertyTypeDescription
titleTextWeb part title
titleUrlTextURL to make the title clickable
titleIconOptionDropdownTitle icon mode: Select Icon or None
titleIconNameIcon PickerFluent UI icon picker (default: DocumentSearch)
titleIconUrlTextCustom icon URL (overrides icon name)

Appearance

PropertyTypeDescription
chromeTypeDropdownChrome type: None, Title Only, Border Only, Title and Border
fixedHeightSlider (200-800)Fixed height in pixels

Advanced

PropertyTypeDescription
descriptionText (Multiline)Web part description
helpUrlTextHelp documentation URL

Features Checklist

  • ✅ Full-text document search
  • ✅ Typeahead suggestions (configurable display fields)
  • ✅ Popular searches section
  • ✅ Favourite documents integration
  • ✅ List and Grid view modes
  • ✅ Configurable sort options
  • ✅ Wildcard search support
  • ✅ Document previews
  • ✅ Pagination
  • ✅ Duplicate result trimming

Migration from Classic

AspectClassicModern
TechnologyJSOM + CAML queriesSPFx + SharePoint Search REST API
TypeaheadBrick configurationConfigured via typeaheadDisplayFields property
View ModesList onlyList and Grid view options
FavouritesSeparate web partIntegrated section (toggle)
Popular SearchesNot availableBuilt-in section (toggle)