[PR #5006] [MERGED] UX of link account (Step 1) #17587

Closed
opened 2025-11-02 14:15:13 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/go-gitea/gitea/pull/5006
Author: @coolaj86
Created: 10/3/2018
Status: Merged
Merged: 10/28/2018
Merged by: @techknowlogick

Base: masterHead: ux-link-account


📝 Commits (10+)

  • 6647860 Show either sign up OR sign in
  • b38b193 disambiguate fresh start from adding recovery options
  • c70fa16 use tabs to switch between account link flows
  • 4d3fb83 add active to tab body as well
  • 0b44528 changes as per discussion
  • 455de4e handle specific error; fix missing err typo
  • 79c831b Merge branch 'master' into ux-link-account
  • 087ed8f Merge branch 'master' into ux-link-account
  • 5ff0149 Merge branch 'master' into ux-link-account
  • cbfda4b Merge branch 'master' into ux-link-account

📊 Changes

5 files changed (+79 additions, -14 deletions)

View changed files

📝 options/locale/locale_en-US.ini (+6 -1)
📝 routers/user/auth.go (+24 -2)
📝 templates/user/auth/link_account.tmpl (+25 -7)
📝 templates/user/auth/signin_inner.tmpl (+12 -2)
📝 templates/user/auth/signup_inner.tmpl (+12 -2)

📄 Description

I'm working towards a solution for https://github.com/go-gitea/gitea/issues/3837

There are multiple issues that need to be addressed, but this pull request only attempts to address one complete unit of work which I consider to be of the highest immediate value and the lowest cost.

  • Current: Show either sign up or sign in - a great first step
    • Show the most appropriate as selected tab and allow other to be selected
  • When Creating Account via OAuth
    • "Register New Account" as tab name
    • display "Register" as "Add Email and Password (for Account Recovery)"
    • submit with "Complete Account"
  • When Linking Account via OAuth
    • "Link to Existing Account" as tab name
    • display "Sign In" as "Sign In to Authorize Linked Account"
    • submit with "Link Account"

New Account

screen shot 2018-10-04 at 11 37 54 pm

Link Account

screen shot 2018-10-04 at 11 38 02 pm

Walkthrough

screencap

If you'd like to test it out

My pull request is against master, but I run it as backport to v1.5.2 (includes https://github.com/go-gitea/gitea/pull/5006, https://github.com/go-gitea/gitea/pull/5029, https://github.com/go-gitea/gitea/pull/5033):

git clone https://github.com/coolaj86/gitea.git gitea.coolaj86 -b v1.5.1-coolaj86
pushd gitea.coolaj86
TAGS="bindata sqlite" make generate all

I would not recommend replacing your existing gitea, but rather creating a symlink so that you can easily switch back if you don't like it. For example, if you keep gitea in /opt/gitea/bin:

rsync -av ./gitea /opt/gitea/bin/gitea-v1.5.1-coolaj86
pushd /opt/gitea/bin
mv gitea gitea-v1.5.1
ln -s gitea-v1.5.1-coolaj86 gitea

I've run a couple of manual tests so far, so I feel comfortable with someone else trying it out. I won't be pushing any additional changes to that branch (such as the upcoming changes to address the empty checkboxes in the issue) until I've tested them in production for myself.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/go-gitea/gitea/pull/5006 **Author:** [@coolaj86](https://github.com/coolaj86) **Created:** 10/3/2018 **Status:** ✅ Merged **Merged:** 10/28/2018 **Merged by:** [@techknowlogick](https://github.com/techknowlogick) **Base:** `master` ← **Head:** `ux-link-account` --- ### 📝 Commits (10+) - [`6647860`](https://github.com/go-gitea/gitea/commit/664786040bff356e611e7f0d8084f20bbddf18bf) Show either sign up OR sign in - [`b38b193`](https://github.com/go-gitea/gitea/commit/b38b19354e714eebe75e7c3025b99aafcd7d5ccb) disambiguate fresh start from adding recovery options - [`c70fa16`](https://github.com/go-gitea/gitea/commit/c70fa161547f477d4d67c6b343b565261cf9d6f6) use tabs to switch between account link flows - [`4d3fb83`](https://github.com/go-gitea/gitea/commit/4d3fb831be7ab35aea6b7b84a2c063cfea22cde4) add active to tab body as well - [`0b44528`](https://github.com/go-gitea/gitea/commit/0b445283abe81828f1689e10f9c95bdad2bb20d7) changes as per discussion - [`455de4e`](https://github.com/go-gitea/gitea/commit/455de4e6b5f8b9b06fc147884faf078f84970715) handle specific error; fix missing err typo - [`79c831b`](https://github.com/go-gitea/gitea/commit/79c831b8e3c32cde62e39e1e27e0e02aa46c1368) Merge branch 'master' into ux-link-account - [`087ed8f`](https://github.com/go-gitea/gitea/commit/087ed8f1bedb87d2321f37b9b2cb985d28d4631f) Merge branch 'master' into ux-link-account - [`5ff0149`](https://github.com/go-gitea/gitea/commit/5ff01497d1f2b651a8fd98391c23c74400cd0f44) Merge branch 'master' into ux-link-account - [`cbfda4b`](https://github.com/go-gitea/gitea/commit/cbfda4bd6ed119b824cb940936ee190bc3272b4c) Merge branch 'master' into ux-link-account ### 📊 Changes **5 files changed** (+79 additions, -14 deletions) <details> <summary>View changed files</summary> 📝 `options/locale/locale_en-US.ini` (+6 -1) 📝 `routers/user/auth.go` (+24 -2) 📝 `templates/user/auth/link_account.tmpl` (+25 -7) 📝 `templates/user/auth/signin_inner.tmpl` (+12 -2) 📝 `templates/user/auth/signup_inner.tmpl` (+12 -2) </details> ### 📄 Description I'm working towards a solution for https://github.com/go-gitea/gitea/issues/3837 There are multiple issues that need to be addressed, but this pull request only attempts to address one complete unit of work which I consider to be of the highest immediate value and the lowest cost. * [x] Current: Show either sign up or sign in - a great first step * [x] Show the most appropriate as selected tab and allow other to be selected * When Creating Account via OAuth * [x] "Register New Account" as tab name * [x] display "Register" as "Add Email and Password (for Account Recovery)" * [x] submit with "Complete Account" * When Linking Account via OAuth * [x] "Link to Existing Account" as tab name * [x] display "Sign In" as "Sign In to Authorize Linked Account" * [x] submit with "Link Account" New Account ![screen shot 2018-10-04 at 11 37 54 pm](https://user-images.githubusercontent.com/122831/46517860-980f7200-c82e-11e8-8535-ff8d18806a65.png) Link Account ![screen shot 2018-10-04 at 11 38 02 pm](https://user-images.githubusercontent.com/122831/46517859-980f7200-c82e-11e8-9a67-13bbe903baa3.png) Walkthrough [![screencap](https://i.imgur.com/LRldREV.png)](https://youtu.be/jM8NL4IMM5Y) If you'd like to test it out ==== My pull request is against `master`, but [I run it](https://git.coolaj86.com) as backport to v1.5.2 (includes https://github.com/go-gitea/gitea/pull/5006, https://github.com/go-gitea/gitea/pull/5029, https://github.com/go-gitea/gitea/pull/5033): ```bash git clone https://github.com/coolaj86/gitea.git gitea.coolaj86 -b v1.5.1-coolaj86 pushd gitea.coolaj86 TAGS="bindata sqlite" make generate all ``` I would not recommend replacing your existing gitea, but rather creating a symlink so that you can easily switch back if you don't like it. For example, if you keep `gitea` in `/opt/gitea/bin`: ```bash rsync -av ./gitea /opt/gitea/bin/gitea-v1.5.1-coolaj86 pushd /opt/gitea/bin mv gitea gitea-v1.5.1 ln -s gitea-v1.5.1-coolaj86 gitea ``` I've run a couple of manual tests so far, so I feel comfortable with someone else trying it out. I won't be pushing any additional changes to that branch (such as the upcoming changes to address the empty checkboxes in the issue) until I've tested them in production for myself. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-02 14:15:13 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#17587