-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Modified main export so that .default does not have to be used in the…
… old syntax. Also exported constants. Bumped version to 0.0.3.
- Loading branch information
Showing
3 changed files
with
99 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,105 @@ | ||
'use strict'; | ||
|
||
module.exports = { | ||
|
||
// Default bootstrap column count | ||
COLUMN_COUNT: 12, | ||
|
||
FORM: 'http://onto.fel.cvut.cz/ontologies/documentation/form', | ||
HAS_SUBQUESTION: 'http://onto.fel.cvut.cz/ontologies/documentation/has_related_question', | ||
HAS_ANSWER: 'http://onto.fel.cvut.cz/ontologies/documentation/has_answer', | ||
HAS_OPTION: 'http://onto.fel.cvut.cz/ontologies/form/has-possible-value', | ||
HAS_OPTIONS_QUERY: 'http://onto.fel.cvut.cz/ontologies/form/has-possible-values-query', | ||
HAS_VALUE_TYPE: 'http://onto.fel.cvut.cz/ontologies/form/has-value-type', | ||
IS_DISABLED: 'http://onto.fel.cvut.cz/ontologies/aviation/form-376/is-disabled', | ||
LAYOUT_CLASS: 'http://onto.fel.cvut.cz/ontologies/form-layout/has-layout-class', | ||
LAYOUT: { | ||
// Default bootstrap column count | ||
const COLUMN_COUNT = 12; | ||
|
||
const FORM = 'http://onto.fel.cvut.cz/ontologies/documentation/form', | ||
HAS_SUBQUESTION = 'http://onto.fel.cvut.cz/ontologies/documentation/has_related_question', | ||
HAS_ANSWER = 'http://onto.fel.cvut.cz/ontologies/documentation/has_answer', | ||
HAS_OPTION = 'http=//onto.fel.cvut.cz/ontologies/form/has-possible-value', | ||
HAS_OPTIONS_QUERY = 'http://onto.fel.cvut.cz/ontologies/form/has-possible-values-query', | ||
HAS_VALUE_TYPE = 'http://onto.fel.cvut.cz/ontologies/form/has-value-type', | ||
IS_DISABLED = 'http://onto.fel.cvut.cz/ontologies/aviation/form-376/is-disabled', | ||
LAYOUT_CLASS = 'http://onto.fel.cvut.cz/ontologies/form-layout/has-layout-class', | ||
LAYOUT = { | ||
FORM: 'form', | ||
QUESTION_TYPEAHEAD: 'type-ahead', | ||
QUESTION_SECTION: 'section', | ||
WIZARD_STEP: 'wizard-step', | ||
DISABLED: 'disabled', | ||
HIDDEN: 'hidden', | ||
TEXTAREA: 'textarea' | ||
TEXTAREA: 'textarea', | ||
DATETIME: 'datetime' | ||
}, | ||
VALUE_TYPE_CODE: 'code', | ||
VALUE_TYPE_TEXT: 'text', | ||
GENERATED_ROW_SIZE: 1, | ||
VALUE_TYPE_CODE = 'code', | ||
VALUE_TYPE_TEXT = 'text', | ||
GENERATED_ROW_SIZE = 1, | ||
|
||
HAS_QUESTION_ORIGIN = 'http://onto.fel.cvut.cz/ontologies/form/has-question-origin', | ||
HAS_ANSWER_ORIGIN = 'http://onto.fel.cvut.cz/ontologies/form/has-answer-origin', | ||
|
||
HAS_DATA_VALUE = 'http://onto.fel.cvut.cz/ontologies/documentation/has_data_value', | ||
HAS_OBJECT_VALUE = 'http://onto.fel.cvut.cz/ontologies/documentation/has_object_value'; | ||
|
||
/** | ||
* Contains mainly definition of constants used to parse the form declaration. | ||
*/ | ||
export default class Constants { | ||
static get COLUMN_COUNT() { | ||
return COLUMN_COUNT; | ||
} | ||
|
||
static get FORM() { | ||
return FORM; | ||
} | ||
|
||
static get HAS_SUBQUESTION() { | ||
return HAS_SUBQUESTION; | ||
} | ||
|
||
static get HAS_ANSWER() { | ||
return HAS_ANSWER; | ||
} | ||
|
||
static get HAS_OPTION() { | ||
return HAS_OPTION; | ||
} | ||
|
||
static get HAS_OPTIONS_QUERY() { | ||
return HAS_OPTIONS_QUERY; | ||
} | ||
|
||
static get HAS_VALUE_TYPE() { | ||
return HAS_VALUE_TYPE; | ||
} | ||
|
||
static get IS_DISABLED() { | ||
return IS_DISABLED; | ||
} | ||
|
||
static get LAYOUT_CLASS() { | ||
return LAYOUT_CLASS; | ||
} | ||
|
||
static get LAYOUT() { | ||
return LAYOUT; | ||
} | ||
|
||
static get VALUE_TYPE_CODE() { | ||
return VALUE_TYPE_CODE; | ||
} | ||
|
||
static get VALUE_TYPE_TEXT() { | ||
return VALUE_TYPE_TEXT; | ||
} | ||
|
||
static get GENERATED_ROW_SIZE() { | ||
return GENERATED_ROW_SIZE; | ||
} | ||
|
||
static get HAS_QUESTION_ORIGIN() { | ||
return HAS_QUESTION_ORIGIN; | ||
} | ||
|
||
static get HAS_ANSWER_ORIGIN() { | ||
return HAS_ANSWER_ORIGIN; | ||
} | ||
|
||
HAS_QUESTION_ORIGIN: 'http://onto.fel.cvut.cz/ontologies/form/has-question-origin', | ||
HAS_ANSWER_ORIGIN: 'http://onto.fel.cvut.cz/ontologies/form/has-answer-origin', | ||
static get HAS_DATA_VALUE() { | ||
return HAS_DATA_VALUE; | ||
} | ||
|
||
HAS_DATA_VALUE: 'http://onto.fel.cvut.cz/ontologies/documentation/has_data_value', | ||
HAS_OBJECT_VALUE: 'http://onto.fel.cvut.cz/ontologies/documentation/has_object_value' | ||
}; | ||
static get HAS_OBJECT_VALUE() { | ||
return HAS_OBJECT_VALUE; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import WizardGenerator from './model/WizardGenerator'; | ||
import Configuration from './model/Configuration'; | ||
import QuestionAnswerProcessor from './model/QuestionAnswerProcessor'; | ||
|
||
export {Configuration, QuestionAnswerProcessor, WizardGenerator}; | ||
export WizardGenerator from './model/WizardGenerator'; | ||
export Configuration from './model/Configuration'; | ||
export QuestionAnswerProcessor from './model/QuestionAnswerProcessor'; | ||
export Constants from './constants/Constants'; |