AdSense 대시보드 헤더 정리

This commit is contained in:
2026-07-20 17:27:41 +09:00
parent c0684737ce
commit 8809183d69
6 changed files with 16 additions and 62 deletions

View File

@@ -1,5 +1,9 @@
# 업데이트 요약
## v1.10.82
- AdSense 대시보드에서 별도 제목/갱신 줄을 제거하고 수익·잔고 카드만 보이도록 정리했다.
## v1.10.81
- AdSense 대시보드를 공식 홈 카드에 가깝게 오늘·어제·지난 7일·이번 달·최근 28일·잔고 형태로 정리했다.

View File

@@ -1,6 +1,6 @@
# 배포 가이드
> 로컬 기준 v1.10.81에서 `npm run lint`와 `npm run build` 검증을 통과했다. NAS 실제 컨테이너 기동과 도메인/프록시 접속 검증은 운영 배포 단계에서 진행한다.
> 로컬 기준 v1.10.82에서 `npm run lint`와 `npm run build` 검증을 통과했다. NAS 실제 컨테이너 기동과 도메인/프록시 접속 검증은 운영 배포 단계에서 진행한다.
## 빌드 유형

View File

@@ -1,5 +1,10 @@
# 업데이트 이력
## v1.10.82
- 관리자 대시보드 AdSense 영역에서 별도 헤더·갱신 표시 제거.
- AdSense 헤더 제거에 따라 사용하지 않는 갱신 상태와 갱신 시각 표시 로직 정리.
## v1.10.81
- 관리자 대시보드 AdSense 설정 안내 문구 제거.

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{
"name": "sori.studio",
"version": "1.10.81",
"version": "1.10.82",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "sori.studio",
"version": "1.10.81",
"version": "1.10.82",
"hasInstallScript": true,
"dependencies": {
"@nuxtjs/tailwindcss": "^6.14.0",

View File

@@ -1,6 +1,6 @@
{
"name": "sori.studio",
"version": "1.10.81",
"version": "1.10.82",
"private": true,
"type": "module",
"imports": {

View File

@@ -80,9 +80,7 @@ const createEmptyAdsenseBalance = () => ({
})
const {
data: adsenseSummary,
pending: isAdsenseLoading,
refresh: refreshAdsenseSummary
data: adsenseSummary
} = await useFetch('/admin/api/adsense/summary', {
server: false,
default: () => ({
@@ -189,16 +187,6 @@ const chartPagination = computed(() => {
const adsenseCards = computed(() => adsenseSummary.value.periods || [])
const adsenseBalance = computed(() => adsenseSummary.value.balance || createEmptyAdsenseBalance())
const adsenseGeneratedLabel = computed(() => {
const value = adsenseSummary.value?.generatedAt
if (!value) {
return ''
}
return formatCompactDateTime(value)
})
/**
* AdSense 통화 코드를 표시 가능한 값으로 보정한다.
* @returns {string} 통화 코드
@@ -553,29 +541,6 @@ const formatCompactDate = (value) => {
return `${year}.${month}.${day}`
}
/**
* 통계 갱신 시각을 짧은 문자열로 변환한다.
* @param {string | null | undefined} value - ISO 날짜
* @returns {string} 표시 날짜와 시간
*/
const formatCompactDateTime = (value) => {
if (!value) {
return '-'
}
const date = new Date(value)
if (Number.isNaN(date.getTime())) {
return '-'
}
const year = date.getFullYear()
const month = String(date.getMonth() + 1).padStart(2, '0')
const day = String(date.getDate()).padStart(2, '0')
const hours = String(date.getHours()).padStart(2, '0')
const minutes = String(date.getMinutes()).padStart(2, '0')
return `${year}.${month}.${day} ${hours}:${minutes}`
}
/**
* 스크롤 도달 지표를 짧은 문자열로 반환한다.
* @param {Object} row - 통계 행
@@ -691,27 +656,7 @@ watch(trendRows, () => {
</p>
</section>
<section class="admin-dashboard__adsense border border-line bg-white p-4">
<div class="admin-dashboard__adsense-header flex flex-wrap items-center justify-between gap-3">
<div>
<h2 class="admin-dashboard__section-title text-sm font-semibold text-ink">
AdSense
</h2>
<p class="admin-dashboard__section-description mt-1 text-xs text-muted">
예상 수입
<span v-if="adsenseGeneratedLabel">· {{ adsenseGeneratedLabel }} 갱신</span>
</p>
</div>
<button
type="button"
class="admin-dashboard__adsense-refresh border border-line bg-white px-3 py-1 text-xs font-medium text-muted transition hover:bg-paper hover:text-ink disabled:cursor-not-allowed disabled:opacity-50"
:disabled="isAdsenseLoading"
@click="refreshAdsenseSummary"
>
{{ isAdsenseLoading ? '갱신 중' : '새로고침' }}
</button>
</div>
<section class="admin-dashboard__adsense">
<p
v-if="adsenseSummary.configured && !adsenseSummary.ok"
class="admin-dashboard__adsense-message mt-3 border border-red-100 bg-red-50 px-3 py-2 text-xs text-red-700"
@@ -719,7 +664,7 @@ watch(trendRows, () => {
{{ adsenseSummary.message || 'AdSense 통계를 불러오지 못했습니다.' }}
</p>
<div class="admin-dashboard__adsense-layout mt-3 grid gap-3 xl:grid-cols-[minmax(0,5fr)_minmax(220px,1fr)]">
<div class="admin-dashboard__adsense-layout grid gap-3 xl:grid-cols-[minmax(0,5fr)_minmax(220px,1fr)]">
<div class="admin-dashboard__adsense-earnings bg-[#2f6cc4] p-4 text-white shadow-sm">
<h3 class="text-sm font-semibold">
예상 수입