Skip to content

Commit

Permalink
Define CustomField
Browse files Browse the repository at this point in the history
  • Loading branch information
Fweddi committed Dec 16, 2024
1 parent 3ae09bf commit 44d3766
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions thrift/src/main/thrift/atoms/interactive.thrift
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,25 @@ namespace java com.gu.contentatom.thrift.atom.interactive
#@namespace scala com.gu.contentatom.thrift.atom.interactive
#@namespace typescript _at_guardian.content_atom_model.interactive

union AnyValue {
1: bool bool
2: byte byte
3: i16 i16
4: i32 i32
5: i64 i64
6: double double
7: string string
8: list<AnyValue> list
9: set<AnyValue> set
10: map<string, AnyValue> map
}

struct CustomField {
1: required string fieldName
2: required string fieldType
3: required AnyValue defaultValue
}

struct InteractiveAtom {
/* the unique ID will be stored in the `atom` data*/
1: required string type
Expand All @@ -18,4 +37,5 @@ struct InteractiveAtom {
See here: https://amp.dev/documentation/components/amp-iframe/ for more information.
*/
7: optional string placeholderUrl
8: optional list<CustomField> customFields = []
}

0 comments on commit 44d3766

Please sign in to comment.