> For the complete documentation index, see [llms.txt](https://docs-shpf.bsscommerce.com/bss-b2b-lock-login-password-hide-price/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs-shpf.bsscommerce.com/bss-b2b-lock-login-password-hide-price/getting-started/app-settings-installation-and-maintenance.md).

# App Settings, Installation & Maintenance

Manage global store-wide settings for BSS B2B Lock, including Theme Editor visibility, theme targeting, app embeds, and code cleanup.

While individual lock rules are configured with their own targets and conditions, the **Settings** area in BSS B2B Lock manages global, store-wide behaviors, theme integration environments, and code lifecycle management.

***

### On This Page

1. [Display Rules on Shopify Theme Editor](#display-rules-on-shopify-theme-editor)
2. [Theme Targeting (Live vs Draft Theme)](#theme-targeting-live-vs-draft-theme)
3. [App Embed Central Management](#app-embed-central-management)
4. [Theme Cleanup & Disabling Rules Before Uninstalling](#theme-cleanup--disabling-rules-before-uninstalling)
5. [Summary of Global Settings vs Per-Rule Settings](#summary-of-global-settings-vs-per-rule-settings)

***

## 1. Display Rules on Shopify Theme Editor

Under **App Settings**, you can control whether lock rules take effect inside the Shopify Theme Customizer/Editor.

* **Setting Location:** **BSS B2B Lock → Settings → General / App Settings → Display rules on Theme Editor**
* **Default State:** **ON** (enabled by default for all stores to comply with Shopify App Store requirements and ensure WYSIWYG editing).
* **Storefront Behavior:** When enabled, whenever you or your team open Shopify Admin → Online Store → Themes → Customize, the preview renders locked content exactly as a customer would experience it.
* **Troubleshooting / Merchant Tip:** If you need to edit theme sections, customize layout blocks, or adjust styling freely without triggering app lock overlays or login gates in the theme preview, you can temporarily toggle this setting **OFF**. Remember to turn it back **ON** once your visual editing is complete.

***

## 2. Theme Targeting (Live vs Draft Theme)

Testing B2B locks on a live production storefront can disrupt active customers. The **Installation** tab allows you to isolate app script injection to a staging theme.

* **Setting Location:** **BSS B2B Lock → Installation → Auto Installation**
* **Install to TEST (Draft Theme):**
  1. Select **Install to TEST (Draft)**.
  2. Choose your staging or duplicate theme from the theme dropdown (e.g. *Theme Dawn (Staging)*).
  3. Click **Install**.
  4. The top banner in the app will reflect: *Install target: \[Theme Name] — Draft Theme*.
  5. Lock rules created or edited in the app will only execute when previewing that specific draft theme.
* **Install to LIVE (Published Theme):**
  1. Once you have verified your locks in the draft preview, return to **Settings → Installation**.
  2. Select **Install to LIVE (Published)**.
  3. Select your published theme and click **Install**.
  4. The banner updates to confirm live storefront execution.

{% hint style="info" %}
**Verification Timestamp**: After auto-installation completes, check the **Latest Install (Date)** field. If it displays a valid timestamp, the theme code injection succeeded. If it displays *Invalid Date*, rerun the installation or contact support.
{% endhint %}

***

## 3. App Embed Central Management

The **BSS B2B Lock App Embed** connects the app's locking logic and rules to your storefront theme:

* **Central Dashboard Control:** App embed status is monitored directly from the **App Dashboard** header.
* **Theme Switching:** Whenever you publish a new theme or duplicate your active theme, always verify that the BSS B2B Lock app embed is turned **ON** in **Shopify Admin → Online Store → Themes → Customize → App Embeds**.

***

## 4. Theme Cleanup & Disabling Rules Before Uninstalling

If you ever decide to change themes, pause usage, or uninstall BSS B2B Lock, you should always deactivate all active rules and remove injected snippets first to prevent accidental customer lockouts.

* **Setting Location:** **BSS B2B Lock → Theme Cleanup** (left navigation menu) or **Settings → Clean up code**
* **Why this is critical:**
  * Auto-installation injects theme Liquid snippets to ensure locks work reliably across all page templates.
  * If the app is uninstalled directly from Shopify Apps without running cleanup, orphaned code snippets can remain in your theme files and keep pages locked.
* **The New Theme Cleanup Page (One-Click Deactivation):**
  * The dedicated **Theme Cleanup** page checks whether lock rules are active on any theme across your store.
  * Click **Disable all rules** and confirm to deactivate 100% of lock rules across all themes, clean up draft theme injections, and instantly restore standard storefront browsing.
  * For full details and step-by-step instructions, see the dedicated [Theme Cleanup Guide](/bss-b2b-lock-login-password-hide-price/getting-started/theme-cleanup.md).

{% hint style="warning" %}
**Best Practice**: Always navigate to **Theme Cleanup** and click **Disable all rules** *before* clicking "Uninstall app" in your Shopify Admin. If you have already uninstalled the app and notice leftover snippets, contact **<support-sbc@bsscommerce.com>** for free cleanup assistance.
{% endhint %}

***

## 5. Summary of Global Settings vs Per-Rule Settings

| Scope                          | Where Configured                                | Examples                                                                                                                        |
| ------------------------------ | ----------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| **Global App Settings**        | **App Settings / Installation / Theme Cleanup** | Theme Editor visibility toggle, Target theme (Live vs Draft), App Embed activation, Theme Cleanup & One-Click Rule Deactivation |
| **Per-Rule Advanced Settings** | **Step 3 of Rule Builder (Lock Settings)**      | Custom lock message, Login/Register buttons, Passcode timeout, Excluded URLs, Session expiry                                    |

***

## **Still Need Help?**

If you have questions or need assistance configuring BSS B2B Lock, our dedicated support team is here to help.

* **In-App Assistance:** Click **Need help?** or use the in-app chat button within BSS B2B Lock.
* **Email Support:** Contact us at [**support-sbc@bsscommerce.com**](mailto:support-sbc@bsscommerce.com) with your store URL and specific rule details.
