Skip to content

Commit 5346fe3

Browse files
committed
Migrate to ibm-watson dependancy
1 parent 36baf36 commit 5346fe3

File tree

3 files changed

+218
-166
lines changed

3 files changed

+218
-166
lines changed

services/text_to_speech/v1-corpus-builder.html

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,6 @@
4444
</div>
4545

4646
<div class="form-row credentials">
47-
<label>&nbsp;</label>
48-
<input type="checkbox" id="node-input-default-endpoint" style="display: inline-block; width: auto; vertical-align: top;">
49-
<label for="node-input-default-endpoint" style="width: 70%;"> Use Default Service Endpoint</label>
50-
</div>
51-
<div class="form-row">
5247
<label for="node-input-service-endpoint"><i class="fa fa-tag"></i> Service Endpoint</label>
5348
<input type="text" id="node-input-service-endpoint" placeholder="https://stream.watsonplatform.net/text-to-speech/api">
5449
</div>
@@ -233,7 +228,7 @@
233228
var k = $('#node-input-apikey').val();
234229

235230
if ( (k && k.length) || (u && u.length && p) ) {
236-
if (!ttsv1qbb.voices) {
231+
if (!ttsv1qbb.voices) {;
237232
ttsv1qbb.getVoices();
238233
}
239234
}
@@ -382,14 +377,6 @@
382377
}
383378
});
384379

385-
$('#node-input-default-endpoint').change(function () {
386-
var checked = $('#node-input-default-endpoint').prop('checked')
387-
if (checked) {
388-
$('#node-input-service-endpoint').parent().hide();
389-
} else {
390-
$('#node-input-service-endpoint').parent().show();
391-
}
392-
});
393380
}
394381

395382
// The dynamic nature of the selection fields in this node has caused problems.
@@ -496,9 +483,8 @@
496483
var e = $('#node-input-service-endpoint').val();
497484
var creds = {un: u, pwd: p, key: k};
498485

499-
if (! $('#node-input-default-endpoint').prop('checked')) {
500-
creds.e = e;
501-
}
486+
creds.e = e;
487+
502488
$.getJSON('watson-text-to-speech-v1-query-builder/voices/',creds)
503489
.done(function (data) {
504490
if (data.error) {
@@ -565,8 +551,7 @@
565551
'tts-voice-or-custom' : {value: ''},
566552
'tts-voice': {value: ""},
567553
'tts-voicehidden': {value: ""},
568-
'default-endpoint' :{value: true},
569-
'service-endpoint' :{value: 'https://stream.watsonplatform.net/text-to-speech/api'}
554+
'service-endpoint' :{value: ''}
570555
},
571556
credentials: {
572557
username: {type:'text'} //,

0 commit comments

Comments
 (0)