@gallop.software/studio 0.1.38 → 0.1.39

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 _chunkZLL7JHVCjs = require('./chunk-ZLL7JHVC.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: ${_chunkZLL7JHVCjs.fontStack};
92
95
  `,
93
96
  modal: _react3.css`
94
- ${_chunkAY2DAS6Wjs.baseReset}
95
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
97
+ ${_chunkZLL7JHVCjs.baseReset}
98
+ background-color: ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.fontSize.lg};
108
111
  font-weight: 600;
109
- color: ${_chunkAY2DAS6Wjs.colors.text};
112
+ color: ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.fontSize.base};
121
+ color: ${_chunkZLL7JHVCjs.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 ${_chunkZLL7JHVCjs.colors.border};
131
+ background-color: ${_chunkZLL7JHVCjs.colors.background};
129
132
  `,
130
133
  btn: _react3.css`
131
134
  padding: 10px 18px;
132
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
135
+ font-size: ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.colors.surface};
144
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
145
+ color: ${_chunkZLL7JHVCjs.colors.text};
143
146
 
144
147
  &:hover {
145
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
146
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
148
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
149
+ border-color: ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.colors.primary};
154
+ border: 1px solid ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.colors.primaryHover};
159
+ border-color: ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.colors.danger};
164
+ border: 1px solid ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.colors.dangerHover};
169
+ border-color: ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.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, ${_chunkZLL7JHVCjs.colors.primary}, ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.fontSize.sm};
230
+ color: ${_chunkZLL7JHVCjs.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: ${_chunkZLL7JHVCjs.fontSize.xs};
238
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
236
239
  margin: 8px 0 0;
237
240
  white-space: nowrap;
238
241
  overflow: hidden;
@@ -323,8 +326,8 @@ var styles2 = {
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: ${_chunkZLL7JHVCjs.colors.surface};
330
+ border-bottom: 1px solid ${_chunkZLL7JHVCjs.colors.border};
328
331
 
329
332
  @media (min-width: 768px) {
330
333
  padding: 12px 24px;
@@ -350,18 +353,18 @@ var styles2 = {
350
353
  height: ${btnHeight};
351
354
  padding: 0 14px;
352
355
  border-radius: 6px;
353
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
356
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
354
357
  font-weight: 500;
355
- background: ${_chunkAY2DAS6Wjs.colors.surface};
356
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
358
+ background: ${_chunkZLL7JHVCjs.colors.surface};
359
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
357
360
  cursor: pointer;
358
361
  transition: all 0.15s ease;
359
- color: ${_chunkAY2DAS6Wjs.colors.text};
362
+ color: ${_chunkZLL7JHVCjs.colors.text};
360
363
  letter-spacing: -0.01em;
361
364
 
362
365
  &:hover:not(:disabled) {
363
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
364
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
366
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
367
+ border-color: ${_chunkZLL7JHVCjs.colors.borderHover};
365
368
  }
366
369
 
367
370
  &:disabled {
@@ -373,21 +376,21 @@ var styles2 = {
373
376
  padding: 0 10px;
374
377
  `,
375
378
  btnPrimary: _react3.css`
376
- background: ${_chunkAY2DAS6Wjs.colors.primary};
377
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
379
+ background: ${_chunkZLL7JHVCjs.colors.primary};
380
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
378
381
  color: white;
379
382
 
380
383
  &:hover:not(:disabled) {
381
- background: ${_chunkAY2DAS6Wjs.colors.primaryHover};
382
- border-color: ${_chunkAY2DAS6Wjs.colors.primaryHover};
384
+ background: ${_chunkZLL7JHVCjs.colors.primaryHover};
385
+ border-color: ${_chunkZLL7JHVCjs.colors.primaryHover};
383
386
  }
384
387
  `,
385
388
  btnDanger: _react3.css`
386
- color: ${_chunkAY2DAS6Wjs.colors.danger};
389
+ color: ${_chunkZLL7JHVCjs.colors.danger};
387
390
 
388
391
  &:hover:not(:disabled) {
389
- background-color: ${_chunkAY2DAS6Wjs.colors.dangerLight};
390
- border-color: ${_chunkAY2DAS6Wjs.colors.danger};
392
+ background-color: ${_chunkZLL7JHVCjs.colors.dangerLight};
393
+ border-color: ${_chunkZLL7JHVCjs.colors.danger};
391
394
  }
392
395
  `,
393
396
  icon: _react3.css`
@@ -398,19 +401,19 @@ var styles2 = {
398
401
  animation: ${spin} 1s linear infinite;
399
402
  `,
400
403
  selectionCount: _react3.css`
401
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
402
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
404
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
405
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
403
406
  display: flex;
404
407
  align-items: center;
405
408
  gap: 8px;
406
409
  margin-right: 8px;
407
410
  `,
408
411
  clearBtn: _react3.css`
409
- color: ${_chunkAY2DAS6Wjs.colors.primary};
412
+ color: ${_chunkZLL7JHVCjs.colors.primary};
410
413
  background: none;
411
414
  border: none;
412
415
  cursor: pointer;
413
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
416
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
414
417
  font-weight: 500;
415
418
  padding: 0;
416
419
 
@@ -421,38 +424,59 @@ var styles2 = {
421
424
  divider: _react3.css`
422
425
  width: 1px;
423
426
  height: 24px;
424
- background: ${_chunkAY2DAS6Wjs.colors.border};
427
+ background: ${_chunkZLL7JHVCjs.colors.border};
425
428
  margin: 0 4px;
426
429
  `,
427
430
  viewToggle: _react3.css`
428
431
  display: flex;
429
432
  align-items: center;
430
433
  height: ${btnHeight};
431
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
432
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
434
+ background-color: ${_chunkZLL7JHVCjs.colors.surface};
435
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
433
436
  border-radius: 6px;
434
437
  overflow: hidden;
435
438
  `,
439
+ searchInput: _react3.css`
440
+ height: ${btnHeight};
441
+ padding: 0 12px;
442
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
443
+ border-radius: 6px;
444
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
445
+ background: ${_chunkZLL7JHVCjs.colors.surface};
446
+ color: ${_chunkZLL7JHVCjs.colors.text};
447
+ width: 180px;
448
+ transition: all 0.15s ease;
449
+
450
+ &:focus {
451
+ outline: none;
452
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
453
+ box-shadow: 0 0 0 2px ${_chunkZLL7JHVCjs.colors.primaryLight};
454
+ }
455
+
456
+ &::placeholder {
457
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
458
+ }
459
+ `,
436
460
  viewBtn: _react3.css`
437
461
  height: 100%;
438
462
  padding: 0 10px;
439
463
  background: transparent;
440
464
  border: none;
441
465
  cursor: pointer;
442
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
466
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
443
467
  transition: all 0.15s ease;
444
468
  display: flex;
445
469
  align-items: center;
446
470
  justify-content: center;
447
471
 
448
472
  &:hover {
449
- color: ${_chunkAY2DAS6Wjs.colors.text};
450
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
473
+ color: ${_chunkZLL7JHVCjs.colors.text};
474
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
451
475
  }
452
476
  `,
453
477
  viewBtnActive: _react3.css`
454
- background-color: ${_chunkAY2DAS6Wjs.colors.background};
455
- color: ${_chunkAY2DAS6Wjs.colors.text};
478
+ background-color: ${_chunkZLL7JHVCjs.colors.background};
479
+ color: ${_chunkZLL7JHVCjs.colors.text};
456
480
  `
457
481
  };
458
482
  function StudioToolbar() {
@@ -774,9 +798,10 @@ function StudioToolbar() {
774
798
  const handleSyncCdn = _react.useCallback.call(void 0, () => {
775
799
  console.log("Sync CDN clicked", selectedItems);
776
800
  }, [selectedItems]);
777
- const handleScan = _react.useCallback.call(void 0, () => {
778
- console.log("Scan clicked");
779
- }, []);
801
+ const { searchQuery, setSearchQuery } = useStudio();
802
+ const handleSearch = _react.useCallback.call(void 0, (e) => {
803
+ setSearchQuery(e.target.value);
804
+ }, [setSearchQuery]);
780
805
  const hasSelection = selectedItems.size > 0;
781
806
  if (focusedItem) {
782
807
  return null;
@@ -891,10 +916,16 @@ function StudioToolbar() {
891
916
  ]
892
917
  }
893
918
  ),
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
- ] })
919
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
920
+ "input",
921
+ {
922
+ css: styles2.searchInput,
923
+ type: "text",
924
+ placeholder: "Search images...",
925
+ value: searchQuery,
926
+ onChange: handleSearch
927
+ }
928
+ )
898
929
  ] }),
899
930
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles2.right, children: [
900
931
  hasSelection && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { css: styles2.selectionCount, children: [
@@ -946,9 +977,6 @@ function TrashIcon() {
946
977
  function CloudIcon() {
947
978
  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
979
  }
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
980
  function GridIcon() {
953
981
  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
982
  }
@@ -977,8 +1005,8 @@ var styles3 = {
977
1005
  width: 32px;
978
1006
  height: 32px;
979
1007
  border-radius: 50%;
980
- border: 3px solid ${_chunkAY2DAS6Wjs.colors.border};
981
- border-top-color: ${_chunkAY2DAS6Wjs.colors.primary};
1008
+ border: 3px solid ${_chunkZLL7JHVCjs.colors.border};
1009
+ border-top-color: ${_chunkZLL7JHVCjs.colors.primary};
982
1010
  animation: ${spin2} 0.8s linear infinite;
983
1011
  `,
984
1012
  empty: _react3.css`
@@ -987,7 +1015,7 @@ var styles3 = {
987
1015
  align-items: center;
988
1016
  justify-content: center;
989
1017
  height: 256px;
990
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1018
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
991
1019
  `,
992
1020
  emptyIcon: _react3.css`
993
1021
  width: 48px;
@@ -996,12 +1024,12 @@ var styles3 = {
996
1024
  opacity: 0.5;
997
1025
  `,
998
1026
  emptyText: _react3.css`
999
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
1027
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
1000
1028
  margin: 0 0 4px 0;
1001
1029
 
1002
1030
  &:last-child {
1003
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1004
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
1031
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1032
+ font-size: ${_chunkZLL7JHVCjs.fontSize.sm};
1005
1033
  }
1006
1034
  `,
1007
1035
  grid: _react3.css`
@@ -1017,11 +1045,11 @@ var styles3 = {
1017
1045
  item: _react3.css`
1018
1046
  position: relative;
1019
1047
  border-radius: 8px;
1020
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1048
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1021
1049
  overflow: hidden;
1022
1050
  cursor: pointer;
1023
1051
  transition: all 0.15s ease;
1024
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
1052
+ background-color: ${_chunkZLL7JHVCjs.colors.surface};
1025
1053
  user-select: none;
1026
1054
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
1027
1055
 
@@ -1031,18 +1059,18 @@ var styles3 = {
1031
1059
  }
1032
1060
  `,
1033
1061
  itemSelected: _react3.css`
1034
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1035
- box-shadow: 0 0 0 1px ${_chunkAY2DAS6Wjs.colors.primary};
1062
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
1063
+ box-shadow: 0 0 0 1px ${_chunkZLL7JHVCjs.colors.primary};
1036
1064
 
1037
1065
  &:hover {
1038
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1066
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
1039
1067
  }
1040
1068
  `,
1041
1069
  parentItem: _react3.css`
1042
1070
  cursor: pointer;
1043
1071
 
1044
1072
  &:hover {
1045
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1073
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
1046
1074
  }
1047
1075
  `,
1048
1076
  checkboxWrapper: _react3.css`
@@ -1056,7 +1084,7 @@ var styles3 = {
1056
1084
  checkbox: _react3.css`
1057
1085
  width: 16px;
1058
1086
  height: 16px;
1059
- accent-color: ${_chunkAY2DAS6Wjs.colors.primary};
1087
+ accent-color: ${_chunkZLL7JHVCjs.colors.primary};
1060
1088
  cursor: pointer;
1061
1089
  `,
1062
1090
  cdnBadge: _react3.css`
@@ -1064,8 +1092,8 @@ var styles3 = {
1064
1092
  top: 8px;
1065
1093
  right: 8px;
1066
1094
  z-index: 10;
1067
- background-color: ${_chunkAY2DAS6Wjs.colors.successLight};
1068
- color: ${_chunkAY2DAS6Wjs.colors.success};
1095
+ background-color: ${_chunkZLL7JHVCjs.colors.successLight};
1096
+ color: ${_chunkZLL7JHVCjs.colors.success};
1069
1097
  font-size: 11px;
1070
1098
  font-weight: 500;
1071
1099
  padding: 2px 8px;
@@ -1077,22 +1105,41 @@ var styles3 = {
1077
1105
  align-items: center;
1078
1106
  justify-content: center;
1079
1107
  padding: 16px;
1080
- background: ${_chunkAY2DAS6Wjs.colors.background};
1108
+ background: ${_chunkZLL7JHVCjs.colors.background};
1081
1109
  `,
1082
1110
  folderIcon: _react3.css`
1083
1111
  width: 56px;
1084
1112
  height: 56px;
1085
1113
  color: #f5a623;
1086
1114
  `,
1115
+ imagesFolderIcon: _react3.css`
1116
+ width: 56px;
1117
+ height: 56px;
1118
+ color: ${_chunkZLL7JHVCjs.colors.imagesFolder};
1119
+ `,
1120
+ imagesFolderWrapper: _react3.css`
1121
+ position: relative;
1122
+ `,
1123
+ lockIcon: _react3.css`
1124
+ position: absolute;
1125
+ bottom: 4px;
1126
+ right: 4px;
1127
+ width: 16px;
1128
+ height: 16px;
1129
+ color: ${_chunkZLL7JHVCjs.colors.imagesFolder};
1130
+ background: white;
1131
+ border-radius: 50%;
1132
+ padding: 2px;
1133
+ `,
1087
1134
  parentIcon: _react3.css`
1088
1135
  width: 56px;
1089
1136
  height: 56px;
1090
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1137
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1091
1138
  `,
1092
1139
  fileIcon: _react3.css`
1093
1140
  width: 40px;
1094
1141
  height: 40px;
1095
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1142
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1096
1143
  `,
1097
1144
  image: _react3.css`
1098
1145
  max-width: 100%;
@@ -1107,8 +1154,8 @@ var styles3 = {
1107
1154
  justify-content: center;
1108
1155
  gap: 8px;
1109
1156
  padding: 16px;
1110
- background: ${_chunkAY2DAS6Wjs.colors.background};
1111
- border: 2px dashed ${_chunkAY2DAS6Wjs.colors.border};
1157
+ background: ${_chunkZLL7JHVCjs.colors.background};
1158
+ border: 2px dashed ${_chunkZLL7JHVCjs.colors.border};
1112
1159
  border-radius: 8px;
1113
1160
  cursor: pointer;
1114
1161
  transition: all 0.15s ease;
@@ -1116,24 +1163,24 @@ var styles3 = {
1116
1163
  height: 60%;
1117
1164
 
1118
1165
  &:hover {
1119
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1120
- background: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1166
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
1167
+ background: ${_chunkZLL7JHVCjs.colors.surfaceHover};
1121
1168
  }
1122
1169
  `,
1123
1170
  noThumbnailIcon: _react3.css`
1124
1171
  width: 32px;
1125
1172
  height: 32px;
1126
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1173
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1127
1174
  `,
1128
1175
  noThumbnailText: _react3.css`
1129
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1130
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1176
+ font-size: ${_chunkZLL7JHVCjs.fontSize.xs};
1177
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1131
1178
  text-align: center;
1132
1179
  `,
1133
1180
  label: _react3.css`
1134
1181
  padding: 10px 12px;
1135
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
1136
- border-top: 1px solid ${_chunkAY2DAS6Wjs.colors.borderLight};
1182
+ background-color: ${_chunkZLL7JHVCjs.colors.surface};
1183
+ border-top: 1px solid ${_chunkZLL7JHVCjs.colors.borderLight};
1137
1184
  `,
1138
1185
  labelRow: _react3.css`
1139
1186
  display: flex;
@@ -1146,9 +1193,9 @@ var styles3 = {
1146
1193
  min-width: 0;
1147
1194
  `,
1148
1195
  name: _react3.css`
1149
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
1196
+ font-size: ${_chunkZLL7JHVCjs.fontSize.sm};
1150
1197
  font-weight: 500;
1151
- color: ${_chunkAY2DAS6Wjs.colors.text};
1198
+ color: ${_chunkZLL7JHVCjs.colors.text};
1152
1199
  white-space: nowrap;
1153
1200
  overflow: hidden;
1154
1201
  text-overflow: ellipsis;
@@ -1156,18 +1203,18 @@ var styles3 = {
1156
1203
  letter-spacing: -0.01em;
1157
1204
  `,
1158
1205
  size: _react3.css`
1159
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1160
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1206
+ font-size: ${_chunkZLL7JHVCjs.fontSize.xs};
1207
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1161
1208
  margin: 2px 0 0 0;
1162
1209
  `,
1163
1210
  openBtn: _react3.css`
1164
1211
  flex-shrink: 0;
1165
1212
  height: 28px;
1166
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1213
+ font-size: ${_chunkZLL7JHVCjs.fontSize.xs};
1167
1214
  font-weight: 500;
1168
- color: ${_chunkAY2DAS6Wjs.colors.primary};
1169
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1170
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1215
+ color: ${_chunkZLL7JHVCjs.colors.primary};
1216
+ background: ${_chunkZLL7JHVCjs.colors.surface};
1217
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1171
1218
  padding: 0 10px;
1172
1219
  cursor: pointer;
1173
1220
  border-radius: 4px;
@@ -1176,8 +1223,8 @@ var styles3 = {
1176
1223
  align-items: center;
1177
1224
 
1178
1225
  &:hover {
1179
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryLight};
1180
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1226
+ background-color: ${_chunkZLL7JHVCjs.colors.primaryLight};
1227
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
1181
1228
  }
1182
1229
  `,
1183
1230
  selectAllRow: _react3.css`
@@ -1185,31 +1232,31 @@ var styles3 = {
1185
1232
  align-items: center;
1186
1233
  margin-bottom: 16px;
1187
1234
  padding: 12px 16px;
1188
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1235
+ background: ${_chunkZLL7JHVCjs.colors.surface};
1189
1236
  border-radius: 8px;
1190
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1237
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1191
1238
  `,
1192
1239
  selectAllLabel: _react3.css`
1193
1240
  display: flex;
1194
1241
  align-items: center;
1195
1242
  gap: 10px;
1196
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
1243
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
1197
1244
  font-weight: 500;
1198
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1245
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
1199
1246
  cursor: pointer;
1200
1247
 
1201
1248
  &:hover {
1202
- color: ${_chunkAY2DAS6Wjs.colors.text};
1249
+ color: ${_chunkZLL7JHVCjs.colors.text};
1203
1250
  }
1204
1251
  `,
1205
1252
  selectAllCheckbox: _react3.css`
1206
1253
  width: 16px;
1207
1254
  height: 16px;
1208
- accent-color: ${_chunkAY2DAS6Wjs.colors.primary};
1255
+ accent-color: ${_chunkZLL7JHVCjs.colors.primary};
1209
1256
  `
1210
1257
  };
1211
1258
  function StudioFileGrid() {
1212
- const { currentPath, setCurrentPath, navigateUp, selectedItems, toggleSelection, selectRange, lastSelectedPath, selectAll, clearSelection, refreshKey, setFocusedItem, triggerRefresh } = useStudio();
1259
+ const { currentPath, setCurrentPath, navigateUp, selectedItems, toggleSelection, selectRange, lastSelectedPath, selectAll, clearSelection, refreshKey, setFocusedItem, triggerRefresh, searchQuery } = useStudio();
1213
1260
  const [items, setItems] = _react.useState.call(void 0, []);
1214
1261
  const [loading, setLoading] = _react.useState.call(void 0, true);
1215
1262
  const isInitialLoad = _react.useRef.call(void 0, true);
@@ -1246,7 +1293,12 @@ function StudioFileGrid() {
1246
1293
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles3.emptyText, children: "Upload images to get started" })
1247
1294
  ] });
1248
1295
  }
1249
- const sortedItems = [...items].sort((a, b) => {
1296
+ const filteredItems = searchQuery ? items.filter((item) => {
1297
+ if (item.type === "folder") return true;
1298
+ const query = searchQuery.toLowerCase();
1299
+ return item.name.toLowerCase().includes(query);
1300
+ }) : items;
1301
+ const sortedItems = [...filteredItems].sort((a, b) => {
1250
1302
  if (a.type === "folder" && b.type !== "folder") return -1;
1251
1303
  if (a.type !== "folder" && b.type === "folder") return 1;
1252
1304
  return a.name.localeCompare(b.name);
@@ -1337,6 +1389,7 @@ function StudioFileGrid() {
1337
1389
  function GridItem({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1338
1390
  const isFolder = item.type === "folder";
1339
1391
  const isImage = !isFolder && item.thumbnail !== void 0;
1392
+ const isImagesFolder = isFolder && (item.name === "images" || item.path.includes("/images/"));
1340
1393
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1341
1394
  "div",
1342
1395
  {
@@ -1360,7 +1413,10 @@ function GridItem({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1360
1413
  }
1361
1414
  ),
1362
1415
  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,
1416
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles3.content, children: isFolder ? isImagesFolder ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles3.imagesFolderWrapper, children: [
1417
+ /* @__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" }) }),
1418
+ /* @__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" }) })
1419
+ ] }) : /* @__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
1420
  "img",
1365
1421
  {
1366
1422
  css: styles3.image,
@@ -1445,8 +1501,8 @@ var styles4 = {
1445
1501
  width: 32px;
1446
1502
  height: 32px;
1447
1503
  border-radius: 50%;
1448
- border: 3px solid ${_chunkAY2DAS6Wjs.colors.border};
1449
- border-top-color: ${_chunkAY2DAS6Wjs.colors.primary};
1504
+ border: 3px solid ${_chunkZLL7JHVCjs.colors.border};
1505
+ border-top-color: ${_chunkZLL7JHVCjs.colors.primary};
1450
1506
  animation: ${spin3} 0.8s linear infinite;
1451
1507
  `,
1452
1508
  empty: _react3.css`
@@ -1455,12 +1511,12 @@ var styles4 = {
1455
1511
  align-items: center;
1456
1512
  justify-content: center;
1457
1513
  height: 256px;
1458
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1514
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
1459
1515
  `,
1460
1516
  tableWrapper: _react3.css`
1461
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1517
+ background: ${_chunkZLL7JHVCjs.colors.surface};
1462
1518
  border-radius: 8px;
1463
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1519
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1464
1520
  overflow: hidden;
1465
1521
  `,
1466
1522
  table: _react3.css`
@@ -1470,13 +1526,13 @@ var styles4 = {
1470
1526
  th: _react3.css`
1471
1527
  text-align: left;
1472
1528
  font-size: 11px;
1473
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1529
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1474
1530
  text-transform: uppercase;
1475
1531
  letter-spacing: 0.05em;
1476
1532
  padding: 12px 16px;
1477
1533
  font-weight: 600;
1478
- background: ${_chunkAY2DAS6Wjs.colors.background};
1479
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1534
+ background: ${_chunkZLL7JHVCjs.colors.background};
1535
+ border-bottom: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1480
1536
  `,
1481
1537
  thCheckbox: _react3.css`
1482
1538
  width: 48px;
@@ -1497,25 +1553,26 @@ var styles4 = {
1497
1553
  user-select: none;
1498
1554
 
1499
1555
  &:hover {
1500
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1556
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
1501
1557
  }
1502
1558
 
1503
1559
  &:not(:last-child) td {
1504
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.borderLight};
1560
+ border-bottom: 1px solid ${_chunkZLL7JHVCjs.colors.borderLight};
1505
1561
  }
1506
1562
  `,
1507
1563
  rowSelected: _react3.css`
1508
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryLight};
1564
+ background-color: ${_chunkZLL7JHVCjs.colors.primaryLight};
1509
1565
 
1510
1566
  &:hover {
1511
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryLight};
1567
+ background-color: ${_chunkZLL7JHVCjs.colors.primaryLight};
1512
1568
  }
1513
1569
  `,
1514
1570
  parentRow: _react3.css`
1515
1571
  cursor: pointer;
1572
+ border-bottom: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1516
1573
 
1517
1574
  &:hover {
1518
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1575
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
1519
1576
  }
1520
1577
  `,
1521
1578
  td: _react3.css`
@@ -1528,7 +1585,7 @@ var styles4 = {
1528
1585
  checkbox: _react3.css`
1529
1586
  width: 16px;
1530
1587
  height: 16px;
1531
- accent-color: ${_chunkAY2DAS6Wjs.colors.primary};
1588
+ accent-color: ${_chunkZLL7JHVCjs.colors.primary};
1532
1589
  cursor: pointer;
1533
1590
  `,
1534
1591
  nameCell: _react3.css`
@@ -1542,16 +1599,34 @@ var styles4 = {
1542
1599
  color: #f5a623;
1543
1600
  flex-shrink: 0;
1544
1601
  `,
1602
+ imagesFolderWrapper: _react3.css`
1603
+ position: relative;
1604
+ display: flex;
1605
+ align-items: center;
1606
+ `,
1607
+ imagesFolderIcon: _react3.css`
1608
+ width: 20px;
1609
+ height: 20px;
1610
+ color: ${_chunkZLL7JHVCjs.colors.imagesFolder};
1611
+ flex-shrink: 0;
1612
+ `,
1613
+ lockIcon: _react3.css`
1614
+ width: 10px;
1615
+ height: 10px;
1616
+ color: ${_chunkZLL7JHVCjs.colors.imagesFolder};
1617
+ margin-left: -6px;
1618
+ margin-top: 8px;
1619
+ `,
1545
1620
  parentIcon: _react3.css`
1546
1621
  width: 20px;
1547
1622
  height: 20px;
1548
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1623
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1549
1624
  flex-shrink: 0;
1550
1625
  `,
1551
1626
  fileIcon: _react3.css`
1552
1627
  width: 20px;
1553
1628
  height: 20px;
1554
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1629
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1555
1630
  flex-shrink: 0;
1556
1631
  `,
1557
1632
  thumbnail: _react3.css`
@@ -1562,7 +1637,7 @@ var styles4 = {
1562
1637
  object-fit: contain;
1563
1638
  border-radius: 4px;
1564
1639
  flex-shrink: 0;
1565
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.borderLight};
1640
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.borderLight};
1566
1641
  `,
1567
1642
  noThumbnail: _react3.css`
1568
1643
  width: 36px;
@@ -1570,56 +1645,56 @@ var styles4 = {
1570
1645
  display: flex;
1571
1646
  align-items: center;
1572
1647
  justify-content: center;
1573
- background: ${_chunkAY2DAS6Wjs.colors.background};
1574
- border: 1px dashed ${_chunkAY2DAS6Wjs.colors.border};
1648
+ background: ${_chunkZLL7JHVCjs.colors.background};
1649
+ border: 1px dashed ${_chunkZLL7JHVCjs.colors.border};
1575
1650
  border-radius: 4px;
1576
1651
  flex-shrink: 0;
1577
1652
  cursor: pointer;
1578
1653
  transition: all 0.15s ease;
1579
1654
 
1580
1655
  &:hover {
1581
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1582
- background: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1656
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
1657
+ background: ${_chunkZLL7JHVCjs.colors.surfaceHover};
1583
1658
  }
1584
1659
  `,
1585
1660
  noThumbnailIcon: _react3.css`
1586
1661
  width: 16px;
1587
1662
  height: 16px;
1588
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1663
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1589
1664
  `,
1590
1665
  name: _react3.css`
1591
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
1666
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
1592
1667
  font-weight: 500;
1593
- color: ${_chunkAY2DAS6Wjs.colors.text};
1668
+ color: ${_chunkZLL7JHVCjs.colors.text};
1594
1669
  letter-spacing: -0.01em;
1595
1670
  `,
1596
1671
  meta: _react3.css`
1597
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
1598
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1672
+ font-size: ${_chunkZLL7JHVCjs.fontSize.sm};
1673
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
1599
1674
  `,
1600
1675
  cdnBadge: _react3.css`
1601
1676
  display: inline-flex;
1602
1677
  align-items: center;
1603
1678
  gap: 4px;
1604
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1679
+ font-size: ${_chunkZLL7JHVCjs.fontSize.xs};
1605
1680
  font-weight: 500;
1606
- color: ${_chunkAY2DAS6Wjs.colors.success};
1681
+ color: ${_chunkZLL7JHVCjs.colors.success};
1607
1682
  `,
1608
1683
  cdnIcon: _react3.css`
1609
1684
  width: 12px;
1610
1685
  height: 12px;
1611
1686
  `,
1612
1687
  cdnEmpty: _react3.css`
1613
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
1614
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
1688
+ font-size: ${_chunkZLL7JHVCjs.fontSize.sm};
1689
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1615
1690
  `,
1616
1691
  openBtn: _react3.css`
1617
1692
  height: 28px;
1618
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
1693
+ font-size: ${_chunkZLL7JHVCjs.fontSize.xs};
1619
1694
  font-weight: 500;
1620
- color: ${_chunkAY2DAS6Wjs.colors.primary};
1621
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1622
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1695
+ color: ${_chunkZLL7JHVCjs.colors.primary};
1696
+ background: ${_chunkZLL7JHVCjs.colors.surface};
1697
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1623
1698
  padding: 0 12px;
1624
1699
  cursor: pointer;
1625
1700
  border-radius: 4px;
@@ -1629,13 +1704,13 @@ var styles4 = {
1629
1704
  margin-left: auto;
1630
1705
 
1631
1706
  &:hover {
1632
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryLight};
1633
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
1707
+ background-color: ${_chunkZLL7JHVCjs.colors.primaryLight};
1708
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
1634
1709
  }
1635
1710
  `
1636
1711
  };
1637
1712
  function StudioFileList() {
1638
- const { currentPath, setCurrentPath, navigateUp, selectedItems, toggleSelection, selectRange, lastSelectedPath, selectAll, clearSelection, refreshKey, setFocusedItem, triggerRefresh } = useStudio();
1713
+ const { currentPath, setCurrentPath, navigateUp, selectedItems, toggleSelection, selectRange, lastSelectedPath, selectAll, clearSelection, refreshKey, setFocusedItem, triggerRefresh, searchQuery } = useStudio();
1639
1714
  const [items, setItems] = _react.useState.call(void 0, []);
1640
1715
  const [loading, setLoading] = _react.useState.call(void 0, true);
1641
1716
  const isInitialLoad = _react.useRef.call(void 0, true);
@@ -1668,7 +1743,12 @@ function StudioFileList() {
1668
1743
  if (items.length === 0 && isAtRoot) {
1669
1744
  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
1745
  }
1671
- const sortedItems = [...items].sort((a, b) => {
1746
+ const filteredItems = searchQuery ? items.filter((item) => {
1747
+ if (item.type === "folder") return true;
1748
+ const query = searchQuery.toLowerCase();
1749
+ return item.name.toLowerCase().includes(query);
1750
+ }) : items;
1751
+ const sortedItems = [...filteredItems].sort((a, b) => {
1672
1752
  if (a.type === "folder" && b.type !== "folder") return -1;
1673
1753
  if (a.type !== "folder" && b.type === "folder") return 1;
1674
1754
  return a.name.localeCompare(b.name);
@@ -1756,6 +1836,7 @@ function StudioFileList() {
1756
1836
  function ListRow({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1757
1837
  const isFolder = item.type === "folder";
1758
1838
  const isImage = !isFolder && item.thumbnail !== void 0;
1839
+ const isImagesFolder = isFolder && (item.name === "images" || item.path.includes("/images/"));
1759
1840
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
1760
1841
  "tr",
1761
1842
  {
@@ -1779,7 +1860,10 @@ function ListRow({ item, isSelected, onClick, onOpen, onGenerateThumbnail }) {
1779
1860
  }
1780
1861
  ),
1781
1862
  /* @__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,
1863
+ isFolder ? isImagesFolder ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles4.imagesFolderWrapper, children: [
1864
+ /* @__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" }) }),
1865
+ /* @__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" }) })
1866
+ ] }) : /* @__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
1867
  "button",
1784
1868
  {
1785
1869
  css: styles4.noThumbnail,
@@ -1862,7 +1946,8 @@ var styles5 = {
1862
1946
  display: flex;
1863
1947
  flex: 1;
1864
1948
  margin: 24px;
1865
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1949
+ background: ${_chunkZLL7JHVCjs.colors.surface};
1950
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1866
1951
  border-radius: 12px;
1867
1952
  overflow: hidden;
1868
1953
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
@@ -1875,7 +1960,7 @@ var styles5 = {
1875
1960
  align-items: center;
1876
1961
  justify-content: center;
1877
1962
  padding: 24px;
1878
- background: ${_chunkAY2DAS6Wjs.colors.background};
1963
+ background: ${_chunkZLL7JHVCjs.colors.background};
1879
1964
  overflow: auto;
1880
1965
  `,
1881
1966
  mainCloseBtn: _react3.css`
@@ -1883,8 +1968,8 @@ var styles5 = {
1883
1968
  top: 16px;
1884
1969
  right: 16px;
1885
1970
  padding: 8px;
1886
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1887
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
1971
+ background: ${_chunkZLL7JHVCjs.colors.surface};
1972
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1888
1973
  border-radius: 8px;
1889
1974
  cursor: pointer;
1890
1975
  transition: all 0.15s ease;
@@ -1895,14 +1980,14 @@ var styles5 = {
1895
1980
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
1896
1981
 
1897
1982
  &:hover {
1898
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
1899
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
1983
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
1984
+ border-color: ${_chunkZLL7JHVCjs.colors.borderHover};
1900
1985
  }
1901
1986
  `,
1902
1987
  mainCloseIcon: _react3.css`
1903
1988
  width: 20px;
1904
1989
  height: 20px;
1905
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
1990
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
1906
1991
  `,
1907
1992
  mediaWrapper: _react3.css`
1908
1993
  max-width: 100%;
@@ -1930,38 +2015,38 @@ var styles5 = {
1930
2015
  align-items: center;
1931
2016
  justify-content: center;
1932
2017
  padding: 48px;
1933
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2018
+ background: ${_chunkZLL7JHVCjs.colors.surface};
1934
2019
  border-radius: 12px;
1935
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2020
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1936
2021
  `,
1937
2022
  fileIcon: _react3.css`
1938
2023
  width: 80px;
1939
2024
  height: 80px;
1940
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
2025
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
1941
2026
  margin-bottom: 16px;
1942
2027
  `,
1943
2028
  fileName: _react3.css`
1944
- font-size: ${_chunkAY2DAS6Wjs.fontSize.lg};
2029
+ font-size: ${_chunkZLL7JHVCjs.fontSize.lg};
1945
2030
  font-weight: 600;
1946
- color: ${_chunkAY2DAS6Wjs.colors.text};
2031
+ color: ${_chunkZLL7JHVCjs.colors.text};
1947
2032
  margin: 0;
1948
2033
  `,
1949
2034
  sidebar: _react3.css`
1950
2035
  width: 280px;
1951
- background: ${_chunkAY2DAS6Wjs.colors.surface};
1952
- border-left: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2036
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2037
+ border-left: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1953
2038
  display: flex;
1954
2039
  flex-direction: column;
1955
2040
  overflow: hidden;
1956
2041
  `,
1957
2042
  sidebarHeader: _react3.css`
1958
2043
  padding: 16px 20px;
1959
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2044
+ border-bottom: 1px solid ${_chunkZLL7JHVCjs.colors.border};
1960
2045
  `,
1961
2046
  sidebarTitle: _react3.css`
1962
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2047
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
1963
2048
  font-weight: 600;
1964
- color: ${_chunkAY2DAS6Wjs.colors.text};
2049
+ color: ${_chunkZLL7JHVCjs.colors.text};
1965
2050
  margin: 0;
1966
2051
  `,
1967
2052
  sidebarContent: _react3.css`
@@ -1978,13 +2063,13 @@ var styles5 = {
1978
2063
  infoRow: _react3.css`
1979
2064
  display: flex;
1980
2065
  justify-content: space-between;
1981
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
2066
+ font-size: ${_chunkZLL7JHVCjs.fontSize.sm};
1982
2067
  `,
1983
2068
  infoLabel: _react3.css`
1984
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2069
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
1985
2070
  `,
1986
2071
  infoValue: _react3.css`
1987
- color: ${_chunkAY2DAS6Wjs.colors.text};
2072
+ color: ${_chunkZLL7JHVCjs.colors.text};
1988
2073
  font-weight: 500;
1989
2074
  text-align: right;
1990
2075
  max-width: 160px;
@@ -1993,7 +2078,7 @@ var styles5 = {
1993
2078
  white-space: nowrap;
1994
2079
  `,
1995
2080
  infoValueWrap: _react3.css`
1996
- color: ${_chunkAY2DAS6Wjs.colors.text};
2081
+ color: ${_chunkZLL7JHVCjs.colors.text};
1997
2082
  font-weight: 500;
1998
2083
  text-align: right;
1999
2084
  max-width: 160px;
@@ -2011,27 +2096,27 @@ var styles5 = {
2011
2096
  gap: 10px;
2012
2097
  width: 100%;
2013
2098
  padding: 12px 14px;
2014
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2099
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
2015
2100
  font-weight: 500;
2016
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2017
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2101
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2102
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2018
2103
  border-radius: 6px;
2019
2104
  cursor: pointer;
2020
2105
  transition: all 0.15s ease;
2021
- color: ${_chunkAY2DAS6Wjs.colors.text};
2106
+ color: ${_chunkZLL7JHVCjs.colors.text};
2022
2107
  text-align: left;
2023
2108
 
2024
2109
  &:hover {
2025
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2026
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2110
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
2111
+ border-color: ${_chunkZLL7JHVCjs.colors.borderHover};
2027
2112
  }
2028
2113
  `,
2029
2114
  actionBtnDanger: _react3.css`
2030
- color: ${_chunkAY2DAS6Wjs.colors.danger};
2115
+ color: ${_chunkZLL7JHVCjs.colors.danger};
2031
2116
 
2032
2117
  &:hover {
2033
- background-color: ${_chunkAY2DAS6Wjs.colors.dangerLight};
2034
- border-color: ${_chunkAY2DAS6Wjs.colors.danger};
2118
+ background-color: ${_chunkZLL7JHVCjs.colors.dangerLight};
2119
+ border-color: ${_chunkZLL7JHVCjs.colors.danger};
2035
2120
  }
2036
2121
  `,
2037
2122
  actionIcon: _react3.css`
@@ -2194,8 +2279,8 @@ var styles6 = {
2194
2279
  btn: _react3.css`
2195
2280
  height: ${btnHeight2};
2196
2281
  padding: 0 12px;
2197
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2198
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2282
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2283
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2199
2284
  border-radius: 6px;
2200
2285
  cursor: pointer;
2201
2286
  transition: all 0.15s ease;
@@ -2204,14 +2289,14 @@ var styles6 = {
2204
2289
  justify-content: center;
2205
2290
 
2206
2291
  &:hover {
2207
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2208
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2292
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
2293
+ border-color: ${_chunkZLL7JHVCjs.colors.borderHover};
2209
2294
  }
2210
2295
  `,
2211
2296
  icon: _react3.css`
2212
2297
  width: 16px;
2213
2298
  height: 16px;
2214
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2299
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
2215
2300
  `,
2216
2301
  overlay: _react3.css`
2217
2302
  position: fixed;
@@ -2227,9 +2312,9 @@ var styles6 = {
2227
2312
  backdrop-filter: blur(4px);
2228
2313
  `,
2229
2314
  panel: _react3.css`
2230
- ${_chunkAY2DAS6Wjs.baseReset}
2315
+ ${_chunkZLL7JHVCjs.baseReset}
2231
2316
  position: relative;
2232
- background-color: ${_chunkAY2DAS6Wjs.colors.surface};
2317
+ background-color: ${_chunkZLL7JHVCjs.colors.surface};
2233
2318
  border-radius: 12px;
2234
2319
  box-shadow: 0 30px 60px -12px rgba(50, 50, 93, 0.25), 0 18px 36px -18px rgba(0, 0, 0, 0.3);
2235
2320
  width: 100%;
@@ -2243,16 +2328,16 @@ var styles6 = {
2243
2328
  margin-bottom: 24px;
2244
2329
  `,
2245
2330
  title: _react3.css`
2246
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xl};
2331
+ font-size: ${_chunkZLL7JHVCjs.fontSize.xl};
2247
2332
  font-weight: 600;
2248
- color: ${_chunkAY2DAS6Wjs.colors.text};
2333
+ color: ${_chunkZLL7JHVCjs.colors.text};
2249
2334
  margin: 0;
2250
2335
  letter-spacing: -0.02em;
2251
2336
  `,
2252
2337
  closeBtn: _react3.css`
2253
2338
  padding: 6px;
2254
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2255
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2339
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2340
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2256
2341
  border-radius: 6px;
2257
2342
  cursor: pointer;
2258
2343
  transition: all 0.15s ease;
@@ -2261,8 +2346,8 @@ var styles6 = {
2261
2346
  justify-content: center;
2262
2347
 
2263
2348
  &:hover {
2264
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2265
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2349
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
2350
+ border-color: ${_chunkZLL7JHVCjs.colors.borderHover};
2266
2351
  }
2267
2352
  `,
2268
2353
  sections: _react3.css`
@@ -2271,24 +2356,52 @@ var styles6 = {
2271
2356
  gap: 24px;
2272
2357
  `,
2273
2358
  sectionTitle: _react3.css`
2274
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2359
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
2275
2360
  font-weight: 600;
2276
- color: ${_chunkAY2DAS6Wjs.colors.text};
2361
+ color: ${_chunkZLL7JHVCjs.colors.text};
2277
2362
  margin: 0 0 12px 0;
2278
2363
  `,
2279
2364
  description: _react3.css`
2280
- font-size: ${_chunkAY2DAS6Wjs.fontSize.sm};
2281
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2365
+ font-size: ${_chunkZLL7JHVCjs.fontSize.sm};
2366
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
2282
2367
  margin: 0 0 12px 0;
2283
2368
  `,
2369
+ codeWrapper: _react3.css`
2370
+ position: relative;
2371
+ `,
2284
2372
  code: _react3.css`
2285
- background-color: ${_chunkAY2DAS6Wjs.colors.background};
2373
+ background-color: ${_chunkZLL7JHVCjs.colors.background};
2286
2374
  border-radius: 8px;
2287
2375
  padding: 12px;
2376
+ padding-right: 40px;
2288
2377
  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};
2378
+ font-size: ${_chunkZLL7JHVCjs.fontSize.xs};
2379
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
2380
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2381
+ `,
2382
+ copyBtn: _react3.css`
2383
+ position: absolute;
2384
+ top: 8px;
2385
+ right: 8px;
2386
+ padding: 4px;
2387
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2388
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2389
+ border-radius: 4px;
2390
+ cursor: pointer;
2391
+ transition: all 0.15s ease;
2392
+ display: flex;
2393
+ align-items: center;
2394
+ justify-content: center;
2395
+
2396
+ &:hover {
2397
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
2398
+ border-color: ${_chunkZLL7JHVCjs.colors.borderHover};
2399
+ }
2400
+ `,
2401
+ copyIcon: _react3.css`
2402
+ width: 14px;
2403
+ height: 14px;
2404
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
2292
2405
  `,
2293
2406
  codeLine: _react3.css`
2294
2407
  margin: 0 0 4px 0;
@@ -2300,21 +2413,21 @@ var styles6 = {
2300
2413
  input: _react3.css`
2301
2414
  width: 100%;
2302
2415
  padding: 10px 14px;
2303
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2416
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2304
2417
  border-radius: 6px;
2305
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2306
- color: ${_chunkAY2DAS6Wjs.colors.text};
2307
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2418
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
2419
+ color: ${_chunkZLL7JHVCjs.colors.text};
2420
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2308
2421
  transition: all 0.15s ease;
2309
2422
 
2310
2423
  &:focus {
2311
2424
  outline: none;
2312
- border-color: ${_chunkAY2DAS6Wjs.colors.primary};
2313
- box-shadow: 0 0 0 3px ${_chunkAY2DAS6Wjs.colors.primaryLight};
2425
+ border-color: ${_chunkZLL7JHVCjs.colors.primary};
2426
+ box-shadow: 0 0 0 3px ${_chunkZLL7JHVCjs.colors.primaryLight};
2314
2427
  }
2315
2428
 
2316
2429
  &::placeholder {
2317
- color: ${_chunkAY2DAS6Wjs.colors.textMuted};
2430
+ color: ${_chunkZLL7JHVCjs.colors.textMuted};
2318
2431
  }
2319
2432
  `,
2320
2433
  grid: _react3.css`
@@ -2323,50 +2436,50 @@ var styles6 = {
2323
2436
  gap: 12px;
2324
2437
  `,
2325
2438
  label: _react3.css`
2326
- font-size: ${_chunkAY2DAS6Wjs.fontSize.xs};
2439
+ font-size: ${_chunkZLL7JHVCjs.fontSize.xs};
2327
2440
  font-weight: 500;
2328
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2441
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
2329
2442
  display: block;
2330
2443
  margin-bottom: 6px;
2331
2444
  `,
2332
2445
  footer: _react3.css`
2333
2446
  margin-top: 24px;
2334
2447
  padding-top: 20px;
2335
- border-top: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2448
+ border-top: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2336
2449
  display: flex;
2337
2450
  justify-content: flex-end;
2338
2451
  gap: 12px;
2339
2452
  `,
2340
2453
  cancelBtn: _react3.css`
2341
2454
  padding: 10px 18px;
2342
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2455
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
2343
2456
  font-weight: 500;
2344
- color: ${_chunkAY2DAS6Wjs.colors.text};
2345
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2346
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2457
+ color: ${_chunkZLL7JHVCjs.colors.text};
2458
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2459
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2347
2460
  border-radius: 6px;
2348
2461
  cursor: pointer;
2349
2462
  transition: all 0.15s ease;
2350
2463
 
2351
2464
  &:hover {
2352
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2353
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2465
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
2466
+ border-color: ${_chunkZLL7JHVCjs.colors.borderHover};
2354
2467
  }
2355
2468
  `,
2356
2469
  saveBtn: _react3.css`
2357
2470
  padding: 10px 18px;
2358
- font-size: ${_chunkAY2DAS6Wjs.fontSize.base};
2471
+ font-size: ${_chunkZLL7JHVCjs.fontSize.base};
2359
2472
  font-weight: 500;
2360
2473
  color: white;
2361
- background-color: ${_chunkAY2DAS6Wjs.colors.primary};
2362
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.primary};
2474
+ background-color: ${_chunkZLL7JHVCjs.colors.primary};
2475
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.primary};
2363
2476
  border-radius: 6px;
2364
2477
  cursor: pointer;
2365
2478
  transition: all 0.15s ease;
2366
2479
 
2367
2480
  &:hover {
2368
- background-color: ${_chunkAY2DAS6Wjs.colors.primaryHover};
2369
- border-color: ${_chunkAY2DAS6Wjs.colors.primaryHover};
2481
+ background-color: ${_chunkZLL7JHVCjs.colors.primaryHover};
2482
+ border-color: ${_chunkZLL7JHVCjs.colors.primaryHover};
2370
2483
  }
2371
2484
  `
2372
2485
  };
@@ -2393,7 +2506,18 @@ function StudioSettings() {
2393
2506
  isOpen && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, SettingsPanel, { onClose: () => setIsOpen(false) })
2394
2507
  ] });
2395
2508
  }
2509
+ var envTemplate = `CLOUDFLARE_R2_ACCOUNT_ID=abc123def456ghi789
2510
+ CLOUDFLARE_R2_ACCESS_KEY_ID=your_access_key_id_here
2511
+ CLOUDFLARE_R2_SECRET_ACCESS_KEY=your_secret_access_key_here
2512
+ CLOUDFLARE_R2_BUCKET_NAME=my-images-bucket
2513
+ CLOUDFLARE_R2_PUBLIC_URL=https://cdn.yourdomain.com`;
2396
2514
  function SettingsPanel({ onClose }) {
2515
+ const [copied, setCopied] = _react.useState.call(void 0, false);
2516
+ const handleCopy = () => {
2517
+ navigator.clipboard.writeText(envTemplate);
2518
+ setCopied(true);
2519
+ setTimeout(() => setCopied(false), 2e3);
2520
+ };
2397
2521
  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
2522
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles6.header, children: [
2399
2523
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h2", { css: styles6.title, children: "Settings" }),
@@ -2403,12 +2527,15 @@ function SettingsPanel({ onClose }) {
2403
2527
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "section", { children: [
2404
2528
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { css: styles6.sectionTitle, children: "Cloudflare R2" }),
2405
2529
  /* @__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" })
2530
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles6.codeWrapper, children: [
2531
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "button", { css: styles6.copyBtn, onClick: handleCopy, title: copied ? "Copied!" : "Copy to clipboard", children: 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" }) }) }),
2532
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles6.code, children: [
2533
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_ACCOUNT_ID=abc123def456ghi789" }),
2534
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_ACCESS_KEY_ID=your_access_key_id_here" }),
2535
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_SECRET_ACCESS_KEY=your_secret_access_key_here" }),
2536
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_BUCKET_NAME=my-images-bucket" }),
2537
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { css: styles6.codeLine, children: "CLOUDFLARE_R2_PUBLIC_URL=https://cdn.yourdomain.com" })
2538
+ ] })
2412
2539
  ] })
2413
2540
  ] }),
2414
2541
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "section", { children: [
@@ -2446,24 +2573,24 @@ function SettingsPanel({ onClose }) {
2446
2573
  var btnHeight3 = "36px";
2447
2574
  var styles7 = {
2448
2575
  container: _react3.css`
2449
- ${_chunkAY2DAS6Wjs.baseReset}
2576
+ ${_chunkZLL7JHVCjs.baseReset}
2450
2577
  display: flex;
2451
2578
  flex-direction: column;
2452
2579
  height: 100%;
2453
- background: ${_chunkAY2DAS6Wjs.colors.background};
2580
+ background: ${_chunkZLL7JHVCjs.colors.background};
2454
2581
  `,
2455
2582
  header: _react3.css`
2456
2583
  display: flex;
2457
2584
  align-items: center;
2458
2585
  justify-content: space-between;
2459
2586
  padding: 12px 24px;
2460
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2461
- border-bottom: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2587
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2588
+ border-bottom: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2462
2589
  `,
2463
2590
  title: _react3.css`
2464
- font-size: ${_chunkAY2DAS6Wjs.fontSize.lg};
2591
+ font-size: ${_chunkZLL7JHVCjs.fontSize.lg};
2465
2592
  font-weight: 600;
2466
- color: ${_chunkAY2DAS6Wjs.colors.text};
2593
+ color: ${_chunkZLL7JHVCjs.colors.text};
2467
2594
  margin: 0;
2468
2595
  letter-spacing: -0.02em;
2469
2596
  `,
@@ -2475,8 +2602,8 @@ var styles7 = {
2475
2602
  headerBtn: _react3.css`
2476
2603
  height: ${btnHeight3};
2477
2604
  padding: 0 12px;
2478
- background: ${_chunkAY2DAS6Wjs.colors.surface};
2479
- border: 1px solid ${_chunkAY2DAS6Wjs.colors.border};
2605
+ background: ${_chunkZLL7JHVCjs.colors.surface};
2606
+ border: 1px solid ${_chunkZLL7JHVCjs.colors.border};
2480
2607
  border-radius: 6px;
2481
2608
  cursor: pointer;
2482
2609
  transition: all 0.15s ease;
@@ -2485,14 +2612,14 @@ var styles7 = {
2485
2612
  justify-content: center;
2486
2613
 
2487
2614
  &:hover {
2488
- background-color: ${_chunkAY2DAS6Wjs.colors.surfaceHover};
2489
- border-color: ${_chunkAY2DAS6Wjs.colors.borderHover};
2615
+ background-color: ${_chunkZLL7JHVCjs.colors.surfaceHover};
2616
+ border-color: ${_chunkZLL7JHVCjs.colors.borderHover};
2490
2617
  }
2491
2618
  `,
2492
2619
  headerIcon: _react3.css`
2493
2620
  width: 16px;
2494
2621
  height: 16px;
2495
- color: ${_chunkAY2DAS6Wjs.colors.textSecondary};
2622
+ color: ${_chunkZLL7JHVCjs.colors.textSecondary};
2496
2623
  `,
2497
2624
  content: _react3.css`
2498
2625
  flex: 1;
@@ -2504,6 +2631,34 @@ var styles7 = {
2504
2631
  min-width: 0;
2505
2632
  overflow: auto;
2506
2633
  padding: 20px 24px;
2634
+ `,
2635
+ dropOverlay: _react3.css`
2636
+ position: absolute;
2637
+ top: 0;
2638
+ left: 0;
2639
+ right: 0;
2640
+ bottom: 0;
2641
+ background: rgba(99, 91, 255, 0.1);
2642
+ border: 3px dashed ${_chunkZLL7JHVCjs.colors.primary};
2643
+ border-radius: 8px;
2644
+ display: flex;
2645
+ align-items: center;
2646
+ justify-content: center;
2647
+ z-index: 50;
2648
+ pointer-events: none;
2649
+ `,
2650
+ dropMessage: _react3.css`
2651
+ display: flex;
2652
+ flex-direction: column;
2653
+ align-items: center;
2654
+ gap: 12px;
2655
+ color: ${_chunkZLL7JHVCjs.colors.primary};
2656
+ font-size: ${_chunkZLL7JHVCjs.fontSize.lg};
2657
+ font-weight: 600;
2658
+ `,
2659
+ dropIcon: _react3.css`
2660
+ width: 48px;
2661
+ height: 48px;
2507
2662
  `
2508
2663
  };
2509
2664
  function StudioUI({ onClose, isVisible = true }) {
@@ -2515,9 +2670,45 @@ function StudioUI({ onClose, isVisible = true }) {
2515
2670
  const [meta, setMeta] = _react.useState.call(void 0, null);
2516
2671
  const [isLoading, setIsLoading] = _react.useState.call(void 0, false);
2517
2672
  const [refreshKey, setRefreshKey] = _react.useState.call(void 0, 0);
2673
+ const [searchQuery, setSearchQuery] = _react.useState.call(void 0, "");
2674
+ const [isDragging, setIsDragging] = _react.useState.call(void 0, false);
2518
2675
  const triggerRefresh = _react.useCallback.call(void 0, () => {
2519
2676
  setRefreshKey((k) => k + 1);
2520
2677
  }, []);
2678
+ const handleDragOver = _react.useCallback.call(void 0, (e) => {
2679
+ e.preventDefault();
2680
+ e.stopPropagation();
2681
+ setIsDragging(true);
2682
+ }, []);
2683
+ const handleDragLeave = _react.useCallback.call(void 0, (e) => {
2684
+ e.preventDefault();
2685
+ e.stopPropagation();
2686
+ setIsDragging(false);
2687
+ }, []);
2688
+ const handleDrop = _react.useCallback.call(void 0, async (e) => {
2689
+ e.preventDefault();
2690
+ e.stopPropagation();
2691
+ setIsDragging(false);
2692
+ const files = Array.from(e.dataTransfer.files);
2693
+ if (files.length === 0) return;
2694
+ if (currentPath === "public/images" || currentPath.startsWith("public/images/")) {
2695
+ return;
2696
+ }
2697
+ for (const file of files) {
2698
+ const formData = new FormData();
2699
+ formData.append("file", file);
2700
+ formData.append("path", currentPath);
2701
+ try {
2702
+ await fetch("/api/studio/upload", {
2703
+ method: "POST",
2704
+ body: formData
2705
+ });
2706
+ } catch (error) {
2707
+ console.error("Upload error:", error);
2708
+ }
2709
+ }
2710
+ triggerRefresh();
2711
+ }, [currentPath, triggerRefresh]);
2521
2712
  const navigateUp = _react.useCallback.call(void 0, () => {
2522
2713
  if (currentPath === "public") return;
2523
2714
  const parts = currentPath.split("/");
@@ -2609,7 +2800,9 @@ function StudioUI({ onClose, isVisible = true }) {
2609
2800
  isLoading,
2610
2801
  setIsLoading,
2611
2802
  refreshKey,
2612
- triggerRefresh
2803
+ triggerRefresh,
2804
+ searchQuery,
2805
+ setSearchQuery
2613
2806
  };
2614
2807
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioContext.Provider, { value: contextValue, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles7.container, children: [
2615
2808
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles7.header, children: [
@@ -2628,7 +2821,22 @@ function StudioUI({ onClose, isVisible = true }) {
2628
2821
  ] })
2629
2822
  ] }),
2630
2823
  /* @__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, {}) }) }),
2824
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
2825
+ "div",
2826
+ {
2827
+ css: styles7.content,
2828
+ onDragOver: handleDragOver,
2829
+ onDragLeave: handleDragLeave,
2830
+ onDrop: handleDrop,
2831
+ children: [
2832
+ isDragging && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { css: styles7.dropOverlay, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { css: styles7.dropMessage, children: [
2833
+ /* @__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" }) }),
2834
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: "Drop files to upload" })
2835
+ ] }) }),
2836
+ /* @__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, {}) })
2837
+ ]
2838
+ }
2839
+ ),
2632
2840
  focusedItem && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, StudioDetailView, {})
2633
2841
  ] }) });
2634
2842
  }
@@ -2656,4 +2864,4 @@ var StudioUI_default = StudioUI;
2656
2864
 
2657
2865
 
2658
2866
  exports.StudioUI = StudioUI; exports.default = StudioUI_default;
2659
- //# sourceMappingURL=StudioUI-X7VS2R5F.js.map
2867
+ //# sourceMappingURL=StudioUI-V4IRLVOZ.js.map