Google docs onebox gem requires a "published" document

Maybe private docs could also use the text field to have a note about that status? E.g. just put “Document is private” there.

6 Likes

Done! :sunflower:

9 Likes

This is perfect, except for a minor quibble:

This works: https://docs.google.com/spreadsheets/d/gibberish/edit

But this doesn’t: https://docs.google.com/spreadsheets/d/gibberish

Both are valid URLs as far as Google Docs is concerned.

4 Likes

Sure @techapj can you have a look at that?

2 Likes

Fixed via:

https://github.com/discourse/onebox/commit/d7c626d2622668d04878ad653ea7d6671773c5e8

5 Likes

FWIW, I find the summaries for public documents underneath the title to be overlong and redundant.

For Google Sheets in particular, the summary is confusing as it runs along the column headings with data.

Real-world example:

I don’t see this as useful at all.

I would love an option to turn the summaries off – or to turn them off entirely, unless there are stalwart fans of them.

Yeah it feels like there is other metadata that is far more interesting.

  • Creation date of the document
  • Last editor
  • Last edit

Perhaps we can pick that up instead?

4 Likes

Accessing that data will require API credentials. Currently we are relying on OpenGraph data which provides title, type, description (summary), image (snippet).

6 Likes

I’m just started to try out the google docs onebox. The following link: (https://docs.google.com/spreadsheets/d/1lAuOv25IyOQgvkrTQb0ijKQhigAIeRrm2DoJUOsUiDQ/pubhtml?gid=1732160294&single=true) is puplished and are able to access through the browser or from the onebox even. But still said as you could see below; “This Sheet is Private”.

https://docs.google.com/spreadsheets/d/1lAuOv25IyOQgvkrTQb0ijKQhigAIeRrm2DoJUOsUiDQ/pubhtml?gid=1732160294&single=true

1 Like

Hmm, this has really screwed us over at www.talk.manvfat.com we used embedded Google Spreadsheets as a way for guys to record their weights, the spreadsheet then calculated BMI, etc.

e.g. - how it used to work for us:

https://talk.manvfat.com/t/weigh-in-day-16th-december/18283

What it looks like now:

https://talk.manvfat.com/t/weigh-in-day-06-01-2017/18738

We also used them as a way of running tracking threads - e.g. guys who wanted to track days off booze, etc.

It wasn’t perfect (mobile users didn’t report great functionality) so it could have been improved but neither of those functions can be replicated by Discourse as standard, so to my mind, you’ve stripped away something without much thought about who might be using this function.

Is there any other way of doing this? Any suggestions?

Create a custom plugin based on old onebox code.

3 Likes

Bummed that we lost the ability to embed Google Docs. The ability to easily iframe a Google Doc was a nice way to get shared notes in front of people’s eyes who are less likely to click through to a separate document. I wish there was a way to get the original embedded behavior (e.g., put “embed:” in front of the URL). Oh well. :sadpanda:

8 Likes

Is there still no workaround for this? At least embedding a slide deck would be extremely helpful.

4 Likes

This topic was automatically closed after 3180 days. New replies are no longer allowed.