summaryrefslogtreecommitdiff
path: root/gnu/packages
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2020-12-29 14:21:58 +0100
committerRicardo Wurmus <rekado@elephly.net>2020-12-29 14:26:52 +0100
commitac80cbfab69b59d17fcf38ef9f4ce0acc0e5f9e6 (patch)
tree1fd1729c071a6182540586cec9ec01afc1b4de21 /gnu/packages
parenta2d5f9f60d0f440e5d5ce1a1cc81743b27d6cede (diff)
gnu: Add js-context-menu.
* gnu/packages/javascript.scm (js-context-menu): New variable.
Diffstat (limited to 'gnu/packages')
-rw-r--r--gnu/packages/javascript.scm39
1 files changed, 38 insertions, 1 deletions
diff --git a/gnu/packages/javascript.scm b/gnu/packages/javascript.scm
index 48bde160cd..c4bce1c42e 100644
--- a/gnu/packages/javascript.scm
+++ b/gnu/packages/javascript.scm
@@ -1,6 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2017 Arun Isaac <arunisaac@systemreboot.net>
-;;; Copyright © 2017, 2019 Ricardo Wurmus <rekado@elephly.net>
+;;; Copyright © 2017, 2019, 2020 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2017, 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2018 Nicolas Goaziou <mail@nicolasgoaziou.fr>
@@ -27,6 +27,7 @@
#:use-module (gnu packages compression)
#:use-module (gnu packages lisp-xyz)
#:use-module (gnu packages readline)
+ #:use-module (gnu packages web)
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix git-download)
@@ -56,6 +57,42 @@
(description "This library provides a portable embeddable JSON parser.")
(license license:expat)))
+(define-public js-context-menu
+ (package
+ (name "js-context-menu")
+ (version "0.6.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/zorkow/context-menu")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1q063l6477z285j6h5wvccp6iswvlp0jmb96sgk32sh0lf7nhknh"))))
+ (build-system trivial-build-system)
+ (arguments
+ `(#:modules ((guix build utils))
+ #:builder
+ (begin
+ (use-modules (guix build utils))
+ (chdir (assoc-ref %build-inputs "source"))
+ (let ((target (string-append %output "/share/javascript/context-menu")))
+ (apply invoke (string-append (assoc-ref %build-inputs "esbuild")
+ "/bin/esbuild")
+ "--bundle"
+ "--tsconfig=tsconfig.json"
+ (string-append "--outdir=" target)
+ (find-files "ts" "\\.ts$"))))))
+ (native-inputs
+ `(("esbuild" ,esbuild)))
+ (home-page "https://github.com/zorkow/context-menu")
+ (synopsis "Generic context menu")
+ (description "This package provides a reimplementation of the MathJax
+context menu in TypeScript.")
+ (license license:asl2.0)))
+
(define-public font-mathjax
(package
(name "font-mathjax")