Abstract Class: TableRowDriverBase<ItemT>
Defined in: packages/component-driver-fluent-v9/src/components/TableRowDriverBase.ts:20
Shared cell-iteration surface for the Fluent v9 plain-Table row family β
TableRowDriver (body rows, TableCell children) and
TableHeaderRowDriver (the header row, TableHeaderCell children).
Both row kinds are a homogeneous, same-tag ListComponentDriver over their
respective cell type (<td class="fui-TableCell"> siblings under a body
row, <th class="fui-TableHeaderCell"> siblings under the header row β
DOM audit, @fluentui/react-table@9.19.17: a row never mixes the two cell
kinds as siblings, so ListComponentDriver's :nth-of-type addressing is
safe for both, unlike the DataGrid row family below, which has to reckon
with a conditionally-rendered selection cell β see
DataGridRowDriverBase). Each subclass fixes its own item
class/locator via its own constructor (mirroring TableRowDriver's MUI
counterpart); this base only supplies the three read methods every row
needs regardless of cell kind.
Extendsβ
ListComponentDriver<ItemT>
Extended byβ
Type Parametersβ
ItemTβ
ItemT extends ComponentDriver
Constructorsβ
Constructorβ
new TableRowDriverBase<
ItemT>(locator,interactor,option):TableRowDriverBase<ItemT>
Defined in: packages/core/dist/index.d.mts:1124
Parametersβ
locatorβ
PartLocator
interactorβ
Interactor
optionβ
ListComponentDriverSpecificOption<ItemT>
Returnsβ
TableRowDriverBase<ItemT>
Inherited fromβ
ListComponentDriver<ItemT>.constructor
Methodsβ
getCell()β
getCell(
index):Promise<Optional<ItemT>>
Defined in: packages/component-driver-fluent-v9/src/components/TableRowDriverBase.ts:27
The cell driver at the given zero-based column index, or undefined when out of range.
Parametersβ
indexβ
number
Returnsβ
Promise<Optional<ItemT>>
getCellCount()β
getCellCount():
Promise<number>
Defined in: packages/component-driver-fluent-v9/src/components/TableRowDriverBase.ts:22
The number of cells in the row.
Returnsβ
Promise<number>
getCellTexts()β
getCellTexts():
Promise<string[]>
Defined in: packages/component-driver-fluent-v9/src/components/TableRowDriverBase.ts:32
The text of every cell, in column order.
Returnsβ
Promise<string[]>
Inherited members (26)
Propertiesβ
commutableOptionβ
readonlycommutableOption:CommutableComponentDriverOption
Defined in: packages/core/dist/index.d.mts:1356
The component-agnostic slice of the constructor option that is safe to share
across the whole driver tree β everything the constructor received EXCEPT the
component-specific parts, which each driver owns for itself. Parent drivers
pass this straight to the constructors of children they create dynamically
(see the list helpers). See CommutableComponentDriverOption.
Inherited fromβ
ListComponentDriver.commutableOption
interactorβ
readonlyinteractor:Interactor
Defined in: packages/core/dist/index.d.mts:1346
Inherited fromβ
ListComponentDriver.interactor
Accessorsβ
driverNameβ
Get Signatureβ
get driverName():
string
Defined in: packages/core/dist/index.d.mts:1173
Returnsβ
string
Inherited fromβ
ListComponentDriver.driverName
locatorβ
Get Signatureβ
get locator():
PartLocator
Defined in: packages/core/dist/index.d.mts:1414
Return the locator of the component
Returnsβ
PartLocator
Inherited fromβ
ListComponentDriver.locator
partsβ
Get Signatureβ
get parts():
ScenePartDriver<T>
Defined in: packages/core/dist/index.d.mts:1410
Return driver instance of all the named parts
Returnsβ
ScenePartDriver<T>
Inherited fromβ
ListComponentDriver.parts
Methodsβ
click()β
click(
option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1492
Parametersβ
option?β
Partial<ClickOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.click
exists()β
exists():
Promise<boolean>
Defined in: packages/core/dist/index.d.mts:1491
Whether the component exists/attached to the DOM
Returnsβ
Promise<boolean>
true if the component is attached to the DOM, false otherwise
Inherited fromβ
ListComponentDriver.exists
focus()β
focus(
option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1501
Parametersβ
option?β
Partial<FocusOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.focus
getAttribute()β
getAttribute(
attributeName):Promise<Optional<string>>
Defined in: packages/core/dist/index.d.mts:1486
Parametersβ
attributeNameβ
string
Returnsβ
Promise<Optional<string>>
Inherited fromβ
ListComponentDriver.getAttribute
getItemByIndex()β
getItemByIndex<
ItemClass>(index,itemDriverClass?):Promise<Optional<ItemClass>>
Defined in: packages/core/dist/index.d.mts:1135
Get the item's driver instance at the given index
Type Parametersβ
ItemClassβ
ItemClass extends ComponentDriver<{ }> = ItemT
Parametersβ
indexβ
number
itemDriverClass?β
ComponentDriverCtor<ItemClass>
Returnsβ
Promise<Optional<ItemClass>>
The item's driver instance at the given index, or undefined when the
index is out of range. Absence is undefined (never null) across every core
read β see ADR-006 Β§7.
Inherited fromβ
ListComponentDriver.getItemByIndex
getItemByLabel()β
getItemByLabel<
ItemClass>(text,itemDriverClass?):Promise<Optional<ItemClass>>
Defined in: packages/core/dist/index.d.mts:1148
Get the item's driver instance by the given text
Type Parametersβ
ItemClassβ
ItemClass extends ComponentDriver<{ }> = ItemT
Parametersβ
textβ
string
itemDriverClass?β
ComponentDriverCtor<ItemClass>
Returnsβ
Promise<Optional<ItemClass>>
The item's driver instance with the given text, or undefined when no
item matches. Absence is undefined (never null) across every core read β see
ADR-006 Β§7.
Throwsβ
ListEnumerationMismatchError when it searched the whole list without a match but the list is not the homogeneous sibling set positional addressing requires β in that case "no item matches" cannot be distinguished from "enumeration stopped before reaching it", so it is not reported as absence.
Inherited fromβ
ListComponentDriver.getItemByLabel
getItemCount()β
getItemCount():
Promise<number>
Defined in: packages/core/dist/index.d.mts:1172
Get the number of items in the list, in a single interactor round-trip and
without instantiating an item driver β so prefer it to getItems().length when
only the count is wanted.
It is not merely a cheaper getItems().length, though: this counts the elements
the item locator matches, while getItems walks :nth-of-type
positions. The two agree exactly for the homogeneous sibling set this driver
requires, and a list that breaks that requirement makes getItems throw
ListEnumerationMismatchError rather than let the two answers diverge in
silence.
Returnsβ
Promise<number>
The number of elements the item locator matches
Inherited fromβ
ListComponentDriver.getItemCount
getItems()β
getItems<
ItemClass>(itemDriverClass?):Promise<ItemClass[]>
Defined in: packages/core/dist/index.d.mts:1157
Get all the items' driver instances in the list, in DOM order.
Type Parametersβ
ItemClassβ
ItemClass extends ComponentDriver<{ }> = ItemT
Parametersβ
itemDriverClass?β
ComponentDriverCtor<ItemClass>
Returnsβ
Promise<ItemClass[]>
Every item in the list β never a partial set: see the @throws below.
Throwsβ
ListEnumerationMismatchError when the list is not the homogeneous sibling set positional addressing requires, so enumeration would otherwise have returned a silently short array.
Inherited fromβ
ListComponentDriver.getItems
getText()β
getText():
Promise<Optional<string>>
Defined in: packages/core/dist/index.d.mts:1485
Get the combined text content of the component
Returnsβ
Promise<Optional<string>>
If the component exists and has content, it should return the text or otherwise undefined
Inherited fromβ
ListComponentDriver.getText
hover()β
hover(
option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1493
Parametersβ
option?β
Partial<HoverOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.hover
isVisible()β
isVisible():
Promise<boolean>
Defined in: packages/core/dist/index.d.mts:1576
Whether the component is visible. Visibility is defined
that the component does not have the CSS property display: none,
visibility: hidden, or opacity: 0. However this does not
check whether the component is within the viewport.
Returnsβ
Promise<boolean>
true if the component is visible, false otherwise
Inherited fromβ
ListComponentDriver.isVisible
pressKey()β
pressKey(
key,option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1508
Dispatch a keyboard key press on the component. See Interactor.pressKey for the full contract, including modifier-key delivery via PressKeyOption.
Parametersβ
keyβ
string
A KeyboardEvent.key value, e.g. 'Escape', 'Backspace', 'Enter'
option?β
Partial<PressKeyOption>
Modifier flags and other per-press options β see PressKeyOption
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.pressKey
runtimeCssSelector()β
runtimeCssSelector():
Promise<string>
Defined in: packages/core/dist/index.d.mts:1641
Get the runtime CSS selector of the component. This is useful for debugging and testing purposes.
Returnsβ
Promise<string>
The runtime CSS selector of the component
Inherited fromβ
ListComponentDriver.runtimeCssSelector
scrollIntoView()β
scrollIntoView():
Promise<void>
Defined in: packages/core/dist/index.d.mts:1529
Scroll the component into the viewport. See Interactor.scrollIntoView.
jsdom has no layout engine, so the scroll is a no-op there and behavioral assertions (visibility, offset) are E2E-only.
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.scrollIntoView
typeText()β
typeText(
text):Promise<void>
Defined in: packages/core/dist/index.d.mts:1514
Type text into the component as real per-character keystrokes, inserting at the current caret without clearing. See Interactor.typeText.
Parametersβ
textβ
string
The literal text to type, one keystroke per character
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.typeText
waitUntil()β
waitUntil<
T>(option):Promise<T>
Defined in: packages/core/dist/index.d.mts:1596
Type Parametersβ
Tβ
T
Parametersβ
optionβ
WaitUntilOption<T>
Returnsβ
Promise<T>
Inherited fromβ
ListComponentDriver.waitUntil
waitUntilComponentState()β
waitUntilComponentState(
option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1595
Wait until the component is in the expected state such as the component's visibility or existence. If the component has not reached the expected state within the timeout, it will throw an error.
By default it waits until the component is attached to the DOM within 30 seconds.
Parametersβ
option?β
Partial<Readonly<WaitForOption>>
The option to configure the wait behavior
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.waitUntilComponentState
waitUntilVisible()β
waitUntilVisible(
timeoutMs?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1583
Wait until the component is attached and becomes visible to the DOM.
Parametersβ
timeoutMs?β
number
The number of milliseconds to wait before timing out. Defaults to defaultWaitForOption.timeoutMs so this wait shares a single flake-tolerance source with waitUntilComponentState (#1057).
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.waitUntilVisible
within()β
within<
ContentT>(parts):ScenePartDriver<ContentT>
Defined in: packages/core/dist/index.d.mts:1468
Driver instances for a caller-supplied interior scene, resolved against this component's ComponentDriver.interiorLocator.
The call-time counterpart to ComponentDriver.parts: parts is the
chrome the driver author hardcodes, this is the interior the scene author
owns β a dialog's body, a popover's panel, a toast's action area. A
PartLocator resolves lazily and queries nothing here, so this is
synchronous and safe to call before the interior has mounted.
This replaced an earlier ContainerDriver base whose content option
required the same scene to be named twice β once as a type argument, once in
the driver option β plus a laundering constructor in every subclass (ADR-019).
Named within rather than getContent because leaf drivers already own that
name for reading a component's own text (a badge's content, a tooltip's
content), and a base-class member cannot collide with them.
Interior children are constructed with an empty option, exactly as content
parts always have been: an interior belongs to the scene, so it inherits no
driver-specific configuration from its host. This differs deliberately from
ComponentDriver.parts, whose children do inherit the host's option.
Type Parametersβ
ContentTβ
ContentT extends ScenePart
Parametersβ
partsβ
ContentT
The interior scene to resolve against this component's interior
Returnsβ
ScenePartDriver<ContentT>
One driver instance per named part
Inherited fromβ
ListComponentDriver.within
overriddenParentLocator()β
staticoverriddenParentLocator(_option?):Optional<PartLocator>
Defined in: packages/core/dist/index.d.mts:1393
Portal hook: where to re-root this driver's locator when its component renders
outside the parent's DOM (a modal, popup, drawer). Return the PartLocator
that locates the component from the document root, or undefined (the default)
for normal in-tree components whose locator chains from the parent.
This is static because it is per-class metadata read off the constructor
before any instance exists β which makes the "no instance state" constraint
structural rather than a documented caution. Override with static override.
option is the fully-merged constructor option the driver is about to receive
(the same value passed to the driver's own constructor) β a purely static,
per-invocation input, not instance state β so a driver whose portalling is
conditional on how its scene configures it (e.g. an overlay that can render
teleported OR in-tree, such as PrimeVue's appendTo="self") can branch on a
flag there instead of always re-rooting. Ignore it to keep unconditional
portal behavior.
Parametersβ
_option?β
Partial<IComponentDriverOption<any>>
Returnsβ
Optional<PartLocator>
Inherited fromβ
ListComponentDriver.overriddenParentLocator
overrideLocatorRelativePosition()β
staticoverrideLocatorRelativePosition(_option?):Optional<LocatorRelativePosition>
Defined in: packages/core/dist/index.d.mts:1406
Portal hook: the locator relative position to apply when the component's real
DOM is a sibling/elsewhere rather than a descendant (e.g. a MUI dialog rendered
at the document root, located by a "Same"-level selector). Return undefined
(the default) to keep the natural position declared by the ScenePart.
Static for the same reason as ComponentDriver.overriddenParentLocator:
it is class-level metadata read before construction. Override with static override.
See ComponentDriver.overriddenParentLocator for what option carries
and why accepting it does not reintroduce instance state.
Parametersβ
_option?β
Partial<IComponentDriverOption<any>>
Returnsβ
Optional<LocatorRelativePosition>
Inherited fromβ
ListComponentDriver.overrideLocatorRelativePosition
Protected members (20)
Accessorsβ
interiorLocatorβ
Get Signatureβ
get
protectedinteriorLocator():PartLocator
Defined in: packages/core/dist/index.d.mts:1442
The element ComponentDriver.within resolves an interior scene against β
"inside this component", as this driver defines inside. Defaults to
ComponentDriver.locator, which is already correct wherever a driver's own
locator resolves to the surface holding caller content (Radix/Reka anchor at
Dialog.Content, Fluent at DialogSurface).
Override it when the driver's locator resolves to a wrapper instead. MUI's
Dialog, Drawer and Menu are the shipped cases: their locator is the portal-rendered
Modal root, whose children are the backdrop, two focus-trap sentinels and a
positioning container. Un-narrowed, an interior there reaches MUI's own chrome,
and a 'Child'-relative interior part resolves to .MuiBackdrop-root rather
than to anything the scene wrote β silently, since a locator that matches the
wrong element raises nothing.
An override only helps where that chrome is ancestral to the caller's content. Where a design system interleaves chrome beside it β Fluent's focus-trap sentinels are siblings of the dialog body β no anchor separates the two, and the default stands (ADR-019's rollout-width audit).
An override MUST resolve to an element containing everything the caller
supplied. For a slotted component that means the surface, never one slot: MUI
spreads caller content across DialogTitle/DialogContent/DialogActions as
siblings, so narrowing to .MuiDialogContent-root would drop the action buttons
scenes click. Over-narrowing fails the same silent way it fixes β the part just
stops resolving (ADR-019).
Returnsβ
PartLocator
Inherited fromβ
ListComponentDriver.interiorLocator
Methodsβ
activate()β
protectedactivate():Promise<void>
Defined in: packages/core/dist/index.d.mts:1522
Activate the component without relying on pointer geometry. See Interactor.activate.
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.activate
awaitPostcondition()β
protectedawaitPostcondition(postcondition,probeFn,option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1628
Hold an action open until its own postcondition holds, so the action does not resolve while the DOM it promised is still arriving.
Why actions, not reads or assertions. An interactor settles the
framework's scheduler after a write (React act(), Vue nextTick(),
Angular whenStable()) and then treats the DOM as final. A component that
defers its own DOM work onto a host timer β a setTimeout to re-register a
select's options, to restore a picker's section spans β lands after that
settle, so the next single-shot read observes a transient state that is
neither the old value nor the new one. Making reads retry cannot fix this
(a read does not know what it is waiting for, and negative reads must stay
fast); making every mutation drain a fixed extra macrotask is a sleep at
framework scale. The action is the only layer that knows what it promised,
so the action is where the wait belongs.
Probing uses waitUntil's escalating intervals, so a postcondition that already holds costs one probe and no delay.
Parametersβ
postconditionβ
string
Human-readable description of the awaited state, used verbatim in PostconditionNotMetError. Phrase it as the state that must arrive, not the action taken.
probeFnβ
() => boolean | Promise<boolean>
Returns true once the postcondition holds. Keep it cheap β it runs repeatedly.
option?β
timeoutMs?β
number
Defaults to defaultWaitForOption.timeoutMs so every wait in the library shares one flake-tolerance source (#1057).
Returnsβ
Promise<void>
Throwsβ
If the postcondition never holds. Failing here is deliberate: an action that cannot keep its promise is a real defect, and reporting it at the action gives a far better diagnostic than the downstream assertion mismatch it would otherwise become.
Inherited fromβ
ListComponentDriver.awaitPostcondition
contextMenu()β
protectedcontextMenu():Promise<void>
Defined in: packages/core/dist/index.d.mts:1518
Dispatch a right-click / contextmenu event on the component. See Interactor.contextMenu.
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.contextMenu
drag()β
protecteddrag(delta):Promise<void>
Defined in: packages/core/dist/index.d.mts:1560
Drag this component by the given pixel delta from its center. See Interactor.drag.
Prefer a keyboard-driven setValue over a true drag in real drivers β these
drag primitives exist only for cases keyboard cannot express (e.g. panning a
Lightbox, reordering a column). jsdom has no layout engine, so the positional
outcome of the drag is E2E-only there.
Parametersβ
deltaβ
Point
Pixel offset to drag by
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.drag
dragTo()β
protecteddragTo(target):Promise<void>
Defined in: packages/core/dist/index.d.mts:1549
Drag this component and drop it onto another component. See Interactor.dragTo.
Prefer a keyboard-driven setValue over a true drag in real drivers β these
drag primitives exist only for cases keyboard cannot express (e.g. panning a
Lightbox, reordering a column). jsdom has no layout engine, so the positional
outcome of the drag is E2E-only there.
Parametersβ
targetβ
ComponentDriver<any>
Another driver whose root element is the drop target
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.dragTo
enforcePartExistence()β
protectedenforcePartExistence(partName):Promise<void>
Defined in: packages/core/dist/index.d.mts:1474
Check the specified parts' existences, and throw MissingPartError if any of the part is found not existence. Existence is defined by the part's existence in the DOM regardless of its visibility on the screen
Parametersβ
partNameβ
readonly never[]
Single or array of the names of the parts to be enforced
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.enforcePartExistence
getBoundingRect()β
protectedgetBoundingRect():Promise<BoundingRect>
Defined in: packages/core/dist/index.d.mts:1567
Get this component's bounding rectangle. See Interactor.getBoundingRect.
jsdom has no layout engine, so every coordinate and dimension is 0 there;
real geometry is E2E-only.
Returnsβ
Promise<BoundingRect>
Inherited fromβ
ListComponentDriver.getBoundingRect
getItemClass()β
protectedgetItemClass<ItemClass>(itemDriverClass?):ComponentDriverCtor<ItemClass>
Defined in: packages/core/dist/index.d.mts:1126
Type Parametersβ
ItemClassβ
ItemClass extends ComponentDriver<{ }> = ItemT
Parametersβ
itemDriverClass?β
ComponentDriverCtor<ItemClass>
Returnsβ
ComponentDriverCtor<ItemClass>
Inherited fromβ
ListComponentDriver.getItemClass
getItemLocator()β
protectedgetItemLocator():PartLocator
Defined in: packages/core/dist/index.d.mts:1125
Returnsβ
PartLocator
Inherited fromβ
ListComponentDriver.getItemLocator
getMissingPartNames()β
protectedgetMissingPartNames(partName):Promise<readonlynever[]>
Defined in: packages/core/dist/index.d.mts:1480
Get the names of parts not in the DOM
Parametersβ
partNameβ
readonly never[]
Single or array of the names of the parts to be examined
Returnsβ
Promise<readonly never[]>
Inherited fromβ
ListComponentDriver.getMissingPartNames
innerHTML()β
protectedinnerHTML():Promise<string>
Defined in: packages/core/dist/index.d.mts:1635
Get the inner HTML of the component
Returnsβ
Promise<string>
The inner HTML of the component
Inherited fromβ
ListComponentDriver.innerHTML
mouseDown()β
protectedmouseDown(option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1495
Parametersβ
option?β
Partial<MouseDownOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.mouseDown
mouseEnter()β
protectedmouseEnter(option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1499
Parametersβ
option?β
Partial<MouseEnterOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.mouseEnter
mouseLeave()β
protectedmouseLeave(option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1500
Parametersβ
option?β
Partial<MouseLeaveOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.mouseLeave
mouseMove()β
protectedmouseMove(option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1494
Parametersβ
option?β
Partial<MouseMoveOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.mouseMove
mouseOut()β
protectedmouseOut(option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1498
Parametersβ
option?β
Partial<MouseOutOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.mouseOut
mouseOver()β
protectedmouseOver(option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1497
Parametersβ
option?β
Partial<HoverOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.mouseOver
mouseUp()β
protectedmouseUp(option?):Promise<void>
Defined in: packages/core/dist/index.d.mts:1496
Parametersβ
option?β
Partial<MouseUpOption>
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.mouseUp
scrollBy()β
protectedscrollBy(delta):Promise<void>
Defined in: packages/core/dist/index.d.mts:1538
Scroll the component by the given pixel delta. See Interactor.scrollBy.
jsdom has no layout engine, so the scroll is a no-op there and behavioral assertions (resulting offset) are E2E-only.
Parametersβ
deltaβ
Point
Pixel offset to scroll by
Returnsβ
Promise<void>
Inherited fromβ
ListComponentDriver.scrollBy