Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Add url param defaultUsername to prefill the login username field #5674

Merged
merged 1 commit into from
Jun 1, 2021

Conversation

djschilling
Copy link
Contributor

@djschilling djschilling commented Feb 22, 2021

This adds the possibility to provide a default username as url parameter defaultUsername for the login forumlar.

Fixes element-hq/element-web#16573

@djschilling djschilling force-pushed the default-username branch 2 times, most recently from 409e19c to 96df810 Compare February 24, 2021 09:45
@jryans
Copy link
Collaborator

jryans commented Feb 27, 2021

@djschilling In general, it's quite hard to review a random PR like this without the motivation. There might be many other ways to solve the problem. Could you file an issue about the use case, so we can track that separate from this one possible solution?

@djschilling
Copy link
Contributor Author

@jryans you are right my bad. i now created the issue for this pull request: element-hq/element-web#16573

@djschilling
Copy link
Contributor Author

@jryans can you have another look at it?

Copy link
Collaborator

@jryans jryans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, I think this makes sense conceptually, but let's tweak a few details first.

After making these changes, please click the re-request review wheel at the top right so I see your updates.

src/components/structures/MatrixChat.tsx Outdated Show resolved Hide resolved
src/components/structures/auth/Login.tsx Show resolved Hide resolved
@djschilling djschilling requested a review from jryans May 25, 2021 08:42
Copy link
Collaborator

@jryans jryans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code here looks okay to me, but before approving I'd like to understand your comment that the username is not removed from the URL for you. See my new comment in the thread.

@djschilling djschilling requested a review from jryans May 28, 2021 21:17
Copy link
Collaborator

@jryans jryans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, glad to hear this is working as expected. 😄

@jryans jryans merged commit a8b6094 into matrix-org:develop Jun 1, 2021
@djschilling djschilling deleted the default-username branch June 1, 2021 12:47
aaronraimist added a commit to aaronraimist/riot-web that referenced this pull request Jul 23, 2021
defaultUsername was added in matrix-org/matrix-react-sdk#5674. I'm not aware of any others but they may exist.

Signed-off-by: Aaron Raimist <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Accept username from app link e.g. via URL param
2 participants