Skip to content
This repository was archived by the owner on Jun 24, 2025. It is now read-only.

Fix incorrect import of multiple inline math.#1906

Merged
eliandoran merged 4 commits intodevelopfrom
importMarkdownfromClipboard
May 12, 2025
Merged

Fix incorrect import of multiple inline math.#1906
eliandoran merged 4 commits intodevelopfrom
importMarkdownfromClipboard

Conversation

@SiriusXT
Copy link
Copy Markdown
Member

Fix the issue where multiple formulas on a single line are incorrectly treated as one when importing Markdown from the clipboard.

A test case:

The fundamental idea underpinning the GKAT architecture is the observation that the attention matrix $A_i$ from GAT can be "densified" as follows:

$$A_i(k, l) = \frac{K(q_k, k_l) T(k, l)}{\sum\limits_{r \in V} K(q_k, k_r) T(k, r)} \tag{2}$$

where $K : \mathbb{R}^d \times \mathbb{R}^d \rightarrow \mathbb{R}$ is a kernel defined on feature vectors in nodes of the graph and $T : V \times V \rightarrow \mathbb{R}$ is another kernel defined on the nodes of the graph $G$ (that for simplicity will depend only on the topology of the graph, but not feature vectors in those nodes).

@github-actions
Copy link
Copy Markdown

Folder/File Previous size New size Difference
/upload/TriliumNextNotes-Server-1906-merge-linux-x64.tar.xz 69.28MB +69.28MB (+100.00%)
TOTAL +69.28MB

Copy link
Copy Markdown
Contributor

@eliandoran eliandoran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a test case in markdown.spec.ts that was failing in the previous implementation and passes on the new one.

@eliandoran eliandoran marked this pull request as draft May 10, 2025 15:23
@SiriusXT SiriusXT marked this pull request as ready for review May 10, 2025 16:09
Comment on lines +1225 to +1227
::selection {
background-color: #3399FF70;
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, I believe this change is too specific. We can't use hard-coded colors here since they can differ between dark and light mode and we generally set up a CSS variable instead so that it can be overridden in themes.

Is there any other way?

Also, not sure exactly how it relates to the rest of the PR.

Copy link
Copy Markdown
Member Author

@SiriusXT SiriusXT May 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand your point. Since this change was quite minor, I included the background adjustment in this PR as a convenience. I've reverted it for now and will look into a suitable solution.

@eliandoran eliandoran added this to the v0.94.0 milestone May 11, 2025
@eliandoran eliandoran marked this pull request as draft May 11, 2025 21:44
@SiriusXT SiriusXT marked this pull request as ready for review May 12, 2025 01:19
@eliandoran eliandoran merged commit 308700d into develop May 12, 2025
11 checks passed
@eliandoran eliandoran deleted the importMarkdownfromClipboard branch May 12, 2025 07:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants