[GH-ISSUE #1485] FR: [$20] allow newlines, images etc in highlights #935

Open
opened 2026-03-02 11:53:50 +03:00 by kerem · 11 comments
Owner

Originally created by @thiswillbeyourgithub on GitHub (May 27, 2025).
Original GitHub issue: https://github.com/karakeep-app/karakeep/issues/1485

Describe the feature you'd like

Hi,

I noticed that currently the highlighting feature does not handle equations nor images well.

Here is an example with images:

Image

Image

Here is an example with multiple lines:

Image

Image

There is a bounty: meaning that anyone that gets this working will receive 20 US dollars (or currency equivalent). I have a track record for being fair.

Describe the benefits this would bring to existing Karakeep users

Better highlights

Can the goal of this request already be achieved via other means?

No

Have you searched for an existing open/closed issue?

  • I have searched for existing issues and none cover my fundamental request

Additional context

No response

Originally created by @thiswillbeyourgithub on GitHub (May 27, 2025). Original GitHub issue: https://github.com/karakeep-app/karakeep/issues/1485 ### Describe the feature you'd like Hi, I noticed that currently the highlighting feature does not handle equations nor images well. Here is an example with images: ![Image](https://github.com/user-attachments/assets/8c01936f-391b-41df-b57a-149b49c3befd) ![Image](https://github.com/user-attachments/assets/b8bc196a-57ff-4e62-8a76-003b90d3aa56) Here is an example with multiple lines: ![Image](https://github.com/user-attachments/assets/cc9fa78d-a4e6-43a0-a21f-dd12a7b58531) ![Image](https://github.com/user-attachments/assets/60d08938-2338-4f5a-b871-4a62934a5ae1) There is a bounty: meaning that anyone that gets this working will receive 20 US dollars (or currency equivalent). I have a track record for being fair. ### Describe the benefits this would bring to existing Karakeep users Better highlights ### Can the goal of this request already be achieved via other means? No ### Have you searched for an existing open/closed issue? - [x] I have searched for existing issues and none cover my fundamental request ### Additional context _No response_
Author
Owner

@haappi commented on GitHub (Jun 1, 2025):

I believe #1457 attempts to fix this issue. If you could give it a shot with some of your URL's for testing that would be awesome!

Image

Newlines however,.. I'll add it to my backlog

<!-- gh-comment-id:2928024336 --> @haappi commented on GitHub (Jun 1, 2025): I believe #1457 attempts to fix this issue. If you could give it a shot with some of your URL's for testing that would be awesome! ![Image](https://github.com/user-attachments/assets/d1be03bf-f19f-4555-9c4a-08ef3008da5a) Newlines however,.. I'll add it to my backlog
Author
Owner

@thiswillbeyourgithub commented on GitHub (Jun 1, 2025):

Hey thanks I'll take a look. Btw there is #836 too for which I'm offering a bounty!

<!-- gh-comment-id:2928045831 --> @thiswillbeyourgithub commented on GitHub (Jun 1, 2025): Hey thanks I'll take a look. Btw there is #836 too for which I'm offering a bounty!
Author
Owner

@haappi commented on GitHub (Jun 5, 2025):

I didn't even realize images can be apart of the reader view, what should intended behavior look like? I'm not exactly sure what your screenshot is trying to convey

<!-- gh-comment-id:2942725569 --> @haappi commented on GitHub (Jun 5, 2025): I didn't even realize images can be apart of the reader view, what should intended behavior look like? I'm not exactly sure what your screenshot is trying to convey
Author
Owner

@thiswillbeyourgithub commented on GitHub (Jun 6, 2025):

Yeah that's what my first image was trying to convey: there is a single blue highlight, it starts before the image and ends after it. I expect the same kind of behavior as on omnivore: there should be some kind of blue overlay on the image to illustrate that it is part of the highlight. And the image should then appear as part of the highlight in the highlight UI.

And my 2nd and 3rd images refers to newlines: there is a single green highlight that goes over 2 lines. But the highlight UI drops the newline (the newline is I think not even stored because when I fetch it using my api client it is missing). And also it shows the text centered instead of left adjusted which makes it even harder to mentally link the original text to the highlight content.

Basically: highlight should keep the formatting of the original text.

Do you think it's doable? I tried a bit with vibe coding but that didn't work out (I'm miserable at typescript though).

Btw I am very serious about my bounties, and I keep a track record if you want proof.

If you are interested, here are the other FR that are somewhat related to that part of the code:

  • #1243 : render equations / latex / etc. $20
  • #836 : this one is an absolute need for me. The bounty is at $30 but I will need it so bad to catch up on my research in the summer that it might increase if nobody shows up. Actually if anyone pulls it off and it took very significant effort I am willing to increase the reward at my own discretion (I am a student though, not a bitcoin billionaire :) )
  • And #1442 has no bounty but seems easy
<!-- gh-comment-id:2949044275 --> @thiswillbeyourgithub commented on GitHub (Jun 6, 2025): Yeah that's what my first image was trying to convey: there is a single blue highlight, it starts before the image and ends after it. I expect the same kind of behavior as on omnivore: there should be some kind of blue overlay on the image to illustrate that it is part of the highlight. And the image should then appear as part of the highlight in the highlight UI. And my 2nd and 3rd images refers to newlines: there is a single green highlight that goes over 2 lines. But the highlight UI drops the newline (the newline is I think not even stored because when I fetch it using [my api client](https://github.com/thiswillbeyourgithub/karakeep_python_api) it is missing). And also it shows the text centered instead of left adjusted which makes it even harder to mentally link the original text to the highlight content. Basically: highlight should keep the formatting of the original text. Do you think it's doable? I tried a bit with vibe coding but that didn't work out (I'm miserable at typescript though). Btw I am very serious about my bounties, and I keep a track record if you want proof. If you are interested, here are the other FR that are somewhat related to that part of the code: - #1243 : render equations / latex / etc. $20 - #836 : this one is an absolute need for me. The bounty is at $30 but I will need it so bad to catch up on my research in the summer that it might increase if nobody shows up. Actually if anyone pulls it off and it took very significant effort I am willing to increase the reward at my own discretion (I am a student though, not a bitcoin billionaire :) ) - And #1442 has no bounty but seems easy
Author
Owner

@haappi commented on GitHub (Jun 7, 2025):

So I gave the newlines thing a shot: Do you prefer it to be center or left aligned?

Center

Image

Left

Image

Or somehow retain the existing formatting... which would most likely make it center aligned by default.

As for the images, I'm not exactly fond of having a color overlay over the image. I guess we could make it so the color overlay is removed upon hover, but that requires some thinking for mobile (long press but also not long enough?)

<!-- gh-comment-id:2952768658 --> @haappi commented on GitHub (Jun 7, 2025): So I gave the newlines thing a shot: Do you prefer it to be center or left aligned? ## Center ![Image](https://github.com/user-attachments/assets/485f5bec-bcfa-4dfc-bacf-eb726520699a) ## Left ![Image](https://github.com/user-attachments/assets/24862310-cbe4-493a-aa21-78ed2bb4d253) Or somehow retain the existing formatting... which would most likely make it center aligned by default. As for the images, I'm not exactly fond of having a color overlay over the image. I guess we could make it so the color overlay is removed upon hover, but that requires some thinking for mobile (long press but also not long enough?)
Author
Owner

@thiswillbeyourgithub commented on GitHub (Jun 7, 2025):

Awesome looking. To me it's a nobrainer to keep left aligned. And the existing article formatting is left aligned no?

I leave it totally up to you re the overlay. Indeed it looks bad with a permanent overlay and hurts redability of said image.

Edit: on second thought maybe it makes sens to align like the article view. In most cases it'll be left aligned but if you're reading haikus both would be center aligned no?

<!-- gh-comment-id:2953217991 --> @thiswillbeyourgithub commented on GitHub (Jun 7, 2025): Awesome looking. To me it's a nobrainer to keep left aligned. And the existing article formatting is left aligned no? I leave it totally up to you re the overlay. Indeed it looks bad with a permanent overlay and hurts redability of said image. Edit: on second thought maybe it makes sens to align like the article view. In most cases it'll be left aligned but if you're reading haikus both would be center aligned no?
Author
Owner

@haappi commented on GitHub (Jun 8, 2025):

Well most pages are left aligned, I'll find a poetry site of some sort and test out haikus seems like a great example to work with.

It's that I'm forcing it to be left, I believe there's another property somewhere else making it center aligned (or it's the defaults I don't remember off the top of my head)

Images, guess I'll do what mister gpt suggests :D

<!-- gh-comment-id:2953419858 --> @haappi commented on GitHub (Jun 8, 2025): Well most pages are left aligned, I'll find a poetry site of some sort and test out haikus seems like a great example to work with. It's that I'm forcing it to be left, I believe there's another property somewhere else making it center aligned (or it's the defaults I don't remember off the top of my head) Images, guess I'll do what mister gpt suggests :D
Author
Owner

@thiswillbeyourgithub commented on GitHub (Jun 23, 2025):

Hi @haappi I was wondering if you had the chance to make some progress on this? Thanks!

<!-- gh-comment-id:2996527413 --> @thiswillbeyourgithub commented on GitHub (Jun 23, 2025): Hi @haappi I was wondering if you had the chance to make some progress on this? Thanks!
Author
Owner

@haappi commented on GitHub (Jun 26, 2025):

Sorry! I've been caught up with some stuff leading to no time on this. I'm hoping I can finish this by Saturday. Sorry about that

<!-- gh-comment-id:3007085499 --> @haappi commented on GitHub (Jun 26, 2025): Sorry! I've been caught up with some stuff leading to no time on this. I'm hoping I can finish this by Saturday. Sorry about that
Author
Owner

@thiswillbeyourgithub commented on GitHub (Oct 19, 2025):

Hi, I made the bounty and it's still on!

@haappi gave it a try but the PR is still open so i'm not sure it's on path to claiming it?

I'm interested in details of your approach @mudaly10-coder

<!-- gh-comment-id:3419760894 --> @thiswillbeyourgithub commented on GitHub (Oct 19, 2025): Hi, I made the bounty and it's still on! @haappi gave it a try but the PR is still open so i'm not sure it's on path to claiming it? I'm interested in details of your approach @mudaly10-coder
Author
Owner

@thiswillbeyourgithub commented on GitHub (Dec 28, 2025):

Hi @haappi and @mudaly10-coder . I was wondering if there were any updates on your site? The bounty is still up for grabs :)

<!-- gh-comment-id:3694660347 --> @thiswillbeyourgithub commented on GitHub (Dec 28, 2025): Hi @haappi and @mudaly10-coder . I was wondering if there were any updates on your site? The bounty is still up for grabs :)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/karakeep#935
No description provided.