Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
setTimeout(() => {
this.emit('init', input.value)
autosize.update(input);
})
public componentDidUpdate() {
if (this.textareaDom && this.textareaDom.value.length === 0) {
autosize.update(this.textareaDom);
}
}
export default function runDemo(app) {
const {attributePicker} = app
const {embedCodeInput, pluginDetailsForm} = app.refs
const {locationSelect} = attributePicker.refs
embedCodeInput.autofocus = false
embedCodeInput.value = script
autosize.update(embedCodeInput)
attributePicker.parseInput()
locationSelect.value = "body"
const {option_1} = app.entities
option_1.title = "Twitter username"
attributePicker.toggleEntityTracking(option_1.element)
const fields = {
"[name='email']": "demo@instantwordpressplugin.com",
"[name='app[title]']": "Nectar Ninja",
"[name='app[description]']": "Send website notifications via Twitter!",
"[name='app[metadata][description]']": `Let users know of new features, deals or downtimes.
Dead-simple, no signup required. Yes, it's free.`
}
export default function runDemo(app) {
const {embedCodeInput, locationSelect, pluginDetailsForm} = app.refs
embedCodeInput.autofocus = false
embedCodeInput.value = script
autosize.update(embedCodeInput)
app.parseInput()
locationSelect.value = "body"
const {option_7, option_8, option_9} = app.entities
option_7.title = "Latitude"
option_8.title = "Longitude"
option_9.title = "Description"
app.toggleEntityTracking(option_7.element)
app.toggleEntityTracking(option_8.element)
app.toggleEntityTracking(option_9.element)
const fields = {
"[name='app[title]']": "Forecast.io",
setTimeout(() => {
autosize.update($('.auto-size'))
}, 0)
updater() {
autosize.update(el);
},
});
componentDidUpdate(prevProps,prevState) { //eslint-disable-line no-unused-vars
if (prevState.shareUrl !== this.state.shareUrl) {
this.selectAllFromNode(this.linkInput);
} else if (prevState.embed.code !== this.state.embed.code) {
this.selectAllFromNode(this.embedCodeInput);
}
autosize.update(this.embedCodeInput);
}
this.$nextTick(function() {
const textarea = document.querySelector(`#js-comment-${this.comment.id}`)
autosize.update(textarea)
$(`.comment-id-${this.comment.id}`).trigger('input');
})
},
_changed() {
autosize.update(this.textarea);
if (this.props.onChange) {
this.props.onChange();
}
}
resize() {
autosize.update( this.refs.textarea );
}