@pie-element/passage 2.21.6 → 2.21.7-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/configure/CHANGELOG.md +11 -0
- package/configure/lib/defaults.js +1 -1
- package/configure/lib/defaults.js.map +1 -1
- package/configure/lib/design.js +49 -39
- package/configure/lib/design.js.map +1 -1
- package/configure/package.json +1 -1
- package/controller/CHANGELOG.md +11 -0
- package/controller/lib/defaults.js +3 -3
- package/controller/lib/defaults.js.map +1 -1
- package/controller/lib/index.js +26 -5
- package/controller/lib/index.js.map +1 -1
- package/controller/package.json +5 -2
- package/lib/print.js +4 -2
- package/lib/print.js.map +1 -1
- package/module/configure.js +56 -55
- package/module/controller.js +1000 -7
- package/module/element.js +2 -2
- package/module/index.html +1 -1
- package/module/manifest.json +2 -2
- package/module/print.html +1 -1
- package/module/print.js +6 -4
- package/package.json +2 -2
- package/LICENSE.md +0 -5
package/module/configure.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {_dll_react, _dll_prop_types, _dll_react_dom} from "../../../@pie-lib/pie-toolbox-math-rendering-module@1.
|
|
1
|
+
import {_dll_react, _dll_prop_types, _dll_react_dom} from "../../../@pie-lib/pie-toolbox-math-rendering-module@1.26.1/module/index.js";
|
|
2
2
|
import {_dll_pie_lib__pie_toolbox_config_ui, _dll_pie_lib__pie_toolbox_editable_html} from "../../../@pie-lib/pie-toolbox-module@4.24.3/module/index.js";
|
|
3
3
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
4
4
|
function getDefaultExportFromCjs(x) {
|
|
@@ -5501,7 +5501,7 @@ const {settings: settings} = _dll_pie_lib__pie_toolbox_config_ui;
|
|
|
5501
5501
|
const {layout: layout} = _dll_pie_lib__pie_toolbox_config_ui;
|
|
5502
5502
|
const {EditableHtml: EditableHtml} = _dll_pie_lib__pie_toolbox_editable_html;
|
|
5503
5503
|
const {ALL_PLUGINS: ALL_PLUGINS} = _dll_pie_lib__pie_toolbox_editable_html;
|
|
5504
|
-
const _jsxFileName = "/
|
|
5504
|
+
const _jsxFileName = "/Users/andreeapescar/WORK/pie/pie-elements/packages/passage/configure/src/design.jsx";
|
|
5505
5505
|
function _optionalChain(ops) {
|
|
5506
5506
|
let lastAccessLHS = undefined;
|
|
5507
5507
|
let value = ops[0];
|
|
@@ -5562,9 +5562,10 @@ class Main extends React$1.Component {
|
|
|
5562
5562
|
}
|
|
5563
5563
|
render() {
|
|
5564
5564
|
const {model, classes, configuration, imageSupport, onConfigurationChanged, onModelChanged, uploadSoundSupport} = this.props;
|
|
5565
|
-
const {settingsPanelDisabled, language = {}, languageChoices = {}, maxImageWidth = {}, maxImageHeight = {}, mathMlOptions = {}, baseInputConfiguration = {}, teacherInstructions = {}, title, subtitle, text, author} = configuration || ({});
|
|
5566
|
-
const {errors = {}, teacherInstructionsEnabled, titleEnabled, subtitleEnabled, authorEnabled, textEnabled} = model || ({});
|
|
5567
|
-
const {
|
|
5565
|
+
const {settingsPanelDisabled, language = {}, languageChoices = {}, maxImageWidth = {}, maxImageHeight = {}, mathMlOptions = {}, baseInputConfiguration = {}, teacherInstructions = {}, title = {}, subtitle = {}, text = {}, author = {}} = configuration || ({});
|
|
5566
|
+
const {errors = {}, passages = [], teacherInstructionsEnabled, titleEnabled, subtitleEnabled, authorEnabled, textEnabled} = model || ({});
|
|
5567
|
+
const {passages: passagesErrors} = errors || ({});
|
|
5568
|
+
const {teacherInstructions: teacherInstructionsError, title: titleError, subtitle: subtitleError, author: authorError, text: textError} = passagesErrors && passagesErrors[0] || ({});
|
|
5568
5569
|
const defaultImageMaxWidth = maxImageWidth && maxImageWidth.prompt;
|
|
5569
5570
|
const defaultImageMaxHeight = maxImageHeight && maxImageHeight.prompt;
|
|
5570
5571
|
const panelSettings = {
|
|
@@ -5598,159 +5599,159 @@ class Main extends React$1.Component {
|
|
|
5598
5599
|
__self: this,
|
|
5599
5600
|
__source: {
|
|
5600
5601
|
fileName: _jsxFileName,
|
|
5601
|
-
lineNumber:
|
|
5602
|
+
lineNumber: 103
|
|
5602
5603
|
}
|
|
5603
5604
|
}),
|
|
5604
5605
|
__self: this,
|
|
5605
5606
|
__source: {
|
|
5606
5607
|
fileName: _jsxFileName,
|
|
5607
|
-
lineNumber:
|
|
5608
|
+
lineNumber: 100
|
|
5608
5609
|
}
|
|
5609
|
-
},
|
|
5610
|
-
label:
|
|
5610
|
+
}, teacherInstructionsEnabled && React$1.createElement(InputContainer, {
|
|
5611
|
+
label: teacherInstructions.label,
|
|
5611
5612
|
className: classes.inputContainer,
|
|
5612
5613
|
__self: this,
|
|
5613
5614
|
__source: {
|
|
5614
5615
|
fileName: _jsxFileName,
|
|
5615
|
-
lineNumber:
|
|
5616
|
+
lineNumber: 116
|
|
5616
5617
|
}
|
|
5617
5618
|
}, React$1.createElement(EditableHtml, {
|
|
5618
5619
|
activePlugins: ALL_PLUGINS,
|
|
5619
|
-
markup:
|
|
5620
|
-
onChange: value => this.handleChange('
|
|
5620
|
+
markup: passages[0].teacherInstructions || '',
|
|
5621
|
+
onChange: value => this.handleChange('teacherInstructions', value),
|
|
5621
5622
|
nonEmpty: false,
|
|
5622
|
-
error:
|
|
5623
|
+
error: teacherInstructionsError,
|
|
5624
|
+
maxImageWidth: maxImageWidth && maxImageWidth.teacherInstructions || defaultImageMaxWidth,
|
|
5625
|
+
maxImageHeight: maxImageHeight && maxImageHeight.teacherInstructions || defaultImageMaxHeight,
|
|
5623
5626
|
mathMlOptions: mathMlOptions,
|
|
5624
5627
|
languageCharactersProps: [{
|
|
5625
5628
|
language: 'spanish'
|
|
5626
5629
|
}, {
|
|
5627
5630
|
language: 'special'
|
|
5628
5631
|
}],
|
|
5629
|
-
pluginProps: getPluginProps(_optionalChain([
|
|
5632
|
+
pluginProps: getPluginProps(_optionalChain([teacherInstructions, 'optionalAccess', _ => _.inputConfiguration])),
|
|
5630
5633
|
__self: this,
|
|
5631
5634
|
__source: {
|
|
5632
5635
|
fileName: _jsxFileName,
|
|
5633
|
-
lineNumber:
|
|
5636
|
+
lineNumber: 117
|
|
5634
5637
|
}
|
|
5635
|
-
}),
|
|
5638
|
+
}), teacherInstructionsError && React$1.createElement('div', {
|
|
5636
5639
|
className: classes.errorText,
|
|
5637
5640
|
__self: this,
|
|
5638
5641
|
__source: {
|
|
5639
5642
|
fileName: _jsxFileName,
|
|
5640
|
-
lineNumber:
|
|
5643
|
+
lineNumber: 129
|
|
5641
5644
|
}
|
|
5642
|
-
},
|
|
5643
|
-
label:
|
|
5645
|
+
}, teacherInstructionsError)), titleEnabled && React$1.createElement(InputContainer, {
|
|
5646
|
+
label: title.label,
|
|
5644
5647
|
className: classes.inputContainer,
|
|
5645
5648
|
__self: this,
|
|
5646
5649
|
__source: {
|
|
5647
5650
|
fileName: _jsxFileName,
|
|
5648
|
-
lineNumber:
|
|
5651
|
+
lineNumber: 134
|
|
5649
5652
|
}
|
|
5650
5653
|
}, React$1.createElement(EditableHtml, {
|
|
5651
5654
|
activePlugins: ALL_PLUGINS,
|
|
5652
|
-
markup:
|
|
5653
|
-
onChange: value => this.handleChange('
|
|
5655
|
+
markup: passages[0].title || '',
|
|
5656
|
+
onChange: value => this.handleChange('title', value),
|
|
5654
5657
|
nonEmpty: false,
|
|
5655
|
-
error:
|
|
5658
|
+
error: titleError,
|
|
5656
5659
|
mathMlOptions: mathMlOptions,
|
|
5657
5660
|
languageCharactersProps: [{
|
|
5658
5661
|
language: 'spanish'
|
|
5659
5662
|
}, {
|
|
5660
5663
|
language: 'special'
|
|
5661
5664
|
}],
|
|
5662
|
-
pluginProps: getPluginProps(_optionalChain([
|
|
5665
|
+
pluginProps: getPluginProps(_optionalChain([title, 'optionalAccess', _2 => _2.inputConfiguration])),
|
|
5663
5666
|
__self: this,
|
|
5664
5667
|
__source: {
|
|
5665
5668
|
fileName: _jsxFileName,
|
|
5666
|
-
lineNumber:
|
|
5669
|
+
lineNumber: 135
|
|
5667
5670
|
}
|
|
5668
|
-
}),
|
|
5671
|
+
}), titleError && React$1.createElement('div', {
|
|
5669
5672
|
className: classes.errorText,
|
|
5670
5673
|
__self: this,
|
|
5671
5674
|
__source: {
|
|
5672
5675
|
fileName: _jsxFileName,
|
|
5673
|
-
lineNumber:
|
|
5676
|
+
lineNumber: 145
|
|
5674
5677
|
}
|
|
5675
|
-
},
|
|
5676
|
-
label:
|
|
5678
|
+
}, titleError)), subtitleEnabled && React$1.createElement(InputContainer, {
|
|
5679
|
+
label: subtitle.label,
|
|
5677
5680
|
className: classes.inputContainer,
|
|
5678
5681
|
__self: this,
|
|
5679
5682
|
__source: {
|
|
5680
5683
|
fileName: _jsxFileName,
|
|
5681
|
-
lineNumber:
|
|
5684
|
+
lineNumber: 150
|
|
5682
5685
|
}
|
|
5683
5686
|
}, React$1.createElement(EditableHtml, {
|
|
5684
5687
|
activePlugins: ALL_PLUGINS,
|
|
5685
|
-
markup:
|
|
5686
|
-
onChange: value => this.handleChange('
|
|
5688
|
+
markup: passages[0].subtitle || '',
|
|
5689
|
+
onChange: value => this.handleChange('subtitle', value),
|
|
5687
5690
|
nonEmpty: false,
|
|
5688
|
-
error:
|
|
5691
|
+
error: subtitleError,
|
|
5689
5692
|
mathMlOptions: mathMlOptions,
|
|
5690
5693
|
languageCharactersProps: [{
|
|
5691
5694
|
language: 'spanish'
|
|
5692
5695
|
}, {
|
|
5693
5696
|
language: 'special'
|
|
5694
5697
|
}],
|
|
5695
|
-
pluginProps: getPluginProps(_optionalChain([
|
|
5698
|
+
pluginProps: getPluginProps(_optionalChain([subtitle, 'optionalAccess', _3 => _3.inputConfiguration])),
|
|
5696
5699
|
__self: this,
|
|
5697
5700
|
__source: {
|
|
5698
5701
|
fileName: _jsxFileName,
|
|
5699
|
-
lineNumber:
|
|
5702
|
+
lineNumber: 151
|
|
5700
5703
|
}
|
|
5701
|
-
}),
|
|
5704
|
+
}), subtitleError && React$1.createElement('div', {
|
|
5702
5705
|
className: classes.errorText,
|
|
5703
5706
|
__self: this,
|
|
5704
5707
|
__source: {
|
|
5705
5708
|
fileName: _jsxFileName,
|
|
5706
|
-
lineNumber:
|
|
5709
|
+
lineNumber: 161
|
|
5707
5710
|
}
|
|
5708
|
-
},
|
|
5709
|
-
label:
|
|
5711
|
+
}, subtitleError)), authorEnabled && React$1.createElement(InputContainer, {
|
|
5712
|
+
label: author.label,
|
|
5710
5713
|
className: classes.inputContainer,
|
|
5711
5714
|
__self: this,
|
|
5712
5715
|
__source: {
|
|
5713
5716
|
fileName: _jsxFileName,
|
|
5714
|
-
lineNumber:
|
|
5717
|
+
lineNumber: 166
|
|
5715
5718
|
}
|
|
5716
5719
|
}, React$1.createElement(EditableHtml, {
|
|
5717
5720
|
activePlugins: ALL_PLUGINS,
|
|
5718
|
-
markup:
|
|
5719
|
-
onChange: value => this.handleChange('
|
|
5721
|
+
markup: passages[0].author || '',
|
|
5722
|
+
onChange: value => this.handleChange('author', value),
|
|
5720
5723
|
nonEmpty: false,
|
|
5721
|
-
error:
|
|
5722
|
-
maxImageWidth: maxImageWidth && maxImageWidth.teacherInstructions || defaultImageMaxWidth,
|
|
5723
|
-
maxImageHeight: maxImageHeight && maxImageHeight.teacherInstructions || defaultImageMaxHeight,
|
|
5724
|
+
error: authorError,
|
|
5724
5725
|
mathMlOptions: mathMlOptions,
|
|
5725
5726
|
languageCharactersProps: [{
|
|
5726
5727
|
language: 'spanish'
|
|
5727
5728
|
}, {
|
|
5728
5729
|
language: 'special'
|
|
5729
5730
|
}],
|
|
5730
|
-
pluginProps: getPluginProps(_optionalChain([
|
|
5731
|
+
pluginProps: getPluginProps(_optionalChain([author, 'optionalAccess', _4 => _4.inputConfiguration])),
|
|
5731
5732
|
__self: this,
|
|
5732
5733
|
__source: {
|
|
5733
5734
|
fileName: _jsxFileName,
|
|
5734
|
-
lineNumber:
|
|
5735
|
+
lineNumber: 167
|
|
5735
5736
|
}
|
|
5736
|
-
}),
|
|
5737
|
+
}), authorError && React$1.createElement('div', {
|
|
5737
5738
|
className: classes.errorText,
|
|
5738
5739
|
__self: this,
|
|
5739
5740
|
__source: {
|
|
5740
5741
|
fileName: _jsxFileName,
|
|
5741
|
-
lineNumber:
|
|
5742
|
+
lineNumber: 177
|
|
5742
5743
|
}
|
|
5743
|
-
},
|
|
5744
|
+
}, authorError)), textEnabled && React$1.createElement(InputContainer, {
|
|
5744
5745
|
label: text.label,
|
|
5745
5746
|
className: classes.inputContainer,
|
|
5746
5747
|
__self: this,
|
|
5747
5748
|
__source: {
|
|
5748
5749
|
fileName: _jsxFileName,
|
|
5749
|
-
lineNumber:
|
|
5750
|
+
lineNumber: 182
|
|
5750
5751
|
}
|
|
5751
5752
|
}, React$1.createElement(EditableHtml, {
|
|
5752
5753
|
activePlugins: ALL_PLUGINS,
|
|
5753
|
-
markup:
|
|
5754
|
+
markup: passages[0].text || '',
|
|
5754
5755
|
onChange: value => this.handleChange('text', value),
|
|
5755
5756
|
imageSupport: imageSupport,
|
|
5756
5757
|
uploadSoundSupport: uploadSoundSupport,
|
|
@@ -5768,14 +5769,14 @@ class Main extends React$1.Component {
|
|
|
5768
5769
|
__self: this,
|
|
5769
5770
|
__source: {
|
|
5770
5771
|
fileName: _jsxFileName,
|
|
5771
|
-
lineNumber:
|
|
5772
|
+
lineNumber: 183
|
|
5772
5773
|
}
|
|
5773
5774
|
}), textError && React$1.createElement('div', {
|
|
5774
5775
|
className: classes.errorText,
|
|
5775
5776
|
__self: this,
|
|
5776
5777
|
__source: {
|
|
5777
5778
|
fileName: _jsxFileName,
|
|
5778
|
-
lineNumber:
|
|
5779
|
+
lineNumber: 197
|
|
5779
5780
|
}
|
|
5780
5781
|
}, textError)));
|
|
5781
5782
|
}
|
|
@@ -5798,8 +5799,8 @@ var defaultValues = {
|
|
|
5798
5799
|
teacherInstructionsEnabled: true,
|
|
5799
5800
|
titleEnabled: true,
|
|
5800
5801
|
subtitleEnabled: true,
|
|
5801
|
-
textEnabled: true,
|
|
5802
5802
|
authorEnabled: true,
|
|
5803
|
+
textEnabled: true,
|
|
5803
5804
|
passages: [{
|
|
5804
5805
|
teacherInstructions: '',
|
|
5805
5806
|
title: '',
|