Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions bitwpfi.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Plugin Name: Bit Integrations
* Plugin URI: https://bitapps.pro/bit-integrations
* Description: Bit Integrations is a platform that integrates with over 200+ different platforms to help with various tasks on your WordPress site, like WooCommerce, Form builder, Page builder, LMS, Sales funnels, Bookings, CRM, Webhooks, Email marketing, Social media and Spreadsheets, etc
* Version: 2.2.7
* Version: 2.2.8
* Author: Automation & Integration Plugin - Bit Apps
* Author URI: https://bitapps.pro
* Text Domain: bit-integrations
Expand All @@ -23,7 +23,7 @@
$btcbi_db_version = '1.0';

// Define most essential constants.
define('BTCBI_VERSION', '2.2.7');
define('BTCBI_VERSION', '2.2.8');
define('BTCBI_PLUGIN_MAIN_FILE', __FILE__);

require_once plugin_dir_path(__FILE__) . 'includes/loader.php';
Expand Down
53 changes: 38 additions & 15 deletions frontend-dev/src/components/Utilities/Modal.jsx
Original file line number Diff line number Diff line change
@@ -1,37 +1,60 @@
import { CSSTransition } from 'react-transition-group'
import CloseIcn from '../../Icons/CloseIcn'

export default function Modal({ show, setModal, sm, lg, style, cssTransStyle, className, title, warning, hdrActn, children, subTitle, noPadding, closeIcon }) {
const handleClickOutside = e => {
export default function Modal({
show,
setModal,
sm,
lg,
style,
cssTransStyle,
className,
title,
warning,
hdrActn,
children,
subTitle,
noPadding,
closeIcon
}) {
const handleClickOutside = (e) => {
if (e.target.classList.contains('btcd-modal-wrp') && closeIcon !== false) {
setModal(false)
}
}

return (
<CSSTransition
in={show}
timeout={500}
classNames="btc-mdl-trn"
unmountOnExit
style={cssTransStyle}
>
<CSSTransition in={show} classNames="btc-mdl-trn" unmountOnExit style={cssTransStyle}>
<div
role="button"
tabIndex={0}
onKeyPress={handleClickOutside}
onClick={handleClickOutside}
className="btcd-modal-wrp flx"
>
style={{ overflow: 'auto' }}>
<div
className={`btcd-modal ${sm ? 'btcd-m-sm' : ''} ${lg ? 'btcd-m-lg' : ''} ${className}`}
style={style}
>
style={style}>
<div className={`btcd-modal-content ${noPadding ? 'no-padding' : ''} `}>
{hdrActn}
{!closeIcon ? '' : <button onClick={() => setModal(false)} className="icn-btn btcd-mdl-close" aria-label="modal-close" type="button"><CloseIcn size={16} stroke={3} /></button>
}
{title ? <h2 className="btcd-mdl-title flx" style={{ color: warning ? 'red' : '' }}>{title}</h2> : ''}
{!closeIcon ? (
''
) : (
<button
onClick={() => setModal(false)}
className="icn-btn btcd-mdl-close"
aria-label="modal-close"
type="button">
<CloseIcn size={16} stroke={3} />
</button>
)}
{title ? (
<h2 className="btcd-mdl-title flx" style={{ color: warning ? 'red' : '' }}>
{title}
</h2>
) : (
''
)}
<small className="btcd-mdl-subtitle">{subTitle}</small>
{/* {!sm && <div className="btcd-mdl-div" />} */}
{children}
Expand Down
31 changes: 26 additions & 5 deletions frontend-dev/src/pages/AnnouncementModal.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,16 @@ import { __, sprintf } from '../Utils/i18nwrap'
import '../resource/css/cashback-modal.css'
import Modal from '../components/Utilities/Modal'
import '../resource/css/newRelease.css'
import { useRecoilValue } from 'recoil'
import { $btcbi } from '../GlobalStates'

const PRODUCT_NAME = 'Bit Integrations'
const Early_Bird_URL = 'https://bit-social.com/?utm_source=bit-integrations&utm_medium=inside-plugin&utm_campaign=early-bird-offer'

export default function AnnouncementModal() {
const [show, setShow] = useState(false)

const btcbi = useRecoilValue($btcbi)
const source = !btcbi.isPro ? 'bit-integrations' : 'bit-integrations-pro'
const Early_Bird_URL = `https://bit-social.com/?utm_source=${source}&utm_medium=inside-plugin&utm_campaign=early-bird-offer`
// if (!btcbi.isPro) return

return (
Expand All @@ -28,13 +31,31 @@ export default function AnnouncementModal() {
<span className="star" />
<span className="star" />
</button>
<Modal md show={show} style={{ width: '33%',height:'85%'}} setModal={() => setShow(false)} noPadding={true} closeIcon={true}>
<Modal
md
show={show}
style={{
height: '450px',
width: '450px',
paddingBottom: '20px'
}}
setModal={() => setShow(false)}
noPadding={true}
closeIcon={true}>
<div>
<a href={Early_Bird_URL} target="_blank" rel="noreferrer">
<img src={promo} style={{width: '100%', marginTop:'-10px'}} alt="" />
<img src={promo} style={{ width: '100%', marginTop: '-10px' }} alt="Early Bird Offer" />
</a>
</div>
<div className="footer-wrapper" style={{ position: 'absolute', zIndex: '1', bottom:'-25px', left: '50%', transform:'translateX(-50%)' }} >
<div
className="footer-wrapper"
style={{
position: 'absolute',
zIndex: '1',
bottom: '-25px',
left: '50%',
transform: 'translateX(-50%)'
}}>
<a className="footer-btn purple" href={Early_Bird_URL} target="_blank" rel="noreferrer">
{__('Grab the Deal', 'bit-integrations')}
<ExternalLinkIcn size={16} className="" />
Expand Down
Loading