Commit b26dfb9e authored by christianrhansen's avatar christianrhansen

removed console.logs and commented out js

parent 1d52a57a
......@@ -472,76 +472,20 @@
observerCallback (entries) {
let target = entries[0]
let scrollLeft = this.$el.scrollLeft
// console.log(target)
// console.log('scrollLeft', scrollLeft)
// console.log('mobileTempCell distance left', this.mobileTempCell.x * this.gridDimensions.full.cell.width - 1)
// if (target.boundingClientRect.x < this.handlerNewCell.size.width) {
if (!target.isIntersecting) {
console.log('is NOT intersecting')
// console.log('outside')
// this.handlerNewCell.move.inViewport = false
// this.handlerNewCell.move.x = 20
this.dummyButton.visibility = true
/*
console.log('----------------')
console.log('scrollLeft', scrollLeft)
console.log('scrollLeft + window.innerWidth', scrollLeft + window.innerWidth)
console.log('this.mobileTempCell.x', this.mobileTempCell.x * (this.gridDimensions.full.cell.width - 1))
*/
if (scrollLeft < this.handlerNewCell.move.x) {
console.log('-->')
this.dummyButton.left = window.innerWidth - 40
}
if (scrollLeft > this.handlerNewCell.move.x) {
console.log('<--')
this.dummyButton.left = 0
}
/*
if (scrollLeft + window.innerWidth < this.mobileTempCell.x * this.gridDimensions.full.cell.width - 1) {
// console.log('--->')
this.dummyButton.left = window.innerWidth - 40
}
if (scrollLeft > this.mobileTempCell.x * this.gridDimensions.full.cell.width) {
// console.log('<---')
this.dummyButton.left = 0
}
*/
}
else {
console.log('is intersecting')
this.dummyButton.visibility = false
}
/*
else {
console.log('INSIDE')
// this.handlerNewCell.move.inViewport = true
// this.handlerNewCell.move.x = this.gridDimensions.full.cell.width * (this.mobileTempCell.x - 1) + 8 + 20
}
*/
/*
let entryX = entries[0].boundingClientRect.x
let _handlerNewCell = this.handlerNewCell
let _handlerNewCellHalf = _handlerNewCell.size.width / 2
console.log(this.mobileTempCell.ox)
// ----- left
if (entryX < _handlerNewCellHalf) {
_handlerNewCell.move.pos = 'fixed on-left-side'
}
// ----- middle
// if (entryX >= 20 && entryX <= window.innerWidth - 20) this.handlerNewCell.move.x = entryX
if (entryX >= _handlerNewCellHalf && entryX <= window.innerWidth - _handlerNewCell.size.width) {
_handlerNewCell.move.x = this.mobileTempCell.left
_handlerNewCell.move.pos = 'absolute'
}
// ----- right
if (entryX > window.innerWidth - _handlerNewCell.size.width) {
_handlerNewCell.move.pos = 'fixed on-right-side'
}
*/
},
handleMoveCell (obj) {
this.dummyButton.left = -100
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment