# Terms Checkbox

> TermsCheckbox checkout acceptance state and checkout blocking behavior.

<!-- Sources: src/Components/Woo/TermsCheckbox/TermsCheckbox.php; client/src/domains/woo/components/terms-checkbox.ts; client/src/domains/woo/checkout-store.ts; src/Testing/E2E/Woo/WooScenarioProvider.php; tests/e2e/components/woo/behavior.spec.ts -->

# Terms Checkbox

`TermsCheckbox` renders checkout terms acceptance and tells the checkout store whether terms are accepted.

## Component

| Component key | Role |
| --- | --- |
| `OmeWooTermsCheckbox` | Renders the terms checkbox, optional label slot, and checkout terms state. |

## Props

| Prop | Meaning |
| --- | --- |
| `content.label` | Label text when using component-managed label copy. |
| `content.required_message` | Local error message when terms are required but unchecked. |
| `accessibility.aria_label` | Accessible checkbox label. |

The component also accepts a default slot, so authors can put richer terms copy next to the checkbox.

## Runtime Behavior

The runtime binds `input[data-ome-woo-terms-checkbox]` and updates the checkout store:

| Store flag | Meaning |
| --- | --- |
| `terms_required` | Checkout should block if the checkbox is unchecked. |
| `terms_accepted` | Current checkbox state. |

When terms are required and unchecked, `WooCheckoutStore.submit()` emits a local `terms_required` error, sets checkout state to `error`, and `CheckoutNotices` renders the message.

## Scenario Coverage

| Scenario | Covered behavior |
| --- | --- |
| `checkout_terms_blocked` | Unchecked terms blocks checkout and renders a checkout notice. |
| `checkout_terms_success` | Checked terms allows checkout success. |
| `lifecycle_checkout` | Terms accepted flow reaches Store API checkout and native order hooks. |
