@sparkvault/sdk 1.10.2 → 1.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +2 -0
- package/dist/sparkvault.cjs.js +3 -1
- package/dist/sparkvault.cjs.js.map +1 -1
- package/dist/sparkvault.esm.js +3 -1
- package/dist/sparkvault.esm.js.map +1 -1
- package/dist/sparkvault.js +1 -1
- package/dist/sparkvault.js.map +1 -1
- package/dist/vaults/upload/types.d.ts +2 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -398,6 +398,8 @@ interface UploadOptions {
|
|
|
398
398
|
target?: string | HTMLElement;
|
|
399
399
|
/** Override backdrop blur for this dialog (uses global config if omitted) */
|
|
400
400
|
backdropBlur?: boolean;
|
|
401
|
+
/** Hide "Upload Another File" button on success screen (for single-file flows) */
|
|
402
|
+
hideUploadAnother?: boolean;
|
|
401
403
|
/** Callback when upload completes successfully (if omitted, uses server-configured redirect) */
|
|
402
404
|
onSuccess?: (result: UploadResult) => void;
|
|
403
405
|
/** Callback when an error occurs (if omitted, uses server-configured redirect) */
|
package/dist/sparkvault.cjs.js
CHANGED
|
@@ -8004,6 +8004,7 @@ class UploadRenderer {
|
|
|
8004
8004
|
from their SparkVault dashboard. Save the Ingot ID above for your records.
|
|
8005
8005
|
</p>
|
|
8006
8006
|
|
|
8007
|
+
${this.options.hideUploadAnother ? '' : `
|
|
8007
8008
|
<button class="svu-btn svu-btn-secondary">
|
|
8008
8009
|
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
8009
8010
|
<path d="M1 4v6h6M23 20v-6h-6"/>
|
|
@@ -8011,6 +8012,7 @@ class UploadRenderer {
|
|
|
8011
8012
|
</svg>
|
|
8012
8013
|
Upload Another File
|
|
8013
8014
|
</button>
|
|
8015
|
+
`}
|
|
8014
8016
|
`;
|
|
8015
8017
|
// Copy button handler
|
|
8016
8018
|
const copyBtn = div.querySelector('.svu-copy-btn');
|
|
@@ -8019,7 +8021,7 @@ class UploadRenderer {
|
|
|
8019
8021
|
navigator.clipboard.writeText(result.ingotId);
|
|
8020
8022
|
});
|
|
8021
8023
|
}
|
|
8022
|
-
// Upload another handler
|
|
8024
|
+
// Upload another handler (only if button exists)
|
|
8023
8025
|
const uploadAnotherBtn = div.querySelector('.svu-btn-secondary');
|
|
8024
8026
|
if (uploadAnotherBtn) {
|
|
8025
8027
|
uploadAnotherBtn.addEventListener('click', () => {
|