chromic_pdf icon indicating copy to clipboard operation
chromic_pdf copied to clipboard

Timezone override

Open CaseyInHaengsin opened this issue 10 months ago • 2 comments

Hello,

I have a use case where I need to render pages with different time zones; I found that this is possible via Emulation.setTimezoneOverride. Are you open to a PR that would add support for this functionality?

CaseyInHaengsin avatar Feb 27 '25 20:02 CaseyInHaengsin

In the Navigate protocol as a set_timezone option perhaps? Sure.

Be aware there's a "hidden feature" that allows you to supply custom protocols as well, which would make this task rather easy to do without changes to ChromicPDF

  • https://github.com/bitcrowd/chromic_pdf/blob/main/CHANGELOG.md#added
  • https://github.com/bitcrowd/chromic_pdf/blob/main/test/integration/custom_protocol_test.exs#L7-L16

but also open to add this as a new option

maltoe avatar Feb 28 '25 10:02 maltoe

Thank you, @maltoe! I am open to using the hidden feature if that makes more sense. I did want to attempt implementing the set_timezone option. I'm definitely open to feedback/suggestions/teasing on PR #338.

CaseyInHaengsin avatar Mar 03 '25 14:03 CaseyInHaengsin