{"action":"closed","number":5162,"pull_request":{"url":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls/5162","id":62305679,"html_url":"https://github.com/CenterForOpenScience/osf.io/pull/5162","diff_url":"https://github.com/CenterForOpenScience/osf.io/pull/5162.diff","patch_url":"https://github.com/CenterForOpenScience/osf.io/pull/5162.patch","issue_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/issues/5162","number":5162,"state":"closed","locked":false,"title":"Pop-up added when navigating away from project settings page after editing title/description","user":{"login":"NehaTelhan","id":16804881,"avatar_url":"https://avatars.githubusercontent.com/u/16804881?v=3","gravatar_id":"","url":"https://api.github.com/users/NehaTelhan","html_url":"https://github.com/NehaTelhan","followers_url":"https://api.github.com/users/NehaTelhan/followers","following_url":"https://api.github.com/users/NehaTelhan/following{/other_user}","gists_url":"https://api.github.com/users/NehaTelhan/gists{/gist_id}","starred_url":"https://api.github.com/users/NehaTelhan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NehaTelhan/subscriptions","organizations_url":"https://api.github.com/users/NehaTelhan/orgs","repos_url":"https://api.github.com/users/NehaTelhan/repos","events_url":"https://api.github.com/users/NehaTelhan/events{/privacy}","received_events_url":"https://api.github.com/users/NehaTelhan/received_events","type":"User","site_admin":false},"body":"**Issue:** https://openscience.atlassian.net/browse/OSF-5104 \r\n# **Purpose**: \r\nCurrently, when a user makes changes to either their category, title, or description in the project settings page and then tries to navigate to another page, their savings won't automatically be made nor are they alerted that they have unsaved changes on the page. This PR will show a pop-up alert when the user is navigating to another page without having saved their changes.\r\n\r\n# **Changes**\r\nShows a pop-up window that tells the user they're leaving a page without having saved the changes made. There are two buttons on this pop-up, the first to 'stay on this page' with the implication that they can save their changes before navigating to another page, and the second to 'leave this page', anyways. This is only enacted if any or all of the following are altered without hitting 'save changes': title, category, description. \r\n\r\n# **Side Effects**\r\nAs very few lines of code were added (four lines including and if-statement with a return), no side effects are anticipated. \r\n\r\n\r\n","created_at":"2016-03-09T22:16:40Z","updated_at":"2016-03-12T17:30:00Z","closed_at":"2016-03-12T17:30:00Z","merged_at":"2016-03-12T17:30:00Z","merge_commit_sha":"e04c668560520f4c99d0baed6201c5c1d6004a1e","assignee":null,"milestone":{"url":"https://api.github.com/repos/CenterForOpenScience/osf.io/milestones/65","html_url":"https://github.com/CenterForOpenScience/osf.io/milestones/0.66.0","labels_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/milestones/65/labels","id":1613152,"number":65,"title":"0.66.0","description":"","creator":{"login":"sloria","id":2379650,"avatar_url":"https://avatars.githubusercontent.com/u/2379650?v=3","gravatar_id":"","url":"https://api.github.com/users/sloria","html_url":"https://github.com/sloria","followers_url":"https://api.github.com/users/sloria/followers","following_url":"https://api.github.com/users/sloria/following{/other_user}","gists_url":"https://api.github.com/users/sloria/gists{/gist_id}","starred_url":"https://api.github.com/users/sloria/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sloria/subscriptions","organizations_url":"https://api.github.com/users/sloria/orgs","repos_url":"https://api.github.com/users/sloria/repos","events_url":"https://api.github.com/users/sloria/events{/privacy}","received_events_url":"https://api.github.com/users/sloria/received_events","type":"User","site_admin":false},"open_issues":7,"closed_issues":35,"state":"open","created_at":"2016-02-29T19:57:46Z","updated_at":"2016-03-12T17:30:00Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls/5162/commits","review_comments_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls/5162/comments","review_comment_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/issues/5162/comments","statuses_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/statuses/772360e23b495163a04a8e33e01b0a4c82001097","head":{"label":"NehaTelhan:pop-up","ref":"pop-up","sha":"772360e23b495163a04a8e33e01b0a4c82001097","user":{"login":"NehaTelhan","id":16804881,"avatar_url":"https://avatars.githubusercontent.com/u/16804881?v=3","gravatar_id":"","url":"https://api.github.com/users/NehaTelhan","html_url":"https://github.com/NehaTelhan","followers_url":"https://api.github.com/users/NehaTelhan/followers","following_url":"https://api.github.com/users/NehaTelhan/following{/other_user}","gists_url":"https://api.github.com/users/NehaTelhan/gists{/gist_id}","starred_url":"https://api.github.com/users/NehaTelhan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NehaTelhan/subscriptions","organizations_url":"https://api.github.com/users/NehaTelhan/orgs","repos_url":"https://api.github.com/users/NehaTelhan/repos","events_url":"https://api.github.com/users/NehaTelhan/events{/privacy}","received_events_url":"https://api.github.com/users/NehaTelhan/received_events","type":"User","site_admin":false},"repo":{"id":53418350,"name":"osf.io","full_name":"NehaTelhan/osf.io","owner":{"login":"NehaTelhan","id":16804881,"avatar_url":"https://avatars.githubusercontent.com/u/16804881?v=3","gravatar_id":"","url":"https://api.github.com/users/NehaTelhan","html_url":"https://github.com/NehaTelhan","followers_url":"https://api.github.com/users/NehaTelhan/followers","following_url":"https://api.github.com/users/NehaTelhan/following{/other_user}","gists_url":"https://api.github.com/users/NehaTelhan/gists{/gist_id}","starred_url":"https://api.github.com/users/NehaTelhan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/NehaTelhan/subscriptions","organizations_url":"https://api.github.com/users/NehaTelhan/orgs","repos_url":"https://api.github.com/users/NehaTelhan/repos","events_url":"https://api.github.com/users/NehaTelhan/events{/privacy}","received_events_url":"https://api.github.com/users/NehaTelhan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/NehaTelhan/osf.io","description":"Facilitating Open Science","fork":true,"url":"https://api.github.com/repos/NehaTelhan/osf.io","forks_url":"https://api.github.com/repos/NehaTelhan/osf.io/forks","keys_url":"https://api.github.com/repos/NehaTelhan/osf.io/keys{/key_id}","collaborators_url":"https://api.github.com/repos/NehaTelhan/osf.io/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/NehaTelhan/osf.io/teams","hooks_url":"https://api.github.com/repos/NehaTelhan/osf.io/hooks","issue_events_url":"https://api.github.com/repos/NehaTelhan/osf.io/issues/events{/number}","events_url":"https://api.github.com/repos/NehaTelhan/osf.io/events","assignees_url":"https://api.github.com/repos/NehaTelhan/osf.io/assignees{/user}","branches_url":"https://api.github.com/repos/NehaTelhan/osf.io/branches{/branch}","tags_url":"https://api.github.com/repos/NehaTelhan/osf.io/tags","blobs_url":"https://api.github.com/repos/NehaTelhan/osf.io/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/NehaTelhan/osf.io/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/NehaTelhan/osf.io/git/refs{/sha}","trees_url":"https://api.github.com/repos/NehaTelhan/osf.io/git/trees{/sha}","statuses_url":"https://api.github.com/repos/NehaTelhan/osf.io/statuses/{sha}","languages_url":"https://api.github.com/repos/NehaTelhan/osf.io/languages","stargazers_url":"https://api.github.com/repos/NehaTelhan/osf.io/stargazers","contributors_url":"https://api.github.com/repos/NehaTelhan/osf.io/contributors","subscribers_url":"https://api.github.com/repos/NehaTelhan/osf.io/subscribers","subscription_url":"https://api.github.com/repos/NehaTelhan/osf.io/subscription","commits_url":"https://api.github.com/repos/NehaTelhan/osf.io/commits{/sha}","git_commits_url":"https://api.github.com/repos/NehaTelhan/osf.io/git/commits{/sha}","comments_url":"https://api.github.com/repos/NehaTelhan/osf.io/comments{/number}","issue_comment_url":"https://api.github.com/repos/NehaTelhan/osf.io/issues/comments{/number}","contents_url":"https://api.github.com/repos/NehaTelhan/osf.io/contents/{+path}","compare_url":"https://api.github.com/repos/NehaTelhan/osf.io/compare/{base}...{head}","merges_url":"https://api.github.com/repos/NehaTelhan/osf.io/merges","archive_url":"https://api.github.com/repos/NehaTelhan/osf.io/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/NehaTelhan/osf.io/downloads","issues_url":"https://api.github.com/repos/NehaTelhan/osf.io/issues{/number}","pulls_url":"https://api.github.com/repos/NehaTelhan/osf.io/pulls{/number}","milestones_url":"https://api.github.com/repos/NehaTelhan/osf.io/milestones{/number}","notifications_url":"https://api.github.com/repos/NehaTelhan/osf.io/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/NehaTelhan/osf.io/labels{/name}","releases_url":"https://api.github.com/repos/NehaTelhan/osf.io/releases{/id}","deployments_url":"https://api.github.com/repos/NehaTelhan/osf.io/deployments","created_at":"2016-03-08T14:25:35Z","updated_at":"2016-03-08T14:25:41Z","pushed_at":"2016-03-10T18:51:06Z","git_url":"git://github.com/NehaTelhan/osf.io.git","ssh_url":"git@github.com:NehaTelhan/osf.io.git","clone_url":"https://github.com/NehaTelhan/osf.io.git","svn_url":"https://github.com/NehaTelhan/osf.io","homepage":"http://osf.io","size":122924,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"CenterForOpenScience:develop","ref":"develop","sha":"81337324b60a7f572a2080d2f9dbe05fcd2ef693","user":{"login":"CenterForOpenScience","id":3344584,"avatar_url":"https://avatars.githubusercontent.com/u/3344584?v=3","gravatar_id":"","url":"https://api.github.com/users/CenterForOpenScience","html_url":"https://github.com/CenterForOpenScience","followers_url":"https://api.github.com/users/CenterForOpenScience/followers","following_url":"https://api.github.com/users/CenterForOpenScience/following{/other_user}","gists_url":"https://api.github.com/users/CenterForOpenScience/gists{/gist_id}","starred_url":"https://api.github.com/users/CenterForOpenScience/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CenterForOpenScience/subscriptions","organizations_url":"https://api.github.com/users/CenterForOpenScience/orgs","repos_url":"https://api.github.com/users/CenterForOpenScience/repos","events_url":"https://api.github.com/users/CenterForOpenScience/events{/privacy}","received_events_url":"https://api.github.com/users/CenterForOpenScience/received_events","type":"Organization","site_admin":false},"repo":{"id":10199599,"name":"osf.io","full_name":"CenterForOpenScience/osf.io","owner":{"login":"CenterForOpenScience","id":3344584,"avatar_url":"https://avatars.githubusercontent.com/u/3344584?v=3","gravatar_id":"","url":"https://api.github.com/users/CenterForOpenScience","html_url":"https://github.com/CenterForOpenScience","followers_url":"https://api.github.com/users/CenterForOpenScience/followers","following_url":"https://api.github.com/users/CenterForOpenScience/following{/other_user}","gists_url":"https://api.github.com/users/CenterForOpenScience/gists{/gist_id}","starred_url":"https://api.github.com/users/CenterForOpenScience/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CenterForOpenScience/subscriptions","organizations_url":"https://api.github.com/users/CenterForOpenScience/orgs","repos_url":"https://api.github.com/users/CenterForOpenScience/repos","events_url":"https://api.github.com/users/CenterForOpenScience/events{/privacy}","received_events_url":"https://api.github.com/users/CenterForOpenScience/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CenterForOpenScience/osf.io","description":"Facilitating Open Science","fork":false,"url":"https://api.github.com/repos/CenterForOpenScience/osf.io","forks_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/forks","keys_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/teams","hooks_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/hooks","issue_events_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/issues/events{/number}","events_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/events","assignees_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/assignees{/user}","branches_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/branches{/branch}","tags_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/tags","blobs_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/git/refs{/sha}","trees_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/statuses/{sha}","languages_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/languages","stargazers_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/stargazers","contributors_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/contributors","subscribers_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/subscribers","subscription_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/subscription","commits_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/commits{/sha}","git_commits_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/git/commits{/sha}","comments_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/comments{/number}","issue_comment_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/issues/comments{/number}","contents_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/contents/{+path}","compare_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/merges","archive_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/downloads","issues_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/issues{/number}","pulls_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls{/number}","milestones_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/milestones{/number}","notifications_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/labels{/name}","releases_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/releases{/id}","deployments_url":"https://api.github.com/repos/CenterForOpenScience/osf.io/deployments","created_at":"2013-05-21T15:53:37Z","updated_at":"2016-03-11T14:17:57Z","pushed_at":"2016-03-12T17:30:00Z","git_url":"git://github.com/CenterForOpenScience/osf.io.git","ssh_url":"git@github.com:CenterForOpenScience/osf.io.git","clone_url":"https://github.com/CenterForOpenScience/osf.io.git","svn_url":"https://github.com/CenterForOpenScience/osf.io","homepage":"http://osf.io","size":268100,"stargazers_count":201,"watchers_count":201,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":158,"mirror_url":null,"open_issues_count":210,"forks":158,"open_issues":210,"watchers":201,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls/5162"},"html":{"href":"https://github.com/CenterForOpenScience/osf.io/pull/5162"},"issue":{"href":"https://api.github.com/repos/CenterForOpenScience/osf.io/issues/5162"},"comments":{"href":"https://api.github.com/repos/CenterForOpenScience/osf.io/issues/5162/comments"},"review_comments":{"href":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls/5162/comments"},"review_comment":{"href":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CenterForOpenScience/osf.io/pulls/5162/commits"},"statuses":{"href":"https://api.github.com/repos/CenterForOpenScience/osf.io/statuses/772360e23b495163a04a8e33e01b0a4c82001097"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"sloria","id":2379650,"avatar_url":"https://avatars.githubusercontent.com/u/2379650?v=3","gravatar_id":"","url":"https://api.github.com/users/sloria","html_url":"https://github.com/sloria","followers_url":"https://api.github.com/users/sloria/followers","following_url":"https://api.github.com/users/sloria/following{/other_user}","gists_url":"https://api.github.com/users/sloria/gists{/gist_id}","starred_url":"https://api.github.com/users/sloria/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sloria/subscriptions","organizations_url":"https://api.github.com/users/sloria/orgs","repos_url":"https://api.github.com/users/sloria/repos","events_url":"https://api.github.com/users/sloria/events{/privacy}","received_events_url":"https://api.github.com/users/sloria/received_events","type":"User","site_admin":false},"comments":3,"review_comments":13,"commits":6,"additions":8,"deletions":6,"changed_files":2}}