diff --git a/src/components/Header.vue b/src/components/Header.vue index 7c691e32a8782fc0f1f4d96706f0b37fff873f24..173cb588fecb2df5e06d68f35591c668344cbbe3 100644 --- a/src/components/Header.vue +++ b/src/components/Header.vue @@ -64,9 +64,6 @@ export default { }); return a_forms.join(', ') }, - inflect_tooltip: function() { - return this.dictionary == 'bm' ? 'Klikk for å se bøyinger' : 'Klikk for å sjå bøyingar' - }, dict_label: function() { return { 'bm': 'bokmålsordboka', @@ -93,15 +90,6 @@ export default { }) return hgnos.join(", ") }, - inflection_button_text: function() { - return { - "bm": {false: "Se bøyning", true: "Skjul bøyning"}, - "nn": {false: "Sjå bøying", true: "Skjul bøying"} - }[this.dictionary][this.inflection_expanded] - }, - inflection_arrow: function() { - return this.inflection_expanded? "expand_less" : "expand_more" - }, group_list: function() { return helpers.group_list(this.lemmas, this.dictionary) }, @@ -142,13 +130,6 @@ export default { } ) }, - lemmas_with_word_class_and_lang: function() { - return this.lemmas.map(lemma => Object.assign({language: this.dictionary == 'bm' ? 'nob' : 'nno', - word_class: lemma.paradigm_info[0].inflection_group.split('_')[0]}, lemma)) - }, - inflected: function() { - return this.lemmas.reduce((acc, lemma) => acc += lemma.paradigm_info.reduce((acc2, digm) => acc2 += digm.inflection.length, 0), 0) > 0 - }, split_inf: function() { return this.lemmas[0].split_inf } @@ -158,19 +139,7 @@ export default { }, data: function() { return { - inflect_reported: false, menu: false, - inflection_expanded: false - } - }, - methods: { - toggle: function() { - this.inflection_expanded = !this.inflection_expanded - if (! this.inflect_reported) { - this.$plausible.trackEvent('open inflection', {props: {article: `/${this.dictionary}/${this.article_id}/${this.lemmas[0].lemma}`}}) - } - this.inflect_reported = true - } } } @@ -214,86 +183,12 @@ article h2.secondary_header { } -.show-inflection .v-icon { - color: var(--v-primary-base) !important; -} - - -.inflection-arrow { - position: absolute; - right: -4px; - margin-left: 3px; - font-size: 10px; -} - -@keyframes open { - 0% { - opacity: 0; - } - 100% { - opacity: 1; - } -} - -.inflection-canvas { - overflow-x: auto; - /*position: absolute;*/ - z-index: 5; - background-color: rgba(255, 255, 255, 0); - /*max-width: 100vw;*/ - padding-top: 10px; -} - - -.inflection-wrapper { - color: var(--v-text-base); - width: min-content; - font-size: 14px; - overflow-x: auto; - margin-top: 10px; -} - -#search_results .xs .inflection-wrapper, #search_results .sm .inflection-wrapper { - display: none; -} - -.context { - color: var(--v-primary-lighten4) !important; -} div.lemma { display: none; } -table { - border-collapse: collapse; - margin-top: 5px; - border-color: var(--v-primary-base); -} -th, td { - border: solid 1px; - padding: 5px; -} - -th { - background-color: var(--v-button-base); -} - -.infl-label { - text-align: center; - vertical-align: top; -} - -article:not(.righ_hand_column) .inflection-canvas { - left: -35px; -} - - -td.hilite { - background-color: var(--v-tertiary-base); - text-align: center -} .article_header { display: flex; diff --git a/src/components/InflectionButton.vue b/src/components/InflectionButton.vue index 4b912dbe30e523cb21260729f276e6ad1ee01d7f..72c3e0b11773b8e27fb1dab23830d6fe7a0f5afb 100644 --- a/src/components/InflectionButton.vue +++ b/src/components/InflectionButton.vue @@ -27,21 +27,6 @@ export default { article_id: Number }, computed: { - header_text: function() { - return this.lemmas.map(lemma => lemma.lemma).join(', ') - }, - secondary_header_text: function() { - let a_forms = [] - this.lemmas.forEach((lemma, i) => { - if (lemma.paradigm_info[0] && lemma.paradigm_info[0].inflection_group == 'VERB') { - let inf2 = lemma.paradigm_info[0].inflection[1] && lemma.paradigm_info[0].inflection[1].word_form - if (inf2 && inf2.length) { - a_forms.push(inf2) - } - } - }); - return a_forms.join(', ') - }, inflect_tooltip: function() { return this.dictionary == 'bm' ? 'Klikk for å se bøyinger' : 'Klikk for å sjå bøyingar' }, @@ -108,7 +93,6 @@ export default { data: function() { return { inflect_reported: false, - menu: false, inflection_expanded: false } }, @@ -127,47 +111,10 @@ export default { </script> <style> - - -article h2 { - padding-top: 4px; - padding-bottom: 0px; - font-family: Inria Serif; - font-size: 30px; -} - -article h2.secondary_header { - padding-top: 0px; - padding-bottom: 4px; -} - -.info-button { - margin-left: 6px; - margin-right: -2px; - height: 10px; - width: 10px; -} - -.word-classification { - text-decoration: underline dashed; -} - -.dict-label { - color: var(--v-primary-base) ; - font-weight: bold; - padding-left: 5px; - position: absolute; - top: 0px; - left: 15px; - font-variant-caps: all-small-caps; -} - - .show-inflection .v-icon { color: var(--v-primary-base) !important; } - .inflection-arrow { position: absolute; right: -4px; @@ -238,19 +185,9 @@ article:not(.righ_hand_column) .inflection-canvas { left: -35px; } - td.hilite { background-color: var(--v-tertiary-base); text-align: center } -.article_header { - display: flex; - align-items: baseline; -} - -.hgno { - padding-left: 3px; -} - </style>