Skip to content

Commit

Permalink
add more options for content
Browse files Browse the repository at this point in the history
  • Loading branch information
Petter Andersson committed Mar 11, 2024
1 parent d275a96 commit 9091c60
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/content/content.gql.schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@ export const contentGqlSchema = /* GraphQL */ `
input ContentModuleInput {
title: String
body: String
border: String
image: String
position: String
width: String
imageRef: String
categories: String
tags: String
Expand All @@ -42,7 +45,10 @@ export const contentGqlSchema = /* GraphQL */ `
type ContentModule {
title: String
body: String
border: String
image: String
position: String
width: String
imageRef: String
categories: String
tags: String
Expand Down
3 changes: 3 additions & 0 deletions src/content/content.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ it('should normalize invalid composition', () => {
module: {
title: '',
body: '',
border: 'true',
image: '',
width: '100%',
position: 'top',
imageRef: '',
categories: '',
tags: '',
Expand Down
3 changes: 3 additions & 0 deletions src/content/mappers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@ import type { ContentModule, ViewComposition } from './types'
export const createEmptyModule = (): ContentModule => ({
title: '',
body: '',
border: 'true',
image: '',
position: 'top',
width: '100%',
categories: '',
tags: '',
imageRef: '',
Expand Down
3 changes: 3 additions & 0 deletions src/content/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,10 @@ export interface ViewColumn {
export type ContentModule = {
title: string
body: string
border: 'true' | 'false'
image: string
position: 'top' | 'bottom' | 'left' | 'right'
width: string
imageRef: string
categories: string
tags: string
Expand Down

0 comments on commit 9091c60

Please sign in to comment.