Blocks

The content of an Ediit Resource is brought to life through Blocks.

Basic Blocks

Heading

A text heading ranging from 1 (largest, primary heading) to 6 (smallest heading).

Type

The block type is "heading".

Data

Key

Value

Description

text

String

Text to display

level

Integer (1 to 6)

Level of heading from 1 to 6 (e.g. h1, h2, ... h6)

textAlign

String ('left', 'right', 'center', 'justify')

Horizontal alignment of the text (default: 'left')

{
    "type": "heading",
    "data": {
        "text": "All About Sharks",
        "level": 1,
        "textAlign": "center"
    }
}

Paragraph

A paragraph of text.

Type

The block type is "paragraph".

Data

Key

Value

Description

text

String

Text to display

textAlign

String ('left', 'right', 'center', 'justify')

Horizontal alignment of the text (default: 'left')

List

An ordered or unordered list of text.

Type

The block type is "list".

Data

Key

Value

Description

style

String ('ordered', 'unordered')

Ordered or unordered list

items

Array of Strings

Items to display in the list

Table

A table with rows and columns that can house blocks.

Type

The block type is "table".

Data

Key

Value

Description

tableRows

Array

An array of the table's rows.

tableCells

Array

An array of the table's cells.

blocks

Array

An array of Blocks (note: Table Blocks can't be nested within Table Blocks)

Image

An image.

Type

The block type is "image".

Data

Key

Value

Description

url

String

URL location of the image file

alt

String

Alternative text for screen readers and in the event the image doesn't load

caption

String

Caption text to display beneath the image

textAlign

String ('left', 'right', 'center', 'justify')

Horizontal alignment of the caption text (default: 'left')

width

Integer (0 to 100)

Percentage width of the image.

Spacer

A spacer to add a vertical gap (whitespace) to a column.

Type

The block type is "spacer".

Data

Key

Value

Description

height

Integer

Height of the spacer; multiplies the theme's default spacing.

A URL link.

Type

The block type is "link".

Data

Key

Value

Description

text

String

Text to display

url

String

URL link

oEmbed

A URL link.

Type

The block type is "oembed".

Data

Key

Value

Description

url

String

oEmbed URL

Advanced Blocks

Question

Question blocks allow for a student's response.

Type

The block type is "question".

Data

Key

Value

Description

questionType

String

question

String

Question text for the student to read

explanation

String

Explanation of the correct answer

hint

String

Hint to assist in answering the question correctly

points

Integer

Number of points awarded to the student for answering correctly

required

Boolean

Is the student required to answer this question to progress?

tags

Array of Strings

Used to group questions when analysing results. e.g. learning area tags

showQuestionNumber

Boolean

Display a question number beside the question text

Question Types

Last updated

Was this helpful?