Skip to content
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

implemented https://w3c.github.io/webdriver/#print currently supporte… #1275

Merged
merged 1 commit into from
Aug 31, 2020
Merged

implemented https://w3c.github.io/webdriver/#print currently supporte… #1275

merged 1 commit into from
Aug 31, 2020

Conversation

babusekaran
Copy link
Contributor

Implemented https://w3c.github.io/webdriver/#print as pdf(), streamlined pdf() API between DevToolsDriver and WebDriver.

pdf({})

currently supported in chrome > 85 with chromedriver > 85 and only in headless mode

sample input json to pdf() supported as per w3c spec

 {
      'orientation': 'landscape',
      'scale': 1.1,
      'margin': {
        'top': 1.1,
        'bottom': 2.2,
        'left': 3.3,
        'right': 4.4
       },
      'background': true,
      'shrinkToFit': false,
      'pageRanges': [1],
      'page': {
       'width': 15.6,
       'height': 20.6
     }
 }

ref:
https://chromedriver.storage.googleapis.com/85.0.4183.83/notes.txt
https://bugs.chromium.org/p/chromedriver/issues/detail?id=3481&q=3481&can=2
https://w3c.github.io/webdriver/#print

  • Relevant Issues : (compulsory)
  • Relevant PRs : (optional)
  • Type of change :
    • New feature
    • Bug fix for existing feature
    • Code quality improvement
    • Addition or Improvement of tests
    • Addition or Improvement of documentation

@ptrthomas ptrthomas merged commit cd60618 into karatelabs:develop Aug 31, 2020
@ptrthomas
Copy link
Member

@babusekaran thank you ! can you suggest if a README change is needed as well

@babusekaran
Copy link
Contributor Author

Sure @ptrthomas, can you please let me know if below-added documentation is sufficient

babusekaran@025bd69

@ptrthomas
Copy link
Member

@babusekaran yes that is exactly what I was thinking

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.

2 participants