import { extend } from 'flarum/extend';
import app from 'flarum/app';
import PermissionGrid from 'flarum/components/PermissionGrid';

app.initializers.add('flarum-sticky', () => {
  extend(PermissionGrid.prototype, 'moderateItems', items => {
    items.add('sticky', {
      icon: 'fas fa-thumbtack',
      label: app.translator.trans('flarum-sticky.admin.permissions.sticky_discussions_label'),
      permission: 'discussion.sticky'
    }, 95);
  });
});

@@ -4,131 +4,28 @@
 ort 
-%7B extend %7D from 'flarum/extend';%0Aimport app from 'flarum/app';%0Aimport PermissionGrid from 'flarum/components/PermissionGrid
+app from 'flarum/app
 ';%0A%0A
@@ -76,93 +76,76 @@
 %7B%0A  
+app.
 exten
-d(PermissionGrid.prototype, 'moderateItems', items =%3E %7B%0A    items.add('sticky', 
+sionData%0A    .for('flarum-sticky')%0A    .registerPermission(
 %7B%0A  
@@ -318,16 +318,22 @@
  %7D, 
-95);%0A  %7D
+'moderate', 95
 );%0A%7D

Update admin js for admin ux redesign