diff --git a/docs/blog/2020-08-28.md b/docs/blog/2020-08-28.md
new file mode 100644
index 00000000..def2a0ad
--- /dev/null
+++ b/docs/blog/2020-08-28.md
@@ -0,0 +1,7 @@
+# Rewriting the tech stack
+
+- started in 2011 as simple webpage with some Processing.js
+- complete rewrite to React in 2016
+- web's caught up, and there is no reason to keep things React. This content should work even without JS.
+
+
diff --git a/docs/chapters/intersections/content.en-GB.md b/docs/chapters/intersections/content.en-GB.md
index a9c36710..7c6418ad 100644
--- a/docs/chapters/intersections/content.en-GB.md
+++ b/docs/chapters/intersections/content.en-GB.md
@@ -10,7 +10,7 @@ If we have two line segments with two coordinates each, segments A-B and C-D, we
The following graphic implements this intersection detection, showing a red point for an intersection on the lines our segments lie on (thus being a virtual intersection point), and a green point for an intersection that lies on both segments (being a real intersection point).
-
+
If we have two line segments with two coordinates each, segments A-B and C-D, we can find the intersection of the lines these segments are an intervals on by linear algebra, using the procedure outlined in this top coder article. Of course, we need to make sure that the intersection isn't just on the lines our line segments lie on, but actually on our line segments themselves. So after we find the intersection, we need to verify that it lies without the bounds of our original line segments.
The following graphic implements this intersection detection, showing a red point for an intersection on the lines our segments lie on (thus being a virtual intersection point), and a green point for an intersection that lies on both segments (being a real intersection point).
-Curve/line intersection is more work, but we've already seen the techniques we need to use in order to perform it: first we translate/rotate both the line and curve together, in such a way that the line coincides with the x-axis. This will position the curve in a way that makes it cross the line at points where its y-function is zero. By doing this, the problem of finding intersections between a curve and a line has now become the problem of performing root finding on our translated/rotated curve, as we already covered in the section on finding extremities.
-Curve/curve intersection, however, is more complicated. Since we have no straight line to align to, we can't simply align one of the curves and be left with a simple procedure. Instead, we'll need to apply two techniques we've met before: de Casteljau's algorithm, and curve splitting.
diff --git a/docs/ja-JP/index.html b/docs/ja-JP/index.html index 8eb2e3f5..802f7d61 100644 --- a/docs/ja-JP/index.html +++ b/docs/ja-JP/index.html @@ -1471,7 +1471,11 @@ y = curve.get(t).yIf we have two line segments with two coordinates each, segments A-B and C-D, we can find the intersection of the lines these segments are an intervals on by linear algebra, using the procedure outlined in this top coder article. Of course, we need to make sure that the intersection isn't just on the lines our line segments lie on, but actually on our line segments themselves. So after we find the intersection, we need to verify that it lies without the bounds of our original line segments.
The following graphic implements this intersection detection, showing a red point for an intersection on the lines our segments lie on (thus being a virtual intersection point), and a green point for an intersection that lies on both segments (being a real intersection point).
-Curve/line intersection is more work, but we've already seen the techniques we need to use in order to perform it: first we translate/rotate both the line and curve together, in such a way that the line coincides with the x-axis. This will position the curve in a way that makes it cross the line at points where its y-function is zero. By doing this, the problem of finding intersections between a curve and a line has now become the problem of performing root finding on our translated/rotated curve, as we already covered in the section on finding extremities.
-Curve/curve intersection, however, is more complicated. Since we have no straight line to align to, we can't simply align one of the curves and be left with a simple procedure. Instead, we'll need to apply two techniques we've met before: de Casteljau's algorithm, and curve splitting.
diff --git a/docs/js/custom-element/api/graphics-api.js b/docs/js/custom-element/api/graphics-api.js index 928ccea7..55ea7b39 100644 --- a/docs/js/custom-element/api/graphics-api.js +++ b/docs/js/custom-element/api/graphics-api.js @@ -128,8 +128,8 @@ class GraphicsAPI extends BaseAPI { if (points) this.setMovable(points); } - setMovable(points) { - points.forEach((p) => this.movable.push(p)); + setMovable(...allpoints) { + allpoints.forEach((points) => points.forEach((p) => this.movable.push(p))); } /** @@ -318,6 +318,22 @@ class GraphicsAPI extends BaseAPI { this.setStroke(false); } + /** + * stroke + fill + */ + setColor(color) { + this.setFill(color); + this.setStroke(color); + } + + /** + * no stroke/fill + */ + noColor() { + this.noFill(); + this.noStroke(); + } + /** * Set a text stroke/color */ diff --git a/docs/zh-CN/index.html b/docs/zh-CN/index.html index 76206b78..aaf9ff09 100644 --- a/docs/zh-CN/index.html +++ b/docs/zh-CN/index.html @@ -1465,7 +1465,11 @@ y = curve.get(t).yIf we have two line segments with two coordinates each, segments A-B and C-D, we can find the intersection of the lines these segments are an intervals on by linear algebra, using the procedure outlined in this top coder article. Of course, we need to make sure that the intersection isn't just on the lines our line segments lie on, but actually on our line segments themselves. So after we find the intersection, we need to verify that it lies without the bounds of our original line segments.
The following graphic implements this intersection detection, showing a red point for an intersection on the lines our segments lie on (thus being a virtual intersection point), and a green point for an intersection that lies on both segments (being a real intersection point).
-Curve/line intersection is more work, but we've already seen the techniques we need to use in order to perform it: first we translate/rotate both the line and curve together, in such a way that the line coincides with the x-axis. This will position the curve in a way that makes it cross the line at points where its y-function is zero. By doing this, the problem of finding intersections between a curve and a line has now become the problem of performing root finding on our translated/rotated curve, as we already covered in the section on finding extremities.
-Curve/curve intersection, however, is more complicated. Since we have no straight line to align to, we can't simply align one of the curves and be left with a simple procedure. Instead, we'll need to apply two techniques we've met before: de Casteljau's algorithm, and curve splitting.
diff --git a/src/build/markdown/preprocess-graphics-element.js b/src/build/markdown/preprocess-graphics-element.js index ceec89b0..600e2abe 100644 --- a/src/build/markdown/preprocess-graphics-element.js +++ b/src/build/markdown/preprocess-graphics-element.js @@ -57,6 +57,12 @@ async function preprocessGraphicsElement(chapter, localeStrings, markdown) { /width="([^"]+)"\s+height="([^"]+)"\s+src="([^"]+)"\s*([^>]*)>/ ); + if (!terms) { + throw new Error( + `Bad markup for