sa2kit 1.6.45 → 1.6.47

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.
@@ -330,7 +330,7 @@ var init_useMasterpieces = chunkZ6ZWNWWR_js.__esm({
330
330
 
331
331
  // src/showmasterpiece/services/masterpiecesConfigService.ts
332
332
  async function getCollectionsOverview() {
333
- const response = await fetch("/api/masterpieces/collections?overview=true");
333
+ const response = await fetch("/api/showmasterpiece/collections?overview=true");
334
334
  if (!response.ok) {
335
335
  throw new Error("\u83B7\u53D6\u753B\u96C6\u6982\u89C8\u5931\u8D25");
336
336
  }
@@ -347,7 +347,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
347
347
  if (configCache && now - configCacheTime < CONFIG_CACHE_DURATION) {
348
348
  return configCache;
349
349
  }
350
- const response = await fetch("/api/masterpieces/config");
350
+ const response = await fetch("/api/showmasterpiece/config");
351
351
  if (!response.ok) {
352
352
  throw new Error("\u83B7\u53D6\u914D\u7F6E\u5931\u8D25");
353
353
  }
@@ -357,7 +357,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
357
357
  return config;
358
358
  };
359
359
  exports.updateConfig = async (configData) => {
360
- const response = await fetch("/api/masterpieces/config", {
360
+ const response = await fetch("/api/showmasterpiece/config", {
361
361
  method: "PUT",
362
362
  headers: {
363
363
  "Content-Type": "application/json"
@@ -373,7 +373,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
373
373
  return updatedConfig;
374
374
  };
375
375
  exports.resetConfig = async () => {
376
- const response = await fetch("/api/masterpieces/config", {
376
+ const response = await fetch("/api/showmasterpiece/config", {
377
377
  method: "DELETE"
378
378
  });
379
379
  if (!response.ok) {
@@ -388,7 +388,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
388
388
  console.log("\u{1F4E1} [\u670D\u52A1] \u5F00\u59CB\u83B7\u53D6\u6240\u6709\u753B\u96C6...");
389
389
  try {
390
390
  const timestamp = (/* @__PURE__ */ new Date()).getTime();
391
- const response = await fetch(`/api/masterpieces/collections?_t=${timestamp}`, {
391
+ const response = await fetch(`/api/showmasterpiece/collections?_t=${timestamp}`, {
392
392
  method: "GET",
393
393
  headers: {
394
394
  "Cache-Control": "no-cache",
@@ -422,7 +422,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
422
422
  };
423
423
  exports.createCollection = async (collectionData) => {
424
424
  const requestBody = collectionData;
425
- const response = await fetch("/api/masterpieces/collections", {
425
+ const response = await fetch("/api/showmasterpiece/collections", {
426
426
  method: "POST",
427
427
  headers: {
428
428
  "Content-Type": "application/json"
@@ -438,7 +438,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
438
438
  return await response.json();
439
439
  };
440
440
  exports.updateCollection = async (id, collectionData) => {
441
- const response = await fetch(`/api/masterpieces/collections/${id}`, {
441
+ const response = await fetch(`/api/showmasterpiece/collections/${id}`, {
442
442
  method: "PUT",
443
443
  headers: {
444
444
  "Content-Type": "application/json"
@@ -464,7 +464,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
464
464
  }
465
465
  };
466
466
  exports.updateCollectionOrder = async (collectionOrders) => {
467
- const response = await fetch("/api/masterpieces/collections?action=reorder", {
467
+ const response = await fetch("/api/showmasterpiece/collections?action=reorder", {
468
468
  method: "PATCH",
469
469
  headers: {
470
470
  "Content-Type": "application/json"
@@ -477,7 +477,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
477
477
  }
478
478
  };
479
479
  exports.moveCollection = async (collectionId, targetOrder) => {
480
- const response = await fetch("/api/masterpieces/collections?action=move", {
480
+ const response = await fetch("/api/showmasterpiece/collections?action=move", {
481
481
  method: "PATCH",
482
482
  headers: {
483
483
  "Content-Type": "application/json"
@@ -490,7 +490,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
490
490
  }
491
491
  };
492
492
  exports.moveCollectionUp = async (collectionId) => {
493
- const response = await fetch("/api/masterpieces/collections?action=up", {
493
+ const response = await fetch("/api/showmasterpiece/collections?action=up", {
494
494
  method: "PATCH",
495
495
  headers: {
496
496
  "Content-Type": "application/json"
@@ -503,7 +503,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
503
503
  }
504
504
  };
505
505
  exports.moveCollectionDown = async (collectionId) => {
506
- const response = await fetch("/api/masterpieces/collections?action=down", {
506
+ const response = await fetch("/api/showmasterpiece/collections?action=down", {
507
507
  method: "PATCH",
508
508
  headers: {
509
509
  "Content-Type": "application/json"
@@ -525,8 +525,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
525
525
  const requestBody = JSON.stringify(artworkData);
526
526
  console.log("\u{1F4E6} [\u670D\u52A1] \u8BF7\u6C42\u4F53\u5927\u5C0F:", `${requestBody.length} chars (${(requestBody.length / 1024).toFixed(1)} KB)`);
527
527
  try {
528
- console.log("\u{1F680} [\u670D\u52A1] \u53D1\u9001HTTP POST\u8BF7\u6C42\u5230:", `/api/masterpieces/collections/${collectionId}/artworks`);
529
- const response = await fetch(`/api/masterpieces/collections/${collectionId}/artworks`, {
528
+ const response = await fetch(`/api/showmasterpiece/collections/${collectionId}/artworks`, {
530
529
  method: "POST",
531
530
  headers: {
532
531
  "Content-Type": "application/json"
@@ -567,7 +566,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
567
566
  }
568
567
  };
569
568
  exports.updateArtwork = async (collectionId, artworkId, artworkData) => {
570
- const response = await fetch(`/api/masterpieces/collections/${collectionId}/artworks/${artworkId}`, {
569
+ const response = await fetch(`/api/showmasterpiece/collections/${collectionId}/artworks/${artworkId}`, {
571
570
  method: "PUT",
572
571
  headers: {
573
572
  "Content-Type": "application/json"
@@ -594,7 +593,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
594
593
  };
595
594
  exports.getArtworksByCollection = async (collectionId) => {
596
595
  const timestamp = (/* @__PURE__ */ new Date()).getTime();
597
- const response = await fetch(`/api/masterpieces/collections/${collectionId}/artworks?_t=${timestamp}`, {
596
+ const response = await fetch(`/api/showmasterpiece/collections/${collectionId}/artworks?_t=${timestamp}`, {
598
597
  headers: {
599
598
  "Cache-Control": "no-cache",
600
599
  "Pragma": "no-cache"
@@ -606,7 +605,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
606
605
  return await response.json();
607
606
  };
608
607
  exports.updateArtworkOrder = async (collectionId, artworkOrders) => {
609
- const response = await fetch(`/api/masterpieces/collections/${collectionId}/artworks?action=reorder`, {
608
+ const response = await fetch(`/api/showmasterpiece/collections/${collectionId}/artworks?action=reorder`, {
610
609
  method: "PATCH",
611
610
  headers: {
612
611
  "Content-Type": "application/json"
@@ -619,7 +618,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
619
618
  }
620
619
  };
621
620
  exports.moveArtwork = async (collectionId, artworkId, targetOrder) => {
622
- const response = await fetch(`/api/masterpieces/collections/${collectionId}/artworks?action=move`, {
621
+ const response = await fetch(`/api/showmasterpiece/collections/${collectionId}/artworks?action=move`, {
623
622
  method: "PATCH",
624
623
  headers: {
625
624
  "Content-Type": "application/json"
@@ -632,7 +631,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
632
631
  }
633
632
  };
634
633
  exports.moveArtworkUp = async (collectionId, artworkId) => {
635
- const response = await fetch(`/api/masterpieces/collections/${collectionId}/artworks?action=up`, {
634
+ const response = await fetch(`/api/showmasterpiece/collections/${collectionId}/artworks?action=up`, {
636
635
  method: "PATCH",
637
636
  headers: {
638
637
  "Content-Type": "application/json"
@@ -645,7 +644,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
645
644
  }
646
645
  };
647
646
  exports.moveArtworkDown = async (collectionId, artworkId) => {
648
- const response = await fetch(`/api/masterpieces/collections/${collectionId}/artworks?action=down`, {
647
+ const response = await fetch(`/api/showmasterpiece/collections/${collectionId}/artworks?action=down`, {
649
648
  method: "PATCH",
650
649
  headers: {
651
650
  "Content-Type": "application/json"
@@ -658,7 +657,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
658
657
  }
659
658
  };
660
659
  exports.getCategories = async () => {
661
- const response = await fetch("/api/masterpieces/categories");
660
+ const response = await fetch("/api/showmasterpiece/categories");
662
661
  if (!response.ok) {
663
662
  throw new Error("\u83B7\u53D6\u5206\u7C7B\u5931\u8D25");
664
663
  }
@@ -670,7 +669,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
670
669
  return categories;
671
670
  };
672
671
  exports.createCategory = async (name, description) => {
673
- const response = await fetch("/api/masterpieces/categories", {
672
+ const response = await fetch("/api/showmasterpiece/categories", {
674
673
  method: "POST",
675
674
  headers: {
676
675
  "Content-Type": "application/json"
@@ -683,7 +682,7 @@ var init_masterpiecesConfigService = chunkZ6ZWNWWR_js.__esm({
683
682
  }
684
683
  };
685
684
  exports.getTags = async () => {
686
- const response = await fetch("/api/masterpieces/tags");
685
+ const response = await fetch("/api/showmasterpiece/tags");
687
686
  if (!response.ok) {
688
687
  throw new Error("\u83B7\u53D6\u6807\u7B7E\u5931\u8D25");
689
688
  }
@@ -2445,7 +2444,7 @@ var init_useMasterpiecesConfig = chunkZ6ZWNWWR_js.__esm({
2445
2444
  const timestamp = Date.now();
2446
2445
  const [configData, collectionsResponse, categoriesData, tagsData] = await Promise.all([
2447
2446
  exports.getConfig(),
2448
- fetch(`/api/masterpieces/collections?_t=${timestamp}&nocache=true&includeImages=true`, {
2447
+ fetch(`/api/showmasterpiece/collections?_t=${timestamp}&nocache=true&includeImages=true`, {
2449
2448
  headers: {
2450
2449
  "Cache-Control": "no-cache",
2451
2450
  "Pragma": "no-cache"