@strapi/content-manager 0.0.0-experimental.c3e9d4b26f9fd3d9eb530b5c11f9baa1d09b13ad → 0.0.0-experimental.d53e940834bf72ddc725f1d2fd36dac9abec30cb
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.
- package/dist/_chunks/{ComponentConfigurationPage-y_7iLdmB.js → ComponentConfigurationPage-C-49MccQ.js} +3 -3
- package/dist/_chunks/{ComponentConfigurationPage-y_7iLdmB.js.map → ComponentConfigurationPage-C-49MccQ.js.map} +1 -1
- package/dist/_chunks/{ComponentConfigurationPage-BMajAl1u.mjs → ComponentConfigurationPage-DmwmiFQy.mjs} +3 -3
- package/dist/_chunks/{ComponentConfigurationPage-BMajAl1u.mjs.map → ComponentConfigurationPage-DmwmiFQy.mjs.map} +1 -1
- package/dist/_chunks/{EditConfigurationPage-CPVB8Uqc.js → EditConfigurationPage-DjFJw56M.js} +3 -3
- package/dist/_chunks/{EditConfigurationPage-CPVB8Uqc.js.map → EditConfigurationPage-DjFJw56M.js.map} +1 -1
- package/dist/_chunks/{EditConfigurationPage-CcOoD26O.mjs → EditConfigurationPage-JT3E7NZy.mjs} +3 -3
- package/dist/_chunks/{EditConfigurationPage-CcOoD26O.mjs.map → EditConfigurationPage-JT3E7NZy.mjs.map} +1 -1
- package/dist/_chunks/{EditViewPage-DWb0DE7R.mjs → EditViewPage-CPj61RMh.mjs} +46 -46
- package/dist/_chunks/EditViewPage-CPj61RMh.mjs.map +1 -0
- package/dist/_chunks/{EditViewPage-CTTDHKkQ.js → EditViewPage-zT3fBr4Y.js} +45 -45
- package/dist/_chunks/EditViewPage-zT3fBr4Y.js.map +1 -0
- package/dist/_chunks/{Field-C5Z1Ivdv.js → Field-Boxf9Ajp.js} +372 -117
- package/dist/_chunks/Field-Boxf9Ajp.js.map +1 -0
- package/dist/_chunks/{Field-DnStdvQw.mjs → Field-dha5VnIQ.mjs} +373 -118
- package/dist/_chunks/Field-dha5VnIQ.mjs.map +1 -0
- package/dist/_chunks/{Form-DqGgE55Q.mjs → Form-DHrru2AV.mjs} +27 -28
- package/dist/_chunks/Form-DHrru2AV.mjs.map +1 -0
- package/dist/_chunks/{Form-B81OtW-k.js → Form-y5g1SRsh.js} +25 -26
- package/dist/_chunks/Form-y5g1SRsh.js.map +1 -0
- package/dist/_chunks/{History-DS6-HCYX.mjs → History-Bru_KoeP.mjs} +12 -14
- package/dist/_chunks/History-Bru_KoeP.mjs.map +1 -0
- package/dist/_chunks/{History-4NbOq2dX.js → History-CqN6K7SX.js} +11 -13
- package/dist/_chunks/History-CqN6K7SX.js.map +1 -0
- package/dist/_chunks/{ListConfigurationPage-DQJJltko.mjs → ListConfigurationPage-D8wGABj0.mjs} +43 -45
- package/dist/_chunks/ListConfigurationPage-D8wGABj0.mjs.map +1 -0
- package/dist/_chunks/{ListConfigurationPage-CpfstlYY.js → ListConfigurationPage-R_p-SbHZ.js} +42 -43
- package/dist/_chunks/ListConfigurationPage-R_p-SbHZ.js.map +1 -0
- package/dist/_chunks/{ListViewPage-nQrOQuVo.mjs → ListViewPage-SID6TRb9.mjs} +48 -65
- package/dist/_chunks/ListViewPage-SID6TRb9.mjs.map +1 -0
- package/dist/_chunks/{ListViewPage-CA3I75m5.js → ListViewPage-pEw_zug9.js} +47 -64
- package/dist/_chunks/ListViewPage-pEw_zug9.js.map +1 -0
- package/dist/_chunks/{NoContentTypePage-Dldu-_Mx.js → NoContentTypePage-C5dcQojD.js} +2 -2
- package/dist/_chunks/{NoContentTypePage-Dldu-_Mx.js.map → NoContentTypePage-C5dcQojD.js.map} +1 -1
- package/dist/_chunks/{NoContentTypePage-DbnHE22g.mjs → NoContentTypePage-CJ7UXwrQ.mjs} +2 -2
- package/dist/_chunks/{NoContentTypePage-DbnHE22g.mjs.map → NoContentTypePage-CJ7UXwrQ.mjs.map} +1 -1
- package/dist/_chunks/{NoPermissionsPage-fOIkQM0v.mjs → NoPermissionsPage-B7syEq5E.mjs} +2 -2
- package/dist/_chunks/{NoPermissionsPage-fOIkQM0v.mjs.map → NoPermissionsPage-B7syEq5E.mjs.map} +1 -1
- package/dist/_chunks/{NoPermissionsPage-CO2MK200.js → NoPermissionsPage-BtPrImPP.js} +2 -2
- package/dist/_chunks/{NoPermissionsPage-CO2MK200.js.map → NoPermissionsPage-BtPrImPP.js.map} +1 -1
- package/dist/_chunks/{Relations-BDRl99Ux.mjs → Relations-B9Crnhnn.mjs} +3 -3
- package/dist/_chunks/{Relations-BDRl99Ux.mjs.map → Relations-B9Crnhnn.mjs.map} +1 -1
- package/dist/_chunks/{Relations-DG2jnOcr.js → Relations-DjTQ5kGB.js} +3 -3
- package/dist/_chunks/{Relations-DG2jnOcr.js.map → Relations-DjTQ5kGB.js.map} +1 -1
- package/dist/_chunks/{index-Drt2DN7v.mjs → index-DJXJw9V5.mjs} +122 -279
- package/dist/_chunks/index-DJXJw9V5.mjs.map +1 -0
- package/dist/_chunks/{index-BZoNZMXL.js → index-DVPWZkbS.js} +109 -266
- package/dist/_chunks/index-DVPWZkbS.js.map +1 -0
- package/dist/_chunks/{layout-BzAbmoO6.mjs → layout-Bau7ZfLV.mjs} +5 -5
- package/dist/_chunks/{layout-BzAbmoO6.mjs.map → layout-Bau7ZfLV.mjs.map} +1 -1
- package/dist/_chunks/{layout-DEYBqgF1.js → layout-Dm6fbiQj.js} +4 -4
- package/dist/_chunks/{layout-DEYBqgF1.js.map → layout-Dm6fbiQj.js.map} +1 -1
- package/dist/_chunks/{relations-D26zVRdi.mjs → relations-BH_kBSJ0.mjs} +2 -2
- package/dist/_chunks/{relations-D26zVRdi.mjs.map → relations-BH_kBSJ0.mjs.map} +1 -1
- package/dist/_chunks/{relations-D0eZ4VWw.js → relations-CKnpRgrN.js} +2 -2
- package/dist/_chunks/{relations-D0eZ4VWw.js.map → relations-CKnpRgrN.js.map} +1 -1
- package/dist/admin/index.js +1 -1
- package/dist/admin/index.mjs +4 -4
- package/dist/admin/src/pages/EditView/components/DocumentActions.d.ts +7 -3
- package/dist/admin/src/pages/EditView/components/FormInputs/BlocksInput/utils/constants.d.ts +4 -0
- package/dist/admin/src/pages/EditView/components/FormInputs/Wysiwyg/WysiwygStyles.d.ts +2 -10
- package/dist/admin/src/pages/ListView/components/BulkActions/Actions.d.ts +3 -30
- package/dist/admin/src/pages/ListView/components/BulkActions/ConfirmBulkActionDialog.d.ts +2 -2
- package/dist/server/index.js +5 -4
- package/dist/server/index.js.map +1 -1
- package/dist/server/index.mjs +5 -4
- package/dist/server/index.mjs.map +1 -1
- package/dist/server/src/history/services/lifecycles.d.ts.map +1 -1
- package/package.json +8 -8
- package/dist/_chunks/EditViewPage-CTTDHKkQ.js.map +0 -1
- package/dist/_chunks/EditViewPage-DWb0DE7R.mjs.map +0 -1
- package/dist/_chunks/Field-C5Z1Ivdv.js.map +0 -1
- package/dist/_chunks/Field-DnStdvQw.mjs.map +0 -1
- package/dist/_chunks/Form-B81OtW-k.js.map +0 -1
- package/dist/_chunks/Form-DqGgE55Q.mjs.map +0 -1
- package/dist/_chunks/History-4NbOq2dX.js.map +0 -1
- package/dist/_chunks/History-DS6-HCYX.mjs.map +0 -1
- package/dist/_chunks/ListConfigurationPage-CpfstlYY.js.map +0 -1
- package/dist/_chunks/ListConfigurationPage-DQJJltko.mjs.map +0 -1
- package/dist/_chunks/ListViewPage-CA3I75m5.js.map +0 -1
- package/dist/_chunks/ListViewPage-nQrOQuVo.mjs.map +0 -1
- package/dist/_chunks/index-BZoNZMXL.js.map +0 -1
- package/dist/_chunks/index-Drt2DN7v.mjs.map +0 -1
package/dist/server/index.mjs
CHANGED
@@ -469,8 +469,6 @@ const createLifecyclesService = ({ strapi: strapi2 }) => {
|
|
469
469
|
deleteExpiredJob: null,
|
470
470
|
isInitialized: false
|
471
471
|
};
|
472
|
-
const query = strapi2.db.query(HISTORY_VERSION_UID);
|
473
|
-
const historyService = getService(strapi2, "history");
|
474
472
|
const serviceUtils = createServiceUtils({ strapi: strapi2 });
|
475
473
|
return {
|
476
474
|
async bootstrap() {
|
@@ -484,6 +482,9 @@ const createLifecyclesService = ({ strapi: strapi2 }) => {
|
|
484
482
|
if (context.action !== "create" && context.action !== "update" && context.action !== "clone" && context.action !== "publish" && context.action !== "unpublish" && context.action !== "discardDraft") {
|
485
483
|
return next();
|
486
484
|
}
|
485
|
+
if (context.action === "update" && strapi2.requestContext.get()?.request.url.endsWith("/actions/publish")) {
|
486
|
+
return next();
|
487
|
+
}
|
487
488
|
const contentTypeUid = context.contentType.uid;
|
488
489
|
if (!contentTypeUid.startsWith("api::")) {
|
489
490
|
return next();
|
@@ -523,7 +524,7 @@ const createLifecyclesService = ({ strapi: strapi2 }) => {
|
|
523
524
|
}, {});
|
524
525
|
await strapi2.db.transaction(async ({ onCommit }) => {
|
525
526
|
onCommit(() => {
|
526
|
-
|
527
|
+
getService(strapi2, "history").createVersion({
|
527
528
|
contentType: contentTypeUid,
|
528
529
|
data: omit(FIELDS_TO_IGNORE, document),
|
529
530
|
schema: omit(FIELDS_TO_IGNORE, attributesSchema),
|
@@ -539,7 +540,7 @@ const createLifecyclesService = ({ strapi: strapi2 }) => {
|
|
539
540
|
state.deleteExpiredJob = scheduleJob("0 0 * * *", () => {
|
540
541
|
const retentionDaysInMilliseconds = serviceUtils.getRetentionDays() * 24 * 60 * 60 * 1e3;
|
541
542
|
const expirationDate = new Date(Date.now() - retentionDaysInMilliseconds);
|
542
|
-
query.deleteMany({
|
543
|
+
strapi2.db.query(HISTORY_VERSION_UID).deleteMany({
|
543
544
|
where: {
|
544
545
|
created_at: {
|
545
546
|
$lt: expirationDate.toISOString()
|