浏览代码

fix(web): Assigns description text area with asset description if it exists #4073 (#4125)

Russell Tan 1 年之前
父节点
当前提交
b6c6a7e403
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      web/src/lib/components/asset-viewer/detail-panel.svelte

+ 4 - 0
web/src/lib/components/asset-viewer/detail-panel.svelte

@@ -25,6 +25,10 @@
   $: isOwner = $page?.data?.user?.id === asset.ownerId;
 
   $: {
+    if (textarea) {
+      textarea.value = asset?.exifInfo?.description || '';
+    }
+
     // Get latest description from server
     if (asset.id && !api.isSharedLink) {
       api.assetApi.getAssetById({ id: asset.id }).then((res) => {