UNPKG

@fleetbase/ember-ui

Version:

Fleetbase UI provides all the interface components, helpers, services and utilities for building a Fleetbase extension into the Console.

24 lines (18 loc) 608 B
import Component from '@glimmer/component'; import { tracked } from '@glimmer/tracking'; import { action } from '@ember/object'; export default class TableCellComponent extends Component { @tracked tableCellNode; @action setupComponent(tableCellNode) { this.tableCellNode = tableCellNode; } @action getOwnerTable(tableCellNode) { while (tableCellNode) { tableCellNode = tableCellNode.parentNode; if (tableCellNode.tagName.toLowerCase() === 'table') { return tableCellNode; } } return undefined; } }