Skip to content

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

Closed
wants to merge 17 commits into from
Closed

Wistia widget #88

wants to merge 17 commits into from

Conversation

floelhoeffel
Copy link
Contributor

Initial commit of the wistia example widget.

@@ -0,0 +1,473 @@
/* Contentful Widgets */
Copy link
Contributor

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 :)

@floelhoeffel
Copy link
Contributor Author

@DanweDE Done!

@zeusdeux @geigerzaehler would be great if someone could have a look!

@geigerzaehler
Copy link

Could you add the example to the main readme?


- Start a local server (replace your port if needed)
```bash
python -m SimpleHTTPServer 3030

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?

Copy link
Contributor Author

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());
Copy link
Contributor

@zeusdeux zeusdeux Apr 25, 2016

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?

Copy link
Contributor Author

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();

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.

@geigerzaehler
Copy link

LGTM. Please squash before merging

@geigerzaehler geigerzaehler deleted the wistia-widget branch September 1, 2016 09:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants