Sha256: 25e9d7368418cb2e673a6e3e68eec2a149f84159d6edb356791502f71c4dcea7
Contents?: true
Size: 721 Bytes
Versions: 104
Compression:
Stored size: 721 Bytes
Contents
/* global table, dom */ /** * Get the x, y coordinates of a table cell; normalized for rowspan and colspan * @method getCellPosition * @memberof axe.commons.table * @instance * @param {HTMLTableCellElement} cell The table cell of which to get the position * @return {Object} Object with `x` and `y` properties of the coordinates */ table.getCellPosition = function(cell, tableGrid) { var rowIndex, index; if (!tableGrid) { tableGrid = table.toGrid(dom.findUp(cell, 'table')); } for (rowIndex = 0; rowIndex < tableGrid.length; rowIndex++) { if (tableGrid[rowIndex]) { index = tableGrid[rowIndex].indexOf(cell); if (index !== -1) { return { x: index, y: rowIndex }; } } } };
Version data entries
104 entries across 104 versions & 1 rubygems