Skip to content

Instantly share code, notes, and snippets.

@danfisher85
Created August 14, 2020 21:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danfisher85/2f1c3f1ffd1db9eff865c37d23e94e61 to your computer and use it in GitHub Desktop.
Save danfisher85/2f1c3f1ffd1db9eff865c37d23e94e61 to your computer and use it in GitHub Desktop.
Color Presets
// Styling Options
Redux::setSection( $opt_name, array(
'title' => esc_html__( 'Styling', 'alchemists' ),
'icon' => 'el-icon-tint',
'id' => 'alchemists__section-styling',
'fields' => array(
array(
'id' => 'alchemists__color-preset',
'type' => 'image_select',
'compiler' => false,
'presets' => true,
'title' => esc_html__('Color Presets', 'alchemists'),
'desc' => esc_html__('Choose color preset you want to use.', 'alchemists'),
'default' => '1',
'options' => array(
// Color Scheme: Basketball
'1' => array(
'alt' => esc_html__( 'Basketball', 'alchemists' ),
'img' => get_template_directory_uri() . '/admin/images/pallete-basketball.png',
'presets' => array(
'color-primary' => '#ffdc11',
'color-primary-darken' => '#ffcc00',
'color-dark' => '#1e2024',
'color-dark-lighten' => '#292c31',
'color-gray' => '#9a9da2',
'color-2' => '#31404b',
'color-3' => '#ff7e1f',
'color-4' => '#9a66ca',
)
),
// Color Scheme: Soccer
'2' => array(
'alt' => esc_html__( 'Soccer', 'alchemists' ),
'img' => get_template_directory_uri() . '/admin/images/pallete-soccer.png',
'presets' => array(
'color-primary' => '#38a9ff',
'color-primary-darken' => '#1892ed',
'color-dark' => '#1e2024',
'color-dark-lighten' => '#292c31',
'color-gray' => '#9a9da2',
'color-2' => '#31404b',
'color-3' => '#07e0c4',
'color-4' => '#c2ff1f',
'color-4-darken' => '#9fe900',
)
),
// Color Scheme: American Football
'3' => array(
'alt' => esc_html__( 'Football', 'alchemists' ),
'img' => get_template_directory_uri() . '/admin/images/pallete-football.png',
'presets' => array(
'color-primary' => '#f92552',
'color-primary-darken' => '#f92552',
'color-dark' => '#323150',
'color-dark-2' => '#282840',
'color-dark-lighten' => '#383759',
'color-gray' => '#9e9caa',
'color-2' => '#3c3b5b',
'color-3' => '#9e69ee',
'color-4' => '#3ffeca',
'color-4-darken' => '#0fe3ab',
)
),
// Color Scheme: eSport
'4' => array(
'alt' => esc_html__( 'eSports', 'alchemists' ),
'img' => get_template_directory_uri() . '/admin/images/pallete-esports.png',
'presets' => array(
'color-primary' => '#00ff5b',
'color-primary-darken' => '#1bd75e',
'color-dark' => '#362b45',
'color-dark-2' => '#403351',
'color-dark-lighten' => '#392d49',
'color-gray' => '#a59cae',
'color-2' => '#6a3bc0',
'color-3' => '#f92552',
'color-4' => '#ffb400',
'color-4-darken' => '#ffb400',
)
),
),
),
array(
'id' => 'color-primary',
'type' => 'color',
'title' => esc_html__( 'Primary Color', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a primary color.', 'alchemists' ),
'default' => '#ffdc11',
'validate' => 'color',
'transparent' => false
),
array(
'id' => 'color-primary-darken',
'type' => 'color',
'title' => esc_html__( 'Primary Color - Alt', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a primary alt color.', 'alchemists' ),
'default' => '#ffcc00',
'validate' => 'color',
'transparent' => false
),
array(
'id' => 'color-dark',
'type' => 'color',
'title' => esc_html__( 'Dark Color', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a dark color.', 'alchemists' ),
'default' => '#1e2024',
'validate' => 'color',
'transparent' => false
),
array(
'id' => 'color-dark-2',
'type' => 'color',
'title' => esc_html__( 'Dark Color 2', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a dark color 2.', 'alchemists' ),
'default' => '#282840',
'validate' => 'color',
'class' => 'alchemists-field alchemists-field--football alchemists-field--football-only alchemists-field--color-dark-2',
'transparent' => false
),
array(
'id' => 'color-dark-lighten',
'type' => 'color',
'title' => esc_html__( 'Dark Color - Lighten', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a dark lighten color.', 'alchemists' ),
'default' => '#292c31',
'validate' => 'color',
'transparent' => false
),
array(
'id' => 'color-gray',
'type' => 'color',
'title' => esc_html__( 'Gray Color', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a gray color.', 'alchemists' ),
'default' => '#9a9da2',
'validate' => 'color',
'transparent' => false
),
array(
'id' => 'color-2',
'type' => 'color',
'title' => esc_html__( 'Secondary Color', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a secondary color.', 'alchemists' ),
'default' => '#31404b',
'validate' => 'color',
'transparent' => false
),
array(
'id' => 'color-3',
'type' => 'color',
'title' => esc_html__( 'Tertiary Color', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a tertiary color.', 'alchemists' ),
'default' => '#ff7e1f',
'validate' => 'color',
'transparent' => false
),
array(
'id' => 'color-4',
'type' => 'color',
'title' => esc_html__( 'Quaternary Color', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a quaternary color.', 'alchemists' ),
'default' => '#9a66ca',
'validate' => 'color',
'transparent' => false
),
array(
'id' => 'color-4-darken',
'type' => 'color',
'title' => esc_html__( 'Quaternary Color - Alt', 'alchemists' ),
'subtitle' => esc_html__( 'Pick a quaternary alt color.', 'alchemists' ),
'validate' => 'color',
'transparent' => false,
'class' => 'alchemists-field alchemists-field--football-only alchemists-field--soccer-only',
),
)
) );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment