Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

Adding a code sample of how the modal widget can be initialized #4269

Merged
merged 9 commits into from
Apr 17, 2019

Conversation

eduard13
Copy link
Contributor

@eduard13 eduard13 commented Apr 17, 2019

Purpose of this PR

This PR is an improvement of Modal widget, which provides an example of how the modal can be used and how the widget's options can be passed during initialization. Also the example's result preview is provided.
Moreover, an additional (important) widget's option was added to the documentation.

Affected URLs

whatsnew
Added a new code sample showing how to initialize a modal widget and pass options to it.

@devops-devdocs
Copy link
Collaborator

An admin must run tests on this PR before it can be merged.

@rogyar rogyar self-assigned this Apr 17, 2019
@rogyar
Copy link
Contributor

rogyar commented Apr 17, 2019

@rogyar rogyar added the Technical Updates to the code or processes that alter the technical content of the doc label Apr 17, 2019
@jeff-matthews jeff-matthews added 2.1.x 2.3.x Magento 2.3 related changes 2.x Major Update Significant original updates to existing content and removed Technical Updates to the code or processes that alter the technical content of the doc labels Apr 17, 2019
@eduard13
Copy link
Contributor Author

Hi @jeff-matthews, the suggested changes were applied.
Thank you for the review.

Copy link
Contributor

@jeff-matthews jeff-matthews left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@eduard13, are all three image files the same? If so, we only need one image and it should be saved to devdocs/common/images/. there's no need to replicate the same image.

@eduard13
Copy link
Contributor Author

@jeff-matthews, yes they are. Interesting, I didn't know about that, thank you for noticing.
Please note that I moved it into the mentioned folder, optimized it and removed the other ones.
Thank you.

@jeff-matthews
Copy link
Contributor

Perfect @eduard13! Thank you for taking the extra step to optimize the image as well. We haven't had good contributor guidelines around doing that in the past, but we'll create some soon. Thank you for being proactive.

@jeff-matthews
Copy link
Contributor

running tests

@jeff-matthews
Copy link
Contributor

Tests failed. Here's the log:

+ rake test:cicd
�[35mChecking links with htmlproofer...�[0m
Running ["LinkChecker::DoubleSlashCheck", "ImageCheck", "LinkCheck", "ScriptCheck"] on ["_site"] on *.html... 

Ran on 3824 files!

- internal image /common/images/js/widgets/modal-widget-result.png does not exist
  *  _site/guides/v2.1/javascript-dev-guide/widgets/widget_modal.html (line 2368)
  *  _site/guides/v2.2/javascript-dev-guide/widgets/widget_modal.html (line 2430)
  *  _site/guides/v2.3/javascript-dev-guide/widgets/widget_modal.html (line 2486)
rake aborted!
HTML-Proofer found 3 failures!```

Copy link
Contributor

@jeff-matthews jeff-matthews left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of adding the image to common/images/js/widget, please add to common/images/widget.

Co-Authored-By: eduard13 <e.chitoraga@atwix.com>
@jeff-matthews
Copy link
Contributor

running tests

@eduard13
Copy link
Contributor Author

@jeff-matthews now it should be fine I guess.

@jeff-matthews
Copy link
Contributor

Yes, I think so too. Almost finished running tests.

@jeff-matthews
Copy link
Contributor

running tests

@jeff-matthews jeff-matthews merged commit 5261639 into magento:master Apr 17, 2019
@ghost
Copy link

ghost commented Apr 17, 2019

Hi @eduard13, thank you for your contribution!
Please, complete Contribution Survey, it will take less than a minute.
Your feedback will help us to improve contribution process.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
2.x 2.1.x 2.3.x Magento 2.3 related changes Major Update Significant original updates to existing content Partner: Atwix partners-contribution PR created by Magento partner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants