summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/ximera/src/interactives/desmos.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/ximera/src/interactives/desmos.dtx')
-rw-r--r--macros/latex/contrib/ximera/src/interactives/desmos.dtx14
1 files changed, 14 insertions, 0 deletions
diff --git a/macros/latex/contrib/ximera/src/interactives/desmos.dtx b/macros/latex/contrib/ximera/src/interactives/desmos.dtx
new file mode 100644
index 0000000000..9a55db8f43
--- /dev/null
+++ b/macros/latex/contrib/ximera/src/interactives/desmos.dtx
@@ -0,0 +1,14 @@
+% \subsubsection{Desmos}
+% \DescribeMacro{\desmos}{Desmos command. Requires id, width, and height as arguments.}
+% \begin{macrocode}
+%<*classXimera>
+\newcommand{\desmos}[3]{Desmos link: \url{https://www.desmos.com/calculator/#1}}
+\newcommand{\desmosThreeD}[3]{Desmos3D link: \url{https://www.desmos.com/3d/#1}}
+%</classXimera>
+% \end{macrocode}
+% \begin{macrocode}
+%<*htXimera>
+\renewcommand{\desmos}[3]{\HCode{<iframe src="https://www.desmos.com/calculator/#1" width="100\%" height="#3px" style="border: 1px solid \#ccc" frameborder=0>This browser does not support embedded elements.</iframe>}}
+\renewcommand{\desmosThreeD}[3]{\HCode{<iframe src="https://www.desmos.com/3d/#1" width="#2px" height="#3px" style="border: 1px solid \#ccc" frameborder=0>This browser does not support embedded elements.</iframe>}}
+%</htXimera>
+% \end{macrocode}