Created
July 3, 2020 15:08
-
-
Save farookibrahim/918b401fce5906a9981109e43686c89e to your computer and use it in GitHub Desktop.
Front - Increase Collapse List Limit
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if( ! function_exists( 'front_child_collapse_rangecontrol_max_limit_increase' ) ) { | |
| function front_child_collapse_rangecontrol_max_limit_increase() { | |
| $custom_script = ' | |
| var addFilter = wp.hooks.addFilter; | |
| addFilter("frontgb.list-group.listlimit.edit.inspector.max.limit", "front-child/list-group-listlimit-edit-inspector-max-limit", frontChildCollapseRangeControlMaxLimit); | |
| function frontChildCollapseRangeControlMaxLimit(limit) { | |
| return 48; | |
| } | |
| '; | |
| wp_add_inline_script( 'wp-blocks', $custom_script ); | |
| } | |
| } | |
| add_action( 'enqueue_block_editor_assets', 'front_child_collapse_rangecontrol_max_limit_increase', 99 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment