Skip to content

Commit

Permalink
feat: add the function of jumping to the front desk (#101)
Browse files Browse the repository at this point in the history
#### What type of PR is this?

/kind feature

#### What this PR does / why we need it:

在瞬间列表上增加一个跳转至前台的按钮

#### Which issue(s) this PR fixes:

Fixes #58 

#### Does this PR introduce a user-facing change?
```release-note
在瞬间列表上增加一个跳转至前台的按钮
```
  • Loading branch information
LIlGG committed May 6, 2024
1 parent e591d3d commit ffc4de3
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions console/src/views/MomentsList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import {
VLoading,
VPagination,
VCard,
VButton,
IconExternalLinkLine,
} from "@halo-dev/components";
import MingcuteMomentsLine from "~icons/mingcute/moment-line";
import type { User } from "@halo-dev/api-client";
Expand Down Expand Up @@ -137,12 +139,24 @@ provide("tag", {
tag: tag.value,
updateTagQuery,
});
const handleJumpToFrontDesk = () => {
window.open("/moments", "_blank");
};
</script>
<template>
<VPageHeader title="瞬间">
<template #icon>
<MingcuteMomentsLine class="moments-mr-2 moments-self-center" />
</template>
<template #actions>
<VButton @click="handleJumpToFrontDesk">
<template #icon>
<IconExternalLinkLine class="h-full w-full" />
</template>
跳转到前台
</VButton>
</template>
</VPageHeader>
<VCard class="moments-m-0 md:moments-m-4 moments-flex-1">
<div class="moments-container moments-mx-auto">
Expand Down

0 comments on commit ffc4de3

Please sign in to comment.