@roottale/cms-renderer-next 0.42.0 → 0.43.0
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/CHANGELOG.md +24 -0
- package/dist/{chunk-RSNUZ4BF.js → chunk-FKDCPFYV.js} +17 -3
- package/dist/chunk-FKDCPFYV.js.map +1 -0
- package/dist/cms-public.css +11 -4
- package/dist/routes.js +2 -2
- package/dist/routes.js.map +1 -1
- package/dist/server.d.ts +6 -0
- package/dist/server.js +1 -1
- package/dist/templates.js +1 -1
- package/package.json +3 -3
- package/dist/chunk-RSNUZ4BF.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# @roottale/cms-renderer-next
|
|
2
2
|
|
|
3
|
+
## 0.43.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 4ec1a83: 콘텐츠 유형(Collections, ADR-0060)에 `detail?: boolean` 옵션 추가 — 기본 `true`(하위호환), `false`면 "목록 전용" 유형(예: 후기 — 목록에서 전문 노출, 글마다 별도 상세 URL 없음).
|
|
8
|
+
- `@roottale/cms-core`: `RouteCollection.detail` 필드. `resolvePostUrl`/`resolvePostPath` 가 `collection.detail === false` 인 글에 `null` 반환(소속 판정 `resolvePostCollection` 은 영향 없음 — 소속과 상세 URL 존재 여부는 별개).
|
|
9
|
+
- `@roottale/cms-client`: `fetchCollections()`(`CmsRouteCollection.detail`)가 공개 API의 새 `detail` 필드를 매핑(미전달 시 `true`).
|
|
10
|
+
- `@roottale/cms-renderer-next`: `createSitemapIndex`/`createSitemap`(기존 `resolvePostUrl` 경유라 자동 반영)·`createFeedRoute`(RSS 아이템에서 `detail:false` 스트림 글 제외)·`createLlmsTxtRoute`가 `detail:false` 스트림 글의 상세 URL 을 발행하지 않는다. `RootTaleBlogList`/관련 글 카드·아카이브 연관 위젯의 postHref 가 `detail:false` 스트림에서는 존재하지 않는 상세 경로 대신 그 유형의 목록 페이지(`basePath`)로 링크한다.
|
|
11
|
+
|
|
12
|
+
어드민 "콘텐츠 유형" 편집기에 "글별 상세 페이지" 토글 추가(기본 켬). 코드 변경 없이 어드민에서 끄면 즉시 반영.
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- 63b2eb0: `RootTaleBlogList`의 포지티브 `collection` 스코프(`collection`+`collections`)가 `fetchPosts()`의 기존 `collectionKey` 옵션을 실어 보내도록 배선 — 공개 posts API가 `LIMIT` 전에 `collection_key=` 필터를 적용해, 다중 스트림 사이트(예: `/notice`)의 `limit` 슬롯이 다른 섹션 글에 낭비되던 페이지네이션 왜곡이 해소된다(`blog-list-collection-scope.md` §2② 잔여 배선, `excludeCollections`와 동일 패턴). 기존 클라이언트 측 `postsForCollection` 필터는 방어선으로 그대로 유지(동작 diff 0).
|
|
17
|
+
- Updated dependencies [4ec1a83]
|
|
18
|
+
- @roottale/cms-core@0.43.0
|
|
19
|
+
- @roottale/cms-client@0.43.0
|
|
20
|
+
|
|
21
|
+
## 0.42.1
|
|
22
|
+
|
|
23
|
+
### Patch Changes
|
|
24
|
+
|
|
25
|
+
- e4b66c0: 본문 표 스타일을 element 셀렉터로도 적용 — 어드민 에디터(ProseMirror 맨 table)가 발행 화면과 동일한 표 모양을 갖도록 (에디터-뷰어 단일 CSS 소스).
|
|
26
|
+
|
|
3
27
|
## 0.42.0
|
|
4
28
|
|
|
5
29
|
### Minor Changes
|
|
@@ -80,6 +80,7 @@ import {
|
|
|
80
80
|
isAllowedEmbedSrc as isAllowedEmbedSrc2,
|
|
81
81
|
postsForCollection,
|
|
82
82
|
postsNotInAnyCollection,
|
|
83
|
+
resolvePostCollection,
|
|
83
84
|
resolvePostPath
|
|
84
85
|
} from "@roottale/cms-core";
|
|
85
86
|
|
|
@@ -2668,6 +2669,11 @@ async function RootTaleBlogList(props) {
|
|
|
2668
2669
|
limit,
|
|
2669
2670
|
type,
|
|
2670
2671
|
...author ? { author } : {},
|
|
2672
|
+
// blog-list-collection-scope.md §2②(잔여 배선) — 포지티브 스코프도 서버가
|
|
2673
|
+
// 이미 그 섹션 글만 걸러 fetch 하게 한다(limit 이 스트림 밖 글에 낭비되지
|
|
2674
|
+
// 않음). 아래 `postsForCollection` 클라이언트 필터는 방어선으로 유지
|
|
2675
|
+
// (판정 시맨틱 = `resolvePostCollection` 동일 정의).
|
|
2676
|
+
...collection && collections ? { collectionKey: collection } : {},
|
|
2671
2677
|
// blog-list-collection-scope.md §2② — 서버(api-core)가 이미 스트림 글을
|
|
2672
2678
|
// 걸러 fetch 하게 한다(limit 이 스트림 글에 낭비되지 않음). 아래
|
|
2673
2679
|
// `postsNotInAnyCollection` 클라이언트 필터는 방어선으로 유지.
|
|
@@ -2962,7 +2968,9 @@ function archiveGroupTitle(group) {
|
|
|
2962
2968
|
function archivePostHref(collectionKey, slug, collections) {
|
|
2963
2969
|
const collection = collections?.find((item) => item.key === collectionKey);
|
|
2964
2970
|
const basePath = collection?.basePath ?? defaultArchiveBasePath(collectionKey);
|
|
2965
|
-
|
|
2971
|
+
const trimmedBase = basePath.replace(/\/+$/, "");
|
|
2972
|
+
if (collection?.detail === false) return trimmedBase;
|
|
2973
|
+
return `${trimmedBase}/${slug}`;
|
|
2966
2974
|
}
|
|
2967
2975
|
function defaultArchiveBasePath(collectionKey) {
|
|
2968
2976
|
if (collectionKey === "symptoms") return "/symptoms";
|
|
@@ -3087,7 +3095,13 @@ function defaultPostHref(post) {
|
|
|
3087
3095
|
return `/blog/${post.slug}`;
|
|
3088
3096
|
}
|
|
3089
3097
|
function makeCollectionPostHref(collections) {
|
|
3090
|
-
return (post) =>
|
|
3098
|
+
return (post) => {
|
|
3099
|
+
const path = resolvePostPath(post, collections);
|
|
3100
|
+
if (path) return path;
|
|
3101
|
+
const collection = resolvePostCollection(post, collections);
|
|
3102
|
+
if (collection && collection.detail === false) return collection.basePath;
|
|
3103
|
+
return defaultPostHref(post);
|
|
3104
|
+
};
|
|
3091
3105
|
}
|
|
3092
3106
|
function formatPublishedDate2(iso) {
|
|
3093
3107
|
const d = new Date(iso);
|
|
@@ -3375,4 +3389,4 @@ export {
|
|
|
3375
3389
|
RootTalePage,
|
|
3376
3390
|
RenderTiptap
|
|
3377
3391
|
};
|
|
3378
|
-
//# sourceMappingURL=chunk-
|
|
3392
|
+
//# sourceMappingURL=chunk-FKDCPFYV.js.map
|