관리자 통계 제외와 콘텐츠 링크 정리
This commit is contained in:
@@ -92,7 +92,7 @@ const romanizeHangulSyllable = (char) => {
|
||||
}
|
||||
|
||||
/**
|
||||
* 문자열을 영문 URL 슬러그로 변환
|
||||
* 문자열을 URL 슬러그로 변환
|
||||
* @param {string} value - 원본 문자열
|
||||
* @returns {string} 영문 슬러그
|
||||
*/
|
||||
@@ -103,10 +103,10 @@ const toSlug = (value) => value
|
||||
.join('')
|
||||
.trim()
|
||||
.toLowerCase()
|
||||
.replace(/[^a-z0-9\s-]/g, '')
|
||||
.replace(/[^a-z0-9\s_-]/g, '')
|
||||
.replace(/\s+/g, '-')
|
||||
.replace(/-+/g, '-')
|
||||
.replace(/^-|-$/g, '')
|
||||
.replace(/[-_]+/g, (match) => match.includes('_') ? '_' : '-')
|
||||
.replace(/^[-_]|[-_]$/g, '')
|
||||
|
||||
const pageSlug = computed(() => toSlug(form.slug || form.title))
|
||||
const viewPageUrl = computed(() => props.publicUrl || (pageSlug.value ? `/pages/${pageSlug.value}` : ''))
|
||||
|
||||
@@ -405,10 +405,10 @@ const toSlug = (value) => value
|
||||
.join('')
|
||||
.trim()
|
||||
.toLowerCase()
|
||||
.replace(/[^a-z0-9\s-]/g, '')
|
||||
.replace(/[^a-z0-9\s_-]/g, '')
|
||||
.replace(/\s+/g, '-')
|
||||
.replace(/-+/g, '-')
|
||||
.replace(/^-|-$/g, '')
|
||||
.replace(/[-_]+/g, (match) => match.includes('_') ? '_' : '-')
|
||||
.replace(/^[-_]|[-_]$/g, '')
|
||||
|
||||
/**
|
||||
* 게시물 태그 입력 토큰 정규화(한글 유지, 공백은 하이픈으로)
|
||||
|
||||
@@ -31,7 +31,17 @@ defineProps({
|
||||
{{ post.excerpt }}
|
||||
</p>
|
||||
<p class="post-card__meta mt-2 text-xs site-muted">
|
||||
{{ post.publishedAt }}<template v-if="post.tag"> / {{ post.tag }}</template>
|
||||
{{ post.publishedAt }}<template v-if="post.tag"> / </template>
|
||||
<NuxtLink
|
||||
v-if="post.tag && post.tagSlug"
|
||||
class="post-card__tag-link site-interactive hover:text-[var(--site-accent)]"
|
||||
:to="`/tag/${post.tagSlug}`"
|
||||
>
|
||||
{{ post.tag }}
|
||||
</NuxtLink>
|
||||
<template v-else-if="post.tag">
|
||||
{{ post.tag }}
|
||||
</template>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user