@strapi/content-manager 0.0.0-experimental.5788c38836be65c0321a2dcadbdf44f04b798e8a → 0.0.0-experimental.58c6b635911a7cb83cd165b4e5abd75b8ec30893

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.
Files changed (149) hide show
  1. package/dist/_chunks/{ComponentConfigurationPage-D1YuKq8j.mjs → ComponentConfigurationPage-BpM_Hc7r.mjs} +4 -4
  2. package/dist/_chunks/{ComponentConfigurationPage-D1YuKq8j.mjs.map → ComponentConfigurationPage-BpM_Hc7r.mjs.map} +1 -1
  3. package/dist/_chunks/{ComponentConfigurationPage-B42mQr1K.js → ComponentConfigurationPage-CL9CAMaL.js} +4 -4
  4. package/dist/_chunks/{ComponentConfigurationPage-B42mQr1K.js.map → ComponentConfigurationPage-CL9CAMaL.js.map} +1 -1
  5. package/dist/_chunks/{EditConfigurationPage-NC89F29V.js → EditConfigurationPage-ILWo0h1e.js} +4 -4
  6. package/dist/_chunks/{EditConfigurationPage-NC89F29V.js.map → EditConfigurationPage-ILWo0h1e.js.map} +1 -1
  7. package/dist/_chunks/{EditConfigurationPage-C9yiwgI_.mjs → EditConfigurationPage-_prbqpTM.mjs} +4 -4
  8. package/dist/_chunks/{EditConfigurationPage-C9yiwgI_.mjs.map → EditConfigurationPage-_prbqpTM.mjs.map} +1 -1
  9. package/dist/_chunks/{EditViewPage-DYDpe5Wi.js → EditViewPage-BqZvBN4s.js} +3 -3
  10. package/dist/_chunks/EditViewPage-BqZvBN4s.js.map +1 -0
  11. package/dist/_chunks/{EditViewPage-k8UcfVwt.mjs → EditViewPage-DAtscabN.mjs} +3 -3
  12. package/dist/_chunks/EditViewPage-DAtscabN.mjs.map +1 -0
  13. package/dist/_chunks/{Field-Crhugun2.js → Field-CcoQiiz1.js} +13 -9
  14. package/dist/_chunks/{Field-Crhugun2.js.map → Field-CcoQiiz1.js.map} +1 -1
  15. package/dist/_chunks/{Field-BLL5lknV.mjs → Field-D-mgn1tH.mjs} +13 -9
  16. package/dist/_chunks/{Field-BLL5lknV.mjs.map → Field-D-mgn1tH.mjs.map} +1 -1
  17. package/dist/_chunks/{Form-UHu2eOuG.mjs → Form-BxyeWiXW.mjs} +3 -3
  18. package/dist/_chunks/Form-BxyeWiXW.mjs.map +1 -0
  19. package/dist/_chunks/{Form-DUU19g6M.js → Form-CmLbZDfi.js} +3 -3
  20. package/dist/_chunks/Form-CmLbZDfi.js.map +1 -0
  21. package/dist/_chunks/{History-CpxkZXS3.mjs → History-BOhLaq_g.mjs} +38 -41
  22. package/dist/_chunks/History-BOhLaq_g.mjs.map +1 -0
  23. package/dist/_chunks/{History-CyA8tvJZ.js → History-uECUbCZB.js} +37 -40
  24. package/dist/_chunks/History-uECUbCZB.js.map +1 -0
  25. package/dist/_chunks/{ListConfigurationPage-OUwV8QF1.mjs → ListConfigurationPage-D0vQez6F.mjs} +3 -3
  26. package/dist/_chunks/{ListConfigurationPage-OUwV8QF1.mjs.map → ListConfigurationPage-D0vQez6F.mjs.map} +1 -1
  27. package/dist/_chunks/{ListConfigurationPage-pJV7aG2V.js → ListConfigurationPage-D_bBSFNW.js} +3 -3
  28. package/dist/_chunks/{ListConfigurationPage-pJV7aG2V.js.map → ListConfigurationPage-D_bBSFNW.js.map} +1 -1
  29. package/dist/_chunks/{ListViewPage-BIT0M8VG.js → ListViewPage-BkZ83b1A.js} +15 -4
  30. package/dist/_chunks/ListViewPage-BkZ83b1A.js.map +1 -0
  31. package/dist/_chunks/{ListViewPage-BOnhCGkE.mjs → ListViewPage-ns-bmy5C.mjs} +15 -4
  32. package/dist/_chunks/{ListViewPage-BOnhCGkE.mjs.map → ListViewPage-ns-bmy5C.mjs.map} +1 -1
  33. package/dist/_chunks/{NoContentTypePage-CwjlHGTn.mjs → NoContentTypePage-BA5ZKMDR.mjs} +2 -2
  34. package/dist/_chunks/{NoContentTypePage-CwjlHGTn.mjs.map → NoContentTypePage-BA5ZKMDR.mjs.map} +1 -1
  35. package/dist/_chunks/{NoContentTypePage-uIBsBUmH.js → NoContentTypePage-C1439s4s.js} +2 -2
  36. package/dist/_chunks/{NoContentTypePage-uIBsBUmH.js.map → NoContentTypePage-C1439s4s.js.map} +1 -1
  37. package/dist/_chunks/{NoPermissionsPage-CcWbyT_z.mjs → NoPermissionsPage-B0GdMw1Q.mjs} +2 -2
  38. package/dist/_chunks/{NoPermissionsPage-CcWbyT_z.mjs.map → NoPermissionsPage-B0GdMw1Q.mjs.map} +1 -1
  39. package/dist/_chunks/{NoPermissionsPage-C8wkEaOF.js → NoPermissionsPage-CPGwsVfb.js} +2 -2
  40. package/dist/_chunks/{NoPermissionsPage-C8wkEaOF.js.map → NoPermissionsPage-CPGwsVfb.js.map} +1 -1
  41. package/dist/_chunks/{Relations-wIdWJnA9.mjs → Relations-BIGPMSW4.mjs} +44 -17
  42. package/dist/_chunks/Relations-BIGPMSW4.mjs.map +1 -0
  43. package/dist/_chunks/{Relations-CwRu_eZv.js → Relations-d-8Uef_-.js} +43 -16
  44. package/dist/_chunks/Relations-d-8Uef_-.js.map +1 -0
  45. package/dist/_chunks/{en-Bm0D0IWz.js → en-Bdpa50w3.js} +6 -2
  46. package/dist/_chunks/{en-Bm0D0IWz.js.map → en-Bdpa50w3.js.map} +1 -1
  47. package/dist/_chunks/{en-DKV44jRb.mjs → en-CZw4xdPY.mjs} +6 -2
  48. package/dist/_chunks/{en-DKV44jRb.mjs.map → en-CZw4xdPY.mjs.map} +1 -1
  49. package/dist/_chunks/{es-EUonQTon.js → es-9K52xZIr.js} +2 -2
  50. package/dist/_chunks/{ja-CcFe8diO.js.map → es-9K52xZIr.js.map} +1 -1
  51. package/dist/_chunks/{es-CeXiYflN.mjs → es-D34tqjMw.mjs} +2 -2
  52. package/dist/_chunks/{es-CeXiYflN.mjs.map → es-D34tqjMw.mjs.map} +1 -1
  53. package/dist/_chunks/{fr-CD9VFbPM.mjs → fr--pg5jUbt.mjs} +13 -3
  54. package/dist/_chunks/{fr-CD9VFbPM.mjs.map → fr--pg5jUbt.mjs.map} +1 -1
  55. package/dist/_chunks/{fr-B7kGGg3E.js → fr-B2Kyv8Z9.js} +13 -3
  56. package/dist/_chunks/{fr-B7kGGg3E.js.map → fr-B2Kyv8Z9.js.map} +1 -1
  57. package/dist/_chunks/{index-BQ8DxaCa.mjs → index-3_WeHXYp.mjs} +137 -34
  58. package/dist/_chunks/index-3_WeHXYp.mjs.map +1 -0
  59. package/dist/_chunks/{index-BO-T2BdP.js → index-BgaeYWIy.js} +136 -32
  60. package/dist/_chunks/index-BgaeYWIy.js.map +1 -0
  61. package/dist/_chunks/{ja-CcFe8diO.js → ja-7sfIbjxE.js} +2 -2
  62. package/dist/_chunks/{es-EUonQTon.js.map → ja-7sfIbjxE.js.map} +1 -1
  63. package/dist/_chunks/{ja-CtsUxOvk.mjs → ja-BHqhDq4V.mjs} +2 -2
  64. package/dist/_chunks/{ja-CtsUxOvk.mjs.map → ja-BHqhDq4V.mjs.map} +1 -1
  65. package/dist/_chunks/{layout-BTB1_M8g.js → layout-ByFyQRDH.js} +3 -3
  66. package/dist/_chunks/{layout-BTB1_M8g.js.map → layout-ByFyQRDH.js.map} +1 -1
  67. package/dist/_chunks/{layout-N63eyE5E.mjs → layout-CrTxOnCy.mjs} +3 -3
  68. package/dist/_chunks/{layout-N63eyE5E.mjs.map → layout-CrTxOnCy.mjs.map} +1 -1
  69. package/dist/_chunks/{objects-gigeqt7s.js → objects-BcXOv6_9.js} +2 -4
  70. package/dist/_chunks/{objects-gigeqt7s.js.map → objects-BcXOv6_9.js.map} +1 -1
  71. package/dist/_chunks/{objects-mKMAmfec.mjs → objects-D6yBsdmx.mjs} +2 -4
  72. package/dist/_chunks/{objects-mKMAmfec.mjs.map → objects-D6yBsdmx.mjs.map} +1 -1
  73. package/dist/_chunks/{relations-Bh9r0CVE.mjs → relations-BlpLgngh.mjs} +3 -7
  74. package/dist/_chunks/relations-BlpLgngh.mjs.map +1 -0
  75. package/dist/_chunks/{relations-C9AQuM2z.js → relations-C5RSW926.js} +3 -7
  76. package/dist/_chunks/relations-C5RSW926.js.map +1 -0
  77. package/dist/admin/index.js +1 -1
  78. package/dist/admin/index.mjs +1 -1
  79. package/dist/admin/src/preview/components/PreviewSidePanel.d.ts +3 -0
  80. package/dist/admin/src/preview/constants.d.ts +1 -0
  81. package/dist/admin/src/preview/index.d.ts +4 -0
  82. package/dist/admin/src/preview/services/preview.d.ts +3 -0
  83. package/dist/server/index.js +350 -145
  84. package/dist/server/index.js.map +1 -1
  85. package/dist/server/index.mjs +350 -145
  86. package/dist/server/index.mjs.map +1 -1
  87. package/dist/server/src/bootstrap.d.ts.map +1 -1
  88. package/dist/server/src/controllers/index.d.ts.map +1 -1
  89. package/dist/server/src/controllers/relations.d.ts.map +1 -1
  90. package/dist/server/src/controllers/utils/metadata.d.ts +15 -1
  91. package/dist/server/src/controllers/utils/metadata.d.ts.map +1 -1
  92. package/dist/server/src/history/services/history.d.ts.map +1 -1
  93. package/dist/server/src/history/services/lifecycles.d.ts.map +1 -1
  94. package/dist/server/src/history/services/utils.d.ts +2 -3
  95. package/dist/server/src/history/services/utils.d.ts.map +1 -1
  96. package/dist/server/src/index.d.ts +4 -4
  97. package/dist/server/src/preview/constants.d.ts +2 -0
  98. package/dist/server/src/preview/constants.d.ts.map +1 -0
  99. package/dist/server/src/preview/controllers/index.d.ts +2 -0
  100. package/dist/server/src/preview/controllers/index.d.ts.map +1 -0
  101. package/dist/server/src/preview/controllers/preview.d.ts +13 -0
  102. package/dist/server/src/preview/controllers/preview.d.ts.map +1 -0
  103. package/dist/server/src/preview/controllers/validation/preview.d.ts +6 -0
  104. package/dist/server/src/preview/controllers/validation/preview.d.ts.map +1 -0
  105. package/dist/server/src/preview/index.d.ts +4 -0
  106. package/dist/server/src/preview/index.d.ts.map +1 -0
  107. package/dist/server/src/preview/routes/index.d.ts +8 -0
  108. package/dist/server/src/preview/routes/index.d.ts.map +1 -0
  109. package/dist/server/src/preview/routes/preview.d.ts +4 -0
  110. package/dist/server/src/preview/routes/preview.d.ts.map +1 -0
  111. package/dist/server/src/preview/services/index.d.ts +15 -0
  112. package/dist/server/src/preview/services/index.d.ts.map +1 -0
  113. package/dist/server/src/preview/services/preview-config.d.ts +30 -0
  114. package/dist/server/src/preview/services/preview-config.d.ts.map +1 -0
  115. package/dist/server/src/preview/services/preview.d.ts +12 -0
  116. package/dist/server/src/preview/services/preview.d.ts.map +1 -0
  117. package/dist/server/src/preview/utils.d.ts +18 -0
  118. package/dist/server/src/preview/utils.d.ts.map +1 -0
  119. package/dist/server/src/routes/index.d.ts.map +1 -1
  120. package/dist/server/src/services/document-metadata.d.ts +8 -8
  121. package/dist/server/src/services/document-metadata.d.ts.map +1 -1
  122. package/dist/server/src/services/index.d.ts +4 -4
  123. package/dist/server/src/services/index.d.ts.map +1 -1
  124. package/dist/server/src/services/utils/configuration/index.d.ts +2 -2
  125. package/dist/server/src/services/utils/configuration/layouts.d.ts +2 -2
  126. package/dist/server/src/utils/index.d.ts +2 -0
  127. package/dist/server/src/utils/index.d.ts.map +1 -1
  128. package/dist/shared/contracts/index.d.ts +1 -0
  129. package/dist/shared/contracts/index.d.ts.map +1 -1
  130. package/dist/shared/contracts/preview.d.ts +27 -0
  131. package/dist/shared/contracts/preview.d.ts.map +1 -0
  132. package/dist/shared/index.js +4 -0
  133. package/dist/shared/index.js.map +1 -1
  134. package/dist/shared/index.mjs +4 -0
  135. package/dist/shared/index.mjs.map +1 -1
  136. package/package.json +8 -8
  137. package/dist/_chunks/EditViewPage-DYDpe5Wi.js.map +0 -1
  138. package/dist/_chunks/EditViewPage-k8UcfVwt.mjs.map +0 -1
  139. package/dist/_chunks/Form-DUU19g6M.js.map +0 -1
  140. package/dist/_chunks/Form-UHu2eOuG.mjs.map +0 -1
  141. package/dist/_chunks/History-CpxkZXS3.mjs.map +0 -1
  142. package/dist/_chunks/History-CyA8tvJZ.js.map +0 -1
  143. package/dist/_chunks/ListViewPage-BIT0M8VG.js.map +0 -1
  144. package/dist/_chunks/Relations-CwRu_eZv.js.map +0 -1
  145. package/dist/_chunks/Relations-wIdWJnA9.mjs.map +0 -1
  146. package/dist/_chunks/index-BO-T2BdP.js.map +0 -1
  147. package/dist/_chunks/index-BQ8DxaCa.mjs.map +0 -1
  148. package/dist/_chunks/relations-Bh9r0CVE.mjs.map +0 -1
  149. package/dist/_chunks/relations-C9AQuM2z.js.map +0 -1
@@ -76,7 +76,7 @@ const en = {
76
76
  "components.TableEmpty.withFilters": "There are no {contentType} with the applied filters...",
77
77
  "components.TableEmpty.withSearch": "There are no {contentType} corresponding to the search ({search})...",
78
78
  "components.TableEmpty.withoutFilter": "There are no {contentType}...",
79
- "components.empty-repeatable": "No entry yet. Click on the button below to add one.",
79
+ "components.empty-repeatable": "No entry yet. Click to add one.",
80
80
  "components.notification.info.maximum-requirement": "You have already reached the maximum number of fields",
81
81
  "components.notification.info.minimum-requirement": "A field has been added to match the minimum requirement",
82
82
  "components.repeatable.reorder.error": "An error occurred while reordering your component's field, please try again",
@@ -236,6 +236,10 @@ const en = {
236
236
  "popUpWarning.warning.unpublish-question": "Are you sure you don't want to publish it?",
237
237
  "popUpWarning.warning.updateAllSettings": "This will modify all your settings",
238
238
  "popover.display-relations.label": "Display relations",
239
+ "preview.panel.title": "Preview",
240
+ "preview.panel.button": "Open preview",
241
+ "preview.copy.label": "Copy preview link",
242
+ "preview.copy.success": "Copied preview link",
239
243
  "relation.add": "Add relation",
240
244
  "relation.disconnect": "Remove",
241
245
  "relation.error-adding-relation": "An error occurred while trying to add the relation.",
@@ -290,4 +294,4 @@ exports.default = en;
290
294
  exports.groups = groups;
291
295
  exports.models = models;
292
296
  exports.pageNotFound = pageNotFound;
293
- //# sourceMappingURL=en-Bm0D0IWz.js.map
297
+ //# sourceMappingURL=en-Bdpa50w3.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"en-Bm0D0IWz.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"en-Bdpa50w3.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -74,7 +74,7 @@ const en = {
74
74
  "components.TableEmpty.withFilters": "There are no {contentType} with the applied filters...",
75
75
  "components.TableEmpty.withSearch": "There are no {contentType} corresponding to the search ({search})...",
76
76
  "components.TableEmpty.withoutFilter": "There are no {contentType}...",
77
- "components.empty-repeatable": "No entry yet. Click on the button below to add one.",
77
+ "components.empty-repeatable": "No entry yet. Click to add one.",
78
78
  "components.notification.info.maximum-requirement": "You have already reached the maximum number of fields",
79
79
  "components.notification.info.minimum-requirement": "A field has been added to match the minimum requirement",
80
80
  "components.repeatable.reorder.error": "An error occurred while reordering your component's field, please try again",
@@ -234,6 +234,10 @@ const en = {
234
234
  "popUpWarning.warning.unpublish-question": "Are you sure you don't want to publish it?",
235
235
  "popUpWarning.warning.updateAllSettings": "This will modify all your settings",
236
236
  "popover.display-relations.label": "Display relations",
237
+ "preview.panel.title": "Preview",
238
+ "preview.panel.button": "Open preview",
239
+ "preview.copy.label": "Copy preview link",
240
+ "preview.copy.success": "Copied preview link",
237
241
  "relation.add": "Add relation",
238
242
  "relation.disconnect": "Remove",
239
243
  "relation.error-adding-relation": "An error occurred while trying to add the relation.",
@@ -290,4 +294,4 @@ export {
290
294
  models,
291
295
  pageNotFound
292
296
  };
293
- //# sourceMappingURL=en-DKV44jRb.mjs.map
297
+ //# sourceMappingURL=en-CZw4xdPY.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"en-DKV44jRb.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"en-CZw4xdPY.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -54,7 +54,7 @@ const es = {
54
54
  "components.TableEmpty.withFilters": "No hay {contentType} con los filtros aplicados...",
55
55
  "components.TableEmpty.withSearch": "No hay {contentType} que coincida con la búsqueda ({search})...",
56
56
  "components.TableEmpty.withoutFilter": "No hay {contentType}...",
57
- "components.empty-repeatable": "Aún no hay entrada. Haga clic en el botón de abajo para agregar uno.",
57
+ "components.empty-repeatable": "Aún no hay entrada. Haga clic para agregar una.",
58
58
  "components.notification.info.maximum-requirement": "Ya has alcanzado el número máximo de campos",
59
59
  "components.notification.info.minimum-requirement": "Se ha agregado un campo para cumplir con el requisito mínimo",
60
60
  "components.repeatable.reorder.error": "Se produjo un error al reordenar el campo de su componente. Vuelva a intentarlo.",
@@ -193,4 +193,4 @@ exports.default = es;
193
193
  exports.groups = groups;
194
194
  exports.models = models;
195
195
  exports.pageNotFound = pageNotFound;
196
- //# sourceMappingURL=es-EUonQTon.js.map
196
+ //# sourceMappingURL=es-9K52xZIr.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ja-CcFe8diO.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"es-9K52xZIr.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -52,7 +52,7 @@ const es = {
52
52
  "components.TableEmpty.withFilters": "No hay {contentType} con los filtros aplicados...",
53
53
  "components.TableEmpty.withSearch": "No hay {contentType} que coincida con la búsqueda ({search})...",
54
54
  "components.TableEmpty.withoutFilter": "No hay {contentType}...",
55
- "components.empty-repeatable": "Aún no hay entrada. Haga clic en el botón de abajo para agregar uno.",
55
+ "components.empty-repeatable": "Aún no hay entrada. Haga clic para agregar una.",
56
56
  "components.notification.info.maximum-requirement": "Ya has alcanzado el número máximo de campos",
57
57
  "components.notification.info.minimum-requirement": "Se ha agregado un campo para cumplir con el requisito mínimo",
58
58
  "components.repeatable.reorder.error": "Se produjo un error al reordenar el campo de su componente. Vuelva a intentarlo.",
@@ -193,4 +193,4 @@ export {
193
193
  models,
194
194
  pageNotFound
195
195
  };
196
- //# sourceMappingURL=es-CeXiYflN.mjs.map
196
+ //# sourceMappingURL=es-D34tqjMw.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"es-CeXiYflN.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"es-D34tqjMw.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -52,7 +52,7 @@ const fr = {
52
52
  "components.TableEmpty.withFilters": "Aucun {contentType} n'a été trouvé avec ces filtres...",
53
53
  "components.TableEmpty.withSearch": "Aucun {contentType} n'a été trouvé avec cette recherche ({search})...",
54
54
  "components.TableEmpty.withoutFilter": "Aucun {contentType} n'a été trouvé...",
55
- "components.empty-repeatable": "Il n'a pas encore d'entrée. Cliquez sur le bouton pour en ajouter une.",
55
+ "components.empty-repeatable": "Il n'a pas encore d'entrée. Cliquez pour en ajouter une.",
56
56
  "components.notification.info.maximum-requirement": "Le nombre maximal de champs est atteint",
57
57
  "components.notification.info.minimum-requirement": "Un champ a été rajouté pour remplir les conditions minimales",
58
58
  "components.repeatable.reorder.error": "Une erreur s'est produite lors de la réorganisation du champ de votre composant, veuillez réessayer",
@@ -195,7 +195,17 @@ const fr = {
195
195
  "apiError.This attribute must be unique": "Le champ {field} doit être unique",
196
196
  "popUpWarning.warning.publish-question": "Êtes-vous sûr de vouloir le publier ?",
197
197
  "popUpwarning.warning.has-draft-relations.button-confirm": "Oui, publier",
198
- "popUpwarning.warning.has-draft-relations.message": "<b>{count, plural, =0 { des relations de votre contenu n'est} one { des relations de votre contenu n'est} other { des relations de votre contenu ne sont}}</b> pas publié actuellement.<br></br>Cela peut engendrer des liens cassés ou des erreurs dans votre projet."
198
+ "popUpwarning.warning.has-draft-relations.message": "<b>{count, plural, =0 { des relations de votre contenu n'est} one { des relations de votre contenu n'est} other { des relations de votre contenu ne sont}}</b> pas publié actuellement.<br></br>Cela peut engendrer des liens cassés ou des erreurs dans votre projet.",
199
+ "history.sidebar.show-newer": "Voir les versions récentes",
200
+ "history.sidebar.show-older": "Voir les anciennes versions",
201
+ "history.content.new-field.message": "Ce champ n'existait pas lorsque cette version a été sauvegardée. Si vous restaurez cette version, il sera vide.",
202
+ "history.content.unknown-fields.message": "Ces champs ont été supprimés ou renommés dans le Content-Type Builder. <b>Ces champs ne seront pas restaurés.</b>",
203
+ "history.content.no-relations": "Aucune relation.",
204
+ "history.restore.confirm.button": "Restaurer",
205
+ "history.restore.confirm.title": "Êtes-vous sûr de vouloir restaurer cette version ?",
206
+ "history.restore.confirm.message": "{isDraft, select, true {Le contenu restauré écrasera votre brouillon.} other {Le contenu restauré ne sera pas publié, il écrasera le brouillon et sera sauvegardé en tant que changement en attente de publication. Vous pourrez publier les changements à tout moment.}}",
207
+ "history.restore.success.title": "Version restaurée.",
208
+ "history.restore.success.message": "Le contenu de la version restaurée n'a pas encore été publié."
199
209
  };
200
210
  export {
201
211
  fr as default,
@@ -203,4 +213,4 @@ export {
203
213
  models,
204
214
  pageNotFound
205
215
  };
206
- //# sourceMappingURL=fr-CD9VFbPM.mjs.map
216
+ //# sourceMappingURL=fr--pg5jUbt.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"fr-CD9VFbPM.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"fr--pg5jUbt.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -54,7 +54,7 @@ const fr = {
54
54
  "components.TableEmpty.withFilters": "Aucun {contentType} n'a été trouvé avec ces filtres...",
55
55
  "components.TableEmpty.withSearch": "Aucun {contentType} n'a été trouvé avec cette recherche ({search})...",
56
56
  "components.TableEmpty.withoutFilter": "Aucun {contentType} n'a été trouvé...",
57
- "components.empty-repeatable": "Il n'a pas encore d'entrée. Cliquez sur le bouton pour en ajouter une.",
57
+ "components.empty-repeatable": "Il n'a pas encore d'entrée. Cliquez pour en ajouter une.",
58
58
  "components.notification.info.maximum-requirement": "Le nombre maximal de champs est atteint",
59
59
  "components.notification.info.minimum-requirement": "Un champ a été rajouté pour remplir les conditions minimales",
60
60
  "components.repeatable.reorder.error": "Une erreur s'est produite lors de la réorganisation du champ de votre composant, veuillez réessayer",
@@ -197,10 +197,20 @@ const fr = {
197
197
  "apiError.This attribute must be unique": "Le champ {field} doit être unique",
198
198
  "popUpWarning.warning.publish-question": "Êtes-vous sûr de vouloir le publier ?",
199
199
  "popUpwarning.warning.has-draft-relations.button-confirm": "Oui, publier",
200
- "popUpwarning.warning.has-draft-relations.message": "<b>{count, plural, =0 { des relations de votre contenu n'est} one { des relations de votre contenu n'est} other { des relations de votre contenu ne sont}}</b> pas publié actuellement.<br></br>Cela peut engendrer des liens cassés ou des erreurs dans votre projet."
200
+ "popUpwarning.warning.has-draft-relations.message": "<b>{count, plural, =0 { des relations de votre contenu n'est} one { des relations de votre contenu n'est} other { des relations de votre contenu ne sont}}</b> pas publié actuellement.<br></br>Cela peut engendrer des liens cassés ou des erreurs dans votre projet.",
201
+ "history.sidebar.show-newer": "Voir les versions récentes",
202
+ "history.sidebar.show-older": "Voir les anciennes versions",
203
+ "history.content.new-field.message": "Ce champ n'existait pas lorsque cette version a été sauvegardée. Si vous restaurez cette version, il sera vide.",
204
+ "history.content.unknown-fields.message": "Ces champs ont été supprimés ou renommés dans le Content-Type Builder. <b>Ces champs ne seront pas restaurés.</b>",
205
+ "history.content.no-relations": "Aucune relation.",
206
+ "history.restore.confirm.button": "Restaurer",
207
+ "history.restore.confirm.title": "Êtes-vous sûr de vouloir restaurer cette version ?",
208
+ "history.restore.confirm.message": "{isDraft, select, true {Le contenu restauré écrasera votre brouillon.} other {Le contenu restauré ne sera pas publié, il écrasera le brouillon et sera sauvegardé en tant que changement en attente de publication. Vous pourrez publier les changements à tout moment.}}",
209
+ "history.restore.success.title": "Version restaurée.",
210
+ "history.restore.success.message": "Le contenu de la version restaurée n'a pas encore été publié."
201
211
  };
202
212
  exports.default = fr;
203
213
  exports.groups = groups;
204
214
  exports.models = models;
205
215
  exports.pageNotFound = pageNotFound;
206
- //# sourceMappingURL=fr-B7kGGg3E.js.map
216
+ //# sourceMappingURL=fr-B2Kyv8Z9.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"fr-B7kGGg3E.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"fr-B2Kyv8Z9.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,9 +1,10 @@
1
- import { More, Cross, WarningCircle, ListPlus, Pencil, Trash, Check, CrossCircle, CheckCircle, ArrowsCounterClockwise, ChevronRight, Duplicate, ClockCounterClockwise, Feather } from "@strapi/icons";
1
+ import { More, Cross, WarningCircle, ListPlus, Pencil, Trash, Check, CrossCircle, CheckCircle, ArrowsCounterClockwise, ChevronRight, Duplicate, ClockCounterClockwise, Link as Link$1, Feather } from "@strapi/icons";
2
2
  import { jsx, Fragment, jsxs } from "react/jsx-runtime";
3
- import { useStrapiApp, createContext, useAuth, useRBAC, Page, adminApi, translatedErrors, useNotification, useAPIErrorHandler, useQueryParams, getYupValidationErrors, useForm, useTracking, useGuidedTour, BackButton, DescriptionComponentRenderer, useTable, Table } from "@strapi/admin/strapi-admin";
3
+ import { useStrapiApp, createContext, useQueryParams, useAuth, useRBAC, Page, adminApi, translatedErrors, useNotification, useAPIErrorHandler, getYupValidationErrors, useForm, useTracking, useGuidedTour, BackButton, DescriptionComponentRenderer, useTable, Table, useClipboard } from "@strapi/admin/strapi-admin";
4
4
  import * as React from "react";
5
5
  import { lazy } from "react";
6
6
  import { Button, Menu, VisuallyHidden, Flex, Typography, Dialog, Modal, Radio, Status, Box, SingleSelect, SingleSelectOption, IconButton, Loader, Tooltip, LinkButton } from "@strapi/design-system";
7
+ import mapValues from "lodash/fp/mapValues";
7
8
  import { useIntl } from "react-intl";
8
9
  import { useParams, useNavigate, Navigate, useMatch, useLocation, Link, NavLink } from "react-router-dom";
9
10
  import * as yup from "yup";
@@ -100,6 +101,7 @@ const DocumentRBAC = ({ children, permissions }) => {
100
101
  if (!slug) {
101
102
  throw new Error("Cannot find the slug param in the URL");
102
103
  }
104
+ const [{ rawQuery }] = useQueryParams();
103
105
  const userPermissions = useAuth("DocumentRBAC", (state) => state.permissions);
104
106
  const contentTypePermissions = React.useMemo(() => {
105
107
  const contentTypePermissions2 = userPermissions.filter(
@@ -110,7 +112,14 @@ const DocumentRBAC = ({ children, permissions }) => {
110
112
  return { ...acc, [action]: [permission] };
111
113
  }, {});
112
114
  }, [slug, userPermissions]);
113
- const { isLoading, allowedActions } = useRBAC(contentTypePermissions, permissions ?? void 0);
115
+ const { isLoading, allowedActions } = useRBAC(
116
+ contentTypePermissions,
117
+ permissions ?? void 0,
118
+ // TODO: useRBAC context should be typed and built differently
119
+ // We are passing raw query as context to the hook so that it can
120
+ // rely on the locale provided from DocumentRBAC for its permission calculations.
121
+ rawQuery
122
+ );
114
123
  const canCreateFields = !isLoading && allowedActions.canCreate ? extractAndDedupeFields(contentTypePermissions.create) : [];
115
124
  const canReadFields = !isLoading && allowedActions.canRead ? extractAndDedupeFields(contentTypePermissions.read) : [];
116
125
  const canUpdateFields = !isLoading && allowedActions.canUpdate ? extractAndDedupeFields(contentTypePermissions.update) : [];
@@ -461,12 +470,15 @@ const buildValidParams = (query) => {
461
470
  const isBaseQueryError = (error) => {
462
471
  return error.name !== void 0;
463
472
  };
464
- const arrayValidator = (options) => ({
473
+ const arrayValidator = (attribute, options) => ({
465
474
  message: translatedErrors.required,
466
475
  test(value) {
467
476
  if (options.status === "draft") {
468
477
  return true;
469
478
  }
479
+ if (!attribute.required) {
480
+ return true;
481
+ }
470
482
  if (!value) {
471
483
  return false;
472
484
  }
@@ -500,7 +512,7 @@ const createYupSchema = (attributes = {}, components = {}, options = { status: n
500
512
  ...acc,
501
513
  [name]: transformSchema(
502
514
  yup.array().of(createModelSchema(attributes3).nullable(false))
503
- ).test(arrayValidator(options))
515
+ ).test(arrayValidator(attribute, options))
504
516
  };
505
517
  } else {
506
518
  return {
@@ -527,7 +539,7 @@ const createYupSchema = (attributes = {}, components = {}, options = { status: n
527
539
  }
528
540
  )
529
541
  )
530
- ).test(arrayValidator(options))
542
+ ).test(arrayValidator(attribute, options))
531
543
  };
532
544
  case "relation":
533
545
  return {
@@ -957,9 +969,10 @@ const formatEditLayout = (data, {
957
969
  currentPanelIndex += 2;
958
970
  } else {
959
971
  if (!panels[currentPanelIndex]) {
960
- panels.push([]);
972
+ panels.push([row]);
973
+ } else {
974
+ panels[currentPanelIndex].push(row);
961
975
  }
962
- panels[currentPanelIndex].push(row);
963
976
  }
964
977
  return panels;
965
978
  }, []);
@@ -1163,16 +1176,18 @@ const useDoc = () => {
1163
1176
  if (!slug) {
1164
1177
  throw new Error("Could not find model in url params");
1165
1178
  }
1179
+ const document = useDocument(
1180
+ { documentId: origin || id, model: slug, collectionType, params },
1181
+ {
1182
+ skip: id === "create" || !origin && !id && collectionType !== SINGLE_TYPES
1183
+ }
1184
+ );
1185
+ const returnId = origin || id === "create" ? void 0 : id;
1166
1186
  return {
1167
1187
  collectionType,
1168
1188
  model: slug,
1169
- id: origin || id === "create" ? void 0 : id,
1170
- ...useDocument(
1171
- { documentId: origin || id, model: slug, collectionType, params },
1172
- {
1173
- skip: id === "create" || !origin && !id && collectionType !== SINGLE_TYPES
1174
- }
1175
- )
1189
+ id: returnId,
1190
+ ...document
1176
1191
  };
1177
1192
  };
1178
1193
  const useContentManagerContext = () => {
@@ -1215,9 +1230,6 @@ const useContentManagerContext = () => {
1215
1230
  };
1216
1231
  };
1217
1232
  const prefixPluginTranslations = (trad, pluginId) => {
1218
- if (!pluginId) {
1219
- throw new TypeError("pluginId can't be empty");
1220
- }
1221
1233
  return Object.keys(trad).reduce((acc, current) => {
1222
1234
  acc[`${pluginId}.${current}`] = trad[current];
1223
1235
  return acc;
@@ -1652,7 +1664,7 @@ const useDocumentActions = () => {
1652
1664
  };
1653
1665
  };
1654
1666
  const ProtectedHistoryPage = lazy(
1655
- () => import("./History-CpxkZXS3.mjs").then((mod) => ({ default: mod.ProtectedHistoryPage }))
1667
+ () => import("./History-BOhLaq_g.mjs").then((mod) => ({ default: mod.ProtectedHistoryPage }))
1656
1668
  );
1657
1669
  const routes$1 = [
1658
1670
  {
@@ -1665,31 +1677,31 @@ const routes$1 = [
1665
1677
  }
1666
1678
  ];
1667
1679
  const ProtectedEditViewPage = lazy(
1668
- () => import("./EditViewPage-k8UcfVwt.mjs").then((mod) => ({ default: mod.ProtectedEditViewPage }))
1680
+ () => import("./EditViewPage-DAtscabN.mjs").then((mod) => ({ default: mod.ProtectedEditViewPage }))
1669
1681
  );
1670
1682
  const ProtectedListViewPage = lazy(
1671
- () => import("./ListViewPage-BOnhCGkE.mjs").then((mod) => ({ default: mod.ProtectedListViewPage }))
1683
+ () => import("./ListViewPage-ns-bmy5C.mjs").then((mod) => ({ default: mod.ProtectedListViewPage }))
1672
1684
  );
1673
1685
  const ProtectedListConfiguration = lazy(
1674
- () => import("./ListConfigurationPage-OUwV8QF1.mjs").then((mod) => ({
1686
+ () => import("./ListConfigurationPage-D0vQez6F.mjs").then((mod) => ({
1675
1687
  default: mod.ProtectedListConfiguration
1676
1688
  }))
1677
1689
  );
1678
1690
  const ProtectedEditConfigurationPage = lazy(
1679
- () => import("./EditConfigurationPage-C9yiwgI_.mjs").then((mod) => ({
1691
+ () => import("./EditConfigurationPage-_prbqpTM.mjs").then((mod) => ({
1680
1692
  default: mod.ProtectedEditConfigurationPage
1681
1693
  }))
1682
1694
  );
1683
1695
  const ProtectedComponentConfigurationPage = lazy(
1684
- () => import("./ComponentConfigurationPage-D1YuKq8j.mjs").then((mod) => ({
1696
+ () => import("./ComponentConfigurationPage-BpM_Hc7r.mjs").then((mod) => ({
1685
1697
  default: mod.ProtectedComponentConfigurationPage
1686
1698
  }))
1687
1699
  );
1688
1700
  const NoPermissions = lazy(
1689
- () => import("./NoPermissionsPage-CcWbyT_z.mjs").then((mod) => ({ default: mod.NoPermissions }))
1701
+ () => import("./NoPermissionsPage-B0GdMw1Q.mjs").then((mod) => ({ default: mod.NoPermissions }))
1690
1702
  );
1691
1703
  const NoContentType = lazy(
1692
- () => import("./NoContentTypePage-CwjlHGTn.mjs").then((mod) => ({ default: mod.NoContentType }))
1704
+ () => import("./NoContentTypePage-BA5ZKMDR.mjs").then((mod) => ({ default: mod.NoContentType }))
1693
1705
  );
1694
1706
  const CollectionTypePages = () => {
1695
1707
  const { collectionType } = useParams();
@@ -2043,6 +2055,18 @@ const DocumentActionModal = ({
2043
2055
  typeof Footer === "function" ? /* @__PURE__ */ jsx(Footer, { onClose: handleClose }) : Footer
2044
2056
  ] }) });
2045
2057
  };
2058
+ const transformData = (data) => {
2059
+ if (Array.isArray(data)) {
2060
+ return data.map(transformData);
2061
+ }
2062
+ if (typeof data === "object" && data !== null) {
2063
+ if ("apiData" in data) {
2064
+ return data.apiData;
2065
+ }
2066
+ return mapValues(transformData)(data);
2067
+ }
2068
+ return data;
2069
+ };
2046
2070
  const PublishAction$1 = ({
2047
2071
  activeTab,
2048
2072
  documentId,
@@ -2156,7 +2180,7 @@ const PublishAction$1 = ({
2156
2180
  documentId,
2157
2181
  params
2158
2182
  },
2159
- formValues
2183
+ transformData(formValues)
2160
2184
  );
2161
2185
  if ("data" in res && collectionType !== SINGLE_TYPES) {
2162
2186
  navigate({
@@ -2272,7 +2296,7 @@ const UpdateAction = ({
2272
2296
  documentId: cloneMatch.params.origin,
2273
2297
  params
2274
2298
  },
2275
- document
2299
+ transformData(document)
2276
2300
  );
2277
2301
  if ("data" in res) {
2278
2302
  navigate(
@@ -2293,7 +2317,7 @@ const UpdateAction = ({
2293
2317
  documentId,
2294
2318
  params
2295
2319
  },
2296
- document
2320
+ transformData(document)
2297
2321
  );
2298
2322
  if ("error" in res && isBaseQueryError(res.error) && res.error.name === "ValidationError") {
2299
2323
  setErrors(formatValidationErrors(res.error));
@@ -2306,7 +2330,7 @@ const UpdateAction = ({
2306
2330
  model,
2307
2331
  params
2308
2332
  },
2309
- document
2333
+ transformData(document)
2310
2334
  );
2311
2335
  if ("data" in res && collectionType !== SINGLE_TYPES) {
2312
2336
  navigate(
@@ -2994,7 +3018,7 @@ const Panel = React.forwardRef(({ children, title }, ref) => {
2994
3018
  justifyContent: "stretch",
2995
3019
  alignItems: "flex-start",
2996
3020
  children: [
2997
- /* @__PURE__ */ jsx(Typography, { tag: "h2", variant: "sigma", textTransform: "uppercase", children: title }),
3021
+ /* @__PURE__ */ jsx(Typography, { tag: "h2", variant: "sigma", textTransform: "uppercase", textColor: "neutral600", children: title }),
2998
3022
  children
2999
3023
  ]
3000
3024
  }
@@ -3977,6 +4001,82 @@ const { setInitialData } = actions;
3977
4001
  const reducer = combineReducers({
3978
4002
  app: reducer$1
3979
4003
  });
4004
+ const previewApi = contentManagerApi.injectEndpoints({
4005
+ endpoints: (builder) => ({
4006
+ getPreviewUrl: builder.query({
4007
+ query({ query, params }) {
4008
+ return {
4009
+ url: `/content-manager/preview/url/${params.contentType}`,
4010
+ method: "GET",
4011
+ config: {
4012
+ params: query
4013
+ }
4014
+ };
4015
+ }
4016
+ })
4017
+ })
4018
+ });
4019
+ const { useGetPreviewUrlQuery } = previewApi;
4020
+ const PreviewSidePanel = ({ model, documentId, document }) => {
4021
+ const { formatMessage } = useIntl();
4022
+ const { toggleNotification } = useNotification();
4023
+ const { copy } = useClipboard();
4024
+ const { data, error } = useGetPreviewUrlQuery({
4025
+ params: {
4026
+ contentType: model
4027
+ },
4028
+ query: {
4029
+ documentId,
4030
+ locale: document?.locale,
4031
+ status: document?.status
4032
+ }
4033
+ });
4034
+ if (!data?.data?.url || error) {
4035
+ return null;
4036
+ }
4037
+ const { url } = data.data;
4038
+ const handleCopyLink = () => {
4039
+ copy(url);
4040
+ toggleNotification({
4041
+ message: formatMessage({
4042
+ id: "content-manager.preview.copy.success",
4043
+ defaultMessage: "Copied preview link"
4044
+ }),
4045
+ type: "success"
4046
+ });
4047
+ };
4048
+ return {
4049
+ title: formatMessage({ id: "content-manager.preview.panel.title", defaultMessage: "Preview" }),
4050
+ content: /* @__PURE__ */ jsxs(Flex, { gap: 2, width: "100%", children: [
4051
+ /* @__PURE__ */ jsx(Button, { variant: "tertiary", tag: Link, to: url, target: "_blank", flex: "auto", children: formatMessage({
4052
+ id: "content-manager.preview.panel.button",
4053
+ defaultMessage: "Open preview"
4054
+ }) }),
4055
+ /* @__PURE__ */ jsx(
4056
+ IconButton,
4057
+ {
4058
+ type: "button",
4059
+ label: formatMessage({
4060
+ id: "preview.copy.label",
4061
+ defaultMessage: "Copy preview link"
4062
+ }),
4063
+ onClick: handleCopyLink,
4064
+ children: /* @__PURE__ */ jsx(Link$1, {})
4065
+ }
4066
+ )
4067
+ ] })
4068
+ };
4069
+ };
4070
+ const FEATURE_ID = "preview";
4071
+ const previewAdmin = {
4072
+ bootstrap(app) {
4073
+ if (!window.strapi.future.isEnabled(FEATURE_ID)) {
4074
+ return;
4075
+ }
4076
+ const contentManagerPluginApis = app.getPlugin("content-manager").apis;
4077
+ contentManagerPluginApis.addEditViewSidePanel([PreviewSidePanel]);
4078
+ }
4079
+ };
3980
4080
  const index = {
3981
4081
  register(app) {
3982
4082
  const cm = new ContentManagerPlugin();
@@ -3996,7 +4096,7 @@ const index = {
3996
4096
  app.router.addRoute({
3997
4097
  path: "content-manager/*",
3998
4098
  lazy: async () => {
3999
- const { Layout } = await import("./layout-N63eyE5E.mjs");
4099
+ const { Layout } = await import("./layout-CrTxOnCy.mjs");
4000
4100
  return {
4001
4101
  Component: Layout
4002
4102
  };
@@ -4009,11 +4109,14 @@ const index = {
4009
4109
  if (typeof historyAdmin.bootstrap === "function") {
4010
4110
  historyAdmin.bootstrap(app);
4011
4111
  }
4112
+ if (typeof previewAdmin.bootstrap === "function") {
4113
+ previewAdmin.bootstrap(app);
4114
+ }
4012
4115
  },
4013
4116
  async registerTrads({ locales }) {
4014
4117
  const importedTrads = await Promise.all(
4015
4118
  locales.map((locale) => {
4016
- return __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "./translations/ar.json": () => import("./ar-CCEVvqGG.mjs"), "./translations/ca.json": () => import("./ca-5U32ON2v.mjs"), "./translations/cs.json": () => import("./cs-CM2aBUar.mjs"), "./translations/de.json": () => import("./de-C72KDNOl.mjs"), "./translations/en.json": () => import("./en-DKV44jRb.mjs"), "./translations/es.json": () => import("./es-CeXiYflN.mjs"), "./translations/eu.json": () => import("./eu-CdALomew.mjs"), "./translations/fr.json": () => import("./fr-CD9VFbPM.mjs"), "./translations/gu.json": () => import("./gu-CNpaMDpH.mjs"), "./translations/hi.json": () => import("./hi-Dwvd04m3.mjs"), "./translations/hu.json": () => import("./hu-CeYvaaO0.mjs"), "./translations/id.json": () => import("./id-BtwA9WJT.mjs"), "./translations/it.json": () => import("./it-BrVPqaf1.mjs"), "./translations/ja.json": () => import("./ja-CtsUxOvk.mjs"), "./translations/ko.json": () => import("./ko-HVQRlfUI.mjs"), "./translations/ml.json": () => import("./ml-BihZwQit.mjs"), "./translations/ms.json": () => import("./ms-m_WjyWx7.mjs"), "./translations/nl.json": () => import("./nl-D4R9gHx5.mjs"), "./translations/pl.json": () => import("./pl-sbx9mSt_.mjs"), "./translations/pt-BR.json": () => import("./pt-BR-C71iDxnh.mjs"), "./translations/pt.json": () => import("./pt-BsaFvS8-.mjs"), "./translations/ru.json": () => import("./ru-BE6A4Exp.mjs"), "./translations/sa.json": () => import("./sa-Dag0k-Z8.mjs"), "./translations/sk.json": () => import("./sk-BFg-R8qJ.mjs"), "./translations/sv.json": () => import("./sv-CUnfWGsh.mjs"), "./translations/th.json": () => import("./th-BqbI8lIT.mjs"), "./translations/tr.json": () => import("./tr-CgeK3wJM.mjs"), "./translations/uk.json": () => import("./uk-CR-zDhAY.mjs"), "./translations/vi.json": () => import("./vi-DUXIk_fw.mjs"), "./translations/zh-Hans.json": () => import("./zh-Hans-BPQcRIyH.mjs"), "./translations/zh.json": () => import("./zh-BWZspA60.mjs") }), `./translations/${locale}.json`).then(({ default: data }) => {
4119
+ return __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "./translations/ar.json": () => import("./ar-CCEVvqGG.mjs"), "./translations/ca.json": () => import("./ca-5U32ON2v.mjs"), "./translations/cs.json": () => import("./cs-CM2aBUar.mjs"), "./translations/de.json": () => import("./de-C72KDNOl.mjs"), "./translations/en.json": () => import("./en-CZw4xdPY.mjs"), "./translations/es.json": () => import("./es-D34tqjMw.mjs"), "./translations/eu.json": () => import("./eu-CdALomew.mjs"), "./translations/fr.json": () => import("./fr--pg5jUbt.mjs"), "./translations/gu.json": () => import("./gu-CNpaMDpH.mjs"), "./translations/hi.json": () => import("./hi-Dwvd04m3.mjs"), "./translations/hu.json": () => import("./hu-CeYvaaO0.mjs"), "./translations/id.json": () => import("./id-BtwA9WJT.mjs"), "./translations/it.json": () => import("./it-BrVPqaf1.mjs"), "./translations/ja.json": () => import("./ja-BHqhDq4V.mjs"), "./translations/ko.json": () => import("./ko-HVQRlfUI.mjs"), "./translations/ml.json": () => import("./ml-BihZwQit.mjs"), "./translations/ms.json": () => import("./ms-m_WjyWx7.mjs"), "./translations/nl.json": () => import("./nl-D4R9gHx5.mjs"), "./translations/pl.json": () => import("./pl-sbx9mSt_.mjs"), "./translations/pt-BR.json": () => import("./pt-BR-C71iDxnh.mjs"), "./translations/pt.json": () => import("./pt-BsaFvS8-.mjs"), "./translations/ru.json": () => import("./ru-BE6A4Exp.mjs"), "./translations/sa.json": () => import("./sa-Dag0k-Z8.mjs"), "./translations/sk.json": () => import("./sk-BFg-R8qJ.mjs"), "./translations/sv.json": () => import("./sv-CUnfWGsh.mjs"), "./translations/th.json": () => import("./th-BqbI8lIT.mjs"), "./translations/tr.json": () => import("./tr-CgeK3wJM.mjs"), "./translations/uk.json": () => import("./uk-CR-zDhAY.mjs"), "./translations/vi.json": () => import("./vi-DUXIk_fw.mjs"), "./translations/zh-Hans.json": () => import("./zh-Hans-BPQcRIyH.mjs"), "./translations/zh.json": () => import("./zh-BWZspA60.mjs") }), `./translations/${locale}.json`).then(({ default: data }) => {
4017
4120
  return {
4018
4121
  data: prefixPluginTranslations(data, PLUGIN_ID),
4019
4122
  locale
@@ -4074,4 +4177,4 @@ export {
4074
4177
  capitalise as y,
4075
4178
  useUpdateContentTypeConfigurationMutation as z
4076
4179
  };
4077
- //# sourceMappingURL=index-BQ8DxaCa.mjs.map
4180
+ //# sourceMappingURL=index-3_WeHXYp.mjs.map