@namiml/web-sdk 3.4.10 → 3.4.11-dev.202609092330

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -106,19 +106,22 @@ declare class NamiButton extends NamiElement {
106
106
  protected updated(changedProperties: PropertyValueMap<this>): void;
107
107
  private _handleFocus;
108
108
  /**
109
- * NAM-3607: on CTV, focus is the selection signal — there is no tap to select a product.
110
- * Bridge a focused product button into `state.selectedProducts` so conditions and smart
111
- * text authored against `${state.selectedProducts.${state.currentGroupId}}` resolve
112
- * against the *focused* product. Buttons outside a product card carry no `sku` (it is
113
- * attached per card by `appendSkuToComponents`) and are ignored, as is every non-television
114
- * form factor, where tap already drives selection.
109
+ * On CTV, focus is the selection signal — there is no tap to select a product (NAM-3607).
115
110
  *
116
- * This button path only ever sets a selection, never clears one: a blur/non-product
117
- * clear here would fight the template's `initialState` selection on incidental focus
118
- * churn. The clear lives on the positive signal instead — focusing the group toggle
119
- * clears the current group's selection (`NamiSegmentPicker._handleFocusIn` →
120
- * `clearSelectedProduct`, NAM-3606), matching Apple's `setFocusedSku(nil)`. `selectSKU`
121
- * is idempotent, so repeat focus events on the same card do not trigger a re-render.
111
+ * - A focused PRODUCT button (one carrying a `sku`, attached per card by `appendSkuToComponents`)
112
+ * is bridged into `state.selectedProducts`, so conditions and smart text authored against
113
+ * `${state.selectedProducts.${state.currentGroupId}}` resolve against the *focused* product.
114
+ * `selectSKU` is idempotent, so repeat focus events on the same card do not re-render.
115
+ * - A focused NON-product button (login / restore / TV-provider — no `sku`) CLEARS the current
116
+ * group's selection (NAM-4270, decision 3 on NAM-4265), the same positive signal the group
117
+ * toggle already uses (`NamiSegmentPicker._handleFocusIn` → `clearSelectedProduct`, NAM-3606).
118
+ * Every `${sku.*}`-conditioned tile then takes its non-premium branch, matching Apple's
119
+ * `setFocusedSku(nil)` and Roku. This supersedes the earlier set-only rule from NAM-3607.
120
+ *
121
+ * Only focus-IN clears; `_handleBlur` never touches the selection, so focus merely leaving a
122
+ * card does nothing, and on web focus moves only under user input (TVJS), never as a side
123
+ * effect of a re-render — the Compose recomposition-loop hazard behind Android's settle guard
124
+ * does not apply here. Every non-television form factor is ignored: tap drives selection there.
122
125
  */
123
126
  private _selectFocusedProductOnTelevision;
124
127
  private _handleBlur;