Add link to community repo in feedback editor

This commit is contained in:
Joseph Lyons 2023-02-23 16:30:00 -05:00
parent 77c396a0ab
commit 37f910949d
4 changed files with 59 additions and 6 deletions

View file

@ -20,7 +20,12 @@ impl_actions!(zed, [OpenBrowser]);
actions!(
zed,
[CopySystemSpecsIntoClipboard, FileBugReport, RequestFeature]
[
CopySystemSpecsIntoClipboard,
FileBugReport,
RequestFeature,
OpenZedCommunityRepo
]
);
pub fn init(app_state: Arc<AppState>, cx: &mut MutableAppContext) {
@ -66,4 +71,11 @@ pub fn init(app_state: Arc<AppState>, cx: &mut MutableAppContext) {
});
},
);
cx.add_action(
|_: &mut Workspace, _: &OpenZedCommunityRepo, cx: &mut ViewContext<Workspace>| {
let url = "https://github.com/zed-industries/community";
cx.dispatch_action(OpenBrowser { url: url.into() });
},
);
}