| @@ -21,9 +21,9 @@ | ||
| 21 | 21 | * Example: |
| 22 | 22 | * [ |
| 23 | 23 | * 'key' => 'my_item', |
| 24 | 24 | * 'label' => 'My Item', |
| 25 | - * 'type' => 'default', | |
| 25 | + * 'type' => 'default', // or 'custom' | |
| 26 | 26 | * 'position' => 1, |
| 27 | 27 | * 'width' => '500px', |
| 28 | 28 | * 'html' => '<div>Content</div>' |
| 29 | 29 | * ] |
| @@ -57,112 +57,127 @@ | ||
| 57 | 57 | private static function getDefaultMenuItems() |
| 58 | 58 | { |
| 59 | 59 | return [ |
| 60 | 60 | [ |
| 61 | - 'key' => 'about_this_board', | |
| 62 | - 'label' => __('About this Board', 'fluent-boards'), | |
| 63 | - 'type' => 'default', | |
| 64 | - 'position' => 1, | |
| 65 | - 'role' => '' | |
| 61 | + 'key' => 'about_this_board', | |
| 62 | + 'icon_name' => 'info', | |
| 63 | + 'label' => __('About this Board', 'fluent-boards'), | |
| 64 | + 'type' => 'default', | |
| 65 | + 'position' => 1, | |
| 66 | + 'role' => '' | |
| 66 | 67 | ], |
| 67 | 68 | [ |
| 68 | - 'key' => 'board_activity', | |
| 69 | - 'label' => __('Board Activity', 'fluent-boards'), | |
| 70 | - 'type' => 'default', | |
| 71 | - 'position' => 2, | |
| 72 | - 'role' => '' | |
| 69 | + 'key' => 'board_activity', | |
| 70 | + 'icon_name' => 'activity', | |
| 71 | + 'label' => __('Board Activity', 'fluent-boards'), | |
| 72 | + 'type' => 'default', | |
| 73 | + 'position' => 2, | |
| 74 | + 'role' => '' | |
| 73 | 75 | ], |
| 74 | 76 | [ |
| 75 | - 'key' => 'change_background', | |
| 76 | - 'label' => __('Change Background', 'fluent-boards'), | |
| 77 | - 'type' => 'default', | |
| 78 | - 'position' => 3, | |
| 79 | - 'role' => 'manager' | |
| 77 | + 'key' => 'change_background', | |
| 78 | + 'icon_name' => 'image', | |
| 79 | + 'label' => __('Change Background', 'fluent-boards'), | |
| 80 | + 'type' => 'default', | |
| 81 | + 'position' => 3, | |
| 82 | + 'role' => 'manager' | |
| 80 | 83 | ], |
| 81 | 84 | [ |
| 82 | - 'key' => 'notification_settings', | |
| 83 | - 'label' => __('Notification Settings', 'fluent-boards'), | |
| 84 | - 'type' => 'default', | |
| 85 | - 'position' => 4, | |
| 86 | - 'role' => '' | |
| 85 | + 'key' => 'notification_settings', | |
| 86 | + 'icon_name' => 'notification', | |
| 87 | + 'label' => __('Notification Settings', 'fluent-boards'), | |
| 88 | + 'type' => 'default', | |
| 89 | + 'position' => 4, | |
| 90 | + 'role' => '' | |
| 87 | 91 | ], |
| 88 | 92 | [ |
| 89 | - 'key' => 'board_labels', | |
| 90 | - 'label' => __('Board Labels', 'fluent-boards'), | |
| 91 | - 'type' => 'default', | |
| 92 | - 'position' => 5, | |
| 93 | - 'role' => '' | |
| 93 | + 'key' => 'board_labels', | |
| 94 | + 'icon_name' => 'label', | |
| 95 | + 'label' => __('Board Labels', 'fluent-boards'), | |
| 96 | + 'type' => 'default', | |
| 97 | + 'position' => 5, | |
| 98 | + 'role' => '' | |
| 94 | 99 | ], |
| 95 | 100 | [ |
| 96 | - 'key' => 'custom_fields', | |
| 97 | - 'label' => __('Custom Fields', 'fluent-boards'), | |
| 98 | - 'type' => 'default', | |
| 99 | - 'position' => 6, | |
| 100 | - 'role' => '' | |
| 101 | + 'key' => 'custom_fields', | |
| 102 | + 'icon_name' => 'custom_fields', | |
| 103 | + 'label' => __('Custom Fields', 'fluent-boards'), | |
| 104 | + 'type' => 'default', | |
| 105 | + 'position' => 6, | |
| 106 | + 'role' => '' | |
| 101 | 107 | ], |
| 102 | 108 | [ |
| 103 | - 'key' => 'board_members', | |
| 104 | - 'label' => __('Board Members', 'fluent-boards'), | |
| 105 | - 'type' => 'default', | |
| 106 | - 'position' => 7, | |
| 107 | - 'role' => '' | |
| 109 | + 'key' => 'board_members', | |
| 110 | + 'icon_name' => 'members', | |
| 111 | + 'label' => __('Board Members', 'fluent-boards'), | |
| 112 | + 'type' => 'default', | |
| 113 | + 'position' => 7, | |
| 114 | + 'role' => '' | |
| 108 | 115 | ], |
| 109 | 116 | [ |
| 110 | - 'key' => 'archived_items', | |
| 111 | - 'label' => __('Archived Items', 'fluent-boards'), | |
| 112 | - 'type' => 'default', | |
| 113 | - 'position' => 8, | |
| 114 | - 'role' => '' | |
| 117 | + 'key' => 'archived_items', | |
| 118 | + 'icon_name' => 'archived_items', | |
| 119 | + 'label' => __('Archived Items', 'fluent-boards'), | |
| 120 | + 'type' => 'default', | |
| 121 | + 'position' => 8, | |
| 122 | + 'role' => '' | |
| 115 | 123 | ], |
| 116 | 124 | [ |
| 117 | - 'key' => 'webhooks', | |
| 118 | - 'label' => __('Webhooks', 'fluent-boards'), | |
| 119 | - 'type' => 'default', | |
| 120 | - 'position' => 9, | |
| 121 | - 'role' => '' | |
| 125 | + 'key' => 'webhooks', | |
| 126 | + 'icon_name' => 'webhooks', | |
| 127 | + 'label' => __('Webhooks', 'fluent-boards'), | |
| 128 | + 'type' => 'default', | |
| 129 | + 'position' => 9, | |
| 130 | + 'role' => '' | |
| 122 | 131 | ], |
| 123 | 132 | [ |
| 124 | - 'key' => 'associated_crm_contacts', | |
| 125 | - 'label' => __('Associated CRM Contacts', 'fluent-boards'), | |
| 126 | - 'type' => 'default', | |
| 127 | - 'position' => 9, | |
| 128 | - 'role' => '' | |
| 133 | + 'key' => 'associated_crm_contacts', | |
| 134 | + 'icon_name' => 'contacts-book', | |
| 135 | + 'label' => __('Associated CRM Contacts', 'fluent-boards'), | |
| 136 | + 'type' => 'default', | |
| 137 | + 'position' => 9, | |
| 138 | + 'role' => '' | |
| 129 | 139 | ], |
| 130 | 140 | [ |
| 131 | - 'key' => 'duplicate_board', | |
| 132 | - 'label' => __('Duplicate Board', 'fluent-boards'), | |
| 133 | - 'type' => 'default', | |
| 134 | - 'position' => 10, | |
| 135 | - 'role' => 'manager' | |
| 141 | + 'key' => 'duplicate_board', | |
| 142 | + 'icon_name' => 'copy', | |
| 143 | + 'label' => __('Duplicate Board', 'fluent-boards'), | |
| 144 | + 'type' => 'default', | |
| 145 | + 'position' => 10, | |
| 146 | + 'role' => 'manager' | |
| 136 | 147 | ], |
| 137 | 148 | [ |
| 138 | - 'key' => 'restore_board', | |
| 139 | - 'label' => __('Restore Board', 'fluent-boards'), | |
| 140 | - 'type' => 'default', | |
| 141 | - 'position' => 10, | |
| 142 | - 'role' => 'admin' | |
| 149 | + 'key' => 'restore_board', | |
| 150 | + 'icon_name' => 'refresh', | |
| 151 | + 'label' => __('Restore Board', 'fluent-boards'), | |
| 152 | + 'type' => 'default', | |
| 153 | + 'position' => 10, | |
| 154 | + 'role' => 'admin' | |
| 143 | 155 | ], |
| 144 | 156 | [ |
| 145 | - 'key' => 'export', | |
| 146 | - 'label' => __('Export', 'fluent-boards'), | |
| 147 | - 'type' => 'default', | |
| 148 | - 'position' => 10.5, | |
| 149 | - 'role' => 'manager', | |
| 150 | - 'pro' => true | |
| 157 | + 'key' => 'export', | |
| 158 | + 'icon_name' => 'export', | |
| 159 | + 'label' => __('Export', 'fluent-boards'), | |
| 160 | + 'type' => 'default', | |
| 161 | + 'position' => 10.5, | |
| 162 | + 'role' => 'manager', | |
| 163 | + 'pro' => true | |
| 151 | 164 | ], |
| 152 | 165 | [ |
| 153 | - 'key' => 'archive_board', | |
| 154 | - 'label' => __('Archive Board', 'fluent-boards'), | |
| 155 | - 'type' => 'default', | |
| 156 | - 'position' => 11, | |
| 157 | - 'role' => 'admin' | |
| 166 | + 'key' => 'archive_board', | |
| 167 | + 'icon_name' => 'archive', | |
| 168 | + 'label' => __('Archive Board', 'fluent-boards'), | |
| 169 | + 'type' => 'default', | |
| 170 | + 'position' => 11, | |
| 171 | + 'role' => 'admin' | |
| 158 | 172 | ], |
| 159 | 173 | [ |
| 160 | - 'key' => 'delete_board', | |
| 161 | - 'label' => __('Delete Board', 'fluent-boards'), | |
| 162 | - 'type' => 'default', | |
| 163 | - 'position' => 11, | |
| 164 | - 'role' => 'admin' | |
| 174 | + 'key' => 'delete_board', | |
| 175 | + 'icon_name' => 'delete', | |
| 176 | + 'label' => __('Delete Board', 'fluent-boards'), | |
| 177 | + 'type' => 'default', | |
| 178 | + 'position' => 11, | |
| 179 | + 'role' => 'admin' | |
| 165 | 180 | ] |
| 166 | 181 | ]; |
| 167 | 182 | } |
| 168 | 183 | |
| @@ -219,5 +234,5 @@ | ||
| 219 | 234 | } |
| 220 | 235 | |
| 221 | 236 | return $validatedItems; |
| 222 | 237 | } |
| 223 | -} | |
| 238 | +} | |