yukey

comments: capitals-for-emphasis in body comments become lowercase

commit dc38216d2fdad5161f10d2dd95618f5758f5c08e · parent 1f1e6068b2 · browse this tree
Ximianth, 2026-10-24 10:48:44 UTC

The docs round lowercased emphasis in the comments it moved; these are
the ones it left in function bodies.  Event.NONE in yk-infopop names the
constant and stays.
diff --git a/packages/yukey/src/megacolumn-controller.ts b/packages/yukey/src/megacolumn-controller.ts
index 4315c93..aa1d3c3 100644
--- a/packages/yukey/src/megacolumn-controller.ts
+++ b/packages/yukey/src/megacolumn-controller.ts
@@ -303,7 +303,7 @@ export class MegacolumnController implements ReactiveController {
 			}
 			// aria-activedescendant needs a referencable id; derive one from the row id.
 			// The mc- prefix is reserved for this derivation: Lit reuses DOM nodes by
-			// position, so an element can reappear under a NEW row identity carrying its
+			// position, so an element can reappear under a new row identity carrying its
 			// old derived id, which must be re-derived (author-set ids are left alone).
 			const derivedId = `mc-${id}`;
 			if (el.id === "" || (el.id.startsWith("mc-") && el.id !== derivedId)) el.id = derivedId;
@@ -420,7 +420,7 @@ export class MegacolumnController implements ReactiveController {
 			row.classList.add("mc-row-focused");
 			control.classList.add("mc-focused");
 			this.#ringed = [row, control];
-			// Logical focus must never sit off-screen, and browsers do NOT scroll
+			// Logical focus must never sit off-screen, and browsers do not scroll
 			// aria-activedescendant targets into view on their own -- so every focus
 			// identity change scrolls here, covering arrows, Home/End, hotkey jumps,
 			// and churn fallbacks in one place.  Nearest-edge and instant: a smooth
@@ -435,7 +435,7 @@ export class MegacolumnController implements ReactiveController {
 			"mc-empty-focus",
 			focusedId === null && this.focusIsInside(container),
 		);
-		// Announce focus IDENTITY changes (see the header's megacolumn-focus-change
+		// Announce focus identity changes (see the header's megacolumn-focus-change
 		// contract).  Dispatched here, the one place every cause converges -- arrows,
 		// Home/End, hotkey jumps, churn fallbacks, focus requests -- and after the
 		// scroll above, so a listener reading anchor geometry sees the settled row.
diff --git a/packages/yukey/src/yk-button.ts b/packages/yukey/src/yk-button.ts
index 2573546..31a2ddf 100644
--- a/packages/yukey/src/yk-button.ts
+++ b/packages/yukey/src/yk-button.ts
@@ -313,7 +313,7 @@ export class YkButton extends LitElement {
 		if ((key === "Enter" || key === " ") && atUs) {
 			this.#claimActivation(e);
 		} else if (this.#hotkey !== "" && k === this.#hotkey && this.#hotkeyDirect) {
-			// A non-direct hotkey is deliberately NOT claimed: the decline is what
+			// A non-direct hotkey is deliberately not claimed: the decline is what
 			// lets the controller resolve the marking as a focus move to this row.
 			this.#claimActivation(e);
 		} else if ((k === "x" || key === "Delete") && this.#position() === "aux") {
@@ -396,7 +396,7 @@ export class YkButton extends LitElement {
 		const ariaDisabled = this.disabled ? "true" : undefined;
 		const ariaCurrent = this.active ? "true" : undefined;
 		const ariaKeys = this.#hotkey !== "" ? this.#hotkey : undefined;
-		// The label wrapper keeps the (possibly marking-split) label ONE flex item:
+		// The label wrapper keeps the (possibly marking-split) label one flex item:
 		// .btn is a flex container, and three anonymous items would have the
 		// whitespace at their edges trimmed ("cycle beacon" -> "cyclebeacon").
 		const content = html`<span class="label">${this.#content(marked)}</span>${
diff --git a/packages/yukey/src/yk-infopop.ts b/packages/yukey/src/yk-infopop.ts
index e5da36d..e48c481 100644
--- a/packages/yukey/src/yk-infopop.ts
+++ b/packages/yukey/src/yk-infopop.ts
@@ -126,7 +126,7 @@ export class YkInfopop extends LitElement {
 		const root = this.getRootNode();
 		this.#root = root;
 		// Triggers, scoped to the tree this popup serves.  The hover carrier is
-		// tracked from pointermove, NOT pointerover: boundary events are suppressed
+		// tracked from pointermove, not pointerover: boundary events are suppressed
 		// at this root whenever a move stays inside one descendant shadow root
 		// (target and relatedTarget both retarget to the same host, so the pair is
 		// never dispatched here) -- a row-to-aux move inside a component would be
@@ -177,7 +177,7 @@ export class YkInfopop extends LitElement {
 	#onPointerout = (e: Event): void => {
 		// Movement within the served tree is fully handled by pointermove.  The
 		// cases only pointerout can see: the pointer leaving the window entirely
-		// (relatedTarget null), and the pointer leaving for an element OUTSIDE
+		// (relatedTarget null), and the pointer leaving for an element outside
 		// the tree this popup serves -- no pointermove will reach us from there.
 		const to = (e as PointerEvent).relatedTarget;
 		if (to === null || !this.#inServedTree(to)) this.#trackCarrier(null);
@@ -209,7 +209,7 @@ export class YkInfopop extends LitElement {
 		if (carrier !== null && !(this.#mode === "hover" && carrier === this.#anchor)) {
 			this.#timer = window.setTimeout(() => {
 				this.#timer = undefined;
-				// A pinned popup outranks hover: skip, and do NOT linger a re-try --
+				// A pinned popup outranks hover: skip, and do not linger a re-try --
 				// after the pinned one closes, a popup should only appear on a fresh
 				// pointer or key action, never spontaneously.
 				if (this.#mode === "pinned" || carrier !== this.#candidate) return;
@@ -221,7 +221,7 @@ export class YkInfopop extends LitElement {
 	#onKeydown = (e: KeyboardEvent): void => {
 		// Bare modifiers close nothing (Shift held for a capital must not blink the
 		// popup away); every other key closes.  Almost never consumed or stopped --
-		// the megacolumn (and everything else) hears the key untouched -- with ONE
+		// the megacolumn (and everything else) hears the key untouched -- with one
 		// exception: an Escape that closes the popup is consumed.  Escape unwinds
 		// layers one at a time (the guidelines' focus-lifecycle norm), and the popup
 		// is the innermost layer: the same press must not also close a panel below.
diff --git a/packages/yukey/src/yk-live-list.ts b/packages/yukey/src/yk-live-list.ts
index 7fddad2..cfe5c0d 100644
--- a/packages/yukey/src/yk-live-list.ts
+++ b/packages/yukey/src/yk-live-list.ts
@@ -63,7 +63,7 @@ const lifecycleStyles = css`
 		transition: grid-template-rows var(--yk-live-list-collapse, 300ms) ease;
 		/* The rowslot is pure geometry machinery and must be free to reach 0 height
 		   (closed rows, and both ends of the grow/collapse animations).  Owners set
-		   hit-target floors on their row CONTENT; in mega mode a [data-mc-row]
+		   hit-target floors on their row content; in mega mode a [data-mc-row]
 		   min-height rule would land on this element and clamp the animations open
 		   (entrances pop, collapses snap, pending rows hold blank space). */
 		min-height: 0;
@@ -381,7 +381,7 @@ export class YkLiveList<T = unknown> extends LitElement {
 		// which keeps hover coverage.
 		this.addEventListener("pointerenter", this.onPointerEnter);
 		this.addEventListener("pointerleave", this.onPointerLeave);
-		// The click guard intercepts in the CAPTURE phase on the host: it must beat
+		// The click guard intercepts in the capture phase on the host: it must beat
 		// both the row content's own listeners (a yk-button acting on a stale click)
 		// and, in mega mode, the megacolumn controller's bubble-phase mousedown
 		// focus-sync on the ancestor container -- stopping propagation here covers
@@ -464,7 +464,7 @@ export class YkLiveList<T = unknown> extends LitElement {
 		}
 		// Mega mode: any completed render may have changed the row set under the
 		// megacolumn scan -- phase timers re-render outside host renders entirely, and
-		// even host-driven data changes land here AFTER the owner's own hostUpdated
+		// even host-driven data changes land here after the owner's own hostUpdated
 		// scan ran (this element updates asynchronously, later in the same task).
 		// Announce every time; re-scans are idempotent and O(rows).
 		if (this.mega) this.dispatchEvent(new CustomEvent("megacolumn-rescan", { bubbles: true }));
@@ -598,7 +598,7 @@ export class YkLiveList<T = unknown> extends LitElement {
 			(this.megaContainer ?? this.itemsEl)?.focus();
 		}
 		// The row's guard entries outlive it (the guard tail); re-anchor them to the
-		// display neighbor above, which is the topmost row that did NOT move.  Entries
+		// display neighbor above, which is the topmost row that did not move.  Entries
 		// already anchored on this row re-anchor the same way (a cascade of collapses).
 		const keys = [...this.rows.keys()];
 		const idx = keys.indexOf(row.key);
@@ -756,7 +756,7 @@ export class YkLiveList<T = unknown> extends LitElement {
 			this.keyPinned = false;
 			this.releaseDeferred();
 		}, this.keyPinMs);
-		// Focus may have moved OFF a deferred ghost since it was deferred; sweep so a
+		// Focus may have moved off a deferred ghost since it was deferred; sweep so a
 		// stale deferral dies with the aim rather than riding out continuous typing.
 		// (This listener may run before the controller's on the same keydown, so a
 		// focus-moving key can be one keydown late here -- and the decay backstops it.)