Advanced Custom Fields: Typography Field | Mujahid Ishtiaq | acf

Advanced Custom Fields: Typography Field | Mujahid Ishtiaq | acf,addon,admin,advanced custom fields,typography

Description

Typography field type for “Advanced Custom Fields” plugin that lets you add different text properties e.g. Font Size, Font Family, Font Color etc.

Version 3.0.0 Introduces

  • Support for Google Fonts
  • The selected Google Fonts CSS is automatically enqueued on front-end of posts/pages
  • Plugin functions and shortcode to fetch properties

Supported Subfields

  • Font Size
  • Font Family
  • Font Weight
  • Font Style
  • Font Variant
  • Font Stretch
  • Line Height
  • Letter Spacing
  • Text Align
  • Text Color
  • Text Decoration
  • Text Transform

Other Features

  • Support for Google Fonts
  • The selected Google Fonts CSS is automatically enqueued on front-end of posts/pages
  • Option to show/hide each subfield individually
  • Option to make each subfield required individually
  • Color Picker for Text Color subfield

Documentation

// Returns the value of a specific property
get_typography_field( $selector, $property, [$post_id], [$format_value] );

// Displays the value of a specific property
the_typography_field( $selector, $property, [$post_id], [$format_value] );

// Returns the value of a specific property from a sub field.
get_typography_sub_field( $selector, $property, [$format_value] );

// Displays the value of a specific property from a sub field.
the_typography_sub_field( $selector, $property, [$format_value] );

Shortcode

[acf_typography field="field-name" property="font_size" post_id="123" format_value="1"]

[Github repository](https://github.com/mujahidi/acf-typography)

Compatibility

This ACF field type is compatible with:
* Free and paid versions of the ACF plugin

Installation

  1. Copy the acf-typography-field folder into your wp-content/plugins folder
  2. Activate the Typography plugin via the plugins admin page
  3. Google API Key is required for Google Fonts. Please add one by going to WordPress Admin Dashboard > Settings > ACF Typography Settings
  4. Create a new field via ACF and select the Typography type
  5. Please refer to the description for more info regarding the field type settings

Plugin author

Mujahid Ishtiaq

Plugin official website address

https://wordpress.org/plugins/acf-typography-field/
If you encounter problems in using the Advanced Custom Fields: Typography Field plugin, you can comment below, and I will try my best to help you solve the problem

Leave a Comment

Your email address will not be published. Required fields are marked *