/**
* Sticky Header - Customizer.
*
* @package Astra Addon
* @since 1.0.0
*/
if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly.
}
if ( ! class_exists( 'Astra_Ext_Transparent_Header_Loader' ) ) {
/**
* Customizer Initialization
*
* @since 1.0.0
*/
class Astra_Ext_Transparent_Header_Loader {
/**
* Member Variable
*
* @var instance
*/
private static $instance;
/**
* Initiator
*/
public static function get_instance() {
if ( ! isset( self::$instance ) ) {
self::$instance = new self();
}
return self::$instance;
}
/**
* Constructor
*/
public function __construct() {
add_filter( 'astra_theme_defaults', array( $this, 'theme_defaults' ) );
add_action( 'customize_preview_init', array( $this, 'preview_scripts' ) );
add_action( 'customize_register', array( $this, 'customize_register' ), 2 );
}
/**
* Set Options Default Values
*
* @param array $defaults Astra options default value array.
* @return array
*/
public function theme_defaults( $defaults ) {
// Header - Transparent.
$defaults['transparent-header-logo'] = '';
$defaults['transparent-header-retina-logo'] = '';
$defaults['different-transparent-logo'] = 0;
$defaults['different-transparent-retina-logo'] = 0;
$defaults['transparent-header-logo-width'] = array(
'desktop' => 150,
'tablet' => 120,
'mobile' => 100,
);
$defaults['transparent-header-enable'] = 0;
$defaults['transparent-header-disable-archive'] = 1;
$defaults['transparent-header-disable-latest-posts-index'] = 1;
$defaults['transparent-header-on-devices'] = 'both';
$defaults['transparent-header-main-sep'] = '';
$defaults['transparent-header-main-sep-color'] = '';
/**
* Transparent Header
*/
$defaults['transparent-header-bg-color'] = '';
$defaults['transparent-header-color-site-title'] = '';
$defaults['transparent-header-color-h-site-title'] = '';
$defaults['transparent-menu-bg-color'] = '';
$defaults['transparent-menu-color'] = '';
$defaults['transparent-menu-h-color'] = '';
$defaults['transparent-submenu-bg-color'] = '';
$defaults['transparent-submenu-color'] = '';
$defaults['transparent-submenu-h-color'] = '';
/**
* Transparent Header Responsive Colors
*/
$defaults['transparent-header-bg-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-header-color-site-title-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-header-color-h-site-title-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-menu-bg-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-menu-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-menu-h-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-submenu-bg-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-submenu-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-submenu-h-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-content-section-text-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-content-section-link-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
$defaults['transparent-content-section-link-h-color-responsive'] = array(
'desktop' => '',
'tablet' => '',
'mobile' => '',
);
return $defaults;
}
/**
* Add postMessage support for site title and description for the Theme Customizer.
*
* @param WP_Customize_Manager $wp_customize Theme Customizer object.
*/
public function customize_register( $wp_customize ) {
// @codingStandardsIgnoreStart WPThemeReview.CoreFunctionality.FileInclude.FileIncludeFound
/**
* Register Panel & Sections
*/
require_once ASTRA_THEME_TRANSPARENT_HEADER_DIR . 'classes/class-astra-transparent-header-panels-and-sections.php';
/**
* Sections
*/
require_once ASTRA_THEME_TRANSPARENT_HEADER_DIR . 'classes/sections/class-astra-customizer-colors-transparent-header-configs.php';
// Check Transparent Header is activated.
require_once ASTRA_THEME_TRANSPARENT_HEADER_DIR . 'classes/sections/class-astra-customizer-transparent-header-configs.php';
// @codingStandardsIgnoreEnd WPThemeReview.CoreFunctionality.FileInclude.FileIncludeFound
}
/**
* Customizer Preview
*/
public function preview_scripts() {
/**
* Load unminified if SCRIPT_DEBUG is true.
*/
/* Directory and Extension */
$dir_name = ( SCRIPT_DEBUG ) ? 'unminified' : 'minified';
$file_prefix = ( SCRIPT_DEBUG ) ? '' : '.min';
wp_enqueue_script( 'astra-transparent-header-customizer-preview-js', ASTRA_THEME_TRANSPARENT_HEADER_URI . 'assets/js/' . $dir_name . '/customizer-preview' . $file_prefix . '.js', array( 'customize-preview', 'astra-customizer-preview-js' ), ASTRA_THEME_VERSION, true );
// Localize variables for further JS.
wp_localize_script(
'astra-transparent-header-customizer-preview-js',
'AstraBuilderTransparentData',
array(
'is_astra_hf_builder_active' => Astra_Builder_Helper::$is_header_footer_builder_active,
'is_flex_based_css' => Astra_Builder_Helper::apply_flex_based_css(),
)
);
}
}
}
/**
* Kicking this off by calling 'get_instance()' method
*/
Astra_Ext_Transparent_Header_Loader::get_instance();
A lot of my pals are to order property immediately, and i also enjoys a great amount of inquiries in their mind. I always start from the inquiring the fresh non-invasive issues, for example why they will have chose to say goodbye to leasing otherwise just how they got on the house of its dreams. Following, I inquire the latest burning matter I recently wish to know – exactly how are they affording this new down payment.
A buddy has just told me she withdrew 50 % of the cash from inside the the woman 401(k) to put toward their advance payment. I’d for ages been informed, getting too many years by more and more people, not to touch the cash on your later years financing (until its a genuine emergency). I got been aware of possible taxation, penalties, and just the general problem you would deal with because of the pulling out bucks too soon. I pondered if the just what she try starting try sensible personal loan credit score 550 or something someone else should think about avoiding.
Therefore i asked the pros and you can learned as to the reasons monetary planners and you can advisors state taking cash out of one’s 401(k) to cover a property is not such as for instance smart.

While you might glance at the balance of one’s 401(k) and consider you might sign up for a few of the dollars and use it but not you’d like, that isn’t fundamentally the case.
There can be a substitute for borrow money from your 401(k) tax-free if you pay back the borrowed funds promptly (usually inside 5 years). When you find yourself by using the currency to acquire a primary home, you have more hours to blow straight back the loan, but one utilizes your own package manager.
If you cannot pay the loan on time, you are able to incur good ten% income tax punishment (if you find yourself lower than 59 1/2). There are also to pay tax towards detachment.
It could be your aim to order you to definitely domestic now, but tapping into pension money making it occurs you will elevates from your coming financial goals, experts state.
“Of the tapping actually a tiny portion of pension nest egg very early, your are in danger off derailing the latest advances you made during the preserving having old age plus the punishment and you can fees sustained,” says Kenny Senour, a monetary planner. “It’s true as possible beginning to replace the money you pull out during your coming salary deferrals, but it usually takes a long time to help you rebuild based on just how much try applied for.”
Financial mentor Jenna Lofton states you may miss out on substance interest for individuals who take out a massive chunk of the offers or take years to spend they back.
“In the event that you will find ever before a financial investment where substance attract work within the your prefer, this can be that,” states Lofton. “Such accounts are designed to have you ever traditions while the easily blog post-senior years as you can imagine your self undertaking during the pre-retirement.”
Specific you’ll justify tapping into the 401(k) as a way of going just a few a lot more cash in order to manage you to definitely down payment, however, considering Steve Landersman, a financial planner, what they are unaware of is they are not available to therefore many other costs.
“The key reason I am go against individuals experiencing their IRA or 401(k) arrangements having a property purchase would be the fact it shows they don’t feel the reserve savings wanted to getting a homeowner,” states Landersman. “Only buying the home is the first step, discover always unexpected expenses and you may improvements.”
]]>