A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/vuematerial/vue-material/commit/b54eb10 below:

remove table head when column removed (#1354) · vuematerial/vue-material@b54eb10 · GitHub

File tree Expand file treeCollapse file tree 1 file changed

+15

-2

lines changed

Filter options

Expand file treeCollapse file tree 1 file changed

+15

-2

lines changed Original file line number Diff line number Diff line change

@@ -17,7 +17,8 @@

17 17

},

18 18

inject: ['MdTable'],

19 19

data: () => ({

20 -

index: null

20 +

index: null,

21 +

parentNode: null

21 22

}),

22 23

computed: {

23 24

cellClasses () {

@@ -50,7 +51,9 @@

50 51

})

51 52

},

52 53

updateAllCellData () {

53 -

const cells = Array.from(this.$el.parentNode.childNodes).filter(({ tagName, classList }) => {

54 +

this.MdTable.items = {}

55 + 56 +

const cells = Array.from(this.parentNode.childNodes).filter(({ tagName, classList }) => {

54 57

const isSelection = classList && classList.contains('md-table-cell-selection')

55 58

const isTd = tagName && tagName.toLowerCase() === 'td'

56 59

@@ -67,6 +70,16 @@

67 70

}

68 71

},

69 72

mounted () {

73 +

this.parentNode = this.$el.parentNode

74 +

this.updateAllCellData()

75 +

},

76 +

destroyed () {

77 +

const rowRemoved = this.$el.parentNode !== null

78 + 79 +

if (rowRemoved) {

80 +

return false

81 +

}

82 + 70 83

this.updateAllCellData()

71 84

}

72 85

}

You can’t perform that action at this time.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4