diff --git a/src/prefabs/pageWithErrors.tsx b/src/prefabs/pageWithErrors.tsx index 26479a2a3..65bdf0d79 100644 --- a/src/prefabs/pageWithErrors.tsx +++ b/src/prefabs/pageWithErrors.tsx @@ -314,6 +314,14 @@ const beforeCreate = ({ value: ['0rem', '0rem', 'M', '0rem'], }), ); + setOption( + backgroundBox, + 'backgroundType', + (opt: PrefabComponentOption) => ({ + ...opt, + value: 'url', + }), + ); setOption( backgroundBox, 'backgroundUrl', diff --git a/src/prefabs/pageWithHomepageLayout.tsx b/src/prefabs/pageWithHomepageLayout.tsx index 068cff2d1..7498351bb 100644 --- a/src/prefabs/pageWithHomepageLayout.tsx +++ b/src/prefabs/pageWithHomepageLayout.tsx @@ -659,6 +659,18 @@ export default makePrefab('Homepage, inspirational', attrs, beforeCreate, [ 'https://assets.bettyblocks.com/63b1c6ccc6874e0796e5cc5b7e41b3da_assets/files/Homepage_banner_gradient', ], }), + backgroundType: option('CUSTOM', { + label: 'Background type', + value: 'url', + configuration: { + as: 'BUTTONGROUP', + dataType: 'string', + allowedInput: [ + { name: 'Image', value: 'img' }, + { name: 'Data/URL', value: 'url' }, + ], + }, + }), }, }, [ diff --git a/src/prefabs/pageWithLoginAndRegisterForm.tsx b/src/prefabs/pageWithLoginAndRegisterForm.tsx index 89d29e258..ff2f9f6f5 100644 --- a/src/prefabs/pageWithLoginAndRegisterForm.tsx +++ b/src/prefabs/pageWithLoginAndRegisterForm.tsx @@ -976,6 +976,18 @@ export default makePrefab( }, }, ), + backgroundType: option('CUSTOM', { + label: 'Background type', + value: 'url', + configuration: { + as: 'BUTTONGROUP', + dataType: 'string', + allowedInput: [ + { name: 'Image', value: 'img' }, + { name: 'Data/URL', value: 'url' }, + ], + }, + }), backgroundUrl: variable('Background url', { value: [ 'https://assets.bettyblocks.com/7730f33d3a624ec6b5383b5dc26c79d6_assets/files/login-background.jpeg', diff --git a/src/prefabs/pageWithLoginForm.tsx b/src/prefabs/pageWithLoginForm.tsx index 9b0a5b984..1661e16e3 100644 --- a/src/prefabs/pageWithLoginForm.tsx +++ b/src/prefabs/pageWithLoginForm.tsx @@ -294,6 +294,18 @@ const prefabStructure: PrefabComponent[] = [ backgroundOptions: toggle('Show background options', { value: true, }), + backgroundType: option('CUSTOM', { + label: 'Background type', + value: 'url', + configuration: { + as: 'BUTTONGROUP', + dataType: 'string', + allowedInput: [ + { name: 'Image', value: 'img' }, + { name: 'Data/URL', value: 'url' }, + ], + }, + }), backgroundUrl: variable('Background url', { value: [ 'https://assets.bettyblocks.com/1e9019bb1c5c4af2ba799c2ee1761af0_assets/files/login-background', diff --git a/src/prefabs/pageWithRegisterForm.tsx b/src/prefabs/pageWithRegisterForm.tsx index 03f9afc84..3b319143c 100644 --- a/src/prefabs/pageWithRegisterForm.tsx +++ b/src/prefabs/pageWithRegisterForm.tsx @@ -662,6 +662,18 @@ export default makePrefab('User, account register only', attrs, beforeCreate, [ as: 'UNIT', }, }), + backgroundType: option('CUSTOM', { + label: 'Background type', + value: 'url', + configuration: { + as: 'BUTTONGROUP', + dataType: 'string', + allowedInput: [ + { name: 'Image', value: 'img' }, + { name: 'Data/URL', value: 'url' }, + ], + }, + }), backgroundOptions: toggle('Show background options', { value: true, }),