Skip to content

Commit

Permalink
feat: add terrasos book a call document (#74)
Browse files Browse the repository at this point in the history
* feat: add terrasos book a call document

* chore: lint
  • Loading branch information
blushi authored Dec 3, 2024
1 parent c07936e commit 1dabe04
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 6 deletions.
4 changes: 4 additions & 0 deletions deskStructure.js
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,10 @@ export default S =>
.title('Compliance Info')
.schemaType('complianceInfo')
.child(S.document().schemaType('complianceInfo')),
S.listItem()
.title('Book a Call')
.schemaType('terrasosBookCall')
.child(S.document().schemaType('terrasosBookCall')),
]),
),
]);
6 changes: 0 additions & 6 deletions schemas/documents/terrasos/complianceInfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,5 @@ export default {
type: 'customPortableText',
validation: Rule => Rule.required(),
},
{
title: 'Book a call link',
name: 'bookCallLink',
type: 'linkItem',
validation: Rule => Rule.required(),
},
],
};
12 changes: 12 additions & 0 deletions schemas/documents/terrasos/terrasosBookCall.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
export default {
name: 'terrasosBookCall',
type: 'document',
title: 'Book a call',
fields: [{
title: 'Button',
name: 'button',
description: 'Used on project page (both bottom banner and compliance info tab)',
type: 'button',
validation: Rule => Rule.required(),
}],
};
2 changes: 2 additions & 0 deletions schemas/schema.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ import creditCategory from './documents/shared/creditCategory';
import tebuBanner from './documents/terrasos/tebuBanner';
import terrasosProject from './documents/terrasos/terrasosProject';
import complianceInfo from './documents/terrasos/complianceInfo';
import terrasosBookCall from './documents/terrasos/terrasosBookCall';
export const documentsSchemas = [
homePage,
homePageWeb,
Expand Down Expand Up @@ -134,6 +135,7 @@ export const documentsSchemas = [
tebuBanner,
terrasosProject,
complianceInfo,
terrasosBookCall,
];

// Object types
Expand Down
1 change: 1 addition & 0 deletions uniqueDocuments.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,5 @@ export const uniqueDocuments = [
'createProjectPage',
'complianceInfo',
'tebuBanner',
'terrasosBookCall',
];

0 comments on commit 1dabe04

Please sign in to comment.