@windward/core 0.4.3 → 0.5.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/.idea/codeStyles/Project.xml +58 -0
- package/.idea/codeStyles/codeStyleConfig.xml +5 -0
- package/.idea/inspectionProfiles/Project_Default.xml +6 -0
- package/.idea/modules.xml +8 -0
- package/.idea/php-docker-settings.xml +24 -0
- package/.idea/php.xml +19 -0
- package/.idea/vcs.xml +6 -0
- package/.idea/watcherTasks.xml +4 -0
- package/.idea/windward-ui-plugin-core.iml +8 -0
- package/components/Content/Blocks/Accordion.vue +10 -6
- package/components/Content/Blocks/ClickableIcons.vue +6 -5
- package/components/Content/Blocks/Feedback.vue +1 -1
- package/components/Content/Blocks/FileDownload/FileLinks.vue +82 -0
- package/components/Content/Blocks/FileDownload/FileTable.vue +106 -0
- package/components/Content/Blocks/FileDownload.vue +145 -0
- package/components/Content/Blocks/GenerateAIQuestionButton.vue +61 -0
- package/components/Content/Blocks/ScenarioChoice.vue +2 -2
- package/components/Content/Blocks/UserUpload.vue +15 -36
- package/components/Content/Blocks/Video.vue +2 -57
- package/components/Settings/AccordionSettings.vue +3 -6
- package/components/Settings/BlockQuoteSettings.vue +2 -2
- package/components/Settings/EmailSettings.vue +2 -2
- package/components/Settings/FileDownloadSettings.vue +168 -0
- package/components/Settings/UserUploadSettings.vue +36 -39
- package/components/utils/ContentViewer.vue +1 -0
- package/components/utils/TinyMCEWrapper.vue +15 -16
- package/components/utils/assets/tinymce/content/global.scss +10 -0
- package/config/menu.config.json +475 -0
- package/coverage/clover.xml +223 -0
- package/coverage/coverage-final.json +16 -0
- package/coverage/lcov-report/base.css +224 -0
- package/coverage/lcov-report/block-navigation.js +87 -0
- package/coverage/lcov-report/components/Content/Blocks/Accordion.vue.html +430 -0
- package/coverage/lcov-report/components/Content/Blocks/Image.vue.html +394 -0
- package/coverage/lcov-report/components/Content/Blocks/Math.vue.html +262 -0
- package/coverage/lcov-report/components/Content/Blocks/RichText.vue.html +295 -0
- package/coverage/lcov-report/components/Content/Blocks/Tab.vue.html +415 -0
- package/coverage/lcov-report/components/Content/Blocks/Table.vue.html +667 -0
- package/coverage/lcov-report/components/Content/Blocks/Video.vue.html +2275 -0
- package/coverage/lcov-report/components/Content/Blocks/index.html +206 -0
- package/coverage/lcov-report/components/utils/ContentViewer.vue.html +199 -0
- package/coverage/lcov-report/components/utils/MathExpressionEditor.vue.html +919 -0
- package/coverage/lcov-report/components/utils/MathLiveWrapper.vue.html +343 -0
- package/coverage/lcov-report/components/utils/TinyMCEWrapper.vue.html +271 -0
- package/coverage/lcov-report/components/utils/index.html +161 -0
- package/coverage/lcov-report/config/index.html +116 -0
- package/coverage/lcov-report/config/tinymce.config.js.html +493 -0
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/helpers/MathHelper.ts.html +793 -0
- package/coverage/lcov-report/helpers/index.html +116 -0
- package/coverage/lcov-report/helpers/tinymce/index.html +116 -0
- package/coverage/lcov-report/helpers/tinymce/plugin.ts.html +334 -0
- package/coverage/lcov-report/index.html +191 -0
- package/coverage/lcov-report/prettify.css +1 -0
- package/coverage/lcov-report/prettify.js +2 -0
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +196 -0
- package/coverage/lcov-report/test/index.html +116 -0
- package/coverage/lcov-report/test/mocks.js.html +457 -0
- package/coverage/lcov.info +403 -0
- package/i18n/en-US/components/content/blocks/file_download.ts +5 -0
- package/i18n/en-US/components/content/blocks/generate_questions.ts +3 -0
- package/i18n/en-US/components/content/blocks/index.ts +4 -0
- package/i18n/en-US/components/content/blocks/user_upload.ts +0 -2
- package/i18n/en-US/components/settings/file_download.ts +8 -0
- package/i18n/en-US/components/settings/index.ts +2 -0
- package/i18n/en-US/shared/content_blocks.ts +1 -0
- package/i18n/en-US/shared/settings.ts +1 -3
- package/i18n/es-ES/components/content/blocks/file_download.ts +5 -0
- package/i18n/es-ES/components/content/blocks/generate_questions.ts +3 -0
- package/i18n/es-ES/components/content/blocks/index.ts +6 -2
- package/i18n/es-ES/components/content/blocks/user_upload.ts +0 -2
- package/i18n/es-ES/components/settings/file_download.ts +8 -0
- package/i18n/es-ES/components/settings/index.ts +4 -2
- package/i18n/es-ES/shared/content_blocks.ts +1 -0
- package/i18n/es-ES/shared/settings.ts +1 -3
- package/i18n/sv-SE/components/content/blocks/file_download.ts +5 -0
- package/i18n/sv-SE/components/content/blocks/generate_questions.ts +3 -0
- package/i18n/sv-SE/components/content/blocks/index.ts +4 -0
- package/i18n/sv-SE/components/content/blocks/user_upload.ts +0 -2
- package/i18n/sv-SE/components/settings/file_download.ts +8 -0
- package/i18n/sv-SE/components/settings/index.ts +4 -2
- package/i18n/sv-SE/shared/content_blocks.ts +1 -0
- package/i18n/sv-SE/shared/settings.ts +2 -4
- package/lib/helpers/GlossaryHelper.d.ts +9 -0
- package/lib/helpers/GlossaryHelper.js +118 -0
- package/lib/helpers/GlossaryTerm.d.ts +10 -0
- package/lib/helpers/GlossaryTerm.js +22 -0
- package/lib/helpers/MathHelper.d.ts +99 -0
- package/lib/helpers/MathHelper.js +194 -0
- package/lib/helpers/tinymce/plugin.d.ts +2 -0
- package/lib/helpers/tinymce/plugin.js +86 -0
- package/lib/i18n/en-US/components/content/blocks/image.d.ts +6 -0
- package/lib/i18n/en-US/components/content/blocks/image.js +7 -0
- package/lib/i18n/en-US/components/content/blocks/index.d.ts +75 -0
- package/lib/i18n/en-US/components/content/blocks/index.js +14 -0
- package/lib/i18n/en-US/components/content/blocks/tab.d.ts +5 -0
- package/lib/i18n/en-US/components/content/blocks/tab.js +6 -0
- package/lib/i18n/en-US/components/content/blocks/table.d.ts +5 -0
- package/lib/i18n/en-US/components/content/blocks/table.js +6 -0
- package/lib/i18n/en-US/components/content/blocks/user_upload.d.ts +13 -0
- package/lib/i18n/en-US/components/content/blocks/user_upload.js +14 -0
- package/lib/i18n/en-US/components/content/blocks/video.d.ts +48 -0
- package/lib/i18n/en-US/components/content/blocks/video.js +49 -0
- package/lib/i18n/en-US/components/content/index.d.ts +77 -0
- package/lib/i18n/en-US/components/content/index.js +6 -0
- package/lib/i18n/en-US/components/index.d.ts +140 -0
- package/lib/i18n/en-US/components/index.js +12 -0
- package/lib/i18n/en-US/components/navigation/image.d.ts +5 -0
- package/lib/i18n/en-US/components/navigation/image.js +6 -0
- package/lib/i18n/en-US/components/navigation/index.d.ts +10 -0
- package/lib/i18n/en-US/components/navigation/index.js +8 -0
- package/lib/i18n/en-US/components/navigation/user_upload.d.ts +4 -0
- package/lib/i18n/en-US/components/navigation/user_upload.js +5 -0
- package/lib/i18n/en-US/components/settings/clickable_icon.d.ts +6 -0
- package/lib/i18n/en-US/components/settings/clickable_icon.js +7 -0
- package/lib/i18n/en-US/components/settings/image.d.ts +2 -0
- package/lib/i18n/en-US/components/settings/image.js +3 -0
- package/lib/i18n/en-US/components/settings/index.d.ts +39 -0
- package/lib/i18n/en-US/components/settings/index.js +14 -0
- package/lib/i18n/en-US/components/settings/text_editor.d.ts +8 -0
- package/lib/i18n/en-US/components/settings/text_editor.js +9 -0
- package/lib/i18n/en-US/components/settings/user_upload.d.ts +12 -0
- package/lib/i18n/en-US/components/settings/user_upload.js +13 -0
- package/lib/i18n/en-US/components/settings/video.d.ts +13 -0
- package/lib/i18n/en-US/components/settings/video.js +14 -0
- package/lib/i18n/en-US/components/utils/index.d.ts +15 -0
- package/lib/i18n/en-US/components/utils/index.js +6 -0
- package/lib/i18n/en-US/components/utils/tiny_mce_wrapper.d.ts +13 -0
- package/lib/i18n/en-US/components/utils/tiny_mce_wrapper.js +14 -0
- package/lib/i18n/en-US/index.d.ts +197 -0
- package/lib/i18n/en-US/index.js +16 -0
- package/lib/i18n/en-US/modules/index.d.ts +2 -0
- package/lib/i18n/en-US/modules/index.js +6 -0
- package/lib/i18n/en-US/pages/glossary.d.ts +8 -0
- package/lib/i18n/en-US/pages/glossary.js +9 -0
- package/lib/i18n/en-US/pages/index.d.ts +13 -0
- package/lib/i18n/en-US/pages/index.js +8 -0
- package/lib/i18n/en-US/pages/user_upload.d.ts +4 -0
- package/lib/i18n/en-US/pages/user_upload.js +5 -0
- package/lib/i18n/en-US/shared/content_blocks.d.ts +20 -0
- package/lib/i18n/en-US/shared/content_blocks.js +21 -0
- package/lib/i18n/en-US/shared/index.d.ts +39 -0
- package/lib/i18n/en-US/shared/index.js +10 -0
- package/lib/i18n/en-US/shared/menu.d.ts +4 -0
- package/lib/i18n/en-US/shared/menu.js +5 -0
- package/lib/i18n/en-US/shared/settings.d.ts +15 -0
- package/lib/i18n/en-US/shared/settings.js +16 -0
- package/lib/i18n/en-US.d.ts +197 -0
- package/lib/i18n/en-US.js +15 -0
- package/lib/models/UserFileAsset.d.ts +5 -0
- package/lib/models/UserFileAsset.js +37 -0
- package/package.json +2 -2
- package/plugin.js +20 -0
- package/test/Components/Content/Blocks/FileDownload.spec.js +25 -0
- package/test/Components/Content/Blocks/Video.spec.js +0 -22
- package/test/Components/Settings/FileDownloadSettings.spec.js +20 -0
- package/test/Components/Settings/UserUploadSettings.spec.js +1 -1
- package/utils/index.js +2 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@windward/core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
4
4
|
"description": "Windward UI Core Plugins",
|
|
5
5
|
"main": "plugin.js",
|
|
6
6
|
"scripts": {
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"license": "MIT",
|
|
22
22
|
"homepage": "https://bitbucket.org/mindedge/windward-ui-plugin-core#readme",
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@mindedge/vuetify-player": "^0.3.
|
|
24
|
+
"@mindedge/vuetify-player": "^0.3.1",
|
|
25
25
|
"@tinymce/tinymce-vue": "^3.2.8",
|
|
26
26
|
"eslint": "^8.11.0",
|
|
27
27
|
"he": "^1.2.0",
|
package/plugin.js
CHANGED
|
@@ -19,6 +19,7 @@ import OpenResponse from './components/Content/Blocks/OpenResponse'
|
|
|
19
19
|
import OpenResponseCollate from './components/Content/Blocks/OpenResponseCollate'
|
|
20
20
|
import Image from './components/Content/Blocks/Image'
|
|
21
21
|
import UserUpload from './components/Content/Blocks/UserUpload'
|
|
22
|
+
import FileDownload from './components/Content/Blocks/FileDownload'
|
|
22
23
|
|
|
23
24
|
import GlossaryPage from './pages/glossary.vue'
|
|
24
25
|
import TinymcePlugin from './pages/plugins/tinymce/_plugin.vue'
|
|
@@ -32,6 +33,7 @@ import OpenResponseSettings from './components/Settings/OpenResponseSettings.vue
|
|
|
32
33
|
import OpenResponseCollateSettings from './components/Settings/OpenResponseCollateSettings.vue'
|
|
33
34
|
import ImageSettings from './components/Settings/ImageSettings.vue'
|
|
34
35
|
import UserUploadSettings from './components/Settings/UserUploadSettings.vue'
|
|
36
|
+
import FileDownloadSettings from './components/Settings/FileDownloadSettings.vue'
|
|
35
37
|
import ClickableIconsSettings from './components/Settings/ClickableIconsSettings.vue'
|
|
36
38
|
import ScenarioChoiceSettings from './components/Settings/ScenarioChoiceSettings.vue'
|
|
37
39
|
import VideoSettings from './components/Settings/VideoSettings.vue'
|
|
@@ -220,6 +222,15 @@ export default {
|
|
|
220
222
|
grouping: 'components.content.blocks.group.multimedia',
|
|
221
223
|
},
|
|
222
224
|
},
|
|
225
|
+
{
|
|
226
|
+
tag: 'core-file-download',
|
|
227
|
+
template: FileDownload,
|
|
228
|
+
metadata: {
|
|
229
|
+
icon: 'mdi-cloud-download',
|
|
230
|
+
name: 'windward.core.shared.content_blocks.title.file_download',
|
|
231
|
+
grouping: 'components.content.blocks.group.multimedia',
|
|
232
|
+
},
|
|
233
|
+
},
|
|
223
234
|
{
|
|
224
235
|
tag: 'core-clickable-icons',
|
|
225
236
|
template: ClickableIcons,
|
|
@@ -312,6 +323,15 @@ export default {
|
|
|
312
323
|
name: 'windward.core.shared.settings.title.user_upload',
|
|
313
324
|
},
|
|
314
325
|
},
|
|
326
|
+
{
|
|
327
|
+
tag: 'core-file-download-settings',
|
|
328
|
+
template: FileDownloadSettings,
|
|
329
|
+
context: ['block.core-file-download'],
|
|
330
|
+
metadata: {
|
|
331
|
+
icon: 'mdi-cog',
|
|
332
|
+
name: 'windward.core.shared.settings.title.file_download',
|
|
333
|
+
},
|
|
334
|
+
},
|
|
315
335
|
{
|
|
316
336
|
tag: 'core-tab-settings',
|
|
317
337
|
template: TabSettings,
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { mount, shallowMount } from '@vue/test-utils'
|
|
2
|
+
import Vue from 'vue'
|
|
3
|
+
import Vuetify from 'vuetify'
|
|
4
|
+
|
|
5
|
+
import { defaultMocks } from '@/test/mocks'
|
|
6
|
+
import FileDownload from '@/components/Content/Blocks/FileDownload.vue'
|
|
7
|
+
|
|
8
|
+
Vue.use(Vuetify)
|
|
9
|
+
|
|
10
|
+
describe('FileDownload component', () => {
|
|
11
|
+
test('is a Vue instance', () => {
|
|
12
|
+
const wrapper = shallowMount(FileDownload, {
|
|
13
|
+
vuetify: new Vuetify(),
|
|
14
|
+
propsData: {
|
|
15
|
+
value: {
|
|
16
|
+
id: '00000000-0000-0000-0000-000000000000',
|
|
17
|
+
body: 'dummy text',
|
|
18
|
+
metadata: {},
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
mocks: defaultMocks,
|
|
22
|
+
})
|
|
23
|
+
expect(wrapper.vm).toBeTruthy()
|
|
24
|
+
})
|
|
25
|
+
})
|
|
@@ -87,26 +87,4 @@ describe('Video', () => {
|
|
|
87
87
|
metadata.config.playlist
|
|
88
88
|
)
|
|
89
89
|
})
|
|
90
|
-
|
|
91
|
-
test('Video config edit mode', async () => {
|
|
92
|
-
const wrapper = mount(Video, {
|
|
93
|
-
vuetify: new Vuetify(),
|
|
94
|
-
propsData: {
|
|
95
|
-
value: {
|
|
96
|
-
body: 'video',
|
|
97
|
-
metadata,
|
|
98
|
-
},
|
|
99
|
-
},
|
|
100
|
-
mocks: defaultMocks,
|
|
101
|
-
})
|
|
102
|
-
expect(wrapper.vm).toBeTruthy()
|
|
103
|
-
|
|
104
|
-
// Render mode enabled by default aka non-edit mode
|
|
105
|
-
expect(wrapper.vm.$data.render).toEqual(true)
|
|
106
|
-
|
|
107
|
-
// Turn on edit mode and test
|
|
108
|
-
await wrapper.vm.onActionPanelEdit()
|
|
109
|
-
|
|
110
|
-
expect(wrapper.vm.$data.render).toEqual(false)
|
|
111
|
-
})
|
|
112
90
|
})
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { shallowMount } from '@vue/test-utils'
|
|
2
|
+
import Vuetify from 'vuetify'
|
|
3
|
+
import Vue from 'vue'
|
|
4
|
+
|
|
5
|
+
import { defaultMocks } from '@/test/mocks'
|
|
6
|
+
import FileDownloadSettings from '@/components/Settings/FileDownloadSettings'
|
|
7
|
+
|
|
8
|
+
Vue.use(Vuetify)
|
|
9
|
+
|
|
10
|
+
describe('FileDownloadSettings', () => {
|
|
11
|
+
test('is a Vue instance', () => {
|
|
12
|
+
const wrapper = shallowMount(FileDownloadSettings, {
|
|
13
|
+
propsData: {
|
|
14
|
+
tag: 'core-file-download',
|
|
15
|
+
},
|
|
16
|
+
mocks: defaultMocks,
|
|
17
|
+
})
|
|
18
|
+
expect(wrapper.vm).toBeTruthy()
|
|
19
|
+
})
|
|
20
|
+
})
|
package/utils/index.js
CHANGED
|
@@ -7,6 +7,7 @@ import TinyMCEWrapper from '../components/utils/TinyMCEWrapper.vue'
|
|
|
7
7
|
import MathExpressionEditor from '../components/utils/MathExpressionEditor'
|
|
8
8
|
import CourseGlossary from '../components/utils/glossary/CourseGlossary.vue'
|
|
9
9
|
import CourseGlossaryForm from '../components/utils/glossary/CourseGlossaryForm.vue'
|
|
10
|
+
import GenerateAIQuestionButton from '../components/Content/Blocks/GenerateAIQuestionButton.vue';
|
|
10
11
|
export {
|
|
11
12
|
MathHelper,
|
|
12
13
|
ContentViewer,
|
|
@@ -15,4 +16,5 @@ export {
|
|
|
15
16
|
TinyMCEWrapper,
|
|
16
17
|
CourseGlossary,
|
|
17
18
|
CourseGlossaryForm,
|
|
19
|
+
GenerateAIQuestionButton,
|
|
18
20
|
}
|