node_modules ignore

This commit is contained in:
2025-05-08 23:43:47 +02:00
parent e19d52f172
commit 4574544c9f
65041 changed files with 10593536 additions and 0 deletions

View File

@@ -0,0 +1,40 @@
'use strict';
const extendCTBInitialDataMiddleware = ()=>{
return ()=>(next)=>(action)=>{
if (action.type === 'ContentTypeBuilder/FormModal/SET_DATA_TO_EDIT' && action.modalType === 'contentType') {
const i18n = {
localized: false
};
const pluginOptions = action.data.pluginOptions ? {
...action.data.pluginOptions,
i18n
} : {
i18n
};
const data = {
...action.data,
pluginOptions
};
if (action.actionType === 'create') {
return next({
...action,
data
});
}
// Override the action if the pluginOption config does not contain i18n
// In this case we need to set the proper initialData shape
if (!action.data.pluginOptions?.i18n?.localized) {
return next({
...action,
data
});
}
}
// action is not the one we want to override
return next(action);
};
};
exports.extendCTBInitialDataMiddleware = extendCTBInitialDataMiddleware;
//# sourceMappingURL=extendCTBInitialData.js.map