aboutsummaryrefslogtreecommitdiff
path: root/src/components/user_popover/user_popover.vue
diff options
context:
space:
mode:
authorHJ <30-hj@users.noreply.git.pleroma.social>2022-07-31 17:57:32 +0000
committerHJ <30-hj@users.noreply.git.pleroma.social>2022-07-31 17:57:32 +0000
commit33ad712852088f8b99a82ec561733d41d63b0034 (patch)
tree75eea24b29b4204b57e38aec8223e91a1f1526fe /src/components/user_popover/user_popover.vue
parent0b88c56aa674ad19be7e7e883a3687ec89569940 (diff)
parent36aae1635ad370ecf4d22ae6d62cbbba6af19fd3 (diff)
Merge branch 'disjointed-popovers' into 'develop'
Disjointed popovers See merge request pleroma/pleroma-fe!1540
Diffstat (limited to 'src/components/user_popover/user_popover.vue')
-rw-r--r--src/components/user_popover/user_popover.vue33
1 files changed, 33 insertions, 0 deletions
diff --git a/src/components/user_popover/user_popover.vue b/src/components/user_popover/user_popover.vue
new file mode 100644
index 00000000..72bb7f77
--- /dev/null
+++ b/src/components/user_popover/user_popover.vue
@@ -0,0 +1,33 @@
+<template>
+<Popover
+ trigger="click"
+ popover-class="popover-default user-popover"
+ :overlay-centers-selector="overlayCentersSelector || '.user-info .Avatar'"
+ :overlay-centers="overlayCenters && userPopoverOverlay"
+ :disabled="disabled"
+>
+ <template v-slot:trigger>
+ <slot />
+ </template>
+ <template v-slot:content={close}>
+ <UserCard
+ class="user-popover"
+ :user-id="userId"
+ :hide-bio="true"
+ :avatar-action="userPopoverZoom ? 'zoom' : close"
+ :on-close="close"
+ />
+ </template>
+</Popover>
+</template>
+
+<script src="./user_popover.js" ></script>
+
+<style lang="scss">
+@import '../../_variables.scss';
+
+/* popover styles load on-demand, so we need to override */
+.user-popover.popover {
+}
+
+</style>