Integrate Obfuscator file picker into Contracts
Deploy contracts-flask / validate (push) Canceled after 0s
Deploy contracts-flask / validate (push) Canceled after 0s
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
+23
-19
@@ -68,6 +68,26 @@
|
||||
.text-pane th { font-size: 10px; padding: 4px 6px; }
|
||||
.text-pane td { padding: 3px 6px; font-size: 11px; }
|
||||
.text-pane .pane-title { font-weight: 600; font-size: 12px; margin-bottom: 8px; color: var(--muted); text-transform: uppercase; }
|
||||
#filePicker .file-picker { color: var(--foreground); font-family: system-ui, sans-serif; }
|
||||
#filePicker .fp-toolbar { margin: 0 0 8px; }
|
||||
#filePicker .fp-toolbar button { min-height: 36px; border: 1px solid var(--brand-gray); border-radius: 6px; padding: 0 14px; color: var(--foreground); background: var(--background); font: inherit; }
|
||||
#filePicker .fp-toolbar button:first-of-type { color: #fff; background: var(--brand-primary); border-color: var(--brand-primary); }
|
||||
#filePicker .fp-toolbar button.secondary { color: var(--foreground); background: var(--background); }
|
||||
#filePicker .fp-toolbar button.quiet { color: var(--muted); }
|
||||
#filePicker .fp-table-wrap { max-height: 50vh; overflow: auto; border: 1px solid var(--brand-gray); border-radius: 6px; }
|
||||
#filePicker .fp-table { font: 13px system-ui, sans-serif; }
|
||||
#filePicker .fp-table th, #filePicker .fp-table td { padding: 6px 10px; border-color: var(--brand-gray); }
|
||||
#filePicker .fp-table th { color: var(--muted); letter-spacing: 0; }
|
||||
#filePicker .tree-name { min-width: 0; padding-top: 0; padding-bottom: 0; color: var(--foreground); font-family: inherit; }
|
||||
#filePicker .tree-file .tree-name { overflow: hidden; text-overflow: ellipsis; }
|
||||
#filePicker .fp-actions { white-space: nowrap; }
|
||||
#filePicker .fp-action { margin-right: 4px; padding: 3px 6px; border: 0; border-radius: 4px; color: var(--brand-primary); background: transparent; cursor: pointer; font: 11px system-ui, sans-serif; }
|
||||
#filePicker .fp-status-uploading { color: var(--brand-primary); }
|
||||
#filePicker .fp-status-parsing { color: var(--brand-primary); }
|
||||
#filePicker .fp-status-parsed { color: var(--green); }
|
||||
#filePicker .fp-status-duplicate { color: var(--muted); }
|
||||
#filePicker .fp-status-error { color: var(--destructive); }
|
||||
#filePicker .fp-status, #filePicker .fp-count { color: var(--muted); font: 12px system-ui, sans-serif; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
@@ -90,22 +110,9 @@
|
||||
Загрузка договоров/приложений/спецификаций
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<input type="file" id="fileInput" accept=".doc,.docx,.pdf,.zip" multiple style="margin-bottom:6px;width:100%;">
|
||||
<input type="file" id="folderInput" webkitdirectory multiple style="display:none;">
|
||||
<div style="margin-bottom:6px;">
|
||||
<button type="button" class="btn" id="folderBtn" style="font-size:12px;height:30px;">📁 Выбрать папку</button>
|
||||
</div>
|
||||
<div style="text-align:right;font-size:11px;color:var(--muted);margin-bottom:6px;">Порядок определяется автоматически при классификации</div>
|
||||
<div style="font-size:11px;color:var(--muted);margin-bottom:6px;">⚠ При совпадении имён — запрос на перезапись (OK / Отмена). Файлы из ZIP-архивов загружаются через тот же поток.</div>
|
||||
|
||||
<div class="table-wrap">
|
||||
<table>
|
||||
<thead>
|
||||
<tr><th>Имя</th><th style="width:130px;">Изменён</th><th style="width:90px;">Размер</th><th style="width:115px;">Парсинг</th><th style="width:30px;">Текст</th><th style="width:30px;">✕</th></tr>
|
||||
</thead>
|
||||
<tbody id="fileTable"></tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div style="font-size:11px;color:var(--muted);margin-bottom:6px;">Выберите PDF, DOC или DOCX. ZIP раскрываются рекурсивно; правила из корневого <code>obscure.lst</code> применяются при выборе папки.</div>
|
||||
<div id="filePicker"></div>
|
||||
|
||||
<button class="btn btn-primary" id="llmBtn" style="width:100%;justify-content:center;margin-top:8px;display:none;background:var(--green);border-color:var(--green);">
|
||||
<i data-lucide="scale" style="width:16px;height:16px;"></i> Общее сравнение
|
||||
@@ -220,10 +227,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type="module">
|
||||
import { listZipFiles } from '/upload/zip/list_zip_files.js';
|
||||
window.listZipFiles = listZipFiles;
|
||||
</script>
|
||||
<script src="/file-picker/file-picker.iife.js"></script>
|
||||
<script src="/static/state.js?v=2.0.21"></script>
|
||||
<script src="/static/app_utils.js?v=2.0.21"></script>
|
||||
<script src="/static/files.js?v=2.0.21"></script>
|
||||
|
||||
Reference in New Issue
Block a user