Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Package generation for JCR pages #459

Open
wants to merge 2 commits into
base: md2jcr
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 31 additions & 20 deletions import.html
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@
<script src="./js/libs/vendors/exceljs/exceljs.min.js"></script>
<script src="./js/dist/helix-importer.js"></script>
<script src="./js/import/import.ui.js" type="module"></script>
<!-- TODO: fix this direct inclusion -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.10.1/jszip.min.js"></script>
</head>

<body class="tool loading">
Expand Down Expand Up @@ -60,11 +62,15 @@ <h3>Workbench</h3>
<sp-accordion>
<sp-accordion-item label="Import Options">
<div>
<sp-field-label for="import-file-url" required>Transformation file URL</sp-field-label>
<sp-textfield class="option-field" id="import-file-url" type="url" value="http://localhost:3001/tools/importer/import.js"></sp-textfield>
<sp-field-label for="import-file-url" required>Transformation file
URL</sp-field-label>
<sp-textfield class="option-field" id="import-file-url" type="url"
value="http://localhost:3001/tools/importer/import.js"></sp-textfield>

<sp-field-label for="import-pageload-timeout">Page load timeout</sp-field-label>
<sp-number-field class="option-field" id="import-pageload-timeout" value="100" min="0" step="100" format-options='{ "style": "unit", "unit": "millisecond", "unitDisplay": "short" }'></sp-number-field>
<sp-number-field class="option-field" id="import-pageload-timeout" value="100"
min="0" step="100"
format-options='{ "style": "unit", "unit": "millisecond", "unitDisplay": "short" }'></sp-number-field>

<div class="local-save">
<sp-checkbox class="option-field" id="import-local-docx" checked>
Expand All @@ -85,26 +91,29 @@ <h3>Workbench</h3>
Enable JavaScript
</sp-checkbox>
<sp-help-text variant="negative" icon>
Security risk: only enable Javascript execution when importing from trusted websites.
Security risk: only enable Javascript execution when importing from trusted
websites.
</sp-help-text>
<sp-checkbox class="option-field" id="import-scroll-to-bottom" checked>
Scroll to bottom
</sp-checkbox>

<sp-field-label for="import-custom-headers">Custom headers</sp-field-label>
<sp-textfield class="option-field" id="import-custom-headers" multiline placeholder="Define your custom headers as a JSON object with key/value (header name/header value)"></sp-textfield>
<sp-textfield class="option-field" id="import-custom-headers" multiline
placeholder="Define your custom headers as a JSON object with key/value (header name/header value)"></sp-textfield>
</div>
</sp-accordion-item>
</sp-accordion>

<div id="import-action-row">
<sp-button-group>
<sp-button id="import-doimport-button">Import</sp-button>
</sp-button-group>
<div id="transformation-file-default" class="hidden">
<sp-status-light size="s" variant="notice">The default transformation file is being used</sp-status-light>
<div id="import-action-row">
<sp-button-group>
<sp-button id="import-doimport-button">Import</sp-button>
</sp-button-group>
<div id="transformation-file-default" class="hidden">
<sp-status-light size="s" variant="notice">The default transformation file is being
used</sp-status-light>
</div>
</div>
</div>
</form>
<span id="folder-name"></span>
<div class="page-preview hidden">
Expand All @@ -127,16 +136,16 @@ <h3>Page preview</h3>
</sp-tab-panel>
<sp-tab-panel value="import-markdown">
<div data-panel="source">
<div class="code">
<textarea id="import-markdown-source" rows="4" cols="10"></textarea>
</div>
<div class="code">
<textarea id="import-markdown-source" rows="4" cols="10"></textarea>
</div>
</div>
</sp-tab-panel>
<sp-tab-panel value="import-html">
<div data-panel="source">
<div class="code">
<textarea id="import-transformed-html" rows="4" cols="10"></textarea>
</div>
<div class="code">
<textarea id="import-transformed-html" rows="4" cols="10"></textarea>
</div>
</div>
</sp-tab-panel>
<sp-tab-panel value="import-jcr">
Expand All @@ -148,7 +157,8 @@ <h3>Page preview</h3>
</sp-tab-panel>
</sp-tabs>
<sp-button-group>
<sp-button id="import-downloadImportReport" class="hidden">Download import report</sp-button>
<sp-button id="import-downloadImportReport" class="hidden">Download import
report</sp-button>
</sp-button-group>
</div>
</div>
Expand All @@ -158,4 +168,5 @@ <h3>Page preview</h3>
</sp-theme>
<script src="./js/swc_loader.js" type="module"></script>
</body>
</html>

</html>
16 changes: 0 additions & 16 deletions js/dist/174.spectrum-web-components.js

This file was deleted.

1 change: 0 additions & 1 deletion js/dist/842.spectrum-web-components.js

This file was deleted.

149,161 changes: 149,159 additions & 2 deletions js/dist/helix-importer.js

Large diffs are not rendered by default.

16 changes: 0 additions & 16 deletions js/dist/helix-importer.js.LICENSE.txt

This file was deleted.

Loading
Loading