ForgeComponents
en

Components

j-FloatingSearch

jComponent 20 · jcomponent@20 component Example loaded with jComponent 20

A simple floating search input. It uses absolute position and it's targeted above of toolbars because it can overlay the toolbar.


Configuration

  • placeholder {String} A placeholder for input (default: empty)
  • height {Number} A height in pixels (default: 45)

Methods:

  • floatingsearch/show shows the component in the current position
  • floatingsearch/hide hides the component

Use it with <ui-component name="floatingsearch">. When the component is not loaded yet, jComponent downloads it on first use from the address in DEF.fallback (the Componentator CDN by default). Author: Peter Širka. Source: the Componentator components repository, MIT license.

example.html
<div style="position:relative">
	<ui-component name="floatingsearch" path="pathtosearch"></ui-component>
	<div style="height:45px;background-color:#F0F0F0;line-height:45px;padding:0 12px;">
		<div class="exec pull-right" data-exec="showsearch"><i class="ti ti-search"></i></div>
		TOOLBAR
	</div>
</div>
<br />
<ui-bind path="pathtosearch" config="text b" class="block">You're searching: <b></b></ui-bind>

<script>
	function showsearch() {
		SETTER('floatingsearch/show');
	}
</script>