0
0
mirror of https://github.com/go-gitea/gitea.git synced 2025-07-21 14:34:43 +02:00

Hide href attribute of a tag if there is no target_url

This commit is contained in:
Lunny Xiao 2025-05-27 21:41:12 -07:00
parent b0936f4f41
commit cd53bd5d5e
No known key found for this signature in database
GPG Key ID: C3B7C91B632F738A

View File

@ -426,7 +426,7 @@ export default defineComponent({
<svg-icon name="octicon-archive" :size="16"/>
</div>
</a>
<a class="tw-flex tw-items-center" v-if="repo.latest_commit_status_state" :href="repo.latest_commit_status_state_link" :data-tooltip-content="repo.locale_latest_commit_status_state">
<a class="tw-flex tw-items-center" v-if="repo.latest_commit_status_state" :href="repo.latest_commit_status_state_link || null" :data-tooltip-content="repo.locale_latest_commit_status_state">
<!-- the commit status icon logic is taken from templates/repo/commit_status.tmpl -->
<svg-icon :name="statusIcon(repo.latest_commit_status_state)" :class="'tw-ml-2 commit-status icon text ' + statusColor(repo.latest_commit_status_state)" :size="16"/>
</a>