# Boxes on a page key. Public reads, admin writes; adminOnly boxes go to # admins only. kind is "widget" or "html" (sandboxed iframe). type Box { id: ID! createdAt: Time! updatedAt: Time! page: String! kind: String! widget: String html: String title: String x: Int! y: Int! w: Int! h: Int! z: Int! framed: Boolean! # A CSS box-shadow value, or "" for none. shadow: String! hideOnMobile: Boolean! adminOnly: Boolean! componentId: ID } input CreateBoxInput { page: String! kind: String! widget: String html: String title: String x: Int y: Int w: Int h: Int z: Int framed: Boolean shadow: String hideOnMobile: Boolean adminOnly: Boolean # Links the new box to this component; kind is then "html" and html is # ignored. componentId: ID } input UpdateBoxInput { widget: String html: String title: String x: Int y: Int w: Int h: Int z: Int framed: Boolean shadow: String hideOnMobile: Boolean adminOnly: Boolean } extend type Query { boxes(page: String!): [Box!]! } extend type Mutation { createBox(input: CreateBoxInput!): Box! @admin updateBox(id: ID!, input: UpdateBoxInput!): Box! @admin deleteBox(id: ID!): Box! @admin }