@windward/core 0.4.1 → 0.4.2
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/components/Content/Blocks/Image.vue +2 -2
- package/components/Settings/ImageSettings.vue +7 -8
- package/components/Settings/TextEditorSettings.vue +1 -0
- package/components/utils/MathExpressionEditor.vue +61 -49
- package/components/utils/TinyMCEWrapper.vue +10 -5
- package/components/utils/assets/tinymce/ui/dark/skin.scss +1 -1
- package/components/utils/assets/tinymce/ui/light/skin.scss +1 -1
- package/config/tinymce.config.ts +2 -6
- package/i18n/en-US/components/settings/image.ts +2 -0
- package/i18n/en-US/components/utils/math_expression_editor.ts +4 -3
- package/i18n/es-ES/components/settings/image.ts +2 -0
- package/i18n/es-ES/components/utils/math_expression_editor.ts +2 -1
- package/i18n/sv-SE/components/settings/image.ts +2 -0
- package/i18n/sv-SE/components/utils/math_expression_editor.ts +1 -0
- package/package.json +1 -1
|
@@ -124,7 +124,7 @@ export default {
|
|
|
124
124
|
altText() {
|
|
125
125
|
// Get the asset info first and fallback to the block metadata if inherit is set to false
|
|
126
126
|
if (_.get(this.block.metadata, 'config.inherit', true)) {
|
|
127
|
-
return _.get(this.fileAsset, 'metadata.props.alt', null)
|
|
127
|
+
return _.get(this.fileAsset, 'asset.metadata.props.alt', null)
|
|
128
128
|
} else {
|
|
129
129
|
return _.get(this.block.metadata, 'config.alt', null)
|
|
130
130
|
}
|
|
@@ -134,7 +134,7 @@ export default {
|
|
|
134
134
|
if (_.get(this.block.metadata, 'config.inherit', true)) {
|
|
135
135
|
return _.get(
|
|
136
136
|
this.fileAsset,
|
|
137
|
-
'metadata.props.aria_describedby',
|
|
137
|
+
'asset.metadata.props.aria_describedby',
|
|
138
138
|
null
|
|
139
139
|
)
|
|
140
140
|
} else {
|
|
@@ -4,18 +4,17 @@
|
|
|
4
4
|
mimes="image/jpeg,image/png,image/gif"
|
|
5
5
|
v-model="block.metadata.config.asset"
|
|
6
6
|
class="mb-4"
|
|
7
|
+
:label="
|
|
8
|
+
$t(
|
|
9
|
+
'windward.core.components.settings.image.current_image_file'
|
|
10
|
+
) + ':'
|
|
11
|
+
"
|
|
7
12
|
:disabled="render"
|
|
13
|
+
:assets.sync="block.assets"
|
|
8
14
|
@click:file="onFileSelect"
|
|
9
15
|
>
|
|
10
16
|
<template #title>
|
|
11
|
-
{{ $t('windward.core.components.
|
|
12
|
-
</template>
|
|
13
|
-
<template #description>
|
|
14
|
-
{{
|
|
15
|
-
$t(
|
|
16
|
-
'windward.core.components.content.blocks.image.description'
|
|
17
|
-
)
|
|
18
|
-
}}
|
|
17
|
+
{{ $t('windward.core.components.settings.image.place_image') }}
|
|
19
18
|
</template>
|
|
20
19
|
</ContentBlockAsset>
|
|
21
20
|
|
|
@@ -25,6 +25,11 @@
|
|
|
25
25
|
>
|
|
26
26
|
{{ $tc(keyboard.name, keyboard.buttons.length) }}
|
|
27
27
|
</v-tab>
|
|
28
|
+
<v-tab>{{
|
|
29
|
+
$t(
|
|
30
|
+
'windward.core.components.utils.math_expression_editor.accessibility'
|
|
31
|
+
)
|
|
32
|
+
}}</v-tab>
|
|
28
33
|
</v-tabs>
|
|
29
34
|
|
|
30
35
|
<v-tabs-items v-model="tab">
|
|
@@ -50,6 +55,62 @@
|
|
|
50
55
|
</div>
|
|
51
56
|
</v-container>
|
|
52
57
|
</v-tab-item>
|
|
58
|
+
<v-tab-item>
|
|
59
|
+
<v-container class="pb-4">
|
|
60
|
+
<v-row align="center">
|
|
61
|
+
<v-switch
|
|
62
|
+
v-model="spokenTextChanged"
|
|
63
|
+
:label="
|
|
64
|
+
$t(
|
|
65
|
+
'windward.core.components.utils.math_expression_editor.custom_screen_reader_text'
|
|
66
|
+
)
|
|
67
|
+
"
|
|
68
|
+
hide-details
|
|
69
|
+
class="shrink mr-2 mt-0"
|
|
70
|
+
></v-switch>
|
|
71
|
+
<v-textarea
|
|
72
|
+
v-model="spokenText"
|
|
73
|
+
:disabled="!spokenTextChanged"
|
|
74
|
+
:label="
|
|
75
|
+
$t(
|
|
76
|
+
'windward.core.components.utils.math_expression_editor.screen_reader_text'
|
|
77
|
+
)
|
|
78
|
+
"
|
|
79
|
+
class="col-md-12"
|
|
80
|
+
@input="submit"
|
|
81
|
+
></v-textarea>
|
|
82
|
+
</v-row>
|
|
83
|
+
|
|
84
|
+
<br />
|
|
85
|
+
<v-row class="float-right">
|
|
86
|
+
<v-btn
|
|
87
|
+
primary
|
|
88
|
+
color="success"
|
|
89
|
+
elevation="0"
|
|
90
|
+
@click="setSRText"
|
|
91
|
+
:class="fontSize"
|
|
92
|
+
>{{
|
|
93
|
+
$t(
|
|
94
|
+
'windward.core.components.utils.math_expression_editor.default_screen_reader_text'
|
|
95
|
+
)
|
|
96
|
+
}}
|
|
97
|
+
</v-btn>
|
|
98
|
+
|
|
99
|
+
<v-btn
|
|
100
|
+
color="primary"
|
|
101
|
+
elevation="0"
|
|
102
|
+
:class="fontSize"
|
|
103
|
+
@click="readSRText"
|
|
104
|
+
>{{
|
|
105
|
+
$t(
|
|
106
|
+
'windward.core.components.utils.math_expression_editor.read_text_aloud'
|
|
107
|
+
)
|
|
108
|
+
}}
|
|
109
|
+
</v-btn>
|
|
110
|
+
</v-row>
|
|
111
|
+
</v-container>
|
|
112
|
+
<br />
|
|
113
|
+
</v-tab-item>
|
|
53
114
|
</v-tabs-items>
|
|
54
115
|
<br />
|
|
55
116
|
<math-live-wrapper
|
|
@@ -61,55 +122,6 @@
|
|
|
61
122
|
@change="submit"
|
|
62
123
|
></math-live-wrapper>
|
|
63
124
|
<br />
|
|
64
|
-
<v-container>
|
|
65
|
-
<v-row align="center">
|
|
66
|
-
<v-switch
|
|
67
|
-
v-model="spokenTextChanged"
|
|
68
|
-
:label="
|
|
69
|
-
$t(
|
|
70
|
-
'windward.core.components.utils.math_expression_editor.custom_screen_reader_text'
|
|
71
|
-
)
|
|
72
|
-
"
|
|
73
|
-
hide-details
|
|
74
|
-
class="shrink mr-2 mt-0"
|
|
75
|
-
></v-switch>
|
|
76
|
-
<v-textarea
|
|
77
|
-
v-model="spokenText"
|
|
78
|
-
:disabled="!spokenTextChanged"
|
|
79
|
-
:label="
|
|
80
|
-
$t(
|
|
81
|
-
'windward.core.components.utils.math_expression_editor.screen_reader_text'
|
|
82
|
-
)
|
|
83
|
-
"
|
|
84
|
-
class="col-md-12"
|
|
85
|
-
@input="submit"
|
|
86
|
-
></v-textarea>
|
|
87
|
-
</v-row>
|
|
88
|
-
</v-container>
|
|
89
|
-
|
|
90
|
-
<br />
|
|
91
|
-
<v-row class="float-right">
|
|
92
|
-
<v-btn
|
|
93
|
-
primary
|
|
94
|
-
color="success"
|
|
95
|
-
elevation="0"
|
|
96
|
-
@click="setSRText"
|
|
97
|
-
:class="fontSize"
|
|
98
|
-
>{{
|
|
99
|
-
$t(
|
|
100
|
-
'windward.core.components.utils.math_expression_editor.default_screen_reader_text'
|
|
101
|
-
)
|
|
102
|
-
}}
|
|
103
|
-
</v-btn>
|
|
104
|
-
|
|
105
|
-
<v-btn color="primary" elevation="0" :class="fontSize" @click="readSRText"
|
|
106
|
-
>{{
|
|
107
|
-
$t(
|
|
108
|
-
'windward.core.components.utils.math_expression_editor.read_text_aloud'
|
|
109
|
-
)
|
|
110
|
-
}}
|
|
111
|
-
</v-btn>
|
|
112
|
-
</v-row>
|
|
113
125
|
</v-card-text>
|
|
114
126
|
</v-card>
|
|
115
127
|
</div>
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
<v-btn-toggle dense multiple class="pt-1 d-flex justify-end">
|
|
27
27
|
<slot name="actions-prepend" :render="render"></slot>
|
|
28
28
|
<slot name="actions" :render="render">
|
|
29
|
-
<v-btn-toggle dense>
|
|
29
|
+
<v-btn-toggle dense v-if="allowRead">
|
|
30
30
|
<v-btn v-if="render" color="primary" outlined @click="read">
|
|
31
31
|
<v-icon> mdi-play</v-icon>
|
|
32
32
|
</v-btn>
|
|
@@ -142,6 +142,7 @@ export default {
|
|
|
142
142
|
},
|
|
143
143
|
root_block: { type: String, required: false, default: 'div' },
|
|
144
144
|
label: { type: String, required: true, default: '' },
|
|
145
|
+
allowRead: { type: Boolean, required: false, default: false },
|
|
145
146
|
},
|
|
146
147
|
beforeMount() {
|
|
147
148
|
if (MathHelper.containsLatex(this.value)) {
|
|
@@ -478,12 +479,16 @@ export default {
|
|
|
478
479
|
}
|
|
479
480
|
},
|
|
480
481
|
resume() {
|
|
481
|
-
this.synthesizer
|
|
482
|
-
|
|
482
|
+
if (this.synthesizer) {
|
|
483
|
+
this.synthesizer.resume()
|
|
484
|
+
this.paused = false
|
|
485
|
+
}
|
|
483
486
|
},
|
|
484
487
|
stop() {
|
|
485
|
-
this.synthesizer
|
|
486
|
-
|
|
488
|
+
if (this.synthesizer) {
|
|
489
|
+
this.synthesizer.stop()
|
|
490
|
+
this.paused = false
|
|
491
|
+
}
|
|
487
492
|
},
|
|
488
493
|
onEditorFocus() {
|
|
489
494
|
if (!this.render) {
|
|
@@ -426,7 +426,7 @@ button::-moz-focus-inner {
|
|
|
426
426
|
background-image: none;
|
|
427
427
|
border-color: var(--v-primary-base);
|
|
428
428
|
box-shadow: none;
|
|
429
|
-
color: var(--v-
|
|
429
|
+
color: var(--v-primary-base);
|
|
430
430
|
}
|
|
431
431
|
.tox .tox-button:active:not(:disabled) {
|
|
432
432
|
background-color: inherit;
|
package/config/tinymce.config.ts
CHANGED
|
@@ -25,10 +25,6 @@ export default {
|
|
|
25
25
|
cmd: false,
|
|
26
26
|
text: 'i',
|
|
27
27
|
},
|
|
28
|
-
{
|
|
29
|
-
cmd: false,
|
|
30
|
-
text: '\\$',
|
|
31
|
-
},
|
|
32
28
|
{
|
|
33
29
|
cmd: false,
|
|
34
30
|
text: '\\%',
|
|
@@ -307,11 +303,11 @@ export default {
|
|
|
307
303
|
buttons: [
|
|
308
304
|
{
|
|
309
305
|
cmd: false,
|
|
310
|
-
text: '\\begin{cases} x
|
|
306
|
+
text: '\\begin{cases} x+y \\\\ x+y \\end{cases}',
|
|
311
307
|
},
|
|
312
308
|
{
|
|
313
309
|
cmd: false,
|
|
314
|
-
text: '\\begin{cases}
|
|
310
|
+
text: '\\begin{cases}x+y\\\\ x-y\\end{cases}',
|
|
315
311
|
},
|
|
316
312
|
],
|
|
317
313
|
},
|
|
@@ -7,8 +7,9 @@ export default {
|
|
|
7
7
|
probability: 'Probability',
|
|
8
8
|
matrix: 'Matrix',
|
|
9
9
|
eq_systems: 'Equation Systems',
|
|
10
|
-
screen_reader_text: '
|
|
11
|
-
default_screen_reader_text: 'Default
|
|
12
|
-
custom_screen_reader_text: 'Customize
|
|
10
|
+
screen_reader_text: 'Screen Reader Text',
|
|
11
|
+
default_screen_reader_text: 'Default Screen Reader Text',
|
|
12
|
+
custom_screen_reader_text: 'Customize Screen Reader Text',
|
|
13
13
|
read_text_aloud: 'Read Text aloud',
|
|
14
|
+
accessibility: 'Accessibility',
|
|
14
15
|
}
|
|
@@ -8,7 +8,8 @@ export default {
|
|
|
8
8
|
matrix: 'Matriz',
|
|
9
9
|
eq_systems: 'Sistemas de ecuaciones',
|
|
10
10
|
screen_reader_text: 'Texto del lector de pantalla',
|
|
11
|
-
default_screen_reader_text: 'Texto del lector de pantalla auto
|
|
11
|
+
default_screen_reader_text: 'Texto del lector de pantalla auto generado',
|
|
12
12
|
custom_screen_reader_text: 'Personalizar el texto del lector de pantalla/',
|
|
13
13
|
read_text_aloud: 'Leer texto',
|
|
14
|
+
accessibility: 'Accesibilidad',
|
|
14
15
|
}
|