angulardart / angular_components

The official Material Design components for AngularDart. Used at Google in production apps.
https://pub.dev/packages/angular_components
372 stars 123 forks source link

MenuItem gallery example needs to be updated from deprecated action to actionWithConext #437

Open supermuka opened 5 years ago

supermuka commented 5 years ago

The analyzer shows the following message to MenuItem component:

'action' is deprecated and shouldn't be used.

However, the example in AngularDart Gallery is implemeting the deprecated action:

Material Menu/MaterialMenuDemoComponent /Source Code

Into MenuItem source code we have:

  MenuItem(this.label,
      { "...", 
      @Deprecated('Use ActionWithContext') MenuAction action,
      ActionWithContext actionWithContext,
       "..." })

It seems that the example needs to be updated.

Environment: Dart VM version: 2.6.0-dev.1.0 angular_components: version: "0.14.0-alpha+1"

nshahan commented 5 years ago

Good catch, thanks for pointing it out.