<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
<link href="https://larlet.fr/david/" rel="alternate" type="text/html" /> | <link href="https://larlet.fr/david/" rel="alternate" type="text/html" /> | ||||
<link href="https://larlet.fr/david/log/" rel="self" /> | <link href="https://larlet.fr/david/log/" rel="self" /> | ||||
<id>https://larlet.fr/david/</id> | <id>https://larlet.fr/david/</id> | ||||
<updated>2024-03-12T12:00:00+01:00</updated> | |||||
<updated>2024-03-13T12:00:00+01:00</updated> | |||||
<author> | <author> | ||||
<name>David Larlet</name> | <name>David Larlet</name> | ||||
<uri>https://larlet.fr/david/</uri> | <uri>https://larlet.fr/david/</uri> |
<script type="module"> | <script type="module"> | ||||
import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | import { annotate } from '/static/david/js/rough-notation-0.5.1.esm.min.js' | ||||
const observer = new IntersectionObserver(elements => { | |||||
const markObserver = new IntersectionObserver((entries, observer) => { | |||||
const computedStyle = getComputedStyle(document.documentElement) | const computedStyle = getComputedStyle(document.documentElement) | ||||
const markBackground = computedStyle.getPropertyValue('--mark-background') | const markBackground = computedStyle.getPropertyValue('--mark-background') | ||||
for (const element of elements) { | |||||
if (element.intersectionRatio === 0) continue | |||||
const markElement = element.target | |||||
if (markElement.dataset.annotated) continue | |||||
for (const entry of entries) { | |||||
if (entry.intersectionRatio === 0) continue | |||||
const markElement = entry.target | |||||
const annotation = annotate( | const annotation = annotate( | ||||
markElement, { | markElement, { | ||||
type: 'highlight', | type: 'highlight', | ||||
} | } | ||||
) | ) | ||||
annotation.show() | annotation.show() | ||||
// Avoid the rough notation to be applied multiple times. | |||||
markElement.dataset.annotated = true | |||||
observer.unobserve(markElement) | |||||
} | } | ||||
}, {threshold: 1.0}) | }, {threshold: 1.0}) | ||||
for (const markElement of document.querySelectorAll('mark')) { | for (const markElement of document.querySelectorAll('mark')) { | ||||
markElement.style.backgroundColor = 'inherit' | markElement.style.backgroundColor = 'inherit' | ||||
observer.observe(markElement) | |||||
markObserver.observe(markElement) | |||||
} | } | ||||
</script> | </script> | ||||
{% endblock %} | {% endblock %} |