Skip to content

Commit

Permalink
fix marked v4.1.0 breaking change
Browse files Browse the repository at this point in the history
fix marked v4.1.0 breaking change
  • Loading branch information
tabdunabi authored Sep 22, 2022
2 parents 2ff20ba + 9d0368e commit 388c053
Show file tree
Hide file tree
Showing 6 changed files with 49 additions and 47 deletions.
2 changes: 2 additions & 0 deletions lambda/fulfillment/lib/middleware/lex.js
Original file line number Diff line number Diff line change
Expand Up @@ -505,3 +505,5 @@ exports.assemble=function(request,response){
qnabot.log('Lex response:',JSON.stringify(out,null,2))
return out
}


Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
python-dateutil==2.8.1
urllib3==1.26.5
canvasapi==2.2.0
canvasapi==3.0.0
certifi==2020.12.5
chardet==5.0.0
idna==2.10
Expand Down
18 changes: 9 additions & 9 deletions website/js/components/alexa/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
v-layout(column )
v-flex
v-card
v-card-title
v-card-title
h3 Alexa Instructions
v-card-text(class="pa-0")
v-stepper(v-model="stepNumber" class="elevation-0")
Expand All @@ -25,9 +25,9 @@
v-layout(row)
v-flex(xs1)
v-btn(
@click="stepNumber--" v-if="index>0"
@click="stepNumber--" v-if="index>0"
style="height:100%"
left)
left)
v-icon keyboard_arrow_left
v-flex(xs10)
v-container
Expand All @@ -54,7 +54,7 @@
v-btn(
@click="stepNumber++" v-if="index+1<steps.length"
style="height:100%"
right)
right)
v-icon keyboard_arrow_right
</template>

Expand All @@ -67,7 +67,7 @@ var Promise=require('bluebird')
var markdown=require('marked')
var renderer=new markdown.Renderer()
renderer.link=function(href,title,text){
return `<a href="${href}" title="${title}" target="_blank">${text}</a>`
return `<a href="${href}" title="${title}" target="_blank">${text}</a>`
}
renderer.table=function(header,body){
return `<table class="pure-table"><thead>${header}</thead><tbody>${body}</tbody></table>`
Expand Down Expand Up @@ -105,25 +105,25 @@ module.exports={
{
steps:function(){
var self=this
return _.map(this.stepsRaw,function(x){
return _.map(this.stepsRaw,function(x){
var y=Object.assign({},x)
if(x.text){
var temp=handlebars.compile(x.text)
y.text=markdown(temp(self.$store.state.bot),{renderer})
y.text=markdown.parse(temp(self.$store.state.bot),{renderer})
}
return y
})
}
}
),
created:function(){
this.$store.dispatch('data/botinfo').catch(()=>null)
this.$store.dispatch('data/botinfo').catch(()=>null)
},
methods:{
copy:function(btn){
btn.loading=true
setTimeout(()=>btn.loading=false,1000)
}
}
}
}
</script>
38 changes: 19 additions & 19 deletions website/js/components/connect/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
v-layout(column )
v-flex
v-card
v-card-title
v-card-title
h3 Connect Instructions
v-card-text(class="pa-0")
v-stepper(v-model="stepNumber" class="elevation-0")
Expand All @@ -25,9 +25,9 @@
v-layout(row)
v-flex(xs1)
v-btn(
@click="stepNumber--" v-if="index>0"
@click="stepNumber--" v-if="index>0"
style="height:100%"
left)
left)
v-icon keyboard_arrow_left
v-flex(xs10)
v-container
Expand Down Expand Up @@ -56,7 +56,7 @@
v-btn(
@click="stepNumber++" v-if="index+1<steps.length"
style="height:100%"
right)
right)
v-icon keyboard_arrow_right
</template>

Expand All @@ -72,7 +72,7 @@ var renderer=new markdown.Renderer()
var axios=require('axios')
renderer.link=function(href,title,text){
return `<a href="${href}" title="${title}" target="_blank">${text}</a>`
return `<a href="${href}" title="${title}" target="_blank">${text}</a>`
}
renderer.table=function(header,body){
return `<table class="pure-table"><thead>${header}</thead><tbody>${body}</tbody></table>`
Expand Down Expand Up @@ -111,11 +111,11 @@ module.exports={
{
steps:function(){
var self=this
return _.map(this.stepsRaw,function(x){
return _.map(this.stepsRaw,function(x){
var y=Object.assign({},x)
if(x.text){
var temp=handlebars.compile(x.text)
y.text=markdown(temp(self.$store.state.bot),{renderer})
y.text=markdown.parse(temp(self.$store.state.bot),{renderer})
}
return y
})
Expand All @@ -125,7 +125,7 @@ module.exports={
updated: function () {
var self = this;
this.$nextTick(function () {
const downloadBlobAsFile = (function closure_shell() {
const a = document.createElement("a");
return function downloadBlobAsFile(blob, filename) {
Expand All @@ -142,7 +142,7 @@ module.exports={
for (var i = 0, linksLength = links.length; i < linksLength; i++) {
if (links[i].hostname != window.location.hostname) {
links[i].target = '_blank';
}
}
}
var button = document.getElementById("DownloadContactFlow");
if(button)
Expand All @@ -159,7 +159,7 @@ module.exports={
}
}
function poll(url){
console.log(url)
return self.$store.dispatch('api/getImport',{href: url})
Expand All @@ -177,9 +177,9 @@ module.exports={
ImportQuestionsStatus.innerHTML = "Complete";
btnImportQuestions.innerHTML = "Import Sample Questions and Answers";
}).then( result => {})
.catch(e =>
.catch(e =>
ImportQuestionsStatus.innerHTML = "Error Rebuilding LexBot. Please return to the Content Designer, correct the errors and REBUILD LEXBOT </br>" +
"LexBot Rebuild Error " + e
)
Expand All @@ -192,7 +192,7 @@ module.exports={
var btnImportQuestions = document.getElementById("ImportQuestions");
var ImportQuestionsStatus = document.getElementById("ImportQuestionsStatus");
if(btnImportQuestions){
btnImportQuestions.onclick = function() {
btnImportQuestions.disabled = true;
Expand All @@ -218,7 +218,7 @@ module.exports={
return self.$store.dispatch('api/startImport',{
qa:result.qna,
name:self.contactFlow.QnaFile
})
})
.then(results => {
Expand All @@ -235,8 +235,8 @@ module.exports={
}
}
var spanBot = document.getElementById("spnBotname")
if(spanBot)
Expand All @@ -248,16 +248,16 @@ module.exports={
},
created:function(){
this.$store.dispatch('data/botinfo').catch(()=>null)
this.$store.dispatch('data/botinfo').catch(()=>null)
},
methods:{
copy:function(btn){
btn.loading=true
setTimeout(()=>btn.loading=false,1000)
}
}
}
}
}
</script>
22 changes: 11 additions & 11 deletions website/js/components/genesys/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
v-layout(column )
v-flex
v-card
v-card-title
v-card-title
h3 Genesys Cloud CX Instructions
v-card-text(class="pa-0")
v-stepper(v-model="stepNumber" class="elevation-0")
Expand All @@ -25,9 +25,9 @@
v-layout(row)
v-flex(xs1)
v-btn(
@click="stepNumber--" v-if="index>0"
@click="stepNumber--" v-if="index>0"
style="height:100%"
left)
left)
v-icon keyboard_arrow_left
v-flex(xs10)
v-container
Expand Down Expand Up @@ -56,7 +56,7 @@
v-btn(
@click="stepNumber++" v-if="index+1<steps.length"
style="height:100%"
right)
right)
v-icon keyboard_arrow_right
</template>

Expand All @@ -72,7 +72,7 @@ var renderer=new markdown.Renderer()
var axios=require('axios')
renderer.link=function(href,title,text){
return `<a href="${href}" title="${title}" target="_blank">${text}</a>`
return `<a href="${href}" title="${title}" target="_blank">${text}</a>`
}
renderer.table=function(header,body){
return `<table class="pure-table"><thead>${header}</thead><tbody>${body}</tbody></table>`
Expand Down Expand Up @@ -101,11 +101,11 @@ module.exports={
{
steps:function(){
var self=this
return _.map(this.stepsRaw,function(x){
return _.map(this.stepsRaw,function(x){
var y=Object.assign({},x)
if(x.text){
var temp=handlebars.compile(x.text)
y.text=markdown(temp(self.$store.state.bot),{renderer})
y.text=markdown.parse(temp(self.$store.state.bot),{renderer})
}
return y
})
Expand All @@ -131,7 +131,7 @@ module.exports={
for (var i = 0, linksLength = links.length; i < linksLength; i++) {
if (links[i].hostname != window.location.hostname) {
links[i].target = '_blank';
}
}
}
var button = document.getElementById("DownloadInboundCallFlow");
if(button)
Expand All @@ -158,16 +158,16 @@ module.exports={
},
created:function(){
this.$store.dispatch('data/botinfo').catch(()=>null)
this.$store.dispatch('data/botinfo').catch(()=>null)
},
methods:{
copy:function(btn){
btn.loading=true
setTimeout(()=>btn.loading=false,1000)
}
}
}
}
}
</script>
14 changes: 7 additions & 7 deletions website/js/components/hooks/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
v-layout(column )
v-flex
v-card
v-card-title
v-card-title
h3 Lambda Hook Instructions
v-card-text(class="pa-0")
v-stepper(v-model="stepNumber" class="elevation-0")
Expand Down Expand Up @@ -59,7 +59,7 @@ markdown.setOptions({
});
var renderer=new markdown.Renderer()
renderer.link=function(href,title,text){
return `<a href="${href}" title="${title}" target="_blank">${text}</a>`
return `<a href="${href}" title="${title}" target="_blank">${text}</a>`
}
var handlebars=require('handlebars')
var clipboard=require('clipboard')
Expand All @@ -81,22 +81,22 @@ module.exports={
Vuex.mapState([
'bot'
]),
{
steps:function(){
var self=this
return _.map(this.stepsRaw,function(x){
return _.map(this.stepsRaw,function(x){
var temp=handlebars.compile(x.text)
var y=Object.assign({},x)
y.text=markdown(temp(self.$store.state.bot),{renderer})
y.text=markdown.parse(temp(self.$store.state.bot),{renderer})
return y
})
}
}
),
created:function(){
var self=this
this.$store.dispatch('data/botinfo').catch(()=>null)
this.$store.dispatch('data/botinfo').catch(()=>null)
var role=new clipboard('#Role',{
text:function(){
return self.$store.state.bot.lambdaRole
Expand All @@ -123,6 +123,6 @@ module.exports={
btn.loading=true
setTimeout(()=>btn.loading=false,1000)
}
}
}
}
</script>

0 comments on commit 388c053

Please sign in to comment.