访问权限
@@ -90,7 +90,7 @@ watch(()=> props.query, () => {
}, { immediate: true })
watch(() => props.isPublic, () => {
isOpen.value = props.isPublic
-})
+}, { immediate: true })
function handleFocusTitle () {
isEditTitle.value = true
}
@@ -100,7 +100,6 @@ function handleBlurTitle () {
}
function handleShare (isUpdate) {
const shareType = String(isOpen.value)
- useCopyToClipboard().copy(window.location.href)
toast.add({
icon: 'i-heroicons-information-circle-20-solid',
timeout: 2000,
@@ -114,4 +113,10 @@ function handleUpdateOpenState (state) {
isOpen.value = state
handleShare(updateOpened)
}
+function handleSetOpenState() {
+ if (!isOpen.value) {
+ isOpen.value = true
+ handleShare(true)
+ }
+}
\ No newline at end of file
--
GitLab