mirror of
https://github.com/hcengineering/platform.git
synced 2026-09-07 18:27:44 +02:00
fix(github): apply guest token to images in markdown sync (#10659)
* fix(github): apply guest token to images in markdown sync (#10516) The appendGuestLinkToImage function existed but was never called from getMarkdown(). Add it as the default preprocessor so image URLs include a guest JWT token, allowing them to render on GitHub. Signed-off-by: Daniel Kendall <dkendall@ledoweb.com> Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Don Kendall <kendall@donkendall.com> * fix: formatting (prettier/eslint) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Don Kendall <kendall@donkendall.com> --------- Signed-off-by: Don Kendall <kendall@donkendall.com> Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
071b7f5329
commit
cd1234b422
@@ -523,9 +523,7 @@ export class IssueSyncManager extends IssueSyncManagerBase implements DocSyncMan
|
||||
info.repository as Ref<GithubIntegrationRepository>,
|
||||
container.project,
|
||||
taskTypes[0]._id,
|
||||
repo as GithubIntegrationRepository & {
|
||||
repository: IntegrationRepositoryData
|
||||
},
|
||||
repo,
|
||||
!markdownCompatible
|
||||
)
|
||||
},
|
||||
|
||||
@@ -86,6 +86,7 @@ import { ReviewCommentSyncManager } from './sync/reviewComments'
|
||||
import { ReviewThreadSyncManager } from './sync/reviewThreads'
|
||||
import { ReviewSyncManager } from './sync/reviews'
|
||||
import { UsersSyncManager, fetchViewerDetails } from './sync/users'
|
||||
import { appendGuestLinkToImage } from './sync/guest'
|
||||
import { errorToObj } from './sync/utils'
|
||||
import {
|
||||
ContainerFocus,
|
||||
@@ -243,7 +244,10 @@ export class GithubWorker implements IntegrationManager {
|
||||
concatLink(this.getBranding()?.front ?? config.FrontURL, `/browse/?workspace=${this.workspace.uuid}`),
|
||||
// TODO storage URL
|
||||
concatLink(this.getBranding()?.front ?? config.FrontURL, `/files/${this.workspace.uuid}/`),
|
||||
preprocessor
|
||||
preprocessor ??
|
||||
(async (nodes) => {
|
||||
appendGuestLinkToImage(nodes, this.workspace.uuid)
|
||||
})
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user