VAT
Your cart

Your cart is empty.

Mobile hooks

This page lists the 4 hooks of this group. Each entry shows its type, the version it arrived in, where it runs, its arguments and a starting point.

adba_card_columns

FilterSince 2.4.0 Runs in src/Modules/Mobile/CardColumns.php.

Filters which columns make up the card of a list row on phones (600px and below).

ArgumentTypeDescription
$cardsarray<string, array<string, mixed>>Screen id => { title, badge, media, handle: column keys; meta: up to 3 column keys (fields before 2.8.0); labels: meta keys that show their column name }. Add a screen to give its list cards; an empty title leaves it to the general card of plugin lists.
add_filter( 'adba_card_columns', function ( $cards ) {
	return $cards;
} );

adba_column_priority

FilterSince 2.8.0 Runs in src/Modules/Mobile/ColumnPriority.php.

Filters the column priorities of list tables on tablets (601 to 782px). Priority 1 always shows, 2 from 701px, 3 not on a tablet; a column without a priority counts as 3. A screen without priorities is stacked as WordPress does it.

ArgumentTypeDescription
$prioritiesarray<string, array<string, int>>Screen id => column key => 1, 2 or 3. By default only the current screen, from its card.
$screen_idstringCurrent screen id.
add_filter( 'adba_column_priority', function ( $priorities, $screen_id ) {
	return $priorities;
}, 10, 2 );

adba_input_modes

FilterSince 2.8.0 Runs in src/Modules/Mobile/Mobile.php.

Filters which keyboard a phone shows for a field: CSS selector => { inputmode, autocomplete }. Addofy only sets the attributes a field does not have yet; the field stays where it is.

ArgumentTypeDescription
$modesarray<string, array<string, string>>Selector => { inputmode: none, text, decimal, numeric, tel, search, email or url; autocomplete: a token }.
add_filter( 'adba_input_modes', function ( $modes ) {
	return $modes;
} );

adba_mobile_nav_items

FilterSince 2.8.0 Runs in src/Modules/Mobile/BottomNav.php.

Filters the items of the navigation bar at the bottom of phones (experimental setting bottom_nav).

ArgumentTypeDescription
$itemsarray<int, array<string, mixed>>Items: id, label, url, icon (SVG path data on a 16px grid, stroked) and screens (screen ids where the item is the current one). Five fit on a phone.
$screen_idstringCurrent screen id.
add_filter( 'adba_mobile_nav_items', function ( $items, $screen_id ) {
	return $items;
}, 10, 2 );

Ready to connect your AI to real tools?

Start free trial