-
Notifications
You must be signed in to change notification settings - Fork 32
Wistia widget #88
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wistia widget #88
Conversation
@@ -0,0 +1,473 @@ | |||
/* Contentful Widgets */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like a hard copy of cf-widget-api.css
.
It would be more intuitive if you would just reference it or let a task to build the widget copy it. Check out some of the other examples for inspiration :)
@DanweDE Done! @zeusdeux @geigerzaehler would be great if someone could have a look! |
Could you add the example to the main readme? |
|
||
- Start a local server (replace your port if needed) | ||
```bash | ||
python -m SimpleHTTPServer 3030 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a npm run widget:serve
task if I’m not mistaken. So do we really need this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point. I will remove the widget:serve as it is not working correctly with the html plugin I use with webpack.
onValueChanged() { | ||
|
||
if (this.widgetApi && this.inputEl) { | ||
console.log(this.widgetApi.field.getValue()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this a debugging artefact?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed.
this.widgetApi.field.onValueChanged(this.onValueChanged.bind(this)); | ||
|
||
// Resize iframe in Contenful UI. | ||
this.widgetApi.window.updateHeight(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this method and make it part of the constructor. This way we can always assume that this.widgetApi
is set and remove some checks.
LGTM. Please squash before merging |
Initial commit of the wistia example widget.