|
1 | 1 | <template> |
2 | | - <div class="navigation"> |
3 | | - |
4 | | - </div> |
| 2 | + <div class="navigation"></div> |
5 | 3 | </template> |
6 | 4 |
|
7 | 5 | <script> |
8 | | -import EndNavigationModal from './EndNavigationModal'; |
9 | | -import { Carousel, Slide } from 'vue-carousel'; |
10 | | -
|
11 | | -/** |
12 | | - * @vue |
13 | | - */ |
14 | 6 | export default { |
15 | | - components: { |
16 | | - EndNavigationModal, |
17 | | - Carousel, |
18 | | - Slide |
19 | | - }, |
20 | 7 | data() { |
21 | 8 | return { |
22 | | - isNavigationLocked: false |
| 9 | + num: 100 |
23 | 10 | }; |
24 | 11 | }, |
25 | 12 | computed: { |
26 | | - isNavigationVisible() { |
27 | | - return this.$store.getters.isNavigationVisible; |
28 | | - }, |
29 | | - isEndNavigationModalVisible() { |
30 | | - return this.$store.getters.isEndNavigationModalVisible; |
31 | | - }, |
32 | | - activeSection() { |
33 | | - return this.$store.getters.activeSection; |
34 | | - }, |
35 | | - activeSubSection() { |
36 | | - return this.$store.getters.activeSubSection; |
37 | | - }, |
38 | | - sections() { |
39 | | - return this.$sections; |
40 | | - }, |
41 | | - sectionsWithoutProfiSubviews() { |
42 | | - return this.$sectionsWithoutProfiSubviews; |
| 13 | + testComputed() { |
| 14 | + return this.num * 5; |
43 | 15 | } |
44 | 16 | }, |
45 | 17 | methods: { |
46 | | - formatSubViewNumber(index) { |
47 | | - return index < 9 ? `0${index + 1}` : index + 1; |
48 | | - }, |
49 | | - calcProgressbarWidth() { |
50 | | - const activeSectionWidth = this.sectionsWithoutProfiSubviews[this.activeSection].subviews.length; |
51 | | - let barWidth = 18; |
52 | | - if (activeSectionWidth < 10) { |
53 | | - barWidth = 40; |
54 | | - } else if (activeSectionWidth < 15) { |
55 | | - barWidth = 30; |
56 | | - } |
57 | | - return barWidth; |
58 | | - }, |
59 | | - resetActiveSubsection() { |
60 | | - this.$store.dispatch( |
61 | | - 'setActiveSubSection', |
62 | | - this.sectionsWithoutProfiSubviews[this.activeSection].subviews[0].meta.index |
63 | | - ); |
64 | | - }, |
65 | | - resetNavigation() { |
66 | | - this.toggleCloseNavigationModal(); |
67 | | - this.toggleNav(); |
68 | | - this.$router.push({ |
69 | | - path: '/' |
70 | | - }); |
71 | | - }, |
72 | | - toggleNav() { |
73 | | - if (!this.isNavigationLocked) { |
74 | | - this.$store.dispatch('toggleIsNavigationVisible'); |
75 | | - } |
76 | | - }, |
77 | | - toggleCloseNavigationModal() { |
78 | | - if (!this.isNavigationLocked) { |
79 | | - this.$store.dispatch('toggleIsEndNavigationModalVisible'); |
80 | | - } |
81 | | - }, |
82 | | - /** |
83 | | - * @param {Number} index Number of the section to display |
84 | | - */ |
85 | | - setActiveSection(index) { |
86 | | - this.$store.dispatch('setActiveSection', index); |
87 | | - this.$store.dispatch('setActiveSubSection', 0); |
88 | | - }, |
89 | | - /** |
90 | | - * @param {Number} index Number of the subsection to display |
91 | | - */ |
92 | | - setActiveSubSection(index) { |
93 | | - this.$store.dispatch('setActiveSubSection', index); |
94 | | - }, |
95 | | - /** |
96 | | - * Navigate to the next subsection |
97 | | - */ |
98 | | - nextSubsection() { |
99 | | - if (!this.isNavigationLocked) { |
100 | | - if (this.activeSubSection < this.$sections[this.activeSection].subviews.length - 1) { |
101 | | - this.$store.dispatch('setActiveSubSection', this.activeSubSection + 1); |
102 | | - this.$router.push({ |
103 | | - path: `/${this.sections[this.activeSection].path}/${ |
104 | | - this.sections[this.activeSection].subviews[this.activeSubSection].path |
105 | | - }` |
106 | | - }); |
107 | | - } else { |
108 | | - this.$router.push({ |
109 | | - path: '/pyramid' |
110 | | - }); |
111 | | - } |
112 | | - } |
113 | | - }, |
114 | 18 | /** |
115 | | - * Navigate to the prevoius subsection |
| 19 | + * @param {number} num - |
116 | 20 | */ |
117 | | - previousSubsection() { |
118 | | - if (!this.isNavigationLocked) { |
119 | | - if (this.activeSubSection > 0) { |
120 | | - this.$store.dispatch('setActiveSubSection', this.activeSubSection - 1); |
121 | | - this.$router.push({ |
122 | | - path: `/${this.sections[this.activeSection].path}/${ |
123 | | - this.sections[this.activeSection].subviews[this.activeSubSection].path |
124 | | - }` |
125 | | - }); |
126 | | - } |
127 | | - } |
| 21 | + getNumber(num) { |
| 22 | + return num; |
128 | 23 | } |
129 | 24 | }, |
130 | | - created() { |
131 | | - this.$root.$on('toggle-paintable-screen', isPainterActive => { |
132 | | - this.isNavigationLocked = isPainterActive; |
133 | | - }); |
134 | | - } |
| 25 | + created() {} |
135 | 26 | }; |
136 | 27 | </script> |
137 | 28 |
|
138 | | -<style lang="scss" scoped> |
139 | | -</style> |
| 29 | +<style lang="scss" scoped></style> |
0 commit comments