{
  "name": "drawer-cancel-sub",
  "kind": "block",
  "primary": "drawer-ui",
  "page": "/apps/saas/app/billing/billing.contents.html",
  "slots": [],
  "nested": [],
  "attrs": {
    "side": "right",
    "size": "md"
  },
  "html": "<drawer-ui id=\"drawer-cancel-sub\" side=\"right\" size=\"md\">\n  <header>\n    <span slot=\"icon\">\n      <avatar-ui icon=\"warning-octagon\"></avatar-ui>\n    </span>\n    <span slot=\"heading\">\n      <text-ui strong>Cancel subscription</text-ui>\n      <badge-ui text=\"Pro\" variant=\"accent\"></badge-ui>\n    </span>\n    <span slot=\"action\"></span>\n  </header>\n  <section>\n    <text-ui color=\"subtle\" size=\"sm\">Your workspace stays available until May 14, 2026 — the end of your current billing period.</text-ui>\n  </section>\n  <section>\n    <col-ui gap=\"4\">\n      <!-- Save offer — shown BEFORE the reason picker; the canonical\n           \"retention\" step in a cancellation flow. Three alternatives\n           to outright cancellation, each addressing a common reason\n           (cost / temporary break / feature gap). Clicking any one\n           closes the drawer and would route to the corresponding\n           apply-discount / pause / downgrade flow in a real app. -->\n      <col-ui gap=\"3\">\n        <text-ui strong>Before you go — try one of these instead</text-ui>\n        <list-ui divider>\n          <list-item-ui>\n            <card-ui>\n              <header>\n                <span slot=\"icon\"><icon-ui name=\"percent\"></icon-ui></span>\n                <span slot=\"heading\">\n                  <text-ui strong>Save 30% for 3 months</text-ui>\n                  <badge-ui text=\"One-time offer\" variant=\"success\"></badge-ui>\n                </span>\n                <span slot=\"description\">\n                  <text-ui color=\"subtle\" size=\"sm\">Your Pro plan drops from $49/mo to $34/mo through Aug 14, 2026.</text-ui>\n                </span>\n                <span slot=\"action\">\n                  <button-ui text=\"Apply discount\" variant=\"primary\" size=\"sm\" onclick=\"this.closest('drawer-ui').open = false\"></button-ui>\n                </span>\n              </header>\n            </card-ui>\n          </list-item-ui>\n          <list-item-ui>\n            <card-ui>\n              <header>\n                <span slot=\"icon\"><icon-ui name=\"pause\"></icon-ui></span>\n                <span slot=\"heading\">\n                  <text-ui strong>Pause for 1 month</text-ui>\n                </span>\n                <span slot=\"description\">\n                  <text-ui color=\"subtle\" size=\"sm\">Workspace stays accessible read-only. No charge during the pause; resume anytime.</text-ui>\n                </span>\n                <span slot=\"action\">\n                  <button-ui text=\"Pause plan\" variant=\"outline\" size=\"sm\" onclick=\"this.closest('drawer-ui').open = false\"></button-ui>\n                </span>\n              </header>\n            </card-ui>\n          </list-item-ui>\n          <list-item-ui>\n            <card-ui>\n              <header>\n                <span slot=\"icon\"><icon-ui name=\"arrow-down\"></icon-ui></span>\n                <span slot=\"heading\">\n                  <text-ui strong>Downgrade to Free</text-ui>\n                </span>\n                <span slot=\"description\">\n                  <text-ui color=\"subtle\" size=\"sm\">Keep core features at no cost. 3-conversation limit, basic charts, community support.</text-ui>\n                </span>\n                <span slot=\"action\">\n                  <button-ui text=\"Switch to Free\" variant=\"outline\" size=\"sm\" onclick=\"this.closest('drawer-ui').open = false\"></button-ui>\n                </span>\n              </header>\n            </card-ui>\n          </list-item-ui>\n        </list-ui>\n      </col-ui>\n      <divider-ui></divider-ui>\n      <alert-ui\n        variant=\"danger\"\n        icon=\"warning\"\n        text=\"You'll lose access to Pro features (advanced charts, API exports, priority support) on May 14. Your data is preserved for 90 days after cancellation.\"\n      ></alert-ui>\n      <divider-ui></divider-ui>\n      <col-ui gap=\"2\">\n        <text-ui strong>What happens on May 14</text-ui>\n        <row-ui gap=\"2\" align=\"center\"><icon-ui name=\"x-circle\" color=\"danger\"></icon-ui><text-ui>Advanced charts become view-only</text-ui></row-ui>\n        <row-ui gap=\"2\" align=\"center\"><icon-ui name=\"x-circle\" color=\"danger\"></icon-ui><text-ui>API key quota drops from 1M to 10K/month</text-ui></row-ui>\n        <row-ui gap=\"2\" align=\"center\"><icon-ui name=\"x-circle\" color=\"danger\"></icon-ui><text-ui>Priority support downgrades to community</text-ui></row-ui>\n        <row-ui gap=\"2\" align=\"center\"><icon-ui name=\"check-circle\" color=\"success\"></icon-ui><text-ui>Workspace, members, and history remain</text-ui></row-ui>\n      </col-ui>\n      <divider-ui></divider-ui>\n      <field-ui label=\"Primary reason for cancelling\">\n        <select-ui value=\"\">\n          <option value=\"\">Select a reason</option>\n          <option value=\"too-expensive\">Too expensive</option>\n          <option value=\"missing-features\">Missing features I need</option>\n          <option value=\"switching\">Switching to another tool</option>\n          <option value=\"not-using\">Not using it enough</option>\n          <option value=\"temporary\">Taking a break, may return</option>\n          <option value=\"other\">Other</option>\n        </select-ui>\n      </field-ui>\n      <field-ui label=\"Anything we could do better?\">\n        <textarea-ui rows=\"3\" placeholder=\"Optional — but we read every response.\"></textarea-ui>\n      </field-ui>\n      <divider-ui></divider-ui>\n      <field-ui label=\"Type CANCEL to confirm\">\n        <input-ui placeholder=\"CANCEL\"></input-ui>\n      </field-ui>\n    </col-ui>\n  </section>\n  <footer slot=\"footer\">\n    <grid-ui>\n      <button-ui text=\"Keep my plan\" variant=\"ghost\" onclick=\"this.closest('drawer-ui').open = false\"></button-ui>\n      <button-ui text=\"Confirm cancellation\" color=\"danger\" onclick=\"this.closest('drawer-ui').open = false\"></button-ui>\n    </grid-ui>\n  </footer>\n</drawer-ui>",
  "source": "apps/saas/app/billing/billing.contents.html",
  "metadata": {
    "domain": "settings",
    "description": "Cancel subscription drawer — cancellation reason form with pause-plan alternative.",
    "keywords": [
      "drawer",
      "cancel",
      "subscription",
      "billing",
      "churn",
      "reason",
      "form"
    ]
  },
  "captured_at": "2026-06-07T19:28:13.657Z",
  "template": [
    {
      "id": "avatar",
      "component": "Avatar",
      "icon": "warning-octagon"
    },
    {
      "id": "text",
      "component": "Text",
      "variant": "body",
      "slot": "icon",
      "children": [
        "avatar"
      ]
    },
    {
      "id": "text-3",
      "component": "Text",
      "strong": true,
      "textContent": "Cancel subscription"
    },
    {
      "id": "badge",
      "component": "Badge",
      "text": "Pro",
      "variant": "accent"
    },
    {
      "id": "text-2",
      "component": "Text",
      "variant": "body",
      "slot": "heading",
      "children": [
        "text-3",
        "badge"
      ]
    },
    {
      "id": "text-4",
      "component": "Text",
      "variant": "body",
      "slot": "action"
    },
    {
      "id": "header",
      "component": "Header",
      "children": [
        "text",
        "text-2",
        "text-4"
      ]
    },
    {
      "id": "text-5",
      "component": "Text",
      "color": "subtle",
      "size": "sm",
      "textContent": "Your workspace stays available until May 14, 2026 — the end of your current billing period."
    },
    {
      "id": "section",
      "component": "Section",
      "children": [
        "text-5"
      ]
    },
    {
      "id": "text-6",
      "component": "Text",
      "strong": true,
      "textContent": "Before you go — try one of these instead"
    },
    {
      "id": "percent",
      "component": "Icon",
      "name": "percent"
    },
    {
      "id": "text-7",
      "component": "Text",
      "variant": "body",
      "slot": "icon",
      "children": [
        "percent"
      ]
    },
    {
      "id": "text-9",
      "component": "Text",
      "strong": true,
      "textContent": "Save 30% for 3 months"
    },
    {
      "id": "badge-2",
      "component": "Badge",
      "text": "One-time offer",
      "variant": "success"
    },
    {
      "id": "text-8",
      "component": "Text",
      "variant": "body",
      "slot": "heading",
      "children": [
        "text-9",
        "badge-2"
      ]
    },
    {
      "id": "text-11",
      "component": "Text",
      "color": "subtle",
      "size": "sm",
      "textContent": "Your Pro plan drops from $49/mo to $34/mo through Aug 14, 2026."
    },
    {
      "id": "text-10",
      "component": "Text",
      "variant": "body",
      "slot": "description",
      "children": [
        "text-11"
      ]
    },
    {
      "id": "button",
      "component": "Button",
      "size": "sm",
      "text": "Apply discount",
      "variant": "primary"
    },
    {
      "id": "text-12",
      "component": "Text",
      "variant": "body",
      "slot": "action",
      "children": [
        "button"
      ]
    },
    {
      "id": "header-2",
      "component": "Header",
      "children": [
        "text-7",
        "text-8",
        "text-10",
        "text-12"
      ]
    },
    {
      "id": "card",
      "component": "Card",
      "children": [
        "header-2"
      ]
    },
    {
      "id": "list-item",
      "component": "ListItem",
      "children": [
        "card"
      ]
    },
    {
      "id": "pause",
      "component": "Icon",
      "name": "pause"
    },
    {
      "id": "text-13",
      "component": "Text",
      "variant": "body",
      "slot": "icon",
      "children": [
        "pause"
      ]
    },
    {
      "id": "text-15",
      "component": "Text",
      "strong": true,
      "textContent": "Pause for 1 month"
    },
    {
      "id": "text-14",
      "component": "Text",
      "variant": "body",
      "slot": "heading",
      "children": [
        "text-15"
      ]
    },
    {
      "id": "text-17",
      "component": "Text",
      "color": "subtle",
      "size": "sm",
      "textContent": "Workspace stays accessible read-only. No charge during the pause; resume anytime."
    },
    {
      "id": "text-16",
      "component": "Text",
      "variant": "body",
      "slot": "description",
      "children": [
        "text-17"
      ]
    },
    {
      "id": "button-2",
      "component": "Button",
      "size": "sm",
      "text": "Pause plan",
      "variant": "outline"
    },
    {
      "id": "text-18",
      "component": "Text",
      "variant": "body",
      "slot": "action",
      "children": [
        "button-2"
      ]
    },
    {
      "id": "header-3",
      "component": "Header",
      "children": [
        "text-13",
        "text-14",
        "text-16",
        "text-18"
      ]
    },
    {
      "id": "card-2",
      "component": "Card",
      "children": [
        "header-3"
      ]
    },
    {
      "id": "list-item-2",
      "component": "ListItem",
      "children": [
        "card-2"
      ]
    },
    {
      "id": "arrow-down",
      "component": "Icon",
      "name": "arrow-down"
    },
    {
      "id": "text-19",
      "component": "Text",
      "variant": "body",
      "slot": "icon",
      "children": [
        "arrow-down"
      ]
    },
    {
      "id": "text-21",
      "component": "Text",
      "strong": true,
      "textContent": "Downgrade to Free"
    },
    {
      "id": "text-20",
      "component": "Text",
      "variant": "body",
      "slot": "heading",
      "children": [
        "text-21"
      ]
    },
    {
      "id": "text-23",
      "component": "Text",
      "color": "subtle",
      "size": "sm",
      "textContent": "Keep core features at no cost. 3-conversation limit, basic charts, community support."
    },
    {
      "id": "text-22",
      "component": "Text",
      "variant": "body",
      "slot": "description",
      "children": [
        "text-23"
      ]
    },
    {
      "id": "button-3",
      "component": "Button",
      "size": "sm",
      "text": "Switch to Free",
      "variant": "outline"
    },
    {
      "id": "text-24",
      "component": "Text",
      "variant": "body",
      "slot": "action",
      "children": [
        "button-3"
      ]
    },
    {
      "id": "header-4",
      "component": "Header",
      "children": [
        "text-19",
        "text-20",
        "text-22",
        "text-24"
      ]
    },
    {
      "id": "card-3",
      "component": "Card",
      "children": [
        "header-4"
      ]
    },
    {
      "id": "list-item-3",
      "component": "ListItem",
      "children": [
        "card-3"
      ]
    },
    {
      "id": "list",
      "component": "List",
      "divider": true,
      "children": [
        "list-item",
        "list-item-2",
        "list-item-3"
      ]
    },
    {
      "id": "column-2",
      "component": "Column",
      "gap": "3",
      "children": [
        "text-6",
        "list"
      ]
    },
    {
      "id": "divider",
      "component": "Divider"
    },
    {
      "id": "alert",
      "component": "Alert",
      "icon": "warning",
      "text": "You'll lose access to Pro features (advanced charts, API exports, priority support) on May 14. Your data is preserved for 90 days after cancellation.",
      "variant": "danger"
    },
    {
      "id": "divider-2",
      "component": "Divider"
    },
    {
      "id": "text-25",
      "component": "Text",
      "strong": true,
      "textContent": "What happens on May 14"
    },
    {
      "id": "x-circle",
      "component": "Icon",
      "name": "x-circle"
    },
    {
      "id": "text-26",
      "component": "Text",
      "textContent": "Advanced charts become view-only"
    },
    {
      "id": "row",
      "component": "Row",
      "align": "center",
      "gap": "2",
      "children": [
        "x-circle",
        "text-26"
      ]
    },
    {
      "id": "icon",
      "component": "Icon",
      "name": "x-circle"
    },
    {
      "id": "text-27",
      "component": "Text",
      "textContent": "API key quota drops from 1M to 10K/month"
    },
    {
      "id": "row-2",
      "component": "Row",
      "align": "center",
      "gap": "2",
      "children": [
        "icon",
        "text-27"
      ]
    },
    {
      "id": "icon-2",
      "component": "Icon",
      "name": "x-circle"
    },
    {
      "id": "text-28",
      "component": "Text",
      "textContent": "Priority support downgrades to community"
    },
    {
      "id": "row-3",
      "component": "Row",
      "align": "center",
      "gap": "2",
      "children": [
        "icon-2",
        "text-28"
      ]
    },
    {
      "id": "check-circle",
      "component": "Icon",
      "name": "check-circle"
    },
    {
      "id": "text-29",
      "component": "Text",
      "textContent": "Workspace, members, and history remain"
    },
    {
      "id": "row-4",
      "component": "Row",
      "align": "center",
      "gap": "2",
      "children": [
        "check-circle",
        "text-29"
      ]
    },
    {
      "id": "column-3",
      "component": "Column",
      "gap": "2",
      "children": [
        "text-25",
        "row",
        "row-2",
        "row-3",
        "row-4"
      ]
    },
    {
      "id": "divider-3",
      "component": "Divider"
    },
    {
      "id": "choice-picker",
      "component": "ChoicePicker",
      "options": [
        {
          "value": "",
          "label": "Select a reason"
        },
        {
          "value": "too-expensive",
          "label": "Too expensive"
        },
        {
          "value": "missing-features",
          "label": "Missing features I need"
        },
        {
          "value": "switching",
          "label": "Switching to another tool"
        },
        {
          "value": "not-using",
          "label": "Not using it enough"
        },
        {
          "value": "temporary",
          "label": "Taking a break, may return"
        },
        {
          "value": "other",
          "label": "Other"
        }
      ]
    },
    {
      "id": "field",
      "component": "Field",
      "label": "Primary reason for cancelling",
      "children": [
        "choice-picker"
      ]
    },
    {
      "id": "text-area",
      "component": "TextArea",
      "placeholder": "Optional — but we read every response.",
      "rows": "3"
    },
    {
      "id": "field-2",
      "component": "Field",
      "label": "Anything we could do better?",
      "children": [
        "text-area"
      ]
    },
    {
      "id": "divider-4",
      "component": "Divider"
    },
    {
      "id": "input",
      "component": "Input",
      "placeholder": "CANCEL"
    },
    {
      "id": "field-3",
      "component": "Field",
      "label": "Type CANCEL to confirm",
      "children": [
        "input"
      ]
    },
    {
      "id": "column",
      "component": "Column",
      "gap": "4",
      "children": [
        "column-2",
        "divider",
        "alert",
        "divider-2",
        "column-3",
        "divider-3",
        "field",
        "field-2",
        "divider-4",
        "field-3"
      ]
    },
    {
      "id": "section-2",
      "component": "Section",
      "children": [
        "column"
      ]
    },
    {
      "id": "button-4",
      "component": "Button",
      "text": "Keep my plan",
      "variant": "ghost"
    },
    {
      "id": "button-5",
      "component": "Button",
      "color": "danger",
      "text": "Confirm cancellation"
    },
    {
      "id": "grid",
      "component": "Grid",
      "children": [
        "button-4",
        "button-5"
      ]
    },
    {
      "id": "footer",
      "component": "Footer",
      "slot": "footer",
      "children": [
        "grid"
      ]
    },
    {
      "id": "root",
      "component": "Drawer",
      "side": "right",
      "size": "md",
      "children": [
        "header",
        "section",
        "section-2",
        "footer"
      ]
    }
  ]
}
