first commit

This commit is contained in:
2026-07-12 15:55:18 +05:30
commit ee98026cc5
404 changed files with 44522 additions and 0 deletions
+21
View File
@@ -0,0 +1,21 @@
// Drag-and-drop file uploader with per-file progress. Progressive enhancement:
// the markup is inert until /__wrnexus/uploader.js loads (auto-injected when a
// page contains `data-uploader`). Pairs with `handleUpload` on the server —
// files POST to `endpoint`, which returns `{ ok, files:[{ key, url, … }] }`.
//
// <div data-component="file-upload" store="public" endpoint="/api/upload"
// accept="image/*" max="10000000" multiple="true"></div>
component FileUpload {
props {
store = "public"
endpoint = "/api/upload"
accept = ""
multiple = false
max = 0
label = "Drag files here or click to browse"
class = ""
}
view {
<div class="wire-fileupload {class}" data-uploader="{store}" data-endpoint="{endpoint}" data-accept="{accept}" data-multiple="{multiple}" data-max="{max}" data-label="{label}"></div>
}
}