[ Index ]

PHP Cross Reference of WordPress

title

Body

[close]

/wp-content/themes/twentytwenty/ -> functions.php (summary)

Twenty Twenty functions and definitions

File Size: 757 lines (27 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 21 functions

  twentytwenty_theme_support()
  twentytwenty_register_styles()
  twentytwenty_register_scripts()
  twentytwenty_skip_link_focus_fix()
  twentytwenty_non_latin_languages()
  twentytwenty_menus()
  twentytwenty_get_custom_logo()
  wp_body_open()
  twentytwenty_skip_link()
  twentytwenty_sidebar_registration()
  twentytwenty_block_editor_styles()
  twentytwenty_classic_editor_styles()
  twentytwenty_add_classic_editor_customizer_styles()
  twentytwenty_add_classic_editor_non_latin_styles()
  twentytwenty_block_editor_settings()
  twentytwenty_read_more_tag()
  twentytwenty_customize_controls_enqueue_scripts()
  twentytwenty_customize_preview_init()
  twentytwenty_get_color_for_area()
  twentytwenty_get_customizer_color_vars()
  twentytwenty_get_elements_array()

Functions
Functions that are not part of a class:

twentytwenty_theme_support()   X-Ref
Sets up theme defaults and registers support for various WordPress features.

Note that this function is hooked into the after_setup_theme hook, which
runs before the init hook. The init hook is too late for some features, such
as indicating support for post thumbnails.

twentytwenty_register_styles()   X-Ref
Register and Enqueue Styles.


twentytwenty_register_scripts()   X-Ref
Register and Enqueue Scripts.


twentytwenty_skip_link_focus_fix()   X-Ref
Fix skip link focus in IE11.

This does not enqueue the script because it is tiny and because it is only for IE11,
thus it does not warrant having an entire dedicated blocking script being loaded.


twentytwenty_non_latin_languages()   X-Ref
No description

twentytwenty_menus()   X-Ref
Register navigation menus uses wp_nav_menu in five places.


twentytwenty_get_custom_logo( $html )   X-Ref
Get the information about the logo.

return: string $html
param: string $html The HTML output from get_custom_logo (core function).

wp_body_open()   X-Ref
Shim for wp_body_open, ensuring backwards compatibility with versions of WordPress older than 5.2.


twentytwenty_skip_link()   X-Ref
Include a skip to content link at the top of the page so that users can bypass the menu.


twentytwenty_sidebar_registration()   X-Ref
Register widget areas.


twentytwenty_block_editor_styles()   X-Ref
Enqueue supplemental block editor styles.


twentytwenty_classic_editor_styles()   X-Ref
Enqueue classic editor styles.


twentytwenty_add_classic_editor_customizer_styles( $mce_init )   X-Ref
Output Customizer settings in the classic editor.
Adds styles to the head of the TinyMCE iframe. Kudos to @Otto42 for the original solution.

return: array $mce_init TinyMCE styles.
param: array $mce_init TinyMCE styles.

twentytwenty_add_classic_editor_non_latin_styles( $mce_init )   X-Ref
Output non-latin font styles in the classic editor.
Adds styles to the head of the TinyMCE iframe. Kudos to @Otto42 for the original solution.

return: array $mce_init TinyMCE styles.
param: array $mce_init TinyMCE styles.

twentytwenty_block_editor_settings()   X-Ref
Block Editor Settings.
Add custom colors and font sizes to the block editor.


twentytwenty_read_more_tag( $html )   X-Ref
Overwrite default more tag with styling and screen reader markup.

return: string $html
param: string $html The default output HTML for the more tag.

twentytwenty_customize_controls_enqueue_scripts()   X-Ref
Enqueues scripts for customizer controls & settings.

return: void
since: Twenty Twenty 1.0

twentytwenty_customize_preview_init()   X-Ref
Enqueue scripts for the customizer preview.

return: void
since: Twenty Twenty 1.0

twentytwenty_get_color_for_area( $area = 'content', $context = 'text' )   X-Ref
Get accessible color for an area.

return: string Returns a HEX color.
since: Twenty Twenty 1.0
param: string $area The area we want to get the colors for.
param: string $context Can be 'text' or 'accent'.

twentytwenty_get_customizer_color_vars()   X-Ref
Returns an array of variables for the customizer preview.

return: array
since: Twenty Twenty 1.0

twentytwenty_get_elements_array()   X-Ref
Get an array of elements.

return: array
since: Twenty Twenty 1.0



Generated: Wed Dec 11 01:00:03 2019 Cross-referenced by PHPXref 0.7.1