Comments (8)
Hi @rajesh-kanakabandi ,
If is that complicated to upgrade to v4,
I will think about releasing a v2.4.5, and look at how complicate it is to do it, probably this week will do it.
from angular-gridster2.
Hi @rajesh-kanakabandi ,
Released a v2.4.5 for angular2 compatible with AOT.
I didn't tested it because my demo now works with Angularv4,
I only replaced Renderer2 with Renderer v1
Let me know if this works for you.
from angular-gridster2.
@tiberiuzuld thank you for the quick update. AOT build works but still I get the following error on the browser.
TypeError: element.addEventListener is not a function
at DomEventsPlugin.addEventListener (https://mydomain.com/dashboard-app/vendor.bundle.js:81519:17)
at EventManager.addEventListener (https://mydomain.com/dashboard-app/vendor.bundle.js:17627:23)
at DomRenderer.listen (https://mydomain.com/dashboard-app/vendor.bundle.js:54271:48)
at DebugDomRenderer.listen (https://mydomain.com/dashboard-app/vendor.bundle.js:100957:31)
at GridsterComponent.ngOnInit (https://mydomain.com/dashboard-app/vendor.bundle.js:38319:43)
at Wrapper_GridsterComponent.ngDoCheck (/GridsterModule/GridsterComponent/wrapper.ngfactory.js:34:53)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent0.detectChangesInternal (/AppModule/Gridster2dashComponent/component.ngfactory.js:172:31)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102610:14)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102805:44)
at CompiledTemplate.proxyViewClass.AppView.internalDetectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102595:18)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent_Host0.detectChangesInternal (/AppModule/Gridster2dashComponent/host.ngfactory.js:29:19)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102610:14)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102805:44)
at ViewRef_.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:70422:20)
at RouterOutlet.activate (https://mydomain.com/dashboard-app/vendor.bundle.js:82505:42)
ErrorHandler.handleError @ error_handler.js:54
next @ application_ref.js:348
schedulerFn @ async.js:93
SafeSubscriber.__tryOrUnsub @ Subscriber.js:234
SafeSubscriber.next @ Subscriber.js:183
Subscriber._next @ Subscriber.js:125
Subscriber.next @ Subscriber.js:89
Subject.next @ Subject.js:55
EventEmitter.emit @ async.js:79
NgZone.triggerError @ ng_zone.js:333
onHandleError @ ng_zone.js:294
ZoneDelegate.handleError @ zone.js:233
Zone.runGuarded @ zone.js:129
_loop_1 @ zone.js:416
drainMicroTaskQueue @ zone.js:425
ZoneTask.invoke @ zone.js:336
2017-04-10 16:32:12.348 error_handler.js:59 ORIGINAL STACKTRACE:
ErrorHandler.handleError @ error_handler.js:59
next @ application_ref.js:348
schedulerFn @ async.js:93
SafeSubscriber.__tryOrUnsub @ Subscriber.js:234
SafeSubscriber.next @ Subscriber.js:183
Subscriber._next @ Subscriber.js:125
Subscriber.next @ Subscriber.js:89
Subject.next @ Subject.js:55
EventEmitter.emit @ async.js:79
NgZone.triggerError @ ng_zone.js:333
onHandleError @ ng_zone.js:294
ZoneDelegate.handleError @ zone.js:233
Zone.runGuarded @ zone.js:129
_loop_1 @ zone.js:416
drainMicroTaskQueue @ zone.js:425
ZoneTask.invoke @ zone.js:336
2017-04-10 16:32:12.348 error_handler.js:60 Error: Uncaught (in promise): Error: Error in ./Gridster2dashComponent class Gridster2dashComponent - inline template:4:10 caused by: element.addEventListener is not a function
TypeError: element.addEventListener is not a function
at DomEventsPlugin.addEventListener (dom_events.js:32)
at EventManager.addEventListener (event_manager.js:37)
at DomRenderer.listen (dom_renderer.js:302)
at DebugDomRenderer.listen (debug_renderer.js:153)
at GridsterComponent.ngOnInit (gridster.component.js:31)
at Wrapper_GridsterComponent.ngDoCheck (/GridsterModule/GridsterComponent/wrapper.ngfactory.js:34)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent0.detectChangesInternal (/AppModule/Gridster2dashComponent/component.ngfactory.js:172)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (view.js:425)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (view.js:620)
at CompiledTemplate.proxyViewClass.AppView.internalDetectChanges (view.js:410)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent_Host0.detectChangesInternal (/AppModule/Gridster2dashComponent/host.ngfactory.js:29)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (view.js:425)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (view.js:620)
at ViewRef_.detectChanges (view_ref.js:170)
at RouterOutlet.activate (router_outlet.js:156)
at resolvePromise (zone.js:475) [angular]
at resolvePromise (zone.js:460) [angular]
at /dashboard-app/vendor.bundle.js:168890:17 [angular]
at Object.onInvokeTask (ng_zone.js:264) [angular]
at ZoneDelegate.invokeTask (zone.js:261) [angular]
at Zone.runTask (zone.js:151) [<root> => angular]
at drainMicroTaskQueue (zone.js:405) [<root>]
at HTMLAnchorElement.ZoneTask.invoke (zone.js:336) [<root>]
ErrorHandler.handleError @ error_handler.js:60
next @ application_ref.js:348
schedulerFn @ async.js:93
SafeSubscriber.__tryOrUnsub @ Subscriber.js:234
SafeSubscriber.next @ Subscriber.js:183
Subscriber._next @ Subscriber.js:125
Subscriber.next @ Subscriber.js:89
Subject.next @ Subject.js:55
EventEmitter.emit @ async.js:79
NgZone.triggerError @ ng_zone.js:333
onHandleError @ ng_zone.js:294
ZoneDelegate.handleError @ zone.js:233
Zone.runGuarded @ zone.js:129
_loop_1 @ zone.js:416
drainMicroTaskQueue @ zone.js:425
ZoneTask.invoke @ zone.js:336
2017-04-10 16:32:12.348 zone.js:392 Unhandled Promise rejection: Error in ./Gridster2dashComponent class Gridster2dashComponent - inline template:4:10 caused by: element.addEventListener is not a function ; Zone: angular ; Task: Promise.then ; Value: ViewWrappedError {_nativeError: Error: Error in ./Gridster2dashComponent class Gridster2dashComponent - inline template:4:10 caused …, originalError: TypeError: element.addEventListener is not a function
at DomEventsPlugin.addEventListener (https…, context: DebugContext} TypeError: element.addEventListener is not a function
at DomEventsPlugin.addEventListener (https://mydomain.com/dashboard-app/vendor.bundle.js:81519:17)
at EventManager.addEventListener (https://mydomain.com/dashboard-app/vendor.bundle.js:17627:23)
at DomRenderer.listen (https://mydomain.com/dashboard-app/vendor.bundle.js:54271:48)
at DebugDomRenderer.listen (https://mydomain.com/dashboard-app/vendor.bundle.js:100957:31)
at GridsterComponent.ngOnInit (https://mydomain.com/dashboard-app/vendor.bundle.js:38319:43)
at Wrapper_GridsterComponent.ngDoCheck (/GridsterModule/GridsterComponent/wrapper.ngfactory.js:34:53)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent0.detectChangesInternal (/AppModule/Gridster2dashComponent/component.ngfactory.js:172:31)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102610:14)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102805:44)
at CompiledTemplate.proxyViewClass.AppView.internalDetectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102595:18)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent_Host0.detectChangesInternal (/AppModule/Gridster2dashComponent/host.ngfactory.js:29:19)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102610:14)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:102805:44)
at ViewRef_.detectChanges (https://mydomain.com/dashboard-app/vendor.bundle.js:70422:20)
at RouterOutlet.activate (https://mydomain.com/dashboard-app/vendor.bundle.js:82505:42)
consoleError @ zone.js:392
_loop_1 @ zone.js:421
drainMicroTaskQueue @ zone.js:425
ZoneTask.invoke @ zone.js:336
2017-04-10 16:32:12.350 zone.js:394 Error: Uncaught (in promise): Error: Error in ./Gridster2dashComponent class Gridster2dashComponent - inline template:4:10 caused by: element.addEventListener is not a function
TypeError: element.addEventListener is not a function
at DomEventsPlugin.addEventListener (dom_events.js:32)
at EventManager.addEventListener (event_manager.js:37)
at DomRenderer.listen (dom_renderer.js:302)
at DebugDomRenderer.listen (debug_renderer.js:153)
at GridsterComponent.ngOnInit (gridster.component.js:31)
at Wrapper_GridsterComponent.ngDoCheck (/GridsterModule/GridsterComponent/wrapper.ngfactory.js:34)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent0.detectChangesInternal (/AppModule/Gridster2dashComponent/component.ngfactory.js:172)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (view.js:425)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (view.js:620)
at CompiledTemplate.proxyViewClass.AppView.internalDetectChanges (view.js:410)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent_Host0.detectChangesInternal (/AppModule/Gridster2dashComponent/host.ngfactory.js:29)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (view.js:425)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (view.js:620)
at ViewRef_.detectChanges (view_ref.js:170)
at RouterOutlet.activate (router_outlet.js:156)
at DomEventsPlugin.addEventListener (dom_events.js:32)
at EventManager.addEventListener (event_manager.js:37)
at DomRenderer.listen (dom_renderer.js:302)
at DebugDomRenderer.listen (debug_renderer.js:153)
at GridsterComponent.ngOnInit (gridster.component.js:31)
at Wrapper_GridsterComponent.ngDoCheck (/GridsterModule/GridsterComponent/wrapper.ngfactory.js:34)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent0.detectChangesInternal (/AppModule/Gridster2dashComponent/component.ngfactory.js:172)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (view.js:425)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (view.js:620)
at CompiledTemplate.proxyViewClass.AppView.internalDetectChanges (view.js:410)
at CompiledTemplate.proxyViewClass.View_Gridster2dashComponent_Host0.detectChangesInternal (/AppModule/Gridster2dashComponent/host.ngfactory.js:29)
at CompiledTemplate.proxyViewClass.AppView.detectChanges (view.js:425)
at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (view.js:620)
at ViewRef_.detectChanges (view_ref.js:170)
at RouterOutlet.activate (router_outlet.js:156)
at resolvePromise (zone.js:475) [angular]
at resolvePromise (zone.js:460) [angular]
at /dashboard-app/vendor.bundle.js:168890:17 [angular]
at Object.onInvokeTask (ng_zone.js:264) [angular]
at ZoneDelegate.invokeTask (zone.js:261) [angular]
at Zone.runTask (zone.js:151) [<root> => angular]
at drainMicroTaskQueue (zone.js:405) [<root>]
at HTMLAnchorElement.ZoneTask.invoke (zone.js:336) [<root>]```
thank you,
--Rajesh
from angular-gridster2.
ok try v2.4.6,
replaced the listen on renderer with listenGlobal
from angular-gridster2.
@tiberiuzuld works fine now.
although just FYI, I had to make change to the 'item' input on gridster-item.
my input previously was
{
id: this.dashboard.length, cols: 2, rows: 1, y: 0, x: 0 ,
payload: payloadObj
}
this was resulting in
TypeError: Cannot set property 'type' of undefined
at Function.GridsterUtils.merge
however moving the payload out of the input for 'item' on gridster-item has successfully worked.
from angular-gridster2.
@rajesh-kanakabandi hmm... yes I should take the options I care about only.
Will make a fix this week.
from angular-gridster2.
@rajesh-kanakabandi made a fix in v2.4.8 try it out.
from angular-gridster2.
Closing since I assume the issues are resolved.
from angular-gridster2.
Related Issues (20)
- issue when add new Widget "Boards - Created vs. Solved" - when Board is chosen from drop down menu -image not work and crash
- Drag item > Right-click to open context menu > Item sticks to cursor HOT 2
- drag and swap according to bottom tile height not working HOT 1
- I am unable to resize apex charts height and width according to grid item dimensions HOT 1
- how to predefine a grid size with px
- Accessibility issue - cannot drag the widgets by use of keyboard arrow keys
- Gridster "angular-gridster2": "^13.3.2" is giving error ERROR TypeError: (0 , Ie.debounceTime) is not a function at n.ngOnInit (main.js:1:1539939)
- Resize and Drag bug when the mouse moves outside gridster in an iframe/container (Chrome)
- Gridster drag continue event for item is not available
- Resizing in Angular causing this HOT 1
- Indefinite swap of items when they are in the top left corner of the grid
- cannot swap and push items smoothly in vertical scroll
- Scrolling the grid with "verticalFixed" mode and emptyCellDrag enabled
- Hi, In the context of using angular-gridster2, is there a method to assign a label or button to vacant grid cells, allowing the addition of a new grid cell?
- angular v17 has been released HOT 5
- The row width is too large
- [BUG] - Grid is bouncing/jumping in specifc browser size
- Auto Position Items When Browser Window Is Resized
- How to have scroll in the gridster while keeping the grid size
- Responsive and size of items
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from angular-gridster2.