-
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix(profile): og images * chore(apps): consistent og images * fix(profile): default og image import * feat(images): cache og image * chore(images): log getOgImage call * no lodash * some lodash * no lodash * test: caching strategy * status checl * b64 bgImage * fix(profile): images binding * feat(profile): cacheKey * domain caches * wip * wip * wip * linter fix * no need to manually cache bust * minor fix * display name * wip * wip * wip --------- Co-authored-by: Adrian Maurer <[email protected]>
- Loading branch information
Showing
24 changed files
with
106 additions
and
136 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
This file contains 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
This file contains 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
Binary file not shown.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,13 @@ | ||
import * as clients from './clients' | ||
import hexStyle from './hex-style' | ||
import * as strings from './strings' | ||
import ogImage from './ogImage' | ||
import { imageFromAddressType } from './icons' | ||
import { normalizeProfileToLinks } from './profile' | ||
|
||
export { | ||
clients, | ||
hexStyle, | ||
strings, | ||
ogImage, | ||
imageFromAddressType, | ||
normalizeProfileToLinks, | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,9 @@ | ||
import createImageClient from '@kubelt/platform-clients/image' | ||
|
||
// TODO: turn into platform client | ||
export default async ( | ||
fgUrl: string | null | undefined, | ||
gradientSeed: string | ||
) => { | ||
const imageClient = createImageClient(Images) | ||
|
||
const bg = await imageClient.getGradient.mutate({ gradientSeed }) | ||
|
||
const fg = fgUrl || bg | ||
|
||
const ogImage = await imageClient.getOgImage.query({ fgUrl: fg, bgUrl: bg }) | ||
|
||
return { | ||
ogImage, | ||
cover: bg, | ||
pfp: fg, | ||
} | ||
} | ||
|
||
export const ogImageFromProfile = async (pfp: string, cover: string) => { | ||
const imageClient = createImageClient(Images) | ||
export const ogImageFromProfile = async (pfp: string) => { | ||
const imageClient = createImageClient(Images, { imagesURL: IMAGES_URL }) | ||
const ogImage = await imageClient.getOgImage.query({ | ||
fgUrl: pfp, | ||
bgUrl: cover, | ||
}) | ||
return ogImage | ||
} |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file was deleted.
Oops, something went wrong.
This file contains 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
Oops, something went wrong.