Class: exports

exports

A class representing an interlinear glossed utterance


new exports(utterance [, options])

Create a new interlinear gloss view

Parameters:
Name Type Argument Default Description
utterance Utterance

The Utterance data to use for this view

options Object <optional>
{}

An options hash

Properties
Name Type Argument Default Description
editTags Boolean <optional>
false

Whether word-level tags should be rendered as editable (with a delete button)

language String <optional>

The language of this interlinear example. Including this value is strongly recommended.

tag String <optional>
`DIV`

The HTML tag that the interlinear gloss should be wrapped in. Defaults to a <div>.

tags Boolean <optional>
false

Whether to render tags along with the interlinear gloss

Extends

  • View

Members


clickToTag :Object|null

The current tag to use for click-to-tag mode. Should be set to null when click-to-tag mode is off.

Type:
  • Object | null

list :HTMLULElement

A reference to the <ul> contained within this view

Type:
  • HTMLULElement

tagMode :String

The current tagging mode for the Tagger. Should always be set to "type-to-tag" or "click-to-tag".

Type:
  • String

templatePath :String

The path to the HTML template for the Tags list

Type:
  • String

templatePath :String

Path to the Texts List HTML template relative to index.html

Type:
  • String

texts :Array.<models#Text>

The texts inclued in this view

Type:
  • Array.<models#Text>

Class: exports

exports

A class representing a MultiLangString view


new exports(data [, options])

Create a new MultiLangStringView

Parameters:
Name Type Argument Default Description
data MultiLangString

The MultiLangString data to render. Must be a MultiLangString (Map) object.

options Object <optional>
{}

An options hash

Properties
Name Type Argument Default Description
classes Array.<String> <optional>
[]

An array of classes to add to the MultiLangString view

labels Boolean <optional>
true

Whether to include orthography labels in the rendered view

legend String <optional>
``

The text to use to label this string view

tag String <optional>
`P`

The HTML tag to wrap each string in. Defaults to <p>.

Extends

  • View

Members


clickToTag :Object|null

The current tag to use for click-to-tag mode. Should be set to null when click-to-tag mode is off.

Type:
  • Object | null

list :HTMLULElement

A reference to the <ul> contained within this view

Type:
  • HTMLULElement

tagMode :String

The current tagging mode for the Tagger. Should always be set to "type-to-tag" or "click-to-tag".

Type:
  • String

templatePath :String

The path to the HTML template for the Tags list

Type:
  • String

templatePath :String

Path to the Texts List HTML template relative to index.html

Type:
  • String

texts :Array.<models#Text>

The texts inclued in this view

Type:
  • Array.<models#Text>

Class: exports

exports

A class representing the Tags List


new exports(tagsUsed)

Create a new Tags List view

Parameters:
Name Type Description
tagsUsed Object

An object hash containing a list of tags used in this Text

Properties
Name Type Description
text Tags

A Tags object for text-level tags

utterance Tags

A Tags object for utterance-level tags

word Tags

A Tags object for word-level tags

morpheme Tags

A Tags object for morpheme-level tags

Extends

  • core#View

Members


clickToTag :Object|null

The current tag to use for click-to-tag mode. Should be set to null when click-to-tag mode is off.

Type:
  • Object | null

list :HTMLULElement

A reference to the <ul> contained within this view

Type:
  • HTMLULElement

tagMode :String

The current tagging mode for the Tagger. Should always be set to "type-to-tag" or "click-to-tag".

Type:
  • String

templatePath :String

The path to the HTML template for the Tags list

Type:
  • String

templatePath :String

Path to the Texts List HTML template relative to index.html

Type:
  • String

texts :Array.<models#Text>

The texts inclued in this view

Type:
  • Array.<models#Text>

Class: exports

exports

A class representing a Text Tagger


new exports(language, text)

Create a new Text Tagger

Parameters:
Name Type Description
language models#Language

The language of the text being rendered

text models#Text

The text to render

Extends

  • View

Members


clickToTag :Object|null

The current tag to use for click-to-tag mode. Should be set to null when click-to-tag mode is off.

Type:
  • Object | null

list :HTMLULElement

A reference to the <ul> contained within this view

Type:
  • HTMLULElement

tagMode :String

The current tagging mode for the Tagger. Should always be set to "type-to-tag" or "click-to-tag".

Type:
  • String

templatePath :String

The path to the HTML template for the Tags list

Type:
  • String

templatePath :String

Path to the Texts List HTML template relative to index.html

Type:
  • String

texts :Array.<models#Text>

The texts inclued in this view

Type:
  • Array.<models#Text>

Class: exports

exports

A class representing a list of texts, as a menu


new exports(languageCID, texts)

Create a new Texts List

Parameters:
Name Type Description
languageCID String

The client ID of the language for these texts

texts Array.<models#Text>

An array of texts to render in the list

Extends

  • View

Members


clickToTag :Object|null

The current tag to use for click-to-tag mode. Should be set to null when click-to-tag mode is off.

Type:
  • Object | null

list :HTMLULElement

A reference to the <ul> contained within this view

Type:
  • HTMLULElement

tagMode :String

The current tagging mode for the Tagger. Should always be set to "type-to-tag" or "click-to-tag".

Type:
  • String

templatePath :String

The path to the HTML template for the Tags list

Type:
  • String

templatePath :String

Path to the Texts List HTML template relative to index.html

Type:
  • String

texts :Array.<models#Text>

The texts inclued in this view

Type:
  • Array.<models#Text>

Class: exports

exports

A class representing a Transcription view


new exports(data [, options])

Create a new TranscriptionView

Parameters:
Name Type Argument Default Description
data Transcription

The Transcription data to render. Must be a Transcription (Map) object.

options Object <optional>
{}

An options hash

Properties
Name Type Argument Default Description
classes Array.<String> <optional>
[]

An array of classes to add to the Transcription view

labels Boolean <optional>
true

Whether to render <span> tags containing orthography labels in the view

language String <optional>

The language of this transcription, as a valid language tag: https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/lang.

legend String <optional>
``

The text to use to label this transcription view

tag String <optional>
`P`

The HTML tag to wrap each transcription in. Defaults to <p>.

Extends

  • View

Members


clickToTag :Object|null

The current tag to use for click-to-tag mode. Should be set to null when click-to-tag mode is off.

Type:
  • Object | null

list :HTMLULElement

A reference to the <ul> contained within this view

Type:
  • HTMLULElement

tagMode :String

The current tagging mode for the Tagger. Should always be set to "type-to-tag" or "click-to-tag".

Type:
  • String

templatePath :String

The path to the HTML template for the Tags list

Type:
  • String

templatePath :String

Path to the Texts List HTML template relative to index.html

Type:
  • String

texts :Array.<models#Text>

The texts inclued in this view

Type:
  • Array.<models#Text>

Class: exports

exports

A class representing a word token view


new exports(word, language [, options])

Create a new WordView

Parameters:
Name Type Argument Default Description
word Word

The word data to use for this view

language String

The language of this word token, as a valid language code

options Object <optional>
{}

An options hash

Properties
Name Type Argument Default Description
editTags Boolean <optional>
false

Whether the tags should be rendered as editable (with a delete button)

labels Boolean <optional>
false

Whether to display labels with the word

tags Boolean <optional>
false

Whether to display tags with the word

Extends

  • View

Members


clickToTag :Object|null

The current tag to use for click-to-tag mode. Should be set to null when click-to-tag mode is off.

Type:
  • Object | null

list :HTMLULElement

A reference to the <ul> contained within this view

Type:
  • HTMLULElement

tagMode :String

The current tagging mode for the Tagger. Should always be set to "type-to-tag" or "click-to-tag".

Type:
  • String

templatePath :String

The path to the HTML template for the Tags list

Type:
  • String

templatePath :String

Path to the Texts List HTML template relative to index.html

Type:
  • String

texts :Array.<models#Text>

The texts inclued in this view

Type:
  • Array.<models#Text>