<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Edit properties side by side with document preview in Alfresco Forum</title>
    <link>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133133#M35868</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/84175"&gt;@Wolfg&lt;/A&gt;&amp;nbsp;&amp;amp; welcome to Alfresco!&lt;/P&gt;
&lt;P&gt;There is an &lt;A title="Opens in a new window" href="http://alfresco-addons.skytizens.com/alfrescoaddons/alfresco-edit-metadata-with-viewer/" target="_blank" rel="noopener nofollow noreferrer"&gt;extension&lt;/A&gt; that does something similar I believe. I think another suggestion could be this &lt;A href="https://hub.alfresco.com/t5/alfresco-content-services-forum/document-preview-in-edit-task-page/td-p/213401" target="_self" rel="nofollow noopener noreferrer"&gt;code approach&lt;/A&gt;. Another non-code option might be to open the document in a second browser window &amp;amp; do your side-by-side thing that way?&lt;/P&gt;
&lt;P&gt;Cheers,&lt;/P&gt;</description>
    <pubDate>Wed, 13 Jan 2021 12:18:47 GMT</pubDate>
    <dc:creator>EddieMay</dc:creator>
    <dc:date>2021-01-13T12:18:47Z</dc:date>
    <item>
      <title>Edit properties side by side with document preview</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133132#M35867</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;We are currently evaluating Alfresco and created a model with custom document type and properties.&lt;BR /&gt;Is it somehow possible to edit the properties of a document while viewing the preview of the document side by side?&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jan 2021 10:37:41 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133132#M35867</guid>
      <dc:creator>Wolfg</dc:creator>
      <dc:date>2021-01-13T10:37:41Z</dc:date>
    </item>
    <item>
      <title>Re: Edit properties side by side with document preview</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133133#M35868</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/84175"&gt;@Wolfg&lt;/A&gt;&amp;nbsp;&amp;amp; welcome to Alfresco!&lt;/P&gt;
&lt;P&gt;There is an &lt;A title="Opens in a new window" href="http://alfresco-addons.skytizens.com/alfrescoaddons/alfresco-edit-metadata-with-viewer/" target="_blank" rel="noopener nofollow noreferrer"&gt;extension&lt;/A&gt; that does something similar I believe. I think another suggestion could be this &lt;A href="https://hub.alfresco.com/t5/alfresco-content-services-forum/document-preview-in-edit-task-page/td-p/213401" target="_self" rel="nofollow noopener noreferrer"&gt;code approach&lt;/A&gt;. Another non-code option might be to open the document in a second browser window &amp;amp; do your side-by-side thing that way?&lt;/P&gt;
&lt;P&gt;Cheers,&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jan 2021 12:18:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133133#M35868</guid>
      <dc:creator>EddieMay</dc:creator>
      <dc:date>2021-01-13T12:18:47Z</dc:date>
    </item>
    <item>
      <title>Re: Edit properties side by side with document preview</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133134#M35869</link>
      <description>&lt;P&gt;Thank's for the info. Working with two browser windows is somewhat cumbersome and not practical for everyday usage. But i will take a look at the two other proposed solutions.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jan 2021 12:30:46 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133134#M35869</guid>
      <dc:creator>Wolfg</dc:creator>
      <dc:date>2021-01-13T12:30:46Z</dc:date>
    </item>
    <item>
      <title>Re: Edit properties side by side with document preview</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133135#M35870</link>
      <description>&lt;P&gt;For me worked fine this variant.&lt;BR /&gt;just go to the file :&lt;/P&gt;&lt;PRE&gt;&amp;nbsp;tomcat\webapps\share\WEB-INF\classes\alfresco\site-webscripts\org\alfresco\components\edit-metadata\edit-metadata-mgr.get.html.ftl&lt;/PRE&gt;&lt;P&gt;and change it's content like this (look to MY CHANGES START/END comments)&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&amp;lt;#include "../../include/alfresco-macros.lib.ftl" /&amp;gt;
&amp;lt;script type="text/javascript"&amp;gt;//&amp;lt;![CDATA[
   new Alfresco.component.ShareFormManager("${args.htmlid}").setOptions(
   {
      failureMessage: "edit-metadata-mgr.update.failed",
      defaultUrl: "${siteURL((nodeType!"document") + "-details?nodeRef=" + (nodeRef!page.url.args.nodeRef)?js_string)}"
   }).setMessages(${messages});
//]]&amp;gt;&amp;lt;/script&amp;gt;

&amp;lt;!--MY CHANGES --START --&amp;gt;
&amp;lt;style&amp;gt;
   #document-preview {
      position: fixed;
      top: 180px;
      right: 0;
      height:78%;
      width: 50%;
      box-sizing: border-box;
      overflow: hidden;
   }

   #resize-handle {
      position: fixed;
      top: 170px;
      right: 50%;
      width: 5px;
      background-color: grey;
      height: 78%;
      cursor: col-resize;
   }
&amp;lt;/style&amp;gt;
&amp;lt;!--MY CHANGES --END --&amp;gt;

&amp;lt;div class="form-manager"&amp;gt;
   &amp;lt;h1&amp;gt;${msg("edit-metadata-mgr.heading", fileName?html)}&amp;lt;/h1&amp;gt;
&amp;lt;/div&amp;gt;

&amp;lt;!--MY CHANGES --START --&amp;gt;
&amp;lt;div id="container"&amp;gt;
   &amp;lt;div id="document-preview"&amp;gt;
      &amp;lt;#if page.url.args.nodeRef??&amp;gt;
         &amp;lt;#assign documentNodeRef = page.url.args.nodeRef?html&amp;gt;
         &amp;lt;#assign documentPreviewURL = "http://127.0.0.1/share/proxy/alfresco/slingshot/node/content/" + documentNodeRef?replace(":", "") + "?noRedirect=true"&amp;gt;
         &amp;lt;iframe src="${documentPreviewURL}" width="100%" height="100%"&amp;gt;&amp;lt;/iframe&amp;gt;
      &amp;lt;/#if&amp;gt;
      &amp;lt;div id="resize-handle"&amp;gt;&amp;lt;/div&amp;gt;
   &amp;lt;/div&amp;gt;
&amp;lt;/div&amp;gt;
&amp;lt;script type="text/javascript"&amp;gt;//&amp;lt;![CDATA[
   var resizeHandle = document.getElementById("resize-handle");
   var documentPreview = document.getElementById("document-preview");

   var resizingActive=false

   function startResizing(e) {
      if(resizingActive===false){
         resizingActive=true
         event.stopPropagation()
         document.addEventListener("mousemove", resize);
         document.addEventListener("click", stopResizing);
      }
      
   }

   function resize(e) {
      var newWidth = window.innerWidth - e.clientX;
      documentPreview.style.width = newWidth-15 + "px";
      resizeHandle.style.right = (newWidth - 20) + "px"; // Сдвиг разделителя
   }

   function stopResizing() {
      if(resizingActive===true){
         resizingActive=false
         event.stopPropagation()
         document.removeEventListener("mousemove", resize);
         document.addEventListener("click", stopResizing);
      }
      
   }

   resizeHandle.addEventListener("click", startResizing);

//]]&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;!--MY CHANGES --END --&amp;gt;&lt;/PRE&gt;&lt;P&gt;also note that we use the server address 127.0.0.1 in one of the added strings. Need to change this if the server is remote or somehow insert this value from global variables (didn't look up how to do that)&lt;/P&gt;</description>
      <pubDate>Sat, 09 Sep 2023 14:11:31 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/edit-properties-side-by-side-with-document-preview/m-p/133135#M35870</guid>
      <dc:creator>soltivka</dc:creator>
      <dc:date>2023-09-09T14:11:31Z</dc:date>
    </item>
  </channel>
</rss>

