angular-gridster2
angular-gridster2 copied to clipboard
Text blur issue by using translate3D repeat issue
#412
As the pr has resolved the issue before,
I found the new code in the gridsterRender.service.ts has involved the translate3d.
Can you resolve the issue? Thank You.
setCellPosition(renderer: Renderer2, el: any, x: number, y: number): void { const xPosition = this.gridster.$options.dirType === DirTypes.RTL ? -x : x; if (this.gridster.$options.useTransformPositioning) { const transform = 'translate3d(' + xPosition + 'px, ' + y + 'px, 0)'; renderer.setStyle(el, 'transform', transform); } else { renderer.setStyle(el, 'left', this.getLeftMargin() + xPosition + 'px'); renderer.setStyle(el, 'top', this.getTopMargin() + y + 'px'); } }
@tiberiuzuld Repeated issue
Same issue here with version 16.0.0.
The issue seems to be, when a translate3d
value is not even. In my case position is transform: translate3d(0px, 675px, 0px);
and content is blurry. When I set the ty
value manually to 674px
, everything is fine.
@oliveshell Found a solution:
Just use the GridsterConfig
option useTransformPositioning: false
, to toggle between transform or top/left positioning of items. With false, translate3D ist not used and the blurrines is away. For more information see documentation .