I think in the core files of the plugin: the typography type is defined like thisβ
Kirki::add_field( 'my_config', array(
'type' => 'typography',
'settings' => 'h1_typography',
'label' => esc_attr__( 'H1 Typography', 'textdomain' ),
'section' => 'typography',
'default' => array(
'font-family' => 'Roboto',
'variant' => 'regular',
'font-size' => '14px',
'line-height' => '1.5',
'letter-spacing' => '0',
'subsets' => array( 'latin-ext' ),
'color' => '#333333',
'text-transform' => 'none',
'text-align' => 'left'
),
'priority' => 10,
'output' => array(
array(
'element' => 'body',
),
),
) );

If we wish to add/delete a Field in this How can we do this?
One this is done from scratch that means add whatever field you want, but I like the way in terms of the CSS and looks it appears in the backend.
But I believe this should be modifiable through some functions.
for now let us restrict my self to doing these two types in the `'type' => 'typography',:
Point Number 1 is very Important though.
adding a slider to manage font-size
If you use a slider to manage font-size, then doesn't that mean you'll be forcing your users to use pixels? What if I want or need to use em, rem, vh, %, pt or any other valid CSS unit?
removing subsets
This one is more complicated than it sounds. font-family, variant and subsets are all necessary to properly build the font-family for the google-api. Besides, if you remove subsets, doesn't that exclude every site that's not in English? If a site is in Russian, Greek or anything other than latin, then they need to be able to select the proper subset for their fonts.
If you want to hide some elements (other than subsets and variants which are part of the font-family) you can just delete their default values from your field π
Right, sir, slider won't be a good option for font-size. or maybe a future update may have a slider + a drop down(Just next to a slider) for 'px','em',rem'','etc'.
Thanks for all your support and prompt reply. All these discussions are very helpful.
Marking this one as a feature request for v3.1 π
You are nice. A real gentleman. Thank you so much, sir. Cheers!
Most helpful comment
Marking this one as a feature request for v3.1 π