forked from goplus/builder
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* project publish * adjust thumbnail generation
- Loading branch information
Showing
24 changed files
with
531 additions
and
111 deletions.
There are no files selected for viewing
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 |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import { client, type FileCollection } from './common' | ||
|
||
export type ProjectRelease = { | ||
/** Unique identifier */ | ||
id: string | ||
/** Creation timestamp */ | ||
createdAt: string | ||
/** Last update timestamp */ | ||
updatedAt: string | ||
/** Full name of the project, in the format `owner/project`. */ | ||
projectFullName: string | ||
/** Unique name of the project release, adhering to [Semantic Versioning 2.0.0](https://semver.org/spec/v2.0.0.html). */ | ||
name: string | ||
/** rief description of the release. */ | ||
description: string | ||
/** File paths and their corresponding universal URLs associated with the release. */ | ||
files: FileCollection | ||
/** Universal URL of the release's thumbnail image. */ | ||
thumbnail: string | ||
/** Number of times the release has been remixed. */ | ||
remixCount: number | ||
} | ||
|
||
export type CreateReleaseParams = Pick< | ||
ProjectRelease, | ||
'projectFullName' | 'name' | 'description' | 'thumbnail' | ||
> | ||
|
||
export function createRelease(params: CreateReleaseParams) { | ||
return client.post('/project-release', params) as Promise<ProjectRelease> | ||
} |
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.
File renamed without changes
File renamed without changes
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
Oops, something went wrong.