diff --git a/.travis.yml b/.travis.yml
index 15ebcf6e..a0c1408b 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -2,7 +2,7 @@ anHsudo: required
dist: trusty
language: node_js
node_js:
- - "6"
+ - "9"
before_install:
- sudo dpkg --add-architecture i386
- sudo apt-get update -qq
@@ -34,13 +34,13 @@ before_deploy:
- mv open-stage-control-linux-ia32 open-stage-control-${VERSION}-linux-ia32
- mv open-stage-control-linux-x64 open-stage-control-${VERSION}-linux-x64
- mv open-stage-control-linux-armv7l open-stage-control-${VERSION}-linux-armv7l
- - mv open-stage-control-linux-arm64 open-stage-control-${VERSION}-linux-arm64
+ # - mv open-stage-control-linux-arm64 open-stage-control-${VERSION}-linux-arm64
- zip -q -r --symlinks packages/open-stage-control-${VERSION}-osx.zip open-stage-control-darwin-x64/open-stage-control.app
- zip -q -r packages/open-stage-control-${VERSION}-win32-ia32.zip open-stage-control-${VERSION}-win32-ia32
- zip -q -r packages/open-stage-control-${VERSION}-win32-x64.zip open-stage-control-${VERSION}-win32-x64
- zip -q -r packages/open-stage-control-${VERSION}-linux-ia32.zip open-stage-control-${VERSION}-linux-ia32
- zip -q -r packages/open-stage-control-${VERSION}-linux-x64.zip open-stage-control-${VERSION}-linux-x64
- zip -q -r packages/open-stage-control-${VERSION}-linux-armv7l.zip open-stage-control-${VERSION}-linux-armv7l
- - zip -q -r packages/open-stage-control-${VERSION}-linux-arm64.zip open-stage-control-${VERSION}-linux-arm64
+ # - zip -q -r packages/open-stage-control-${VERSION}-linux-arm64.zip open-stage-control-${VERSION}-linux-arm64
- ls packages
- cd ..
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 1b843c1c..1c0f2151 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,11 +1,66 @@
# Changelog
+## 0.23.0
+
+- bug fixes
+ - plots now send their value to other widget for synchronization as expected
+ - text widgets now apply their target widget's precision
+ - property inheritance accepts targetting a parent widget by its id
+ - multiple icons not displayed correctly
+ - broken `--blank` option
+- main
+ - added `--disable-gpu` option for disabling hardware acceleration (fixes rendering glitches and reduces input lag on some systems)
+- widgets
+ - inputs: **new** `keys` widget, for keyboard bindings
+ - property inheritance: new special property name `_value` (retrieve the widget's value, and update when it changes)
+ - switch: added `showValues` to display both values and labels in the buttons; array values can now be selected via osc
+ - range: both handles can be moved by holding `shift` while dragging
+ - rgb: **removed** `touchAddress` option
+ - labels/texts: multiple white spaces are no longer merged
+ - plot: can receive stringified arrays of coordinates or stringified objects for merging coordinates sets; added `bars` option for drawing barcharts;
+ - widgets' `precision` option allows setting a specific data type for numbers (sliders can send doubles !)
+- misc
+ - event system rewritten
+ - js build size reduced
+
+## 0.22.0
+
+- bug fixes
+ - sessions opened from command line with relative paths are now added to the history with their absolute path
+ - sending an empty message to a `text` widget resets it to its initial value and without ignoring its `value` property
+ - sending no value to a widget with `preArgs` is now possible : all the arguments found in incomming osc messages are now taken into account to match the widgets in the session
+ - regression breaking state quicksave from sidepanel
+- engine
+ - downgraded to the latest *stable* electron release
+- main
+ - added `zeroconf` / `bonjour` publishing for the app's http and osc input ports
+ - added `--instance-name` option to differenciate mulitple instances in zeroconf networks
+- widgets
+ - sliders/pads: holding `Ctrl` now enables high precision dragging with the mouse and bypasses the `snap` option
+ - inputs: renamed `input`'s property `horizontal` to `vertical` to match how the widget actually displays
+ - sliders: **new** `range` widget
+ - plots: **new** `image` widget
+- remote control
+ - **removed** deprecated `/EXEC`
+ - renamed `/EDIT_SOFT` to `/EDIT/MERGE`
+ - added `/EDIT/GET` (get a widget's data)
+ - added `/GET` (get a widget's value)
+ - added `/SET` (set a widget's value as if it was interacted with from the interface)
+
+
+## 0.21.3
+
+- bug fixes
+ - session/state: regression (0.21.2) breaking save-to-file function
+- ui
+ - FontAwesome 5 (icon font) !
+
## 0.21.2
- bug fixes
- cli: broken long flag `--no-gui`
- headless: when running with `node`, errors don't stop the server; when running with `electron` (default), errors are logged in the console instead of being showed in a dialog window
- - switcher widgets regression (broken)
+ - switcher widgets regression (broken)
- midi
- float values are now allowed and automatically rounded
- misc
diff --git a/README.md b/README.md
index bbd178ab..5c7187da 100644
--- a/README.md
+++ b/README.md
@@ -46,6 +46,6 @@ This program is a free software released under the GNU/GPL3 license, it relies o
----
-
+
BrowserStack helps debugging Open Stage Control by providing a complete suite of browser emulators for Android, iOS and Windows, how awesome is that ? *Quite very much indeed !*
diff --git a/app/browser/fonts/fa-solid-900.woff b/app/browser/fonts/fa-solid-900.woff
new file mode 100644
index 00000000..e9981ea5
Binary files /dev/null and b/app/browser/fonts/fa-solid-900.woff differ
diff --git a/app/browser/fonts/fa-solid.css b/app/browser/fonts/fa-solid.css
new file mode 100644
index 00000000..c6208d0b
--- /dev/null
+++ b/app/browser/fonts/fa-solid.css
@@ -0,0 +1,14 @@
+/*!
+ * Font Awesome Free 5.0.0 by @fontawesome - http://fontawesome.com
+ * License - http://fontawesome.com/license (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
+ */
+@font-face {
+ font-family: FontAwesome;
+ font-style: normal;
+ font-weight: 900;
+ src: url("./fa-solid-900.woff") format("woff")}
+
+.fa,
+.fas {
+ font-family: FontAwesome;
+ font-weight: 900; }
diff --git a/app/browser/fonts/font-awesome.min.css b/app/browser/fonts/font-awesome.min.css
deleted file mode 100644
index 4d9f65de..00000000
--- a/app/browser/fonts/font-awesome.min.css
+++ /dev/null
@@ -1,4 +0,0 @@
-/*!
- * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome
- * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License)
- */@font-face{font-family:'FontAwesome'; src:url('fontawesome-webfont.woff') format('woff');font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571429em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.fa-li.fa-lg{left:-1.85714286em}.fa-border{padding:.2em .25em .15em;border:solid .08em #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left{margin-right:.3em}.fa.fa-pull-right{margin-left:.3em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left{margin-right:.3em}.fa.pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scale(-1, 1);-ms-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scale(1, -1);-ms-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:"\f000"}.fa-music:before{content:"\f001"}.fa-search:before{content:"\f002"}.fa-envelope-o:before{content:"\f003"}.fa-heart:before{content:"\f004"}.fa-star:before{content:"\f005"}.fa-star-o:before{content:"\f006"}.fa-user:before{content:"\f007"}.fa-film:before{content:"\f008"}.fa-th-large:before{content:"\f009"}.fa-th:before{content:"\f00a"}.fa-th-list:before{content:"\f00b"}.fa-check:before{content:"\f00c"}.fa-remove:before,.fa-close:before,.fa-times:before{content:"\f00d"}.fa-search-plus:before{content:"\f00e"}.fa-search-minus:before{content:"\f010"}.fa-power-off:before{content:"\f011"}.fa-signal:before{content:"\f012"}.fa-gear:before,.fa-cog:before{content:"\f013"}.fa-trash-o:before{content:"\f014"}.fa-home:before{content:"\f015"}.fa-file-o:before{content:"\f016"}.fa-clock-o:before{content:"\f017"}.fa-road:before{content:"\f018"}.fa-download:before{content:"\f019"}.fa-arrow-circle-o-down:before{content:"\f01a"}.fa-arrow-circle-o-up:before{content:"\f01b"}.fa-inbox:before{content:"\f01c"}.fa-play-circle-o:before{content:"\f01d"}.fa-rotate-right:before,.fa-repeat:before{content:"\f01e"}.fa-refresh:before{content:"\f021"}.fa-list-alt:before{content:"\f022"}.fa-lock:before{content:"\f023"}.fa-flag:before{content:"\f024"}.fa-headphones:before{content:"\f025"}.fa-volume-off:before{content:"\f026"}.fa-volume-down:before{content:"\f027"}.fa-volume-up:before{content:"\f028"}.fa-qrcode:before{content:"\f029"}.fa-barcode:before{content:"\f02a"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-book:before{content:"\f02d"}.fa-bookmark:before{content:"\f02e"}.fa-print:before{content:"\f02f"}.fa-camera:before{content:"\f030"}.fa-font:before{content:"\f031"}.fa-bold:before{content:"\f032"}.fa-italic:before{content:"\f033"}.fa-text-height:before{content:"\f034"}.fa-text-width:before{content:"\f035"}.fa-align-left:before{content:"\f036"}.fa-align-center:before{content:"\f037"}.fa-align-right:before{content:"\f038"}.fa-align-justify:before{content:"\f039"}.fa-list:before{content:"\f03a"}.fa-dedent:before,.fa-outdent:before{content:"\f03b"}.fa-indent:before{content:"\f03c"}.fa-video-camera:before{content:"\f03d"}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:"\f03e"}.fa-pencil:before{content:"\f040"}.fa-map-marker:before{content:"\f041"}.fa-adjust:before{content:"\f042"}.fa-tint:before{content:"\f043"}.fa-edit:before,.fa-pencil-square-o:before{content:"\f044"}.fa-share-square-o:before{content:"\f045"}.fa-check-square-o:before{content:"\f046"}.fa-arrows:before{content:"\f047"}.fa-step-backward:before{content:"\f048"}.fa-fast-backward:before{content:"\f049"}.fa-backward:before{content:"\f04a"}.fa-play:before{content:"\f04b"}.fa-pause:before{content:"\f04c"}.fa-stop:before{content:"\f04d"}.fa-forward:before{content:"\f04e"}.fa-fast-forward:before{content:"\f050"}.fa-step-forward:before{content:"\f051"}.fa-eject:before{content:"\f052"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-plus-circle:before{content:"\f055"}.fa-minus-circle:before{content:"\f056"}.fa-times-circle:before{content:"\f057"}.fa-check-circle:before{content:"\f058"}.fa-question-circle:before{content:"\f059"}.fa-info-circle:before{content:"\f05a"}.fa-crosshairs:before{content:"\f05b"}.fa-times-circle-o:before{content:"\f05c"}.fa-check-circle-o:before{content:"\f05d"}.fa-ban:before{content:"\f05e"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-up:before{content:"\f062"}.fa-arrow-down:before{content:"\f063"}.fa-mail-forward:before,.fa-share:before{content:"\f064"}.fa-expand:before{content:"\f065"}.fa-compress:before{content:"\f066"}.fa-plus:before{content:"\f067"}.fa-minus:before{content:"\f068"}.fa-asterisk:before{content:"\f069"}.fa-exclamation-circle:before{content:"\f06a"}.fa-gift:before{content:"\f06b"}.fa-leaf:before{content:"\f06c"}.fa-fire:before{content:"\f06d"}.fa-eye:before{content:"\f06e"}.fa-eye-slash:before{content:"\f070"}.fa-warning:before,.fa-exclamation-triangle:before{content:"\f071"}.fa-plane:before{content:"\f072"}.fa-calendar:before{content:"\f073"}.fa-random:before{content:"\f074"}.fa-comment:before{content:"\f075"}.fa-magnet:before{content:"\f076"}.fa-chevron-up:before{content:"\f077"}.fa-chevron-down:before{content:"\f078"}.fa-retweet:before{content:"\f079"}.fa-shopping-cart:before{content:"\f07a"}.fa-folder:before{content:"\f07b"}.fa-folder-open:before{content:"\f07c"}.fa-arrows-v:before{content:"\f07d"}.fa-arrows-h:before{content:"\f07e"}.fa-bar-chart-o:before,.fa-bar-chart:before{content:"\f080"}.fa-twitter-square:before{content:"\f081"}.fa-facebook-square:before{content:"\f082"}.fa-camera-retro:before{content:"\f083"}.fa-key:before{content:"\f084"}.fa-gears:before,.fa-cogs:before{content:"\f085"}.fa-comments:before{content:"\f086"}.fa-thumbs-o-up:before{content:"\f087"}.fa-thumbs-o-down:before{content:"\f088"}.fa-star-half:before{content:"\f089"}.fa-heart-o:before{content:"\f08a"}.fa-sign-out:before{content:"\f08b"}.fa-linkedin-square:before{content:"\f08c"}.fa-thumb-tack:before{content:"\f08d"}.fa-external-link:before{content:"\f08e"}.fa-sign-in:before{content:"\f090"}.fa-trophy:before{content:"\f091"}.fa-github-square:before{content:"\f092"}.fa-upload:before{content:"\f093"}.fa-lemon-o:before{content:"\f094"}.fa-phone:before{content:"\f095"}.fa-square-o:before{content:"\f096"}.fa-bookmark-o:before{content:"\f097"}.fa-phone-square:before{content:"\f098"}.fa-twitter:before{content:"\f099"}.fa-facebook-f:before,.fa-facebook:before{content:"\f09a"}.fa-github:before{content:"\f09b"}.fa-unlock:before{content:"\f09c"}.fa-credit-card:before{content:"\f09d"}.fa-feed:before,.fa-rss:before{content:"\f09e"}.fa-hdd-o:before{content:"\f0a0"}.fa-bullhorn:before{content:"\f0a1"}.fa-bell:before{content:"\f0f3"}.fa-certificate:before{content:"\f0a3"}.fa-hand-o-right:before{content:"\f0a4"}.fa-hand-o-left:before{content:"\f0a5"}.fa-hand-o-up:before{content:"\f0a6"}.fa-hand-o-down:before{content:"\f0a7"}.fa-arrow-circle-left:before{content:"\f0a8"}.fa-arrow-circle-right:before{content:"\f0a9"}.fa-arrow-circle-up:before{content:"\f0aa"}.fa-arrow-circle-down:before{content:"\f0ab"}.fa-globe:before{content:"\f0ac"}.fa-wrench:before{content:"\f0ad"}.fa-tasks:before{content:"\f0ae"}.fa-filter:before{content:"\f0b0"}.fa-briefcase:before{content:"\f0b1"}.fa-arrows-alt:before{content:"\f0b2"}.fa-group:before,.fa-users:before{content:"\f0c0"}.fa-chain:before,.fa-link:before{content:"\f0c1"}.fa-cloud:before{content:"\f0c2"}.fa-flask:before{content:"\f0c3"}.fa-cut:before,.fa-scissors:before{content:"\f0c4"}.fa-copy:before,.fa-files-o:before{content:"\f0c5"}.fa-paperclip:before{content:"\f0c6"}.fa-save:before,.fa-floppy-o:before{content:"\f0c7"}.fa-square:before{content:"\f0c8"}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:"\f0c9"}.fa-list-ul:before{content:"\f0ca"}.fa-list-ol:before{content:"\f0cb"}.fa-strikethrough:before{content:"\f0cc"}.fa-underline:before{content:"\f0cd"}.fa-table:before{content:"\f0ce"}.fa-magic:before{content:"\f0d0"}.fa-truck:before{content:"\f0d1"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-square:before{content:"\f0d3"}.fa-google-plus-square:before{content:"\f0d4"}.fa-google-plus:before{content:"\f0d5"}.fa-money:before{content:"\f0d6"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-up:before{content:"\f0d8"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-columns:before{content:"\f0db"}.fa-unsorted:before,.fa-sort:before{content:"\f0dc"}.fa-sort-down:before,.fa-sort-desc:before{content:"\f0dd"}.fa-sort-up:before,.fa-sort-asc:before{content:"\f0de"}.fa-envelope:before{content:"\f0e0"}.fa-linkedin:before{content:"\f0e1"}.fa-rotate-left:before,.fa-undo:before{content:"\f0e2"}.fa-legal:before,.fa-gavel:before{content:"\f0e3"}.fa-dashboard:before,.fa-tachometer:before{content:"\f0e4"}.fa-comment-o:before{content:"\f0e5"}.fa-comments-o:before{content:"\f0e6"}.fa-flash:before,.fa-bolt:before{content:"\f0e7"}.fa-sitemap:before{content:"\f0e8"}.fa-umbrella:before{content:"\f0e9"}.fa-paste:before,.fa-clipboard:before{content:"\f0ea"}.fa-lightbulb-o:before{content:"\f0eb"}.fa-exchange:before{content:"\f0ec"}.fa-cloud-download:before{content:"\f0ed"}.fa-cloud-upload:before{content:"\f0ee"}.fa-user-md:before{content:"\f0f0"}.fa-stethoscope:before{content:"\f0f1"}.fa-suitcase:before{content:"\f0f2"}.fa-bell-o:before{content:"\f0a2"}.fa-coffee:before{content:"\f0f4"}.fa-cutlery:before{content:"\f0f5"}.fa-file-text-o:before{content:"\f0f6"}.fa-building-o:before{content:"\f0f7"}.fa-hospital-o:before{content:"\f0f8"}.fa-ambulance:before{content:"\f0f9"}.fa-medkit:before{content:"\f0fa"}.fa-fighter-jet:before{content:"\f0fb"}.fa-beer:before{content:"\f0fc"}.fa-h-square:before{content:"\f0fd"}.fa-plus-square:before{content:"\f0fe"}.fa-angle-double-left:before{content:"\f100"}.fa-angle-double-right:before{content:"\f101"}.fa-angle-double-up:before{content:"\f102"}.fa-angle-double-down:before{content:"\f103"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angle-down:before{content:"\f107"}.fa-desktop:before{content:"\f108"}.fa-laptop:before{content:"\f109"}.fa-tablet:before{content:"\f10a"}.fa-mobile-phone:before,.fa-mobile:before{content:"\f10b"}.fa-circle-o:before{content:"\f10c"}.fa-quote-left:before{content:"\f10d"}.fa-quote-right:before{content:"\f10e"}.fa-spinner:before{content:"\f110"}.fa-circle:before{content:"\f111"}.fa-mail-reply:before,.fa-reply:before{content:"\f112"}.fa-github-alt:before{content:"\f113"}.fa-folder-o:before{content:"\f114"}.fa-folder-open-o:before{content:"\f115"}.fa-smile-o:before{content:"\f118"}.fa-frown-o:before{content:"\f119"}.fa-meh-o:before{content:"\f11a"}.fa-gamepad:before{content:"\f11b"}.fa-keyboard-o:before{content:"\f11c"}.fa-flag-o:before{content:"\f11d"}.fa-flag-checkered:before{content:"\f11e"}.fa-terminal:before{content:"\f120"}.fa-code:before{content:"\f121"}.fa-mail-reply-all:before,.fa-reply-all:before{content:"\f122"}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:"\f123"}.fa-location-arrow:before{content:"\f124"}.fa-crop:before{content:"\f125"}.fa-code-fork:before{content:"\f126"}.fa-unlink:before,.fa-chain-broken:before{content:"\f127"}.fa-question:before{content:"\f128"}.fa-info:before{content:"\f129"}.fa-exclamation:before{content:"\f12a"}.fa-superscript:before{content:"\f12b"}.fa-subscript:before{content:"\f12c"}.fa-eraser:before{content:"\f12d"}.fa-puzzle-piece:before{content:"\f12e"}.fa-microphone:before{content:"\f130"}.fa-microphone-slash:before{content:"\f131"}.fa-shield:before{content:"\f132"}.fa-calendar-o:before{content:"\f133"}.fa-fire-extinguisher:before{content:"\f134"}.fa-rocket:before{content:"\f135"}.fa-maxcdn:before{content:"\f136"}.fa-chevron-circle-left:before{content:"\f137"}.fa-chevron-circle-right:before{content:"\f138"}.fa-chevron-circle-up:before{content:"\f139"}.fa-chevron-circle-down:before{content:"\f13a"}.fa-html5:before{content:"\f13b"}.fa-css3:before{content:"\f13c"}.fa-anchor:before{content:"\f13d"}.fa-unlock-alt:before{content:"\f13e"}.fa-bullseye:before{content:"\f140"}.fa-ellipsis-h:before{content:"\f141"}.fa-ellipsis-v:before{content:"\f142"}.fa-rss-square:before{content:"\f143"}.fa-play-circle:before{content:"\f144"}.fa-ticket:before{content:"\f145"}.fa-minus-square:before{content:"\f146"}.fa-minus-square-o:before{content:"\f147"}.fa-level-up:before{content:"\f148"}.fa-level-down:before{content:"\f149"}.fa-check-square:before{content:"\f14a"}.fa-pencil-square:before{content:"\f14b"}.fa-external-link-square:before{content:"\f14c"}.fa-share-square:before{content:"\f14d"}.fa-compass:before{content:"\f14e"}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:"\f150"}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:"\f151"}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:"\f152"}.fa-euro:before,.fa-eur:before{content:"\f153"}.fa-gbp:before{content:"\f154"}.fa-dollar:before,.fa-usd:before{content:"\f155"}.fa-rupee:before,.fa-inr:before{content:"\f156"}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:"\f157"}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:"\f158"}.fa-won:before,.fa-krw:before{content:"\f159"}.fa-bitcoin:before,.fa-btc:before{content:"\f15a"}.fa-file:before{content:"\f15b"}.fa-file-text:before{content:"\f15c"}.fa-sort-alpha-asc:before{content:"\f15d"}.fa-sort-alpha-desc:before{content:"\f15e"}.fa-sort-amount-asc:before{content:"\f160"}.fa-sort-amount-desc:before{content:"\f161"}.fa-sort-numeric-asc:before{content:"\f162"}.fa-sort-numeric-desc:before{content:"\f163"}.fa-thumbs-up:before{content:"\f164"}.fa-thumbs-down:before{content:"\f165"}.fa-youtube-square:before{content:"\f166"}.fa-youtube:before{content:"\f167"}.fa-xing:before{content:"\f168"}.fa-xing-square:before{content:"\f169"}.fa-youtube-play:before{content:"\f16a"}.fa-dropbox:before{content:"\f16b"}.fa-stack-overflow:before{content:"\f16c"}.fa-instagram:before{content:"\f16d"}.fa-flickr:before{content:"\f16e"}.fa-adn:before{content:"\f170"}.fa-bitbucket:before{content:"\f171"}.fa-bitbucket-square:before{content:"\f172"}.fa-tumblr:before{content:"\f173"}.fa-tumblr-square:before{content:"\f174"}.fa-long-arrow-down:before{content:"\f175"}.fa-long-arrow-up:before{content:"\f176"}.fa-long-arrow-left:before{content:"\f177"}.fa-long-arrow-right:before{content:"\f178"}.fa-apple:before{content:"\f179"}.fa-windows:before{content:"\f17a"}.fa-android:before{content:"\f17b"}.fa-linux:before{content:"\f17c"}.fa-dribbble:before{content:"\f17d"}.fa-skype:before{content:"\f17e"}.fa-foursquare:before{content:"\f180"}.fa-trello:before{content:"\f181"}.fa-female:before{content:"\f182"}.fa-male:before{content:"\f183"}.fa-gittip:before,.fa-gratipay:before{content:"\f184"}.fa-sun-o:before{content:"\f185"}.fa-moon-o:before{content:"\f186"}.fa-archive:before{content:"\f187"}.fa-bug:before{content:"\f188"}.fa-vk:before{content:"\f189"}.fa-weibo:before{content:"\f18a"}.fa-renren:before{content:"\f18b"}.fa-pagelines:before{content:"\f18c"}.fa-stack-exchange:before{content:"\f18d"}.fa-arrow-circle-o-right:before{content:"\f18e"}.fa-arrow-circle-o-left:before{content:"\f190"}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:"\f191"}.fa-dot-circle-o:before{content:"\f192"}.fa-wheelchair:before{content:"\f193"}.fa-vimeo-square:before{content:"\f194"}.fa-turkish-lira:before,.fa-try:before{content:"\f195"}.fa-plus-square-o:before{content:"\f196"}.fa-space-shuttle:before{content:"\f197"}.fa-slack:before{content:"\f198"}.fa-envelope-square:before{content:"\f199"}.fa-wordpress:before{content:"\f19a"}.fa-openid:before{content:"\f19b"}.fa-institution:before,.fa-bank:before,.fa-university:before{content:"\f19c"}.fa-mortar-board:before,.fa-graduation-cap:before{content:"\f19d"}.fa-yahoo:before{content:"\f19e"}.fa-google:before{content:"\f1a0"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-square:before{content:"\f1a2"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-stumbleupon:before{content:"\f1a4"}.fa-delicious:before{content:"\f1a5"}.fa-digg:before{content:"\f1a6"}.fa-pied-piper-pp:before{content:"\f1a7"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-drupal:before{content:"\f1a9"}.fa-joomla:before{content:"\f1aa"}.fa-language:before{content:"\f1ab"}.fa-fax:before{content:"\f1ac"}.fa-building:before{content:"\f1ad"}.fa-child:before{content:"\f1ae"}.fa-paw:before{content:"\f1b0"}.fa-spoon:before{content:"\f1b1"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-behance:before{content:"\f1b4"}.fa-behance-square:before{content:"\f1b5"}.fa-steam:before{content:"\f1b6"}.fa-steam-square:before{content:"\f1b7"}.fa-recycle:before{content:"\f1b8"}.fa-automobile:before,.fa-car:before{content:"\f1b9"}.fa-cab:before,.fa-taxi:before{content:"\f1ba"}.fa-tree:before{content:"\f1bb"}.fa-spotify:before{content:"\f1bc"}.fa-deviantart:before{content:"\f1bd"}.fa-soundcloud:before{content:"\f1be"}.fa-database:before{content:"\f1c0"}.fa-file-pdf-o:before{content:"\f1c1"}.fa-file-word-o:before{content:"\f1c2"}.fa-file-excel-o:before{content:"\f1c3"}.fa-file-powerpoint-o:before{content:"\f1c4"}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:"\f1c5"}.fa-file-zip-o:before,.fa-file-archive-o:before{content:"\f1c6"}.fa-file-sound-o:before,.fa-file-audio-o:before{content:"\f1c7"}.fa-file-movie-o:before,.fa-file-video-o:before{content:"\f1c8"}.fa-file-code-o:before{content:"\f1c9"}.fa-vine:before{content:"\f1ca"}.fa-codepen:before{content:"\f1cb"}.fa-jsfiddle:before{content:"\f1cc"}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:"\f1cd"}.fa-circle-o-notch:before{content:"\f1ce"}.fa-ra:before,.fa-resistance:before,.fa-rebel:before{content:"\f1d0"}.fa-ge:before,.fa-empire:before{content:"\f1d1"}.fa-git-square:before{content:"\f1d2"}.fa-git:before{content:"\f1d3"}.fa-y-combinator-square:before,.fa-yc-square:before,.fa-hacker-news:before{content:"\f1d4"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-qq:before{content:"\f1d6"}.fa-wechat:before,.fa-weixin:before{content:"\f1d7"}.fa-send:before,.fa-paper-plane:before{content:"\f1d8"}.fa-send-o:before,.fa-paper-plane-o:before{content:"\f1d9"}.fa-history:before{content:"\f1da"}.fa-circle-thin:before{content:"\f1db"}.fa-header:before{content:"\f1dc"}.fa-paragraph:before{content:"\f1dd"}.fa-sliders:before{content:"\f1de"}.fa-share-alt:before{content:"\f1e0"}.fa-share-alt-square:before{content:"\f1e1"}.fa-bomb:before{content:"\f1e2"}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:"\f1e3"}.fa-tty:before{content:"\f1e4"}.fa-binoculars:before{content:"\f1e5"}.fa-plug:before{content:"\f1e6"}.fa-slideshare:before{content:"\f1e7"}.fa-twitch:before{content:"\f1e8"}.fa-yelp:before{content:"\f1e9"}.fa-newspaper-o:before{content:"\f1ea"}.fa-wifi:before{content:"\f1eb"}.fa-calculator:before{content:"\f1ec"}.fa-paypal:before{content:"\f1ed"}.fa-google-wallet:before{content:"\f1ee"}.fa-cc-visa:before{content:"\f1f0"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-bell-slash:before{content:"\f1f6"}.fa-bell-slash-o:before{content:"\f1f7"}.fa-trash:before{content:"\f1f8"}.fa-copyright:before{content:"\f1f9"}.fa-at:before{content:"\f1fa"}.fa-eyedropper:before{content:"\f1fb"}.fa-paint-brush:before{content:"\f1fc"}.fa-birthday-cake:before{content:"\f1fd"}.fa-area-chart:before{content:"\f1fe"}.fa-pie-chart:before{content:"\f200"}.fa-line-chart:before{content:"\f201"}.fa-lastfm:before{content:"\f202"}.fa-lastfm-square:before{content:"\f203"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-bicycle:before{content:"\f206"}.fa-bus:before{content:"\f207"}.fa-ioxhost:before{content:"\f208"}.fa-angellist:before{content:"\f209"}.fa-cc:before{content:"\f20a"}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:"\f20b"}.fa-meanpath:before{content:"\f20c"}.fa-buysellads:before{content:"\f20d"}.fa-connectdevelop:before{content:"\f20e"}.fa-dashcube:before{content:"\f210"}.fa-forumbee:before{content:"\f211"}.fa-leanpub:before{content:"\f212"}.fa-sellsy:before{content:"\f213"}.fa-shirtsinbulk:before{content:"\f214"}.fa-simplybuilt:before{content:"\f215"}.fa-skyatlas:before{content:"\f216"}.fa-cart-plus:before{content:"\f217"}.fa-cart-arrow-down:before{content:"\f218"}.fa-diamond:before{content:"\f219"}.fa-ship:before{content:"\f21a"}.fa-user-secret:before{content:"\f21b"}.fa-motorcycle:before{content:"\f21c"}.fa-street-view:before{content:"\f21d"}.fa-heartbeat:before{content:"\f21e"}.fa-venus:before{content:"\f221"}.fa-mars:before{content:"\f222"}.fa-mercury:before{content:"\f223"}.fa-intersex:before,.fa-transgender:before{content:"\f224"}.fa-transgender-alt:before{content:"\f225"}.fa-venus-double:before{content:"\f226"}.fa-mars-double:before{content:"\f227"}.fa-venus-mars:before{content:"\f228"}.fa-mars-stroke:before{content:"\f229"}.fa-mars-stroke-v:before{content:"\f22a"}.fa-mars-stroke-h:before{content:"\f22b"}.fa-neuter:before{content:"\f22c"}.fa-genderless:before{content:"\f22d"}.fa-facebook-official:before{content:"\f230"}.fa-pinterest-p:before{content:"\f231"}.fa-whatsapp:before{content:"\f232"}.fa-server:before{content:"\f233"}.fa-user-plus:before{content:"\f234"}.fa-user-times:before{content:"\f235"}.fa-hotel:before,.fa-bed:before{content:"\f236"}.fa-viacoin:before{content:"\f237"}.fa-train:before{content:"\f238"}.fa-subway:before{content:"\f239"}.fa-medium:before{content:"\f23a"}.fa-yc:before,.fa-y-combinator:before{content:"\f23b"}.fa-optin-monster:before{content:"\f23c"}.fa-opencart:before{content:"\f23d"}.fa-expeditedssl:before{content:"\f23e"}.fa-battery-4:before,.fa-battery:before,.fa-battery-full:before{content:"\f240"}.fa-battery-3:before,.fa-battery-three-quarters:before{content:"\f241"}.fa-battery-2:before,.fa-battery-half:before{content:"\f242"}.fa-battery-1:before,.fa-battery-quarter:before{content:"\f243"}.fa-battery-0:before,.fa-battery-empty:before{content:"\f244"}.fa-mouse-pointer:before{content:"\f245"}.fa-i-cursor:before{content:"\f246"}.fa-object-group:before{content:"\f247"}.fa-object-ungroup:before{content:"\f248"}.fa-sticky-note:before{content:"\f249"}.fa-sticky-note-o:before{content:"\f24a"}.fa-cc-jcb:before{content:"\f24b"}.fa-cc-diners-club:before{content:"\f24c"}.fa-clone:before{content:"\f24d"}.fa-balance-scale:before{content:"\f24e"}.fa-hourglass-o:before{content:"\f250"}.fa-hourglass-1:before,.fa-hourglass-start:before{content:"\f251"}.fa-hourglass-2:before,.fa-hourglass-half:before{content:"\f252"}.fa-hourglass-3:before,.fa-hourglass-end:before{content:"\f253"}.fa-hourglass:before{content:"\f254"}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:"\f255"}.fa-hand-stop-o:before,.fa-hand-paper-o:before{content:"\f256"}.fa-hand-scissors-o:before{content:"\f257"}.fa-hand-lizard-o:before{content:"\f258"}.fa-hand-spock-o:before{content:"\f259"}.fa-hand-pointer-o:before{content:"\f25a"}.fa-hand-peace-o:before{content:"\f25b"}.fa-trademark:before{content:"\f25c"}.fa-registered:before{content:"\f25d"}.fa-creative-commons:before{content:"\f25e"}.fa-gg:before{content:"\f260"}.fa-gg-circle:before{content:"\f261"}.fa-tripadvisor:before{content:"\f262"}.fa-odnoklassniki:before{content:"\f263"}.fa-odnoklassniki-square:before{content:"\f264"}.fa-get-pocket:before{content:"\f265"}.fa-wikipedia-w:before{content:"\f266"}.fa-safari:before{content:"\f267"}.fa-chrome:before{content:"\f268"}.fa-firefox:before{content:"\f269"}.fa-opera:before{content:"\f26a"}.fa-internet-explorer:before{content:"\f26b"}.fa-tv:before,.fa-television:before{content:"\f26c"}.fa-contao:before{content:"\f26d"}.fa-500px:before{content:"\f26e"}.fa-amazon:before{content:"\f270"}.fa-calendar-plus-o:before{content:"\f271"}.fa-calendar-minus-o:before{content:"\f272"}.fa-calendar-times-o:before{content:"\f273"}.fa-calendar-check-o:before{content:"\f274"}.fa-industry:before{content:"\f275"}.fa-map-pin:before{content:"\f276"}.fa-map-signs:before{content:"\f277"}.fa-map-o:before{content:"\f278"}.fa-map:before{content:"\f279"}.fa-commenting:before{content:"\f27a"}.fa-commenting-o:before{content:"\f27b"}.fa-houzz:before{content:"\f27c"}.fa-vimeo:before{content:"\f27d"}.fa-black-tie:before{content:"\f27e"}.fa-fonticons:before{content:"\f280"}.fa-reddit-alien:before{content:"\f281"}.fa-edge:before{content:"\f282"}.fa-credit-card-alt:before{content:"\f283"}.fa-codiepie:before{content:"\f284"}.fa-modx:before{content:"\f285"}.fa-fort-awesome:before{content:"\f286"}.fa-usb:before{content:"\f287"}.fa-product-hunt:before{content:"\f288"}.fa-mixcloud:before{content:"\f289"}.fa-scribd:before{content:"\f28a"}.fa-pause-circle:before{content:"\f28b"}.fa-pause-circle-o:before{content:"\f28c"}.fa-stop-circle:before{content:"\f28d"}.fa-stop-circle-o:before{content:"\f28e"}.fa-shopping-bag:before{content:"\f290"}.fa-shopping-basket:before{content:"\f291"}.fa-hashtag:before{content:"\f292"}.fa-bluetooth:before{content:"\f293"}.fa-bluetooth-b:before{content:"\f294"}.fa-percent:before{content:"\f295"}.fa-gitlab:before{content:"\f296"}.fa-wpbeginner:before{content:"\f297"}.fa-wpforms:before{content:"\f298"}.fa-envira:before{content:"\f299"}.fa-universal-access:before{content:"\f29a"}.fa-wheelchair-alt:before{content:"\f29b"}.fa-question-circle-o:before{content:"\f29c"}.fa-blind:before{content:"\f29d"}.fa-audio-description:before{content:"\f29e"}.fa-volume-control-phone:before{content:"\f2a0"}.fa-braille:before{content:"\f2a1"}.fa-assistive-listening-systems:before{content:"\f2a2"}.fa-asl-interpreting:before,.fa-american-sign-language-interpreting:before{content:"\f2a3"}.fa-deafness:before,.fa-hard-of-hearing:before,.fa-deaf:before{content:"\f2a4"}.fa-glide:before{content:"\f2a5"}.fa-glide-g:before{content:"\f2a6"}.fa-signing:before,.fa-sign-language:before{content:"\f2a7"}.fa-low-vision:before{content:"\f2a8"}.fa-viadeo:before{content:"\f2a9"}.fa-viadeo-square:before{content:"\f2aa"}.fa-snapchat:before{content:"\f2ab"}.fa-snapchat-ghost:before{content:"\f2ac"}.fa-snapchat-square:before{content:"\f2ad"}.fa-pied-piper:before{content:"\f2ae"}.fa-first-order:before{content:"\f2b0"}.fa-yoast:before{content:"\f2b1"}.fa-themeisle:before{content:"\f2b2"}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:"\f2b3"}.fa-fa:before,.fa-font-awesome:before{content:"\f2b4"}.fa-handshake-o:before{content:"\f2b5"}.fa-envelope-open:before{content:"\f2b6"}.fa-envelope-open-o:before{content:"\f2b7"}.fa-linode:before{content:"\f2b8"}.fa-address-book:before{content:"\f2b9"}.fa-address-book-o:before{content:"\f2ba"}.fa-vcard:before,.fa-address-card:before{content:"\f2bb"}.fa-vcard-o:before,.fa-address-card-o:before{content:"\f2bc"}.fa-user-circle:before{content:"\f2bd"}.fa-user-circle-o:before{content:"\f2be"}.fa-user-o:before{content:"\f2c0"}.fa-id-badge:before{content:"\f2c1"}.fa-drivers-license:before,.fa-id-card:before{content:"\f2c2"}.fa-drivers-license-o:before,.fa-id-card-o:before{content:"\f2c3"}.fa-quora:before{content:"\f2c4"}.fa-free-code-camp:before{content:"\f2c5"}.fa-telegram:before{content:"\f2c6"}.fa-thermometer-4:before,.fa-thermometer:before,.fa-thermometer-full:before{content:"\f2c7"}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:"\f2c8"}.fa-thermometer-2:before,.fa-thermometer-half:before{content:"\f2c9"}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:"\f2ca"}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:"\f2cb"}.fa-shower:before{content:"\f2cc"}.fa-bathtub:before,.fa-s15:before,.fa-bath:before{content:"\f2cd"}.fa-podcast:before{content:"\f2ce"}.fa-window-maximize:before{content:"\f2d0"}.fa-window-minimize:before{content:"\f2d1"}.fa-window-restore:before{content:"\f2d2"}.fa-times-rectangle:before,.fa-window-close:before{content:"\f2d3"}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:"\f2d4"}.fa-bandcamp:before{content:"\f2d5"}.fa-grav:before{content:"\f2d6"}.fa-etsy:before{content:"\f2d7"}.fa-imdb:before{content:"\f2d8"}.fa-ravelry:before{content:"\f2d9"}.fa-eercast:before{content:"\f2da"}.fa-microchip:before{content:"\f2db"}.fa-snowflake-o:before{content:"\f2dc"}.fa-superpowers:before{content:"\f2dd"}.fa-wpexplorer:before{content:"\f2de"}.fa-meetup:before{content:"\f2e0"}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}
diff --git a/app/browser/fonts/fontawesome-webfont.woff b/app/browser/fonts/fontawesome-webfont.woff
deleted file mode 100644
index 400014a4..00000000
Binary files a/app/browser/fonts/fontawesome-webfont.woff and /dev/null differ
diff --git a/app/browser/fonts/fontawesome.min.css b/app/browser/fonts/fontawesome.min.css
new file mode 100644
index 00000000..7b36b77f
--- /dev/null
+++ b/app/browser/fonts/fontawesome.min.css
@@ -0,0 +1,5 @@
+/*!
+ * Font Awesome Free 5.0.0 by @fontawesome - http://fontawesome.com
+ * License - http://fontawesome.com/license (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
+ */
+.fa,.fab,.fal,.far,.fas{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:inline-block;font-style:normal;font-variant:normal;text-rendering:auto;line-height:1}.fa-lg{font-size:1.33333em;line-height:.75em;vertical-align:-.0667em}.fa-xs{font-size:.75em}.fa-sm{font-size:.875em}.fa-1x{font-size:1em}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-6x{font-size:6em}.fa-7x{font-size:7em}.fa-8x{font-size:8em}.fa-9x{font-size:9em}.fa-10x{font-size:10em}.fa-fw{text-align:center;width:1.25em}.fa-ul{list-style-type:none;margin-left:2.5em;padding-left:0}.fa-ul>li{position:relative}.fa-li{left:-2em;position:absolute;text-align:center;width:2em;line-height:inherit}.fa-border{border:.08em solid #eee;border-radius:.1em;padding:.2em .25em .15em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left,.fab.fa-pull-left,.fal.fa-pull-left,.far.fa-pull-left,.fas.fa-pull-left{margin-right:.3em}.fa.fa-pull-right,.fab.fa-pull-right,.fal.fa-pull-right,.far.fa-pull-right,.fas.fa-pull-right{margin-left:.3em}.fa-spin{-webkit-animation:a 2s infinite linear;animation:a 2s infinite linear}.fa-pulse{-webkit-animation:a 1s infinite steps(8);animation:a 1s infinite steps(8)}@-webkit-keyframes a{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes a{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scaleX(-1);transform:scaleX(-1)}.fa-flip-vertical{-webkit-transform:scaleY(-1);transform:scaleY(-1)}.fa-flip-horizontal.fa-flip-vertical,.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)"}.fa-flip-horizontal.fa-flip-vertical{-webkit-transform:scale(-1);transform:scale(-1)}:root .fa-flip-horizontal,:root .fa-flip-vertical,:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270{-webkit-filter:none;filter:none}.fa-stack{display:inline-block;height:2em;line-height:2em;position:relative;vertical-align:middle;width:2em}.fa-stack-1x,.fa-stack-2x{left:0;position:absolute;text-align:center;width:100%}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-500px:before{content:"\f26e"}.fa-accessible-icon:before{content:"\f368"}.fa-accusoft:before{content:"\f369"}.fa-address-book:before{content:"\f2b9"}.fa-address-card:before{content:"\f2bb"}.fa-adjust:before{content:"\f042"}.fa-adn:before{content:"\f170"}.fa-adversal:before{content:"\f36a"}.fa-affiliatetheme:before{content:"\f36b"}.fa-algolia:before{content:"\f36c"}.fa-align-center:before{content:"\f037"}.fa-align-justify:before{content:"\f039"}.fa-align-left:before{content:"\f036"}.fa-align-right:before{content:"\f038"}.fa-amazon:before{content:"\f270"}.fa-ambulance:before{content:"\f0f9"}.fa-american-sign-language-interpreting:before{content:"\f2a3"}.fa-amilia:before{content:"\f36d"}.fa-anchor:before{content:"\f13d"}.fa-android:before{content:"\f17b"}.fa-angellist:before{content:"\f209"}.fa-angle-double-down:before{content:"\f103"}.fa-angle-double-left:before{content:"\f100"}.fa-angle-double-right:before{content:"\f101"}.fa-angle-double-up:before{content:"\f102"}.fa-angle-down:before{content:"\f107"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angrycreative:before{content:"\f36e"}.fa-angular:before{content:"\f420"}.fa-app-store:before{content:"\f36f"}.fa-app-store-ios:before{content:"\f370"}.fa-apper:before{content:"\f371"}.fa-apple:before{content:"\f179"}.fa-apple-pay:before{content:"\f415"}.fa-archive:before{content:"\f187"}.fa-arrow-alt-circle-down:before{content:"\f358"}.fa-arrow-alt-circle-left:before{content:"\f359"}.fa-arrow-alt-circle-right:before{content:"\f35a"}.fa-arrow-alt-circle-up:before{content:"\f35b"}.fa-arrow-circle-down:before{content:"\f0ab"}.fa-arrow-circle-left:before{content:"\f0a8"}.fa-arrow-circle-right:before{content:"\f0a9"}.fa-arrow-circle-up:before{content:"\f0aa"}.fa-arrow-down:before{content:"\f063"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-up:before{content:"\f062"}.fa-arrows-alt:before{content:"\f0b2"}.fa-arrows-alt-h:before{content:"\f337"}.fa-arrows-alt-v:before{content:"\f338"}.fa-assistive-listening-systems:before{content:"\f2a2"}.fa-asterisk:before{content:"\f069"}.fa-asymmetrik:before{content:"\f372"}.fa-at:before{content:"\f1fa"}.fa-audible:before{content:"\f373"}.fa-audio-description:before{content:"\f29e"}.fa-autoprefixer:before{content:"\f41c"}.fa-avianex:before{content:"\f374"}.fa-aviato:before{content:"\f421"}.fa-aws:before{content:"\f375"}.fa-backward:before{content:"\f04a"}.fa-balance-scale:before{content:"\f24e"}.fa-ban:before{content:"\f05e"}.fa-bandcamp:before{content:"\f2d5"}.fa-barcode:before{content:"\f02a"}.fa-bars:before{content:"\f0c9"}.fa-bath:before{content:"\f2cd"}.fa-battery-empty:before{content:"\f244"}.fa-battery-full:before{content:"\f240"}.fa-battery-half:before{content:"\f242"}.fa-battery-quarter:before{content:"\f243"}.fa-battery-three-quarters:before{content:"\f241"}.fa-bed:before{content:"\f236"}.fa-beer:before{content:"\f0fc"}.fa-behance:before{content:"\f1b4"}.fa-behance-square:before{content:"\f1b5"}.fa-bell:before{content:"\f0f3"}.fa-bell-slash:before{content:"\f1f6"}.fa-bicycle:before{content:"\f206"}.fa-bimobject:before{content:"\f378"}.fa-binoculars:before{content:"\f1e5"}.fa-birthday-cake:before{content:"\f1fd"}.fa-bitbucket:before{content:"\f171"}.fa-bitcoin:before{content:"\f379"}.fa-bity:before{content:"\f37a"}.fa-black-tie:before{content:"\f27e"}.fa-blackberry:before{content:"\f37b"}.fa-blind:before{content:"\f29d"}.fa-blogger:before{content:"\f37c"}.fa-blogger-b:before{content:"\f37d"}.fa-bluetooth:before{content:"\f293"}.fa-bluetooth-b:before{content:"\f294"}.fa-bold:before{content:"\f032"}.fa-bolt:before{content:"\f0e7"}.fa-bomb:before{content:"\f1e2"}.fa-book:before{content:"\f02d"}.fa-bookmark:before{content:"\f02e"}.fa-braille:before{content:"\f2a1"}.fa-briefcase:before{content:"\f0b1"}.fa-btc:before{content:"\f15a"}.fa-bug:before{content:"\f188"}.fa-building:before{content:"\f1ad"}.fa-bullhorn:before{content:"\f0a1"}.fa-bullseye:before{content:"\f140"}.fa-buromobelexperte:before{content:"\f37f"}.fa-bus:before{content:"\f207"}.fa-buysellads:before{content:"\f20d"}.fa-calculator:before{content:"\f1ec"}.fa-calendar:before{content:"\f133"}.fa-calendar-alt:before{content:"\f073"}.fa-calendar-check:before{content:"\f274"}.fa-calendar-minus:before{content:"\f272"}.fa-calendar-plus:before{content:"\f271"}.fa-calendar-times:before{content:"\f273"}.fa-camera:before{content:"\f030"}.fa-camera-retro:before{content:"\f083"}.fa-car:before{content:"\f1b9"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-caret-square-down:before{content:"\f150"}.fa-caret-square-left:before{content:"\f191"}.fa-caret-square-right:before{content:"\f152"}.fa-caret-square-up:before{content:"\f151"}.fa-caret-up:before{content:"\f0d8"}.fa-cart-arrow-down:before{content:"\f218"}.fa-cart-plus:before{content:"\f217"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-apple-pay:before{content:"\f416"}.fa-cc-diners-club:before{content:"\f24c"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-jcb:before{content:"\f24b"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-cc-visa:before{content:"\f1f0"}.fa-centercode:before{content:"\f380"}.fa-certificate:before{content:"\f0a3"}.fa-chart-area:before{content:"\f1fe"}.fa-chart-bar:before{content:"\f080"}.fa-chart-line:before{content:"\f201"}.fa-chart-pie:before{content:"\f200"}.fa-check:before{content:"\f00c"}.fa-check-circle:before{content:"\f058"}.fa-check-square:before{content:"\f14a"}.fa-chevron-circle-down:before{content:"\f13a"}.fa-chevron-circle-left:before{content:"\f137"}.fa-chevron-circle-right:before{content:"\f138"}.fa-chevron-circle-up:before{content:"\f139"}.fa-chevron-down:before{content:"\f078"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-chevron-up:before{content:"\f077"}.fa-child:before{content:"\f1ae"}.fa-chrome:before{content:"\f268"}.fa-circle:before{content:"\f111"}.fa-circle-notch:before{content:"\f1ce"}.fa-clipboard:before{content:"\f328"}.fa-clock:before{content:"\f017"}.fa-clone:before{content:"\f24d"}.fa-closed-captioning:before{content:"\f20a"}.fa-cloud:before{content:"\f0c2"}.fa-cloud-download-alt:before{content:"\f381"}.fa-cloud-upload-alt:before{content:"\f382"}.fa-cloudscale:before{content:"\f383"}.fa-cloudsmith:before{content:"\f384"}.fa-cloudversify:before{content:"\f385"}.fa-code:before{content:"\f121"}.fa-code-branch:before{content:"\f126"}.fa-codepen:before{content:"\f1cb"}.fa-codiepie:before{content:"\f284"}.fa-coffee:before{content:"\f0f4"}.fa-cog:before{content:"\f013"}.fa-cogs:before{content:"\f085"}.fa-columns:before{content:"\f0db"}.fa-comment:before{content:"\f075"}.fa-comment-alt:before{content:"\f27a"}.fa-comments:before{content:"\f086"}.fa-compass:before{content:"\f14e"}.fa-compress:before{content:"\f066"}.fa-connectdevelop:before{content:"\f20e"}.fa-contao:before{content:"\f26d"}.fa-copy:before{content:"\f0c5"}.fa-copyright:before{content:"\f1f9"}.fa-cpanel:before{content:"\f388"}.fa-creative-commons:before{content:"\f25e"}.fa-credit-card:before{content:"\f09d"}.fa-crop:before{content:"\f125"}.fa-crosshairs:before{content:"\f05b"}.fa-css3:before{content:"\f13c"}.fa-css3-alt:before{content:"\f38b"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-cut:before{content:"\f0c4"}.fa-cuttlefish:before{content:"\f38c"}.fa-d-and-d:before{content:"\f38d"}.fa-dashcube:before{content:"\f210"}.fa-database:before{content:"\f1c0"}.fa-deaf:before{content:"\f2a4"}.fa-delicious:before{content:"\f1a5"}.fa-deploydog:before{content:"\f38e"}.fa-deskpro:before{content:"\f38f"}.fa-desktop:before{content:"\f108"}.fa-deviantart:before{content:"\f1bd"}.fa-digg:before{content:"\f1a6"}.fa-digital-ocean:before{content:"\f391"}.fa-discord:before{content:"\f392"}.fa-discourse:before{content:"\f393"}.fa-dochub:before{content:"\f394"}.fa-docker:before{content:"\f395"}.fa-dollar-sign:before{content:"\f155"}.fa-dot-circle:before{content:"\f192"}.fa-download:before{content:"\f019"}.fa-draft2digital:before{content:"\f396"}.fa-dribbble:before{content:"\f17d"}.fa-dribbble-square:before{content:"\f397"}.fa-dropbox:before{content:"\f16b"}.fa-dropbox-alt:before{content:"\f398"}.fa-drupal:before{content:"\f1a9"}.fa-dyalog:before{content:"\f399"}.fa-earlybirds:before{content:"\f39a"}.fa-edge:before{content:"\f282"}.fa-edit:before{content:"\f044"}.fa-eject:before{content:"\f052"}.fa-ellipsis-h:before{content:"\f141"}.fa-ellipsis-v:before{content:"\f142"}.fa-ember:before{content:"\f423"}.fa-empire:before{content:"\f1d1"}.fa-envelope:before{content:"\f0e0"}.fa-envelope-open:before{content:"\f2b6"}.fa-envelope-square:before{content:"\f199"}.fa-envira:before{content:"\f299"}.fa-eraser:before{content:"\f12d"}.fa-erlang:before{content:"\f39d"}.fa-etsy:before{content:"\f2d7"}.fa-euro-sign:before{content:"\f153"}.fa-exchange-alt:before{content:"\f362"}.fa-exclamation:before{content:"\f12a"}.fa-exclamation-circle:before{content:"\f06a"}.fa-exclamation-triangle:before{content:"\f071"}.fa-expand:before{content:"\f065"}.fa-expand-arrows-alt:before{content:"\f31e"}.fa-expeditedssl:before{content:"\f23e"}.fa-external-link-alt:before{content:"\f35d"}.fa-external-link-square-alt:before{content:"\f360"}.fa-eye:before{content:"\f06e"}.fa-eye-dropper:before{content:"\f1fb"}.fa-eye-slash:before{content:"\f070"}.fa-facebook:before{content:"\f09a"}.fa-facebook-f:before{content:"\f39e"}.fa-facebook-messenger:before{content:"\f39f"}.fa-facebook-square:before{content:"\f082"}.fa-fast-backward:before{content:"\f049"}.fa-fast-forward:before{content:"\f050"}.fa-fax:before{content:"\f1ac"}.fa-female:before{content:"\f182"}.fa-fighter-jet:before{content:"\f0fb"}.fa-file:before{content:"\f15b"}.fa-file-alt:before{content:"\f15c"}.fa-file-archive:before{content:"\f1c6"}.fa-file-audio:before{content:"\f1c7"}.fa-file-code:before{content:"\f1c9"}.fa-file-excel:before{content:"\f1c3"}.fa-file-image:before{content:"\f1c5"}.fa-file-pdf:before{content:"\f1c1"}.fa-file-powerpoint:before{content:"\f1c4"}.fa-file-video:before{content:"\f1c8"}.fa-file-word:before{content:"\f1c2"}.fa-film:before{content:"\f008"}.fa-filter:before{content:"\f0b0"}.fa-fire:before{content:"\f06d"}.fa-fire-extinguisher:before{content:"\f134"}.fa-firefox:before{content:"\f269"}.fa-first-order:before{content:"\f2b0"}.fa-firstdraft:before{content:"\f3a1"}.fa-flag:before{content:"\f024"}.fa-flag-checkered:before{content:"\f11e"}.fa-flask:before{content:"\f0c3"}.fa-flickr:before{content:"\f16e"}.fa-fly:before{content:"\f417"}.fa-folder:before{content:"\f07b"}.fa-folder-open:before{content:"\f07c"}.fa-font:before{content:"\f031"}.fa-font-awesome:before{content:"\f2b4"}.fa-font-awesome-alt:before{content:"\f35c"}.fa-fonticons:before{content:"\f280"}.fa-fonticons-fi:before{content:"\f3a2"}.fa-fort-awesome:before{content:"\f286"}.fa-fort-awesome-alt:before{content:"\f3a3"}.fa-forumbee:before{content:"\f211"}.fa-forward:before{content:"\f04e"}.fa-foursquare:before{content:"\f180"}.fa-free-code-camp:before{content:"\f2c5"}.fa-freebsd:before{content:"\f3a4"}.fa-frown:before{content:"\f119"}.fa-futbol:before{content:"\f1e3"}.fa-gamepad:before{content:"\f11b"}.fa-gavel:before{content:"\f0e3"}.fa-gem:before{content:"\f3a5"}.fa-genderless:before{content:"\f22d"}.fa-get-pocket:before{content:"\f265"}.fa-gg:before{content:"\f260"}.fa-gg-circle:before{content:"\f261"}.fa-gift:before{content:"\f06b"}.fa-git:before{content:"\f1d3"}.fa-git-square:before{content:"\f1d2"}.fa-github:before{content:"\f09b"}.fa-github-alt:before{content:"\f113"}.fa-github-square:before{content:"\f092"}.fa-gitkraken:before{content:"\f3a6"}.fa-gitlab:before{content:"\f296"}.fa-gitter:before{content:"\f426"}.fa-glass-martini:before{content:"\f000"}.fa-glide:before{content:"\f2a5"}.fa-glide-g:before{content:"\f2a6"}.fa-globe:before{content:"\f0ac"}.fa-gofore:before{content:"\f3a7"}.fa-goodreads:before{content:"\f3a8"}.fa-goodreads-g:before{content:"\f3a9"}.fa-google:before{content:"\f1a0"}.fa-google-drive:before{content:"\f3aa"}.fa-google-play:before{content:"\f3ab"}.fa-google-plus:before{content:"\f2b3"}.fa-google-plus-g:before{content:"\f0d5"}.fa-google-plus-square:before{content:"\f0d4"}.fa-google-wallet:before{content:"\f1ee"}.fa-graduation-cap:before{content:"\f19d"}.fa-gratipay:before{content:"\f184"}.fa-grav:before{content:"\f2d6"}.fa-gripfire:before{content:"\f3ac"}.fa-grunt:before{content:"\f3ad"}.fa-gulp:before{content:"\f3ae"}.fa-h-square:before{content:"\f0fd"}.fa-hacker-news:before{content:"\f1d4"}.fa-hacker-news-square:before{content:"\f3af"}.fa-hand-lizard:before{content:"\f258"}.fa-hand-paper:before{content:"\f256"}.fa-hand-peace:before{content:"\f25b"}.fa-hand-point-down:before{content:"\f0a7"}.fa-hand-point-left:before{content:"\f0a5"}.fa-hand-point-right:before{content:"\f0a4"}.fa-hand-point-up:before{content:"\f0a6"}.fa-hand-pointer:before{content:"\f25a"}.fa-hand-rock:before{content:"\f255"}.fa-hand-scissors:before{content:"\f257"}.fa-hand-spock:before{content:"\f259"}.fa-handshake:before{content:"\f2b5"}.fa-hashtag:before{content:"\f292"}.fa-hdd:before{content:"\f0a0"}.fa-heading:before{content:"\f1dc"}.fa-headphones:before{content:"\f025"}.fa-heart:before{content:"\f004"}.fa-heartbeat:before{content:"\f21e"}.fa-hire-a-helper:before{content:"\f3b0"}.fa-history:before{content:"\f1da"}.fa-home:before{content:"\f015"}.fa-hooli:before{content:"\f427"}.fa-hospital:before{content:"\f0f8"}.fa-hotjar:before{content:"\f3b1"}.fa-hourglass:before{content:"\f254"}.fa-hourglass-end:before{content:"\f253"}.fa-hourglass-half:before{content:"\f252"}.fa-hourglass-start:before{content:"\f251"}.fa-houzz:before{content:"\f27c"}.fa-html5:before{content:"\f13b"}.fa-hubspot:before{content:"\f3b2"}.fa-i-cursor:before{content:"\f246"}.fa-id-badge:before{content:"\f2c1"}.fa-id-card:before{content:"\f2c2"}.fa-image:before{content:"\f03e"}.fa-images:before{content:"\f302"}.fa-imdb:before{content:"\f2d8"}.fa-inbox:before{content:"\f01c"}.fa-indent:before{content:"\f03c"}.fa-industry:before{content:"\f275"}.fa-info:before{content:"\f129"}.fa-info-circle:before{content:"\f05a"}.fa-instagram:before{content:"\f16d"}.fa-internet-explorer:before{content:"\f26b"}.fa-ioxhost:before{content:"\f208"}.fa-italic:before{content:"\f033"}.fa-itunes:before{content:"\f3b4"}.fa-itunes-note:before{content:"\f3b5"}.fa-jenkins:before{content:"\f3b6"}.fa-joget:before{content:"\f3b7"}.fa-joomla:before{content:"\f1aa"}.fa-js:before{content:"\f3b8"}.fa-js-square:before{content:"\f3b9"}.fa-jsfiddle:before{content:"\f1cc"}.fa-key:before{content:"\f084"}.fa-keyboard:before{content:"\f11c"}.fa-keycdn:before{content:"\f3ba"}.fa-kickstarter:before{content:"\f3bb"}.fa-kickstarter-k:before{content:"\f3bc"}.fa-language:before{content:"\f1ab"}.fa-laptop:before{content:"\f109"}.fa-laravel:before{content:"\f3bd"}.fa-lastfm:before{content:"\f202"}.fa-lastfm-square:before{content:"\f203"}.fa-leaf:before{content:"\f06c"}.fa-leanpub:before{content:"\f212"}.fa-lemon:before{content:"\f094"}.fa-less:before{content:"\f41d"}.fa-level-down-alt:before{content:"\f3be"}.fa-level-up-alt:before{content:"\f3bf"}.fa-life-ring:before{content:"\f1cd"}.fa-lightbulb:before{content:"\f0eb"}.fa-line:before{content:"\f3c0"}.fa-link:before{content:"\f0c1"}.fa-linkedin:before{content:"\f08c"}.fa-linkedin-in:before{content:"\f0e1"}.fa-linode:before{content:"\f2b8"}.fa-linux:before{content:"\f17c"}.fa-lira-sign:before{content:"\f195"}.fa-list:before{content:"\f03a"}.fa-list-alt:before{content:"\f022"}.fa-list-ol:before{content:"\f0cb"}.fa-list-ul:before{content:"\f0ca"}.fa-location-arrow:before{content:"\f124"}.fa-lock:before{content:"\f023"}.fa-long-arrow-alt-down:before{content:"\f309"}.fa-long-arrow-alt-left:before{content:"\f30a"}.fa-long-arrow-alt-right:before{content:"\f30b"}.fa-long-arrow-alt-up:before{content:"\f30c"}.fa-low-vision:before{content:"\f2a8"}.fa-lyft:before{content:"\f3c3"}.fa-magento:before{content:"\f3c4"}.fa-magic:before{content:"\f0d0"}.fa-magnet:before{content:"\f076"}.fa-male:before{content:"\f183"}.fa-map:before{content:"\f279"}.fa-map-marker:before{content:"\f041"}.fa-map-marker-alt:before{content:"\f3c5"}.fa-map-pin:before{content:"\f276"}.fa-map-signs:before{content:"\f277"}.fa-mars:before{content:"\f222"}.fa-mars-double:before{content:"\f227"}.fa-mars-stroke:before{content:"\f229"}.fa-mars-stroke-h:before{content:"\f22b"}.fa-mars-stroke-v:before{content:"\f22a"}.fa-maxcdn:before{content:"\f136"}.fa-medapps:before{content:"\f3c6"}.fa-medium:before{content:"\f23a"}.fa-medium-m:before{content:"\f3c7"}.fa-medkit:before{content:"\f0fa"}.fa-medrt:before{content:"\f3c8"}.fa-meetup:before{content:"\f2e0"}.fa-meh:before{content:"\f11a"}.fa-mercury:before{content:"\f223"}.fa-microchip:before{content:"\f2db"}.fa-microphone:before{content:"\f130"}.fa-microphone-slash:before{content:"\f131"}.fa-microsoft:before{content:"\f3ca"}.fa-minus:before{content:"\f068"}.fa-minus-circle:before{content:"\f056"}.fa-minus-square:before{content:"\f146"}.fa-mix:before{content:"\f3cb"}.fa-mixcloud:before{content:"\f289"}.fa-mizuni:before{content:"\f3cc"}.fa-mobile:before{content:"\f10b"}.fa-mobile-alt:before{content:"\f3cd"}.fa-modx:before{content:"\f285"}.fa-monero:before{content:"\f3d0"}.fa-money-bill-alt:before{content:"\f3d1"}.fa-moon:before{content:"\f186"}.fa-motorcycle:before{content:"\f21c"}.fa-mouse-pointer:before{content:"\f245"}.fa-music:before{content:"\f001"}.fa-napster:before{content:"\f3d2"}.fa-neuter:before{content:"\f22c"}.fa-newspaper:before{content:"\f1ea"}.fa-nintendo-switch:before{content:"\f418"}.fa-node:before{content:"\f419"}.fa-node-js:before{content:"\f3d3"}.fa-npm:before{content:"\f3d4"}.fa-ns8:before{content:"\f3d5"}.fa-nutritionix:before{content:"\f3d6"}.fa-object-group:before{content:"\f247"}.fa-object-ungroup:before{content:"\f248"}.fa-odnoklassniki:before{content:"\f263"}.fa-odnoklassniki-square:before{content:"\f264"}.fa-opencart:before{content:"\f23d"}.fa-openid:before{content:"\f19b"}.fa-opera:before{content:"\f26a"}.fa-optin-monster:before{content:"\f23c"}.fa-osi:before{content:"\f41a"}.fa-outdent:before{content:"\f03b"}.fa-page4:before{content:"\f3d7"}.fa-pagelines:before{content:"\f18c"}.fa-paint-brush:before{content:"\f1fc"}.fa-palfed:before{content:"\f3d8"}.fa-paper-plane:before{content:"\f1d8"}.fa-paperclip:before{content:"\f0c6"}.fa-paragraph:before{content:"\f1dd"}.fa-paste:before{content:"\f0ea"}.fa-patreon:before{content:"\f3d9"}.fa-pause:before{content:"\f04c"}.fa-pause-circle:before{content:"\f28b"}.fa-paw:before{content:"\f1b0"}.fa-paypal:before{content:"\f1ed"}.fa-pen-square:before{content:"\f14b"}.fa-pencil-alt:before{content:"\f303"}.fa-percent:before{content:"\f295"}.fa-periscope:before{content:"\f3da"}.fa-phabricator:before{content:"\f3db"}.fa-phoenix-framework:before{content:"\f3dc"}.fa-phone:before{content:"\f095"}.fa-phone-square:before{content:"\f098"}.fa-phone-volume:before{content:"\f2a0"}.fa-pied-piper:before{content:"\f2ae"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-pied-piper-pp:before{content:"\f1a7"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-p:before{content:"\f231"}.fa-pinterest-square:before{content:"\f0d3"}.fa-plane:before{content:"\f072"}.fa-play:before{content:"\f04b"}.fa-play-circle:before{content:"\f144"}.fa-playstation:before{content:"\f3df"}.fa-plug:before{content:"\f1e6"}.fa-plus:before{content:"\f067"}.fa-plus-circle:before{content:"\f055"}.fa-plus-square:before{content:"\f0fe"}.fa-podcast:before{content:"\f2ce"}.fa-pound-sign:before{content:"\f154"}.fa-power-off:before{content:"\f011"}.fa-print:before{content:"\f02f"}.fa-product-hunt:before{content:"\f288"}.fa-pushed:before{content:"\f3e1"}.fa-puzzle-piece:before{content:"\f12e"}.fa-python:before{content:"\f3e2"}.fa-qq:before{content:"\f1d6"}.fa-qrcode:before{content:"\f029"}.fa-question:before{content:"\f128"}.fa-question-circle:before{content:"\f059"}.fa-quora:before{content:"\f2c4"}.fa-quote-left:before{content:"\f10d"}.fa-quote-right:before{content:"\f10e"}.fa-random:before{content:"\f074"}.fa-ravelry:before{content:"\f2d9"}.fa-react:before{content:"\f41b"}.fa-rebel:before{content:"\f1d0"}.fa-recycle:before{content:"\f1b8"}.fa-red-river:before{content:"\f3e3"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-alien:before{content:"\f281"}.fa-reddit-square:before{content:"\f1a2"}.fa-redo:before{content:"\f01e"}.fa-registered:before{content:"\f25d"}.fa-rendact:before{content:"\f3e4"}.fa-renren:before{content:"\f18b"}.fa-reply:before{content:"\f3e5"}.fa-reply-all:before{content:"\f122"}.fa-replyd:before{content:"\f3e6"}.fa-resolving:before{content:"\f3e7"}.fa-retweet:before{content:"\f079"}.fa-road:before{content:"\f018"}.fa-rocket:before{content:"\f135"}.fa-rocketchat:before{content:"\f3e8"}.fa-rockrms:before{content:"\f3e9"}.fa-rss:before{content:"\f09e"}.fa-rss-square:before{content:"\f143"}.fa-ruble-sign:before{content:"\f158"}.fa-rupee-sign:before{content:"\f156"}.fa-safari:before{content:"\f267"}.fa-sass:before{content:"\f41e"}.fa-save:before{content:"\f0c7"}.fa-schlix:before{content:"\f3ea"}.fa-scribd:before{content:"\f28a"}.fa-search:before{content:"\f002"}.fa-search-minus:before{content:"\f010"}.fa-search-plus:before{content:"\f00e"}.fa-searchengin:before{content:"\f3eb"}.fa-sellcast:before{content:"\f2da"}.fa-sellsy:before{content:"\f213"}.fa-server:before{content:"\f233"}.fa-servicestack:before{content:"\f3ec"}.fa-share:before{content:"\f064"}.fa-share-alt:before{content:"\f1e0"}.fa-share-alt-square:before{content:"\f1e1"}.fa-share-square:before{content:"\f14d"}.fa-shekel-sign:before{content:"\f20b"}.fa-shield-alt:before{content:"\f3ed"}.fa-ship:before{content:"\f21a"}.fa-shirtsinbulk:before{content:"\f214"}.fa-shopping-bag:before{content:"\f290"}.fa-shopping-basket:before{content:"\f291"}.fa-shopping-cart:before{content:"\f07a"}.fa-shower:before{content:"\f2cc"}.fa-sign-in-alt:before{content:"\f2f6"}.fa-sign-language:before{content:"\f2a7"}.fa-sign-out-alt:before{content:"\f2f5"}.fa-signal:before{content:"\f012"}.fa-simplybuilt:before{content:"\f215"}.fa-sistrix:before{content:"\f3ee"}.fa-sitemap:before{content:"\f0e8"}.fa-skyatlas:before{content:"\f216"}.fa-skype:before{content:"\f17e"}.fa-slack:before{content:"\f198"}.fa-slack-hash:before{content:"\f3ef"}.fa-sliders-h:before{content:"\f1de"}.fa-slideshare:before{content:"\f1e7"}.fa-smile:before{content:"\f118"}.fa-snapchat:before{content:"\f2ab"}.fa-snapchat-ghost:before{content:"\f2ac"}.fa-snapchat-square:before{content:"\f2ad"}.fa-snowflake:before{content:"\f2dc"}.fa-sort:before{content:"\f0dc"}.fa-sort-alpha-down:before{content:"\f15d"}.fa-sort-alpha-up:before{content:"\f15e"}.fa-sort-amount-down:before{content:"\f160"}.fa-sort-amount-up:before{content:"\f161"}.fa-sort-down:before{content:"\f0dd"}.fa-sort-numeric-down:before{content:"\f162"}.fa-sort-numeric-up:before{content:"\f163"}.fa-sort-up:before{content:"\f0de"}.fa-soundcloud:before{content:"\f1be"}.fa-space-shuttle:before{content:"\f197"}.fa-speakap:before{content:"\f3f3"}.fa-spinner:before{content:"\f110"}.fa-spotify:before{content:"\f1bc"}.fa-square:before{content:"\f0c8"}.fa-stack-exchange:before{content:"\f18d"}.fa-stack-overflow:before{content:"\f16c"}.fa-star:before{content:"\f005"}.fa-star-half:before{content:"\f089"}.fa-staylinked:before{content:"\f3f5"}.fa-steam:before{content:"\f1b6"}.fa-steam-square:before{content:"\f1b7"}.fa-steam-symbol:before{content:"\f3f6"}.fa-step-backward:before{content:"\f048"}.fa-step-forward:before{content:"\f051"}.fa-stethoscope:before{content:"\f0f1"}.fa-sticker-mule:before{content:"\f3f7"}.fa-sticky-note:before{content:"\f249"}.fa-stop:before{content:"\f04d"}.fa-stop-circle:before{content:"\f28d"}.fa-strava:before{content:"\f428"}.fa-street-view:before{content:"\f21d"}.fa-strikethrough:before{content:"\f0cc"}.fa-stripe:before{content:"\f429"}.fa-studiovinari:before{content:"\f3f8"}.fa-stumbleupon:before{content:"\f1a4"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-subscript:before{content:"\f12c"}.fa-subway:before{content:"\f239"}.fa-suitcase:before{content:"\f0f2"}.fa-sun:before{content:"\f185"}.fa-superpowers:before{content:"\f2dd"}.fa-superscript:before{content:"\f12b"}.fa-supple:before{content:"\f3f9"}.fa-sync:before{content:"\f021"}.fa-table:before{content:"\f0ce"}.fa-tablet:before{content:"\f10a"}.fa-tablet-alt:before{content:"\f3fa"}.fa-tachometer-alt:before{content:"\f3fd"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-tasks:before{content:"\f0ae"}.fa-taxi:before{content:"\f1ba"}.fa-telegram:before{content:"\f2c6"}.fa-telegram-plane:before{content:"\f3fe"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-terminal:before{content:"\f120"}.fa-text-height:before{content:"\f034"}.fa-text-width:before{content:"\f035"}.fa-th:before{content:"\f00a"}.fa-th-large:before{content:"\f009"}.fa-th-list:before{content:"\f00b"}.fa-themeisle:before{content:"\f2b2"}.fa-thermometer-empty:before{content:"\f2cb"}.fa-thermometer-full:before{content:"\f2c7"}.fa-thermometer-half:before{content:"\f2c9"}.fa-thermometer-quarter:before{content:"\f2ca"}.fa-thermometer-three-quarters:before{content:"\f2c8"}.fa-thumbs-down:before{content:"\f165"}.fa-thumbs-up:before{content:"\f164"}.fa-thumbtack:before{content:"\f08d"}.fa-ticket-alt:before{content:"\f3ff"}.fa-times:before{content:"\f00d"}.fa-times-circle:before{content:"\f057"}.fa-tint:before{content:"\f043"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-trademark:before{content:"\f25c"}.fa-train:before{content:"\f238"}.fa-transgender:before{content:"\f224"}.fa-transgender-alt:before{content:"\f225"}.fa-trash:before{content:"\f1f8"}.fa-trash-alt:before{content:"\f2ed"}.fa-tree:before{content:"\f1bb"}.fa-trello:before{content:"\f181"}.fa-tripadvisor:before{content:"\f262"}.fa-trophy:before{content:"\f091"}.fa-truck:before{content:"\f0d1"}.fa-tty:before{content:"\f1e4"}.fa-tumblr:before{content:"\f173"}.fa-tumblr-square:before{content:"\f174"}.fa-tv:before{content:"\f26c"}.fa-twitch:before{content:"\f1e8"}.fa-twitter:before{content:"\f099"}.fa-twitter-square:before{content:"\f081"}.fa-uber:before{content:"\f402"}.fa-uikit:before{content:"\f403"}.fa-umbrella:before{content:"\f0e9"}.fa-underline:before{content:"\f0cd"}.fa-undo:before{content:"\f0e2"}.fa-uniregistry:before{content:"\f404"}.fa-universal-access:before{content:"\f29a"}.fa-university:before{content:"\f19c"}.fa-unlink:before{content:"\f127"}.fa-unlock:before{content:"\f09c"}.fa-unlock-alt:before{content:"\f13e"}.fa-untappd:before{content:"\f405"}.fa-upload:before{content:"\f093"}.fa-usb:before{content:"\f287"}.fa-user:before{content:"\f007"}.fa-user-circle:before{content:"\f2bd"}.fa-user-md:before{content:"\f0f0"}.fa-user-plus:before{content:"\f234"}.fa-user-secret:before{content:"\f21b"}.fa-user-times:before{content:"\f235"}.fa-users:before{content:"\f0c0"}.fa-ussunnah:before{content:"\f407"}.fa-utensil-spoon:before{content:"\f2e5"}.fa-utensils:before{content:"\f2e7"}.fa-vaadin:before{content:"\f408"}.fa-venus:before{content:"\f221"}.fa-venus-double:before{content:"\f226"}.fa-venus-mars:before{content:"\f228"}.fa-viacoin:before{content:"\f237"}.fa-viadeo:before{content:"\f2a9"}.fa-viadeo-square:before{content:"\f2aa"}.fa-viber:before{content:"\f409"}.fa-video:before{content:"\f03d"}.fa-vimeo:before{content:"\f40a"}.fa-vimeo-square:before{content:"\f194"}.fa-vimeo-v:before{content:"\f27d"}.fa-vine:before{content:"\f1ca"}.fa-vk:before{content:"\f189"}.fa-vnv:before{content:"\f40b"}.fa-volume-down:before{content:"\f027"}.fa-volume-off:before{content:"\f026"}.fa-volume-up:before{content:"\f028"}.fa-vuejs:before{content:"\f41f"}.fa-weibo:before{content:"\f18a"}.fa-weixin:before{content:"\f1d7"}.fa-whatsapp:before{content:"\f232"}.fa-whatsapp-square:before{content:"\f40c"}.fa-wheelchair:before{content:"\f193"}.fa-whmcs:before{content:"\f40d"}.fa-wifi:before{content:"\f1eb"}.fa-wikipedia-w:before{content:"\f266"}.fa-window-close:before{content:"\f410"}.fa-window-maximize:before{content:"\f2d0"}.fa-window-minimize:before{content:"\f2d1"}.fa-window-restore:before{content:"\f2d2"}.fa-windows:before{content:"\f17a"}.fa-won-sign:before{content:"\f159"}.fa-wordpress:before{content:"\f19a"}.fa-wordpress-simple:before{content:"\f411"}.fa-wpbeginner:before{content:"\f297"}.fa-wpexplorer:before{content:"\f2de"}.fa-wpforms:before{content:"\f298"}.fa-wrench:before{content:"\f0ad"}.fa-xbox:before{content:"\f412"}.fa-xing:before{content:"\f168"}.fa-xing-square:before{content:"\f169"}.fa-y-combinator:before{content:"\f23b"}.fa-yahoo:before{content:"\f19e"}.fa-yandex:before{content:"\f413"}.fa-yandex-international:before{content:"\f414"}.fa-yelp:before{content:"\f1e9"}.fa-yen-sign:before{content:"\f157"}.fa-yoast:before{content:"\f2b1"}.fa-youtube:before{content:"\f167"}.sr-only{border:0;clip:rect(0,0,0,0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.sr-only-focusable:active,.sr-only-focusable:focus{clip:auto;height:auto;margin:0;overflow:visible;position:static;width:auto}
\ No newline at end of file
diff --git a/app/browser/index.html b/app/browser/index.html
index 20917171..bb016bdc 100644
--- a/app/browser/index.html
+++ b/app/browser/index.html
@@ -3,18 +3,18 @@
`).appendTo(this.widget)
+ this.hueWrapper = this.widget.appendChild(DOM.create(``))
this.hue = new Fader({props:{
...faderDefaults,
@@ -71,10 +70,10 @@ module.exports = class Rgb extends _pads_base {
range:{min:0,max:360},
input:false,
precision:2
- }, cancelDraw: false})
+ }, cancelDraw: false, parent: this})
this.hue.margin = this.pointSize
this.hue.sendValue = ()=>{}
- this.hueWrapper.append(this.hue.widget)
+ this.hueWrapper.appendChild(this.hue.widget)
this.pad = new Xy({props:{
...xyDefaults,
@@ -86,25 +85,21 @@ module.exports = class Rgb extends _pads_base {
pointSize: this.getProp('pointSize'),
pips: false,
input:false
- }})
+ }, parent: this})
this.pad.sendValue = ()=>{}
- this.wrapper.append(this.pad.widget)
+ this.wrapper.appendChild(this.pad.widget)
this.value = []
this.hsb = {h:0,s:0,b:0}
- this.wrapper.on('change',(e)=>{
- e.stopPropagation()
- })
-
- this.hue.widget.on('change',(e)=>{
- e.stopPropagation()
+ this.hue.on('change',(e)=>{
+ e.stopPropagation = true
this.dragHandle(true)
})
- this.wrapper.on('change',(e)=>{
- e.stopPropagation()
+ this.pad.on('change',(e)=>{
+ e.stopPropagation = true
this.dragHandle()
})
@@ -115,8 +110,8 @@ module.exports = class Rgb extends _pads_base {
parent:this, parentNode:this.widget
})
this.widget.append(this.input.widget)
- this.input.widget.on('change', (e)=>{
- e.stopPropagation()
+ this.input.on('change', (e)=>{
+ e.stopPropagation = true
this.setValue(this.input.getValue(), {sync:true, send:true})
this.showValue()
})
@@ -151,7 +146,7 @@ module.exports = class Rgb extends _pads_base {
setValue(v, options={}) {
if (!v || !v.length || v.length!=3) return
- if (this.touched && !options.dragged) return this.setValueTouchedQueue = arguments
+ if (this.touched && !options.dragged) return this.setValueTouchedQueue = [v, options]
for (let i in [0,1,2]) {
v[i] = clip(v[i],[0,255])
@@ -167,7 +162,7 @@ module.exports = class Rgb extends _pads_base {
this.value = v
if (options.send) this.sendValue()
- if (options.sync) this.widget.trigger({type:'change', id:this.getProp('id'),widget:this, linkId:this.getProp('linkId'), options:options})
+ if (options.sync) this.changed(options)
this.update({dragged:options.dragged, nohue:options.nohue || (v[0]==v[1]&&v[1]==v[2])})
@@ -178,20 +173,16 @@ module.exports = class Rgb extends _pads_base {
if (!options.nohue && !options.dragged) {
var hue = hsbToRgb({h:this.hsb.h,s:100,b:100}),
hueStr = `rgb(${Math.round(hue.r)},${Math.round(hue.g)},${Math.round(hue.b)})`
- this.canvas[0].setAttribute('style',`background-color:${hueStr}`)
+ this.canvas.setAttribute('style',`background-color:${hueStr}`)
this.hue.setValue(this.hsb.h, {sync: false, send:false, dragged:false})
}
- this.draw()
-
this.showValue()
}
- draw() {
-
- }
+ draw() {}
showValue() {
@@ -199,4 +190,11 @@ module.exports = class Rgb extends _pads_base {
}
+ onRemove() {
+ this.hue.onRemove()
+ this.pad.onRemove()
+ if (this.input) this.input.onRemove()
+ super.onRemove()
+ }
+
}
diff --git a/src/browser/js/app/widgets/pads/xy.js b/src/browser/js/app/widgets/pads/xy.js
index 4226b266..e229f0c7 100644
--- a/src/browser/js/app/widgets/pads/xy.js
+++ b/src/browser/js/app/widgets/pads/xy.js
@@ -2,7 +2,8 @@ var _pads_base = require('./_pads_base'),
Fader = require('./_fake_fader'),
{clip} = require('../utils'),
doubletab = require('../mixins/double_tap'),
- Input = require('../inputs/input')
+ Input = require('../inputs/input'),
+ touchstate = require('../mixins/touch_state')
var faderDefaults = Fader.defaults()
@@ -80,7 +81,7 @@ module.exports = class Xy extends _pads_base {
precision:this.precision,
logScale:this.getProp('logScaleX'),
input:false
- }, cancelDraw: true}),
+ }, cancelDraw: true, parent: this}),
y: new Fader({props:{
...faderDefaults,
id:1,
@@ -96,36 +97,47 @@ module.exports = class Xy extends _pads_base {
precision:this.precision,
logScale:this.getProp('logScaleY'),
input:false
- }, cancelDraw: true}),
+ }, cancelDraw: true, parent: this}),
}
this.faders.x.margin = this.faders.y.margin = this.pointSize + 1
this.value = [this.faders.x.value, this.faders.y.value]
- this.wrapper.append(this.faders.x.widget)
- this.wrapper.append(this.faders.y.widget)
+ this.wrapper.appendChild(this.faders.x.widget)
+ this.wrapper.appendChild(this.faders.y.widget)
- this.wrapper.on('change',(e)=>{
- e.stopPropagation()
+ this.faders.x.on('change',(e)=>{
+ e.stopPropagation = true
})
- this.wrapper.on('draginit',(e, data, traversing)=>{
- this.faders.x.draginitHandleProxy(e, data, traversing)
- this.faders.y.draginitHandleProxy(e, data, traversing)
+ this.faders.y.on('change',(e)=>{
+ e.stopPropagation = true
+ })
+
+ touchstate(this, {element: this.wrapper})
+
+ this.on('draginit',(e)=>{
+ e.stopPropagation = true
+ this.faders.x.trigger('draginit', [e])
+ this.faders.y.trigger('draginit', [e])
this.dragHandle()
- })
- this.wrapper.on('drag',(e, data, traversing)=>{
- this.faders.x.dragHandleProxy(e, data, traversing)
- this.faders.y.dragHandleProxy(e, data, traversing)
- this.dragHandle()
- })
+ }, {element: this.wrapper})
- if (this.getProp('spring')) {
- this.wrapper.on('dragend', ()=>{
+ this.on('drag',(e)=>{
+ this.faders.x.trigger('drag', [e])
+ this.faders.y.trigger('drag', [e])
+ this.dragHandle()
+ }, {element: this.wrapper})
+
+ this.on('dragend', (e)=>{
+ e.stopPropagation = true
+ this.faders.x.trigger('dragend', [e])
+ this.faders.y.trigger('dragend', [e])
+ if (this.getProp('spring')) {
this.setValue([this.faders.x.springValue,this.faders.y.springValue],{sync:true,send:true,fromLocal:true})
- })
- }
+ }
+ }, {element: this.wrapper})
if (this.getProp('doubleTap')) {
doubletab(this.wrapper, ()=>{
@@ -139,9 +151,9 @@ module.exports = class Xy extends _pads_base {
props:{...Input.defaults(), precision:this.getProp('precision'), unit:this.getProp('unit')},
parent:this, parentNode:this.widget
})
- this.widget.append(this.input.widget)
- this.input.widget.on('change', (e)=>{
- e.stopPropagation()
+ this.widget.appendChild(this.input.widget)
+ this.input.on('change', (e)=>{
+ e.stopPropagation = true
this.setValue(this.input.getValue(), {sync:true, send:true})
this.showValue()
})
@@ -168,7 +180,7 @@ module.exports = class Xy extends _pads_base {
setValue(v, options={}) {
if (!v || !v.length || v.length!=2) return
- if (this.touched && !options.dragged) return this.setValueTouchedQueue = arguments
+ if (this.touched && !options.dragged) return this.setValueTouchedQueue = [v, options]
if (!options.dragged) {
this.faders.x.setValue(v[0], {sync: false, send:false, dragged:false})
@@ -181,9 +193,9 @@ module.exports = class Xy extends _pads_base {
]
if (options.send) this.sendValue()
- if (options.sync) this.widget.trigger({type:'change', id:this.getProp('id'),widget:this, linkId:this.getProp('linkId'), options:options})
+ if (options.sync) this.changed(options)
- this.draw()
+ this.batchDraw()
this.showValue()
@@ -252,4 +264,11 @@ module.exports = class Xy extends _pads_base {
}
+ onRemove() {
+ this.faders.x.onRemove()
+ this.faders.y.onRemove()
+ if (this.input) this.input.onRemove()
+ super.onRemove()
+ }
+
}
diff --git a/src/browser/js/app/widgets/plots/_plots_base.js b/src/browser/js/app/widgets/plots/_plots_base.js
index bf5cbbf6..7c84b5f4 100644
--- a/src/browser/js/app/widgets/plots/_plots_base.js
+++ b/src/browser/js/app/widgets/plots/_plots_base.js
@@ -35,7 +35,7 @@ module.exports = class _plots_base extends _canvas_base {
- $('body').on(`change.${this.hash}`,this.syncHandleProxy.bind(this))
+ widgetManager.on(`change.${this.hash}`, this.syncHandleProxy.bind(this), this)
}
@@ -45,18 +45,11 @@ module.exports = class _plots_base extends _canvas_base {
}
- onRemove() {
-
- $('body').off(`change.${this.hash}`)
- super.onRemove()
-
- }
-
syncHandle(e) {
if (this.linkedWidgets.indexOf(e.id)==-1 || !widgetManager.getWidgetById(e.id).length) return
this.updateData()
- this.draw()
+ this.batchDraw()
}
@@ -70,11 +63,69 @@ module.exports = class _plots_base extends _canvas_base {
draw() {
this.ctx.clearRect(0,0,this.width,this.height)
+
+ if (this.getProp('bars')) {
+ this.draw_bars()
+ } else {
+ this.draw_line()
+ }
+
+ if (this.getProp('pips')) this.draw_pips()
+
+ }
+
+ draw_pips() {
+
+ this.ctx.globalAlpha = 1
+ this.ctx.fillStyle = this.colors.text
+
+ if (this.pips.x) {
+
+ this.ctx.textBaseline = "bottom"
+ this.ctx.textAlign = 'left'
+ this.ctx.fillText(this.pips.x.min,(this.pips.y?12:2)*PXSCALE,this.height)
+ this.ctx.textAlign = 'right'
+ this.ctx.fillText(this.pips.x.max,this.width-2*PXSCALE,this.height)
+
+ }
+
+ if (this.pips.y) {
+
+ this.ctx.save()
+ this.ctx.translate(0, this.height)
+ this.ctx.rotate(-Math.PI/2)
+
+ this.ctx.textBaseline = "top"
+ this.ctx.textAlign = 'left'
+ this.ctx.fillText(this.pips.y.min,(this.pips.x?12:2)*PXSCALE,2*PXSCALE)
+ this.ctx.textAlign = 'right'
+ this.ctx.fillText(this.pips.y.max,this.height-2*PXSCALE,2*PXSCALE)
+ this.ctx.rotate(Math.PI/2)
+ this.ctx.restore()
+
+ }
+
+ }
+
+ draw_line() {
+
+ var points = []
+
+ for (let i in this.data) {
+
+ if (this.data[i].length) {
+ points.push(mapToScale(this.data[i][0],[this.rangeX.min,this.rangeX.max],[0,this.width],0,this.logScaleX,true))
+ points.push(mapToScale(this.data[i][1],[this.rangeY.min,this.rangeY.max],[this.height-2*PXSCALE,2*PXSCALE],0,this.logScaleY,true))
+ } else {
+ points.push(mapToScale(i,[0,this.data.length-1],[0,this.width],0,this.logScaleX,true))
+ points.push(mapToScale(this.data[i],[this.rangeY.min,this.rangeY.max],[this.height-2*PXSCALE,2*PXSCALE],0,this.logScaleY,true))
+ }
+
+ }
+
this.ctx.beginPath()
- if (!this.width) return
-
- this.draw_data()
+ this.ctx.curve(points, this.smooth, Math.round(this.width/(points.length/2 - 1)))
this.ctx.globalAlpha = 0.7
this.ctx.lineWidth = 2 * PXSCALE
@@ -94,66 +145,56 @@ module.exports = class _plots_base extends _canvas_base {
}
-
- this.ctx.globalAlpha = 1
- this.ctx.font = PXSCALE * 10 + 'px sans-serif'
- this.ctx.fillStyle = this.colors.text
-
- if (this.getProp('pips')) {
-
- if (this.pips.x) {
-
- this.ctx.textBaseline = "bottom"
- this.ctx.textAlign = 'left'
- this.ctx.fillText(this.pips.x.min,(this.pips.y?12:2)*PXSCALE,this.height)
- this.ctx.textAlign = 'right'
- this.ctx.fillText(this.pips.x.max,this.width-2*PXSCALE,this.height)
-
- }
-
- if (this.pips.y) {
-
- this.ctx.save()
- this.ctx.translate(0, this.height)
- this.ctx.rotate(-Math.PI/2)
-
- this.ctx.textBaseline = "top"
- this.ctx.textAlign = 'left'
- this.ctx.fillText(this.pips.y.min,(this.pips.x?12:2)*PXSCALE,2*PXSCALE)
- this.ctx.textAlign = 'right'
- this.ctx.fillText(this.pips.y.max,this.height-2*PXSCALE,2*PXSCALE)
- this.ctx.rotate(Math.PI/2)
- this.ctx.restore()
-
- }
-
- }
-
}
- draw_data() {
+ draw_bars() {
+
+ var points = [],
+ barWidth = Math.round(this.width / this.data.length),
+ offset = Math.round((this.width - barWidth * this.data.length) / 2)
+
+ var origin = mapToScale(this.getProp('origin') || this.rangeY.min,[this.rangeY.min,this.rangeY.max],[this.height,0],0,this.getProp('logScaleY'),true)
+
+ this.ctx.beginPath()
- var points = []
for (let i in this.data) {
-
- if (this.data[i].length) {
- points.push(mapToScale(this.data[i][0],[this.rangeX.min,this.rangeX.max],[0,this.width],0,this.logScaleX,true))
- points.push(mapToScale(this.data[i][1],[this.rangeY.min,this.rangeY.max],[this.height-2*PXSCALE,2*PXSCALE],0,this.logScaleY,true))
- } else {
- points.push(mapToScale(i,[0,this.data.length-1],[0,this.width],0,this.logScaleX,true))
- points.push(mapToScale(this.data[i],[this.rangeY.min,this.rangeY.max],[this.height-2*PXSCALE,2*PXSCALE],0,this.logScaleY,true))
- }
+ var y = mapToScale(this.data[i].length ? this.data[i][1] : this.data[i],[this.rangeY.min,this.rangeY.max],[this.height-2*PXSCALE,2*PXSCALE],0,this.logScaleY,true)
+ this.ctx.rect(offset + i * barWidth, Math.min(y, origin), barWidth - PXSCALE, Math.abs(Math.min(y - origin)))
}
- this.ctx.curve(points, this.smooth, Math.round(this.width/(points.length/2 - 1)))
+ this.ctx.globalAlpha = 0.4
+ this.ctx.fillStyle = this.colors.custom
+ this.ctx.fill()
}
- setValue(v) {
+ setValue(v, options={}) {
+
+ if (typeof v == 'string' && (v[0] == '[' || v[0] == '{' )) {
+ v = JSON.parseFlex(v)
+ }
+
+ if (typeof v == 'object') {
+
+ if (Array.isArray(v)) {
+
+ this.data = v
+
+ } else {
+
+ for (var i in v) {
+ if (!isNaN(i)) this.data[i] = v[i]
+ }
+
+ }
+
+ this.batchDraw()
+
+ if (options.sync) this.changed(options)
+
+ }
- this.data = v
- this.draw()
}
diff --git a/src/browser/js/app/widgets/plots/image.js b/src/browser/js/app/widgets/plots/image.js
new file mode 100644
index 00000000..f97b670b
--- /dev/null
+++ b/src/browser/js/app/widgets/plots/image.js
@@ -0,0 +1,88 @@
+var {mapToScale} = require('../utils'),
+ _widgets_base = require('../common/_widgets_base')
+
+module.exports = class Led extends _widgets_base {
+
+ static defaults() {
+
+ return {
+ type:'image',
+ id:'auto',
+
+ _geometry:'geometry',
+
+ left:'auto',
+ top:'auto',
+ width:'auto',
+ height:'auto',
+
+ _style:'style',
+
+ label:'auto',
+ // color:'auto',
+ css:'',
+
+ _image:'image',
+
+ size: 'cover',
+ position: 'center',
+ repeat: 'no-repeat',
+ border: true,
+ cache: true,
+ value:'',
+
+ _osc:'osc',
+
+ preArgs:[],
+ address:'auto'
+
+ }
+
+ }
+
+ constructor(options) {
+
+ var html = `
+
+ `
+
+ super({...options, html: html})
+
+ if (!this.getProp('border')) this.container.classList.add('noborder')
+
+ this.widget.style.setProperty('background-size', this.getProp('size'))
+ this.widget.style.setProperty('background-position', this.getProp('position'))
+ this.widget.style.setProperty('background-repeat', this.getProp('repeat'))
+
+
+ }
+
+ setValue(v, options={}) {
+
+ var s = v==null ? '' : '' + v,
+ cache_query = ''
+
+ if (!s.length) {
+
+ this.value = this.getProp('value')
+
+ } else if (s != 'reload') {
+
+ if (s.length > 1) this.value = s
+
+ }
+
+ if (this.value.length) {
+
+ cache_query = this.getProp('cache') || this.value.indexOf('base64') != -1 ?
+ '' : (this.value.indexOf('?') != -1 ? '&' : '?') + Date.now()
+
+ }
+
+ this.widget.style.setProperty('background-image', `url(${this.value}${cache_query})`)
+
+ if (options.sync) this.changed(options)
+
+ }
+
+}
diff --git a/src/browser/js/app/widgets/plots/led.js b/src/browser/js/app/widgets/plots/led.js
index b1b8e865..a7065f5b 100644
--- a/src/browser/js/app/widgets/plots/led.js
+++ b/src/browser/js/app/widgets/plots/led.js
@@ -48,19 +48,12 @@ module.exports = class Led extends _widgets_base {
super({...options, html: html})
- if (this.getProp('widgetId').length) $('body').on(`change.${this.hash}`,this.syncHandle.bind(this))
+ if (this.getProp('widgetId').length) widgetManager.on(`change.${this.hash}`, this.syncHandle.bind(this))
this.setValue(this.getProp('range').min)
}
- onRemove() {
-
- $('body').off(`change.${this.hash}`)
- super.onRemove()
-
- }
-
syncHandle(e) {
if (this.getProp('widgetId')!=e.id || !widgetManager.getWidgetById(e.id).length) return
@@ -68,17 +61,19 @@ module.exports = class Led extends _widgets_base {
value
for (var i=widget.length-1; i>=0; i--) {
if (widget[i].getValue) {
- this.setValue(widget[i].getValue())
+ this.setValue(widget[i].getValue(), {sync: e.options.sync})
return
}
}
}
- setValue(v) {
+ setValue(v, options={}) {
if (typeof v != 'number') return
this.value = v
- this.widget[0].style.setProperty('--opacity', mapToScale(v,[this.getProp('range').min,this.getProp('range').max],[0,1],false,this.getProp('logScale'),true))
+ this.widget.style.setProperty('--opacity', mapToScale(v,[this.getProp('range').min,this.getProp('range').max],[0,1],false,this.getProp('logScale'),true))
+
+ if (options.sync) this.changed(options)
}
diff --git a/src/browser/js/app/widgets/plots/meter.js b/src/browser/js/app/widgets/plots/meter.js
index f5ec9799..a1a56f28 100644
--- a/src/browser/js/app/widgets/plots/meter.js
+++ b/src/browser/js/app/widgets/plots/meter.js
@@ -52,23 +52,15 @@ module.exports = class Meter extends Fader {
super(options)
- this.widget.addClass('meter')
- .off('mousewheel')
+ this.widget.classList.add('meter')
- this.canvas.off('draginit drag')
+ this.off(/drag(.*)?/)
- if (this.getProp('widgetId').length) $('body').on(`change.${this.hash}`,this.syncHandle.bind(this))
+ if (this.getProp('widgetId').length) widgetManager.on(`change.${this.hash}`,this.syncHandle.bind(this))
}
- onRemove() {
-
- $('body').off(`change.${this.hash}`)
- super.onRemove()
-
- }
-
syncHandle(e) {
if (this.getProp('widgetId')!=e.id || !widgetManager.getWidgetById(e.id).length) return
@@ -76,7 +68,7 @@ module.exports = class Meter extends Fader {
value
for (var i=widget.length-1; i>=0; i--) {
if (widget[i].getValue) {
- this.setValue(widget[i].getValue())
+ this.setValue(widget[i].getValue(), {sync: e.options.sync})
return
}
}
diff --git a/src/browser/js/app/widgets/plots/plot.js b/src/browser/js/app/widgets/plots/plot.js
index 6fc17b46..7a277f19 100644
--- a/src/browser/js/app/widgets/plots/plot.js
+++ b/src/browser/js/app/widgets/plots/plot.js
@@ -29,6 +29,7 @@ module.exports = class Plot extends _plots_base {
rangeX: {min:0,max:1},
rangeY: {min:0,max:1},
origin: 'auto',
+ bars: false,
logScaleX: false,
logScaleY: false,
smooth: false,
diff --git a/src/browser/js/app/widgets/plots/rgbled.js b/src/browser/js/app/widgets/plots/rgbled.js
index 746ba8aa..7d2a762b 100644
--- a/src/browser/js/app/widgets/plots/rgbled.js
+++ b/src/browser/js/app/widgets/plots/rgbled.js
@@ -46,19 +46,12 @@ module.exports = class Rbgled extends _widgets_base {
super({...options, html: html})
- if (this.getProp('widgetId').length) $('body').on(`change.${this.hash}`,this.syncHandle.bind(this))
+ if (this.getProp('widgetId').length) widgetManager.on(`change.${this.hash}`,this.syncHandle.bind(this))
this.setValue([0,0,0,0])
}
- onRemove() {
-
- $('body').off(`change.${this.hash}`)
- super.onRemove()
-
- }
-
syncHandle(e) {
if (this.getProp('widgetId')!=e.id || !widgetManager.getWidgetById(e.id).length) return
@@ -68,13 +61,13 @@ module.exports = class Rbgled extends _widgets_base {
for (var i=widget.length-1; i>=0; i--) {
if (widget[i].getValue) {
- this.setValue(widget[i].getValue())
+ this.setValue(widget[i].getValue(), {sync: e.options.sync})
return
}
}
}
- setValue(v) {
+ setValue(v, options={}) {
var c = ''
@@ -101,7 +94,9 @@ module.exports = class Rbgled extends _widgets_base {
this.value = v
- this.widget[0].style.setProperty('--color-custom', c)
+ this.widget.style.setProperty('--color-led', c)
+
+ if (options.sync) this.changed(options)
}
diff --git a/src/browser/js/app/widgets/plots/text.js b/src/browser/js/app/widgets/plots/text.js
index c2ab9751..efb15ecc 100644
--- a/src/browser/js/app/widgets/plots/text.js
+++ b/src/browser/js/app/widgets/plots/text.js
@@ -1,4 +1,4 @@
-var {iconify} = require('../../utils'),
+var {iconify} = require('../../ui/utils'),
_widgets_base = require('../common/_widgets_base'),
widgetManager = require('../../managers/widgets')
@@ -41,29 +41,22 @@ module.exports = class Text extends _widgets_base {
super({...options, html: ''})
- if (this.getProp('vertical')) this.widget.addClass('vertical')
+ if (this.getProp('vertical')) this.widget.classList.add('vertical')
- this.defaultValue = this.getProp('label')===false?
+ this.defaultValue = this.getProp('value') || ( this.getProp('label')===false ?
this.getProp('id'):
this.getProp('label')=='auto'?
this.getProp('id'):
- this.getProp('label')
+ this.getProp('label') )
this.value = this.defaultValue
- if (this.getProp('widgetId').length) $('body').on(`change.${this.hash}`,this.syncHandle.bind(this))
+ if (this.getProp('widgetId').length) widgetManager.on(`change.${this.hash}`,this.syncHandle.bind(this))
this.setValue(this.value)
}
- onRemove() {
-
- $('body').off(`change.${this.hash}`)
- super.onRemove()
-
- }
-
syncHandle(e) {
if (this.getProp('widgetId')!=e.id || !widgetManager.getWidgetById(e.id).length) return
@@ -71,17 +64,19 @@ module.exports = class Text extends _widgets_base {
value
for (var i=widget.length-1; i>=0; i--) {
if (widget[i].getValue) {
- this.setValue(widget[i].getValue())
+ this.setValue(widget[i].getValue(true), {sync: e.options.sync})
return
}
}
}
- setValue(v) {
+ setValue(v, options={}) {
this.value = v==null ? this.defaultValue : v
- this.widget.html(iconify(String(this.value).replace(/\n/g,'
')))
+ this.widget.innerHTML = iconify(String(this.value).replace(/\n/g,'
'))
+
+ if (options.sync) this.changed(options)
}
diff --git a/src/browser/js/app/widgets/plots/visualizer.js b/src/browser/js/app/widgets/plots/visualizer.js
index 6488f0f4..aa53c697 100644
--- a/src/browser/js/app/widgets/plots/visualizer.js
+++ b/src/browser/js/app/widgets/plots/visualizer.js
@@ -67,7 +67,7 @@ module.exports = class Visualizer extends _plots_base {
syncHandle(e) {
if (this.getProp('widgetId')!=e.id || !widgetManager.getWidgetById(e.id).length || !e.widget) return
- this.setValue(e.widget.getValue())
+ this.setValue(e.widget.getValue(), {sync: e.options.sync})
}
@@ -95,7 +95,7 @@ module.exports = class Visualizer extends _plots_base {
if (Math.floor(this.ticks) > 0) {
this.shiftData(Math.floor(this.ticks))
this.ticks -= Math.floor(this.ticks)
- this.draw()
+ this.batchDraw()
}
this.lastUpdate = t
@@ -117,7 +117,7 @@ module.exports = class Visualizer extends _plots_base {
}
- setValue(v) {
+ setValue(v, options={}) {
if (Array.isArray(v) && v.length == this.length) {
@@ -125,11 +125,17 @@ module.exports = class Visualizer extends _plots_base {
this.value = v[v.length - 1]
this.startLoop()
+ if (options.sync) this.changed(options)
+
+
} else if (typeof(v) == 'number'){
this.value = v
this.startLoop()
+ if (options.sync) this.changed(options)
+
+
}
}
diff --git a/src/browser/js/app/widgets/sliders/_sliders_base.js b/src/browser/js/app/widgets/sliders/_sliders_base.js
index ed81a15f..cc21189f 100644
--- a/src/browser/js/app/widgets/sliders/_sliders_base.js
+++ b/src/browser/js/app/widgets/sliders/_sliders_base.js
@@ -18,7 +18,7 @@ module.exports = class _sliders_base extends _canvas_base {
super({...options, html: html})
- this.wrapper = this.widget.find('.wrapper')
+ this.wrapper = DOM.get(this.widget, '.wrapper')[0]
this.value = undefined
this.percent = 0
@@ -60,12 +60,14 @@ module.exports = class _sliders_base extends _canvas_base {
}
- touchstate(this, this.wrapper)
- this.wrapper.on('mousewheel',this.mousewheelHandleProxy.bind(this))
- this.wrapper.on('draginit',this.draginitHandleProxy.bind(this))
- this.wrapper.on('drag',this.dragHandleProxy.bind(this))
- this.wrapper.on('dragend',this.dragendHandleProxy.bind(this))
+ this.wrapper.addEventListener('mousewheel',this.mousewheelHandleProxy.bind(this))
+
+ this.on('draginit', this.draginitHandleProxy.bind(this), {element:this.wrapper})
+ this.on('drag', this.dragHandleProxy.bind(this), {element:this.wrapper})
+ this.on('dragend', this.dragendHandleProxy.bind(this), {element:this.wrapper})
+
+ touchstate(this, {element: this.wrapper})
if (this.getProp('input')) {
@@ -75,19 +77,19 @@ module.exports = class _sliders_base extends _canvas_base {
...Input.defaults(),
precision:this.getProp('precision'),
unit:this.getProp('unit'),
- horizontal: this.getProp('type') == 'fader' && this.getProp('compact') && !this.getProp('horizontal')
+ vertical: this.getProp('type') == 'fader' && this.getProp('compact') && !this.getProp('horizontal')
},
parent:this, parentNode:this.widget
})
- this.widget.append(this.input.widget)
- this.input.widget.on('change', (e)=>{
- e.stopPropagation()
+ this.widget.appendChild(this.input.widget)
+ this.input.on('change', (e)=>{
+ e.stopPropagation = true
this.setValue(this.input.getValue(), {sync:true, send:true})
this.showValue()
})
- this.widget.on('fake-right-click',function(e){
+ this.widget.addEventListener('fast-right-click',function(e){
if (!EDITING) {
e.stopPropagation()
e.preventDefault()
@@ -125,14 +127,14 @@ module.exports = class _sliders_base extends _canvas_base {
}
- mousewheelHandle(e, data, traversing) {
+ mousewheelHandle(e) {
- if (e.originalEvent.wheelDeltaX) return
+ if (e.wheelDeltaX) return
e.preventDefault()
e.stopPropagation()
- var direction = e.originalEvent.wheelDelta / Math.abs(e.originalEvent.wheelDelta),
+ var direction = e.wheelDelta / Math.abs(e.wheelDelta),
increment = e.ctrlKey?0.25:1
this.percent = clip(this.percent + Math.max(increment,10/Math.pow(10,this.precision + 1)) * direction, [0,100])
@@ -156,10 +158,11 @@ module.exports = class _sliders_base extends _canvas_base {
}
- resizeHandle(e, width, height, checkColors) {
+ resizeHandle(event) {
+
+ var {style, checkColors} = event
if (!this.visible || checkColors) {
- var style = getComputedStyle(this.widget[0])
this.colors.track = style.getPropertyValue('--color-track')
this.colors.gauge = style.getPropertyValue('--color-gauge')
this.colors.knob = style.getPropertyValue('--color-knob')
@@ -195,7 +198,7 @@ module.exports = class _sliders_base extends _canvas_base {
setValue(v,options={}) {
if (typeof v != 'number') return
- if (this.touched && !options.dragged) return this.setValueTouchedQueue = arguments
+ if (this.touched && !options.dragged) return this.setValueTouchedQueue = [v, options]
var value = clip(v,[this.rangeValsMin,this.rangeValsMax])
@@ -205,12 +208,12 @@ module.exports = class _sliders_base extends _canvas_base {
if (!options.dragged) this.percent = this.valueToPercent(this.value)
- if (!this.noDraw) this.draw()
+ if (!this.noDraw) this.batchDraw()
this.showValue()
- if (options.sync) this.widget.trigger({type:'change',id:this.getProp('id'),widget:this, linkId:this.getProp('linkId'), options:options})
if (options.send) this.sendValue()
+ if (options.sync) this.changed(options)
}
@@ -220,4 +223,9 @@ module.exports = class _sliders_base extends _canvas_base {
}
+ onRemove() {
+ if (this.input) this.input.onRemove()
+ super.onRemove()
+ }
+
}
diff --git a/src/browser/js/app/widgets/sliders/encoder.js b/src/browser/js/app/widgets/sliders/encoder.js
index 67af2bf7..b0516c47 100644
--- a/src/browser/js/app/widgets/sliders/encoder.js
+++ b/src/browser/js/app/widgets/sliders/encoder.js
@@ -6,18 +6,18 @@ var {clip, mapToScale} = require('../utils'),
var EncoderKnob = class extends Knob {
- draginitHandle(e, data, traversing) {
+ draginitHandle(e) {
this.percent = clip(this.percent,[0,100])
- this.lastOffsetX = data.offsetX
- this.lastOffsetY = data.offsetY
+ this.lastOffsetX = e.offsetX
+ this.lastOffsetY = e.offsetY
- if (!(traversing || this.getProp('snap'))) return
+ if (!(e.traversing || this.getProp('snap'))) return
- this.percent = this.angleToPercent(this.coordsToAngle(data.offsetX, data.offsetY))
+ this.percent = this.angleToPercent(this.coordsToAngle(e.offsetX, e.offsetY))
- this.setValue(this.percentToValue(this.percent), {send:true,sync:true,dragged:true, draginit:true})
+ this.setValue(this.percentToValue(this.percent), {send:true,sync:true,dragged:true, draginit:!e.traversing})
}
mousewheelHandle(){}
@@ -78,7 +78,7 @@ module.exports = class Encoder extends _widgets_base {
`
super({...options, html: html})
- this.wrapper = this.widget.find('.wrapper')
+ this.wrapper = DOM.get(this.widget, '.wrapper')[0]
this.ticks = Math.abs(parseInt(this.getProp('ticks')))
this.knob = new EncoderKnob({props:{
@@ -87,7 +87,7 @@ module.exports = class Encoder extends _widgets_base {
snap:true,
range:{min:0,max:this.ticks},
pips:false,
- }})
+ }, parent: this})
this.knob.noDraw = true
@@ -97,18 +97,24 @@ module.exports = class Encoder extends _widgets_base {
range:{min:0,max:this.ticks},
origin:this.ticks/2,
pips:false,
- }})
+ }, parent: this})
- this.wrapper.append(this.knob.widget.addClass('drag-knob'))
- this.wrapper.append(this.display.widget.addClass('display-knob'))
+ this.knob.widget.classList.add('drag-knob')
+ this.display.widget.classList.add('display-knob')
+
+ this.wrapper.appendChild(this.knob.widget)
+ this.wrapper.appendChild(this.display.widget)
this.knob.setValue(this.ticks/2)
this.display.setValue(this.ticks/2)
this.previousValue = this.ticks/2
- this.wrapper.on('change',(e)=>{
- e.stopPropagation()
+ this.on('change',(e)=>{
+
+ if (e.widget == this) return
+
+ e.stopPropagation = true
var value = this.knob.getValue()
@@ -130,34 +136,37 @@ module.exports = class Encoder extends _widgets_base {
})
- this.wrapper.on('draginit', (e)=>{
+ this.knob.on('draginit', (e)=>{
if (this.getProp('touchAddress') && this.getProp('touchAddress').length
- && e.target == this.wrapper[0])
+ && e.target == this.wrapper)
this.sendValue({
address:this.getProp('touchAddress'),
v:1
})
})
- this.wrapper.on('dragend', (e)=>{
+ this.knob.on('dragend', (e)=>{
if (this.getProp('release') !== '' && this.value !== this.getProp('release')) {
this.knob.setValue(this.ticks/2)
this.display.setValue(this.ticks/2)
this.setValue(this.getProp('release'), {sync:true, send:true, dragged:false})
}
- if (this.getProp('touchAddress') && this.getProp('touchAddress').length
- && e.target == this.wrapper[0])
+ if (
+ this.getProp('touchAddress') && this.getProp('touchAddress').length
+ && e.target == this.wrapper
+ ) {
this.sendValue({
address:this.getProp('touchAddress'),
v:0
})
+ }
})
if (this.getProp('doubleTap')) {
doubletab(this.wrapper, ()=>{
- this.knob.setValue(this.ticks/2)
- this.display.setValue(this.ticks/2)
+ this.knob.setValue(this.ticks/2)
+ this.display.setValue(this.ticks/2)
if (this.getProp('release') !== '' && this.value !== this.getProp('release')) {
this.setValue(this.getProp('release'), {sync:true, send:true, dragged:false})
}
@@ -165,11 +174,11 @@ module.exports = class Encoder extends _widgets_base {
}
- this.wrapper.on('mousewheel', (e)=>{
+ this.wrapper.addEventListener('mousewheel', (e)=>{
- if (e.originalEvent.wheelDeltaX || e.originalEvent.wheelDelta == 0) return
+ if (e.wheelDeltaX || e.wheelDelta == 0) return
- var direction = e.originalEvent.wheelDelta / Math.abs(e.originalEvent.wheelDelta)
+ var direction = e.wheelDelta / Math.abs(e.wheelDelta)
this.display.setValue(this.display.value + direction)
this.setValue(direction < 0 ? this.getProp('back') : this.getProp('forth'), {sync:true, send:true})
@@ -202,7 +211,7 @@ module.exports = class Encoder extends _widgets_base {
}
- if (options.sync && match) this.widget.trigger({type:'change',id:this.getProp('id'),widget:this, linkId:this.getProp('linkId'), options:options})
+ if (options.sync && match) this.changed(options)
if (options.send && match && !(!this.getProp('snap') && options.draginit)) this.sendValue()
if (options.dragged || options.draginit) this.updateDisplay(options.draginit)
@@ -250,4 +259,10 @@ module.exports = class Encoder extends _widgets_base {
}
+ onRemove() {
+ this.knob.onRemove()
+ this.display.onRemove()
+ super.onRemove()
+ }
+
}
diff --git a/src/browser/js/app/widgets/sliders/fader.js b/src/browser/js/app/widgets/sliders/fader.js
index 58cedfe7..fc88fbd1 100644
--- a/src/browser/js/app/widgets/sliders/fader.js
+++ b/src/browser/js/app/widgets/sliders/fader.js
@@ -59,21 +59,22 @@ module.exports = class Fader extends _sliders_base {
super(options)
- this.widget.addClass('fader')
+ this.widget.classList.add('fader')
this.margin = 22
if (this.getProp('horizontal')) {
- this.widget.add(this.container).addClass('horizontal')
+ this.widget.classList.add('horizontal')
+ this.container.classList.add('horizontal')
}
if (this.getProp('compact')) {
- this.widget.addClass('compact')
+ this.widget.classList.add('compact')
this.margin = 0
}
if (this.getProp('alignRight') && !this.getProp('horizontal')) {
- this.widget.addClass('align-right')
+ this.widget.classList.add('align-right')
}
if (this.getProp('meter')) {
@@ -90,16 +91,17 @@ module.exports = class Fader extends _sliders_base {
pips:false,
dashed:true
}
- var element = parser.parse([data],this.wrapper, this.parent)
- element[0].classList.add('not-editable')
- this.widget[0].classList.add('has-meter')
+ var meter = parser.parse([data],this.wrapper, this)
+ meter.container.classList.add('not-editable')
+
+ this.widget.classList.add('has-meter')
}
if (this.getProp('pips')) {
- this.widget.addClass('has-pips')
+ this.widget.classList.add('has-pips')
- var pips = $('').appendTo(this.wrapper)
+ var pips = this.wrapper.appendChild(DOM.create(''))
var pipTexts = {}
for (var k in this.rangeKeys) {
pipTexts[this.rangeKeys[k]]=this.rangeLabels[k]
@@ -118,23 +120,23 @@ module.exports = class Fader extends _sliders_base {
`
pipsInner = pipsInner + add
}
- pips[0].innerHTML = pipsInner
+ pips.innerHTML = pipsInner
}
}
- draginitHandle(e, data, traversing) {
+ draginitHandle(e) {
super.draginitHandle(...arguments)
this.percent = clip(this.percent,[0,100])
- if (!(traversing || this.getProp('snap'))) return
+ if (!(e.traversing || this.getProp('snap')) || e.ctrlKey) return
this.percent = this.getProp('horizontal')?
- (data.offsetX - this.margin * PXSCALE) / (this.width - (this.margin * PXSCALE * 2)) * 100:
- (this.height - data.offsetY - this.margin * PXSCALE) / (this.height - (this.margin * PXSCALE * 2)) * 100
+ (e.offsetX - this.margin * PXSCALE) / (this.width - (this.margin * PXSCALE * 2)) * 100:
+ (this.height - e.offsetY - this.margin * PXSCALE) / (this.height - (this.margin * PXSCALE * 2)) * 100
// this.percent = clip(this.percent,[0,100])
@@ -147,8 +149,8 @@ module.exports = class Fader extends _sliders_base {
super.dragHandle(...arguments)
this.percent = this.getProp('horizontal')?
- this.percent + ( data.speedX/(this.width - this.margin * PXSCALE * 2)) * 100:
- this.percent + (-data.speedY/(this.height - this.margin * PXSCALE * 2)) * 100
+ this.percent + ( e.movementX/(this.width - this.margin * PXSCALE * 2)) * 100 / e.inertia:
+ this.percent + (-e.movementY/(this.height - this.margin * PXSCALE * 2)) * 100 / e.inertia
this.setValue(this.percentToValue(this.percent), {send:true,sync:true,dragged:true})
@@ -164,24 +166,24 @@ module.exports = class Fader extends _sliders_base {
}
- resizeHandle(e, width, height, checkColors) {
+ resizeHandle(event) {
- var ratio = CANVAS_SCALING * this.scaling
+ var {width, height, style} = event,
+ ratio = CANVAS_SCALING * this.scaling
if (this.getProp('compact')) {
if (this.getProp('horizontal')) {
- super.resizeHandle(e, width, 1 / ratio, checkColors)
+ event.height = 1 / ratio
} else {
- super.resizeHandle(e, 1 / ratio, height, checkColors)
}
- } else {
- super.resizeHandle(...arguments)
}
+ super.resizeHandle(event)
+
if (this.getProp('horizontal')){
this.ctx.setTransform(1, 0, 0, 1, 0, 0)
this.ctx.rotate(-Math.PI/2)
- this.ctx.translate(-this.height, 0)
+ this.ctx.translate(-this.height * ratio, 0)
if (ratio != 1) this.ctx.scale(ratio, ratio)
}
diff --git a/src/browser/js/app/widgets/sliders/knob.js b/src/browser/js/app/widgets/sliders/knob.js
index b1cfb5cc..d4ec2e24 100644
--- a/src/browser/js/app/widgets/sliders/knob.js
+++ b/src/browser/js/app/widgets/sliders/knob.js
@@ -53,9 +53,9 @@ module.exports = class Knob extends _sliders_base {
super(options)
- this.widget.addClass('knob')
+ this.widget.classList.add('knob')
- this.widget.addClass('compact')
+ this.widget.classList.add('compact')
this.lastOffsetX = 0
this.lastOffsetY = 0
@@ -69,31 +69,31 @@ module.exports = class Knob extends _sliders_base {
}
- draginitHandle(e, data, traversing) {
+ draginitHandle(e) {
this.percent = clip(this.percent,[0,100])
- this.lastOffsetX = data.offsetX
- this.lastOffsetY = data.offsetY
+ this.lastOffsetX = e.offsetX
+ this.lastOffsetY = e.offsetY
- if (!(traversing || this.getProp('snap'))) return
+ if (!(e.traversing || this.getProp('snap')) || e.ctrlKey) return
- this.percent = this.angleToPercent(this.coordsToAngle(data.offsetX, data.offsetY))
+ this.percent = this.angleToPercent(this.coordsToAngle(e.offsetX, e.offsetY))
this.setValue(this.percentToValue(this.percent), {send:true,sync:true,dragged:true})
}
- dragHandle(e, data, traversing) {
+ dragHandle(e) {
- if (!(traversing || this.getProp('snap'))) {
+ if (!(e.traversing || this.getProp('snap')) || e.ctrlKey) {
- this.percent = -100*data.speedY/this.height + this.percent
+ this.percent = -100 * (e.movementY / e.inertia) / this.height + this.percent
} else {
- this.lastOffsetX = this.lastOffsetX + data.speedX
- this.lastOffsetY = this.lastOffsetY + data.speedY
+ this.lastOffsetX = this.lastOffsetX + e.movementX / e.inertia
+ this.lastOffsetY = this.lastOffsetY + e.movementY / e.inertia
this.percent = this.angleToPercent(this.coordsToAngle(this.lastOffsetX, this.lastOffsetY))
}
@@ -134,14 +134,12 @@ module.exports = class Knob extends _sliders_base {
this.minDimension = Math.min(this.width, this.height)
- this.wrapper[0].style.top = (this.minDimension) * this.lostHeightFactor - (this.getProp('label') === false ? 0 : this.gaugeWidth / 4) + 'px'
+ this.wrapper.style.top = (this.minDimension) * this.lostHeightFactor - (this.getProp('label') === false ? 0 : this.gaugeWidth / 4) + 'px'
}
draw() {
- if (!this.width || !this.height) return
-
var tiny = this.minDimension < 45 * PXSCALE,
margin = tiny ? 0 : 3 * PXSCALE
diff --git a/src/browser/js/app/widgets/sliders/range.js b/src/browser/js/app/widgets/sliders/range.js
new file mode 100644
index 00000000..7b75b125
--- /dev/null
+++ b/src/browser/js/app/widgets/sliders/range.js
@@ -0,0 +1,450 @@
+var {clip} = require('../utils'),
+ _widgets_base = require('../common/_widgets_base'),
+ Fader = require('./fader'),
+ Input = require('../inputs/input'),
+ touchstate = require('../mixins/touch_state')
+
+var faderDefaults = Fader.defaults()
+
+var RangeFader = class RangeFader extends Fader {
+
+ constructor(options) {
+
+ super(options)
+ this.cancelDraw = options.cancelDraw
+
+ }
+
+ sendValue() {}
+
+ draginitHandle() {
+
+ this.percent = clip(this.percent,[
+ this.valueToPercent(this.rangeValsMin),
+ this.valueToPercent(this.rangeValsMax)
+ ])
+
+ super.draginitHandle(...arguments)
+ }
+
+ draw() {
+
+ if (this.cancelDraw || !this.parent.faders) return
+
+ var width = this.getProp('horizontal') ? this.height : this.width,
+ height = !this.getProp('horizontal') ? this.height : this.width
+
+ var d = Math.round(this.percentToCoord(this.valueToPercent(this.parent.faders[this.getProp('horizontal')?0:1].value))),
+ d2 = Math.round(this.percentToCoord(this.valueToPercent(this.parent.faders[this.getProp('horizontal')?1:0].value))),
+ m = Math.round(this.getProp('horizontal') ? this.height / 2 : this.width / 2)
+
+ var dashed = this.getProp('dashed')
+
+ this.clear()
+
+ if (this.getProp('compact')) {
+
+ this.ctx.globalAlpha = (dashed ? .3 : .2) + 0.2 * Math.abs(d-d2) / height
+ this.ctx.strokeStyle = this.colors.gauge
+ this.ctx.beginPath()
+ this.ctx.moveTo(m, d2)
+ this.ctx.lineTo(m, d)
+ this.ctx.lineWidth = width + 2 * PXSCALE
+ if (dashed) this.ctx.setLineDash([PXSCALE, PXSCALE])
+ this.ctx.stroke()
+ if (dashed) this.ctx.setLineDash([])
+
+ this.ctx.globalAlpha = 1
+ this.ctx.beginPath()
+ this.ctx.fillStyle = this.colors.knob
+ this.ctx.rect(0, Math.min(d, height - PXSCALE), width, PXSCALE)
+ this.ctx.rect(0, Math.min(d2, height - PXSCALE), width, PXSCALE)
+ this.ctx.fill()
+
+ this.clearRect = [0, 0, width, height]
+
+ } else {
+
+ this.ctx.lineWidth = 6 * PXSCALE
+
+ this.ctx.beginPath()
+ this.ctx.globalAlpha = 1
+ this.ctx.strokeStyle = this.colors.light
+ this.ctx.moveTo(m, this.margin * PXSCALE - 2 * PXSCALE)
+ this.ctx.lineTo(m, height - this.margin * PXSCALE + 2 * PXSCALE)
+ this.ctx.stroke()
+
+ this.ctx.lineWidth = 4 * PXSCALE
+
+ this.ctx.beginPath()
+ this.ctx.globalAlpha = 1
+ this.ctx.strokeStyle = this.colors.bg
+ this.ctx.moveTo(m, this.margin * PXSCALE - 1 * PXSCALE)
+ this.ctx.lineTo(m, height - this.margin * PXSCALE + 1 * PXSCALE)
+ this.ctx.stroke()
+
+ this.ctx.lineWidth = 2 * PXSCALE
+
+ this.ctx.beginPath()
+ this.ctx.strokeStyle = this.colors.track
+ this.ctx.moveTo(m, this.margin * PXSCALE)
+ this.ctx.lineTo(m, height - this.margin * PXSCALE)
+ this.ctx.stroke()
+
+ this.ctx.beginPath()
+ this.ctx.globalAlpha = 0.7
+ this.ctx.strokeStyle = this.colors.gauge
+ this.ctx.moveTo(m, d2)
+ this.ctx.lineTo(m, d)
+ if (dashed) this.ctx.setLineDash([PXSCALE, PXSCALE])
+ this.ctx.stroke()
+ if (dashed) this.ctx.setLineDash([])
+
+ this.ctx.globalAlpha = 1
+
+ // high knob bg
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 9 * PXSCALE, d - 14 * PXSCALE, 18 * PXSCALE, 16 * PXSCALE)
+ this.ctx.lineWidth = PXSCALE
+ this.ctx.fillStyle = this.colors.bg
+ this.ctx.fill()
+
+ // low knob bg
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 9 * PXSCALE, d2 - PXSCALE, 18 * PXSCALE, 16 * PXSCALE)
+ this.ctx.lineWidth = PXSCALE
+ this.ctx.fillStyle = this.colors.bg
+ this.ctx.fill()
+
+ // high knob
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 8 * PXSCALE, d - 13 * PXSCALE, 16 * PXSCALE, 14 * PXSCALE)
+ this.ctx.fillStyle = this.colors.raised
+ this.ctx.fill()
+ this.ctx.lineWidth = PXSCALE
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 7.5 * PXSCALE, d - 12.5 * PXSCALE, 15 * PXSCALE, 13.5 * PXSCALE)
+ this.ctx.lineWidth = PXSCALE
+ this.ctx.strokeStyle = this.colors.light
+ this.ctx.stroke()
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 8 * PXSCALE, d - 13 * PXSCALE, 16 * PXSCALE, PXSCALE)
+ this.ctx.lineWidth = PXSCALE
+ this.ctx.fillStyle = this.colors.light
+ this.ctx.fill()
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 4 * PXSCALE, d, 8 * PXSCALE, PXSCALE)
+ this.ctx.fillStyle = this.colors.knob
+ this.ctx.fill()
+
+ // low knob
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 8 * PXSCALE, d2, 16 * PXSCALE, 14 * PXSCALE)
+ this.ctx.fillStyle = this.colors.raised
+ this.ctx.fill()
+ this.ctx.lineWidth = PXSCALE
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 7.5 * PXSCALE, d2, 15 * PXSCALE, 13.5 * PXSCALE)
+ this.ctx.lineWidth = PXSCALE
+ this.ctx.strokeStyle = this.colors.light
+ this.ctx.stroke()
+
+ this.ctx.beginPath()
+ this.ctx.rect(m - 4 * PXSCALE, d2, 8 * PXSCALE, PXSCALE)
+ this.ctx.fillStyle = this.colors.knob
+ this.ctx.fill()
+
+
+
+ this.clearRect = [width / 2 - 11 * PXSCALE, 0, 22 * PXSCALE, height]
+ }
+ }
+
+}
+
+
+module.exports = class Range extends _widgets_base {
+
+ static defaults() {
+
+ return {
+ type:'range',
+ id:'auto',
+ linkId:'',
+
+ _geometry:'geometry',
+
+ left:'auto',
+ top:'auto',
+ width:'auto',
+ height:'auto',
+
+ _style:'style',
+
+ label:'auto',
+ color:'auto',
+ css:'',
+
+ _fader:'fader',
+
+ horizontal:false,
+ alignRight:false,
+ input: true,
+ compact:false,
+ pips:true,
+ snap:false,
+ spring:false,
+ range:{min:0,max:1},
+ logScale:false,
+ value:'',
+
+ _osc:'osc',
+
+ precision:2,
+ address:'auto',
+ touchAddress:'',
+ preArgs:[],
+ split:false,
+ target:[]
+ }
+
+ }
+
+ constructor(options) {
+
+ var html = `
+
+ `
+
+ super({...options, html: html})
+
+ this.split = this.getProp('split')?
+ typeof this.getProp('split') == 'object' && this.getProp('split').length == 2 ?
+ this.getProp('split')
+ : [this.getProp('address') + '/low', this.getProp('address') + '/high']
+ : false
+
+ this.wrapper = DOM.get(this.widget, '.wrapper')[0]
+
+ this.faders = [
+ new RangeFader({props:{
+ ...faderDefaults,
+ compact:this.getProp('compact'),
+ pips:false,
+ alignRight:false,
+ horizontal:this.getProp('horizontal'),
+ height:'100%',
+ width:'100%',
+ value:this.getProp('value').length==2?this.getProp('value')[0]:'',
+ snap:this.getProp('snap'),
+ spring:this.getProp('spring'),
+ range:this.getProp('range'),
+ origin:'auto',
+ precision:this.precision,
+ logScale:this.getProp('logScale'),
+ input:false
+ }, cancelDraw: true, parent: this}),
+ new RangeFader({props:{
+ ...faderDefaults,
+ compact:this.getProp('compact'),
+ pips:this.getProp('pips'),
+ alignRight:this.getProp('alignRight'),
+ horizontal:this.getProp('horizontal'),
+ height:'100%',
+ width:'100%',
+ value:this.getProp('value').length==2?this.getProp('value')[1]:'',
+ snap:this.getProp('snap'),
+ spring:this.getProp('spring'),
+ range:this.getProp('range'),
+ origin:'auto',
+ precision:this.precision,
+ logScale:this.getProp('logScale'),
+ input:false
+ }, cancelDraw: false, parent: this})
+ ]
+
+ this.wrapper.appendChild(this.faders[0].widget)
+ this.wrapper.appendChild(this.faders[1].widget)
+
+ this.on('change',(e)=>{
+
+ if (e.widget == this) return
+
+ e.stopPropagation = true
+
+ var v = [
+ this.faders[0].getValue(),
+ this.faders[1].getValue()
+ ]
+
+ this.setValue(v, e.options)
+
+ })
+
+ this.touchMap = {}
+
+ touchstate(this, {element: this.wrapper, multitouch: true})
+
+ this.on('draginit',(e)=>{
+
+ var id
+
+ if (!this.touchMap[e.pointerId]) {
+
+ var ndiff, diff = -1
+
+ for (var i in this.faders) {
+
+ if (Object.values(this.touchMap).indexOf(i) != -1) continue
+
+ var coord = this.faders[i].percentToCoord(this.faders[i].valueToPercent(this.faders[i].value)) - (this.getProp('horizontal') ? -1 : 1) * (i == 0 ? -20 : 20)
+
+ ndiff = this.getProp('horizontal')?
+ Math.abs(e.offsetX - coord) :
+ Math.abs(e.offsetY - coord)
+
+ if (diff == -1 || ndiff < diff) {
+ id = i
+ diff = ndiff
+ }
+
+ }
+
+ this.touchMap[e.pointerId] = id
+
+
+ } else if (e.traversing) {
+
+ id = this.touchMap[e.pointerId]
+
+ }
+
+ if (!id) return
+
+ e.stopPropagation = true
+ this.faders[id].trigger('draginit', [e])
+
+ }, {element: this.wrapper, multitouch: true})
+
+ this.on('drag',(e)=>{
+
+ var i = this.touchMap[e.pointerId]
+ if (e.shiftKey) {
+ this.faders[0].trigger('drag', [e])
+ this.faders[1].trigger('drag', [e])
+ } else {
+ this.faders[i].trigger('drag', [e])
+ }
+
+ }, {element: this.wrapper, multitouch: true})
+
+ this.on('dragend',(e)=>{
+
+ var i = this.touchMap[e.pointerId]
+ e.stopPropagation = true
+ this.faders[i].trigger('dragend', [e])
+ delete this.touchMap[e.pointerId]
+
+ }, {element: this.wrapper, multitouch: true})
+
+ if (this.getProp('input')) {
+
+ this.input = new Input({
+ props:{...Input.defaults(),
+ precision:this.getProp('precision'),
+ unit:this.getProp('unit'),
+ vertical: this.getProp('compact') && !this.getProp('horizontal')
+ },
+ parent:this, parentNode:this.widget,
+ })
+ this.widget.appendChild(this.input.widget)
+ this.input.on('change', (e)=>{
+ e.stopPropagation = true
+ this.setValue(this.input.getValue(), {sync:true, send:true})
+ this.showValue()
+ })
+
+ this.widget.addEventListener('fast-right-click',function(e){
+ if (!EDITING) {
+ e.stopPropagation()
+ e.preventDefault()
+ this.input.canvas.focus()
+ }
+ }.bind(this))
+
+ }
+
+
+ if (this.getProp('horizontal')) {
+ this.widget.classList.add('horizontal')
+ this.container.classList.add('horizontal')
+ }
+ if (this.getProp('alignRight') && !this.getProp('horizontal')) {
+ this.widget.classList.add('align-right')
+ }
+ if (this.getProp('compact')) {
+ this.widget.classList.add('compact')
+ }
+ if (this.getProp('pips')) {
+ this.widget.classList.add('has-pips')
+ }
+
+ this.setValue([
+ this.faders[0].rangeValsMin,
+ this.faders[1].rangeValsMax
+ ])
+
+ }
+
+ setValue(v, options={}) {
+ if (!v || !v.length || v.length!=2) return
+
+
+ this.faders[0].rangeValsMax = v[1]
+ this.faders[1].rangeValsMin = v[0]
+
+ if (!options.dragged) {
+ this.faders[0].setValue(v[0])
+ this.faders[1].setValue(v[1])
+ }
+
+ this.value = [
+ this.faders[0].getValue(),
+ this.faders[1].getValue()
+ ]
+
+
+ if (options.send) this.sendValue()
+ if (options.sync) this.changed(options)
+
+ this.faders[1].batchDraw()
+
+ this.showValue()
+
+
+ }
+
+ showValue() {
+
+ if (this.getProp('input')) this.input.setValue(this.value)
+
+ }
+
+ onRemove() {
+ this.faders[0].onRemove()
+ this.faders[1].onRemove()
+ if (this.input) this.input.onRemove()
+ super.onRemove()
+ }
+
+}
diff --git a/src/browser/js/app/widgets/switchers/_switchers_base.js b/src/browser/js/app/widgets/switchers/_switchers_base.js
index 5c065ac3..5cb5ca2d 100644
--- a/src/browser/js/app/widgets/switchers/_switchers_base.js
+++ b/src/browser/js/app/widgets/switchers/_switchers_base.js
@@ -19,7 +19,7 @@ module.exports = class _switchers_base extends _widgets_base {
}
- $('body').on(`change.${this.hash}`,this.syncHandler.bind(this))
+ widgetManager.on(`change.${this.hash}`,this.syncHandler.bind(this))
}
@@ -36,14 +36,6 @@ module.exports = class _switchers_base extends _widgets_base {
}
-
- onRemove() {
-
- $('body').off(`change.${this.hash}`)
- super.onRemove()
-
- }
-
isWatching(id, widget) {
if (this.linkedWidgets.indexOf(id) != -1) return true
@@ -54,7 +46,7 @@ module.exports = class _switchers_base extends _widgets_base {
for (var i in widgets) {
- if (widgets[i].widget[0].contains(widget.widget[0])) return true
+ if (widgets[i].childrenHashes.indexOf(widget.hash) != -1) return true
}
@@ -95,16 +87,14 @@ module.exports = class _switchers_base extends _widgets_base {
for (var id in state) {
var value = state[id],
widgets = widgetManager.getWidgetById(id)
- if (widgets.length) {
- for (var i=widgets.length-1;i>=0;i--) {
- if (widgets[i].setValue) {
- widgets[i].setValue(value,{sync:options.sync, send:options.send})
- }
+ for (var i = widgets.length - 1; i >= 0; i--) {
+ if (widgets[i].setValue) {
+ widgets[i].setValue(value,{sync:options.sync, send:options.send})
}
}
}
- if (options.sync) this.widget.trigger({type:'change',id:this.getProp('id'),widget:this, linkId:this.getProp('linkId'), options:options})
+ if (options.sync) this.changed(options)
if (options.send) this.sendValue()
}
diff --git a/src/browser/js/app/widgets/switchers/crossfader.js b/src/browser/js/app/widgets/switchers/crossfader.js
index ed3fbdbd..745d6112 100644
--- a/src/browser/js/app/widgets/switchers/crossfader.js
+++ b/src/browser/js/app/widgets/switchers/crossfader.js
@@ -27,20 +27,22 @@ module.exports = class Crossfader extends Switcher {
...faderDefaults,
horizontal: this.getProp('horizontal'),
range: {min:{'A':0}, '50%':{" ":0.5},max:{'B':1}}
- }})
+ }, parent: this})
this.fader.sendValue = ()=>{}
- this.widget.append($('').append(this.fader.widget))
+ this.widget.appendChild(DOM.create('')).appendChild(this.fader.widget)
- this.fader.widget.on('change', (e)=>{
+ this.fader.on('change', (e)=>{
- e.stopPropagation()
+ e.stopPropagation = true
this.setValue(this.fader.getValue(), e.options)
})
+ this.value._fader = 0
+
}
setValue(v, options={}) {
@@ -111,4 +113,9 @@ module.exports = class Crossfader extends Switcher {
}
+ onRemove() {
+ this.fader.onRemove()
+ super.onRemove()
+ }
+
}
diff --git a/src/browser/js/app/widgets/switchers/switcher.js b/src/browser/js/app/widgets/switchers/switcher.js
index 8cf31ae5..90c8057f 100644
--- a/src/browser/js/app/widgets/switchers/switcher.js
+++ b/src/browser/js/app/widgets/switchers/switcher.js
@@ -30,7 +30,7 @@ module.exports = class Switcher extends _switchers_base {
horizontal:false,
linkedWidgets:'',
values:['A', 'B'],
- value:'A',
+ value:'',
_osc:'osc',
@@ -45,7 +45,7 @@ module.exports = class Switcher extends _switchers_base {
super({...options, html: ''})
- if (this.getProp('horizontal')) this.widget.addClass('horizontal')
+ if (this.getProp('horizontal')) this.widget.classList.add('horizontal')
this.switch = new Switch({props:{
...switchDefaults,
@@ -53,21 +53,18 @@ module.exports = class Switcher extends _switchers_base {
values:this.getProp('values'),
value: this.getProp('value'),
horizontal:this.getProp('horizontal')
- }})
+ }, parent: this})
this.switch.sendValue = ()=>{}
- this.widget.append(this.switch.widget)
+ this.widget.appendChild(this.switch.widget)
- this.switch.widget.on('change', (e)=>{
+ this.switch.on('change', (e)=>{
- e.stopPropagation()
+ e.stopPropagation = true
+ e.options.fromSelf = true
- var {widget, options} = e
-
- options.fromSelf = true
-
- this.setValue(this.switch.getValue(), options)
+ this.setValue(this.switch.getValue(), e.options)
})
@@ -76,11 +73,15 @@ module.exports = class Switcher extends _switchers_base {
setValue(v, options={}) {
- super.setValue(...arguments)
+ super.setValue(v, options)
if (!options.fromSelf) this.switch.setValue(this.value._selected)
}
+ onRemove() {
+ this.switch.onRemove()
+ super.onRemove()
+ }
}
diff --git a/src/browser/js/app/widgets/utils.js b/src/browser/js/app/widgets/utils.js
index db755163..c33a9da8 100644
--- a/src/browser/js/app/widgets/utils.js
+++ b/src/browser/js/app/widgets/utils.js
@@ -1,3 +1,11 @@
+var math = require('mathjs/dist/math.min.js').create({
+ matrix: 'Array'
+})
+
+// set math's parser array index base to zero
+math.expression.mathWithTransform = Object.assign({}, math)
+
+
module.exports = {
clip: function(value,range) {
@@ -70,10 +78,5 @@ module.exports = {
return hsb
},
- math: function(){
- var math = require('mathjs/dist/math.min.js')
- // set math's parser array index base to zero
- math.expression.transform = Object.create(math)
- return math
- }()
+ math: math
}
diff --git a/src/browser/js/browser.js b/src/browser/js/browser.js
index efe3b8cb..99c050de 100644
--- a/src/browser/js/browser.js
+++ b/src/browser/js/browser.js
@@ -1,17 +1,25 @@
+require('./app/stacktrace')
+
require('./app/globals')
-require('./app/sourcemap')
-var ipc = require('./app/ipc/'),
- osc = require('./app/osc'),
- parser = require('./app/parser'),
- {loading} = require('./app/utils')
+var {loading} = require('./app/ui/utils')
-ipc.init()
-osc.init()
-parser.init()
+document.addEventListener("DOMContentLoaded", function(event) {
+
+ DOM.init()
-$(document).ready(function(){
LOADING = loading('Connecting server...')
- require('./app/ui')
- ipc.send('ready')
+
+ setTimeout(()=>{
+
+ var ipc = require('./app/ipc/')
+
+ ipc.init()
+
+ require('./app/ui/init')
+ ipc.send('ready')
+
+
+ }, 100)
+
})
diff --git a/src/browser/js/libs/jquery.drag.js b/src/browser/js/libs/jquery.drag.js
deleted file mode 100644
index f12660f4..00000000
--- a/src/browser/js/libs/jquery.drag.js
+++ /dev/null
@@ -1,395 +0,0 @@
-// jQuery drag event handler
-// note: triggerHandler() is used instead of trigger() when event bubblig is not
-// necessary, this increases performances a lot.
-;(function($){
- var events = {
- touch:{start:'touchstart',stop:'touchend touchcancel',move:'touchmove',touch:true},
- mouse:{start:'mousedown',stop:'mouseup',move:'mousemove',out:'mouseout',touch:false}
- },
-
-
- $document = $(document),
- getOffset = function(obj) {
- var offsetLeft = 0
- var offsetTop = 0
- if (obj) {
- do {
- if (!isNaN(obj.offsetLeft)) {
- offsetLeft += obj.offsetLeft - obj.scrollLeft
- }
- if (!isNaN(obj.offsetTop)) {
- offsetTop += obj.offsetTop - obj.scrollTop
- }
- } while(obj = obj.offsetParent )
- }
-
- return {left: offsetLeft, top: offsetTop}
- }
-
-
- $.event.special.draginit = $.event.special.drag = {
- setup:function(){
-
- var $this = $(this)
-
- if ($this.data('dragSetup') == 'true') return
- $this.data('dragSetup','true')
-
-
- // mouse single touch handler
- var previousEvent = null,
- target = null,
- traversing = false,
- mouseStartHandler = function(e){
-
- // ignore mouse event when fired by a simulated touch event
- if ((e.originalEvent.sourceCapabilities && e.originalEvent.sourceCapabilities.firesTouchEvents) || e.button == 2) return
-
- target = $this
- previousEvent = e
-
- e.speedX = 0
- e.speedY = 0
- e.deltaX = 0
- e.deltaY = 0
-
- target.triggerHandler('draginit',[e,e.originalEvent.traversing])
-
- $document.on(events.mouse.move,mouseMoveHandler)
- $document.on(events.mouse.stop,mouseStopHandler)
- $document.on(events.mouse.out,mouseOutHandler)
-
- },
- mouseMoveHandler = function(e){
- e.stopPropagation()
-
- e.speedX = e.pageX - previousEvent.pageX
- e.speedY = e.pageY - previousEvent.pageY
- e.deltaX = e.speedX + previousEvent.deltaX
- e.deltaY = e.speedY + previousEvent.deltaY
-
-
- if (e.originalEvent.traversing) {
- target = $(e.target)
- e.preventDefault()
- target.triggerHandler('draginit',[e,e.originalEvent.traversing])
- } else {
- target.triggerHandler('drag',[e,e.originalEvent.traversing])
- }
-
- previousEvent = e
- },
- mouseStopHandler = function(e){
- e.stopPropagation()
-
- // ignore mouse event when fired by a simulated touch event
- if (e.originalEvent.sourceCapabilities && e.originalEvent.sourceCapabilities.firesTouchEvents) return
-
- e.speedX = e.pageX - previousEvent.pageX
- e.speedY = e.pageY - previousEvent.pageY
- e.deltaX = e.deltaX + previousEvent.deltaX
- e.deltaY = e.deltaY + previousEvent.deltaY
-
-
- target.trigger('dragend',[e,e.originalEvent.traversing])
-
- $document.off(events.mouse.move,mouseMoveHandler)
- $document.off(events.mouse.stop,mouseStopHandler)
- $document.off(events.mouse.out,mouseOutHandler)
- },
- mouseOutHandler = function(e){
- if (e.originalEvent.traversing) {
- e.stopPropagation()
-
- e.speedX = e.pageX - previousEvent.pageX
- e.speedY = e.pageY - previousEvent.pageY
- e.deltaX = e.deltaX + previousEvent.deltaX
- e.deltaY = e.deltaY + previousEvent.deltaY
-
- target.trigger('dragend',[e,e.originalEvent.traversing])
-
- previousEvent = e
-
- }
- }
-
-
- $this.on(events.mouse.start + '.drag-osc',mouseStartHandler)
-
-
- // multi touch hanlder
- window.targets = window.targets || {}
- window.previousTouches = window.previousTouches || {}
- window.touchActive = window.touchActive || false
-
- var self = this,
- touchStartHandler = function(e){
- e.preventDefault()
-
- var oE = e.originalEvent
-
- for (let i in oE.changedTouches) {
- if (isNaN(i) || !oE.changedTouches[i]) continue
-
- var touch = oE.changedTouches[i],
- id = touch.identifier,
- emit = true
-
- for (let j in targets) {
- if (targets[j][0].isSameNode(touch.target)) {
- emit = false
- break
- }
- }
-
- targets[id] = $(touch.target)
- previousTouches[id] = {
- deltaX:touch.deltaX,
- deltaY:touch.deltaY,
- offsetX:touch.offsetX,
- offsetY:touch.offsetY,
- speedX:touch.speedX,
- speedY:touch.speedY,
- pageX:touch.pageX,
- pageY:touch.pageY,
- clientX:touch.clientX,
- clientY:touch.clientY
- }
-
- touch.speedX = 0
- touch.speedY = 0
-
- touch.deltaX = 0
- touch.deltaY = 0
-
- var off = getOffset(touch.target)
- touch.offsetX = touch.pageX-off.left
- touch.offsetY = touch.pageY-off.top
-
-
- if (emit) targets[id].triggerHandler('draginit',[touch,e.originalEvent.traversing])
-
- }
-
- if (!touchActive) {
- $document.on(events.touch.move,touchMoveHandler)
- $document.on(events.touch.stop,touchStopHandler)
- touchActive = true
- }
-
- },
- touchMoveHandler = function(e){
-
- var oE = e.originalEvent
-
- for (let i in oE.changedTouches) {
- if (isNaN(i) || !oE.changedTouches[i]) continue
-
- var nFingers = 0
- for (let j in oE.touches) {
- if (oE.touches[j].target && oE.touches[j].target.isSameNode(oE.changedTouches[i].target)) {
- nFingers += 1
- }
- }
-
- var touch = oE.changedTouches[i],
- id = touch.identifier,
- speedFactor = nFingers * nFingers
-
- if (e.originalEvent.traversing) {
- targets[id] = $(document.elementFromPoint(touch.clientX, touch.clientY))
- }
-
- if (!targets[id]) continue
-
- touch.speedX = (touch.pageX - previousTouches[id].pageX) / speedFactor
- touch.speedY = (touch.pageY - previousTouches[id].pageY) / speedFactor
-
- touch.deltaX = touch.speedX + previousTouches[id].deltaX
- touch.deltaY = touch.speedY + previousTouches[id].deltaY
-
- touch.offsetX = previousTouches[id].offsetX+touch.speedX
- touch.offsetY = previousTouches[id].offsetY+touch.speedY
-
- if (e.originalEvent.traversing) {
- touch.traversing = true
- var previousTarget = document.elementFromPoint(previousTouches[id].clientX, previousTouches[id].clientY)
- if (targets[id][0]!=previousTarget) {
- var off = getOffset(targets[id][0])
- touch.offsetX = touch.pageX-off.left
- touch.offsetY = touch.pageY-off.top
- $(previousTarget).trigger('dragend',[touch,e.originalEvent.traversing])
- }
- e.preventDefault()
- if (oE.traversingContainer.contains(targets[id][0])) targets[id].triggerHandler('draginit',[touch,e.originalEvent.traversing])
-
- } else {
-
- targets[id].triggerHandler('drag',[touch,e.originalEvent.traversing])
-
- }
-
- previousTouches[id] = {
- deltaX:touch.deltaX,
- deltaY:touch.deltaY,
- offsetX:touch.offsetX,
- offsetY:touch.offsetY,
- speedX:touch.speedX,
- speedY:touch.speedY,
- pageX:touch.pageX,
- pageY:touch.pageY,
- clientX:touch.clientX,
- clientY:touch.clientY
- }
-
- }
-
- },
- touchStopHandler = function(e){
-
- var oE = e.originalEvent
-
- for (let i in oE.changedTouches) {
-
- if (isNaN(i) || !oE.changedTouches[i]) continue
-
- var touch = oE.changedTouches[i],
- id = touch.identifier
-
- $(targets[id]).trigger('dragend',[touch,e.originalEvent.traversing])
-
- delete previousTouches[id]
- delete targets[id]
-
- }
-
- if (oE.touches.length==0) {
- $document.off(events.touch.move,touchMoveHandler)
- $document.off(events.touch.stop,touchStopHandler)
- touchActive = false
- }
-
- }
-
- $this.on(events.touch.start + '.drag-osc',touchStartHandler)
-
-
- },
- teardown: function(){
- var $this = $(this)
- $this.off(events.touch.start + '.drag-osc')
- $this.off(events.mouse.start + '.drag-osc')
- $this.data('dragSetup','false')
- }
-
- }
-
-
-
-
-
-
-
-
- var makeEventTraversing = function(e){
- e.traversing=true
- if (!e.traversingContainer) e.traversingContainer=this
- }
-
-
- $.fn.enableTraversingGestures = function() {
-
- var self = this[0]
-
- var down = function(e){
- makeEventTraversing(e)
- self.addEventListener("mousemove", makeEventTraversing, true)
- self.addEventListener("touchmove", makeEventTraversing, true)
- self.addEventListener("mouseout", makeEventTraversing, true)
- document.addEventListener("mouseup",up,true)
- document.addEventListener("touchend",up,true)
- },
- up = function(e){
- makeEventTraversing(e)
- self.removeEventListener("mousemove", makeEventTraversing, true)
- self.removeEventListener("touchmove", makeEventTraversing, true)
- self.removeEventListener("mouseout", makeEventTraversing, true)
- document.removeEventListener("mouseup",up,true)
- document.removeEventListener("touchend",up,true)
- }
-
- self.addEventListener("mousedown", down, true)
- self.addEventListener("touchstart", down, true)
-
- this.on('draginit.traversing',()=>{})
-
- this.on('disableTraversingGestures',()=>{
- this.off('draginit.traversing')
- self.removeEventListener("mousedown", down, true)
- self.removeEventListener("touchstart", down, true)
- })
-
-
- return this
-
- }
-
- $.fn.disableTraversingGestures = function() {
-
- this.trigger('disableTraversingGestures')
-
- }
-
-
- var longTapTimer = false,
- clearLongTapTimer = function() {
- clearTimeout(longTapTimer)
- longTapTimer = false
- }
-
- $document.on('mousedown',function(e){
-
- if (e.originalEvent.sourceCapabilities && e.originalEvent.sourceCapabilities.firesTouchEvents) return
-
-
- if (e.button==2) {
-
- e.preventDefault()
- $(e.target).trigger('fake-right-click', e)
-
- } else {
-
- $(e.target).trigger('fake-click', e)
-
- }
-
- })
-
- $document.on(events.touch.start,function(e){
- var touch = e.originalEvent.changedTouches[0]
-
- $(e.target).trigger('fake-click', touch)
-
- if (!longTapTimer&&e.originalEvent.touches.length==1) {
- longTapTimer = setTimeout(function(){
- if (longTapTimer) {
- var off = getOffset(touch.target)
-
- touch.offsetX = touch.pageX-off.left
- touch.offsetY = touch.pageY-off.top
- $(e.originalEvent.changedTouches[0].target).trigger('fake-right-click',touch)
- }
- longTapTimer = false
- },600)
- } else {
- clearLongTapTimer()
- }
- })
-
- $document.on(events.touch.stop + ' ' + events.touch.move,function(e){
- clearLongTapTimer()
- })
-
- $document.on('contextmenu',function(){return false})
-
-})($)
diff --git a/src/browser/js/libs/jquery.resize.js b/src/browser/js/libs/jquery.resize.js
deleted file mode 100644
index d1b14fcc..00000000
--- a/src/browser/js/libs/jquery.resize.js
+++ /dev/null
@@ -1,84 +0,0 @@
-/* jquery.resize
- * based on jQuery resize event (@ "Cowboy" Ben Alman http://benalman.com/projects/jquery-resize-plugin/)
- * just lighter and faster
-*/
-(function($){
-
- var elems = []
-
- $.event.special.resize = {
- setup: function(data, namespaces, handler) {
-
- if (this===window) return false
-
- // Add this element to the list of internal elements to monitor.
- elems.push(this)
-
- },
- teardown: function() {
-
- if (this===window) return false
-
- // Remove this element from the list of internal elements to monitor.
- for (var i = elems.length - 1; i >= 0; i--) {
- if(elems[i] == this){
- elems.splice(i, 1)
- break
- }
- }
-
- },
- add: function(handleObj) {
- if (this===window) return false
-
- if (this.resizeHandler) {
-
- var handler = this.resizeHandler
-
- this.resizeHandler = function(){
- handler(...arguments)
- handleObj.handler(...arguments)
- }
-
- } else {
-
- this.resizeHandler = function(){
- handleObj.handler(...arguments)
- }
-
- }
- }
-
- }
-
- function checkResizes(){
- // Iterate over all elements to which the 'resize' event is bound.
- var resizedElems = []
- for (var i = elems.length - 1; i >= 0; i--) {
- var elem = elems[i]
-
- if (!document.contains(elem)) continue
-
- var style = window.getComputedStyle(elem),
- width = parseInt(style['width']) - parseInt(style['padding-left']) - parseInt(style['padding-right']),
- height = parseInt(style['height']) - parseInt(style['padding-top']) - parseInt(style['padding-bottom'])
-
- if (!width) continue
-
- // If element size has changed since the last time, update the element
- // data store and trigger the 'resize' event.
- if ( width != elem.resizedataw || height != elem.resizedatah ) {
- elem.resizedataw = width
- elem.resizedatah = height
- resizedElems.push(elem)
- }
- }
- for (var i = resizedElems.length - 1; i >= 0; i--) {
- resizedElems[i].resizeHandler(undefined, resizedElems[i].resizedataw, resizedElems[i].resizedatah)
- }
-
- }
-
- $(window).resize(checkResizes)
-
-})($)
diff --git a/src/browser/js/libs/source-map.min.js b/src/browser/js/libs/source-map.min.js
deleted file mode 100644
index 2e9876d8..00000000
--- a/src/browser/js/libs/source-map.min.js
+++ /dev/null
@@ -1,4 +0,0 @@
-// source-map
-// Copyright (c) 2009-2011, Mozilla Foundation and contributors
-// All rights reserved.
-!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.sourceMap=n():e.sourceMap=n()}(this,function(){return function(e){function n(t){if(r[t])return r[t].exports;var o=r[t]={exports:{},id:t,loaded:!1};return e[t].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}var r={};return n.m=e,n.c=r,n.p="",n(0)}([function(e,n,r){n.SourceMapGenerator=r(1).SourceMapGenerator,n.SourceMapConsumer=r(7).SourceMapConsumer,n.SourceNode=r(10).SourceNode},function(e,n,r){function t(e){e||(e={}),this._file=i.getArg(e,"file",null),this._sourceRoot=i.getArg(e,"sourceRoot",null),this._skipValidation=i.getArg(e,"skipValidation",!1),this._sources=new s,this._names=new s,this._mappings=new a,this._sourcesContents=null}var o=r(2),i=r(4),s=r(5).ArraySet,a=r(6).MappingList;t.prototype._version=3,t.fromSourceMap=function(e){var n=e.sourceRoot,r=new t({file:e.file,sourceRoot:n});return e.eachMapping(function(e){var t={generated:{line:e.generatedLine,column:e.generatedColumn}};null!=e.source&&(t.source=e.source,null!=n&&(t.source=i.relative(n,t.source)),t.original={line:e.originalLine,column:e.originalColumn},null!=e.name&&(t.name=e.name)),r.addMapping(t)}),e.sources.forEach(function(n){var t=e.sourceContentFor(n);null!=t&&r.setSourceContent(n,t)}),r},t.prototype.addMapping=function(e){var n=i.getArg(e,"generated"),r=i.getArg(e,"original",null),t=i.getArg(e,"source",null),o=i.getArg(e,"name",null);this._skipValidation||this._validateMapping(n,r,t,o),null!=t&&(t=String(t),this._sources.has(t)||this._sources.add(t)),null!=o&&(o=String(o),this._names.has(o)||this._names.add(o)),this._mappings.add({generatedLine:n.line,generatedColumn:n.column,originalLine:null!=r&&r.line,originalColumn:null!=r&&r.column,source:t,name:o})},t.prototype.setSourceContent=function(e,n){var r=e;null!=this._sourceRoot&&(r=i.relative(this._sourceRoot,r)),null!=n?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[i.toSetString(r)]=n):this._sourcesContents&&(delete this._sourcesContents[i.toSetString(r)],0===Object.keys(this._sourcesContents).length&&(this._sourcesContents=null))},t.prototype.applySourceMap=function(e,n,r){var t=n;if(null==n){if(null==e.file)throw new Error('SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map\'s "file" property. Both were omitted.');t=e.file}var o=this._sourceRoot;null!=o&&(t=i.relative(o,t));var a=new s,u=new s;this._mappings.unsortedForEach(function(n){if(n.source===t&&null!=n.originalLine){var s=e.originalPositionFor({line:n.originalLine,column:n.originalColumn});null!=s.source&&(n.source=s.source,null!=r&&(n.source=i.join(r,n.source)),null!=o&&(n.source=i.relative(o,n.source)),n.originalLine=s.line,n.originalColumn=s.column,null!=s.name&&(n.name=s.name))}var l=n.source;null==l||a.has(l)||a.add(l);var c=n.name;null==c||u.has(c)||u.add(c)},this),this._sources=a,this._names=u,e.sources.forEach(function(n){var t=e.sourceContentFor(n);null!=t&&(null!=r&&(n=i.join(r,n)),null!=o&&(n=i.relative(o,n)),this.setSourceContent(n,t))},this)},t.prototype._validateMapping=function(e,n,r,t){if((!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0)||n||r||t)&&!(e&&"line"in e&&"column"in e&&n&&"line"in n&&"column"in n&&e.line>0&&e.column>=0&&n.line>0&&n.column>=0&&r))throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:r,original:n,name:t}))},t.prototype._serializeMappings=function(){for(var e,n,r,t,s=0,a=1,u=0,l=0,c=0,g=0,p="",h=this._mappings.toArray(),f=0,d=h.length;d>f;f++){if(n=h[f],e="",n.generatedLine!==a)for(s=0;n.generatedLine!==a;)e+=";",a++;else if(f>0){if(!i.compareByGeneratedPositionsInflated(n,h[f-1]))continue;e+=","}e+=o.encode(n.generatedColumn-s),s=n.generatedColumn,null!=n.source&&(t=this._sources.indexOf(n.source),e+=o.encode(t-g),g=t,e+=o.encode(n.originalLine-1-l),l=n.originalLine-1,e+=o.encode(n.originalColumn-u),u=n.originalColumn,null!=n.name&&(r=this._names.indexOf(n.name),e+=o.encode(r-c),c=r)),p+=e}return p},t.prototype._generateSourcesContent=function(e,n){return e.map(function(e){if(!this._sourcesContents)return null;null!=n&&(e=i.relative(n,e));var r=i.toSetString(e);return Object.prototype.hasOwnProperty.call(this._sourcesContents,r)?this._sourcesContents[r]:null},this)},t.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return null!=this._file&&(e.file=this._file),null!=this._sourceRoot&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e},t.prototype.toString=function(){return JSON.stringify(this.toJSON())},n.SourceMapGenerator=t},function(e,n,r){function t(e){return 0>e?(-e<<1)+1:(e<<1)+0}function o(e){var n=1===(1&e),r=e>>1;return n?-r:r}var i=r(3),s=5,a=1<>>=s,o>0&&(n|=l),r+=i.encode(n);while(o>0);return r},n.decode=function(e,n,r){var t,a,c=e.length,g=0,p=0;do{if(n>=c)throw new Error("Expected more digits in base 64 VLQ value.");if(a=i.decode(e.charCodeAt(n++)),-1===a)throw new Error("Invalid base64 digit: "+e.charAt(n-1));t=!!(a&l),a&=u,g+=a<=0&&e=n&&r>=e?e-n:e>=t&&o>=e?e-t+l:e>=i&&s>=e?e-i+c:e==a?62:e==u?63:-1}},function(e,n){function r(e,n,r){if(n in e)return e[n];if(3===arguments.length)return r;throw new Error('"'+n+'" is a required argument.')}function t(e){var n=e.match(m);return n?{scheme:n[1],auth:n[2],host:n[3],port:n[4],path:n[5]}:null}function o(e){var n="";return e.scheme&&(n+=e.scheme+":"),n+="//",e.auth&&(n+=e.auth+"@"),e.host&&(n+=e.host),e.port&&(n+=":"+e.port),e.path&&(n+=e.path),n}function i(e){var r=e,i=t(e);if(i){if(!i.path)return e;r=i.path}for(var s,a=n.isAbsolute(r),u=r.split(/\/+/),l=0,c=u.length-1;c>=0;c--)s=u[c],"."===s?u.splice(c,1):".."===s?l++:l>0&&(""===s?(u.splice(c+1,l),l=0):(u.splice(c,2),l--));return r=u.join("/"),""===r&&(r=a?"/":"."),i?(i.path=r,o(i)):r}function s(e,n){""===e&&(e="."),""===n&&(n=".");var r=t(n),s=t(e);if(s&&(e=s.path||"/"),r&&!r.scheme)return s&&(r.scheme=s.scheme),o(r);if(r||n.match(_))return n;if(s&&!s.host&&!s.path)return s.host=n,o(s);var a="/"===n.charAt(0)?n:i(e.replace(/\/+$/,"")+"/"+n);return s?(s.path=a,o(s)):a}function a(e,n){""===e&&(e="."),e=e.replace(/\/$/,"");for(var r=0;0!==n.indexOf(e+"/");){var t=e.lastIndexOf("/");if(0>t)return n;if(e=e.slice(0,t),e.match(/^([^\/]+:\/)?\/*$/))return n;++r}return Array(r+1).join("../")+n.substr(e.length+1)}function u(e){return e}function l(e){return g(e)?"$"+e:e}function c(e){return g(e)?e.slice(1):e}function g(e){if(!e)return!1;var n=e.length;if(9>n)return!1;if(95!==e.charCodeAt(n-1)||95!==e.charCodeAt(n-2)||111!==e.charCodeAt(n-3)||116!==e.charCodeAt(n-4)||111!==e.charCodeAt(n-5)||114!==e.charCodeAt(n-6)||112!==e.charCodeAt(n-7)||95!==e.charCodeAt(n-8)||95!==e.charCodeAt(n-9))return!1;for(var r=n-10;r>=0;r--)if(36!==e.charCodeAt(r))return!1;return!0}function p(e,n,r){var t=e.source-n.source;return 0!==t?t:(t=e.originalLine-n.originalLine,0!==t?t:(t=e.originalColumn-n.originalColumn,0!==t||r?t:(t=e.generatedColumn-n.generatedColumn,0!==t?t:(t=e.generatedLine-n.generatedLine,0!==t?t:e.name-n.name))))}function h(e,n,r){var t=e.generatedLine-n.generatedLine;return 0!==t?t:(t=e.generatedColumn-n.generatedColumn,0!==t||r?t:(t=e.source-n.source,0!==t?t:(t=e.originalLine-n.originalLine,0!==t?t:(t=e.originalColumn-n.originalColumn,0!==t?t:e.name-n.name))))}function f(e,n){return e===n?0:e>n?1:-1}function d(e,n){var r=e.generatedLine-n.generatedLine;return 0!==r?r:(r=e.generatedColumn-n.generatedColumn,0!==r?r:(r=f(e.source,n.source),0!==r?r:(r=e.originalLine-n.originalLine,0!==r?r:(r=e.originalColumn-n.originalColumn,0!==r?r:f(e.name,n.name)))))}n.getArg=r;var m=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.]*)(?::(\d+))?(\S*)$/,_=/^data:.+\,.+$/;n.urlParse=t,n.urlGenerate=o,n.normalize=i,n.join=s,n.isAbsolute=function(e){return"/"===e.charAt(0)||!!e.match(m)},n.relative=a;var v=function(){var e=Object.create(null);return!("__proto__"in e)}();n.toSetString=v?u:l,n.fromSetString=v?u:c,n.compareByOriginalPositions=p,n.compareByGeneratedPositionsDeflated=h,n.compareByGeneratedPositionsInflated=d},function(e,n,r){function t(){this._array=[],this._set=Object.create(null)}var o=r(4),i=Object.prototype.hasOwnProperty;t.fromArray=function(e,n){for(var r=new t,o=0,i=e.length;i>o;o++)r.add(e[o],n);return r},t.prototype.size=function(){return Object.getOwnPropertyNames(this._set).length},t.prototype.add=function(e,n){var r=o.toSetString(e),t=i.call(this._set,r),s=this._array.length;(!t||n)&&this._array.push(e),t||(this._set[r]=s)},t.prototype.has=function(e){var n=o.toSetString(e);return i.call(this._set,n)},t.prototype.indexOf=function(e){var n=o.toSetString(e);if(i.call(this._set,n))return this._set[n];throw new Error('"'+e+'" is not in the set.')},t.prototype.at=function(e){if(e>=0&&er||t==r&&s>=o||i.compareByGeneratedPositionsInflated(e,n)<=0}function o(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}var i=r(4);o.prototype.unsortedForEach=function(e,n){this._array.forEach(e,n)},o.prototype.add=function(e){t(this._last,e)?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))},o.prototype.toArray=function(){return this._sorted||(this._array.sort(i.compareByGeneratedPositionsInflated),this._sorted=!0),this._array},n.MappingList=o},function(e,n,r){function t(e){var n=e;return"string"==typeof e&&(n=JSON.parse(e.replace(/^\)\]\}'/,""))),null!=n.sections?new s(n):new o(n)}function o(e){var n=e;"string"==typeof e&&(n=JSON.parse(e.replace(/^\)\]\}'/,"")));var r=a.getArg(n,"version"),t=a.getArg(n,"sources"),o=a.getArg(n,"names",[]),i=a.getArg(n,"sourceRoot",null),s=a.getArg(n,"sourcesContent",null),u=a.getArg(n,"mappings"),c=a.getArg(n,"file",null);if(r!=this._version)throw new Error("Unsupported version: "+r);t=t.map(String).map(a.normalize).map(function(e){return i&&a.isAbsolute(i)&&a.isAbsolute(e)?a.relative(i,e):e}),this._names=l.fromArray(o.map(String),!0),this._sources=l.fromArray(t,!0),this.sourceRoot=i,this.sourcesContent=s,this._mappings=u,this.file=c}function i(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}function s(e){var n=e;"string"==typeof e&&(n=JSON.parse(e.replace(/^\)\]\}'/,"")));var r=a.getArg(n,"version"),o=a.getArg(n,"sections");if(r!=this._version)throw new Error("Unsupported version: "+r);this._sources=new l,this._names=new l;var i={line:-1,column:0};this._sections=o.map(function(e){if(e.url)throw new Error("Support for url field in sections not implemented.");var n=a.getArg(e,"offset"),r=a.getArg(n,"line"),o=a.getArg(n,"column");if(r=0){var i=this._originalMappings[o];if(void 0===e.column)for(var s=i.originalLine;i&&i.originalLine===s;)t.push({line:a.getArg(i,"generatedLine",null),column:a.getArg(i,"generatedColumn",null),lastColumn:a.getArg(i,"lastGeneratedColumn",null)}),i=this._originalMappings[++o];else for(var l=i.originalColumn;i&&i.originalLine===n&&i.originalColumn==l;)t.push({line:a.getArg(i,"generatedLine",null),column:a.getArg(i,"generatedColumn",null),lastColumn:a.getArg(i,"lastGeneratedColumn",null)}),i=this._originalMappings[++o]}return t},n.SourceMapConsumer=t,o.prototype=Object.create(t.prototype),o.prototype.consumer=t,o.fromSourceMap=function(e){var n=Object.create(o.prototype),r=n._names=l.fromArray(e._names.toArray(),!0),t=n._sources=l.fromArray(e._sources.toArray(),!0);n.sourceRoot=e._sourceRoot,n.sourcesContent=e._generateSourcesContent(n._sources.toArray(),n.sourceRoot),n.file=e._file;for(var s=e._mappings.toArray().slice(),u=n.__generatedMappings=[],c=n.__originalMappings=[],p=0,h=s.length;h>p;p++){var f=s[p],d=new i;d.generatedLine=f.generatedLine,d.generatedColumn=f.generatedColumn,f.source&&(d.source=t.indexOf(f.source),d.originalLine=f.originalLine,d.originalColumn=f.originalColumn,f.name&&(d.name=r.indexOf(f.name)),c.push(d)),u.push(d)}return g(n.__originalMappings,a.compareByOriginalPositions),n},o.prototype._version=3,Object.defineProperty(o.prototype,"sources",{get:function(){return this._sources.toArray().map(function(e){return null!=this.sourceRoot?a.join(this.sourceRoot,e):e},this)}}),o.prototype._parseMappings=function(e,n){for(var r,t,o,s,u,l=1,p=0,h=0,f=0,d=0,m=0,_=e.length,v=0,C={},y={},A=[],S=[];_>v;)if(";"===e.charAt(v))l++,v++,p=0;else if(","===e.charAt(v))v++;else{for(r=new i,r.generatedLine=l,s=v;_>s&&!this._charIsMappingSeparator(e,s);s++);if(t=e.slice(v,s),o=C[t])v+=t.length;else{for(o=[];s>v;)c.decode(e,v,y),u=y.value,v=y.rest,o.push(u);if(2===o.length)throw new Error("Found a source, but no line and column");if(3===o.length)throw new Error("Found a source and line, but no column");C[t]=o}r.generatedColumn=p+o[0],p=r.generatedColumn,o.length>1&&(r.source=d+o[1],d+=o[1],r.originalLine=h+o[2],h=r.originalLine,r.originalLine+=1,r.originalColumn=f+o[3],f=r.originalColumn,o.length>4&&(r.name=m+o[4],m+=o[4])),S.push(r),"number"==typeof r.originalLine&&A.push(r)}g(S,a.compareByGeneratedPositionsDeflated),this.__generatedMappings=S,g(A,a.compareByOriginalPositions),this.__originalMappings=A},o.prototype._findMapping=function(e,n,r,t,o,i){if(e[r]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[r]);if(e[t]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[t]);return u.search(e,n,o,i)},o.prototype.computeColumnSpans=function(){for(var e=0;e=0){var o=this._generatedMappings[r];if(o.generatedLine===n.generatedLine){var i=a.getArg(o,"source",null);null!==i&&(i=this._sources.at(i),null!=this.sourceRoot&&(i=a.join(this.sourceRoot,i)));var s=a.getArg(o,"name",null);return null!==s&&(s=this._names.at(s)),{source:i,line:a.getArg(o,"originalLine",null),column:a.getArg(o,"originalColumn",null),name:s}}}return{source:null,line:null,column:null,name:null}},o.prototype.hasContentsOfAllSources=function(){return this.sourcesContent?this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(e){return null==e}):!1},o.prototype.sourceContentFor=function(e,n){if(!this.sourcesContent)return null;if(null!=this.sourceRoot&&(e=a.relative(this.sourceRoot,e)),this._sources.has(e))return this.sourcesContent[this._sources.indexOf(e)];var r;if(null!=this.sourceRoot&&(r=a.urlParse(this.sourceRoot))){var t=e.replace(/^file:\/\//,"");if("file"==r.scheme&&this._sources.has(t))return this.sourcesContent[this._sources.indexOf(t)];if((!r.path||"/"==r.path)&&this._sources.has("/"+e))return this.sourcesContent[this._sources.indexOf("/"+e)]}if(n)return null;throw new Error('"'+e+'" is not in the SourceMap.')},o.prototype.generatedPositionFor=function(e){var n=a.getArg(e,"source");if(null!=this.sourceRoot&&(n=a.relative(this.sourceRoot,n)),!this._sources.has(n))return{line:null,column:null,lastColumn:null};n=this._sources.indexOf(n);var r={source:n,originalLine:a.getArg(e,"line"),originalColumn:a.getArg(e,"column")},o=this._findMapping(r,this._originalMappings,"originalLine","originalColumn",a.compareByOriginalPositions,a.getArg(e,"bias",t.GREATEST_LOWER_BOUND));if(o>=0){var i=this._originalMappings[o];if(i.source===r.source)return{line:a.getArg(i,"generatedLine",null),column:a.getArg(i,"generatedColumn",null),lastColumn:a.getArg(i,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}},n.BasicSourceMapConsumer=o,s.prototype=Object.create(t.prototype),s.prototype.constructor=t,s.prototype._version=3,Object.defineProperty(s.prototype,"sources",{get:function(){for(var e=[],n=0;n0?t-u>1?r(u,t,o,i,s,a):a==n.LEAST_UPPER_BOUND?t1?r(e,u,o,i,s,a):a==n.LEAST_UPPER_BOUND?u:0>e?-1:e}n.GREATEST_LOWER_BOUND=1,n.LEAST_UPPER_BOUND=2,n.search=function(e,t,o,i){if(0===t.length)return-1;var s=r(-1,t.length,e,t,o,i||n.GREATEST_LOWER_BOUND);if(0>s)return-1;for(;s-1>=0&&0===o(t[s],t[s-1],!0);)--s;return s}},function(e,n){function r(e,n,r){var t=e[n];e[n]=e[r],e[r]=t}function t(e,n){return Math.round(e+Math.random()*(n-e))}function o(e,n,i,s){if(s>i){var a=t(i,s),u=i-1;r(e,a,s);for(var l=e[s],c=i;s>c;c++)n(e[c],l)<=0&&(u+=1,r(e,u,c));r(e,u+1,c);var g=u+1;o(e,n,i,g-1),o(e,n,g+1,s)}}n.quickSort=function(e,n){o(e,n,0,e.length-1)}},function(e,n,r){function t(e,n,r,t,o){this.children=[],this.sourceContents={},this.line=null==e?null:e,this.column=null==n?null:n,this.source=null==r?null:r,this.name=null==o?null:o,this[u]=!0,null!=t&&this.add(t)}var o=r(1).SourceMapGenerator,i=r(4),s=/(\r?\n)/,a=10,u="$$$isSourceNode$$$";t.fromStringWithSourceMap=function(e,n,r){function o(e,n){if(null===e||void 0===e.source)a.add(n);else{var o=r?i.join(r,e.source):e.source;a.add(new t(e.originalLine,e.originalColumn,o,n,e.name))}}var a=new t,u=e.split(s),l=function(){var e=u.shift(),n=u.shift()||"";return e+n},c=1,g=0,p=null;return n.eachMapping(function(e){if(null!==p){if(!(c0&&(p&&o(p,l()),a.add(u.join(""))),n.sources.forEach(function(e){var t=n.sourceContentFor(e);null!=t&&(null!=r&&(e=i.join(r,e)),a.setSourceContent(e,t))}),a},t.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(e){this.add(e)},this);else{if(!e[u]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);e&&this.children.push(e)}return this},t.prototype.prepend=function(e){if(Array.isArray(e))for(var n=e.length-1;n>=0;n--)this.prepend(e[n]);else{if(!e[u]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);this.children.unshift(e)}return this},t.prototype.walk=function(e){for(var n,r=0,t=this.children.length;t>r;r++)n=this.children[r],n[u]?n.walk(e):""!==n&&e(n,{source:this.source,line:this.line,column:this.column,name:this.name})},t.prototype.join=function(e){var n,r,t=this.children.length;if(t>0){for(n=[],r=0;t-1>r;r++)n.push(this.children[r]),n.push(e);n.push(this.children[r]),this.children=n}return this},t.prototype.replaceRight=function(e,n){var r=this.children[this.children.length-1];return r[u]?r.replaceRight(e,n):"string"==typeof r?this.children[this.children.length-1]=r.replace(e,n):this.children.push("".replace(e,n)),this},t.prototype.setSourceContent=function(e,n){this.sourceContents[i.toSetString(e)]=n},t.prototype.walkSourceContents=function(e){for(var n=0,r=this.children.length;r>n;n++)this.children[n][u]&&this.children[n].walkSourceContents(e);for(var t=Object.keys(this.sourceContents),n=0,r=t.length;r>n;n++)e(i.fromSetString(t[n]),this.sourceContents[t[n]])},t.prototype.toString=function(){var e="";return this.walk(function(n){e+=n}),e},t.prototype.toStringWithSourceMap=function(e){var n={code:"",line:1,column:0},r=new o(e),t=!1,i=null,s=null,u=null,l=null;return this.walk(function(e,o){n.code+=e,null!==o.source&&null!==o.line&&null!==o.column?((i!==o.source||s!==o.line||u!==o.column||l!==o.name)&&r.addMapping({source:o.source,original:{line:o.line,column:o.column},generated:{line:n.line,column:n.column},name:o.name}),i=o.source,s=o.line,u=o.column,l=o.name,t=!0):t&&(r.addMapping({generated:{line:n.line,column:n.column}}),i=null,t=!1);for(var c=0,g=e.length;g>c;c++)e.charCodeAt(c)===a?(n.line++,n.column=0,c+1===g?(i=null,t=!1):t&&r.addMapping({source:o.source,original:{line:o.line,column:o.column},generated:{line:n.line,column:n.column},name:o.name})):n.column++}),this.walkSourceContents(function(e,n){r.setSourceContent(e,n)}),{code:n.code,map:r}},n.SourceNode=t}])});
diff --git a/src/browser/scss/_editor.scss b/src/browser/scss/_editor.scss
index 46b79da6..ba0ff990 100644
--- a/src/browser/scss/_editor.scss
+++ b/src/browser/scss/_editor.scss
@@ -71,7 +71,7 @@
border-top:1rem solid var(--color-fg);
border-radius: 0;
-webkit-appearance:none;
- cursor: text;
+ cursor: initial;
}
&.column {
ul {
@@ -165,7 +165,7 @@
position: absolute;
padding:5rem;
right:0;
- top:0;
+ top:1rem;
font-size: 20rem;
pointer-events: none;
}
@@ -268,7 +268,7 @@
width: 15rem;
text-align: center;
}
- &:hover, &:focus {
+ &.focus, &:focus {
> .context-menu {
pointer-events: auto;
opacity: 1;
diff --git a/src/browser/scss/_layout.scss b/src/browser/scss/_layout.scss
index eeec0202..584de27a 100644
--- a/src/browser/scss/_layout.scss
+++ b/src/browser/scss/_layout.scss
@@ -12,6 +12,11 @@ body {
flex-direction: column;
background:var(--color-bg);
padding:2rem;
+ opacity: 0;
+ transition: opacity .1s;
+ &.show {
+ opacity: 1;
+ }
&.sidepanel-open {
right:var(--sidepanel-size);
}
@@ -80,6 +85,7 @@ body {
box-shadow: 0 0 0 1rem var(--color-light) inset;
letter-spacing: 1rem;
font-size: 109%;
+ white-space: pre;
span {
display:block;
width:100%;
@@ -91,6 +97,7 @@ body {
pointer-events: auto;
i {
pointer-events: none;
+ font-size:13rem;
}
}
&.on a, .sidepanel-open {
diff --git a/src/browser/scss/_vars.scss b/src/browser/scss/_vars.scss
index 991cd749..a95f1dea 100644
--- a/src/browser/scss/_vars.scss
+++ b/src/browser/scss/_vars.scss
@@ -1,25 +1,30 @@
+
+$base: rgb(25, 31, 42);
+$accent: rgb(82, 168, 255);
+$tone: rgb(104, 174, 245);
+$text: white;
+
:root {
////////////////////// COLOR SCHEME
- --color-text:rgba(255, 255, 255, .6);
- --color-text-fade:rgba(255, 255, 255, .4);
+ --color-text: transparentize($text, .4);
+ --color-text-fade: transparentize($text, .6);
- --color-accent:rgba(82, 168, 255, 1);
- --color-grid: rgba(82, 168, 255, .1);
+ --color-accent: $accent;
+ --color-grid: transparentize($accent, 0.90);
- --color-bg: rgb(25, 31, 42);
- --color-track: rgb(32, 41, 58);
- --color-fg: rgb(40, 49, 67);
- --color-raised: rgb(49, 63, 85);
-
- --color-light:rgba(255, 255, 255, .06);
+ --color-bg: $base;
+ --color-track: desaturate(mix($base, $tone, 95), 2);
+ --color-fg: desaturate(mix($base, $tone, 88), 5);
+ --color-raised: desaturate(mix($base, $tone, 75), 5);
+ --color-light: desaturate(transparentize($tone, 0.90), 50);
--color-white: white;
////////////////////// AUTO
- --color-custom:var(--color-accent);
+ --color-custom: var(--color-accent);
////////////////////// MISC
diff --git a/src/browser/scss/_widgets.scss b/src/browser/scss/_widgets.scss
index c0906e63..898e41dc 100644
--- a/src/browser/scss/_widgets.scss
+++ b/src/browser/scss/_widgets.scss
@@ -53,7 +53,9 @@
width: 100%;
flex-shrink: 0;
display: flex;
- justify-content: space-around;
+ justify-content: center;
+ white-space: pre;
+ // justify-content: space-around;
align-items: center;
&.accent {
color:var(--color-accent);
@@ -61,6 +63,25 @@
}
}
+.glass-effect {
+ position: relative;
+ &:after {
+ content:"";
+ position: absolute;
+ pointer-events: none;
+ top:0;
+ left:0;
+ right:0;
+ bottom:0;
+ background: radial-gradient(ellipse farthest-side at center top, var(--color-custom), var(--color-track));
+ background-size: 150% 150%;
+ background-repeat: no-repeat;
+ background-position: center top;
+ opacity: .15;
+ z-index: 3;
+ }
+}
+
@import 'widgets/fader';
@import 'widgets/knob';
diff --git a/src/browser/scss/style.scss b/src/browser/scss/style.scss
index b96a3287..232cd72b 100644
--- a/src/browser/scss/style.scss
+++ b/src/browser/scss/style.scss
@@ -22,7 +22,9 @@ input {
-
+.fa {
+ font-weight: 900;
+}
html, body {
height:100%;
@@ -111,8 +113,8 @@ body {
display: flex;
flex-direction: column;
opacity: 0;
- transition: opacity .25s;
- &.loaded {
+ transition: opacity .1s;
+ &.show {
opacity: 1;
overflow: auto;
}
@@ -133,8 +135,8 @@ body {
left:0;
bottom:0;
right:0;
- border:1rem solid var(--color-accent);
- opacity: 0.3;
+ background: var(--color-accent);
+ opacity: 0.1;
}
}
}
@@ -167,8 +169,8 @@ body {
left:0;
bottom:0;
right:0;
- border:1rem solid var(--color-accent);
- opacity: 0.3;
+ background: var(--color-accent);
+ opacity: 0.1;
}
}
}
@@ -183,7 +185,9 @@ body {
text-overflow: ellipsis;
background: none;
border-bottom:1rem solid var(--color-bg);
-
+ em {
+ pointer-events: none;
+ }
&:last-child {
border-bottom:0;
}
@@ -197,6 +201,9 @@ body {
&:hover {
color:var(--color-accent);
}
+ i {
+ pointer-events: none;
+ }
}
}
}
@@ -480,11 +487,13 @@ body {
right:0;
bottom:0;
padding:10%;
- display: flex;
align-items: center;
z-index:1000000;
transform: translate3d(0,0,0);
-
+ display: none;
+ &.show {
+ display: flex;
+ }
&:before {
content: "";
position: absolute;
diff --git a/src/browser/scss/widgets/_fader.scss b/src/browser/scss/widgets/_fader.scss
index fb5568ff..082ee1f5 100644
--- a/src/browser/scss/widgets/_fader.scss
+++ b/src/browser/scss/widgets/_fader.scss
@@ -335,9 +335,9 @@
&:not(.horizontal) {
.input {
height: 100rem;
- width: 24rem;
+ width: 100rem;
margin-top: -50rem;
- margin-left: calc(-1 * 12rem + var(--input-margin));
+ margin-left: calc(-1 * 50rem + var(--input-margin));
z-index: 3;
input {
transform: rotate(-90deg);
@@ -347,7 +347,7 @@
&.align-right {
.input {
- margin-left: calc(-1 * 12rem - var(--input-margin));
+ margin-left: calc(-1 * 50rem - var(--input-margin));
}
}
@@ -364,3 +364,137 @@
}
+
+
+.range-container {
+ width:100rem;
+ height:300rem;
+ &.horizontal {
+ height:130rem;
+ width:300rem
+ }
+ padding: 1rem;
+ --color-pips: var(--color-custom);
+ --color-gauge: var(--color-custom);
+ --color-knob: var(--color-custom);
+ .range {
+ height:100%;
+ overflow: hidden;
+ display: flex;
+ position: relative;
+ flex-direction: column;
+ flex: 1;
+ > .input {
+ height: 25rem;
+ flex:initial!important;
+ flex-shrink: 0!important;
+ // display: block;
+ background: transparent!important;
+ border: 0!important;
+ }
+ > .wrapper {
+ overflow: hidden;
+ flex: 1 1 100%;
+ max-height: 100%;
+ width: 100%;
+ position: relative;
+ display: flex;
+ justify-content: center;
+ border-radius: inherit;
+ .fader {
+ position: absolute;
+ top:0;
+ left:0;
+ right:0;
+ bottom:0;
+ pointer-events: none;
+ .wrapper {
+ // border: 0;
+ }
+ &:first-child {
+ opacity: 0;
+ }
+ }
+ }
+ &.compact {
+ > canvas {
+ background: var(--color-track);
+ }
+ }
+
+
+
+ &.compact {
+
+ --input-margin:0rem;
+ &.has-meter {
+ --input-margin:-3rem;
+ }
+ &.has-pips {
+ --input-margin:-1rem;
+ }
+ &.has-meter.has-pips {
+ --input-margin:-4rem;
+ }
+
+ .input {
+ pointer-events: none;
+ position: absolute;
+ border:0;
+ background:transparent;
+ overflow: hidden;
+ position: absolute;
+ top:50%;
+ left:50%;
+ z-index: 1;
+ }
+
+ &.horizontal {
+
+ .input {
+ width: 100rem;
+ height: 24rem;
+ margin-left: -50rem;
+ margin-top: calc(-1 * 12rem + var(--input-margin));
+ }
+
+ }
+
+ &:not(.horizontal) {
+ .input {
+ height: 100rem;
+ width: 100rem;
+ margin-top: -50rem;
+ margin-left: calc(-1 * 50rem + var(--input-margin));
+ z-index: 3;
+ input {
+ transform: rotate(-90deg);
+ width: 100rem;
+ }
+ }
+
+ &.align-right {
+ .input {
+ margin-left: calc(-1 * 50rem - var(--input-margin));
+ }
+ }
+ }
+
+ }
+
+ }
+}
+
+.panel:not(.tab) > .range-container {
+ padding: 0rem;
+ --color-border:transparent;
+ .fader.compact {
+ padding: 1rem;
+ }
+ .fader.compact > .wrapper {
+ box-shadow: 0 0 0 1rem var(--color-fg);
+
+ outline: 1rem solid var(--color-light);
+ border: 1rem solid var(--color-bg);
+ }
+}
diff --git a/src/browser/scss/widgets/_inputs.scss b/src/browser/scss/widgets/_inputs.scss
index f4093822..e873af3c 100644
--- a/src/browser/scss/widgets/_inputs.scss
+++ b/src/browser/scss/widgets/_inputs.scss
@@ -2,8 +2,18 @@
width: 100rem;
height: 60rem;
padding:1rem;
- .input {
-
+ .vertical {
+ position: relative;
+ input {
+ transform: rotate(-90deg);
+ vertical-align: middle;
+ max-width: initial!important;
+ position: absolute;
+ top: 50%;
+ left: 50%;
+ transform: translateX(-50%) translateY(-50%) rotate(-90deg);
+ margin-top: -1px
+ }
}
}
.widget {
@@ -17,8 +27,6 @@
padding:1rem;
border: 1rem solid var(--color-bg);
background: var(--color-track);
- font-size: 109%;
-
input {
display: block;
flex:1;
@@ -31,6 +39,7 @@
border-radius: inherit;
-webkit-appearance:none;
text-align:inherit;
+ line-height: 50rem;
vertical-align: top;
letter-spacing: 1rem;
&:focus {
@@ -60,3 +69,43 @@
border: 1rem solid var(--color-bg);
}
}
+
+
+.keys-container {
+ width: 100rem;
+ height:60rem;
+ flex-shrink: 0;
+ padding:1rem;
+ --opacity: .75;
+ .keys {
+ flex: 1 1 100%;
+ height:35rem;
+ padding: 10rem;
+ justify-content: center;
+ display: flex;
+ align-items: center;
+ background: var(--color-track);
+ color:var(--color-custom);
+ border: 1rem solid var(--color-bg);
+ @extend .glass-effect;
+ i {
+ opacity: var(--opacity);
+ }
+ span {
+ font-family: monospace;
+ letter-spacing: 0;
+ margin-left: 4rem;
+ }
+ }
+}
+
+.panel:not(.tab) > .keys-container {
+ --color-border:transparent;
+ padding: 0rem;
+ .keys {
+ margin: 1rem;
+ box-shadow: 0 0 0 1rem var(--color-fg);
+ outline:1rem solid var(--color-light);
+ border: 1rem solid var(--color-bg);
+ }
+}
diff --git a/src/browser/scss/widgets/_knob.scss b/src/browser/scss/widgets/_knob.scss
index c35da1d0..0f28ec69 100644
--- a/src/browser/scss/widgets/_knob.scss
+++ b/src/browser/scss/widgets/_knob.scss
@@ -87,5 +87,12 @@
.drag-knob {
opacity: 0;
+
+ // safari fix
+ position: absolute;
+ top:0;
+ bottom:0;
+ left:0;
+ right:0;
}
}
diff --git a/src/browser/scss/widgets/_maths.scss b/src/browser/scss/widgets/_maths.scss
index e0b04951..3b84318d 100644
--- a/src/browser/scss/widgets/_maths.scss
+++ b/src/browser/scss/widgets/_maths.scss
@@ -7,6 +7,7 @@
height:100%;
background: var(--color-track);
border:1rem solid var(--color-bg);
+ @extend .glass-effect;
.input {
background: transparent!important;
border: 0!important;
diff --git a/src/browser/scss/widgets/_pads.scss b/src/browser/scss/widgets/_pads.scss
index f0509f3d..d3021b34 100644
--- a/src/browser/scss/widgets/_pads.scss
+++ b/src/browser/scss/widgets/_pads.scss
@@ -28,7 +28,7 @@
background:var(--color-track);
border: 1rem solid var(--color-bg);
touch-action: none;
-
+
> canvas {
width:100%;
height:100%;
@@ -157,17 +157,7 @@
top:0;
left:0;
}
- .handle {
- position: absolute;
- top: 0;
- left: 0;
- right: 0;
- bottom:0;
- z-index: 1;
- &.active {
- pointer-events: none;
- }
- }
+
> .pad {
pointer-events: none;
position: absolute;
diff --git a/src/browser/scss/widgets/_panel.scss b/src/browser/scss/widgets/_panel.scss
index bffd4914..5456edb4 100644
--- a/src/browser/scss/widgets/_panel.scss
+++ b/src/browser/scss/widgets/_panel.scss
@@ -270,6 +270,13 @@
}
}
+.tab-container {
+ display: none;
+ &.show {
+ display: flex;
+ }
+}
+
.clone-container {
width: 100rem;
height: 100rem;
diff --git a/src/browser/scss/widgets/_plots.scss b/src/browser/scss/widgets/_plots.scss
index 8dd7d109..08a9ddf8 100644
--- a/src/browser/scss/widgets/_plots.scss
+++ b/src/browser/scss/widgets/_plots.scss
@@ -3,20 +3,24 @@
height:100rem;
padding:1rem;
.led {
+ --opacity: 0;
+ --color-led: var(--color-custom);
display: flex;
flex-direction: row;
flex: 1 1 100%;
background: var(--color-track);
border:1rem solid var(--color-bg);
- --opacity: 0;
- &:after {
+ &:before {
content:"";
width:100%;
height: 100%;
- background: var(--color-custom);
+ background: var(--color-led);
border-radius: inherit;
opacity: var(--opacity);
+ box-shadow: inset 0 0 10rem var(--color-track);
}
+ @extend .glass-effect;
+
}
}
@@ -32,9 +36,9 @@
display: flex;
flex-direction: row;
flex: 1 1 100%;
- position: relative;
background: var(--color-track);
border:1rem solid var(--color-bg);
+ @extend .glass-effect;
}
canvas {
flex:1;
@@ -49,6 +53,7 @@
--color-knob: transparent;
.wrapper {
pointer-events: none;
+ @extend .glass-effect;
}
}
@@ -64,6 +69,7 @@
justify-content: center;
display: flex;
align-items: center;
+ white-space: pre;
background: var(--color-track);
color:var(--color-custom);
border: 1rem solid var(--color-bg);
@@ -73,6 +79,37 @@
overflow: hidden;
-webkit-writing-mode:vertical-lr;
writing-mode:vertical-lr;
+ &:after {
+ transform: rotate(-180deg);
+ }
+ }
+ @extend .glass-effect;
+ }
+}
+
+.image-container {
+ width:100rem;
+ height:100rem;
+ padding:1rem;
+ .image {
+ display: flex;
+ flex-direction: row;
+ flex: 1 1 100%;
+ background-size:cover;
+ border:1rem solid var(--color-bg);
+ background-repeat: no-repeat;
+ }
+ &.noborder {
+ --color-border:transparent;
+ --color-light:transparent;
+ --color-light:transparent;
+ background: transparent;
+ padding: 0!important;
+ .image {
+ outline:transparent!important;
+ border:0!important;
+ box-shadow:none!important;
+ margin: 0!important;
}
}
}
@@ -82,10 +119,11 @@
.panel:not(.tab) > .text-container,
.panel:not(.tab) > .visualizer-container,
.panel:not(.tab) > .eq-container,
-.panel:not(.tab) > .plot-container {
+.panel:not(.tab) > .plot-container,
+.panel:not(.tab) > .image-container {
--color-border:transparent;
padding: 0rem;
- .plot, .text, .led {
+ .plot, .text, .led, .image {
padding: 0rem;
margin: 1rem;
background-clip: content-box;
diff --git a/src/browser/scss/widgets/_push.scss b/src/browser/scss/widgets/_push.scss
index 9dc1cb3c..aaf10365 100644
--- a/src/browser/scss/widgets/_push.scss
+++ b/src/browser/scss/widgets/_push.scss
@@ -11,7 +11,9 @@
right: 0;
bottom: 0;
opacity: 0.4;
- background: radial-gradient( ellipse at center, transparent, var(--color-bg));
+ background: radial-gradient( ellipse at center, var(--color-raised), var(--color-bg)),
+ ;
+ z-index: 2;
}
}
&.on:not(.active) {
diff --git a/src/browser/scss/widgets/_switch.scss b/src/browser/scss/widgets/_switch.scss
index 70c8a43c..8d635356 100644
--- a/src/browser/scss/widgets/_switch.scss
+++ b/src/browser/scss/widgets/_switch.scss
@@ -199,6 +199,13 @@
line-height: 120%!important;
text-transform: none;
border-radius: inherit;
+
+ &:focus {
+ box-shadow: 0 0 0 1rem var(--color-light) inset,
+ 0 1rem 0 0 var(--color-light) inset,
+ 0 0 1rem 0 var(--color-custom) inset;
+
+ }
}
&:after{
content:"\f107";
@@ -207,7 +214,7 @@
padding:0 10rem;
right:0;
top:50%;
- margin-top:-11rem;
+ margin-top:-10rem;
font-size: 180%;
height: 20rem;
line-height: 20rem;