CuriousAlways / udemy-notes-downloader

chrome extension to download udemy notes
https://chrome.google.com/webstore/detail/udemy-notes-downloader/nfmebebffodanoadjadpjimpkihfeamn
MIT License
2 stars 5 forks source link

Proposed new feature: add note metadata to generated markdown files #5

Open theorib opened 6 months ago

theorib commented 6 months ago

Proposed new feature:

Option to add a metadata title tag to each note including:

Presently these are added as h4 tags not for semantics but because otherwise they look huge on most generated markdown files.

The formatting logic has been placed in a new helper file but all necessary selectors needed were kept inside the contentScripts.js so they can all be managed in the same place.

I also proposed an amendment to the displayed text for all the options on the UI so they feel more in line with each other.

Updated UI: Screenshot 2024-04-02 at 15 59 07

Generated Markdown (preview mode): Screenshot 2024-04-02 at 16 00 08

Generated Markdown (raw): Screenshot 2024-04-02 at 16 02 08

CuriousAlways commented 4 months ago

first of all sorry for delayed response and Thanks for raising PR. This looks good, i think it would nice to have clickable timestamps (i.e. link click take you to specific time on video). I did some digging lectures have following format <link>/<lecture_id>?start=<timestamp in seconds>. edit and delete notes icons are buttons with attribute formAction with this link. We should use these links to display timestamps.

CuriousAlways commented 4 months ago
Screenshot 2024-06-02 at 4 26 51 PM
theorib commented 4 months ago

No worries, thanks for getting back. I'll tweak the code to include a link to jump to the timestamp and send it over.

theorib commented 4 months ago

I was also thinking that it would be good idea to include at least a few other of the most popular languages out there, such as Go, TypeScript, SQL, Kotlin, PHP and Bash (not a language but people are always referencing terminal commands). I could submit that as a separate PR if you like the idea.

CuriousAlways commented 4 months ago

@theorib that would be awsome

theorib commented 4 months ago

Hi, sorry for the delay on my part this time around :)

I managed to find the URLs in the formAction property out of the edit or delete buttons for each note as you pointed out but there is a very strange behaviour that I haven't been able to solve:

Whenever I create a node list of all the notes, if I dig into each note, they all have their unique individual properties like the unique titles, content, etc. On the other hand the formAction property for the buttons on every list all have exactly the same URL. That URL points to the lesson location for the very first note on a list of notes.

It's very strange since every other aspect of the node list is unique but the URL is the same.

Here I am console.logging the data for different notes: Screenshot 2024-06-18 at 21 43 40

As you can see, they all have their own unique info but the URL is always the same.
I am at a bit of a loss. I tried to find the unique URL for each note in a lot of different places without success.

Wondering if you have any ideas?

CuriousAlways commented 3 months ago

@theorib i'm not sure will check