mirror of
https://github.com/ialley-workshop-open/uni-halo.git
synced 2026-11-13 22:11:42 +08:00
refactor: 清理注释中的迁移来源、日期与文档引用等额外信息
删除“源自旧项目/与旧项目一致/已下线(日期)/设计见 xxx.md”等迁移记录 与文档引用,注释仅保留功能描述;TODO 与脚手架杂项注释保留原样
This commit is contained in:
@@ -408,7 +408,7 @@
|
||||
|
||||
/* ---------------- 格式化 ---------------- */
|
||||
function formatPublishTime(time ?: string) : string {
|
||||
// 与旧项目一致:yyyy年MM月dd日 星期w
|
||||
// yyyy年MM月dd日 星期w
|
||||
return time ? formatTime({ d: time, f: 'yyyy年MM月dd日 星期w' }) : ''
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script lang="ts" setup>
|
||||
/**
|
||||
* 免责声明页(源自旧项目 pagesA/disclaimers,新建复刻)
|
||||
* 免责声明页
|
||||
*/
|
||||
import { computed } from 'vue'
|
||||
import { useAppConfigStore } from '@/store/appConfig'
|
||||
|
||||
@@ -68,7 +68,7 @@ async function handleMiniPluginRefresh() {
|
||||
handleGetMiniProgramLinks()
|
||||
}
|
||||
|
||||
/** 是否开放公开提交申请(通用配置-友链信息-基本配置 submissionEnabled,2026-09-11 由 setting linkConfig 迁入;默认 true) */
|
||||
/** 是否开放公开提交申请(通用配置-友链信息-基本配置 submissionEnabled;默认 true) */
|
||||
const submissionEnabled = computed(() => (haloPluginConfigs.value?.linkInfo?.submissionEnabled ?? true))
|
||||
|
||||
/* ---------------- tabs ---------------- */
|
||||
@@ -578,7 +578,7 @@ onReachBottom(() => {
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 底部悬浮操作栏(通用组件);提交申请入口按 submissionEnabled 显隐(2026-09-11) -->
|
||||
<!-- 底部悬浮操作栏(通用组件);提交申请入口按 submissionEnabled 显隐 -->
|
||||
<uh-links-actions :actions="submissionEnabled ? ['apply', 'info'] : ['info']" @apply="handleOpenApply" @info="handleOpenMiniInfo" />
|
||||
</view>
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script lang="ts" setup>
|
||||
/**
|
||||
* 恋爱清单页(源自旧项目 pagesA/love/list.vue,新建复刻)
|
||||
* 恋爱清单页
|
||||
* 恋爱清单卡片列表(未开始/进行中/已完成),展开查看详情与回忆图片
|
||||
*/
|
||||
import { computed, ref } from 'vue'
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
updateTimestamp ?: string
|
||||
}[]>([])
|
||||
|
||||
/* ---------------- 动画(对应旧版 mixin calcAniWait) ---------------- */
|
||||
/* ---------------- 动画 ---------------- */
|
||||
/** 预计算列表项入场延迟(每 10 项重置一轮,每项递增 50ms);必须在渲染外算好,渲染中修改响应式状态会导致递归更新 */
|
||||
const calcAniDelays = computed(() => {
|
||||
let wait = 0
|
||||
@@ -103,7 +103,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
/** 实时搜索:输入防抖 400ms 后触发(对应旧版 tm-search 的 @input) */
|
||||
/** 实时搜索:输入防抖 400ms 后触发 */
|
||||
const handleOnInput = debounce(() => {
|
||||
handleOnSearch()
|
||||
}, 400)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script lang="ts" setup>
|
||||
/**
|
||||
* 标签详情页(源自旧项目 pagesA/tag-detail,新建复刻)
|
||||
* 标签详情页
|
||||
* 展示某标签下的文章列表,分页加载
|
||||
*/
|
||||
import { ref } from 'vue'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script lang="ts" setup>
|
||||
/**
|
||||
* 文章标签页(源自旧项目 pagesA/tags,新建复刻)
|
||||
* 文章标签页
|
||||
*/
|
||||
definePage({
|
||||
style: {
|
||||
|
||||
@@ -57,7 +57,7 @@ const isEnded = computed(() => vote.value?.spec?.hasEnded || false)
|
||||
|
||||
/* ---------------- 工具 ---------------- */
|
||||
function formatTime(date?: string, fmt = 'yyyy-MM-dd HH:mm'): string {
|
||||
// 与旧项目一致:yyyy-MM-dd HH:mm
|
||||
// yyyy-MM-dd HH:mm
|
||||
return date ? formatTimeUtil({ d: date, f: fmt }) : ''
|
||||
}
|
||||
|
||||
@@ -88,7 +88,7 @@ async function handleGetData() {
|
||||
tempVote.spec.disabled = isVoted.value
|
||||
tempVote.spec._uh_type = VOTE_TYPES[typeKey] || tempVote.spec.type
|
||||
|
||||
// 计算状态(与旧项目 calcVoteState 一致,含 timeLimit 非 custom 时 hasEnded 兜底)
|
||||
// 计算状态(含 timeLimit 非 custom 时 hasEnded 兜底)
|
||||
tempVote.spec._uh_state = calcVoteState(tempVote)
|
||||
if (tempVote.spec._uh_state.state === '已结束')
|
||||
tempVote.spec.hasEnded = true
|
||||
@@ -327,7 +327,7 @@ onShareTimeline(() => ({
|
||||
</text>
|
||||
</view>
|
||||
<view class="options flex flex-col gap-3 w-full">
|
||||
<!-- PK 对抗条(与旧项目 pk-container 一致;样式需顶层定义,勿嵌套在 .vote-card 下) -->
|
||||
<!-- PK 对抗条(样式需顶层定义,勿嵌套在 .vote-card 下) -->
|
||||
<view v-if="vote.spec?.type === 'pk'" class="pk-container box-border w-full flex">
|
||||
<view
|
||||
v-for="(option, optionIndex) in vote.spec?.options" :key="optionIndex"
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
options : IFilterOption[]
|
||||
}
|
||||
|
||||
/** 筛选维度(与旧项目 tm-dropDownMenu 一致) */
|
||||
/** 筛选维度 */
|
||||
const filterConfig : IFilterItem[] = [
|
||||
{
|
||||
key: 'type',
|
||||
@@ -150,7 +150,7 @@
|
||||
}
|
||||
|
||||
/* ---------------- 搜索 ---------------- */
|
||||
/** 实时搜索:输入防抖 400ms 后触发(对应旧版 tm-search 的 @input) */
|
||||
/** 实时搜索:输入防抖 400ms 后触发 */
|
||||
const handleOnInput = debounce(() => {
|
||||
queryParams.value.page = 1
|
||||
isLoadMore.value = false
|
||||
@@ -196,12 +196,12 @@
|
||||
? dataList.value.concat(tempItems)
|
||||
: tempItems
|
||||
|
||||
// 未投优先排序(与旧项目一致)
|
||||
// 未投优先排序
|
||||
dataList.value = dataList.value.sort((a, b) => {
|
||||
return Number(a.spec?.isVoted) - Number(b.spec?.isVoted)
|
||||
})
|
||||
|
||||
// 是否已投过滤(与旧项目一致)
|
||||
// 是否已投过滤
|
||||
if (filterIsVoted.value !== undefined) {
|
||||
dataList.value = dataList.value.filter(x => x.spec?.isVoted === filterIsVoted.value)
|
||||
}
|
||||
@@ -221,7 +221,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
/** 卡片点击跳详情(与旧项目 VoteCard @on-click 一致) */
|
||||
/** 卡片点击跳详情 */
|
||||
function handleOnVoteClick(vote : IVoteItem) {
|
||||
const name = vote.metadata?.name
|
||||
if (!name)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script lang="ts" setup>
|
||||
/**
|
||||
* 网站浏览页(源自旧项目 pagesC/website,新建复刻)
|
||||
* 网站浏览页
|
||||
* 内嵌 web-view 展示外部链接
|
||||
*/
|
||||
import { ref } from 'vue'
|
||||
|
||||
Reference in New Issue
Block a user