@marianmeres/stuic 2.42.0 → 2.43.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.
@@ -31,7 +31,6 @@
31
31
  import { X } from "../X/index.js";
32
32
  import { preloadImgs } from "../../utils/preload-img.js";
33
33
  import { fade } from "svelte/transition";
34
- import { C } from "vitest/dist/chunks/reporters.d.BFLkQcL6.js";
35
34
 
36
35
  export type AssetPreviewUrlObj = {
37
36
  // o
@@ -56,9 +55,14 @@
56
55
  }
57
56
 
58
57
  export interface Props {
59
- class?: string;
60
58
  assets: string[] | AssetPreview[];
61
59
  classControls?: string;
60
+ //
61
+ modalClassBackdrop?: string;
62
+ modalClassInner?: string;
63
+ modalClass?: string;
64
+ modalClassMain?: string;
65
+ //
62
66
  /** Optional translate function */
63
67
  t?: TranslateFn;
64
68
  /** Optional delete handler - receives the current asset and its index */
@@ -168,7 +172,10 @@
168
172
  const clog = createClog("AssetsPreview", { color: "auto" });
169
173
 
170
174
  let {
171
- class: classProp = "",
175
+ modalClassBackdrop = "",
176
+ modalClassInner = "",
177
+ modalClass = "",
178
+ modalClassMain = "",
172
179
  assets: _assets,
173
180
  t = t_default,
174
181
  classControls = "",
@@ -387,10 +394,10 @@
387
394
  <Modal
388
395
  bind:this={modal}
389
396
  onEscape={modal?.close}
390
- classBackdrop="p-4 md:p-4"
391
- classInner="max-w-full h-full"
392
- class="max-h-full md:max-h-full rounded-lg {classProp}"
393
- classMain="flex items-center justify-center relative stuic-assets-preview stuic-assets-preview-open"
397
+ classBackdrop="p-4 md:p-4 {modalClassBackdrop}"
398
+ classInner="max-w-full h-full {modalClassInner}"
399
+ class="max-h-full md:max-h-full rounded-lg {modalClass}"
400
+ classMain="flex items-center justify-center relative stuic-assets-preview stuic-assets-preview-open {modalClassMain}"
394
401
  >
395
402
  {@const previewAsset = assets?.[previewIdx]}
396
403
  {#if previewAsset}
@@ -10,9 +10,12 @@ export interface AssetPreview {
10
10
  type?: string;
11
11
  }
12
12
  export interface Props {
13
- class?: string;
14
13
  assets: string[] | AssetPreview[];
15
14
  classControls?: string;
15
+ modalClassBackdrop?: string;
16
+ modalClassInner?: string;
17
+ modalClass?: string;
18
+ modalClassMain?: string;
16
19
  /** Optional translate function */
17
20
  t?: TranslateFn;
18
21
  /** Optional delete handler - receives the current asset and its index */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@marianmeres/stuic",
3
- "version": "2.42.0",
3
+ "version": "2.43.0",
4
4
  "files": [
5
5
  "dist",
6
6
  "!dist/**/*.test.*",