Added option to remove arrow buttons

This commit is contained in:
PMKuipers 2024-08-08 19:27:51 +02:00
parent a9595974bb
commit 13523670cb
6 changed files with 25 additions and 13 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -8,7 +8,7 @@
import {loadStrings} from './util/string-helper';
import {formatDate, studyplanDates, studyplanTiming} from './util/date-helper';
import FitTextVue from './util/fittext-vue';
import {settings} from "./util/settings";
export default {
@ -498,6 +498,7 @@ export default {
},
data() {
return {
showarrows: settings("showprevnextarrows"),
text: strings.prevnext,
};
},
@ -571,10 +572,12 @@ export default {
},
template: `
<div :class="'s-prevnext-selector '">
<b-button :variant='variant' @click="prev" :disabled="atFirst()"
<template v-if="showarrows"
><b-button :variant='variant' @click="prev" :disabled="atFirst()"
><i v-if='arrows' class='fa fa-caret-left s-prevnext-arrow'></i
><template v-else>{{text.prev}}</template></b-button>
<b-form-select v-model="bubblevalue"
><template v-else>{{text.prev}}</template></b-button
>&nbsp;</template
><b-form-select v-model="bubblevalue"
@change='selectedchanged'
>
<b-form-select-option
@ -604,10 +607,12 @@ export default {
:value="o"
><slot :value="o">{{o[titlefield]}}</slot></b-form-select-option>
</template>
</b-form-select>
<b-button :variant='variant' @click="next" :disabled="atLast()"
</b-form-select
><template v-if="showarrows"
>&nbsp;<b-button :variant='variant' @click="next" :disabled="atLast()"
><i v-if='arrows' class='fa fa-caret-right s-prevnext-arrow'></i
><template v-else>{{text.next}}</template></b-button>
><template v-else>{{text.next}}</template></b-button
></template>
</div>
`,
});

View File

@ -128,12 +128,12 @@ $string["settingdesc_infofields_heading"] = 'Select up to 5 fields or custom fie
$string["setting_hivizdropslots"] = 'High visibility drop fields';
$string["settingdesc_hivizdropslots"] = 'Give the drop fields when editing a study plan extra visibility.';
$string["setting_toolboxleft"] = 'Toolbar left side by default';
$string["settingdesc_toolboxleft"] = 'Show the course and component toolbar on the left by default, instead of the right side of the screen.';
$string["setting_toolboxcoursesonly"] = 'Show only the courses in the toolbox';
$string["settingdesc_toolboxcoursesonly"] = 'Hide the badges and flow tabs in the toolbox and show only the courses.';
$string["setting_showprevnextarrows"] = 'Show arrows next to student selector dropdowns';
$string["settingdesc_showprevnextarrows"] = 'Show arrows for previous and next student in the student selector in coach and view mode.';
$string["drophere"] = "Drop here";
$string["infofield_position_above"] = 'Above course results';

View File

@ -128,12 +128,12 @@ $string["settingdesc_infofields_heading"] = 'Kies tot 5 extra velden om in het c
$string["setting_hivizdropslots"] = 'Extra zichtbare sleepvelden';
$string["settingdesc_hivizdropslots"] = 'Maak de velden waar cursussen heen gesleept kunnen worden extra goed zichtbaar.';
$string["setting_toolboxleft"] = 'Toolbox standaard links';
$string["settingdesc_toolboxleft"] = 'Toon de toolbox met cursussen en componenten standaard links in plaats van rechts.';
$string["setting_toolboxcoursesonly"] = 'Toon alleen cursussen in toolbox';
$string["settingdesc_toolboxcoursesonly"] = 'Verberg de tabbladen "flow" en "badges" in de toolbox en toon alleen de cursussen.';
$string["setting_showprevnextarrows"] = 'Toon pijltjes naast de studentselectie drop-down';
$string["settingdesc_showprevnextarrows"] = 'Laat pijltjes zien voor de vorige en volgende student naast de drop-down box om een student te selecteren.';
$string["drophere"] = "Sleep hierheen";
$string["infofield_position_above"] = 'Boven cursusresultaten';

View File

@ -150,6 +150,12 @@ if ($hassiteconfig) {
false,
));
$page->add(new admin_setting_configcheckbox('local_treestudyplan/showprevnextarrows',
get_string('setting_showprevnextarrows', 'local_treestudyplan'),
get_string('settingdesc_showprevnextarrows', 'local_treestudyplan'),
true,
));
$page->add(new admin_setting_configcheckbox('local_treestudyplan/copystudylinesnewpage',
get_string('setting_copystudylinesnewpage', 'local_treestudyplan'),
get_string('settingdesc_copystudylinesnewpage', 'local_treestudyplan'),
@ -234,6 +240,7 @@ if ($hassiteconfig) {
get_string('setting_competency_heading', 'local_treestudyplan'),
get_string('settingdesc_competency_heading', 'local_treestudyplan')
));
$page->add(new admin_setting_configtext('local_treestudyplan/competency_thresh_completed',
get_string('setting_competency_thresh_completed', 'local_treestudyplan'),
get_string('settingdesc_competency_thresh_completed', 'local_treestudyplan'),