Repository Analysis

tailwindlabs/headlessui

Completely unstyled, fully accessible UI components, designed to integrate beautifully with Tailwind CSS.

0.7 Likely human-written View on GitHub
0.7
Adjusted Score
0.7
Raw Score
100%
Time Factor
2026-04-13
Last Push
28,590
Stars
TypeScript
Language
120,431
Lines of Code
446
Files
80
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 0MEDIUM 0LOW 80

Pattern Findings

80 matches across 4 categories. Click a row to expand file-level details.

Hyper-Verbose Identifiers43 hits · 43 pts
SeverityFileLineSnippet
LOW…essui-react/src/test-utils/accessibility-assertions.ts154export function assertLinkedWithDescription(
LOW…essui-react/src/test-utils/accessibility-assertions.ts259export function assertMenuButtonLinkedWithMenu(button = getMenuButton(), menu = getMenu()) {
LOW…essui-react/src/test-utils/accessibility-assertions.ts273export function assertMenuLinkedWithMenuItem(item: HTMLElement | null, menu = getMenu()) {
LOW…essui-react/src/test-utils/accessibility-assertions.ts671export function assertComboboxButtonLinkedWithCombobox(
LOW…essui-react/src/test-utils/accessibility-assertions.ts688export function assertComboboxLabelLinkedWithCombobox(
LOW…essui-react/src/test-utils/accessibility-assertions.ts703export function assertComboboxButtonLinkedWithComboboxLabel(
LOW…essui-react/src/test-utils/accessibility-assertions.ts720export function assertActiveComboboxOption(
LOW…essui-react/src/test-utils/accessibility-assertions.ts736export function assertNotActiveComboboxOption(
LOW…essui-react/src/test-utils/accessibility-assertions.ts752export function assertNoActiveComboboxOption(combobox = getComboboxInput()) {
LOW…essui-react/src/test-utils/accessibility-assertions.ts764export function assertNoSelectedComboboxOption(items = getComboboxOptions()) {
LOW…essui-react/src/test-utils/accessibility-assertions.ts1003export function assertListboxButtonLinkedWithListbox(
LOW…essui-react/src/test-utils/accessibility-assertions.ts1020export function assertListboxLabelLinkedWithListbox(
LOW…essui-react/src/test-utils/accessibility-assertions.ts1035export function assertListboxButtonLinkedWithListboxLabel(
LOW…essui-react/src/test-utils/accessibility-assertions.ts1052export function assertActiveListboxOption(item: HTMLElement | null, listbox = getListbox()) {
LOW…essui-react/src/test-utils/accessibility-assertions.ts1065export function assertNoActiveListboxOption(listbox = getListbox()) {
LOW…essui-react/src/test-utils/accessibility-assertions.ts1077export function assertNoSelectedListboxOption(items = getListboxOptions()) {
LOW…essui-react/src/test-utils/accessibility-assertions.ts1828export function assertContainsActiveElement(element: HTMLElement | null) {
LOWpackages/@headlessui-react/src/internal/floating.tsx113export function useFloatingReferenceProps() {
LOWpackages/@headlessui-react/src/internal/floating.tsx548function resolveCSSVariablePxValue(input: string, element: HTMLElement) {
LOWpackages/@headlessui-react/src/utils/render.test.tsx334function testRenderStrategyFeature(Dummy: (props: any) => React.JSX.Element) {
LOW…dlessui-react/src/components/disclosure/disclosure.tsx155function useDisclosurePanelContext() {
LOW…kages/@headlessui-react/src/hooks/use-active-press.tsx9function pointerRectFromPointerEvent(event: PointerEvent): Rect {
LOW…t/src/hooks/document-overflow/use-document-overflow.ts5export function useDocumentOverflowLockedEffect(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts91export function assertMenuButtonLinkedWithMenu(button = getMenuButton(), menu = getMenu()) {
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts105export function assertMenuLinkedWithMenuItem(item: HTMLElement | null, menu = getMenu()) {
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts503export function assertComboboxButtonLinkedWithCombobox(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts520export function assertComboboxLabelLinkedWithCombobox(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts535export function assertComboboxButtonLinkedWithComboboxLabel(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts552export function assertActiveComboboxOption(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts568export function assertNotActiveComboboxOption(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts584export function assertNoActiveComboboxOption(combobox = getComboboxInput()) {
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts596export function assertNoSelectedComboboxOption(items = getComboboxOptions()) {
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts835export function assertListboxButtonLinkedWithListbox(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts852export function assertListboxLabelLinkedWithListbox(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts867export function assertListboxButtonLinkedWithListboxLabel(
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts884export function assertActiveListboxOption(item: HTMLElement | null, listbox = getListbox()) {
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts897export function assertNoActiveListboxOption(listbox = getListbox()) {
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts909export function assertNoSelectedListboxOption(items = getListboxOptions()) {
LOW…dlessui-vue/src/test-utils/accessibility-assertions.ts1719export function assertContainsActiveElement(element: HTMLElement | null) {
LOW…headlessui-vue/src/components/disclosure/disclosure.ts58function useDisclosurePanelContext() {
LOW…ages/@headlessui-vue/src/components/popover/popover.ts217 function isFocusWithinPopoverGroup() {
LOW…ages/@headlessui-vue/src/components/popover/popover.ts778 function isFocusWithinPopoverGroup() {
LOW…e/src/hooks/document-overflow/use-document-overflow.ts5export function useDocumentOverflowLockedEffect(
Over-Commented Block29 hits · 29 pts
SeverityFileLineSnippet
LOWplaygrounds/react/next-env.d.ts1/// <reference types="next" />
LOWpackages/@headlessui-react/src/internal/floating.tsx221 //
LOWpackages/@headlessui-react/src/internal/floating.tsx441 // this variable in the `margin` of an element. Then we can observe the `margin` of the
LOWpackages/@headlessui-react/src/internal/floating.tsx461 // })
LOWpackages/@headlessui-react/src/internal/floating.tsx541
LOWpackages/@headlessui-react/src/internal/floating.tsx561 // current element. Which means that if the passed in element has CSS that looks like:
LOWpackages/@headlessui-react/src/utils/dom.ts61
LOWpackages/@headlessui-react/src/utils/get-text-value.ts1import * as DOM from './dom'
LOWpackages/@headlessui-react/src/utils/render.ts241
LOW…s/@headlessui-react/src/components/listbox/listbox.tsx581 //
LOW…kages/@headlessui-react/src/components/label/label.tsx141 //
LOW…@headlessui-react/src/components/combobox/combobox.tsx581 } else {
LOW…@headlessui-react/src/components/combobox/combobox.tsx801 machine.actions.closeCombobox()
LOW…@headlessui-react/src/components/combobox/combobox.tsx861 let relatedTarget =
LOW…@headlessui-react/src/components/combobox/combobox.tsx881 // already in the middle of rendering. This will result in the following
LOW…@headlessui-react/src/components/combobox/combobox.tsx1301 // When clicking inside of the scrollbar, a `click` event will be triggered
LOW…@headlessui-react/src/components/combobox/combobox.tsx1501 // that the `left` mouse button was clicked.
LOW…s/@headlessui-react/src/components/popover/popover.tsx341 // `Popover.Panel` (aka nested popovers), then we need to make sure that the button is able to
LOWpackages/@headlessui-react/src/components/menu/menu.tsx421 // We keep track whether the button moved or not, we only check this when the
LOWpackages/@headlessui-react/src/hooks/use-transition.ts221 }
LOW…ckages/@headlessui-react/src/hooks/use-is-top-layer.ts61 // this case we assume that we will be the top-most item, so we return
LOW…ages/@headlessui-react/src/hooks/use-handle-toggle.tsx21 // event we have to check this property manually because this is also
LOWpackages/@headlessui-vue/src/utils/get-text-value.ts1let emojiRegex =
LOWpackages/@headlessui-vue/src/utils/focus-management.ts261 // By default if you <Tab> to a text input or a textarea, the browser will
LOW…es/@headlessui-vue/src/components/combobox/combobox.ts961 onMounted(() => {
LOW…es/@headlessui-vue/src/components/combobox/combobox.ts1481 // event, allowing us to cancel the event before focus is moved from the
LOW…es/@headlessui-vue/src/components/combobox/combobox.ts1501 // (button), then we re-focus the input).
LOW…-vue/src/hooks/document-overflow/handle-ios-locking.ts21
LOW…-vue/src/hooks/document-overflow/handle-ios-locking.ts101 }
Fake / Example Data6 hits · 6 pts
SeverityFileLineSnippet
LOW…ct/page-examples/dialog/dialog-built-in-transition.tsx51 Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar, nunc nec
LOW…ct/page-examples/dialog/dialog-built-in-transition.tsx51 Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar, nunc nec
LOW…t/page-examples/dialog/scrollable-page-with-dialog.tsx13 Lorem ipsum dolor sit amet consectetur adipisicing elit. Quisquam numquam beatae,
LOW…t/page-examples/dialog/scrollable-page-with-dialog.tsx13 Lorem ipsum dolor sit amet consectetur adipisicing elit. Quisquam numquam beatae,
LOW…t/page-examples/dialog/scrollable-page-with-dialog.tsx31 Lorem ipsum dolor sit amet consectetur adipisicing elit. Quisquam numquam beatae,
LOW…t/page-examples/dialog/scrollable-page-with-dialog.tsx31 Lorem ipsum dolor sit amet consectetur adipisicing elit. Quisquam numquam beatae,
Verbosity Indicators2 hits · 3 pts
SeverityFileLineSnippet
LOW…kages/@headlessui-react/src/hooks/use-outside-click.ts76 // If the click crossed a shadow boundary, we need to check if the
LOWpackages/@headlessui-vue/src/hooks/use-outside-click.ts70 // If the click crossed a shadow boundary, we need to check if the container