Skip to content

Commit ed3db5d

Browse files
committed
fix(TextareaCopyable): copy placement top right display bug
Fix #297
1 parent d7b7b20 commit ed3db5d

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/components/TextareaCopyable.vue

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ const { download } = useDownloadFileFromBase64(
9494
<div style="overflow-x: hidden; width: 100%">
9595
<c-card
9696
relative
97-
:style="(copyPlacement === 'top-right' || copyPlacement === 'bottom-right') ? `padding-bottom: 50px` : ''"
97+
:style="copyPlacement === 'top-right' ? 'padding-top: 50px' : (copyPlacement === 'bottom-right' ? 'padding-bottom: 50px' : '')"
9898
>
9999
<n-scrollbar
100100
ref="scrollbarRef"
@@ -112,9 +112,8 @@ const { download } = useDownloadFileFromBase64(
112112
</n-scrollbar>
113113
<div
114114
v-if="value && copyPlacement !== 'none'"
115-
:top-10px="copyPlacement === 'top-right' ? '' : 'no'"
116-
:bottom-10px="copyPlacement === 'bottom-right' ? '' : 'no'"
117115
absolute right-10px
116+
:class="copyPlacement === 'top-right' ? 'top-10px' : (copyPlacement === 'bottom-right' ? 'bottom-10px' : '')"
118117
:style="scrollable ? 'z-index: 10; background: var(--bg-color); border-radius: 50%; padding: 2px;' : ''"
119118
>
120119
<c-tooltip v-if="value && copyPlacement !== 'outside'" :tooltip="tooltipText" position="left">

0 commit comments

Comments
 (0)