Repository navigation
Implement Texera User Avatars Featuer - #1373
Merged
Merged
Conversation
Zhen-Guan
marked this pull request as ready for review
November 20, 2021 13:28
Yicong-Huang
approved these changes
Dec 1, 2021
Yicong-Huang
left a comment
Contributor
There was a problem hiding this comment.
LGTM. left some minor comments.
Contributor
|
Group discussion 1/11: @Yicong-Huang will merge this PR soon |
yangzhang75
pushed a commit
to yangzhang75/texera
that referenced
this pull request
Jun 22, 2026
This PR creates an Angular component to show the avatar of a Texera user. The library/component **ngx-avatar** does not support retrieving Google users' avatars by Google ID (HaithemMosbahi/ngx-avatar#51), so I implemented the logic to retrieve Google users' avatars myself in the component. In order to send requests to Google People API, a public key is needed to provide. Creating a Google API Public Key is easy, please follow this instruction. https://developers.google.com/maps/documentation/maps-static/get-api-key Then fill the public key in the **environment.default.ts** `google: { clientID: "", publicKey: "", },` Demo: If the user is a normal Texera user, the avatar will be the default avatar with a random background color.  If the user is a Google user, the avatar will be its Google profile picture.  Co-authored-by: Yicong Huang <[email protected]>
This was referenced Oct 22, 2026
renovate-bot
pushed a commit
to renovate-bot/apache-_-texera
that referenced
this pull request
Oct 24, 2026
### What changes were proposed in this PR? Deletes `frontend/src/app/dashboard/type/google-api-response.ts`, a type file nothing imports. **−43 lines.** There is no behaviour change. The file exports `GooglePeopleApiResponse` and its nested `Source`, `Metadata` and `Photo` types. No code, spec, barrel file or path alias references the file or any of them, and no open PR adds an import. ### History | | | | --- | --- | | **Introduced by** | apache#1373 (2022-03-02), "Implement Texera User Avatars Featuer", whose user-avatar component called the Google People API | | **Usage removed by** | apache#2457 (2024-03-07), "Fix Google Avatar Display". It removed that call and the import | It has been unused for over two and a half years. ### Any related issues, documentation, discussions? Closes apache#9085 ### How was this PR tested? No new tests; nothing referenced the file. From `frontend/`: - `npx tsc --noEmit -p src/tsconfig.app.json` and `-p src/tsconfig.spec.json`: clean. - `yarn format:ci`: clean. - `npx ng build`: success. To re-check: ``` git grep -n -i -e GooglePeopleApiResponse -e google-api-response # no hits ``` ### Was this PR authored or co-authored using generative AI tooling? Generated-by: Claude Code (Claude Opus 5.5) 🤖 Generated with [Claude Code](https://claude.com/claude-code)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR creates an Angular component to show the avatar of a Texera user.
The library/component ngx-avatar does not support retrieving Google users' avatars by Google ID (HaithemMosbahi/ngx-avatar#51), so I implemented the logic to retrieve Google users' avatars myself in the component.
In order to send requests to Google People API, a public key is needed to provide.
Creating a Google API Public Key is easy, please follow this instruction.
https://developers.google.com/maps/documentation/maps-static/get-api-key
Then fill the public key in the environment.default.ts
google: { clientID: "", publicKey: "", },Demo:

If the user is a normal Texera user, the avatar will be the default avatar with a random background color.
If the user is a Google user, the avatar will be its Google profile picture.
