Kodefix Sticky Bar

Description

Kodefix Sticky Bar adds a container block for the block editor. Place any blocks inside it — paragraphs, buttons, Kadence Row Layout, sections, and more. The bar stays in its place in the page layout and only pins to the top or bottom of the viewport once you scroll past it (CSS position: sticky).

Features

  • Nest any Gutenberg blocks inside the sticky bar
  • Choose top or bottom sticky edge
  • Offset and z-index controls to avoid clashes with other sticky or fixed elements (theme headers, admin bar)
  • Optional admin bar compensation on the front end
  • Hide the bar below a chosen viewport width
  • Optionally keep the bar hidden until a chosen page element (anchor ID) appears on screen or leaves above the viewport

Development

Compiled editor and front scripts under dist/assets/ (for example editor-*.js, view-*.js, and related CSS) are built with Vite 7, @kucrut/vite-for-wp, and @vitejs/plugin-react. WordPress provides react and @wordpress/* as externals; they are not bundled.

Human-readable sources that match those builds ship inside this plugin under assets/src/ (editor.tsx, view.ts, style.ts, style.css).

To regenerate the compiled files from a full monorepo checkout:

  1. cd plugins/blocks/front
  2. pnpm install
  3. pnpm run build -- kfx-sticky-bar

Installation

  1. Upload the plugin folder to /wp-content/plugins/kfx-sticky-bar/
  2. Activate through the Plugins menu
  3. In the block editor, insert Kodefix Sticky Bar and add blocks inside it
  4. Adjust position, offset, and z-index in the block sidebar

FAQ

Does this require Kadence?

No. Kadence blocks work inside the bar when Kadence is installed, but they are not required.

Why does sticky not work on my layout?

CSS sticky only works when ancestor elements use overflow: visible. Some page-builder wrappers set overflow: hidden or auto, which disables sticky. Move the bar outside that wrapper or adjust the parent overflow.

Can I stack multiple sticky bars?

Yes. Use offset and z-index to separate them when they are stuck.

Reviews

There are no reviews for this plugin.

Contributors & Developers

“Kodefix Sticky Bar” is open source software. The following people have contributed to this plugin.

Contributors

Translate “Kodefix Sticky Bar” into your language.

Interested in development?

Browse the code, check out the SVN repository, or subscribe to the development log by RSS.

Changelog

1.0.0

  • Initial release.