SShortSingh.
Back to feed

HTML's New switch Attribute Gives Checkboxes a Native Toggle Look and Screen Reader Role

0
·2 views

The article argues that many web toggle switches are built from several elements and CSS hacks, yet are often exposed to assistive technology as plain checkboxes. Screen readers therefore announce them as "checked" or "not checked" rather than "on" or "off," a mismatch that usually goes unnoticed because the controls still function visually. Developers have long fixed this with the role="switch" ARIA attribute, which changes the announced vocabulary without changing behavior. Safari 17.4 introduced a native switch attribute on checkbox inputs that applies the switch role and renders a platform-style toggle, while other browsers ignore it and fall back to a normal checkbox. The attribute is meant only for binary toggles, not for states like indeterminate "select all" checkboxes.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Why a Cited Source Isn't Proof: Classifying Provenance in Generative-Search Citations

A named, reputable domain attached to an answer does not by itself show the model consulted a primary record. The same claim often spreads from an original lab note through newswire rewrites to many blogs that repeat quotes without methods, making syndicated copies look like independent confirmation. The article proposes a desk method for sorting each cited URL into a provenance class, such as primary record, first-party explanation, arm's-length field note, or syndicated release, during a fixed sampling window. It stresses recording query, tool, timing, and access conditions before sending requests, and keeping blank or missing citations as recorded outcomes. The method is meant only to label sources for later review, not to rank engines or vendors.

0
ProgrammingDEV Community ·

What an agentic harness is and why regulated industries need one

An agentic harness is the set of controls surrounding an AI model that makes it usable in regulated operations such as banking, insurance and lending. It encodes the organisation's own process as explicit steps, checks and approvals, rather than relying on the model's raw capability. Each new agent version is tested against real sample files, including difficult edge cases, before it replaces the previous one. Extracted values are linked to their exact source location so reviewers can verify them quickly, and a named human makes every final decision. Every run is logged so that auditors and regulators can later see what was done, by which version, and who approved it.

0
ProgrammingDEV Community ·

Shopify Subscription Renewals Often Fail in the App Stack, Not the Storefront

A Shopify subscription store can look healthy on its storefront while renewals quietly fail between the subscription app, payment gateway, and email tool. The author recommends auditing ten recent failed renewals by hand to check whether failures were recorded promptly, whether retries were well timed, and whether subscribers received actionable messages. The audit also urges separating genuine dunning recoveries from self-cures and returning subscribers who are wrongly counted as saved renewals. Finally, it advises reviewing the cancellation path alongside the billing path on mobile, since both are often encountered in the same week. The article notes that the fixes it describes were small and did not require rebuilding the store.

0
ProgrammingDEV Community ·

CROON app dubs foreign videos live on iPhone and adds AI Q&A and summaries

A developer has released CROON, an iPhone and iPad app for iOS 26 and later that provides real-time voice dubbing of foreign-language videos and lectures. Unlike subtitle-only translators, it assigns voices close to each speaker and keeps the video playing in a compact bilingual bar. Users can ask questions by voice or text, generate incremental summaries, and hand the running transcript to ChatGPT, Claude, or Grok with one tap. The developer, who disclosed being the app's creator, compared its performance against several live translation models across four public YouTube videos. The article presents these claims as the developer's own measurements.