Skip to content
This repository has been archived by the owner on Feb 20, 2023. It is now read-only.

For #3709: Add save to PDF UI. #27257

Merged
merged 1 commit into from Oct 5, 2022
Merged

Conversation

Amejia481
Copy link
Contributor

@Amejia481 Amejia481 commented Oct 3, 2022

https://www.figma.com/file/4TFvx6UlVO127bubv1WZKZ/Print-to-PDF-%2F-Share-Sheet?node-id=438%3A19971

image

We still need to land https://bugzilla.mozilla.org/show_bug.cgi?id=1784554 for improving the long time when the PDF is requested.

Pull Request checklist

  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Screenshots: This PR includes screenshots or GIFs of the changes made or an explanation of why it does not
  • Accessibility: The code in this PR follows accessibility best practices or does not include any user facing features. In addition, it includes a screenshot of a successful accessibility scan to ensure no new defects are added to the product.

QA

  • [] QA Needed

To download an APK when reviewing a PR (after all CI tasks finished running):

  1. Click on Checks at the top of the PR page.
  2. Click on the firefoxci-taskcluster group on the left to expand all tasks.
  3. Click on the build-debug task.
  4. Click on View task in Taskcluster in the new DETAILS section.
  5. The APK links should be on the right side of the screen, named for each CPU architecture.

GitHub Automation

Fixes #3709

@Amejia481 Amejia481 requested review from a team as code owners October 3, 2022 19:49
@Amejia481 Amejia481 requested review from jonalmeida and removed request for a team October 3, 2022 19:51
@Amejia481 Amejia481 added the needs:review PRs that need to be reviewed label Oct 3, 2022
@Amejia481
Copy link
Contributor Author

Amejia481 commented Oct 3, 2022

Request for data collection review

  1. What questions will you answer with this data?
    This data will provide statistics regarding the usage of the save to PDF feature.

  2. Why does Mozilla need to answer these questions? Are there benefits for users? Do we need this information to address product or business requirements?
    This will give us an understanding of the usage of the save to PDF functionality, we will use the info for improving the user experience.

  3. What alternative methods did you consider to answer these questions? Why were they not sufficient?
    No alternative is available to answer this question.

  4. Can current instrumentation answer these questions?
    No.

  5. List all proposed measurements and indicate the category of data collection for each measurement, using the Firefox data collection categories found on the Mozilla wiki.

Measurement Description Data Collection Category Tracking Bug #
Save to PDF button clicks category 2 - Interaction data #3709
  1. Please provide a link to the documentation for this data collection which describes the ultimate data set in a public, complete, and accurate way.
    https://dictionary.telemetry.mozilla.org/apps/fenix


  2. How long will this data be collected? Choose one of the following:
    Up until version 122, with the option to renew at that point.


  3. What populations will you measure?
    No filters - all locales, channels, etc. Currently, the button is visible only in Nightly.

  4. If this data collection is default on, what is the opt-out mechanism for users?
    Default Glean SDK opt-out mechanism.

  5. Please provide a general description of how you will analyze this data.
    Glean / Amplitude

  6. Where do you intend to share the results of your analysis?
    Only on Glean, Amplitude and with mobile teams.

  7. Is there a third-party tool (i.e. not Telemetry) that you are proposing to use for this data collection?
    No third-party tool will use this data.

Copy link
Contributor

@jonalmeida jonalmeida left a comment

Choose a reason for hiding this comment

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

Mostly nits and few design fixes, but once they are fixed along with Matt's comments addressed, I think this looks good to land. Happy to re-review if needed. 🙂

app/metrics.yaml Outdated Show resolved Hide resolved
app/metrics.yaml Outdated
expires: 122
metadata:
tags:
- ContextMenu
Copy link
Contributor

Choose a reason for hiding this comment

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

The ContextMenu is the tag for the press-and-hold menu that shows up in web content. See feature-contextmenu.

Suggested change
- ContextMenu
- Sharing

app/src/main/res/navigation/nav_graph.xml Show resolved Hide resolved
app/src/main/java/org/mozilla/fenix/share/SaveToPDFItem.kt Outdated Show resolved Hide resolved
app/src/main/java/org/mozilla/fenix/share/SaveToPDFItem.kt Outdated Show resolved Hide resolved
app/src/main/java/org/mozilla/fenix/share/ShareFragment.kt Outdated Show resolved Hide resolved
app/src/main/res/layout/fragment_share.xml Outdated Show resolved Hide resolved
@Amejia481
Copy link
Contributor Author

Thanks all for all the feedback, I address the comment and updated the PR, when you have a moment please take a look :)

setContent {
FirefoxTheme {
SaveToPDFItem {
shareInteractor.onSaveToPDF(tabId = args.sessionId)
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: maybe it's just me, but it looks strange having the lambda out of the parenthesis, in a "tree" of composables content. 😅 .
Maybe you could leave it on the same row as SaveToPDFItem so it looks more like a method call rather than an "inside" composable.

Copy link
Contributor

@mcarare mcarare left a comment

Choose a reason for hiding this comment

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

LGTM!

@jonalmeida jonalmeida added needs:data-review PR is awaiting a data review and removed needs:review PRs that need to be reviewed labels Oct 5, 2022
@jonalmeida jonalmeida added the pr:approved PR that has been approved label Oct 5, 2022
@Amejia481 Amejia481 force-pushed the for-3709 branch 3 times, most recently from a00c206 to 636342c Compare October 5, 2022 17:54
@rocketsroger
Copy link
Contributor

Request for data collection review

1. What questions will you answer with this data?
   This data will provide statistics regarding the usage of the save to PDF feature.

2. Why does Mozilla need to answer these questions? Are there benefits for users? Do we need this information to address product or business requirements?
   This will give us an understanding of the usage of the save to PDF functionality, we will use the info for improving the user experience.

3. What alternative methods did you consider to answer these questions? Why were they not sufficient?
   No alternative is available to answer this question.

4. Can current instrumentation answer these questions?
   No.

5. List all proposed measurements and indicate the category of data collection for each measurement, using the Firefox data collection categories found on the Mozilla wiki.

Measurement Description Data Collection Category Tracking Bug #
Save to PDF button clicks category 2 - Interaction data #3709

6. Please provide a link to the documentation for this data collection which describes the ultimate data set in a public, complete, and accurate way.
   [https://dictionary.telemetry.mozilla.org/apps/fenix
   ](https://dictionary.telemetry.mozilla.org/apps/fenix%E2%80%A8)

7. How long will this data be collected? Choose one of the following:
   Up until version 122, with the option to renew at that point.

8. What populations will you measure?
   No filters - all locales, channels, etc. Currently, the button is visible only in Nightly.

9. If this data collection is default on, what is the opt-out mechanism for users?
   Default Glean SDK opt-out mechanism.

10. Please provide a general description of how you will analyze this data.
    Glean / Amplitude

11. Where do you intend to share the results of your analysis?
    Only on Glean, Amplitude and with mobile teams.

12. Is there a third-party tool (i.e. not Telemetry) that you are proposing to use for this data collection?
    No third-party tool will use this data.

Data Review

  1. Is there or will there be documentation that describes the schema for the ultimate data set in a public, complete, and accurate way?

Yes, through the metrics.yaml file and the Glean Dictionary

  1. Is there a control mechanism that allows the user to turn the data collection on and off?

Yes, through the "Send Usage Data" preference in the application settings

  1. If the request is for permanent data collection, is there someone who will monitor the data over time?

N/A, collection set to end or be renewed by version 122

  1. Using the category system of data types on the Mozilla wiki, what collection type of data do the requested measurements fall under?

Category 2, Interaction data

  1. Is the data collection request for default-on or default-off?

default-on

  1. Does the instrumentation include the addition of any new identifiers?

No

  1. Is the data collection covered by the existing Firefox privacy notice?

Yes

  1. Does the data collection use a third-party collection tool?

No

Result

data-review+

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
pr:approved PR that has been approved
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Save as PDF option
7 participants