30.10.2024 – Pavel Klavík, Kamila Klavíková
Documents in OrgPad can now be exported and imported in various formats. The export is available in the sidebar menu, with three formats supported: OrgPad's internal format as EDN, JSON Canvas, and linear HTML export including all images and uploaded files. Import is supported from EDN, JSON Canvas, and LucidChart formats, and the import option can be found in the document list in the sidebar menu.
#export, #update, #OrgPad, #improvements
Our work is to create OrgPad as a tool for working with structured data in the form of diagrams. Even though the data is stored in the OrgPad cloud, it has always been and will always be true that all data belongs to our customers. Our job is to take good care of it, create regular backups, and improve the OrgPad tool. This is also why OrgPad is a paid service: we do not make money by selling your data or displaying annoying ads.
To help you manage your data better, we have added the ability to export OrgPages. You can find this option in the sidebar menu under Export OrgPage. A dialog will appear, where you can download the OrgPage in three export formats.
Import can be done from the document list. In the sidebar menu, simply select Import. A dialog will appear, where you upload a file, and an OrgPage will be created from it. Currently, three formats are supported. When the imported document is opened for the first time, the layout of cells and links is automatically adjusted to match the calculated sizes.
If you have data in other formats that you would like to import into OrgPad, let us know and ideally send us some sample files. For importing a larger collection of documents, contact us at support@orgpad.info, and we will assist you.
OrgPad works internally in the EDN format, which is a tree format similar to JSON and used in the programming languages Clojure and ClojureScript, in which OrgPad is built.
When you click export, you will either download an EDN file with the extension .orgpage or a .zip file containing this EDN file and all uploaded images and files. This format can also be imported back into OrgPad.
The basic structure is that an OrgPage is described as a map that has keys :orgpage/units (a vector of cells) and :orgpage/links (a vector of links). Other keys describe the document ID, name, description, tags, created presentations, etc. All IDs are randomly generated UUIDv4.
In an OrgPage, there are two types of units, selected in :unit/type. Books (type :unit/book) are individual cells, with titles, colors, and positions. Each book consists of a sequence of pages (type :unit/page) in :unit/child-unit-ids, always at least one. Individual pages have their content (:unit/content) as a sequence of HTML tags in hiccup format. The sizes of the cells are not described anywhere; OrgPad calculates them directly when opening documents, depending on the specific device.
A link describes the ID of the connected cells in :link/endpoint-ids and the appearance in :link/props (color, orientation, thickness).
(#:unit{:id #uuid"70b50862-691a-4247-8cc5-208367b1420c",
:type :unit/page,
:content ([:p {} "There is some "
[:strong {} "bold text"]
" here and some "
[:span {:style {:background-color "rgb(254, 245, 166)"}}
"yellow text"]
"."]
[:p {}
[:strong {} "Pythagoras Theorem:"]
" "
[:math #:math{:id #uuid"32494cdd-c975-443d-a901-cbef5b980835"}]
"."]
[:p {}]
[:p {:style {:text-align "center"}}
[:img {:width "181",
:src "/img/CPiwCrUDJGCIkE0q6At-Vy",
:height "170"}]])}
#:unit{:id #uuid"aab522e0-6554-44dd-943e-58b1d84c3658",
:type :unit/book,
:pos [-250.23569992614486 -148.19423894003708],
:child-unit-ids [#uuid"05b53a7d-c8ef-4759-880b-a77a80e752e6"],
:props #:props{:title-size :props/h2, :color :color/blue},
:title "A cell with just a title"}
#:unit{:id #uuid"05b53a7d-c8ef-4759-880b-a77a80e752e6",
:type :unit/page}
#:unit{:id #uuid"e2ffd3c0-0274-41c1-bb9d-53d4b5586cef",
:type :unit/book,
:pos [322 -120.5],
:child-unit-ids [#uuid"70b50862-691a-4247-8cc5-208367b1420c"],
:props #:props{:title-size :props/h2, :color :color/red},
:title "A cell with title and content"})(#:link{:id #uuid"5f533d75-c7a0-485d-bbb4-485a6ffe7b9a",
:endpoint-ids [#uuid"aab522e0-6554-44dd-943e-58b1d84c3658"
#uuid"e2ffd3c0-0274-41c1-bb9d-53d4b5586cef"],
:props #:props{:arrowhead :props/single,
:color :color/orange,
:weight :props/strong}})We will describe more detailed information in the future when the API for OrgPad is ready. The easiest way is to create an export of a sample document and directly see how it is represented in EDN. In the future, we plan to change the structure of this format somewhat, based on the needs of OrgPad.
This format was created for the needs of the Obsidian program and is described on the website https://jsoncanvas.org/. It is supported by various tools with infinite canvases, and OrgPad is now one of them.
The goal of the format is to ensure that data created in applications with infinite canvases is easily readable and usable in other programs as well. It gives users full control over their data and is designed to be easy to work with. Files in JSON Canvas format have the .canvas extension.
OrgPages can be exported in this format. However, compared to OrgPad, it is limited in several respects, for example, it does not allow cells with multiple pages. Therefore, individual pages are placed sequentially in one cell in the export. The Markdown format for content is also much more limited than hiccup. You will need to adjust the result a bit in the target application that supports JSON Canvas, but the export is usable.
You can also import JSON Canvas files into OrgPad. This will create a new document, into which images from external sources are also uploaded. When opened for the first time, the positions of cells are adjusted according to the calculated sizes.
Export in this format generates a zip file that contains the text of the entire OrgPage in individual cells. If you have a defined presentation, the order of the cells will follow this presentation; otherwise, they are arranged in rows from left to right. This zip file also contains all uploaded images and files, and other used images (e.g., attachment icons). Here you can download the HTML export of the IT architecture of OrgPad.
You can import .vsdx files from the Lucidchart program in Microsoft Visio format. External images are automatically uploaded to OrgPad. When opened for the first time, cell positions are adjusted. Here is a sample import of a school project.
OrgPad has excellent support for clipboard, allowing you to efficiently copy data between OrgPad and other applications.
When you select cells in OrgPad and press CTRL+C (or CMD+C on MacOS), they are placed in the clipboard. To quickly select all cells in a document, simply press CTRL+A (or CMD+A on MacOS). The data in the clipboard is available in three formats, depending on the target application:
Similarly, you can paste formatted text into OrgPad from a wide range of applications: Word, Google Docs, various websites, such as Wikipedia. Unlike other applications, pasted text does not break formatting. We keep only basic formatting (bold text, links), but remove text color, background, font, size, etc. Additionally, we perform specific cleaning for Wikipedia and other websites.