mirror of https://github.com/artf/grapesjs.git
1 changed files with 6 additions and 3 deletions
@ -1,17 +1,20 @@ |
|||||
import Component from './Component'; |
import Component from './Component'; |
||||
import { toLowerCase } from 'utils/mixins'; |
import { toLowerCase } from '../../utils/mixins'; |
||||
|
|
||||
const tagName = 'tr'; |
const tagName = 'tr'; |
||||
|
|
||||
export default class ComponentTableRow extends Component { |
export default class ComponentTableRow extends Component { |
||||
get defaults() { |
get defaults() { |
||||
return { |
return { |
||||
|
// @ts-ignore
|
||||
...super.defaults, |
...super.defaults, |
||||
tagName, |
tagName, |
||||
draggable: ['thead', 'tbody', 'tfoot'], |
draggable: ['thead', 'tbody', 'tfoot'], |
||||
droppable: ['th', 'td'], |
droppable: ['th', 'td'], |
||||
}; |
}; |
||||
} |
} |
||||
} |
|
||||
|
|
||||
ComponentTableRow.isComponent = el => toLowerCase(el.tagName) === tagName; |
static isComponent(el: HTMLElement) { |
||||
|
return toLowerCase(el.tagName) === tagName; |
||||
|
} |
||||
|
} |
||||
Loading…
Reference in new issue