studiowebux / obsidian-spotify-link

Obsidian.md Plugin to include the song or episode you're currently listening to in your note.
https://studiowebux.github.io/obsidian-plugins-docs/docs/category/plugin-spotify-link
MIT License
9 stars 2 forks source link

Compact links #9

Closed notuntoward closed 6 months ago

notuntoward commented 6 months ago

I noticed that when I link to a bunch of songs or many passages in a podcast, that the quoted links and extra meta information chew up a lot of vertical space.

Update: I just looked at the updated documentation: I should be able to shrink the links using templates, but not, as far as I can tell, by removing the quotes. But are these working yet? I tried this podcast table template:

| {{ episode_name }} | {{ timestamp }}|

but here's the link I got:

> ['**A legally binding treaty to fight the plastic problem**': ***The plastic problem is everywhere: in our oceans, communities, even inside our bodies. Plastic is abundant and very cheap, and the amount we produce is expected to triple by 2060 from 430 million tons a year to 1.2 billion tons, according to the OECD. The large amount of plastic could produce four billion tons of greenhouse gases, so a fix is becoming increasingly necessary. This week, Bloomberg Green senior reporter Akshat Rathi sat down with Inger Andersen, head of the UN’s Environment Program, to talk about an upcoming treaty that tackles increasing levels of plastic. You can read the transcript of this conversation here. Zero is a production of Bloomberg Green. Our producer is Oscar Boyd and our senior producer is Christine Driscoll. Special thanks to Kira Bindrim, Leslie Kaufman and Tiffany Tsoi. Email us at zeropod@bloomberg.net. For more coverage of climate change and solutions, visit https://www.bloomberg.com/green.See omnystudio.com/listener for privacy information.***, released 2024-03-28 | **15s** (1%)](https://open.spotify.com/episode/70xMHMhnQZz6YzWBN6trXY)
> Sat Mar 30 2024 - 1:08:55 PM
studiowebux commented 6 months ago

Hello !

I didn't test all of them for the episode. (if some of them does not resolve let me know, by not resolving it will print the {{ ... }} as is instead of replacing)

but in summary, I personnaly only listen to song (so never tested the podcast before yesterday) so the append <track or episode> with timestamp was made especially for the songs and there is no configurable template for that one (the with timestamp I mean), i think that is why you don't see the changes. I will check to integrate the template with that one as well. I think i decoupled the features correctly yesterday.

I will try to do that and test it within the next few days, I will update this ticket as soon as I get time to do it 😊

TL;DR: The append with timestamp has a hardcoded template. to use the actual template from the setting tab you must use the command append using template and there is two templates, one for song and one for podcast as they are different

So if my understanding is good you need to short the description length ? this one might be harder to do as I dont have anything currently to configure the text length

studiowebux commented 6 months ago
image

the first one is hardcoded

the second one uses the template

notuntoward commented 6 months ago

Thanks, yes, that's right. For podcasts, at least for me, short links are better. The reason is that, if I'm listening to one with details I want to remember, I'll take a note as it plays, making a bullet with a short description and a timestamp.

For music, it's the other way around: the whole song is what's interesting, and then a big link is luxurious.

studiowebux commented 6 months ago

Hello !

here is the quickest thing I can do:

the template to use: ['**{{ episode_name }}**' about ***{{ description[100] }}*** **{{ release_date }}** @ **{{ progress_min_sec }}**]({{ episode_link }})

output:

image

If it is good for you I will merge as-is

notuntoward commented 6 months ago

Yes, those capabilities should work well. Looks like I can edit them as needed. Thanks!