@redturtle/volto-searchblocks
v0.1.5
Published
Additional control-panel that allow users to search which contents using a specific block
Downloads
40
Readme
Search blocks (volto-searchblocks)
A Volto add-on that provides a control panel for searching and managing content that uses specific blocks.
Features ✨
- Search Blocks Control Panel: Dedicated control panel view for searching content by block types
- Table Display: Results displayed in a sortable table with key metadata
- Pagination: Navigate through results with configurable page sizes (default, 50, or all)
- Block Type Selection: Dropdown selector for choosing which block type to search for
- Multilingual Support: Full i18n support with Italian translation included
- Error Handling: Comprehensive error displays for API failures
- Semantic UI Integration: Uses Volto's standard Semantic UI components for consistent styling
Installation
To install your project, you must choose the method appropriate to your version of Volto.
Volto 18 and later
Add volto-searchblocks to your package.json.
"dependencies": {
"volto-searchblocks": "*"
}Add volto-searchblocks to your volto.config.js.
const addons = ['volto-searchblocks'];If this package provides a Volto theme, and you want to activate it, then add the following to your volto.config.js.
const theme = 'volto-searchblocks';Volto 17 and earlier
Create a new Volto project. You can skip this step if you already have one.
npm install -g yo @plone/generator-volto
yo @plone/volto my-volto-project --addon volto-searchblocks
cd my-volto-projectAdd volto-searchblocks to your package.json.
"addons": [
"volto-searchblocks"
],
"dependencies": {
"volto-searchblocks": "*"
}Download and install the new add-on.
yarn installStart Volto.
yarn startTest installation
Visit http://localhost:3000/ in a browser, login, and check the awesome new features.
Development
The development of this add-on is done in isolation using pnpm workspaces, the latest mrs-developer, and other Volto core improvements.
For these reasons, it only works with pnpm and Volto 18.
Prerequisites ✅
- An operating system that runs all the requirements mentioned.
- nvm
- Node.js and pnpm 22
- Make
- Git
- Docker (optional)
Installation 🔧
Clone this repository, then change your working directory.
git clone [email protected]:collective/collective-searchblocks.git cd collective-searchblocks/frontendInstall this code base.
make install
Make convenience commands
Run make help to list the available Make commands.
Set up development environment
Install package requirements.
make installStart developing
Start the backend.
make backend-docker-startIn a separate terminal session, start the frontend.
make startLint code
Run ESlint, Prettier, and Stylelint in analyze mode.
make lintFormat code
Run ESlint, Prettier, and Stylelint in fix mode.
make formati18n
Extract the i18n messages to locales.
make i18nUnit tests
Run unit tests.
make testRun Cypress tests
Run each of these steps in separate terminal sessions.
In the first session, start the frontend in development mode.
make acceptance-frontend-dev-startIn the second session, start the backend acceptance server.
make acceptance-backend-startIn the third session, start the Cypress interactive test runner.
make acceptance-testLicense
The project is licensed under the MIT license.
