@spfn/cms 0.1.0-alpha.5 → 0.1.0-alpha.60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/actions.d.ts +140 -6
- package/dist/actions.js +97 -10
- package/dist/actions.js.map +1 -1
- package/dist/client.d.ts +43 -9
- package/dist/client.js +406 -56
- package/dist/client.js.map +1 -1
- package/dist/contracts/labels.d.ts +149 -0
- package/dist/contracts/labels.js +166 -0
- package/dist/contracts/labels.js.map +1 -0
- package/dist/contracts/published-cache.d.ts +25 -0
- package/dist/contracts/published-cache.js +32 -0
- package/dist/contracts/published-cache.js.map +1 -0
- package/dist/contracts/values.d.ts +69 -0
- package/dist/contracts/values.js +100 -0
- package/dist/contracts/values.js.map +1 -0
- package/dist/entities/cms-audit-logs.d.ts +15 -70
- package/dist/entities/cms-audit-logs.js +75 -100
- package/dist/entities/cms-audit-logs.js.map +1 -1
- package/dist/entities/cms-draft-cache.d.ts +13 -73
- package/dist/entities/cms-draft-cache.js +35 -109
- package/dist/entities/cms-draft-cache.js.map +1 -1
- package/dist/entities/cms-label-values.d.ts +14 -65
- package/dist/entities/cms-label-values.js +78 -102
- package/dist/entities/cms-label-values.js.map +1 -1
- package/dist/entities/cms-label-versions.d.ts +16 -49
- package/dist/entities/cms-label-versions.js +73 -77
- package/dist/entities/cms-label-versions.js.map +1 -1
- package/dist/entities/cms-labels.d.ts +17 -14
- package/dist/entities/cms-labels.js +39 -45
- package/dist/entities/cms-labels.js.map +1 -1
- package/dist/entities/cms-published-cache.d.ts +14 -69
- package/dist/entities/cms-published-cache.js +33 -100
- package/dist/entities/cms-published-cache.js.map +1 -1
- package/dist/entities/index.d.ts +7 -10
- package/dist/entities/index.js +217 -9
- package/dist/entities/index.js.map +1 -1
- package/dist/generators/index.d.ts +8 -7
- package/dist/generators/index.js +657 -17
- package/dist/generators/index.js.map +1 -1
- package/dist/index.d.ts +134 -20
- package/dist/index.js +1115 -23
- package/dist/index.js.map +1 -1
- package/dist/{generators/label-sync-generator.d.ts → label-sync-generator-lQrcVfja.d.ts} +9 -6
- package/dist/labels/index.d.ts +31 -4
- package/dist/labels/index.js +31 -6
- package/dist/labels/index.js.map +1 -1
- package/dist/repositories/index.d.ts +205 -6
- package/dist/repositories/index.js +435 -8
- package/dist/repositories/index.js.map +1 -1
- package/dist/routes/labels/[id]/index.js +499 -89
- package/dist/routes/labels/[id]/index.js.map +1 -1
- package/dist/routes/labels/{[id] → _id_}/index.d.ts +5 -3
- package/dist/routes/labels/by-key/[key]/index.js +453 -29
- package/dist/routes/labels/by-key/[key]/index.js.map +1 -1
- package/dist/routes/labels/by-key/_key_/index.d.ts +10 -0
- package/dist/routes/labels/index.d.ts +5 -3
- package/dist/routes/labels/index.js +488 -68
- package/dist/routes/labels/index.js.map +1 -1
- package/dist/routes/published-cache/index.d.ts +5 -3
- package/dist/routes/published-cache/index.js +325 -30
- package/dist/routes/published-cache/index.js.map +1 -1
- package/dist/routes/values/[labelId]/[version]/index.js +467 -41
- package/dist/routes/values/[labelId]/[version]/index.js.map +1 -1
- package/dist/routes/values/[labelId]/index.js +463 -39
- package/dist/routes/values/[labelId]/index.js.map +1 -1
- package/dist/routes/values/_labelId_/_version_/index.d.ts +10 -0
- package/dist/routes/values/_labelId_/index.d.ts +10 -0
- package/dist/server.d.ts +17 -7
- package/dist/server.js +263 -244
- package/dist/server.js.map +1 -1
- package/dist/store.d.ts +8 -14
- package/dist/store.js +396 -198
- package/dist/store.js.map +1 -1
- package/dist/types.d.ts +14 -7
- package/dist/types.js +0 -6
- package/dist/types.js.map +1 -1
- package/migrations/0000_condemned_centennial.sql +89 -0
- package/migrations/meta/0000_snapshot.json +687 -0
- package/migrations/meta/_journal.json +13 -0
- package/package.json +33 -16
- package/dist/actions.d.ts.map +0 -1
- package/dist/client.d.ts.map +0 -1
- package/dist/cms.config.d.ts +0 -77
- package/dist/cms.config.d.ts.map +0 -1
- package/dist/cms.config.js +0 -111
- package/dist/cms.config.js.map +0 -1
- package/dist/entities/cms-audit-logs.d.ts.map +0 -1
- package/dist/entities/cms-draft-cache.d.ts.map +0 -1
- package/dist/entities/cms-label-values.d.ts.map +0 -1
- package/dist/entities/cms-label-versions.d.ts.map +0 -1
- package/dist/entities/cms-labels.d.ts.map +0 -1
- package/dist/entities/cms-published-cache.d.ts.map +0 -1
- package/dist/entities/index.d.ts.map +0 -1
- package/dist/generators/index.d.ts.map +0 -1
- package/dist/generators/label-sync-generator.d.ts.map +0 -1
- package/dist/generators/label-sync-generator.js +0 -87
- package/dist/generators/label-sync-generator.js.map +0 -1
- package/dist/helpers/locale.actions.d.ts +0 -132
- package/dist/helpers/locale.actions.d.ts.map +0 -1
- package/dist/helpers/locale.actions.js +0 -210
- package/dist/helpers/locale.actions.js.map +0 -1
- package/dist/helpers/locale.constants.d.ts +0 -10
- package/dist/helpers/locale.constants.d.ts.map +0 -1
- package/dist/helpers/locale.constants.js +0 -10
- package/dist/helpers/locale.constants.js.map +0 -1
- package/dist/helpers/locale.d.ts +0 -17
- package/dist/helpers/locale.d.ts.map +0 -1
- package/dist/helpers/locale.js +0 -20
- package/dist/helpers/locale.js.map +0 -1
- package/dist/helpers/sync.d.ts +0 -41
- package/dist/helpers/sync.d.ts.map +0 -1
- package/dist/helpers/sync.js +0 -309
- package/dist/helpers/sync.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/init.d.ts +0 -31
- package/dist/init.d.ts.map +0 -1
- package/dist/init.js +0 -36
- package/dist/init.js.map +0 -1
- package/dist/labels/helpers.d.ts +0 -31
- package/dist/labels/helpers.d.ts.map +0 -1
- package/dist/labels/helpers.js +0 -60
- package/dist/labels/helpers.js.map +0 -1
- package/dist/labels/index.d.ts.map +0 -1
- package/dist/repositories/cms-draft-cache.repository.d.ts +0 -62
- package/dist/repositories/cms-draft-cache.repository.d.ts.map +0 -1
- package/dist/repositories/cms-draft-cache.repository.js +0 -56
- package/dist/repositories/cms-draft-cache.repository.js.map +0 -1
- package/dist/repositories/cms-label-values.repository.d.ts +0 -32
- package/dist/repositories/cms-label-values.repository.d.ts.map +0 -1
- package/dist/repositories/cms-label-values.repository.js +0 -72
- package/dist/repositories/cms-label-values.repository.js.map +0 -1
- package/dist/repositories/cms-labels.repository.d.ts +0 -53
- package/dist/repositories/cms-labels.repository.d.ts.map +0 -1
- package/dist/repositories/cms-labels.repository.js +0 -77
- package/dist/repositories/cms-labels.repository.js.map +0 -1
- package/dist/repositories/cms-published-cache.repository.d.ts +0 -53
- package/dist/repositories/cms-published-cache.repository.d.ts.map +0 -1
- package/dist/repositories/cms-published-cache.repository.js +0 -54
- package/dist/repositories/cms-published-cache.repository.js.map +0 -1
- package/dist/repositories/index.d.ts.map +0 -1
- package/dist/routes/labels/[id]/contract.d.ts +0 -68
- package/dist/routes/labels/[id]/contract.d.ts.map +0 -1
- package/dist/routes/labels/[id]/contract.js +0 -84
- package/dist/routes/labels/[id]/contract.js.map +0 -1
- package/dist/routes/labels/[id]/index.d.ts.map +0 -1
- package/dist/routes/labels/by-key/[key]/contract.d.ts +0 -24
- package/dist/routes/labels/by-key/[key]/contract.d.ts.map +0 -1
- package/dist/routes/labels/by-key/[key]/contract.js +0 -28
- package/dist/routes/labels/by-key/[key]/contract.js.map +0 -1
- package/dist/routes/labels/by-key/[key]/index.d.ts +0 -8
- package/dist/routes/labels/by-key/[key]/index.d.ts.map +0 -1
- package/dist/routes/labels/contract.d.ts +0 -59
- package/dist/routes/labels/contract.d.ts.map +0 -1
- package/dist/routes/labels/contract.js +0 -75
- package/dist/routes/labels/contract.js.map +0 -1
- package/dist/routes/labels/index.d.ts.map +0 -1
- package/dist/routes/published-cache/contract.d.ts +0 -25
- package/dist/routes/published-cache/contract.d.ts.map +0 -1
- package/dist/routes/published-cache/contract.js +0 -35
- package/dist/routes/published-cache/contract.js.map +0 -1
- package/dist/routes/published-cache/index.d.ts.map +0 -1
- package/dist/routes/values/[labelId]/[version]/contract.d.ts +0 -29
- package/dist/routes/values/[labelId]/[version]/contract.d.ts.map +0 -1
- package/dist/routes/values/[labelId]/[version]/contract.js +0 -33
- package/dist/routes/values/[labelId]/[version]/contract.js.map +0 -1
- package/dist/routes/values/[labelId]/[version]/index.d.ts +0 -8
- package/dist/routes/values/[labelId]/[version]/index.d.ts.map +0 -1
- package/dist/routes/values/[labelId]/contract.d.ts +0 -38
- package/dist/routes/values/[labelId]/contract.d.ts.map +0 -1
- package/dist/routes/values/[labelId]/contract.js +0 -59
- package/dist/routes/values/[labelId]/contract.js.map +0 -1
- package/dist/routes/values/[labelId]/index.d.ts +0 -8
- package/dist/routes/values/[labelId]/index.d.ts.map +0 -1
- package/dist/server.d.ts.map +0 -1
- package/dist/store.d.ts.map +0 -1
- package/dist/types.d.ts.map +0 -1
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CMS Published Cache Repository
|
|
3
|
-
*
|
|
4
|
-
* 발행된 콘텐츠 캐시 관리 (초고속 조회)
|
|
5
|
-
*/
|
|
6
|
-
import { findOne, findMany, deleteOne, deleteMany, upsert as upsertHelper } from '@spfn/core/db';
|
|
7
|
-
import { eq, and, sql } from 'drizzle-orm';
|
|
8
|
-
import { cmsPublishedCache } from '../entities/index.js';
|
|
9
|
-
/**
|
|
10
|
-
* 섹션 + 언어로 발행된 캐시 조회
|
|
11
|
-
*/
|
|
12
|
-
export async function findBySection(section, locale = 'ko') {
|
|
13
|
-
return findOne(cmsPublishedCache, and(eq(cmsPublishedCache.section, section), eq(cmsPublishedCache.locale, locale)));
|
|
14
|
-
}
|
|
15
|
-
/**
|
|
16
|
-
* 캐시 생성 또는 업데이트 (UPSERT)
|
|
17
|
-
*/
|
|
18
|
-
export async function upsert(data) {
|
|
19
|
-
return upsertHelper(cmsPublishedCache, data, {
|
|
20
|
-
target: [cmsPublishedCache.section, cmsPublishedCache.locale],
|
|
21
|
-
set: {
|
|
22
|
-
content: data.content,
|
|
23
|
-
publishedAt: data.publishedAt,
|
|
24
|
-
publishedBy: data.publishedBy,
|
|
25
|
-
version: sql `${cmsPublishedCache.version} + 1`, // 버전 증가로 클라이언트 캐시 무효화
|
|
26
|
-
}
|
|
27
|
-
});
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* 섹션별 모든 언어 캐시 조회
|
|
31
|
-
*/
|
|
32
|
-
export async function findAllLanguages(section) {
|
|
33
|
-
return findMany(cmsPublishedCache, {
|
|
34
|
-
where: eq(cmsPublishedCache.section, section)
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* 캐시 삭제
|
|
39
|
-
*/
|
|
40
|
-
export async function deleteBySection(section, locale) {
|
|
41
|
-
if (locale) {
|
|
42
|
-
await deleteOne(cmsPublishedCache, and(eq(cmsPublishedCache.section, section), eq(cmsPublishedCache.locale, locale)));
|
|
43
|
-
}
|
|
44
|
-
else {
|
|
45
|
-
await deleteMany(cmsPublishedCache, eq(cmsPublishedCache.section, section));
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
export const cmsPublishedCacheRepository = {
|
|
49
|
-
findBySection,
|
|
50
|
-
upsert,
|
|
51
|
-
findAllLanguages,
|
|
52
|
-
deleteBySection,
|
|
53
|
-
};
|
|
54
|
-
//# sourceMappingURL=cms-published-cache.repository.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cms-published-cache.repository.js","sourceRoot":"","sources":["../../src/repositories/cms-published-cache.repository.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,IAAI,YAAY,EAAE,MAAM,eAAe,CAAC;AACjG,OAAO,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,EAAE,iBAAiB,EAA6B,MAAM,sBAAsB,CAAC;AAEpF;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,aAAa,CAAC,OAAe,EAAE,SAAi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CAAC;AAED,MAAM,CAAC,MAAM,2BAA2B,GAAG;IACvC,aAAa;IACb,MAAM;IACN,gBAAgB;IAChB,eAAe;CAClB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/repositories/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AACjE,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAC;AAC1E,OAAO,EAAE,2BAA2B,EAAE,MAAM,qCAAqC,CAAC"}
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CMS Label Detail Contracts
|
|
3
|
-
*/
|
|
4
|
-
/**
|
|
5
|
-
* GET /cms/labels/:id - 라벨 단건 조회
|
|
6
|
-
*/
|
|
7
|
-
export declare const getLabelContract: {
|
|
8
|
-
readonly method: "GET";
|
|
9
|
-
readonly path: "/:id";
|
|
10
|
-
readonly params: import("@sinclair/typebox").TObject<{
|
|
11
|
-
id: import("@sinclair/typebox").TString;
|
|
12
|
-
}>;
|
|
13
|
-
readonly response: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
|
|
14
|
-
id: import("@sinclair/typebox").TNumber;
|
|
15
|
-
key: import("@sinclair/typebox").TString;
|
|
16
|
-
section: import("@sinclair/typebox").TString;
|
|
17
|
-
type: import("@sinclair/typebox").TString;
|
|
18
|
-
publishedVersion: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TNumber, import("@sinclair/typebox").TNull]>;
|
|
19
|
-
createdBy: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNull]>;
|
|
20
|
-
createdAt: import("@sinclair/typebox").TString;
|
|
21
|
-
updatedAt: import("@sinclair/typebox").TString;
|
|
22
|
-
}>, import("@sinclair/typebox").TObject<{
|
|
23
|
-
error: import("@sinclair/typebox").TString;
|
|
24
|
-
}>]>;
|
|
25
|
-
};
|
|
26
|
-
/**
|
|
27
|
-
* PATCH /cms/labels/:id - 라벨 메타데이터 수정
|
|
28
|
-
*/
|
|
29
|
-
export declare const updateLabelContract: {
|
|
30
|
-
readonly method: "PATCH";
|
|
31
|
-
readonly path: "/:id";
|
|
32
|
-
readonly params: import("@sinclair/typebox").TObject<{
|
|
33
|
-
id: import("@sinclair/typebox").TString;
|
|
34
|
-
}>;
|
|
35
|
-
readonly body: import("@sinclair/typebox").TObject<{
|
|
36
|
-
section: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
37
|
-
type: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"text">, import("@sinclair/typebox").TLiteral<"image">, import("@sinclair/typebox").TLiteral<"video">, import("@sinclair/typebox").TLiteral<"file">, import("@sinclair/typebox").TLiteral<"object">]>>;
|
|
38
|
-
}>;
|
|
39
|
-
readonly response: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
|
|
40
|
-
id: import("@sinclair/typebox").TNumber;
|
|
41
|
-
key: import("@sinclair/typebox").TString;
|
|
42
|
-
section: import("@sinclair/typebox").TString;
|
|
43
|
-
type: import("@sinclair/typebox").TString;
|
|
44
|
-
publishedVersion: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TNumber, import("@sinclair/typebox").TNull]>;
|
|
45
|
-
createdBy: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNull]>;
|
|
46
|
-
createdAt: import("@sinclair/typebox").TString;
|
|
47
|
-
updatedAt: import("@sinclair/typebox").TString;
|
|
48
|
-
}>, import("@sinclair/typebox").TObject<{
|
|
49
|
-
error: import("@sinclair/typebox").TString;
|
|
50
|
-
}>]>;
|
|
51
|
-
};
|
|
52
|
-
/**
|
|
53
|
-
* DELETE /cms/labels/:id - 라벨 삭제
|
|
54
|
-
*/
|
|
55
|
-
export declare const deleteLabelContract: {
|
|
56
|
-
readonly method: "DELETE";
|
|
57
|
-
readonly path: "/:id";
|
|
58
|
-
readonly params: import("@sinclair/typebox").TObject<{
|
|
59
|
-
id: import("@sinclair/typebox").TString;
|
|
60
|
-
}>;
|
|
61
|
-
readonly response: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
|
|
62
|
-
success: import("@sinclair/typebox").TBoolean;
|
|
63
|
-
id: import("@sinclair/typebox").TNumber;
|
|
64
|
-
}>, import("@sinclair/typebox").TObject<{
|
|
65
|
-
error: import("@sinclair/typebox").TString;
|
|
66
|
-
}>]>;
|
|
67
|
-
};
|
|
68
|
-
//# sourceMappingURL=contract.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.d.ts","sourceRoot":"","sources":["../../../../src/routes/labels/[id]/contract.ts"],"names":[],"mappings":"AAGA;;GAEG;AAEH;;GAEG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;CAqBK,CAAC;AAEnC;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;CA+BE,CAAC;AAEnC;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;CAeE,CAAC"}
|
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
import { Type } from '@sinclair/typebox';
|
|
2
|
-
/**
|
|
3
|
-
* CMS Label Detail Contracts
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* GET /cms/labels/:id - 라벨 단건 조회
|
|
7
|
-
*/
|
|
8
|
-
export const getLabelContract = {
|
|
9
|
-
method: 'GET',
|
|
10
|
-
path: '/:id',
|
|
11
|
-
params: Type.Object({
|
|
12
|
-
id: Type.String({ description: '라벨 ID' })
|
|
13
|
-
}),
|
|
14
|
-
response: Type.Union([
|
|
15
|
-
Type.Object({
|
|
16
|
-
id: Type.Number(),
|
|
17
|
-
key: Type.String(),
|
|
18
|
-
section: Type.String(),
|
|
19
|
-
type: Type.String(),
|
|
20
|
-
publishedVersion: Type.Union([Type.Number(), Type.Null()]),
|
|
21
|
-
createdBy: Type.Union([Type.String(), Type.Null()]),
|
|
22
|
-
createdAt: Type.String(),
|
|
23
|
-
updatedAt: Type.String()
|
|
24
|
-
}),
|
|
25
|
-
Type.Object({
|
|
26
|
-
error: Type.String()
|
|
27
|
-
})
|
|
28
|
-
])
|
|
29
|
-
};
|
|
30
|
-
/**
|
|
31
|
-
* PATCH /cms/labels/:id - 라벨 메타데이터 수정
|
|
32
|
-
*/
|
|
33
|
-
export const updateLabelContract = {
|
|
34
|
-
method: 'PATCH',
|
|
35
|
-
path: '/:id',
|
|
36
|
-
params: Type.Object({
|
|
37
|
-
id: Type.String({ description: '라벨 ID' })
|
|
38
|
-
}),
|
|
39
|
-
body: Type.Object({
|
|
40
|
-
section: Type.Optional(Type.String({ description: '섹션 변경' })),
|
|
41
|
-
type: Type.Optional(Type.Union([
|
|
42
|
-
Type.Literal('text'),
|
|
43
|
-
Type.Literal('image'),
|
|
44
|
-
Type.Literal('video'),
|
|
45
|
-
Type.Literal('file'),
|
|
46
|
-
Type.Literal('object')
|
|
47
|
-
]))
|
|
48
|
-
}),
|
|
49
|
-
response: Type.Union([
|
|
50
|
-
Type.Object({
|
|
51
|
-
id: Type.Number(),
|
|
52
|
-
key: Type.String(),
|
|
53
|
-
section: Type.String(),
|
|
54
|
-
type: Type.String(),
|
|
55
|
-
publishedVersion: Type.Union([Type.Number(), Type.Null()]),
|
|
56
|
-
createdBy: Type.Union([Type.String(), Type.Null()]),
|
|
57
|
-
createdAt: Type.String(),
|
|
58
|
-
updatedAt: Type.String()
|
|
59
|
-
}),
|
|
60
|
-
Type.Object({
|
|
61
|
-
error: Type.String()
|
|
62
|
-
})
|
|
63
|
-
])
|
|
64
|
-
};
|
|
65
|
-
/**
|
|
66
|
-
* DELETE /cms/labels/:id - 라벨 삭제
|
|
67
|
-
*/
|
|
68
|
-
export const deleteLabelContract = {
|
|
69
|
-
method: 'DELETE',
|
|
70
|
-
path: '/:id',
|
|
71
|
-
params: Type.Object({
|
|
72
|
-
id: Type.String({ description: '라벨 ID' })
|
|
73
|
-
}),
|
|
74
|
-
response: Type.Union([
|
|
75
|
-
Type.Object({
|
|
76
|
-
success: Type.Boolean(),
|
|
77
|
-
id: Type.Number()
|
|
78
|
-
}),
|
|
79
|
-
Type.Object({
|
|
80
|
-
error: Type.String()
|
|
81
|
-
})
|
|
82
|
-
])
|
|
83
|
-
};
|
|
84
|
-
//# sourceMappingURL=contract.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.js","sourceRoot":"","sources":["../../../../src/routes/labels/[id]/contract.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAGzC;;GAEG;AAEH;;GAEG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC5B,MAAM,EAAE,KAAc;IACtB,IAAI,EAAE,MAAM;IACZ,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC;QAChB,EAAE,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC;KAC5C,CAAC;IACF,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC;QACjB,IAAI,CAAC,MAAM,CAAC;YACR,EAAE,EAAE,IAAI,CAAC,MAAM,EAAE;YACjB,GAAG,EAAE,IAAI,CAAC,MAAM,EAAE;YAClB,OAAO,EAAE,IAAI,CAAC,MAAM,EAAE;YACtB,IAAI,EAAE,IAAI,CAAC,MAAM,EAAE;YACnB,gBAAgB,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;YAC1D,SAAS,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,IAA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,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;YAC1D,SAAS,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;YACnD,SAAS,EAAE,IAAI,CAAC,MAAM,EAAE;YACxB,SAAS,EAAE,IAAI,CAAC,MAAM,EAAE;SAC3B,CAAC;QACF,IAAI,CAAC,MAAM,CAAC;YACR,KAAK,EAAE,IAAI,CAAC,MAAM,EAAE;SACvB,CAAC;KACL,CAAC;CAC4B,CAAC;AAEnC;;GAEG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG;IAC/B,MAAM,EAAE,QAAiB;IACzB,IAAI,EAAE,MAAM;IACZ,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC;QAChB,EAAE,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC;KAC5C,CAAC;IACF,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC;QACjB,IAAI,CAAC,MAAM,CAAC;YACR,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE;YACvB,EAAE,EAAE,IAAI,CAAC,MAAM,EAAE;SACpB,CAAC;QACF,IAAI,CAAC,MAAM,CAAC;YACR,KAAK,EAAE,IAAI,CAAC,MAAM,EAAE;SACvB,CAAC;KACL,CAAC;CAC4B,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/routes/labels/[id]/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAWH,QAAA,MAAM,GAAG,oCAAc,CAAC;AAiHxB,eAAe,GAAG,CAAC"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* GET /cms/labels/by-key/:key - Key로 라벨 조회
|
|
3
|
-
*/
|
|
4
|
-
export declare const getLabelByKeyContract: {
|
|
5
|
-
readonly method: "GET";
|
|
6
|
-
readonly path: "/:key";
|
|
7
|
-
readonly params: import("@sinclair/typebox").TObject<{
|
|
8
|
-
key: import("@sinclair/typebox").TString;
|
|
9
|
-
}>;
|
|
10
|
-
readonly response: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
|
|
11
|
-
id: import("@sinclair/typebox").TNumber;
|
|
12
|
-
key: import("@sinclair/typebox").TString;
|
|
13
|
-
section: import("@sinclair/typebox").TString;
|
|
14
|
-
type: import("@sinclair/typebox").TString;
|
|
15
|
-
publishedVersion: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TNumber, import("@sinclair/typebox").TNull]>;
|
|
16
|
-
createdBy: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNull]>;
|
|
17
|
-
createdAt: import("@sinclair/typebox").TString;
|
|
18
|
-
updatedAt: import("@sinclair/typebox").TString;
|
|
19
|
-
}>, import("@sinclair/typebox").TObject<{
|
|
20
|
-
error: import("@sinclair/typebox").TString;
|
|
21
|
-
key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
22
|
-
}>]>;
|
|
23
|
-
};
|
|
24
|
-
//# sourceMappingURL=contract.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.d.ts","sourceRoot":"","sources":["../../../../../src/routes/labels/by-key/[key]/contract.ts"],"names":[],"mappings":"AAGA;;GAEG;AACH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;CAsBA,CAAC"}
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import { Type } from '@sinclair/typebox';
|
|
2
|
-
/**
|
|
3
|
-
* GET /cms/labels/by-key/:key - Key로 라벨 조회
|
|
4
|
-
*/
|
|
5
|
-
export const getLabelByKeyContract = {
|
|
6
|
-
method: 'GET',
|
|
7
|
-
path: '/:key',
|
|
8
|
-
params: Type.Object({
|
|
9
|
-
key: Type.String({ description: '라벨 Key (예: home.hero.title)' })
|
|
10
|
-
}),
|
|
11
|
-
response: Type.Union([
|
|
12
|
-
Type.Object({
|
|
13
|
-
id: Type.Number(),
|
|
14
|
-
key: Type.String(),
|
|
15
|
-
section: Type.String(),
|
|
16
|
-
type: Type.String(),
|
|
17
|
-
publishedVersion: Type.Union([Type.Number(), Type.Null()]),
|
|
18
|
-
createdBy: Type.Union([Type.String(), Type.Null()]),
|
|
19
|
-
createdAt: Type.String(),
|
|
20
|
-
updatedAt: Type.String()
|
|
21
|
-
}),
|
|
22
|
-
Type.Object({
|
|
23
|
-
error: Type.String(),
|
|
24
|
-
key: Type.Optional(Type.String())
|
|
25
|
-
})
|
|
26
|
-
])
|
|
27
|
-
};
|
|
28
|
-
//# sourceMappingURL=contract.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.js","sourceRoot":"","sources":["../../../../../src/routes/labels/by-key/[key]/contract.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAGzC;;GAEG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACjC,MAAM,EAAE,KAAc;IACtB,IAAI,EAAE,OAAO;IACb,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC;QAChB,GAAG,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,6BAA6B,EAAE,CAAC;KACnE,CAAC;IACF,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC;QACjB,IAAI,CAAC,MAAM,CAAC;YACR,EAAE,EAAE,IAAI,CAAC,MAAM,EAAE;YACjB,GAAG,EAAE,IAAI,CAAC,MAAM,EAAE;YAClB,OAAO,EAAE,IAAI,CAAC,MAAM,EAAE;YACtB,IAAI,EAAE,IAAI,CAAC,MAAM,EAAE;YACnB,gBAAgB,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;YAC1D,SAAS,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;YACnD,SAAS,EAAE,IAAI,CAAC,MAAM,EAAE;YACxB,SAAS,EAAE,IAAI,CAAC,MAAM,EAAE;SAC3B,CAAC;QACF,IAAI,CAAC,MAAM,CAAC;YACR,KAAK,EAAE,IAAI,CAAC,MAAM,EAAE;YACpB,GAAG,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC;SACpC,CAAC;KACL,CAAC;CAC4B,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/routes/labels/by-key/[key]/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAMH,QAAA,MAAM,GAAG,oCAAc,CAAC;AA6BxB,eAAe,GAAG,CAAC"}
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CMS Labels Contracts
|
|
3
|
-
*
|
|
4
|
-
* 라벨 메타데이터 관리 API
|
|
5
|
-
*/
|
|
6
|
-
/**
|
|
7
|
-
* GET /cms/labels - 라벨 목록 조회
|
|
8
|
-
*/
|
|
9
|
-
export declare const getLabelsContract: {
|
|
10
|
-
readonly method: "GET";
|
|
11
|
-
readonly path: "/";
|
|
12
|
-
readonly query: import("@sinclair/typebox").TObject<{
|
|
13
|
-
section: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
14
|
-
limit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
|
|
15
|
-
offset: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
|
|
16
|
-
}>;
|
|
17
|
-
readonly response: import("@sinclair/typebox").TObject<{
|
|
18
|
-
labels: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
|
|
19
|
-
id: import("@sinclair/typebox").TNumber;
|
|
20
|
-
key: import("@sinclair/typebox").TString;
|
|
21
|
-
section: import("@sinclair/typebox").TString;
|
|
22
|
-
type: import("@sinclair/typebox").TString;
|
|
23
|
-
publishedVersion: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TNumber, import("@sinclair/typebox").TNull]>;
|
|
24
|
-
createdBy: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNull]>;
|
|
25
|
-
createdAt: import("@sinclair/typebox").TString;
|
|
26
|
-
updatedAt: import("@sinclair/typebox").TString;
|
|
27
|
-
}>>;
|
|
28
|
-
total: import("@sinclair/typebox").TNumber;
|
|
29
|
-
limit: import("@sinclair/typebox").TNumber;
|
|
30
|
-
offset: import("@sinclair/typebox").TNumber;
|
|
31
|
-
}>;
|
|
32
|
-
};
|
|
33
|
-
/**
|
|
34
|
-
* POST /cms/labels - 새 라벨 생성
|
|
35
|
-
*/
|
|
36
|
-
export declare const createLabelContract: {
|
|
37
|
-
readonly method: "POST";
|
|
38
|
-
readonly path: "/";
|
|
39
|
-
readonly body: import("@sinclair/typebox").TObject<{
|
|
40
|
-
key: import("@sinclair/typebox").TString;
|
|
41
|
-
section: import("@sinclair/typebox").TString;
|
|
42
|
-
type: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"text">, import("@sinclair/typebox").TLiteral<"image">, import("@sinclair/typebox").TLiteral<"video">, import("@sinclair/typebox").TLiteral<"file">, import("@sinclair/typebox").TLiteral<"object">]>;
|
|
43
|
-
createdBy: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
44
|
-
}>;
|
|
45
|
-
readonly response: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
|
|
46
|
-
id: import("@sinclair/typebox").TNumber;
|
|
47
|
-
key: import("@sinclair/typebox").TString;
|
|
48
|
-
section: import("@sinclair/typebox").TString;
|
|
49
|
-
type: import("@sinclair/typebox").TString;
|
|
50
|
-
publishedVersion: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TNumber, import("@sinclair/typebox").TNull]>;
|
|
51
|
-
createdBy: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNull]>;
|
|
52
|
-
createdAt: import("@sinclair/typebox").TString;
|
|
53
|
-
updatedAt: import("@sinclair/typebox").TString;
|
|
54
|
-
}>, import("@sinclair/typebox").TObject<{
|
|
55
|
-
error: import("@sinclair/typebox").TString;
|
|
56
|
-
key: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
57
|
-
}>]>;
|
|
58
|
-
};
|
|
59
|
-
//# sourceMappingURL=contract.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.d.ts","sourceRoot":"","sources":["../../../src/routes/labels/contract.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AAEH;;GAEG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;CAuBI,CAAC;AAEnC;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;CAqCE,CAAC"}
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
import { Type } from '@sinclair/typebox';
|
|
2
|
-
/**
|
|
3
|
-
* CMS Labels Contracts
|
|
4
|
-
*
|
|
5
|
-
* 라벨 메타데이터 관리 API
|
|
6
|
-
*/
|
|
7
|
-
/**
|
|
8
|
-
* GET /cms/labels - 라벨 목록 조회
|
|
9
|
-
*/
|
|
10
|
-
export const getLabelsContract = {
|
|
11
|
-
method: 'GET',
|
|
12
|
-
path: '/',
|
|
13
|
-
query: Type.Object({
|
|
14
|
-
section: Type.Optional(Type.String({ description: '섹션으로 필터링 (예: home, why-futureplay)' })),
|
|
15
|
-
limit: Type.Optional(Type.Number({ minimum: 1, maximum: 100, default: 20, description: '페이지당 항목 수' })),
|
|
16
|
-
offset: Type.Optional(Type.Number({ minimum: 0, default: 0, description: '시작 오프셋' }))
|
|
17
|
-
}),
|
|
18
|
-
response: Type.Object({
|
|
19
|
-
labels: Type.Array(Type.Object({
|
|
20
|
-
id: Type.Number(),
|
|
21
|
-
key: Type.String(),
|
|
22
|
-
section: Type.String(),
|
|
23
|
-
type: Type.String(),
|
|
24
|
-
publishedVersion: Type.Union([Type.Number(), Type.Null()]),
|
|
25
|
-
createdBy: Type.Union([Type.String(), Type.Null()]),
|
|
26
|
-
createdAt: Type.String(),
|
|
27
|
-
updatedAt: Type.String()
|
|
28
|
-
})),
|
|
29
|
-
total: Type.Number(),
|
|
30
|
-
limit: Type.Number(),
|
|
31
|
-
offset: Type.Number()
|
|
32
|
-
})
|
|
33
|
-
};
|
|
34
|
-
/**
|
|
35
|
-
* POST /cms/labels - 새 라벨 생성
|
|
36
|
-
*/
|
|
37
|
-
export const createLabelContract = {
|
|
38
|
-
method: 'POST',
|
|
39
|
-
path: '/',
|
|
40
|
-
body: Type.Object({
|
|
41
|
-
key: Type.String({
|
|
42
|
-
description: '고유 키 (예: home.hero.title)',
|
|
43
|
-
pattern: '^[a-z0-9-]+\\.[a-z0-9-]+\\.[a-z0-9-]+$'
|
|
44
|
-
}),
|
|
45
|
-
section: Type.String({
|
|
46
|
-
description: '섹션 이름 (예: home, why-futureplay)',
|
|
47
|
-
pattern: '^[a-z0-9-]+$'
|
|
48
|
-
}),
|
|
49
|
-
type: Type.Union([
|
|
50
|
-
Type.Literal('text'),
|
|
51
|
-
Type.Literal('image'),
|
|
52
|
-
Type.Literal('video'),
|
|
53
|
-
Type.Literal('file'),
|
|
54
|
-
Type.Literal('object')
|
|
55
|
-
], { description: '값 타입' }),
|
|
56
|
-
createdBy: Type.Optional(Type.String({ description: '생성자 ID' }))
|
|
57
|
-
}),
|
|
58
|
-
response: Type.Union([
|
|
59
|
-
Type.Object({
|
|
60
|
-
id: Type.Number(),
|
|
61
|
-
key: Type.String(),
|
|
62
|
-
section: Type.String(),
|
|
63
|
-
type: Type.String(),
|
|
64
|
-
publishedVersion: Type.Union([Type.Number(), Type.Null()]),
|
|
65
|
-
createdBy: Type.Union([Type.String(), Type.Null()]),
|
|
66
|
-
createdAt: Type.String(),
|
|
67
|
-
updatedAt: Type.String()
|
|
68
|
-
}),
|
|
69
|
-
Type.Object({
|
|
70
|
-
error: Type.String(),
|
|
71
|
-
key: Type.Optional(Type.String())
|
|
72
|
-
})
|
|
73
|
-
])
|
|
74
|
-
};
|
|
75
|
-
//# sourceMappingURL=contract.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.js","sourceRoot":"","sources":["../../../src/routes/labels/contract.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAGzC;;;;GAIG;AAEH;;GAEG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG;IAC7B,MAAM,EAAE,KAAc;IACtB,IAAI,EAAE,GAAG;IACT,KAAK,EAAE,IAAI,CAAC,MAAM,CAAC;QACf,OAAO,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,oCAAoC,EAAE,CAAC,CAAC;QAC1F,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,EAAE,EAAE,WAAW,EAAE,WAAW,EAAE,CAAC,CAAC;QACtG,MAAM,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,WAAW,EAAE,QAAQ,EAAE,CAAC,CAAC;KACxF,CAAC;IACF,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC;QAClB,MAAM,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC;YAC3B,EAAE,EAAE,IAAI,CAAC,MAAM,EAAE;YACjB,GAAG,EAAE,IAAI,CAAC,MAAM,EAAE;YAClB,OAA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IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,QAAQ,EAAE,CAAC,CAAC;KACnE,CAAC;IACF,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC;QACjB,IAAI,CAAC,MAAM,CAAC;YACR,EAAE,EAAE,IAAI,CAAC,MAAM,EAAE;YACjB,GAAG,EAAE,IAAI,CAAC,MAAM,EAAE;YAClB,OAAO,EAAE,IAAI,CAAC,MAAM,EAAE;YACtB,IAAI,EAAE,IAAI,CAAC,MAAM,EAAE;YACnB,gBAAgB,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;YAC1D,SAAS,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;YACnD,SAAS,EAAE,IAAI,CAAC,MAAM,EAAE;YACxB,SAAS,EAAE,IAAI,CAAC,MAAM,EAAE;SAC3B,CAAC;QACF,IAAI,CAAC,MAAM,CAAC;YACR,KAAK,EAAE,IAAI,CAAC,MAAM,EAAE;YACpB,GAAG,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC;SACpC,CAAC;KACL,CAAC;CAC4B,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/routes/labels/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAOH,QAAA,MAAM,GAAG,oCAAc,CAAC;AA8ExB,eAAe,GAAG,CAAC"}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CMS Published Cache API Contract
|
|
3
|
-
*/
|
|
4
|
-
/**
|
|
5
|
-
* GET /cms/published-cache
|
|
6
|
-
* 발행된 콘텐츠 캐시 조회 (단일 또는 여러 섹션)
|
|
7
|
-
*/
|
|
8
|
-
export declare const getPublishedCacheContract: {
|
|
9
|
-
readonly method: "GET";
|
|
10
|
-
readonly path: "/";
|
|
11
|
-
readonly query: import("@sinclair/typebox").TObject<{
|
|
12
|
-
sections: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>]>;
|
|
13
|
-
locale: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
14
|
-
}>;
|
|
15
|
-
readonly response: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
|
|
16
|
-
section: import("@sinclair/typebox").TString;
|
|
17
|
-
locale: import("@sinclair/typebox").TString;
|
|
18
|
-
content: import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TAny>;
|
|
19
|
-
version: import("@sinclair/typebox").TNumber;
|
|
20
|
-
publishedAt: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNull]>;
|
|
21
|
-
}>>, import("@sinclair/typebox").TObject<{
|
|
22
|
-
error: import("@sinclair/typebox").TString;
|
|
23
|
-
}>]>;
|
|
24
|
-
};
|
|
25
|
-
//# sourceMappingURL=contract.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.d.ts","sourceRoot":"","sources":["../../../src/routes/published-cache/contract.ts"],"names":[],"mappings":"AAAA;;GAEG;AAaH;;;GAGG;AACH,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;CAkBJ,CAAC"}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CMS Published Cache API Contract
|
|
3
|
-
*/
|
|
4
|
-
import { Type } from '@sinclair/typebox';
|
|
5
|
-
const SectionData = Type.Object({
|
|
6
|
-
section: Type.String(),
|
|
7
|
-
locale: Type.String(),
|
|
8
|
-
content: Type.Record(Type.String(), Type.Any()),
|
|
9
|
-
version: Type.Number(),
|
|
10
|
-
publishedAt: Type.Union([Type.String(), Type.Null()]),
|
|
11
|
-
});
|
|
12
|
-
/**
|
|
13
|
-
* GET /cms/published-cache
|
|
14
|
-
* 발행된 콘텐츠 캐시 조회 (단일 또는 여러 섹션)
|
|
15
|
-
*/
|
|
16
|
-
export const getPublishedCacheContract = {
|
|
17
|
-
method: 'GET',
|
|
18
|
-
path: '/',
|
|
19
|
-
query: Type.Object({
|
|
20
|
-
sections: Type.Union([
|
|
21
|
-
Type.String({ description: '단일 섹션 이름 (예: home)' }),
|
|
22
|
-
Type.Array(Type.String(), { description: '여러 섹션 이름 (예: ["home", "footer"])' })
|
|
23
|
-
]),
|
|
24
|
-
locale: Type.Optional(Type.String({ default: 'ko', description: '언어 코드' })),
|
|
25
|
-
}),
|
|
26
|
-
response: Type.Union([
|
|
27
|
-
// 성공: 항상 배열로 반환
|
|
28
|
-
Type.Array(SectionData),
|
|
29
|
-
// 에러
|
|
30
|
-
Type.Object({
|
|
31
|
-
error: Type.String()
|
|
32
|
-
})
|
|
33
|
-
])
|
|
34
|
-
};
|
|
35
|
-
//# sourceMappingURL=contract.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.js","sourceRoot":"","sources":["../../../src/routes/published-cache/contract.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAGzC,MAAM,WAAW,GAAG,IAAI,CAAC,MAAM,CAAC;IAC5B,OAAO,EAAE,IAAI,CAAC,MAAM,EAAE;IACtB,MAAM,EAAE,IAAI,CAAC,MAAM,EAAE;IACrB,OAAO,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,GAAG,EAAE,CAAC;IAC/C,OAAO,EAAE,IAAI,CAAC,MAAM,EAAE;IACtB,WAAW,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;CACxD,CAAC,CAAC;AAEH;;;GAGG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG;IACrC,MAAM,EAAE,KAAc;IACtB,IAAI,EAAE,GAAG;IACT,KAAK,EAAE,IAAI,CAAC,MAAM,CAAC;QACf,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC;YACjB,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,oBAAoB,EAAE,CAAC;YAClD,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,EAAE,EAAE,WAAW,EAAE,kCAAkC,EAAE,CAAC;SACjF,CAAC;QACF,MAAM,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC,CAAC;KAC9E,CAAC;IACF,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC;QACjB,gBAAgB;QAChB,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC;QACvB,KAAK;QACL,IAAI,CAAC,MAAM,CAAC;YACR,KAAK,EAAE,IAAI,CAAC,MAAM,EAAE;SACvB,CAAC;KACL,CAAC;CAC4B,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/routes/published-cache/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAMH,QAAA,MAAM,GAAG,oCAAc,CAAC;AAgCxB,eAAe,GAAG,CAAC"}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* GET /cms/values/:labelId/:version - 특정 버전의 값 조회
|
|
3
|
-
*/
|
|
4
|
-
export declare const getValuesContract: {
|
|
5
|
-
readonly method: "GET";
|
|
6
|
-
readonly path: "/:labelId/:version";
|
|
7
|
-
readonly params: import("@sinclair/typebox").TObject<{
|
|
8
|
-
labelId: import("@sinclair/typebox").TString;
|
|
9
|
-
version: import("@sinclair/typebox").TString;
|
|
10
|
-
}>;
|
|
11
|
-
readonly query: import("@sinclair/typebox").TObject<{
|
|
12
|
-
locale: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
13
|
-
breakpoint: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
14
|
-
}>;
|
|
15
|
-
readonly response: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TObject<{
|
|
16
|
-
labelId: import("@sinclair/typebox").TNumber;
|
|
17
|
-
version: import("@sinclair/typebox").TNumber;
|
|
18
|
-
values: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
|
|
19
|
-
id: import("@sinclair/typebox").TNumber;
|
|
20
|
-
locale: import("@sinclair/typebox").TString;
|
|
21
|
-
breakpoint: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNull]>;
|
|
22
|
-
value: import("@sinclair/typebox").TAny;
|
|
23
|
-
createdAt: import("@sinclair/typebox").TString;
|
|
24
|
-
}>>;
|
|
25
|
-
}>, import("@sinclair/typebox").TObject<{
|
|
26
|
-
error: import("@sinclair/typebox").TString;
|
|
27
|
-
}>]>;
|
|
28
|
-
};
|
|
29
|
-
//# sourceMappingURL=contract.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.d.ts","sourceRoot":"","sources":["../../../../../src/routes/values/[labelId]/[version]/contract.ts"],"names":[],"mappings":"AAGA;;GAEG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;CA6BI,CAAC"}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { Type } from '@sinclair/typebox';
|
|
2
|
-
/**
|
|
3
|
-
* GET /cms/values/:labelId/:version - 특정 버전의 값 조회
|
|
4
|
-
*/
|
|
5
|
-
export const getValuesContract = {
|
|
6
|
-
method: 'GET',
|
|
7
|
-
path: '/:labelId/:version',
|
|
8
|
-
params: Type.Object({
|
|
9
|
-
labelId: Type.String({ description: '라벨 ID' }),
|
|
10
|
-
version: Type.String({ description: '버전 번호' })
|
|
11
|
-
}),
|
|
12
|
-
query: Type.Object({
|
|
13
|
-
locale: Type.Optional(Type.String({ description: '언어 코드 (ko, en, ja)' })),
|
|
14
|
-
breakpoint: Type.Optional(Type.String({ description: '반응형 브레이크포인트' }))
|
|
15
|
-
}),
|
|
16
|
-
response: Type.Union([
|
|
17
|
-
Type.Object({
|
|
18
|
-
labelId: Type.Number(),
|
|
19
|
-
version: Type.Number(),
|
|
20
|
-
values: Type.Array(Type.Object({
|
|
21
|
-
id: Type.Number(),
|
|
22
|
-
locale: Type.String(),
|
|
23
|
-
breakpoint: Type.Union([Type.String(), Type.Null()]),
|
|
24
|
-
value: Type.Any(),
|
|
25
|
-
createdAt: Type.String()
|
|
26
|
-
}))
|
|
27
|
-
}),
|
|
28
|
-
Type.Object({
|
|
29
|
-
error: Type.String()
|
|
30
|
-
})
|
|
31
|
-
])
|
|
32
|
-
};
|
|
33
|
-
//# sourceMappingURL=contract.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.js","sourceRoot":"","sources":["../../../../../src/routes/values/[labelId]/[version]/contract.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAGzC;;GAEG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG;IAC7B,MAAM,EAAE,KAAc;IACtB,IAAI,EAAE,oBAAoB;IAC1B,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC;QAChB,OAAO,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC;QAC9C,OAAO,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC;KACjD,CAAC;IACF,KAAK,EAAE,IAAI,CAAC,MAAM,CAAC;QACf,MAAM,EAAE,IAAI,CAAC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