Skip to content

most used content (updated table) #51

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

Open
wants to merge 24 commits into
base: main
Choose a base branch
from

Conversation

toph-allen
Copy link
Contributor

@toph-allen toph-allen commented Mar 25, 2025

This PR contains the updated content usage dashboard.

  • Dogfood: https://rsc.radixu.com/most-used-content/
  • connect.posit.it: https://connect.posit.it/most-used-content/
    • Note: Because this version uses the small-page paginated "legacy" metrics endpoints, it takes a long time to initially load data — maybe about ten minutes to load one week of data. Don't expect to be able to load 30 or 90 days of data on that version. The final version of this content should never use those endpoints, as it's not a good experience, even with caching.
    • It would be better if we could adjust the config for connect.posit.it to enable the dev version of the firehose API. In fact, that might be a good idea, because then we can get a more realistic impression of performance with the firehose API and larger data sizes.

This PR has been open too long. The core app.R file has changed significantly, but my hope is that it's pretty self-explanatory to review. The majority of the changed lines are in files like manifest.json, the bulk of which is auto-generated. (Aside: I think this was a by-product of the approach of iterating based on feedback in Slack rather than in commits. I'll try to do a better job going forward of explicitly scoping commits, and directly prompting for review to close out the current round of changes.) Happy to pair on a review.

Changes in this version:

  • Uses reactable instead of gt.
  • Incorporated the "Visit Merge Window" slider from the content-specific dashboard.
  • Rejiggered display of items across a few iterations. Things I'm unsure about:
    • Is "Unique Visitors" worth including? It's really only "Unique Logged-in Visitors", but that's too much text to display on one row in the title. It just be extra clutter.
    • Same for "Last Viewed".
  • Added filter by app mode.
  • Added two export buttons
    • One downloads a CSV of the raw hits data.
    • The other downloads the currently-displayed table, including a content guid column that is hidden from display. @kmasiello requested that specifically — the kind of thing you could feed into a "content rebuild" script.
  • Added a text line showing the total number of visits and content items displayed.
  • Added a placeholder modal that displays when you click on a row, which I'm next going to add the content-specific view to.
  • Removed the "Last Viewed At" column.
  • Added a link to open the Connect content dashboard.
  • Added a checkbox to show the GUID.
  • Made the date range controller nicer.

Changes to come in a future pull request:

  • Do not use the legacy content endpoints?
  • Use the visitor's API key and show some kind of "content scope" control (e.g. "All content I can see", "My content", "Content I can contribute to", etc.).
  • Possibly add an "Email" icon / button next to the Owner column? I'm not sure if this will feel silly when viewing "My content", but perhaps that's overthinking.
  • Possibly integrate the single content dashboard (mega dashboard).

@toph-allen toph-allen marked this pull request as ready for review April 3, 2025 18:59
@toph-allen
Copy link
Contributor Author

toph-allen commented Apr 3, 2025

Note to self: Check sparkline math.

Screen Shot 2025-04-03 at 03 23 26 PM@2x

[edit: math was correct, just wasn't passing an option to sparkline::sparkline().]

@toph-allen toph-allen requested review from fizzboop, dotNomad and cgraham-rs and removed request for dethmasque April 15, 2025 19:02
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.

1 participant