sjrk.storyTelling.story
represents the data of a single story. It contains metadata and content in the form of individual story block contents (see below for more on blocks).sjrk.dynamicViewComponentManager
handles the dynamic creation, manipulation and removal of dynamic components from a given DOM container. It will automatically register and un-register view components with itself.sjrk.storyTelling.templateManager
renders handlebars templates to HTML, substituting in localized messages as well as any dynamic values to be included.- Template and message bundle options are configured at
{that}.options.templateConfig
- Localized messages are loaded to the key
{that}.templateStrings.localizedMessages
- Localization of content is specified at
{that}.model.locale
, and this is configured at the highest level by thepage
(more on this below)
- Template and message bundle options are configured at
sjrk.storyTelling.binder
is an implementation offluid.binder
that links DOM elements to model values and provides a couple of events to tie into theui
grade (see below).sjrk.storyTelling.block.singleFileUploader
provides some wiring for the Edit page to upload files to the server
sjrk.storyTelling.block
and its derivatives represent a part of the content of a story, and each block has a type related to its use and presentation. This type is expressed at{that}.model.blockType
.sjrk.storyTelling.block.textBlock
is for text contentsjrk.storyTelling.block.imageBlock
is for graphical content (images, photos, etc.)sjrk.storyTelling.block.timeBased
is for time-based content that generally use a media player. This is common code that is used by one of the two 'concrete' implementations:sjrk.storyTelling.block.audioBlock
is for audio contentsjrk.storyTelling.block.videoBlock
is for video content
sjrk.storyTelling.blockUi
, similarly to theui
grade, provides a user interface for a given individual block. EachblockUi
has atemplateManager
to load its unique template and messages as well as ablock
component and manages communication between the two. There are many subcategories ofblockUi
.- Grades for
blockUi
's that handle presentation only:sjrk.storyTelling.blockUi.imageBlockViewer
for image blockssjrk.storyTelling.blockUi.textBlockViewer
for text blockssjrk.storyTelling.blockUi.audioBlockViewer
for audio blockssjrk.storyTelling.blockUi.videoBlockViewer
for video blocks
sjrk.storyTelling.blockUi.timeBased
provides common shared controls related to playback of audio and video blocks and is used for both viewing and editing.sjrk.storyTelling.blockUi.editor
is for editing a block, providing the common elements for the various individual editor types. This includes events and button selectors to reorder the block up or down. Theeditor
derived grades are:sjrk.storyTelling.blockUi.editor.textBlockEditor
for text blockssjrk.storyTelling.blockUi.editor.imageBlockEditor
for image blockssjrk.storyTelling.blockUi.editor.mediaBlockEditor
for time-based media types:sjrk.storyTelling.blockUi.editor.audioBlockEditor
for audio blocks
sjrk.storyTelling.blockUi.editor.videoBlockEditor
for video blocks
sjrk.storyTelling.ui
is used to set up UI contexts (parts of a page).sjrk.storyTelling.ui.storyEditor
is an editing interface for astory
(which it has as a component). It has a handlebars template associated with it calledstoryEditor.hbs
, and abinder
to connect the title, author and keywords fields to their respective model values in thestory
. It makes use of adynamicViewComponentManager
called blockManager to add blocks of varying types on demand. Thereorderer
component is for reordering individual blocks via buttons on each (seesjrk.storyTelling.block.editor
above), by pressingCTRL + UP
orCTRL + DOWN
(or in macOS,CTRL + SHIFT + UP
orCTRL + SHIFT + DOWN
) or by dragging and dropping a block.sjrk.storyTelling.ui.storyViewer
is to view a single story. Its handlebars template isstoryViewer.hbs
. There is also a special version of thestoryViewer
called thestoryPreviewer
which is meant to be used in thestoryEdit
page (more info below).- has a
fluid.orator
component called orator for reading out various content on demand
- has a
sjrk.storyTelling.ui.storyBrowser
shows a list of all the stories in the database. Its handlebars template isstoryBrowse.hbs
.sjrk.storyTelling.base.page
represents a single HTML page, including all interactions within that page. It is the highest-level interface management grade. It has:- a
fluid.prefs.cookieStore
for storing site preferences, - a
ui
grade called menu for top-level links and controls, with an associated template calledmenu.hbs
. - a component for User Interface Options with some associated events to dynamically redraw the page contents when the language is changed, and
- a component for each
ui
in the tool and wiring for communication of relevant information between them.
- a
sjrk.storyTelling.base.page.storyBrowse
represents the Browse page and has astoryBrowser
sjrk.storyTelling.base.page.storyView
represents the View page, has astoryViewer
sjrk.storyTelling.base.page.storyEdit
represents the Edit page, has astoryEditor
and astoryPreviewer
which together form the story authoring environment. There is afluid.locationBar
to manage browser history states within the page. This grade also contains some events, listeners and functions to handle story submission to the server