@gallop.software/studio 0.1.38 → 0.1.40

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.
@@ -4,7 +4,7 @@
4
4
 
5
5
 
6
6
 
7
- var _chunkAY2DAS6Wjs = require('./chunk-AY2DAS6W.js');
7
+ var _chunkUFCWGUAGjs = require('./chunk-UFCWGUAG.js');
8
8
 
9
9
  // src/components/StudioUI.tsx
10
10
  var _react = require('react');
@@ -49,6 +49,9 @@ var defaultState = {
49
49
  },
50
50
  refreshKey: 0,
51
51
  triggerRefresh: () => {
52
+ },
53
+ searchQuery: "",
54
+ setSearchQuery: () => {
52
55
  }
53
56
  };
54
57
  var StudioContext = _react.createContext.call(void 0, defaultState);
@@ -88,11 +91,11 @@ var styles = {
88
91
  justify-content: center;
89
92
  z-index: 10000;
90
93
  animation: ${fadeIn} 0.15s ease-out;
91
- font-family: ${_chunkAY2DAS6Wjs.fontStack};
94
+ font-family: ${_chunkUFCWGUAGjs.fontStack};
92
95
  `,
93
96
  modal: _react3.css`
94
- ${_chunkAY2DAS6Wjs.baseReset}
95
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
97
+ ${_chunkUFCWGUAGjs.baseReset}
98
+ background-color: ${_chunkUFCWGUAGjs.colors.surface};
96
99
  border-radius: 12px;
97
100
  box-shadow: 0 30px 60px -12px rgba(50, 50, 93, 0.25), 0 18px 36px -18px rgba(0, 0, 0, 0.3);
98
101
  max-width: 420px;
@@ -104,9 +107,9 @@ var styles = {
104
107
  padding: 24px 24px 0;
105
108
  `,
106
109
  title: _react3.css`
107
- font-size: ${_chunkAY2DAS6Wjs.fontSize.lg};
110
+ font-size: ${_chunkUFCWGUAGjs.fontSize.lg};
108
111
  font-weight: 600;
109
- color: ${_chunkAY2DAS6Wjs.colors.text};
112
+ color: ${_chunkUFCWGUAGjs.colors.text};
110
113
  margin: 0;
111
114
  letter-spacing: -0.02em;
112
115
  `,
@@ -114,8 +117,8 @@ var styles = {
114
117
  padding: 12px 24px 24px;
115
118
  `,
116
119
  message: _react3.css`
117
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
118
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
120
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
121
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
119
122
  margin: 0;
120
123
  line-height: 1.6;
121
124
  `,
@@ -124,12 +127,12 @@ var styles = {
124
127
  justify-content: flex-end;
125
128
  gap: 12px;
126
129
  padding: 16px 24px;
127
- border-top: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
128
- background-color: ${_chunkAY2DAS6Wjs.colors.background};
130
+ border-top: 1px solid ${_chunkUFCWGUAGjs.colors.border};
131
+ background-color: ${_chunkUFCWGUAGjs.colors.background};
129
132
  `,
130
133
  btn: _react3.css`
131
134
  padding: 10px 18px;
132
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
135
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
133
136
  font-weight: 500;
134
137
  border-radius: 6px;
135
138
  cursor: pointer;
@@ -137,33 +140,33 @@ var styles = {
137
140
  letter-spacing: -0.01em;
138
141
  `,
139
142
  btnCancel: _react3.css`
140
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
141
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
142
- color: ${_chunkAY2DAS6Wjs.colors.text};
143
+ background-color: ${_chunkUFCWGUAGjs.colors.surface};
144
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
145
+ color: ${_chunkUFCWGUAGjs.colors.text};
143
146
 
144
147
  &:hover {
145
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
146
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
148
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
149
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
147
150
  }
148
151
  `,
149
152
  btnConfirm: _react3.css`
150
- background-color: ${_chunkAY2DAS6Wjs.colors.primary};
151
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.primary};
153
+ background-color: ${_chunkUFCWGUAGjs.colors.primary};
154
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.primary};
152
155
  color: white;
153
156
 
154
157
  &:hover {
155
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryHover};
156
- border-color: ${_chunkAY2DAS6Wjs.colors.primaryHover};
158
+ background-color: ${_chunkUFCWGUAGjs.colors.primaryHover};
159
+ border-color: ${_chunkUFCWGUAGjs.colors.primaryHover};
157
160
  }
158
161
  `,
159
162
  btnDanger: _react3.css`
160
- background-color: ${_chunkAY2DAS6Wjs.colors.danger};
161
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.danger};
163
+ background-color: ${_chunkUFCWGUAGjs.colors.danger};
164
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.danger};
162
165
  color: white;
163
166
 
164
167
  &:hover {
165
- background-color: ${_chunkAY2DAS6Wjs.colors.dangerHover};
166
- border-color: ${_chunkAY2DAS6Wjs.colors.dangerHover};
168
+ background-color: ${_chunkUFCWGUAGjs.colors.dangerHover};
169
+ border-color: ${_chunkUFCWGUAGjs.colors.dangerHover};
167
170
  }
168
171
  `
169
172
  };
@@ -211,28 +214,28 @@ var progressStyles = {
211
214
  progressBar: _react3.css`
212
215
  width: 100%;
213
216
  height: 8px;
214
- background-color: ${_chunkAY2DAS6Wjs.colors.background};
217
+ background-color: ${_chunkUFCWGUAGjs.colors.background};
215
218
  border-radius: 4px;
216
219
  overflow: hidden;
217
220
  margin-bottom: 12px;
218
221
  `,
219
222
  progressFill: _react3.css`
220
223
  height: 100%;
221
- background: linear-gradient(90deg, ${_chunkAY2DAS6Wjs.colors.primary}, ${_chunkAY2DAS6Wjs.colors.primaryHover});
224
+ background: linear-gradient(90deg, ${_chunkUFCWGUAGjs.colors.primary}, ${_chunkUFCWGUAGjs.colors.primaryHover});
222
225
  border-radius: 4px;
223
226
  transition: width 0.3s ease;
224
227
  `,
225
228
  progressText: _react3.css`
226
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
227
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
229
+ font-size: ${_chunkUFCWGUAGjs.fontSize.sm};
230
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
228
231
  margin: 0;
229
232
  display: flex;
230
233
  justify-content: space-between;
231
234
  align-items: center;
232
235
  `,
233
236
  currentFile: _react3.css`
234
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
235
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
237
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
238
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
236
239
  margin: 8px 0 0;
237
240
  white-space: nowrap;
238
241
  overflow: hidden;
@@ -318,13 +321,15 @@ var spin = _react3.keyframes`
318
321
  var styles2 = {
319
322
  toolbar: _react3.css`
320
323
  display: flex;
321
- flex-wrap: wrap;
324
+ flex-wrap: nowrap;
322
325
  align-items: center;
323
326
  justify-content: space-between;
324
327
  gap: 8px;
325
328
  padding: 12px 16px;
326
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
327
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
329
+ background-color: ${_chunkUFCWGUAGjs.colors.surface};
330
+ border-bottom: 1px solid ${_chunkUFCWGUAGjs.colors.border};
331
+ overflow-x: auto;
332
+ min-width: 0;
328
333
 
329
334
  @media (min-width: 768px) {
330
335
  padding: 12px 24px;
@@ -332,13 +337,15 @@ var styles2 = {
332
337
  `,
333
338
  left: _react3.css`
334
339
  display: flex;
335
- flex-wrap: wrap;
340
+ flex-wrap: nowrap;
341
+ flex-shrink: 0;
336
342
  align-items: center;
337
343
  gap: 8px;
338
344
  `,
339
345
  right: _react3.css`
340
346
  display: flex;
341
- flex-wrap: wrap;
347
+ flex-wrap: nowrap;
348
+ flex-shrink: 0;
342
349
  align-items: center;
343
350
  gap: 8px;
344
351
  `,
@@ -350,18 +357,18 @@ var styles2 = {
350
357
  height: ${btnHeight};
351
358
  padding: 0 14px;
352
359
  border-radius: 6px;
353
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
360
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
354
361
  font-weight: 500;
355
- background: ${_chunkAY2DAS6Wjs.colors.surface};
356
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
362
+ background: ${_chunkUFCWGUAGjs.colors.surface};
363
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
357
364
  cursor: pointer;
358
365
  transition: all 0.15s ease;
359
- color: ${_chunkAY2DAS6Wjs.colors.text};
366
+ color: ${_chunkUFCWGUAGjs.colors.text};
360
367
  letter-spacing: -0.01em;
361
368
 
362
369
  &:hover:not(:disabled) {
363
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
364
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
370
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
371
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
365
372
  }
366
373
 
367
374
  &:disabled {
@@ -373,21 +380,21 @@ var styles2 = {
373
380
  padding: 0 10px;
374
381
  `,
375
382
  btnPrimary: _react3.css`
376
- background: ${_chunkAY2DAS6Wjs.colors.primary};
377
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
383
+ background: ${_chunkUFCWGUAGjs.colors.primary};
384
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
378
385
  color: white;
379
386
 
380
387
  &:hover:not(:disabled) {
381
- background: ${_chunkAY2DAS6Wjs.colors.primaryHover};
382
- border-color: ${_chunkAY2DAS6Wjs.colors.primaryHover};
388
+ background: ${_chunkUFCWGUAGjs.colors.primaryHover};
389
+ border-color: ${_chunkUFCWGUAGjs.colors.primaryHover};
383
390
  }
384
391
  `,
385
392
  btnDanger: _react3.css`
386
- color: ${_chunkAY2DAS6Wjs.colors.danger};
393
+ color: ${_chunkUFCWGUAGjs.colors.danger};
387
394
 
388
395
  &:hover:not(:disabled) {
389
- background-color: ${_chunkAY2DAS6Wjs.colors.dangerLight};
390
- border-color: ${_chunkAY2DAS6Wjs.colors.danger};
396
+ background-color: ${_chunkUFCWGUAGjs.colors.dangerLight};
397
+ border-color: ${_chunkUFCWGUAGjs.colors.danger};
391
398
  }
392
399
  `,
393
400
  icon: _react3.css`
@@ -398,19 +405,19 @@ var styles2 = {
398
405
  animation: ${spin} 1s linear infinite;
399
406
  `,
400
407
  selectionCount: _react3.css`
401
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
402
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
408
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
409
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
403
410
  display: flex;
404
411
  align-items: center;
405
412
  gap: 8px;
406
413
  margin-right: 8px;
407
414
  `,
408
415
  clearBtn: _react3.css`
409
- color: ${_chunkAY2DAS6Wjs.colors.primary};
416
+ color: ${_chunkUFCWGUAGjs.colors.primary};
410
417
  background: none;
411
418
  border: none;
412
419
  cursor: pointer;
413
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
420
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
414
421
  font-weight: 500;
415
422
  padding: 0;
416
423
 
@@ -421,38 +428,64 @@ var styles2 = {
421
428
  divider: _react3.css`
422
429
  width: 1px;
423
430
  height: 24px;
424
- background: ${_chunkAY2DAS6Wjs.colors.border};
431
+ background: ${_chunkUFCWGUAGjs.colors.border};
425
432
  margin: 0 4px;
426
433
  `,
427
434
  viewToggle: _react3.css`
428
435
  display: flex;
429
436
  align-items: center;
430
437
  height: ${btnHeight};
431
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
432
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
438
+ background-color: ${_chunkUFCWGUAGjs.colors.surface};
439
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
433
440
  border-radius: 6px;
434
441
  overflow: hidden;
435
442
  `,
443
+ searchInput: _react3.css`
444
+ height: ${btnHeight};
445
+ padding: 0 12px;
446
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
447
+ border-radius: 6px;
448
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
449
+ background: ${_chunkUFCWGUAGjs.colors.surface};
450
+ color: ${_chunkUFCWGUAGjs.colors.text};
451
+ width: 180px;
452
+ transition: all 0.15s ease;
453
+
454
+ &:focus {
455
+ outline: none;
456
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
457
+ box-shadow: 0 0 0 2px ${_chunkUFCWGUAGjs.colors.primaryLight};
458
+ }
459
+
460
+ &::placeholder {
461
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
462
+ }
463
+ `,
436
464
  viewBtn: _react3.css`
437
465
  height: 100%;
438
466
  padding: 0 10px;
439
467
  background: transparent;
440
468
  border: none;
441
469
  cursor: pointer;
442
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
470
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
443
471
  transition: all 0.15s ease;
444
472
  display: flex;
445
473
  align-items: center;
446
474
  justify-content: center;
447
475
 
448
476
  &:hover {
449
- color: ${_chunkAY2DAS6Wjs.colors.text};
450
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
477
+ color: ${_chunkUFCWGUAGjs.colors.text};
478
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
451
479
  }
452
480
  `,
453
481
  viewBtnActive: _react3.css`
454
- background-color: ${_chunkAY2DAS6Wjs.colors.background};
455
- color: ${_chunkAY2DAS6Wjs.colors.text};
482
+ background-color: ${_chunkUFCWGUAGjs.colors.primaryLight};
483
+ color: ${_chunkUFCWGUAGjs.colors.primary};
484
+
485
+ &:hover {
486
+ background-color: ${_chunkUFCWGUAGjs.colors.primaryLight};
487
+ color: ${_chunkUFCWGUAGjs.colors.primary};
488
+ }
456
489
  `
457
490
  };
458
491
  function StudioToolbar() {
@@ -774,10 +807,14 @@ function StudioToolbar() {
774
807
  const handleSyncCdn = _react.useCallback.call(void 0, () => {
775
808
  console.log("Sync CDN clicked", selectedItems);
776
809
  }, [selectedItems]);
777
- const handleScan = _react.useCallback.call(void 0, () => {
778
- console.log("Scan clicked");
779
- }, []);
810
+ const { searchQuery, setSearchQuery } = useStudio();
811
+ const handleSearch = _react.useCallback.call(void 0, (e) => {
812
+ setSearchQuery(e.target.value);
813
+ }, [setSearchQuery]);
780
814
  const hasSelection = selectedItems.size > 0;
815
+ const hasImagesSelected = Array.from(selectedItems).some(
816
+ (path) => path === "public/images" || path.startsWith("public/images/")
817
+ );
781
818
  if (focusedItem) {
782
819
  return null;
783
820
  }
@@ -859,8 +896,8 @@ function StudioToolbar() {
859
896
  {
860
897
  css: styles2.btn,
861
898
  onClick: handleProcessImages,
862
- disabled: processing || isInImagesFolder,
863
- title: isInImagesFolder ? "Cannot process images from within the images folder" : void 0,
899
+ disabled: processing || isInImagesFolder || hasImagesSelected,
900
+ title: isInImagesFolder || hasImagesSelected ? "Cannot process protected images folder" : void 0,
864
901
  children: [
865
902
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ImageStackIcon, {}),
866
903
  processing ? "Processing..." : "Process Images"
@@ -872,7 +909,8 @@ function StudioToolbar() {
872
909
  {
873
910
  css: [styles2.btn, styles2.btnDanger],
874
911
  onClick: handleDeleteClick,
875
- disabled: !hasSelection,
912
+ disabled: !hasSelection || hasImagesSelected,
913
+ title: hasImagesSelected ? "Cannot delete protected images folder items" : void 0,
876
914
  children: [
877
915
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TrashIcon, {}),
878
916
  "Delete"
@@ -891,10 +929,16 @@ function StudioToolbar() {
891
929
  ]
892
930
  }
893
931
  ),
894
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "button", { css: styles2.btn, onClick: handleScan, children: [
895
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ScanIcon, {}),
896
- "Scan"
897
- ] })
932
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
933
+ "input",
934
+ {
935
+ css: styles2.searchInput,
936
+ type: "text",
937
+ placeholder: "Search images...",
938
+ value: searchQuery,
939
+ onChange: handleSearch
940
+ }
941
+ )
898
942
  ] }),
899
943
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles2.right, children: [
900
944
  hasSelection && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { css: styles2.selectionCount, children: [
@@ -946,9 +990,6 @@ function TrashIcon() {
946
990
  function CloudIcon() {
947
991
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles2.icon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M7 16a4 4 0 01-.88-7.903A5 5 0 1115.9 6L16 6a5 5 0 011 9.9M15 13l-3-3m0 0l-3 3m3-3v12" }) });
948
992
  }
949
- function ScanIcon() {
950
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles2.icon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" }) });
951
- }
952
993
  function GridIcon() {
953
994
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles2.icon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z" }) });
954
995
  }
@@ -977,8 +1018,8 @@ var styles3 = {
977
1018
  width: 32px;
978
1019
  height: 32px;
979
1020
  border-radius: 50%;
980
- border: 3px solid ${_chunkAY2DAS6Wjs.colors.border};
981
- border-top-color: ${_chunkAY2DAS6Wjs.colors.primary};
1021
+ border: 3px solid ${_chunkUFCWGUAGjs.colors.border};
1022
+ border-top-color: ${_chunkUFCWGUAGjs.colors.primary};
982
1023
  animation: ${spin2} 0.8s linear infinite;
983
1024
  `,
984
1025
  empty: _react3.css`
@@ -987,7 +1028,7 @@ var styles3 = {
987
1028
  align-items: center;
988
1029
  justify-content: center;
989
1030
  height: 256px;
990
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1031
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
991
1032
  `,
992
1033
  emptyIcon: _react3.css`
993
1034
  width: 48px;
@@ -996,32 +1037,32 @@ var styles3 = {
996
1037
  opacity: 0.5;
997
1038
  `,
998
1039
  emptyText: _react3.css`
999
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
1040
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
1000
1041
  margin: 0 0 4px 0;
1001
1042
 
1002
1043
  &:last-child {
1003
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1004
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
1044
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1045
+ font-size: ${_chunkUFCWGUAGjs.fontSize.sm};
1005
1046
  }
1006
1047
  `,
1007
1048
  grid: _react3.css`
1008
1049
  display: grid;
1009
- grid-template-columns: repeat(2, 1fr);
1050
+ grid-template-columns: 1fr;
1010
1051
  gap: 12px;
1011
1052
 
1012
- @media (min-width: 640px) { grid-template-columns: repeat(3, 1fr); }
1013
- @media (min-width: 768px) { grid-template-columns: repeat(4, 1fr); }
1014
- @media (min-width: 1024px) { grid-template-columns: repeat(5, 1fr); }
1015
- @media (min-width: 1280px) { grid-template-columns: repeat(6, 1fr); }
1053
+ @media (min-width: 480px) { grid-template-columns: repeat(2, 1fr); }
1054
+ @media (min-width: 768px) { grid-template-columns: repeat(3, 1fr); }
1055
+ @media (min-width: 1024px) { grid-template-columns: repeat(4, 1fr); }
1056
+ @media (min-width: 1280px) { grid-template-columns: repeat(5, 1fr); }
1016
1057
  `,
1017
1058
  item: _react3.css`
1018
1059
  position: relative;
1019
1060
  border-radius: 8px;
1020
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1061
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1021
1062
  overflow: hidden;
1022
1063
  cursor: pointer;
1023
1064
  transition: all 0.15s ease;
1024
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
1065
+ background-color: ${_chunkUFCWGUAGjs.colors.surface};
1025
1066
  user-select: none;
1026
1067
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
1027
1068
 
@@ -1031,18 +1072,18 @@ var styles3 = {
1031
1072
  }
1032
1073
  `,
1033
1074
  itemSelected: _react3.css`
1034
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1035
- box-shadow: 0 0 0 1px ${_chunkAY2DAS6Wjs.colors.primary};
1075
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
1076
+ box-shadow: 0 0 0 1px ${_chunkUFCWGUAGjs.colors.primary};
1036
1077
 
1037
1078
  &:hover {
1038
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1079
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
1039
1080
  }
1040
1081
  `,
1041
1082
  parentItem: _react3.css`
1042
1083
  cursor: pointer;
1043
1084
 
1044
1085
  &:hover {
1045
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1086
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
1046
1087
  }
1047
1088
  `,
1048
1089
  checkboxWrapper: _react3.css`
@@ -1056,7 +1097,7 @@ var styles3 = {
1056
1097
  checkbox: _react3.css`
1057
1098
  width: 16px;
1058
1099
  height: 16px;
1059
- accent-color: ${_chunkAY2DAS6Wjs.colors.primary};
1100
+ accent-color: ${_chunkUFCWGUAGjs.colors.primary};
1060
1101
  cursor: pointer;
1061
1102
  `,
1062
1103
  cdnBadge: _react3.css`
@@ -1064,8 +1105,8 @@ var styles3 = {
1064
1105
  top: 8px;
1065
1106
  right: 8px;
1066
1107
  z-index: 10;
1067
- background-color: ${_chunkAY2DAS6Wjs.colors.successLight};
1068
- color: ${_chunkAY2DAS6Wjs.colors.success};
1108
+ background-color: ${_chunkUFCWGUAGjs.colors.successLight};
1109
+ color: ${_chunkUFCWGUAGjs.colors.success};
1069
1110
  font-size: 11px;
1070
1111
  font-weight: 500;
1071
1112
  padding: 2px 8px;
@@ -1077,22 +1118,41 @@ var styles3 = {
1077
1118
  align-items: center;
1078
1119
  justify-content: center;
1079
1120
  padding: 16px;
1080
- background: ${_chunkAY2DAS6Wjs.colors.background};
1121
+ background: ${_chunkUFCWGUAGjs.colors.background};
1081
1122
  `,
1082
1123
  folderIcon: _react3.css`
1083
1124
  width: 56px;
1084
1125
  height: 56px;
1085
1126
  color: #f5a623;
1086
1127
  `,
1128
+ imagesFolderIcon: _react3.css`
1129
+ width: 56px;
1130
+ height: 56px;
1131
+ color: ${_chunkUFCWGUAGjs.colors.imagesFolder};
1132
+ `,
1133
+ imagesFolderWrapper: _react3.css`
1134
+ position: relative;
1135
+ `,
1136
+ lockIcon: _react3.css`
1137
+ position: absolute;
1138
+ bottom: 4px;
1139
+ right: 4px;
1140
+ width: 16px;
1141
+ height: 16px;
1142
+ color: ${_chunkUFCWGUAGjs.colors.imagesFolder};
1143
+ background: white;
1144
+ border-radius: 50%;
1145
+ padding: 2px;
1146
+ `,
1087
1147
  parentIcon: _react3.css`
1088
1148
  width: 56px;
1089
1149
  height: 56px;
1090
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1150
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1091
1151
  `,
1092
1152
  fileIcon: _react3.css`
1093
1153
  width: 40px;
1094
1154
  height: 40px;
1095
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1155
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1096
1156
  `,
1097
1157
  image: _react3.css`
1098
1158
  max-width: 100%;
@@ -1107,8 +1167,8 @@ var styles3 = {
1107
1167
  justify-content: center;
1108
1168
  gap: 8px;
1109
1169
  padding: 16px;
1110
- background: ${_chunkAY2DAS6Wjs.colors.background};
1111
- border: 2px dashed ${_chunkAY2DAS6Wjs.colors.border};
1170
+ background: ${_chunkUFCWGUAGjs.colors.background};
1171
+ border: 2px dashed ${_chunkUFCWGUAGjs.colors.border};
1112
1172
  border-radius: 8px;
1113
1173
  cursor: pointer;
1114
1174
  transition: all 0.15s ease;
@@ -1116,39 +1176,94 @@ var styles3 = {
1116
1176
  height: 60%;
1117
1177
 
1118
1178
  &:hover {
1119
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1120
- background: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1179
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
1180
+ background: ${_chunkUFCWGUAGjs.colors.surfaceHover};
1121
1181
  }
1122
1182
  `,
1123
1183
  noThumbnailIcon: _react3.css`
1124
1184
  width: 32px;
1125
1185
  height: 32px;
1126
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1186
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1127
1187
  `,
1128
1188
  noThumbnailText: _react3.css`
1129
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1130
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1189
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
1190
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1131
1191
  text-align: center;
1132
1192
  `,
1133
1193
  label: _react3.css`
1134
1194
  padding: 10px 12px;
1135
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
1136
- border-top: 1px solid ${_chunkAY2DAS6Wjs.colors.borderLight};
1195
+ background-color: ${_chunkUFCWGUAGjs.colors.surface};
1196
+ border-top: 1px solid ${_chunkUFCWGUAGjs.colors.borderLight};
1137
1197
  `,
1138
1198
  labelRow: _react3.css`
1139
1199
  display: flex;
1140
- align-items: center;
1141
- justify-content: space-between;
1142
- gap: 8px;
1200
+ flex-direction: column;
1201
+ gap: 6px;
1143
1202
  `,
1144
1203
  labelText: _react3.css`
1145
1204
  flex: 1;
1146
1205
  min-width: 0;
1147
1206
  `,
1207
+ buttonRow: _react3.css`
1208
+ display: flex;
1209
+ gap: 6px;
1210
+ `,
1211
+ copyBtn: _react3.css`
1212
+ position: relative;
1213
+ flex-shrink: 0;
1214
+ height: 28px;
1215
+ width: 28px;
1216
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
1217
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
1218
+ background: ${_chunkUFCWGUAGjs.colors.surface};
1219
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1220
+ padding: 0;
1221
+ cursor: pointer;
1222
+ border-radius: 4px;
1223
+ transition: all 0.15s ease;
1224
+ display: inline-flex;
1225
+ align-items: center;
1226
+ justify-content: center;
1227
+
1228
+ &:hover {
1229
+ background: ${_chunkUFCWGUAGjs.colors.surfaceHover};
1230
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
1231
+ color: ${_chunkUFCWGUAGjs.colors.text};
1232
+ }
1233
+ `,
1234
+ copyIcon: _react3.css`
1235
+ width: 14px;
1236
+ height: 14px;
1237
+ `,
1238
+ tooltip: _react3.css`
1239
+ position: absolute;
1240
+ bottom: 100%;
1241
+ left: 50%;
1242
+ transform: translateX(-50%);
1243
+ background: #1a1f36;
1244
+ color: white;
1245
+ padding: 4px 8px;
1246
+ border-radius: 4px;
1247
+ font-size: 12px;
1248
+ white-space: nowrap;
1249
+ margin-bottom: 6px;
1250
+ pointer-events: none;
1251
+ z-index: 100;
1252
+
1253
+ &::after {
1254
+ content: '';
1255
+ position: absolute;
1256
+ top: 100%;
1257
+ left: 50%;
1258
+ transform: translateX(-50%);
1259
+ border: 4px solid transparent;
1260
+ border-top-color: #1a1f36;
1261
+ }
1262
+ `,
1148
1263
  name: _react3.css`
1149
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
1264
+ font-size: ${_chunkUFCWGUAGjs.fontSize.sm};
1150
1265
  font-weight: 500;
1151
- color: ${_chunkAY2DAS6Wjs.colors.text};
1266
+ color: ${_chunkUFCWGUAGjs.colors.text};
1152
1267
  white-space: nowrap;
1153
1268
  overflow: hidden;
1154
1269
  text-overflow: ellipsis;
@@ -1156,18 +1271,18 @@ var styles3 = {
1156
1271
  letter-spacing: -0.01em;
1157
1272
  `,
1158
1273
  size: _react3.css`
1159
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1160
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1274
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
1275
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1161
1276
  margin: 2px 0 0 0;
1162
1277
  `,
1163
1278
  openBtn: _react3.css`
1164
1279
  flex-shrink: 0;
1165
1280
  height: 28px;
1166
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1281
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
1167
1282
  font-weight: 500;
1168
- color: ${_chunkAY2DAS6Wjs.colors.primary};
1169
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1170
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1283
+ color: ${_chunkUFCWGUAGjs.colors.primary};
1284
+ background: ${_chunkUFCWGUAGjs.colors.surface};
1285
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1171
1286
  padding: 0 10px;
1172
1287
  cursor: pointer;
1173
1288
  border-radius: 4px;
@@ -1176,8 +1291,8 @@ var styles3 = {
1176
1291
  align-items: center;
1177
1292
 
1178
1293
  &:hover {
1179
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryLight};
1180
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1294
+ background-color: ${_chunkUFCWGUAGjs.colors.primaryLight};
1295
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
1181
1296
  }
1182
1297
  `,
1183
1298
  selectAllRow: _react3.css`
@@ -1185,31 +1300,31 @@ var styles3 = {
1185
1300
  align-items: center;
1186
1301
  margin-bottom: 16px;
1187
1302
  padding: 12px 16px;
1188
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1303
+ background: ${_chunkUFCWGUAGjs.colors.surface};
1189
1304
  border-radius: 8px;
1190
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1305
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1191
1306
  `,
1192
1307
  selectAllLabel: _react3.css`
1193
1308
  display: flex;
1194
1309
  align-items: center;
1195
1310
  gap: 10px;
1196
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
1311
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
1197
1312
  font-weight: 500;
1198
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1313
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
1199
1314
  cursor: pointer;
1200
1315
 
1201
1316
  &:hover {
1202
- color: ${_chunkAY2DAS6Wjs.colors.text};
1317
+ color: ${_chunkUFCWGUAGjs.colors.text};
1203
1318
  }
1204
1319
  `,
1205
1320
  selectAllCheckbox: _react3.css`
1206
1321
  width: 16px;
1207
1322
  height: 16px;
1208
- accent-color: ${_chunkAY2DAS6Wjs.colors.primary};
1323
+ accent-color: ${_chunkUFCWGUAGjs.colors.primary};
1209
1324
  `
1210
1325
  };
1211
1326
  function StudioFileGrid() {
1212
- const { currentPath, setCurrentPath, navigateUp, selectedItems, toggleSelection, selectRange, lastSelectedPath, selectAll, clearSelection, refreshKey, setFocusedItem, triggerRefresh } = useStudio();
1327
+ const { currentPath, setCurrentPath, navigateUp, selectedItems, toggleSelection, selectRange, lastSelectedPath, selectAll, clearSelection, refreshKey, setFocusedItem, triggerRefresh, searchQuery } = useStudio();
1213
1328
  const [items, setItems] = _react.useState.call(void 0, []);
1214
1329
  const [loading, setLoading] = _react.useState.call(void 0, true);
1215
1330
  const isInitialLoad = _react.useRef.call(void 0, true);
@@ -1246,7 +1361,12 @@ function StudioFileGrid() {
1246
1361
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles3.emptyText, children: "Upload images to get started" })
1247
1362
  ] });
1248
1363
  }
1249
- const sortedItems = [...items].sort((a, b) => {
1364
+ const filteredItems = searchQuery ? items.filter((item) => {
1365
+ if (item.type === "folder") return true;
1366
+ const query = searchQuery.toLowerCase();
1367
+ return item.name.toLowerCase().includes(query);
1368
+ }) : items;
1369
+ const sortedItems = [...filteredItems].sort((a, b) => {
1250
1370
  if (a.type === "folder" && b.type !== "folder") return -1;
1251
1371
  if (a.type !== "folder" && b.type === "folder") return 1;
1252
1372
  return a.name.localeCompare(b.name);
@@ -1335,8 +1455,17 @@ function StudioFileGrid() {
1335
1455
  ] });
1336
1456
  }
1337
1457
  function GridItem({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1458
+ const [showCopied, setShowCopied] = _react.useState.call(void 0, false);
1338
1459
  const isFolder = item.type === "folder";
1339
1460
  const isImage = !isFolder && item.thumbnail !== void 0;
1461
+ const isImagesFolder = isFolder && (item.name === "images" || item.path.includes("/images/"));
1462
+ const handleCopyPath = (e) => {
1463
+ e.stopPropagation();
1464
+ const pathToCopy = "/" + item.path;
1465
+ navigator.clipboard.writeText(pathToCopy);
1466
+ setShowCopied(true);
1467
+ setTimeout(() => setShowCopied(false), 1500);
1468
+ };
1340
1469
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1341
1470
  "div",
1342
1471
  {
@@ -1360,7 +1489,10 @@ function GridItem({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1360
1489
  }
1361
1490
  ),
1362
1491
  item.cdnSynced && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { css: styles3.cdnBadge, children: "CDN" }),
1363
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles3.content, children: isFolder ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles3.folderIcon, fill: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: "M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z" }) }) : isImage && item.hasThumbnail ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1492
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles3.content, children: isFolder ? isImagesFolder ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles3.imagesFolderWrapper, children: [
1493
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles3.imagesFolderIcon, fill: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: "M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z" }) }),
1494
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles3.lockIcon, fill: "currentColor", viewBox: "0 0 20 20", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { fillRule: "evenodd", d: "M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z", clipRule: "evenodd" }) })
1495
+ ] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles3.folderIcon, fill: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: "M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z" }) }) : isImage && item.hasThumbnail ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1364
1496
  "img",
1365
1497
  {
1366
1498
  css: styles3.image,
@@ -1392,17 +1524,31 @@ function GridItem({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1392
1524
  item.totalSize !== void 0 ? formatFileSize(item.totalSize) : ""
1393
1525
  ] }) : item.size !== void 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles3.size, children: formatFileSize(item.size) })
1394
1526
  ] }),
1395
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1396
- "button",
1397
- {
1398
- css: styles3.openBtn,
1399
- onClick: (e) => {
1400
- e.stopPropagation();
1401
- onOpen();
1402
- },
1403
- children: "Open"
1404
- }
1405
- )
1527
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles3.buttonRow, children: [
1528
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1529
+ "button",
1530
+ {
1531
+ css: styles3.copyBtn,
1532
+ onClick: handleCopyPath,
1533
+ title: "Copy file path",
1534
+ children: [
1535
+ showCopied && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { css: styles3.tooltip, children: "Copied!" }),
1536
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles3.copyIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z" }) })
1537
+ ]
1538
+ }
1539
+ ),
1540
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1541
+ "button",
1542
+ {
1543
+ css: styles3.openBtn,
1544
+ onClick: (e) => {
1545
+ e.stopPropagation();
1546
+ onOpen();
1547
+ },
1548
+ children: "Open"
1549
+ }
1550
+ )
1551
+ ] })
1406
1552
  ] }) })
1407
1553
  ]
1408
1554
  }
@@ -1445,8 +1591,8 @@ var styles4 = {
1445
1591
  width: 32px;
1446
1592
  height: 32px;
1447
1593
  border-radius: 50%;
1448
- border: 3px solid ${_chunkAY2DAS6Wjs.colors.border};
1449
- border-top-color: ${_chunkAY2DAS6Wjs.colors.primary};
1594
+ border: 3px solid ${_chunkUFCWGUAGjs.colors.border};
1595
+ border-top-color: ${_chunkUFCWGUAGjs.colors.primary};
1450
1596
  animation: ${spin3} 0.8s linear infinite;
1451
1597
  `,
1452
1598
  empty: _react3.css`
@@ -1455,12 +1601,12 @@ var styles4 = {
1455
1601
  align-items: center;
1456
1602
  justify-content: center;
1457
1603
  height: 256px;
1458
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1604
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
1459
1605
  `,
1460
1606
  tableWrapper: _react3.css`
1461
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1607
+ background: ${_chunkUFCWGUAGjs.colors.surface};
1462
1608
  border-radius: 8px;
1463
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1609
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1464
1610
  overflow: hidden;
1465
1611
  `,
1466
1612
  table: _react3.css`
@@ -1470,13 +1616,13 @@ var styles4 = {
1470
1616
  th: _react3.css`
1471
1617
  text-align: left;
1472
1618
  font-size: 11px;
1473
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1619
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1474
1620
  text-transform: uppercase;
1475
1621
  letter-spacing: 0.05em;
1476
1622
  padding: 12px 16px;
1477
1623
  font-weight: 600;
1478
- background: ${_chunkAY2DAS6Wjs.colors.background};
1479
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1624
+ background: ${_chunkUFCWGUAGjs.colors.background};
1625
+ border-bottom: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1480
1626
  `,
1481
1627
  thCheckbox: _react3.css`
1482
1628
  width: 48px;
@@ -1497,25 +1643,26 @@ var styles4 = {
1497
1643
  user-select: none;
1498
1644
 
1499
1645
  &:hover {
1500
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1646
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
1501
1647
  }
1502
1648
 
1503
1649
  &:not(:last-child) td {
1504
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.borderLight};
1650
+ border-bottom: 1px solid ${_chunkUFCWGUAGjs.colors.borderLight};
1505
1651
  }
1506
1652
  `,
1507
1653
  rowSelected: _react3.css`
1508
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryLight};
1654
+ background-color: ${_chunkUFCWGUAGjs.colors.primaryLight};
1509
1655
 
1510
1656
  &:hover {
1511
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryLight};
1657
+ background-color: ${_chunkUFCWGUAGjs.colors.primaryLight};
1512
1658
  }
1513
1659
  `,
1514
1660
  parentRow: _react3.css`
1515
1661
  cursor: pointer;
1662
+ border-bottom: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1516
1663
 
1517
1664
  &:hover {
1518
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1665
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
1519
1666
  }
1520
1667
  `,
1521
1668
  td: _react3.css`
@@ -1524,12 +1671,66 @@ var styles4 = {
1524
1671
  checkboxCell: _react3.css`
1525
1672
  padding: 12px 16px;
1526
1673
  cursor: pointer;
1674
+ vertical-align: middle;
1527
1675
  `,
1528
1676
  checkbox: _react3.css`
1529
1677
  width: 16px;
1530
1678
  height: 16px;
1531
- accent-color: ${_chunkAY2DAS6Wjs.colors.primary};
1679
+ accent-color: ${_chunkUFCWGUAGjs.colors.primary};
1680
+ cursor: pointer;
1681
+ display: block;
1682
+ `,
1683
+ copyBtn: _react3.css`
1684
+ position: relative;
1685
+ flex-shrink: 0;
1686
+ height: 28px;
1687
+ width: 28px;
1688
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
1689
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
1690
+ background: ${_chunkUFCWGUAGjs.colors.surface};
1691
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1692
+ padding: 0;
1532
1693
  cursor: pointer;
1694
+ border-radius: 4px;
1695
+ transition: all 0.15s ease;
1696
+ display: inline-flex;
1697
+ align-items: center;
1698
+ justify-content: center;
1699
+
1700
+ &:hover {
1701
+ background: ${_chunkUFCWGUAGjs.colors.surfaceHover};
1702
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
1703
+ color: ${_chunkUFCWGUAGjs.colors.text};
1704
+ }
1705
+ `,
1706
+ copyIcon: _react3.css`
1707
+ width: 14px;
1708
+ height: 14px;
1709
+ `,
1710
+ tooltip: _react3.css`
1711
+ position: absolute;
1712
+ bottom: 100%;
1713
+ left: 50%;
1714
+ transform: translateX(-50%);
1715
+ background: #1a1f36;
1716
+ color: white;
1717
+ padding: 4px 8px;
1718
+ border-radius: 4px;
1719
+ font-size: 12px;
1720
+ white-space: nowrap;
1721
+ margin-bottom: 6px;
1722
+ pointer-events: none;
1723
+ z-index: 100;
1724
+
1725
+ &::after {
1726
+ content: '';
1727
+ position: absolute;
1728
+ top: 100%;
1729
+ left: 50%;
1730
+ transform: translateX(-50%);
1731
+ border: 4px solid transparent;
1732
+ border-top-color: #1a1f36;
1733
+ }
1533
1734
  `,
1534
1735
  nameCell: _react3.css`
1535
1736
  display: flex;
@@ -1542,16 +1743,34 @@ var styles4 = {
1542
1743
  color: #f5a623;
1543
1744
  flex-shrink: 0;
1544
1745
  `,
1746
+ imagesFolderWrapper: _react3.css`
1747
+ position: relative;
1748
+ display: flex;
1749
+ align-items: center;
1750
+ `,
1751
+ imagesFolderIcon: _react3.css`
1752
+ width: 20px;
1753
+ height: 20px;
1754
+ color: ${_chunkUFCWGUAGjs.colors.imagesFolder};
1755
+ flex-shrink: 0;
1756
+ `,
1757
+ lockIcon: _react3.css`
1758
+ width: 10px;
1759
+ height: 10px;
1760
+ color: ${_chunkUFCWGUAGjs.colors.imagesFolder};
1761
+ margin-left: -6px;
1762
+ margin-top: 8px;
1763
+ `,
1545
1764
  parentIcon: _react3.css`
1546
1765
  width: 20px;
1547
1766
  height: 20px;
1548
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1767
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1549
1768
  flex-shrink: 0;
1550
1769
  `,
1551
1770
  fileIcon: _react3.css`
1552
1771
  width: 20px;
1553
1772
  height: 20px;
1554
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1773
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1555
1774
  flex-shrink: 0;
1556
1775
  `,
1557
1776
  thumbnail: _react3.css`
@@ -1562,7 +1781,7 @@ var styles4 = {
1562
1781
  object-fit: contain;
1563
1782
  border-radius: 4px;
1564
1783
  flex-shrink: 0;
1565
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.borderLight};
1784
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.borderLight};
1566
1785
  `,
1567
1786
  noThumbnail: _react3.css`
1568
1787
  width: 36px;
@@ -1570,56 +1789,56 @@ var styles4 = {
1570
1789
  display: flex;
1571
1790
  align-items: center;
1572
1791
  justify-content: center;
1573
- background: ${_chunkAY2DAS6Wjs.colors.background};
1574
- border: 1px dashed ${_chunkAY2DAS6Wjs.colors.border};
1792
+ background: ${_chunkUFCWGUAGjs.colors.background};
1793
+ border: 1px dashed ${_chunkUFCWGUAGjs.colors.border};
1575
1794
  border-radius: 4px;
1576
1795
  flex-shrink: 0;
1577
1796
  cursor: pointer;
1578
1797
  transition: all 0.15s ease;
1579
1798
 
1580
1799
  &:hover {
1581
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1582
- background: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1800
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
1801
+ background: ${_chunkUFCWGUAGjs.colors.surfaceHover};
1583
1802
  }
1584
1803
  `,
1585
1804
  noThumbnailIcon: _react3.css`
1586
1805
  width: 16px;
1587
1806
  height: 16px;
1588
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1807
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1589
1808
  `,
1590
1809
  name: _react3.css`
1591
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
1810
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
1592
1811
  font-weight: 500;
1593
- color: ${_chunkAY2DAS6Wjs.colors.text};
1812
+ color: ${_chunkUFCWGUAGjs.colors.text};
1594
1813
  letter-spacing: -0.01em;
1595
1814
  `,
1596
1815
  meta: _react3.css`
1597
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
1598
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1816
+ font-size: ${_chunkUFCWGUAGjs.fontSize.sm};
1817
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
1599
1818
  `,
1600
1819
  cdnBadge: _react3.css`
1601
1820
  display: inline-flex;
1602
1821
  align-items: center;
1603
1822
  gap: 4px;
1604
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1823
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
1605
1824
  font-weight: 500;
1606
- color: ${_chunkAY2DAS6Wjs.colors.success};
1825
+ color: ${_chunkUFCWGUAGjs.colors.success};
1607
1826
  `,
1608
1827
  cdnIcon: _react3.css`
1609
1828
  width: 12px;
1610
1829
  height: 12px;
1611
1830
  `,
1612
1831
  cdnEmpty: _react3.css`
1613
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
1614
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1832
+ font-size: ${_chunkUFCWGUAGjs.fontSize.sm};
1833
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1615
1834
  `,
1616
1835
  openBtn: _react3.css`
1617
1836
  height: 28px;
1618
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1837
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
1619
1838
  font-weight: 500;
1620
- color: ${_chunkAY2DAS6Wjs.colors.primary};
1621
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1622
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1839
+ color: ${_chunkUFCWGUAGjs.colors.primary};
1840
+ background: ${_chunkUFCWGUAGjs.colors.surface};
1841
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1623
1842
  padding: 0 12px;
1624
1843
  cursor: pointer;
1625
1844
  border-radius: 4px;
@@ -1629,13 +1848,13 @@ var styles4 = {
1629
1848
  margin-left: auto;
1630
1849
 
1631
1850
  &:hover {
1632
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryLight};
1633
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1851
+ background-color: ${_chunkUFCWGUAGjs.colors.primaryLight};
1852
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
1634
1853
  }
1635
1854
  `
1636
1855
  };
1637
1856
  function StudioFileList() {
1638
- const { currentPath, setCurrentPath, navigateUp, selectedItems, toggleSelection, selectRange, lastSelectedPath, selectAll, clearSelection, refreshKey, setFocusedItem, triggerRefresh } = useStudio();
1857
+ const { currentPath, setCurrentPath, navigateUp, selectedItems, toggleSelection, selectRange, lastSelectedPath, selectAll, clearSelection, refreshKey, setFocusedItem, triggerRefresh, searchQuery } = useStudio();
1639
1858
  const [items, setItems] = _react.useState.call(void 0, []);
1640
1859
  const [loading, setLoading] = _react.useState.call(void 0, true);
1641
1860
  const isInitialLoad = _react.useRef.call(void 0, true);
@@ -1668,7 +1887,12 @@ function StudioFileList() {
1668
1887
  if (items.length === 0 && isAtRoot) {
1669
1888
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles4.empty, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { children: "No files in this folder" }) });
1670
1889
  }
1671
- const sortedItems = [...items].sort((a, b) => {
1890
+ const filteredItems = searchQuery ? items.filter((item) => {
1891
+ if (item.type === "folder") return true;
1892
+ const query = searchQuery.toLowerCase();
1893
+ return item.name.toLowerCase().includes(query);
1894
+ }) : items;
1895
+ const sortedItems = [...filteredItems].sort((a, b) => {
1672
1896
  if (a.type === "folder" && b.type !== "folder") return -1;
1673
1897
  if (a.type !== "folder" && b.type === "folder") return 1;
1674
1898
  return a.name.localeCompare(b.name);
@@ -1754,8 +1978,17 @@ function StudioFileList() {
1754
1978
  ] }) });
1755
1979
  }
1756
1980
  function ListRow({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1981
+ const [showCopied, setShowCopied] = _react.useState.call(void 0, false);
1757
1982
  const isFolder = item.type === "folder";
1758
1983
  const isImage = !isFolder && item.thumbnail !== void 0;
1984
+ const isImagesFolder = isFolder && (item.name === "images" || item.path.includes("/images/"));
1985
+ const handleCopyPath = (e) => {
1986
+ e.stopPropagation();
1987
+ const pathToCopy = "/" + item.path;
1988
+ navigator.clipboard.writeText(pathToCopy);
1989
+ setShowCopied(true);
1990
+ setTimeout(() => setShowCopied(false), 1500);
1991
+ };
1759
1992
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1760
1993
  "tr",
1761
1994
  {
@@ -1779,7 +2012,10 @@ function ListRow({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1779
2012
  }
1780
2013
  ),
1781
2014
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "td", { css: styles4.td, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles4.nameCell, children: [
1782
- isFolder ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles4.folderIcon, fill: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: "M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z" }) }) : isImage && item.hasThumbnail ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "img", { css: styles4.thumbnail, src: item.thumbnail, alt: item.name, loading: "lazy" }) : isImage && !item.hasThumbnail ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2015
+ isFolder ? isImagesFolder ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles4.imagesFolderWrapper, children: [
2016
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles4.imagesFolderIcon, fill: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: "M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z" }) }),
2017
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles4.lockIcon, fill: "currentColor", viewBox: "0 0 20 20", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { fillRule: "evenodd", d: "M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z", clipRule: "evenodd" }) })
2018
+ ] }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles4.folderIcon, fill: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { d: "M10 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V8a2 2 0 00-2-2h-8l-2-2z" }) }) : isImage && item.hasThumbnail ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "img", { css: styles4.thumbnail, src: item.thumbnail, alt: item.name, loading: "lazy" }) : isImage && !item.hasThumbnail ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1783
2019
  "button",
1784
2020
  {
1785
2021
  css: styles4.noThumbnail,
@@ -1792,6 +2028,18 @@ function ListRow({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1792
2028
  }
1793
2029
  ) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles4.fileIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 1.5, d: "M7 21h10a2 2 0 002-2V9.414a1 1 0 00-.293-.707l-5.414-5.414A1 1 0 0012.586 3H7a2 2 0 00-2 2v14a2 2 0 002 2z" }) }),
1794
2030
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { css: styles4.name, title: item.name, children: truncateMiddle2(item.name) }),
2031
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
2032
+ "button",
2033
+ {
2034
+ css: styles4.copyBtn,
2035
+ onClick: handleCopyPath,
2036
+ title: "Copy file path",
2037
+ children: [
2038
+ showCopied && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { css: styles4.tooltip, children: "Copied!" }),
2039
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles4.copyIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z" }) })
2040
+ ]
2041
+ }
2042
+ ),
1795
2043
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1796
2044
  "button",
1797
2045
  {
@@ -1862,7 +2110,8 @@ var styles5 = {
1862
2110
  display: flex;
1863
2111
  flex: 1;
1864
2112
  margin: 24px;
1865
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2113
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2114
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1866
2115
  border-radius: 12px;
1867
2116
  overflow: hidden;
1868
2117
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
@@ -1875,34 +2124,86 @@ var styles5 = {
1875
2124
  align-items: center;
1876
2125
  justify-content: center;
1877
2126
  padding: 24px;
1878
- background: ${_chunkAY2DAS6Wjs.colors.background};
2127
+ background: ${_chunkUFCWGUAGjs.colors.background};
1879
2128
  overflow: auto;
1880
2129
  `,
1881
- mainCloseBtn: _react3.css`
2130
+ headerButtons: _react3.css`
1882
2131
  position: absolute;
1883
2132
  top: 16px;
1884
2133
  right: 16px;
2134
+ display: flex;
2135
+ gap: 8px;
2136
+ z-index: 10;
2137
+ `,
2138
+ copyBtn: _react3.css`
2139
+ position: relative;
1885
2140
  padding: 8px;
1886
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1887
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2141
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2142
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1888
2143
  border-radius: 8px;
1889
2144
  cursor: pointer;
1890
2145
  transition: all 0.15s ease;
1891
2146
  display: flex;
1892
2147
  align-items: center;
1893
2148
  justify-content: center;
1894
- z-index: 10;
1895
2149
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
1896
2150
 
1897
2151
  &:hover {
1898
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1899
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2152
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
2153
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
2154
+ }
2155
+ `,
2156
+ copyIcon: _react3.css`
2157
+ width: 20px;
2158
+ height: 20px;
2159
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
2160
+ `,
2161
+ tooltip: _react3.css`
2162
+ position: absolute;
2163
+ bottom: 100%;
2164
+ left: 50%;
2165
+ transform: translateX(-50%);
2166
+ background: #1a1f36;
2167
+ color: white;
2168
+ padding: 4px 8px;
2169
+ border-radius: 4px;
2170
+ font-size: 12px;
2171
+ white-space: nowrap;
2172
+ margin-bottom: 6px;
2173
+ pointer-events: none;
2174
+ z-index: 100;
2175
+
2176
+ &::after {
2177
+ content: '';
2178
+ position: absolute;
2179
+ top: 100%;
2180
+ left: 50%;
2181
+ transform: translateX(-50%);
2182
+ border: 4px solid transparent;
2183
+ border-top-color: #1a1f36;
2184
+ }
2185
+ `,
2186
+ mainCloseBtn: _react3.css`
2187
+ padding: 8px;
2188
+ background: ${_chunkUFCWGUAGjs.colors.danger};
2189
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.danger};
2190
+ border-radius: 8px;
2191
+ cursor: pointer;
2192
+ transition: all 0.15s ease;
2193
+ display: flex;
2194
+ align-items: center;
2195
+ justify-content: center;
2196
+ box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
2197
+
2198
+ &:hover {
2199
+ background-color: ${_chunkUFCWGUAGjs.colors.dangerHover};
2200
+ border-color: ${_chunkUFCWGUAGjs.colors.dangerHover};
1900
2201
  }
1901
2202
  `,
1902
2203
  mainCloseIcon: _react3.css`
1903
2204
  width: 20px;
1904
2205
  height: 20px;
1905
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2206
+ color: white;
1906
2207
  `,
1907
2208
  mediaWrapper: _react3.css`
1908
2209
  max-width: 100%;
@@ -1930,38 +2231,38 @@ var styles5 = {
1930
2231
  align-items: center;
1931
2232
  justify-content: center;
1932
2233
  padding: 48px;
1933
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2234
+ background: ${_chunkUFCWGUAGjs.colors.surface};
1934
2235
  border-radius: 12px;
1935
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2236
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1936
2237
  `,
1937
2238
  fileIcon: _react3.css`
1938
2239
  width: 80px;
1939
2240
  height: 80px;
1940
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
2241
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
1941
2242
  margin-bottom: 16px;
1942
2243
  `,
1943
2244
  fileName: _react3.css`
1944
- font-size: ${_chunkAY2DAS6Wjs.fontSize.lg};
2245
+ font-size: ${_chunkUFCWGUAGjs.fontSize.lg};
1945
2246
  font-weight: 600;
1946
- color: ${_chunkAY2DAS6Wjs.colors.text};
2247
+ color: ${_chunkUFCWGUAGjs.colors.text};
1947
2248
  margin: 0;
1948
2249
  `,
1949
2250
  sidebar: _react3.css`
1950
2251
  width: 280px;
1951
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1952
- border-left: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2252
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2253
+ border-left: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1953
2254
  display: flex;
1954
2255
  flex-direction: column;
1955
2256
  overflow: hidden;
1956
2257
  `,
1957
2258
  sidebarHeader: _react3.css`
1958
2259
  padding: 16px 20px;
1959
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2260
+ border-bottom: 1px solid ${_chunkUFCWGUAGjs.colors.border};
1960
2261
  `,
1961
2262
  sidebarTitle: _react3.css`
1962
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2263
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
1963
2264
  font-weight: 600;
1964
- color: ${_chunkAY2DAS6Wjs.colors.text};
2265
+ color: ${_chunkUFCWGUAGjs.colors.text};
1965
2266
  margin: 0;
1966
2267
  `,
1967
2268
  sidebarContent: _react3.css`
@@ -1978,13 +2279,13 @@ var styles5 = {
1978
2279
  infoRow: _react3.css`
1979
2280
  display: flex;
1980
2281
  justify-content: space-between;
1981
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
2282
+ font-size: ${_chunkUFCWGUAGjs.fontSize.sm};
1982
2283
  `,
1983
2284
  infoLabel: _react3.css`
1984
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2285
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
1985
2286
  `,
1986
2287
  infoValue: _react3.css`
1987
- color: ${_chunkAY2DAS6Wjs.colors.text};
2288
+ color: ${_chunkUFCWGUAGjs.colors.text};
1988
2289
  font-weight: 500;
1989
2290
  text-align: right;
1990
2291
  max-width: 160px;
@@ -1993,7 +2294,7 @@ var styles5 = {
1993
2294
  white-space: nowrap;
1994
2295
  `,
1995
2296
  infoValueWrap: _react3.css`
1996
- color: ${_chunkAY2DAS6Wjs.colors.text};
2297
+ color: ${_chunkUFCWGUAGjs.colors.text};
1997
2298
  font-weight: 500;
1998
2299
  text-align: right;
1999
2300
  max-width: 160px;
@@ -2011,27 +2312,27 @@ var styles5 = {
2011
2312
  gap: 10px;
2012
2313
  width: 100%;
2013
2314
  padding: 12px 14px;
2014
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2315
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
2015
2316
  font-weight: 500;
2016
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2017
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2317
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2318
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2018
2319
  border-radius: 6px;
2019
2320
  cursor: pointer;
2020
2321
  transition: all 0.15s ease;
2021
- color: ${_chunkAY2DAS6Wjs.colors.text};
2322
+ color: ${_chunkUFCWGUAGjs.colors.text};
2022
2323
  text-align: left;
2023
2324
 
2024
2325
  &:hover {
2025
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2026
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2326
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
2327
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
2027
2328
  }
2028
2329
  `,
2029
2330
  actionBtnDanger: _react3.css`
2030
- color: ${_chunkAY2DAS6Wjs.colors.danger};
2331
+ color: ${_chunkUFCWGUAGjs.colors.danger};
2031
2332
 
2032
2333
  &:hover {
2033
- background-color: ${_chunkAY2DAS6Wjs.colors.dangerLight};
2034
- border-color: ${_chunkAY2DAS6Wjs.colors.danger};
2334
+ background-color: ${_chunkUFCWGUAGjs.colors.dangerLight};
2335
+ border-color: ${_chunkUFCWGUAGjs.colors.danger};
2035
2336
  }
2036
2337
  `,
2037
2338
  actionIcon: _react3.css`
@@ -2044,6 +2345,7 @@ function StudioDetailView() {
2044
2345
  const { focusedItem, setFocusedItem, triggerRefresh, clearSelection } = useStudio();
2045
2346
  const [showDeleteConfirm, setShowDeleteConfirm] = _react.useState.call(void 0, false);
2046
2347
  const [alertMessage, setAlertMessage] = _react.useState.call(void 0, null);
2348
+ const [showCopied, setShowCopied] = _react.useState.call(void 0, false);
2047
2349
  if (!focusedItem) return null;
2048
2350
  const isImage = isImageFile(focusedItem.name);
2049
2351
  const isVideo = isVideoFile(focusedItem.name);
@@ -2051,6 +2353,12 @@ function StudioDetailView() {
2051
2353
  const handleClose = () => {
2052
2354
  setFocusedItem(null);
2053
2355
  };
2356
+ const handleCopyPath = () => {
2357
+ const pathToCopy = "/" + focusedItem.path;
2358
+ navigator.clipboard.writeText(pathToCopy);
2359
+ setShowCopied(true);
2360
+ setTimeout(() => setShowCopied(false), 1500);
2361
+ };
2054
2362
  const handleRename = () => {
2055
2363
  const newName = prompt("Enter new name:", focusedItem.name);
2056
2364
  if (newName && newName !== focusedItem.name) {
@@ -2124,7 +2432,13 @@ function StudioDetailView() {
2124
2432
  ),
2125
2433
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles5.overlay, onClick: handleClose, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles5.container, onClick: (e) => e.stopPropagation(), children: [
2126
2434
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles5.main, children: [
2127
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "button", { css: styles5.mainCloseBtn, onClick: handleClose, "aria-label": "Close", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles5.mainCloseIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M6 18L18 6M6 6l12 12" }) }) }),
2435
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles5.headerButtons, children: [
2436
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "button", { css: styles5.copyBtn, onClick: handleCopyPath, title: "Copy file path", children: [
2437
+ showCopied && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { css: styles5.tooltip, children: "Copied!" }),
2438
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles5.copyIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z" }) })
2439
+ ] }),
2440
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "button", { css: styles5.mainCloseBtn, onClick: handleClose, "aria-label": "Close", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles5.mainCloseIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M6 18L18 6M6 6l12 12" }) }) })
2441
+ ] }),
2128
2442
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles5.mediaWrapper, children: renderMedia() })
2129
2443
  ] }),
2130
2444
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles5.sidebar, children: [
@@ -2194,8 +2508,8 @@ var styles6 = {
2194
2508
  btn: _react3.css`
2195
2509
  height: ${btnHeight2};
2196
2510
  padding: 0 12px;
2197
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2198
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2511
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2512
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2199
2513
  border-radius: 6px;
2200
2514
  cursor: pointer;
2201
2515
  transition: all 0.15s ease;
@@ -2204,14 +2518,14 @@ var styles6 = {
2204
2518
  justify-content: center;
2205
2519
 
2206
2520
  &:hover {
2207
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2208
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2521
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
2522
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
2209
2523
  }
2210
2524
  `,
2211
2525
  icon: _react3.css`
2212
2526
  width: 16px;
2213
2527
  height: 16px;
2214
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2528
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
2215
2529
  `,
2216
2530
  overlay: _react3.css`
2217
2531
  position: fixed;
@@ -2227,9 +2541,9 @@ var styles6 = {
2227
2541
  backdrop-filter: blur(4px);
2228
2542
  `,
2229
2543
  panel: _react3.css`
2230
- ${_chunkAY2DAS6Wjs.baseReset}
2544
+ ${_chunkUFCWGUAGjs.baseReset}
2231
2545
  position: relative;
2232
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
2546
+ background-color: ${_chunkUFCWGUAGjs.colors.surface};
2233
2547
  border-radius: 12px;
2234
2548
  box-shadow: 0 30px 60px -12px rgba(50, 50, 93, 0.25), 0 18px 36px -18px rgba(0, 0, 0, 0.3);
2235
2549
  width: 100%;
@@ -2243,16 +2557,16 @@ var styles6 = {
2243
2557
  margin-bottom: 24px;
2244
2558
  `,
2245
2559
  title: _react3.css`
2246
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xl};
2560
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xl};
2247
2561
  font-weight: 600;
2248
- color: ${_chunkAY2DAS6Wjs.colors.text};
2562
+ color: ${_chunkUFCWGUAGjs.colors.text};
2249
2563
  margin: 0;
2250
2564
  letter-spacing: -0.02em;
2251
2565
  `,
2252
2566
  closeBtn: _react3.css`
2253
2567
  padding: 6px;
2254
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2255
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2568
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2569
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2256
2570
  border-radius: 6px;
2257
2571
  cursor: pointer;
2258
2572
  transition: all 0.15s ease;
@@ -2261,8 +2575,8 @@ var styles6 = {
2261
2575
  justify-content: center;
2262
2576
 
2263
2577
  &:hover {
2264
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2265
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2578
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
2579
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
2266
2580
  }
2267
2581
  `,
2268
2582
  sections: _react3.css`
@@ -2271,24 +2585,79 @@ var styles6 = {
2271
2585
  gap: 24px;
2272
2586
  `,
2273
2587
  sectionTitle: _react3.css`
2274
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2588
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
2275
2589
  font-weight: 600;
2276
- color: ${_chunkAY2DAS6Wjs.colors.text};
2590
+ color: ${_chunkUFCWGUAGjs.colors.text};
2277
2591
  margin: 0 0 12px 0;
2278
2592
  `,
2279
2593
  description: _react3.css`
2280
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
2281
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2594
+ font-size: ${_chunkUFCWGUAGjs.fontSize.sm};
2595
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
2282
2596
  margin: 0 0 12px 0;
2283
2597
  `,
2598
+ codeWrapper: _react3.css`
2599
+ position: relative;
2600
+ `,
2284
2601
  code: _react3.css`
2285
- background-color: ${_chunkAY2DAS6Wjs.colors.background};
2602
+ background-color: ${_chunkUFCWGUAGjs.colors.background};
2286
2603
  border-radius: 8px;
2287
2604
  padding: 12px;
2605
+ padding-right: 40px;
2288
2606
  font-family: 'SF Mono', Monaco, Consolas, monospace;
2289
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
2290
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2291
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2607
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
2608
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
2609
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2610
+ overflow-x: auto;
2611
+ white-space: nowrap;
2612
+ `,
2613
+ copyBtn: _react3.css`
2614
+ position: absolute;
2615
+ top: 8px;
2616
+ right: 8px;
2617
+ padding: 4px;
2618
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2619
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2620
+ border-radius: 4px;
2621
+ cursor: pointer;
2622
+ transition: all 0.15s ease;
2623
+ display: flex;
2624
+ align-items: center;
2625
+ justify-content: center;
2626
+
2627
+ &:hover {
2628
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
2629
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
2630
+ }
2631
+ `,
2632
+ tooltip: _react3.css`
2633
+ position: absolute;
2634
+ bottom: 100%;
2635
+ left: 50%;
2636
+ transform: translateX(-50%);
2637
+ background: #1a1f36;
2638
+ color: white;
2639
+ padding: 4px 8px;
2640
+ border-radius: 4px;
2641
+ font-size: 12px;
2642
+ white-space: nowrap;
2643
+ margin-bottom: 6px;
2644
+ pointer-events: none;
2645
+ z-index: 100;
2646
+
2647
+ &::after {
2648
+ content: '';
2649
+ position: absolute;
2650
+ top: 100%;
2651
+ left: 50%;
2652
+ transform: translateX(-50%);
2653
+ border: 4px solid transparent;
2654
+ border-top-color: #1a1f36;
2655
+ }
2656
+ `,
2657
+ copyIcon: _react3.css`
2658
+ width: 14px;
2659
+ height: 14px;
2660
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
2292
2661
  `,
2293
2662
  codeLine: _react3.css`
2294
2663
  margin: 0 0 4px 0;
@@ -2300,21 +2669,21 @@ var styles6 = {
2300
2669
  input: _react3.css`
2301
2670
  width: 100%;
2302
2671
  padding: 10px 14px;
2303
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2672
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2304
2673
  border-radius: 6px;
2305
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2306
- color: ${_chunkAY2DAS6Wjs.colors.text};
2307
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2674
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
2675
+ color: ${_chunkUFCWGUAGjs.colors.text};
2676
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2308
2677
  transition: all 0.15s ease;
2309
2678
 
2310
2679
  &:focus {
2311
2680
  outline: none;
2312
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
2313
- box-shadow: 0 0 0 3px ${_chunkAY2DAS6Wjs.colors.primaryLight};
2681
+ border-color: ${_chunkUFCWGUAGjs.colors.primary};
2682
+ box-shadow: 0 0 0 3px ${_chunkUFCWGUAGjs.colors.primaryLight};
2314
2683
  }
2315
2684
 
2316
2685
  &::placeholder {
2317
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
2686
+ color: ${_chunkUFCWGUAGjs.colors.textMuted};
2318
2687
  }
2319
2688
  `,
2320
2689
  grid: _react3.css`
@@ -2323,50 +2692,50 @@ var styles6 = {
2323
2692
  gap: 12px;
2324
2693
  `,
2325
2694
  label: _react3.css`
2326
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
2695
+ font-size: ${_chunkUFCWGUAGjs.fontSize.xs};
2327
2696
  font-weight: 500;
2328
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2697
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
2329
2698
  display: block;
2330
2699
  margin-bottom: 6px;
2331
2700
  `,
2332
2701
  footer: _react3.css`
2333
2702
  margin-top: 24px;
2334
2703
  padding-top: 20px;
2335
- border-top: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2704
+ border-top: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2336
2705
  display: flex;
2337
2706
  justify-content: flex-end;
2338
2707
  gap: 12px;
2339
2708
  `,
2340
2709
  cancelBtn: _react3.css`
2341
2710
  padding: 10px 18px;
2342
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2711
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
2343
2712
  font-weight: 500;
2344
- color: ${_chunkAY2DAS6Wjs.colors.text};
2345
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2346
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2713
+ color: ${_chunkUFCWGUAGjs.colors.text};
2714
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2715
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2347
2716
  border-radius: 6px;
2348
2717
  cursor: pointer;
2349
2718
  transition: all 0.15s ease;
2350
2719
 
2351
2720
  &:hover {
2352
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2353
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2721
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
2722
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
2354
2723
  }
2355
2724
  `,
2356
2725
  saveBtn: _react3.css`
2357
2726
  padding: 10px 18px;
2358
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2727
+ font-size: ${_chunkUFCWGUAGjs.fontSize.base};
2359
2728
  font-weight: 500;
2360
2729
  color: white;
2361
- background-color: ${_chunkAY2DAS6Wjs.colors.primary};
2362
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.primary};
2730
+ background-color: ${_chunkUFCWGUAGjs.colors.primary};
2731
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.primary};
2363
2732
  border-radius: 6px;
2364
2733
  cursor: pointer;
2365
2734
  transition: all 0.15s ease;
2366
2735
 
2367
2736
  &:hover {
2368
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryHover};
2369
- border-color: ${_chunkAY2DAS6Wjs.colors.primaryHover};
2737
+ background-color: ${_chunkUFCWGUAGjs.colors.primaryHover};
2738
+ border-color: ${_chunkUFCWGUAGjs.colors.primaryHover};
2370
2739
  }
2371
2740
  `
2372
2741
  };
@@ -2393,7 +2762,18 @@ function StudioSettings() {
2393
2762
  isOpen && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SettingsPanel, { onClose: () => setIsOpen(false) })
2394
2763
  ] });
2395
2764
  }
2765
+ var envTemplate = `CLOUDFLARE_R2_ACCOUNT_ID=abc123def456ghi789
2766
+ CLOUDFLARE_R2_ACCESS_KEY_ID=your_access_key_id_here
2767
+ CLOUDFLARE_R2_SECRET_ACCESS_KEY=your_secret_access_key_here
2768
+ CLOUDFLARE_R2_BUCKET_NAME=my-images-bucket
2769
+ CLOUDFLARE_R2_PUBLIC_URL=https://cdn.yourdomain.com`;
2396
2770
  function SettingsPanel({ onClose }) {
2771
+ const [copied, setCopied] = _react.useState.call(void 0, false);
2772
+ const handleCopy = () => {
2773
+ navigator.clipboard.writeText(envTemplate);
2774
+ setCopied(true);
2775
+ setTimeout(() => setCopied(false), 2e3);
2776
+ };
2397
2777
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles6.overlay, onClick: onClose, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles6.panel, onClick: (e) => e.stopPropagation(), children: [
2398
2778
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles6.header, children: [
2399
2779
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h2", { css: styles6.title, children: "Settings" }),
@@ -2403,12 +2783,18 @@ function SettingsPanel({ onClose }) {
2403
2783
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "section", { children: [
2404
2784
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { css: styles6.sectionTitle, children: "Cloudflare R2" }),
2405
2785
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.description, children: "Configure in .env.local file:" }),
2406
- /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles6.code, children: [
2407
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_ACCOUNT_ID" }),
2408
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_ACCESS_KEY_ID" }),
2409
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_SECRET_ACCESS_KEY" }),
2410
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_BUCKET_NAME" }),
2411
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_PUBLIC_URL" })
2786
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles6.codeWrapper, children: [
2787
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "button", { css: styles6.copyBtn, onClick: handleCopy, title: "Copy to clipboard", children: [
2788
+ copied && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { css: styles6.tooltip, children: "Copied!" }),
2789
+ copied ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles6.copyIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M5 13l4 4L19 7" }) }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles6.copyIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z" }) })
2790
+ ] }),
2791
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles6.code, children: [
2792
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_ACCOUNT_ID=abc123def456ghi789" }),
2793
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_ACCESS_KEY_ID=your_access_key_id_here" }),
2794
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_SECRET_ACCESS_KEY=your_secret_access_key_here" }),
2795
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_BUCKET_NAME=my-images-bucket" }),
2796
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_PUBLIC_URL=https://cdn.yourdomain.com" })
2797
+ ] })
2412
2798
  ] })
2413
2799
  ] }),
2414
2800
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "section", { children: [
@@ -2446,24 +2832,24 @@ function SettingsPanel({ onClose }) {
2446
2832
  var btnHeight3 = "36px";
2447
2833
  var styles7 = {
2448
2834
  container: _react3.css`
2449
- ${_chunkAY2DAS6Wjs.baseReset}
2835
+ ${_chunkUFCWGUAGjs.baseReset}
2450
2836
  display: flex;
2451
2837
  flex-direction: column;
2452
2838
  height: 100%;
2453
- background: ${_chunkAY2DAS6Wjs.colors.background};
2839
+ background: ${_chunkUFCWGUAGjs.colors.background};
2454
2840
  `,
2455
2841
  header: _react3.css`
2456
2842
  display: flex;
2457
2843
  align-items: center;
2458
2844
  justify-content: space-between;
2459
2845
  padding: 12px 24px;
2460
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2461
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2846
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2847
+ border-bottom: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2462
2848
  `,
2463
2849
  title: _react3.css`
2464
- font-size: ${_chunkAY2DAS6Wjs.fontSize.lg};
2850
+ font-size: ${_chunkUFCWGUAGjs.fontSize.lg};
2465
2851
  font-weight: 600;
2466
- color: ${_chunkAY2DAS6Wjs.colors.text};
2852
+ color: ${_chunkUFCWGUAGjs.colors.text};
2467
2853
  margin: 0;
2468
2854
  letter-spacing: -0.02em;
2469
2855
  `,
@@ -2475,8 +2861,8 @@ var styles7 = {
2475
2861
  headerBtn: _react3.css`
2476
2862
  height: ${btnHeight3};
2477
2863
  padding: 0 12px;
2478
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2479
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2864
+ background: ${_chunkUFCWGUAGjs.colors.surface};
2865
+ border: 1px solid ${_chunkUFCWGUAGjs.colors.border};
2480
2866
  border-radius: 6px;
2481
2867
  cursor: pointer;
2482
2868
  transition: all 0.15s ease;
@@ -2485,14 +2871,14 @@ var styles7 = {
2485
2871
  justify-content: center;
2486
2872
 
2487
2873
  &:hover {
2488
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2489
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2874
+ background-color: ${_chunkUFCWGUAGjs.colors.surfaceHover};
2875
+ border-color: ${_chunkUFCWGUAGjs.colors.borderHover};
2490
2876
  }
2491
2877
  `,
2492
2878
  headerIcon: _react3.css`
2493
2879
  width: 16px;
2494
2880
  height: 16px;
2495
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2881
+ color: ${_chunkUFCWGUAGjs.colors.textSecondary};
2496
2882
  `,
2497
2883
  content: _react3.css`
2498
2884
  flex: 1;
@@ -2504,6 +2890,34 @@ var styles7 = {
2504
2890
  min-width: 0;
2505
2891
  overflow: auto;
2506
2892
  padding: 20px 24px;
2893
+ `,
2894
+ dropOverlay: _react3.css`
2895
+ position: absolute;
2896
+ top: 0;
2897
+ left: 0;
2898
+ right: 0;
2899
+ bottom: 0;
2900
+ background: rgba(99, 91, 255, 0.1);
2901
+ border: 3px dashed ${_chunkUFCWGUAGjs.colors.primary};
2902
+ border-radius: 8px;
2903
+ display: flex;
2904
+ align-items: center;
2905
+ justify-content: center;
2906
+ z-index: 50;
2907
+ pointer-events: none;
2908
+ `,
2909
+ dropMessage: _react3.css`
2910
+ display: flex;
2911
+ flex-direction: column;
2912
+ align-items: center;
2913
+ gap: 12px;
2914
+ color: ${_chunkUFCWGUAGjs.colors.primary};
2915
+ font-size: ${_chunkUFCWGUAGjs.fontSize.lg};
2916
+ font-weight: 600;
2917
+ `,
2918
+ dropIcon: _react3.css`
2919
+ width: 48px;
2920
+ height: 48px;
2507
2921
  `
2508
2922
  };
2509
2923
  function StudioUI({ onClose, isVisible = true }) {
@@ -2515,9 +2929,45 @@ function StudioUI({ onClose, isVisible = true }) {
2515
2929
  const [meta, setMeta] = _react.useState.call(void 0, null);
2516
2930
  const [isLoading, setIsLoading] = _react.useState.call(void 0, false);
2517
2931
  const [refreshKey, setRefreshKey] = _react.useState.call(void 0, 0);
2932
+ const [searchQuery, setSearchQuery] = _react.useState.call(void 0, "");
2933
+ const [isDragging, setIsDragging] = _react.useState.call(void 0, false);
2518
2934
  const triggerRefresh = _react.useCallback.call(void 0, () => {
2519
2935
  setRefreshKey((k) => k + 1);
2520
2936
  }, []);
2937
+ const handleDragOver = _react.useCallback.call(void 0, (e) => {
2938
+ e.preventDefault();
2939
+ e.stopPropagation();
2940
+ setIsDragging(true);
2941
+ }, []);
2942
+ const handleDragLeave = _react.useCallback.call(void 0, (e) => {
2943
+ e.preventDefault();
2944
+ e.stopPropagation();
2945
+ setIsDragging(false);
2946
+ }, []);
2947
+ const handleDrop = _react.useCallback.call(void 0, async (e) => {
2948
+ e.preventDefault();
2949
+ e.stopPropagation();
2950
+ setIsDragging(false);
2951
+ const files = Array.from(e.dataTransfer.files);
2952
+ if (files.length === 0) return;
2953
+ if (currentPath === "public/images" || currentPath.startsWith("public/images/")) {
2954
+ return;
2955
+ }
2956
+ for (const file of files) {
2957
+ const formData = new FormData();
2958
+ formData.append("file", file);
2959
+ formData.append("path", currentPath);
2960
+ try {
2961
+ await fetch("/api/studio/upload", {
2962
+ method: "POST",
2963
+ body: formData
2964
+ });
2965
+ } catch (error) {
2966
+ console.error("Upload error:", error);
2967
+ }
2968
+ }
2969
+ triggerRefresh();
2970
+ }, [currentPath, triggerRefresh]);
2521
2971
  const navigateUp = _react.useCallback.call(void 0, () => {
2522
2972
  if (currentPath === "public") return;
2523
2973
  const parts = currentPath.split("/");
@@ -2609,7 +3059,9 @@ function StudioUI({ onClose, isVisible = true }) {
2609
3059
  isLoading,
2610
3060
  setIsLoading,
2611
3061
  refreshKey,
2612
- triggerRefresh
3062
+ triggerRefresh,
3063
+ searchQuery,
3064
+ setSearchQuery
2613
3065
  };
2614
3066
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioContext.Provider, { value: contextValue, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles7.container, children: [
2615
3067
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles7.header, children: [
@@ -2628,7 +3080,22 @@ function StudioUI({ onClose, isVisible = true }) {
2628
3080
  ] })
2629
3081
  ] }),
2630
3082
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioToolbar, {}),
2631
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles7.content, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles7.fileBrowser, children: viewMode === "grid" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioFileGrid, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioFileList, {}) }) }),
3083
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
3084
+ "div",
3085
+ {
3086
+ css: styles7.content,
3087
+ onDragOver: handleDragOver,
3088
+ onDragLeave: handleDragLeave,
3089
+ onDrop: handleDrop,
3090
+ children: [
3091
+ isDragging && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles7.dropOverlay, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles7.dropMessage, children: [
3092
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", { css: styles7.dropIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M4 16v1a3 3 0 003 3h10a3 3 0 003-3v-1m-4-8l-4-4m0 0L8 8m4-4v12" }) }),
3093
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Drop files to upload" })
3094
+ ] }) }),
3095
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles7.fileBrowser, children: viewMode === "grid" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioFileGrid, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioFileList, {}) })
3096
+ ]
3097
+ }
3098
+ ),
2632
3099
  focusedItem && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioDetailView, {})
2633
3100
  ] }) });
2634
3101
  }
@@ -2656,4 +3123,4 @@ var StudioUI_default = StudioUI;
2656
3123
 
2657
3124
 
2658
3125
  exports.StudioUI = StudioUI; exports.default = StudioUI_default;
2659
- //# sourceMappingURL=StudioUI-X7VS2R5F.js.map
3126
+ //# sourceMappingURL=StudioUI-JYVMD7QS.js.map