Is Rowing Good for Your Back? Expert Analysis & Recommendations
By peng yu
By Mark Jennings
Mark spent 12 years helping patients with back problems before injuring his own disc. After using rowing as part of his recovery journey, he now treats patients and consults with companies on spine-friendly equipment design. This is part of our ongoing fitness equipment series.
Understanding Back Pain: The Modern Epidemic
Back pain affects roughly 80% of adults at some point in their lives, making it one of the most common medical complaints worldwide. Our increasingly sedentary lifestyle is a major culprit sitting for 8+ hours daily places abnormal stress on the spine and weakens crucial supporting muscles.
The consequences are predictable but devastating:
· Tight, shortened hip flexors
· Weakened, inhibited glute muscles
· Excessive curvature in the lower spine
· Core muscle deactivation
· Rounded shoulder posture
This combination creates the perfect storm for back pain, particularly in the lumbar region. By day's end, many experience that familiar burning sensation a sign that your body is rebelling against modern life's unnatural demands.
Rowing's Unique Benefits for Back Health
Unlike many exercise options, rowing offers a comprehensive solution to several backhealth challenges. Here's why specialists increasingly recommend it for both back pain prevention and rehabilitation:
1. Posterior Chain Activation
Rowing specifically targets the posterior chain the interconnected system of muscles running from your calves up through your hamstrings, glutes, spinal erectors, and upper back. These muscles are chronically underused in daily life but essential for proper posture and spine support.
Regular rowing strengthens this entire system, creating balanced muscle support around your spine. Studies show that posterior chain weakness correlates strongly with chronic back pain, making this benefit particularly valuable.
2. LowImpact Loading Pattern
Unlike running or even elliptical training, rowing places minimal compressive forces on your spinal discs. The seated position distributes weight through your sit bones rather than sending shock waves up your spine with each movement.
For those with disc herniations, bulges, or degenerative conditions, this makes rowing one of the few cardio options that doesn't exacerbate symptoms. The fluid motion avoids sudden loading patterns that often trigger pain.
3. Posture Re-Education
Proper rowing technique naturally promotes neutral spine positioning and scapular retraction precisely the postural elements that deteriorate during prolonged sitting. The rowing stroke essentially functions as "posture therapy in disguise."
Most importantly, it creates muscle memory for proper spine alignment that carries over into daily activities. This kin-esthetic awareness is crucial for long-term back health.
4. Integrated Movement Patterns
Unlike isolated machine exercises, rowing teaches coordinated movement across multiple joints and muscle groups mimicking how our bodies naturally function in daily life.
This integrated movement pattern improves neuromuscular coordination between the legs, hips, and torso. Research shows that poor movement sequencing contributes significantly to back injury risk, making this benefit particularly valuable.
A comparison with popular exercise equipment for back health:
Exercise Equipment
Impact on Spine
Posture Concerns
Back Muscle Activation
Overall Back Health Rating
Treadmill
High impact, compressive loading
Forward lean common with fatigue
Minimal
⭐⭐
Elliptical
Moderate impact
Tendency toward hunched position
Low to moderate
⭐⭐⭐
Stationary Bike
Low impact
Promotes forward flexed posture
Minimal
⭐⭐
Weight Machines
Variable, often high
Often isolates muscles unnaturally
Selective, not functional
⭐⭐⭐
Rowing Machine
Low impact
Promotes neutral spine
Comprehensive posterior chain
⭐⭐⭐⭐⭐
Proper Rowing Technique for Back Protection
The benefits of rowing for back health are entirely dependent on proper technique. Following these guidelines is essential:
1. Maintain a Neutral Spine
Perhaps the most critical aspect of spinesafe rowing is maintaining your natural spinal curves throughout the stroke. Avoid the common "banana back" position where the lower back rounds.
Technique tip: Think about sitting tall through your torso while hinging forward from the hips, not curving through the spine.
2. Follow the Correct Stroke Sequence
The rowing stroke has a specific bio-mechanical sequence that protects your back:
· Drive phase: Legs → Hips → Arms
· Recovery phase: Arms → Hips → Legs
Deviating from this sequence places excessive strain on the lower back. Many beginners pull with their back immediately instead of initiating with leg drive, which dramatically increases injury risk.
3. Control the Recovery Phase
The return portion of the stroke deserves equal attention. Maintain core engagement and spinal alignment as you move forward. Many back injuries occur during this phase when form deteriorates.
Technique tip: Extend your arms fully before hinging forward at the hips, then finally bend your knees. This sequencing prevents the "crowding" at the front of the stroke that often leads to poor spinal positioning.
4. Select Appropriate Resistance
Higher resistance isn't always better, especially for back health. Begin with lower resistance settings that allow perfect form maintenance throughout your workout.
Recommendation: Start at 35 on most machines and focus on smooth, controlled movements rather than maximum power output.
5. Build Duration Gradually
Start with short sessions (1015 minutes) to perfect form and build supporting muscle endurance. Gradually increase duration as your technique and back endurance improve.
For those with existing back issues, three shorter sessions often prove more beneficial than one longer workout, as form typically deteriorates with fatigue.
Choosing a BackFriendly Rowing Machine
The specific rowing machine you select significantly impacts back safety and comfort:
Critical Features for Back Health:
1.Seat Design and Support A properly contoured seat redistributes pressure away from the tailbone and supports the pelvis in a neutral position. Flat seats create excessive pressure points and promote poor pelvic positioning.
2.Smooth Resistance System The resistance mechanism should provide consistent tension throughout the entire stroke. Jerky or inconsistent resistance patterns force your back muscles to compensate unpredictably, increasing injury risk.
3.Adjustable Footplate Positioning Proper foot positioning is foundational to correct rowing biomechanics. Adjustable footplates accommodate different body proportions and allow optimal alignment from feet through spine.
4.Ergonomic Handle Design The handle should facilitate a natural grip without excessive wrist deviation. Poor grip positioning can create compensatory patterns that affect the entire kinetic chain, including your back.
5.Stable Frame Construction Any wobbling or shifting during the rowing stroke forces stabilization muscles to work overtime, diverting energy from proper technique maintenance.
Tousains Rowing Machine: Designed for Back Health
After evaluating numerous machines specifically for back health considerations, the Tousains 3in1 Rowing Machine stands out for several spine-friendly design elements:
Adaptive Lumbar Support: The seat incorporates adjustable support that can be customized to match your specific spinal curvature, promoting neutral positioning even during longer sessions.
Pressure-mapped Seat Design: Developed using pressure-mapping technology, the seat distributes weight properly through the sit bones rather than the tailbone or soft tissues.
Consistent Resistance Profile: The resistance system maintains predictable tension throughout the stroke cycle, eliminating the sudden resistance changes that can cause spinal loading spikes.
Posture Monitoring Technology: The machine provides feedback about spinal positioning, alerting you when form deteriorates before pain occurs.
Beyond subjective improvements, research and clinical observations document specific benefits when rowing is incorporated regularly:
1. Increased Back Extensor Strength
After 8 weeks of consistent rowing (3 sessions weekly), patients typically demonstrate 1520% improvement in back extensor muscle strength testing. These muscles are critical for maintaining upright posture throughout the day.
2. Improved Positional Awareness
Proprioception (your body's awareness of position in space) typically improves significantly with regular rowing. This enhanced body awareness translates directly to better posture habits in daily activities.
3. Reduced Pain Scores
Using standardized pain assessment tools (110 scale), patients with chronic back pain often report 34 point reductions after 12 weeks of regular rowing programming when performed with proper technique.
4. Functional Improvement
Beyond pain reduction, patients experience measurable improvements in functional capacity:
· Increased comfortable sitting duration
· Improved bending and lifting tolerance
· Enhanced ability to maintain proper posture during prolonged activities
5. Reduced Inflammatory Markers
The cardiovascular benefits of rowing help reduce systemic inflammation, which plays a role in pain sensitization and tissue healing. Additionally, improved core strength helps maintain neutral spine positioning, reducing mechanical tissue irritation.
Implementation Guidelines for Back Pain Sufferers
If you're dealing with back pain and want to incorporate rowing safely:
For Acute Back Pain:
· Consult your healthcare provider before beginning
· Start with 5minute sessions focusing exclusively on perfect form
· Use minimal resistance (levels 13 on your rowing machine)
· Stop immediately if pain increases during or after rowing
For Chronic Back Pain:
· Begin with 10minute sessions, 23 times weekly
· Focus on maintaining neutral spine position throughout
· Gradually increase duration by 23 minutes weekly as tolerated
· Complement with specific core stability exercises
For Preventive Back Care:
· Aim for 2030 minute sessions, 34 times weekly
· Incorporate interval training once basic technique is mastered
· Use moderate resistance levels that challenge without compromising form
· Consider using the Tousains 3in1 Rowing Machine for its backfriendly features
Conclusion: Why Rowing Works for Back Health
The effectiveness of rowing for back health stems from its unique combination of benefits that address the root causes of most back problems:
1. It strengthens precisely the muscles that become deactivated during prolonged sitting
2. It promotes spinefriendly movement patterns that transfer to daily activities
3. It provides cardiovascular benefits without the spinal impact of most aerobic exercises
4. It improves body awareness and proper movement sequencing
While rowing isn't a miracle solution for all back conditions, it offers one of the most comprehensive approaches to spine health available in a single exercise modality. When performed correctly on appropriate equipment like the Tousains 3in1 Rowing Machine, it provides a sustainable way to build back supporting strength and endurance while improving overall fitness.
The key lies in proper technique, appropriate equipment selection, and gradual progression principles that apply to both preventing back problems and rehabilitating existing issues.
Mark rows 3x weekly and has successfully returned to an active lifestyle without pain. He treats back pain patients at Back To Life Clinic in Portland when he's not researching biomechanics or testing new fitness equipment.
(() => {
const executeDynamicBundleBlock = ({ blockElement, productId = null, isCustomPage = false }) => {
const babBundles = [{"id":23530,"shop":"4c0bba-2.myshopify.com","name":"Your Home, Your Gym","description":null,"status":"ACTIVE","customerIncludeTags":null,"discountType":"PERCENTAGE","discountValue":10.0,"products":null,"variants":"[{\"productId\":10109810016543,\"variantId\":51127775461663,\"name\":\"Cable Machine CR63 - 55 LB A Pair-🔥 Top Choice\",\"productHandle\":\"cable-machine-cr63\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/summer_sale_1.webp?v=1754105678\",\"quantity\":1,\"price\":\"399.99\",\"status\":\"ACTIVE\",\"productTitle\":\"Cable Machine CR63\",\"variantTitle\":\"55 LB A Pair-🔥 Top Choice\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":10109810016543,\"variantId\":51127775428895,\"name\":\"Cable Machine CR63 - None\",\"productHandle\":\"cable-machine-cr63\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/summer_sale_1.webp?v=1754105678\",\"quantity\":1,\"price\":\"219.99\",\"status\":\"ACTIVE\",\"productTitle\":\"Cable Machine CR63\",\"variantTitle\":\"None\",\"isMandatory\":false,\"preSelected\":true,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":10223207350559,\"variantId\":51135896027423,\"name\":\"Adjustable Dumbbell MX55 (A Pair) \",\"productHandle\":\"adjustable-dumbbell\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/dumbbell_5_704c06a5-4a17-4d01-aba9-80d00dd37c71.webp?v=1755659245\",\"quantity\":1,\"price\":\"259.00\",\"status\":\"ACTIVE\",\"productTitle\":\"Adjustable Dumbbell MX55 (A Pair)\",\"variantTitle\":null,\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":9802827596063,\"variantId\":50042750107935,\"name\":\"HIVEGYM ACCESSOIRES - Extension Rope\",\"productHandle\":\"hivegym-basic-box-copy\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_3_a2624be1-2715-4f6e-bed2-c103715188af.webp?v=1734517818\",\"quantity\":1,\"price\":\"26.00\",\"status\":\"ACTIVE\",\"productTitle\":\"HIVEGYM ACCESSOIRES\",\"variantTitle\":\"Extension Rope\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":9802827596063,\"variantId\":50042750075167,\"name\":\"HIVEGYM ACCESSOIRES - Pull Rope Handle\",\"productHandle\":\"hivegym-basic-box-copy\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_3_a2624be1-2715-4f6e-bed2-c103715188af.webp?v=1734517818\",\"quantity\":1,\"price\":\"26.00\",\"status\":\"ACTIVE\",\"productTitle\":\"HIVEGYM ACCESSOIRES\",\"variantTitle\":\"Pull Rope Handle\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":9802827596063,\"variantId\":50042749976863,\"name\":\"HIVEGYM ACCESSOIRES - Reward-Exercise Bar\",\"productHandle\":\"hivegym-basic-box-copy\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_3_a2624be1-2715-4f6e-bed2-c103715188af.webp?v=1734517818\",\"quantity\":1,\"price\":\"36.00\",\"status\":\"ACTIVE\",\"productTitle\":\"HIVEGYM ACCESSOIRES\",\"variantTitle\":\"Reward-Exercise Bar\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":9802827596063,\"variantId\":50042750140703,\"name\":\"HIVEGYM ACCESSOIRES - Reward-HIVEGYM Basic Box\",\"productHandle\":\"hivegym-basic-box-copy\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_3_a2624be1-2715-4f6e-bed2-c103715188af.webp?v=1734517818\",\"quantity\":1,\"price\":\"60.00\",\"status\":\"ACTIVE\",\"productTitle\":\"HIVEGYM ACCESSOIRES\",\"variantTitle\":\"Reward-HIVEGYM Basic Box\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":9802827596063,\"variantId\":50042750042399,\"name\":\"HIVEGYM ACCESSOIRES - Reward-Suction Cup*2\",\"productHandle\":\"hivegym-basic-box-copy\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_3_a2624be1-2715-4f6e-bed2-c103715188af.webp?v=1734517818\",\"quantity\":1,\"price\":\"70.00\",\"status\":\"ACTIVE\",\"productTitle\":\"HIVEGYM ACCESSOIRES\",\"variantTitle\":\"Reward-Suction Cup*2\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":9802827596063,\"variantId\":50042750009631,\"name\":\"HIVEGYM ACCESSOIRES - Suction Cup\",\"productHandle\":\"hivegym-basic-box-copy\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_3_a2624be1-2715-4f6e-bed2-c103715188af.webp?v=1734517818\",\"quantity\":1,\"price\":\"40.00\",\"status\":\"ACTIVE\",\"productTitle\":\"HIVEGYM ACCESSOIRES\",\"variantTitle\":\"Suction Cup\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":8806754156831,\"variantId\":50038623109407,\"name\":\"Portable Gym HIVEGYM Power Pump - Advanced\",\"productHandle\":\"hivegym-power-pump\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_1295c6dd-0ad2-4f67-b020-0dd85bdca327.webp?v=1746609865\",\"quantity\":1,\"price\":\"249.00\",\"status\":\"ACTIVE\",\"productTitle\":\"Portable Gym HIVEGYM Power Pump\",\"variantTitle\":\"Advanced\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":8806754156831,\"variantId\":50038623076639,\"name\":\"Portable Gym HIVEGYM Power Pump - Basic\",\"productHandle\":\"hivegym-power-pump\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_1295c6dd-0ad2-4f67-b020-0dd85bdca327.webp?v=1746609865\",\"quantity\":1,\"price\":\"239.00\",\"status\":\"ACTIVE\",\"productTitle\":\"Portable Gym HIVEGYM Power Pump\",\"variantTitle\":\"Basic\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null},{\"productId\":8806754156831,\"variantId\":50038623142175,\"name\":\"Portable Gym HIVEGYM Power Pump - Professional\",\"productHandle\":\"hivegym-power-pump\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/hivegym_1295c6dd-0ad2-4f67-b020-0dd85bdca327.webp?v=1746609865\",\"quantity\":1,\"price\":\"520.00\",\"status\":\"ACTIVE\",\"productTitle\":\"Portable Gym HIVEGYM Power Pump\",\"variantTitle\":\"Professional\",\"isMandatory\":false,\"preSelected\":false,\"minQuantity\":null,\"maxQuantity\":null}]","sequenceNo":null,"bundleType":"CLASSIC_BUILD_A_BOX","settings":null,"bundleProductId":null,"bundleVariantId":null,"productHandle":null,"discountId":null,"price":null,"numberOfProducts":0,"subscriptionBundlingEnabled":false,"subscriptionId":null,"minProductCount":2,"maxProductCount":null,"uniqueRef":"YK7wWFRke7","bundleRedirect":"CART","customRedirectURL":null,"minOrderAmount":20.0,"tieredDiscount":null,"productViewStyle":"QUICK_ADD","singleProductSettings":null,"trackInventory":false,"sellingPlanType":"BUNDLE_LEVEL","clearCart":"ENABLED","minPrice":null,"maxPrice":null,"externalBuildABoxId":null,"variantVisibilityType":"SHOW_VARIANTS_AS_OPTIONS","subTitle":"An exclusive discount will be applied at checkout.","freeShipping":false,"themeType":"THEME_TWO","showBundleInProductPage":true,"combinedWithProductDiscount":true,"combinedWithShippingDiscount":true,"combinedWithOrderDiscount":true,"allowedTags":null,"restrictTags":null,"selectionType":"FLEXIBLE","bundleHtml":null,"discountedVariants":null,"allowedCountries":null,"appliesOn":"BOTH","purchaseRequirement":"NO_REQUIREMENT","productDiscountType":"EACH_PRODUCT","countrySelectionType":"ALL_COUNTRY","discountApplyApproach":"SHOPIFY_DISCOUNT_FUNCTION","discountedProductChooseType":"CHOOSE_ALL","internalName":"hivegym页面bundle","sections":"[{\"id\":1,\"name\":\"\",\"description\":\"\",\"minProductCount\":0,\"maxProductCount\":0,\"variants\":[]}]","limitToUsePerCustomer":-3,"discountedVariantSelectionLimit":null,"hideOneTimePurchase":false,"hideSubscriptionPurchase":false,"maxOrderAmount":null,"collectionData":null,"productSelectionType":"PRODUCT","tag":"appstle_bundles","productChooseType":"CHOOSE_ALL","variantSelectionLimit":null,"discountTargetType":"PRODUCT","enableSubscription":false,"subscriptionWidgetPosition":"BELOW","subscribeTitle":"Subscribe and Save","subscribeSubtitle":"Delivered Monthly","subscriptionPreselected":true,"getYAppliesOn":"BOTH","announcementBarMessage":null,"automaticDiscountNodeId":"gid://shopify/DiscountAutomaticNode/1974983917855","recurringCycleLimit":0},{"id":23531,"shop":"4c0bba-2.myshopify.com","name":"YOUR HOME, YOUR GYM","description":null,"status":"ACTIVE","customerIncludeTags":null,"discountType":"NO_DISCOUNT","discountValue":null,"products":"[{\"productId\":10223207350559,\"variantId\":null,\"price\":null,\"name\":\"Adjustable Dumbbell MX55 (A Pair)\",\"productHandle\":\"adjustable-dumbbell\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/dumbbell_5_704c06a5-4a17-4d01-aba9-80d00dd37c71.webp?v=1755659245\",\"quantity\":1,\"status\":\"ACTIVE\",\"options\":[]},{\"productId\":10109810016543,\"variantId\":null,\"price\":null,\"name\":\"Cable Machine CR63\",\"productHandle\":\"cable-machine-cr63\",\"imageSrc\":\"https://cdn.shopify.com/s/files/1/0802/0315/3695/files/summer_sale_1.webp?v=1754105678\",\"quantity\":1,\"status\":\"ACTIVE\",\"options\":[{\"name\":\"Cable Machine CR63 (Pair it with)\",\"value\":[{\"name\":\"55 LB A Pair-🔥 Top Choice\",\"selected\":true},{\"name\":\"None\",\"selected\":true}]}]}]","variants":"[]","sequenceNo":null,"bundleType":"CLASSIC","settings":null,"bundleProductId":10238240325919,"bundleVariantId":null,"productHandle":"your-home-your-gym","discountId":null,"price":null,"numberOfProducts":0,"subscriptionBundlingEnabled":false,"subscriptionId":null,"minProductCount":null,"maxProductCount":null,"uniqueRef":"y1RQh4yKi8","bundleRedirect":"CART","customRedirectURL":null,"minOrderAmount":null,"tieredDiscount":null,"productViewStyle":"QUICK_ADD","singleProductSettings":null,"trackInventory":false,"sellingPlanType":"BUNDLE_LEVEL","clearCart":"ENABLED","minPrice":478.99,"maxPrice":658.99,"externalBuildABoxId":null,"variantVisibilityType":"SHOW_VARIANTS_AS_INDIVIDUAL","subTitle":null,"freeShipping":false,"themeType":"THEME_TWO","showBundleInProductPage":true,"combinedWithProductDiscount":true,"combinedWithShippingDiscount":true,"combinedWithOrderDiscount":true,"allowedTags":null,"restrictTags":null,"selectionType":"FLEXIBLE","bundleHtml":null,"discountedVariants":null,"allowedCountries":null,"appliesOn":"BOTH","purchaseRequirement":"NO_REQUIREMENT","productDiscountType":"EACH_PRODUCT","countrySelectionType":"ALL_COUNTRY","discountApplyApproach":"SHOPIFY_DISCOUNT_FUNCTION","discountedProductChooseType":"CHOOSE_ALL","internalName":"固定","sections":"[{\"id\":1,\"name\":\"\",\"description\":\"\",\"minProductCount\":0,\"maxProductCount\":0,\"variants\":[]}]","limitToUsePerCustomer":null,"discountedVariantSelectionLimit":null,"hideOneTimePurchase":false,"hideSubscriptionPurchase":false,"maxOrderAmount":null,"collectionData":null,"productSelectionType":"PRODUCT","tag":"appstle_bundles","productChooseType":"CHOOSE_ALL","variantSelectionLimit":null,"discountTargetType":"PRODUCT","enableSubscription":false,"subscriptionWidgetPosition":"BELOW","subscribeTitle":"Subscribe and Save","subscribeSubtitle":"Delivered Monthly","subscriptionPreselected":true,"getYAppliesOn":"BOTH","announcementBarMessage":null,"automaticDiscountNodeId":null,"recurringCycleLimit":null}];
window['isAppstleBuildABox'] = true;
window.sessionStorage.setItem('external-bundle-token', window.appstle_bundle_external_token);
const referenceBundle = blockElement.getAttribute('ref') || null;
const baseFilteredBundles = Array.isArray(babBundles) && babBundles?.length > 0 && babBundles.filter((rule) => {
if(!isCustomPage) {
rule.themeType = 'THEME_TWO';
}
if (rule?.bundleType === 'CLASSIC_BUILD_A_BOX' && rule?.status === 'ACTIVE' && (rule?.showBundleInProductPage === true || isCustomPage)) {
try {
const variants = JSON.parse(rule?.variants || '[]');
if(productId) return variants.some((variant) => parseInt(variant?.productId) === parseInt(productId));
if(!productId) return true;
} catch (e) {
console.error('Failed to parse JSON:', e);
return false;
}
}
return false;
}) || [];
const filteredBundles = isCustomPage && referenceBundle ? baseFilteredBundles?.filter(rule => rule?.uniqueRef === referenceBundle) : baseFilteredBundles;
if (filteredBundles?.length > 0 && blockElement) {
const link = document.createElement('link');
link.rel = 'stylesheet';
link.href = "https://bundles-admin.appstle.com/content/build-a-box.css?v=1760355692209";
document.head.appendChild(link);
const script = document.createElement('script');
script.async = true;
script.src = "https://bundles-admin.appstle.com/app/build-a-box.bundle.js?v=1760355692209";
document.head.appendChild(script);
filteredBundles.forEach((rule) => {
const bundleDiv = document.createElement('div');
const uniqueRef = rule?.uniqueRef;
bundleDiv.setAttribute('appstle-dynamic-bundle-unique-reference', uniqueRef);
bundleDiv.className = isCustomPage ? `appstleBundlesCustomPage appstleCustomPageDynamicBundle-${uniqueRef}` : `appstleBundlesProductPage appstleDynamicBundle-${uniqueRef}`;
blockElement.appendChild(bundleDiv);
const appBlockDiv = document.querySelector(isCustomPage ? 'div[data-block-handle="appstle-bundle-dynamic-pricing-custom-page"]' : 'div[data-block-handle="appstle-bundle-product-page-build-a-box"]');
if (appBlockDiv) {
appBlockDiv.appendChild(blockElement);
}
});
}
};
const executeDynamicBundleLogic = () => {
const productId = "";
const blockElement = document.getElementById('dynamic-pricing-bundle-product-page');
const blockElements = document.querySelectorAll('.ab-dynamic-bundle-custom-placement-selector');
if (blockElement && productId) {
blockElement.classList.add(`product-id-${productId}`);
executeDynamicBundleBlock({ blockElement, productId, isCustomPage: false });
}
if (blockElements && blockElements.length > 0) {
blockElements.forEach((element) => {
const productId = element?.getAttribute('data-product-id');
element.classList.add(`product-id-${productId}`);
executeDynamicBundleBlock({ blockElement: element, productId, isCustomPage: false });
});
}
const customPageBlockElement = document.getElementById('dynamic-pricing-bundle-custom-page');
if (customPageBlockElement) executeDynamicBundleBlock({ blockElement: customPageBlockElement, productId: null, isCustomPage: true });
}
document.addEventListener('DOMContentLoaded', executeDynamicBundleLogic);
})();
document.addEventListener('DOMContentLoaded', () => {
const bundleSettings = {"id":7661,"shop":"4c0bba-2.myshopify.com","showOnProductPage":null,"selector":null,"placement":"AFTER","customCss":null,"customizeBundleOptionType":"RADIO","buyButtonSelector":null,"labels":"{\"productDiscountCombinedWithOrderDiscount\":true,\"bundleListViewDetailsButtonLabel\":\"View Details\",\"topBarFixedDiscountTitlePostfix\":\"{{currency}}{{discount}} off on shipping\",\"requiredLoginValidationLabel\":\"Please log in to purchase this bundle!\",\"volumeDiscountTypeLabel\":\"Volume Discount\",\"loginAlertLinkLabel\":\"Click here to login\",\"includedSubscriptionPlans\":\"\",\"breadCrumbProductsLabel\":\"Choose Products\",\"enableClassicBundleRecreation\":true,\"emptyProductImage\":\"https://cdn.shopify.com/s/files/1/0661/9224/4900/files/EmptyImage.jpg?v=1718447038\",\"enableAnnouncementBarAutoRotate\":true,\"reviewOrderInfoLabel\":\"\",\"productDiscountCombinedWithProductDiscount\":true,\"bundleMaximumQuantityLabel\":\"Add maximum up to {{maximum_quantity}} product\",\"volumeDiscountAppliesOnOneTimePurchase\":true,\"productAddToBundleLabel\":\"Add\",\"defaultSelectedPurchaseOptionSwitch\":\"ONE_TIME\",\"breadCrumbReviewBundleLabel\":\"Review Bundle\",\"enableScrollingToBundleSection\":false,\"orderNoteLabel\":\"Order Note\",\"showProductPerPage\":50,\"dynamicBundleDiscountCombinedWithShippingDiscount\":true,\"hidePurchaseOptionSelectLabel\":false,\"showPriceAsDecimals\":false,\"fixedDiscountText\":\"Enjoy a fixed discount of {{currency}}{{discount_value}} on your purchase!\",\"sectionTotalLabel\":\"Section Total\",\"fieldDisabledBackgroundColor\":\"#D1D5DB\",\"bundleTotalLabel\":\"Total\",\"disableRefreshSellingPlan\":false,\"checkInventoryQuantity\":false,\"showSubscriptionPlanDescription\":false,\"disableProductDescription\":false,\"fixedPricingBundleTypeLabel\":\"Fixed Pricing Bundle\",\"subscriptionAvailableLabel\":\"Subscription Available\",\"excludeSubscriptionPlans\":\"\",\"readLessText\":\"Read Less\",\"buyXGetYDiscountAppliesOnSubscription\":true,\"shippingDiscountLabel\":\"{{discount}}{{discount_type}} Shipping Discount\",\"selectedGiftProductProgressLabelText\":\"{{selected_product_quantity}} gift products added. The required quantity is {{required_product_quantity}}.\",\"disableFitImage\":false,\"secondaryTextColor\":\"#ece0dc\",\"bundleProductsQuantityLabel\":\"{{quantity}}x quantity\",\"buyXGetYDiscountCombinedWithProductDiscount\":true,\"tieredDiscountLabel\":\"{{discount_amount}}{{discount_type}} Discount\",\"buyXGetYQuantityValidationLabel\":\"Add {{product_quantity}} quantities of the gift product (Get Y)\",\"primaryTextColor\":\"#000000\",\"modalOpenOnAddToCart\":true,\"notApplicableForSubscribeAndSaveNotificationTitle\":\"Not applicable for subscribe & save\",\"customSignInLink\":\"\",\"productDiscountAppliesOnOneTimePurchase\":true,\"topBarDiscountUnlockTitlePrefix\":\"You've unlocked \",\"loginAlertTextLabel\":\"You need to login to purchase this bundle.\",\"buyXGetYChooseProductLabel\":\"Choose Product\",\"chooseAPlanLabel\":\"Choose Plan\",\"singleParentProductDirectRedirectToChildProducts\":true,\"buyXGetYFixedDiscountText\":\"Enjoy a fixed discount of {{discount_value}} {{currency}}\",\"primaryColor\":\"#000000\",\"buyXGetYGiftProductPriceVisibilityType\":\"UNIT_PRICE\",\"shippingDiscountRecurringCycleLimit\":0,\"volumeDiscountVariantSelectLabel\":\"Denominations\",\"chooseSourceProductValidationLabel\":\"Please choose source product!\",\"shippingDiscountAppliesOnSubscription\":true,\"volumeDiscountSpentAmountRewardsLabel\":\"Spend {{currency}}{{spent_amount}} and get {{discount}}{{discount_type}} discount!\",\"hideBundleToastNotification\":false,\"classicBundleTypeLabel\":\"Classic Bundle\",\"volumeDiscountRecurringCycleLimit\":0,\"bundleListDescription\":\"Explore our Bundles and Discounted Pricing and enjoy exclusive discounts when you buy products together\",\"getYNoProductSelectedLabel\":\"No gift product selected (Get Y)\",\"hideVariantSelectLabel\":false,\"availableOnlySubscriptionLabel\":\"Available Only On Subscription\",\"enableParentProductDetailButton\":false,\"bundleListTitle\":\"List of Bundles and Discounted Pricing\",\"chooseAssociatedProductsValidationLabel\":\"Please choose associated products!\",\"selectedSourceProductLabel\":\"Selected\",\"enableBuyXGetYWidgetMergeAsOptions\":false,\"volumeDiscountNextApplicableSpentAmountRewardsLabel\":\"Spend {{spent_amount}}{{currency}} get {{discount}}{{discount_type}}\",\"sectionNoProductSelectedValidationLabel\":\"No product selected for: {{section_name}}!\",\"bundlePageBackgroundColor\":\"#FAFAF9\",\"showVendorName\":false,\"buyXQuantityValidationLabel\":\"Add {{product_quantity}} quantities of the product (Bux X)\",\"sectionMaximumQuantityValidationLabel\":\"Maximum quantity not selected for: {{section_name}}!\",\"enableMaxDiscountCap\":false,\"volumeAmountDiscountSaveRewardsLabel\":\"Save {{currency}}{{discount}}!\",\"sectionLabel\":\"Section\",\"disabledTextColor\":\"#6B7280\",\"primaryHoverColor\":\"#000000\",\"shippingDiscountCombinedWithOrderDiscount\":true,\"defaultDiscountBarMessage\":\"Welcome to our store\",\"enableBundleProductFilter\":false,\"buyXGetYDiscountCombinedWithOrderDiscount\":true,\"bundleSubtotalLabel\":\"Subtotal\",\"reviewOrderDescription\":\"Check your items and select your required frequency plan\",\"dynamicBundleDiscountCombinedWithOrderDiscount\":true,\"volumeDiscountSaveRewardsLabel\":\"Save {{discount}}{{discount_type}}!\",\"addingProductsToBundle\":\"Adding products to bundle\",\"buyXGetYMergedWidgetTitle\":\"Select Buy X Get Y Discount\",\"bundleModalHeaderLabel\":\"Your Bundle({{total_quantity}})\",\"productAddedToBundleNotificationDescription\":\"{{product_title}} added to bundle.\",\"dynamicBundleDiscountAppliesOnSubscription\":true,\"productDiscountTypeLabel\":\"Product Discount\",\"bundleTopHtml\":\"\",\"proceedToCheckoutButtonText\":\"\",\"defaultSelectedPurchaseOption\":\"ONE_TIME\",\"showDraftProduct\":false,\"switchSubscriptionLabel\":\"Subscribe & Save\",\"percentDiscountText\":\"Get {{discount_value}}% off on your purchase!\",\"discountUsageLimitExceedLabel\":\"You have exceeded the bundle usage limit\",\"reviewOrderLabel\":\"Review Bundle\",\"chooseSectionProductsLabel\":\"Choose Section Products\",\"primaryDisabledColor\":\"#333333\",\"bundleMinimumOrderAmountLabel\":\"Add minimum {{minimum_amount}} order amount\",\"dynamicBundleDiscountRecurringCycleLimit\":0,\"breadCrumbSelectSectionLabel\":\"Select Section\",\"loadMoreButtonLabel\":\"Load More\",\"bundleQuantityRewardsLabel\":\"Add {{quantity}} item, get {{discount}}{{discount_type}} discount\",\"shippingDiscountCombinedWithProductDiscount\":true,\"sellingPlanNameSortOrder\":\"ASC\",\"switchOnTimeLabel\":\"One Time\",\"volumeDiscountCombinedWithProductDiscount\":true,\"chooseProductsText\":\"Products\",\"productDetailsViewType\":\"SHOW_PRODUCT_POPUP\",\"enableManualBundleBlockIntegration\":false,\"volumeDiscountNextApplicableQuantityRewardsLabel\":\"Buy {{quantity}} get {{discount}}{{discount_type}}\",\"bundleCheckoutLabel\":\"Checkout\",\"productDiscountCombinedWithShippingDiscount\":true,\"skipSelectSectionPage\":false,\"productCardBackgroundColor\":\"#ffffff\",\"buyXGetYFreeLabel\":\"Free\",\"buttonBackgroundColor\":\"#000000\",\"dockbarHeadingLabel\":\"Bundle\",\"discountMessageInterval\":3000,\"sectionedBundleTypeLabel\":\"Sectioned Bundle\",\"buyXGetYAddToCartLabel\":\"Add to cart\",\"buyXGetYDiscountCombinedWithShippingDiscount\":true,\"dynamicBundleDiscountCodeText\":\"BUNDLE_DISCOUNT_{{bundle_id}}\",\"productDiscountAppliesOnSubscription\":true,\"selectedProgressLabelText\":\"{{total_bundle_items}} item added with a minimum quantity of {{minimum_quantity}}\",\"requiredBundleProductLabel\":\"Your bundle needs {{min_product_count}} more item(s).\",\"sellingPlanSelectionDropDownLabel\":\"Purchase Options\",\"buyXGetYPercentDiscountText\":\"Enjoy a percentage discount of {{discount_value}}%\",\"dockbarDescriptionLabel\":\"You're getting the most rewards!\",\"productDiscountRecurringCycleLimit\":0,\"preventClickableProductsOnCart\":false,\"enableProductDetailButton\":false,\"discountTargetType\":\"VARIANT\",\"buyXGetYDiscountTypeLabel\":\"Buy X Get Y Discount\",\"customOfferLink\":\"collections/all\",\"noItemsInBundle\":\"No items added to the bundle\",\"topBarPercentDiscountTitlePostfix\":\"{{discount}}% off on shipping\",\"variantSelectionDropDownLabel\":\"Variants\",\"chooseSectionLabel\":\"Choose Section\",\"dynamicPricingBundleTypeLabel\":\"Dynamic Pricing Bundle\",\"breadCrumbPlanLabel\":\"Select Plan\",\"showDynamicBundleOrderNote\":false,\"showOutOfStockProduct\":true,\"disabledSellingPlanSelectionValidation\":false,\"disableViewShopifyProduct\":false,\"bundleDiscountLabel\":\"Discount\",\"topBarDiscountRequiredAmountTitlePrefix\":\"Add {{currency}}{{remainingAmount}} more to unlock \",\"volumeDiscountAppliedQuantityRewardsLabel\":\"Applied: buy {{quantity}} get {{discount}}{{discount_type}}\",\"bundleNotEligibleLabel\":\"You're not eligible to purchase this bundle!\",\"reviewOrderProductsLabel\":\"Bundle Products\",\"outOfStockLabel\":\"Out Of Stock\",\"showUnitPrice\":false,\"buyXGetYFreeGiftDiscountText\":\"Enjoy the free product\",\"showDescriptionPopup\":true,\"maxDiscountCapValue\":0,\"readMoreText\":\"Read More\",\"totalBundleProductsAddedLabel\":\"{{total_bundle_items}} Products Added\",\"bundleMinimumQuantityLabel\":\"Add minimum {{minimum_quantity}} product\",\"noSourceProductSelectedLabel\":\"No source product selected.\",\"nonListedProductText\":\"Non-Listed\",\"buyXNoProductSelectedLabel\":\"No product selected (Buy X)\",\"volumeDiscountQuantityRewardsLabel\":\"Buy {{quantity}} quantity and get {{discount}}{{discount_type}} discount!\",\"freeShippingLabel\":\"Free Shipping\",\"previousButtonLabel\":\"Previous Step\",\"draftBundlePageTitle\":\"Oops! This bundle is temporarily unavailable.\",\"productDetailsMaximumDescriptionCount\":300,\"oneTimeOnlyLabel\":\"One time only\",\"buyXAnyNumberOfProductChooseLabel\":\"Choose any number of products\",\"productFilterConfig\":\"{\\\"enabled\\\":false,\\\"filters\\\":[]}\",\"volumeAmountDiscountQuantityRewardsLabel\":\"Buy {{quantity}} quantity and get {{currency}}{{discount}} discount!\",\"disableDiscountedPricingRedirectToCart\":false,\"volumeDiscountCombinedWithOrderDiscount\":true,\"dynamicBundleDiscountAppliesOnOneTimePurchase\":true,\"choosePlanButtonLabel\":\"Choose Plan\",\"enableAnnouncementBar\":false,\"bundleQuantityLabel\":\"{{quantity}}x\",\"showClassicBundleWidgetInChildProduct\":false,\"shippingDiscountAppliesOnOneTimePurchase\":true,\"classicBundleLinkLabel\":\"Go to the Classic Bundle\",\"topBarDiscountRequiredQuantityTitlePrefix\":\"Add {{remainingQuantity}} more item(s) to unlock \",\"bundleDetailsLabel\":\"Your bundle:\",\"buyXGetYDiscountAppliesOnOneTimePurchase\":true,\"volumeDiscountAppliedSpentAmountRewardsLabel\":\"Applied: spend {{spent_amount}}{{currency}} get {{discount}}{{discount_type}}\",\"enableAutoRemoveRelevantBundleItemInCart\":false,\"bundleModalShowRewardsLabel\":\"Show all rewards\",\"topBarFreeShippingTitlePostfix\":\"free shipping\",\"buyXGetYDiscountRecurringCycleLimit\":0,\"cartAndCheckoutMandatoryProductValidationMessage\":\"This bundle or discount must include all required products and they cannot be removed.\",\"volumeAmountDiscountSpentAmountRewardsLabel\":\"Spend {{currency}}{{spent_amount}} and get {{currency}}{{discount}} discount!\",\"notApplicableForOneTimeNotificationTitle\":\"Not applicable for one time\",\"showDiscountToNonEligibleCustomers\":false,\"primaryDisabledTextColor\":\"#ffffff\",\"draftBundlePageSubTitle\":\"In the meantime, check out our latest offers and discounts!\",\"volumeDiscountCombinedWithShippingDiscount\":true,\"bundleSpentAmountRewardsLabel\":\"Spent {{spent_amount}} worth of items, get {{discount}}{{discount_type}} discount\",\"nextButtonLabel\":\"Next Step\",\"classicBundleDescriptionLabel\":\"Your bundle contains the following products.\",\"bundleBottomHtml\":\"\",\"sectionMinimumQuantityValidationLabel\":\"Minimum quantity not selected for: {{section_name}}!\",\"volumeDiscountAppliesOnSubscription\":true,\"dynamicBundleDiscountCombinedWithProductDiscount\":true,\"buyXGetYAnyNumberOfGiftProductLabel\":\"Choose any number of gift products\",\"descriptionLength\":200,\"bundleDiscountNote\":\"Discounts will be applied at checkout.\",\"bundleModalCloseRewardsLabel\":\"Close all rewards\",\"dockbarCurrentRewardLabel\":\"You got {{discount_amount}}{{discount_type}} discount\",\"productDetailsAddToBundleLabel\":\"Add to bundle\",\"cartAndCheckoutQuantityValidationMessage\":\"Orders must match the quantity range: Min {{min_quantity}}, Max {{max_quantity}}\",\"bundleNoProductSelectedLabel\":\"No product selected\",\"checkoutInfoLabel\":\"Add products from each section to enable the add to cart button.\",\"enableShowMultipleImages\":false,\"redirectToCartPageOnCartIconClick\":true,\"freeShippingDiscountCodeText\":\"FREE_SHIPPING_{{bundle_id}}\",\"customOfferLinkButtonLabel\":\"Explore Offers\",\"oneTimePurchaseLabel\":\"One Time Purchase\",\"bundleMaximumOrderAmountLabel\":\"Add maximum {{maximum_amount}} order amount\",\"enableBundleProductAscOrderView\":true,\"productAddedToBundleNotificationTitle\":\"Added to bundle\",\"showClassicBundleProductVariant\":false,\"customHtmlInject\":\"[]\",\"breadCrumbReviewSectionLabel\":\"Review Section\"}","bundleTopHtml":"","bundleBottomHtml":"","proceedToCheckoutButtonText":"","chooseProductsText":"Products","productAddToBundleLabel":"Add","productDetailsAddToBundleLabel":"Add to bundle","productDetailsMaximumDescriptionCount":300,"variantSelectionDropDownLabel":"Variants","sellingPlanSelectionDropDownLabel":"Purchase Options","dockbarHeadingLabel":"Bundle","dockbarCurrentRewardLabel":"You got {{discount_amount}}{{discount_type}} discount","dockbarDescriptionLabel":"You're getting the most rewards!","bundleModalHeaderLabel":"Your Bundle({{total_quantity}})","bundleModalShowRewardsLabel":"Show all rewards","bundleModalCloseRewardsLabel":"Close all rewards","bundleQuantityRewardsLabel":"Add {{quantity}} item, get {{discount}}{{discount_type}} discount","bundleSpentAmountRewardsLabel":"Spent {{spent_amount}} worth of items, get {{discount}}{{discount_type}} discount","bundleQuantityLabel":"{{quantity}}x","bundleSubtotalLabel":"Subtotal","bundleDiscountLabel":"Discount","bundleTotalLabel":"Total","bundleCheckoutLabel":"Checkout","bundleMinimumQuantityLabel":"Add minimum {{minimum_quantity}} product","bundleMaximumQuantityLabel":"Add maximum up to {{maximum_quantity}} product","bundleMinimumOrderAmountLabel":"Add minimum {{minimum_amount}} order amount","oneTimePurchaseLabel":"One Time Purchase","noItemsInBundle":"No items added to the bundle","modalOpenOnAddToCart":true,"productAddedToBundleNotificationTitle":"Added to bundle","productAddedToBundleNotificationDescription":"{{product_title}} added to bundle.","chooseAPlanLabel":"Choose Plan","nextButtonLabel":"Next Step","previousButtonLabel":"Previous Step","chooseSourceProductValidationLabel":"Please choose source product!","chooseAssociatedProductsValidationLabel":"Please choose associated products!","choosePlanButtonLabel":"Choose Plan","selectedSourceProductLabel":"Selected","noSourceProductSelectedLabel":"No source product selected.","reviewOrderLabel":"Review Bundle","reviewOrderDescription":"Check your items and select your required frequency plan","reviewOrderProductsLabel":"Bundle Products","reviewOrderInfoLabel":"","orderNoteLabel":"Order Note","selectedProgressLabelText":"{{total_bundle_items}} item added with a minimum quantity of {{minimum_quantity}}","availableOnlySubscriptionLabel":"Available Only On Subscription","subscriptionAvailableLabel":"Subscription Available","oneTimeOnlyLabel":"One time only","switchOnTimeLabel":"One Time","switchSubscriptionLabel":"Subscribe & Save","breadCrumbPlanLabel":"Select Plan","breadCrumbProductsLabel":"Choose Products","breadCrumbReviewBundleLabel":"Review Bundle","showDescriptionPopup":true,"tieredDiscountLabel":"{{discount_amount}}{{discount_type}} Discount","emptyProductImage":"https://cdn.shopify.com/s/files/1/0661/9224/4900/files/EmptyImage.jpg?v=1718447038","outOfStockLabel":"Out Of Stock","notApplicableForOneTimeNotificationTitle":"Not applicable for one time","notApplicableForSubscribeAndSaveNotificationTitle":"Not applicable for subscribe & save","disableProductDescription":false,"descriptionLength":200,"readLessText":"Read Less","readMoreText":"Read More","bundleNoProductSelectedLabel":"No product selected","customHtmlInject":"[]","bundleDetailsLabel":"Your bundle:","bundleDiscountNote":"Discounts will be applied at checkout.","fixedDiscountText":"Enjoy a fixed discount of {{currency}}{{discount_value}} on your purchase!","percentDiscountText":"Get {{discount_value}}% off on your purchase!","hideVariantSelectLabel":false,"hidePurchaseOptionSelectLabel":false,"primaryColor":"#000000","primaryTextColor":"#000000","secondaryTextColor":"#ece0dc","primaryHoverColor":"#000000","primaryDisabledColor":"#333333","primaryDisabledTextColor":"#ffffff","fieldDisabledBackgroundColor":"#D1D5DB","disabledTextColor":"#6B7280","volumeDiscountSaveRewardsLabel":"Save {{discount}}{{discount_type}}!","volumeDiscountQuantityRewardsLabel":"Buy {{quantity}} quantity and get {{discount}}{{discount_type}} discount!","volumeDiscountSpentAmountRewardsLabel":"Spend {{currency}}{{spent_amount}} and get {{discount}}{{discount_type}} discount!","volumeDiscountAppliedQuantityRewardsLabel":"Applied: buy {{quantity}} get {{discount}}{{discount_type}}","volumeDiscountAppliedSpentAmountRewardsLabel":"Applied: spend {{spent_amount}}{{currency}} get {{discount}}{{discount_type}}","volumeDiscountNextApplicableQuantityRewardsLabel":"Buy {{quantity}} get {{discount}}{{discount_type}}","volumeDiscountNextApplicableSpentAmountRewardsLabel":"Spend {{spent_amount}}{{currency}} get {{discount}}{{discount_type}}","addingProductsToBundle":"Adding products to bundle","freeShippingLabel":"Free Shipping","requiredBundleProductLabel":"Your bundle needs {{min_product_count}} more item(s).","enableProductDetailButton":false,"requiredLoginValidationLabel":"Please log in to purchase this bundle!","bundleNotEligibleLabel":"You're not eligible to purchase this bundle!","loginAlertTextLabel":"You need to login to purchase this bundle.","loginAlertLinkLabel":"Click here to login","customSignInLink":"","shippingDiscountLabel":"{{discount}}{{discount_type}} Shipping Discount","classicBundleDescriptionLabel":"Your bundle contains the following products.","singleParentProductDirectRedirectToChildProducts":true,"buyXGetYFixedDiscountText":"Enjoy a fixed discount of {{discount_value}} {{currency}}","buyXGetYPercentDiscountText":"Enjoy a percentage discount of {{discount_value}}%","buyXGetYFreeGiftDiscountText":"Enjoy the free product","buyXGetYAddToCartLabel":"Add to cart","buyXGetYFreeLabel":"Free","disableDiscountedPricingRedirectToCart":false,"nonListedProductText":"Non-Listed","preventClickableProductsOnCart":false,"buyXGetYChooseProductLabel":"Choose Product","showSubscriptionPlanDescription":false,"volumeAmountDiscountSaveRewardsLabel":"Save {{currency}}{{discount}}!","volumeAmountDiscountQuantityRewardsLabel":"Buy {{quantity}} quantity and get {{currency}}{{discount}} discount!","volumeAmountDiscountSpentAmountRewardsLabel":"Spend {{currency}}{{spent_amount}} and get {{currency}}{{discount}} discount!","enableManualBundleBlockIntegration":false,"cartAndCheckoutQuantityValidationMessage":"Orders must match the quantity range: Min {{min_quantity}}, Max {{max_quantity}}","dynamicBundleDiscountCodeText":"BUNDLE_DISCOUNT_{{bundle_id}}","discountUsageLimitExceedLabel":"You have exceeded the bundle usage limit","disableViewShopifyProduct":false,"redirectToCartPageOnCartIconClick":true,"sectionLabel":"Section","chooseSectionLabel":"Choose Section","chooseSectionProductsLabel":"Choose Section Products","breadCrumbSelectSectionLabel":"Select Section","breadCrumbReviewSectionLabel":"Review Section","checkoutInfoLabel":"Add products from each section to enable the add to cart button.","sectionNoProductSelectedValidationLabel":"No product selected for: {{section_name}}!","sectionMinimumQuantityValidationLabel":"Minimum quantity not selected for: {{section_name}}!","sectionMaximumQuantityValidationLabel":"Maximum quantity not selected for: {{section_name}}!","dynamicBundleDiscountCombinedWithProductDiscount":true,"dynamicBundleDiscountCombinedWithShippingDiscount":true,"dynamicBundleDiscountCombinedWithOrderDiscount":true,"volumeDiscountCombinedWithProductDiscount":true,"volumeDiscountCombinedWithShippingDiscount":true,"volumeDiscountCombinedWithOrderDiscount":true,"productDiscountCombinedWithProductDiscount":true,"productDiscountCombinedWithShippingDiscount":true,"productDiscountCombinedWithOrderDiscount":true,"buyXGetYDiscountCombinedWithProductDiscount":true,"buyXGetYDiscountCombinedWithShippingDiscount":true,"buyXGetYDiscountCombinedWithOrderDiscount":true,"shippingDiscountCombinedWithProductDiscount":true,"shippingDiscountCombinedWithOrderDiscount":true,"showDynamicBundleOrderNote":false,"bundleMaximumOrderAmountLabel":"Add maximum {{maximum_amount}} order amount","buyXGetYQuantityValidationLabel":"Add {{product_quantity}} quantities of the gift product (Get Y)","selectedGiftProductProgressLabelText":"{{selected_product_quantity}} gift products added. The required quantity is {{required_product_quantity}}.","draftBundlePageTitle":"Oops! This bundle is temporarily unavailable.","draftBundlePageSubTitle":"In the meantime, check out our latest offers and discounts!","customOfferLink":"collections/all","customOfferLinkButtonLabel":"Explore Offers","enableParentProductDetailButton":false,"sectionTotalLabel":"Section Total","skipSelectSectionPage":false,"buyXGetYGiftProductPriceVisibilityType":"UNIT_PRICE","defaultSelectedPurchaseOptionSwitch":"ONE_TIME","defaultSelectedPurchaseOption":"ONE_TIME","discountTargetType":"VARIANT","enableShowMultipleImages":false,"buyXGetYAnyNumberOfGiftProductLabel":"Choose any number of gift products","showDiscountToNonEligibleCustomers":false,"dynamicBundleDiscountRecurringCycleLimit":0,"dynamicBundleDiscountAppliesOnOneTimePurchase":true,"dynamicBundleDiscountAppliesOnSubscription":true,"volumeDiscountRecurringCycleLimit":0,"volumeDiscountAppliesOnOneTimePurchase":true,"volumeDiscountAppliesOnSubscription":true,"productDiscountRecurringCycleLimit":0,"productDiscountAppliesOnOneTimePurchase":true,"productDiscountAppliesOnSubscription":true,"buyXGetYDiscountRecurringCycleLimit":0,"buyXGetYDiscountAppliesOnOneTimePurchase":true,"buyXGetYDiscountAppliesOnSubscription":true,"shippingDiscountRecurringCycleLimit":0,"shippingDiscountAppliesOnOneTimePurchase":true,"shippingDiscountAppliesOnSubscription":true,"buyXNoProductSelectedLabel":"No product selected (Buy X)","getYNoProductSelectedLabel":"No gift product selected (Get Y)","buyXQuantityValidationLabel":"Add {{product_quantity}} quantities of the product (Bux X)","buyXAnyNumberOfProductChooseLabel":"Choose any number of products","freeShippingDiscountCodeText":"FREE_SHIPPING_{{bundle_id}}","includedSubscriptionPlans":"","excludeSubscriptionPlans":"","enableBuyXGetYWidgetMergeAsOptions":false,"buyXGetYMergedWidgetTitle":"Select Buy X Get Y Discount","showClassicBundleProductVariant":false,"showProductPerPage":50,"loadMoreButtonLabel":"Load More","enableBundleProductAscOrderView":true,"cartAndCheckoutMandatoryProductValidationMessage":"This bundle or discount must include all required products and they cannot be removed.","sellingPlanNameSortOrder":"ASC","showVendorName":false,"disableFitImage":false,"enableAutoRemoveRelevantBundleItemInCart":false,"enableBundleProductFilter":false,"productFilterConfig":"{\"enabled\":false,\"filters\":[]}","enableMaxDiscountCap":false,"maxDiscountCapValue":0,"classicBundleLinkLabel":"Go to the Classic Bundle","showPriceAsDecimals":false,"showClassicBundleWidgetInChildProduct":false,"showOutOfStockProduct":true,"showDraftProduct":false,"totalBundleProductsAddedLabel":"{{total_bundle_items}} Products Added","bundleProductsQuantityLabel":"{{quantity}}x quantity","showUnitPrice":false,"productDetailsViewType":"SHOW_PRODUCT_POPUP","disableRefreshSellingPlan":false,"enableShippingDiscountBar":null,"enableVolumeDiscountBar":null,"defaultDiscountBarMessage":"Welcome to our store","discountMessageInterval":3000,"addedBundleToTheCart":null,"disabledSellingPlanSelectionValidation":false,"volumeDiscountVariantSelectLabel":"Denominations","enableScrollingToBundleSection":false,"enableClassicBundleRecreation":true,"topBarDiscountUnlockTitlePrefix":"You've unlocked ","topBarDiscountRequiredAmountTitlePrefix":"Add {{currency}}{{remainingAmount}} more to unlock ","topBarDiscountRequiredQuantityTitlePrefix":"Add {{remainingQuantity}} more item(s) to unlock ","topBarPercentDiscountTitlePostfix":"{{discount}}% off on shipping","topBarFixedDiscountTitlePostfix":"{{currency}}{{discount}} off on shipping","topBarFreeShippingTitlePostfix":"free shipping","checkInventoryQuantity":false,"hideBundleToastNotification":false,"enableBundleRecreation":null,"enableAnnouncementBar":false,"enableAnnouncementBarAutoRotate":true,"bundleListTitle":"List of Bundles and Discounted Pricing","bundleListDescription":"Explore our Bundles and Discounted Pricing and enjoy exclusive discounts when you buy products together","bundleListViewDetailsButtonLabel":"View Details","classicBundleTypeLabel":"Classic Bundle","dynamicPricingBundleTypeLabel":"Dynamic Pricing Bundle","fixedPricingBundleTypeLabel":"Fixed Pricing Bundle","sectionedBundleTypeLabel":"Sectioned Bundle","volumeDiscountTypeLabel":"Volume Discount","productDiscountTypeLabel":"Product Discount","buyXGetYDiscountTypeLabel":"Buy X Get Y Discount","bundlePageBackgroundColor":"#FAFAF9","productCardBackgroundColor":"#ffffff","buttonBackgroundColor":"#000000","showPrepaidPerDeliveryPrice":null,"prepaidPerDeliveryPriceLabel":null};
if (!bundleSettings?.enableAutoRemoveRelevantBundleItemInCart) return;
const originalFetch = window.fetch;
window.fetch = async function (...args) {
const [resource, config] = args;
const isRemoveRequest = typeof resource === 'string' &&
resource.includes('/cart/change') &&
config?.method === 'POST';
if (!isRemoveRequest) {
return originalFetch(...args);
}
let bodyData = {};
try {
bodyData = JSON.parse(config.body);
} catch (e) {
console.warn('Failed to parse request body', e);
return originalFetch(...args);
}
if (bodyData.quantity !== 0) {
return originalFetch(...args);
}
const cart = await fetch('/cart.js').then(res => res.json());
const removingLineIndex = parseInt(bodyData?.line) - 1;
const removingItem = cart?.items[removingLineIndex];
const bundleId = removingItem?.properties?.["_appstle-bb-id"];
if (!bundleId) {
return originalFetch(...args);
}
const updates = {};
cart?.items.forEach(item => {
if (item?.properties?.["_appstle-bb-id"] === bundleId) {
updates[item?.key] = 0;
}
});
const hasNonBundleItems = cart?.items.some(item => !item?.properties?.["_appstle-bb-id"]);
await fetch('/cart/update.js', {
method: 'POST',
headers: {
'Content-Type': 'application/json'
},
body: JSON.stringify({ updates })
});
if (hasNonBundleItems) {
const sections = bodyData?.sections;
const sectionsUrl = bodyData?.sections_url || '/cart';
const htmlResponse = await fetch(
`/?sections=${sections.join(',')}§ions_url=${encodeURIComponent(sectionsUrl)}`
);
const htmlData = await htmlResponse.json();
return new Response(JSON.stringify({
status: 'bundle removed',
sections: htmlData
}), {
status: 200,
headers: { 'Content-Type': 'application/json' }
});
}
return originalFetch(...args);
};
});
document.addEventListener('DOMContentLoaded', () => {
const originalFetch = window.fetch;
window.fetch = async function (...args) {
const [resource, config] = args;
const isCartUpdate = typeof resource === 'string' &&
(resource.includes('/cart/change') || resource.includes('/cart/update')) &&
config?.method === 'POST';
if (!isCartUpdate) {
return originalFetch(...args);
}
const response = await originalFetch(...args);
const cart = await fetch('/cart.js').then(res => res.json());
const hasBundleItems = cart?.items.some(item =>
item?.properties?.["_appstle-bb-id"]
);
const freeProductItems = cart?.items.filter(item =>
item?.properties?.["_appstle_free_product"] === true ||
item?.properties?.["_appstle_free_product"] === "true"
);
if (!hasBundleItems && freeProductItems.length > 0) {
const updates = {};
freeProductItems.forEach(item => {
updates[item?.key] = 0;
});
await fetch('/cart/update.js', {
method: 'POST',
headers: {
'Content-Type': 'application/json'
},
body: JSON.stringify({ updates })
});
let bodyData = {};
try {
bodyData = JSON.parse(config.body);
} catch (e) {
}
if (bodyData?.sections) {
const sections = bodyData.sections;
const sectionsUrl = bodyData.sections_url || '/cart';
const htmlResponse = await fetch(
`/?sections=${sections.join(',')}§ions_url=${encodeURIComponent(sectionsUrl)}`
);
const htmlData = await htmlResponse.json();
return new Response(JSON.stringify({
status: 'free product removed',
sections: htmlData
}), {
status: 200,
headers: { 'Content-Type': 'application/json' }
});
}
}
return response;
};
});