Changeset 35528


Ignore:
Timestamp:
2021-09-29T15:47:16+13:00 (3 years ago)
Author:
cstephen
Message:

Fix text download. Only show WordTimingSelector in dev mode

Location:
main/trunk/model-interfaces-dev/atea/korero-maori-asr/src/components
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/model-interfaces-dev/atea/korero-maori-asr/src/components/TranscriptionItem.vue

    r35489 r35528  
    124124            const fileName = buildDownloadableFileName(this.transcription.fileName, "txt");
    125125
    126             const blob = new Blob([ this.transcription.transcription ], { type: "text/plain;charset=utf-8" });
     126            const blob = new Blob([ this.$refs.editor.words.map(w => w.word).join(" ") ], { type: "text/plain;charset=utf-8" });
    127127            saveAs(blob, fileName);
    128128        },
  • main/trunk/model-interfaces-dev/atea/korero-maori-asr/src/components/TranscriptionItemEditor.vue

    r35525 r35528  
    2020    </div>
    2121
    22     <word-timing-selector class="word-timing-selector" :surroundingWords="surroundingWords" :word="selectedWord" />
     22    <word-timing-selector class="word-timing-selector" :surroundingWords="surroundingWords" :word="selectedWord" v-if="isProduction" />
    2323
    2424    <div class="editor-controls">
     
    132132            words: [],
    133133            lastHighlightedWordIndex: 0,
    134             selectedIndex: 0
     134            selectedIndex: 0,
     135            isProduction: false
    135136        }
    136137    },
     
    369370    beforeMount() {
    370371        this.words = getWords(this.transcription);
     372        this.isProduction = process.env.NODE_ENV !== "production";
    371373    }
    372374}
Note: See TracChangeset for help on using the changeset viewer.