|
@@ -211,7 +211,7 @@
|
|
</t-dropdown-item>
|
|
</t-dropdown-item>
|
|
</t-dropdown-menu>
|
|
</t-dropdown-menu>
|
|
</t-dropdown>
|
|
</t-dropdown>
|
|
- <input v-model="data.name" />
|
|
|
|
|
|
+ <input v-model="data.name" @input="inputMeta2dName" />
|
|
|
|
|
|
<div style="width: 290px; flex-shrink: 0"></div>
|
|
<div style="width: 290px; flex-shrink: 0"></div>
|
|
<t-dropdown
|
|
<t-dropdown
|
|
@@ -259,7 +259,7 @@
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script lang="ts" setup>
|
|
<script lang="ts" setup>
|
|
-import { reactive, ref } from "vue";
|
|
|
|
|
|
+import { reactive, ref, onMounted, onUnmounted, nextTick } from "vue";
|
|
import { useRouter, useRoute } from "vue-router";
|
|
import { useRouter, useRoute } from "vue-router";
|
|
import { useUser } from "@/services/user";
|
|
import { useUser } from "@/services/user";
|
|
import { NotifyPlugin, MessagePlugin } from "tdesign-vue-next";
|
|
import { NotifyPlugin, MessagePlugin } from "tdesign-vue-next";
|
|
@@ -301,6 +301,22 @@ const data = reactive({
|
|
name: "空白文件",
|
|
name: "空白文件",
|
|
});
|
|
});
|
|
|
|
|
|
|
|
+const inputMeta2dName = (value) => {
|
|
|
|
+ meta2d.store.data.name = data.name;
|
|
|
|
+};
|
|
|
|
+
|
|
|
|
+const initMeta2dName = () => {
|
|
|
|
+ data.name = meta2d.store.data.name;
|
|
|
|
+};
|
|
|
|
+
|
|
|
|
+nextTick(() => {
|
|
|
|
+ meta2d.on("opened", initMeta2dName);
|
|
|
|
+});
|
|
|
|
+
|
|
|
|
+onUnmounted(() => {
|
|
|
|
+ meta2d.off("opened", initMeta2dName);
|
|
|
|
+});
|
|
|
|
+
|
|
function login() {
|
|
function login() {
|
|
//TODO 临时地址
|
|
//TODO 临时地址
|
|
return `https://account.le5le.com/?cb=${encodeURIComponent(location.href)}`;
|
|
return `https://account.le5le.com/?cb=${encodeURIComponent(location.href)}`;
|