diff --git a/packages/client/index.ts b/packages/client/index.ts index d2535b1..624662f 100644 --- a/packages/client/index.ts +++ b/packages/client/index.ts @@ -1,3 +1,11 @@ +/** + * @module + * LINE SelfBot Client + */ + +/** + * @description LINE SelfBot Client + */ export class Client { constructor() { throw new Error("not impl") diff --git a/packages/utils/obs/index.ts b/packages/utils/obs/index.ts index 36433e8..68a8052 100644 --- a/packages/utils/obs/index.ts +++ b/packages/utils/obs/index.ts @@ -3,7 +3,7 @@ * Utility for LINE OBS */ -import { ALL_STRING, WEB_SCHEME_PREFIX } from "../common/types.ts"; +import type { ALL_STRING, WEB_SCHEME_PREFIX } from "../common/types.ts"; type LINE_OBS_PREFIX = | "obs://" @@ -12,19 +12,34 @@ type LINE_OBS_PREFIX = | WEB_SCHEME_PREFIX<"obs.line-apps.com/"> | ALL_STRING; +/** + * @description LINE Obs Utility + */ class LINE_OBS_BASE { constructor( public prefix: LINE_OBS_PREFIX = "obs://", ) {} + /** + * @param hash {string} obs hash + * @returns line-obs url + */ public createURI(hash: string): string { return this.prefix + hash; } + /** + * @param mid {string} user mid + * @returns line-obs profile-image url + */ public createProfileImage(mid: string): string { return this.prefix + "os/p/" + mid; } + /** + * @param gid {string} group id + * @returns line-obs group-image url + */ public createGroupImage(gid: string): string { return this.prefix + "os/g/" + gid; } diff --git a/packages/utils/scheme/index.ts b/packages/utils/scheme/index.ts index 1b72240..7e92c58 100644 --- a/packages/utils/scheme/index.ts +++ b/packages/utils/scheme/index.ts @@ -3,7 +3,7 @@ * Utility for LINE Scheme URI */ -import { ALL_STRING, WEB_SCHEME_PREFIX } from "../common/types.ts"; +import type { ALL_STRING, WEB_SCHEME_PREFIX } from "../common/types.ts"; type LINE_SCHEME_PREFIX = | "line://" @@ -11,15 +11,24 @@ type LINE_SCHEME_PREFIX = | WEB_SCHEME_PREFIX<"line.naver.jp/R/"> | ALL_STRING; +/** + * @description LINE Scheme Utility + */ class LINE_SCHEME_BASE { constructor( public prefix: LINE_SCHEME_PREFIX = "line://", ) {} + /** + * @returns home url + */ public getHome(): string { return this.prefix + "home"; } + /** + * @returns user profile setting url + */ public getProfile(): string { return this.prefix + "profile"; }