Compare commits

...

62 Commits

Author SHA1 Message Date
Jeffrey Warren
8574275e53 Merge branch 'main' into update-gh-pages-script 2020-10-28 16:35:38 -04:00
dependabot-preview[bot]
5408467800 Bump jsdom from 16.3.0 to 16.4.0 (#1735)
Bumps [jsdom](https://github.com/jsdom/jsdom) from 16.3.0 to 16.4.0.
- [Release notes](https://github.com/jsdom/jsdom/releases)
- [Changelog](https://github.com/jsdom/jsdom/blob/master/Changelog.md)
- [Commits](https://github.com/jsdom/jsdom/compare/16.3.0...16.4.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-28 16:35:29 -04:00
Jeffrey Warren
578a12ef9a Merge branch 'main' into update-gh-pages-script 2020-10-28 16:27:39 -04:00
Jeffrey Warren
30c3fba933 Update and rename .github/ISSUE_TEMPLATE.md to .github/ISSUE_TEMPLATE/bug_report.md 2020-10-28 16:23:03 -04:00
Jeffrey Warren
cfd3750b68 Update release_workflow.md 2020-10-28 16:20:00 -04:00
Jeffrey Warren
fadaebcdb6 Update release_workflow.md 2020-10-28 16:18:45 -04:00
Jeffrey Warren
10f2739435 Create release_workflow.md 2020-10-28 16:16:34 -04:00
Harsh Khandeparkar
5d87d6c67f Merge branch 'main' into update-gh-pages-script 2020-10-27 22:07:07 +05:30
Jeffrey Warren
3caa033c8f Update demo.css to fix font links to League Spartan CDN via fontsource - (#1741)
https://cdn.jsdelivr.net/npm/fontsource-league-spartan@3.0.5/files/
2020-10-27 11:05:18 -04:00
HarshKhandeparkar
4438c3ebab docs<CONTRIBUTING>: document the scripts 2020-10-26 12:13:03 +05:30
HarshKhandeparkar
6157055b15 feat: completely refactor the script 2020-10-26 11:47:41 +05:30
HarshKhandeparkar
ba39d2e9bc fix: option to choose upstream branch 2020-10-24 00:45:57 +05:30
HarshKhandeparkar
e67d839be5 fix: add scripts/ to CODEOWNERS file 2020-10-24 00:43:45 +05:30
HarshKhandeparkar
afe4bf31d2 fix: make script executable 2020-10-24 00:42:33 +05:30
Harsh Khandeparkar
56be8779e0 fix: pull from stable branch instead of main 2020-10-23 22:33:23 +05:30
Harsh Khandeparkar
277aa51f26 Create update-gh-pages 2020-10-23 22:28:29 +05:30
Harsh Khandeparkar
14f13c300b fix: bump lockfile and sw.js versions (#1734) 2020-10-22 10:13:35 -04:00
Jeffrey Warren
a2d654321d Bump to v3.6.0 for new npm release (#1695)
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
2020-10-18 16:13:10 -04:00
dependabot-preview[bot]
ad2f63ce4f Bump jasmine-core from 3.5.0 to 3.6.0 (#1730)
Bumps [jasmine-core](https://github.com/jasmine/jasmine) from 3.5.0 to 3.6.0.
- [Release notes](https://github.com/jasmine/jasmine/releases)
- [Changelog](https://github.com/jasmine/jasmine/blob/main/RELEASE.md)
- [Commits](https://github.com/jasmine/jasmine/compare/v3.5.0...v3.6.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-18 15:54:08 -04:00
dependabot-preview[bot]
82601ecbea Bump gpu.js from 2.9.5 to 2.10.4 (#1731)
Bumps [gpu.js](https://github.com/gpujs/gpu.js) from 2.9.5 to 2.10.4.
- [Release notes](https://github.com/gpujs/gpu.js/releases)
- [Commits](https://github.com/gpujs/gpu.js/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-18 11:16:03 -04:00
dependabot-preview[bot]
c750958add Bump lint-staged from 10.2.11 to 10.4.2 (#1732)
Bumps [lint-staged](https://github.com/okonet/lint-staged) from 10.2.11 to 10.4.2.
- [Release notes](https://github.com/okonet/lint-staged/releases)
- [Commits](https://github.com/okonet/lint-staged/compare/v10.2.11...v10.4.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-10-17 17:57:38 -04:00
Harsh Khandeparkar
e1c8a5f218 Edge Detect Horizontal Edges Got Fixed (#1696)
* fix: edge detect horizontal angle fixed

* test: fix edge detect tests

Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-17 11:46:58 -04:00
Adam G
8c461bbeee Make the site responsive (#1382)
* Removed line 47 & 68, added line 154

* Line 61 removed inline styles from header

Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-17 11:34:18 -04:00
dependabot-preview[bot]
11478ce421 Bump lodash from 4.17.19 to 4.17.20 (#1720)
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.19 to 4.17.20.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.19...4.17.20)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
2020-10-17 11:16:52 -04:00
dependabot-preview[bot]
fa02c9f1c4 Bump jsqr from 1.2.0 to 1.3.1
Bumps [jsqr](https://github.com/cozmo/jsQR) from 1.2.0 to 1.3.1.
- [Release notes](https://github.com/cozmo/jsQR/releases)
- [Commits](https://github.com/cozmo/jsQR/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-10-17 06:51:12 +00:00
Shazeb Ata
f4baebd7c7 Change dimension upon loading through camera (#1456)
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-16 16:56:40 -04:00
dependabot-preview[bot]
d0172f91ff Bump @babel/plugin-proposal-object-rest-spread from 7.11.0 to 7.12.1 (#1726)
Bumps [@babel/plugin-proposal-object-rest-spread](https://github.com/babel/babel/tree/HEAD/packages/babel-plugin-proposal-object-rest-spread) from 7.11.0 to 7.12.1.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.12.1/packages/babel-plugin-proposal-object-rest-spread)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-10-16 11:16:42 -04:00
Shazeb Ata
c0cf8798a7 Hide ui on each draw (#1559)
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
2020-10-16 10:24:57 +05:30
Rishabh Shukla
d33afe09da refactored resize (#1562)
Co-authored-by: h <f>
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-16 10:04:59 +05:30
Akshay Gupta
1713751728 Colorbar module default overlay shift fixed (#1542)
* Fixes #1538

* Fixes #1538

Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
2020-10-16 09:48:55 +05:30
Harsh Khandeparkar
a7993d5f7b Text Overlay Works (#1561)
Co-authored-by: Rishabh Shukla <42492389+blurry-x-face@users.noreply.github.com>
2020-10-16 08:55:11 +05:30
Mansi Sharma
31eaba8912 Updated config.yml according to plots2 file (#1566)
* Updated config.yml according to plots2 file

* Corrected according to suggestions

* minor change

* minor change

* minor change

* minor change

* minor change

* minor changes

Co-authored-by: sharmamansi <mansisharma785622gmail.com>
Co-authored-by: Rishabh Shukla <42492389+blurry-x-face@users.noreply.github.com>
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
2020-10-16 01:20:53 +05:30
Naimish Rastogi
c372b7d950 VersionText color change (#1567)
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-15 11:19:23 -04:00
dependabot-preview[bot]
765dbc5c9c Bump jasmine from 3.5.0 to 3.6.1 (#1723)
Bumps [jasmine](https://github.com/jasmine/jasmine-npm) from 3.5.0 to 3.6.1.
- [Release notes](https://github.com/jasmine/jasmine-npm/releases)
- [Commits](https://github.com/jasmine/jasmine-npm/compare/v3.5.0...v3.6.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-10-15 07:42:48 -04:00
Harsh Khandeparkar
8e3abcccd6 Create CODEOWNERS (#1719)
* Create CODEOWNERS

* Update .github/CODEOWNERS

Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>

* Update .github/CODEOWNERS

Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>

* Update .github/CODEOWNERS

Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>

Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-14 19:47:56 -04:00
dependabot-preview[bot]
68a0995997 Bump @babel/core from 7.9.0 to 7.12.0 (#1721)
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.9.0 to 7.12.0.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.12.0/packages/babel-core)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-14 19:05:04 -04:00
Jeffrey Warren
47fd8fe6db bump tape-run to ^8.0.0 (#1722) 2020-10-14 18:42:40 -04:00
dependabot-preview[bot]
2914aaef70 Bump jpegtran-bin from 4.0.0 to 5.0.2 (#1699)
Bumps [jpegtran-bin](https://github.com/imagemin/jpegtran-bin) from 4.0.0 to 5.0.2.
- [Release notes](https://github.com/imagemin/jpegtran-bin/releases)
- [Commits](https://github.com/imagemin/jpegtran-bin/compare/v4.0.0...v5.0.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-14 16:09:50 -04:00
dependabot-preview[bot]
e2dd5a7309 Bump imagemin-pngquant from 8.0.0 to 9.0.1 (#1715)
Bumps [imagemin-pngquant](https://github.com/imagemin/imagemin-pngquant) from 8.0.0 to 9.0.1.
- [Release notes](https://github.com/imagemin/imagemin-pngquant/releases)
- [Commits](https://github.com/imagemin/imagemin-pngquant/compare/v8.0.0...v9.0.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-10-14 16:02:20 -04:00
dependabot-preview[bot]
eb497e1a62 [Security] Bump bl from 1.2.2 to 1.2.3
Bumps [bl](https://github.com/rvagg/bl) from 1.2.2 to 1.2.3. **This update includes a security fix.**
- [Release notes](https://github.com/rvagg/bl/releases)
- [Commits](https://github.com/rvagg/bl/compare/v1.2.2...v1.2.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-10-06 15:55:34 +00:00
bajajvinamr
8a929c4b4d Update defaultHtmlSequencerUi.js (#1712)
Fixed Module Selector dropdown showing error in console publiclab#1531

Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-10-01 16:29:40 -04:00
Jeffrey Warren
b95af7672c Update README.md 2020-10-01 12:57:54 -04:00
dependabot-preview[bot]
eb5672c433 [Security] Bump decompress from 4.2.0 to 4.2.1
Bumps [decompress](https://github.com/kevva/decompress) from 4.2.0 to 4.2.1. **This update includes a security fix.**
- [Release notes](https://github.com/kevva/decompress/releases)
- [Commits](https://github.com/kevva/decompress/compare/v4.2.0...v4.2.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-09-21 21:51:45 +00:00
dependabot-preview[bot]
c0b9f88818 Bump lint-staged from 10.1.3 to 10.2.11
Bumps [lint-staged](https://github.com/okonet/lint-staged) from 10.1.3 to 10.2.11.
- [Release notes](https://github.com/okonet/lint-staged/releases)
- [Commits](https://github.com/okonet/lint-staged/compare/v10.1.3...v10.2.11)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-08-05 23:31:58 +00:00
dependabot-preview[bot]
4810a3b975 Bump gpu.js from 2.9.4 to 2.9.5
Bumps [gpu.js](https://github.com/gpujs/gpu.js) from 2.9.4 to 2.9.5.
- [Release notes](https://github.com/gpujs/gpu.js/releases)
- [Commits](https://github.com/gpujs/gpu.js/commits/2.9.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-08-04 15:51:26 +00:00
dependabot-preview[bot]
07c6d1497a Bump lodash from 4.17.15 to 4.17.19 (#1697)
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.15...4.17.19)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-08-04 11:15:24 -04:00
dependabot-preview[bot]
8ddf05f0bc Bump @babel/plugin-proposal-object-rest-spread from 7.8.3 to 7.11.0
Bumps [@babel/plugin-proposal-object-rest-spread](https://github.com/babel/babel/tree/HEAD/packages/babel-plugin-proposal-object-rest-spread) from 7.8.3 to 7.11.0.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.11.0/packages/babel-plugin-proposal-object-rest-spread)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-08-04 03:19:53 +00:00
dependabot-preview[bot]
456a22a845 [Security] Bump elliptic from 6.4.1 to 6.5.3
Bumps [elliptic](https://github.com/indutny/elliptic) from 6.4.1 to 6.5.3. **This update includes a security fix.**
- [Release notes](https://github.com/indutny/elliptic/releases)
- [Commits](https://github.com/indutny/elliptic/compare/v6.4.1...v6.5.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-08-04 03:12:35 +00:00
dependabot-preview[bot]
740693b655 Bump geotiff from 1.0.0-beta.6 to 1.0.0-beta.13 (#1677)
Bumps [geotiff](https://github.com/geotiffjs/geotiff.js) from 1.0.0-beta.6 to 1.0.0-beta.13.
- [Release notes](https://github.com/geotiffjs/geotiff.js/releases)
- [Commits](https://github.com/geotiffjs/geotiff.js/compare/v1.0.0-beta.6...v1.0.0-beta.13)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-07-12 16:14:07 -04:00
Shazeb Ata
23ddf1fce0 Added test for Apply button (#1579)
* Added test for Apply button

* Refactored

Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-07-12 16:03:10 -04:00
Jeffrey Warren
b7eb9cfc45 update gitpod badge URL due to referrer issues
https://github.com/gitpod-io/gitpod/issues/688
2020-07-11 13:26:59 -04:00
Yogesh Sharma
da9b167258 Updated Link (#1627)
Co-authored-by: Rishabh Shukla <42492389+blurry-x-face@users.noreply.github.com>
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-07-11 10:56:39 -04:00
dependabot-preview[bot]
3b6eac4a96 Bump gpu.js from 2.9.3 to 2.9.4
Bumps [gpu.js](https://github.com/gpujs/gpu.js) from 2.9.3 to 2.9.4.
- [Release notes](https://github.com/gpujs/gpu.js/releases)
- [Commits](https://github.com/gpujs/gpu.js/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-07-10 21:45:20 +00:00
dependabot-preview[bot]
8367f4bc26 Bump jsdom from 15.2.1 to 16.3.0 (#1691)
Bumps [jsdom](https://github.com/jsdom/jsdom) from 15.2.1 to 16.3.0.
- [Release notes](https://github.com/jsdom/jsdom/releases)
- [Changelog](https://github.com/jsdom/jsdom/blob/master/Changelog.md)
- [Commits](https://github.com/jsdom/jsdom/compare/15.2.1...16.3.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-07-10 14:50:53 -04:00
dependabot-preview[bot]
a5abbeaf76 Bump imagemin-jpegtran from 6.0.0 to 7.0.0
Bumps [imagemin-jpegtran](https://github.com/imagemin/imagemin-jpegtran) from 6.0.0 to 7.0.0.
- [Release notes](https://github.com/imagemin/imagemin-jpegtran/releases)
- [Commits](https://github.com/imagemin/imagemin-jpegtran/compare/v6.0.0...v7.0.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-07-07 21:23:59 +00:00
Jeffrey Warren
d55752827d Update .travis.yml 2020-07-07 18:58:58 +00:00
dependabot-preview[bot]
1658220198 Bump jest from 25.1.0 to 26.1.0
Bumps [jest](https://github.com/facebook/jest) from 25.1.0 to 26.1.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v25.1.0...v26.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-07-07 18:58:58 +00:00
Jeffrey Warren
54722a35f7 Update README.md (#1688) 2020-07-07 14:43:59 -04:00
Harsh Khandeparkar
eb381555c4 Edge Detect Fixed! (#1629)
* FIX!

* fix the test

* trigger travis

Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
2020-07-07 11:52:12 -04:00
Jeffrey Warren
917979267a Update .gitpod.yml to include gitpod dependencies in a mini dockerfile (#1685)
* Update .gitpod.yml

* Create .gitpod.dockerfile

* Update .gitpod.dockerfile

* Update .gitpod.dockerfile

* Update .gitpod.dockerfile

* Update .gitpod.dockerfile
2020-07-07 10:15:25 -04:00
dependabot-preview[bot]
fb303a8ca9 [Security] Bump websocket-extensions from 0.1.3 to 0.1.4 (#1671)
Bumps [websocket-extensions](https://github.com/faye/websocket-extensions-node) from 0.1.3 to 0.1.4. **This update includes a security fix.**
- [Release notes](https://github.com/faye/websocket-extensions-node/releases)
- [Changelog](https://github.com/faye/websocket-extensions-node/blob/master/CHANGELOG.md)
- [Commits](https://github.com/faye/websocket-extensions-node/compare/0.1.3...0.1.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-07-07 00:20:51 -04:00
Jeffrey Warren
102b82bd34 Split tests into separate Travis jobs with better labeling (#1684)
* Split tests into separate Travis jobs with better labeling

* format test browserification

* more descriptive labels

* combine grunt browserify of tests and the run of those tests
2020-07-07 00:03:02 -04:00
29 changed files with 5681 additions and 3445 deletions

75
.github/CODEOWNERS vendored Normal file
View File

@@ -0,0 +1,75 @@
# <-- DOCS FOR THIS FILE -->
# This is a comment.
# Each line is a file pattern followed by one or more owners.
# These owners will be the default owners for everything in
# the repo. Unless a later match takes precedence,
# @global-owner1 and @global-owner2 will be requested for
# review when someone opens a pull request.
# * @global-owner1 @global-owner2
# Order is important; the last matching pattern takes the most
# precedence. When someone opens a pull request that only
# modifies JS files, only @js-owner and not the global
# owner(s) will be requested for a review.
# *.js @js-owner
# You can also use email addresses if you prefer. They'll be
# used to look up users just like we do for commit author
# emails.
# *.go docs@example.com
# In this example, @doctocat owns any files in the build/logs
# directory at the root of the repository and any of its
# subdirectories.
# /build/logs/ @doctocat
# The `docs/*` pattern will match files like
# `docs/getting-started.md` but not further nested files like
# `docs/build-app/troubleshooting.md`.
# docs/* docs@example.com
# In this example, @octocat owns any file in an apps directory
# anywhere in your repository.
# apps/ @octocat
# In this example, @doctocat owns any file in the `/docs`
# directory in the root of your repository.
# /docs/ @doctocat
# <-- /DOCS FOR THIS FILE -->
# <-- COMMON TO ALL MAINTAINERS -->
/*.json @publiclab/is-maintainers
/*.md @publiclab/is-maintainers
/*.lock @ubliclab/is-maintainers
/Gruntfile.js @publiclab/is-maintainers
/.github/ @publiclab/is-maintainers
/scripts/ @publiclab/is-maintainers
# <-- /COMMON TO ALL MAINTAINERS -->
# <-- SPECIFIC MAINTAINERS -->
/index.js @publiclab/is-cli-maintainers
/src/cli/ @publiclab/is-cli-maintainers
/src/CliUtils.js @publiclab/is-cli-maintainers
/src/*.js @publiclab/is-core-maintainers
/src/*.json @publiclab/is-core-maintainers
/src/util/ @publiclab/is-core-maintainers
/test/core/* @publiclab/is-core-maintainers
/src/modules/ @publiclab/is-module-maintainers
/docs/ @publiclab/is-module-maintainers
/test/ @publiclab/is-tests-maintainers
/jest* @publiclab/is-tests-maintainers
/eslint* @publiclab/is-tests-maintainers
/travis* @publiclab/is-tests-maintainers
.travis.yml @publiclab/is-tests-maintainers
.gitpod* @publiclab/is-tests-maintainers
/gitpod* @publiclab/is-tests-maintainers
/examples/ @publiclab/is-ui-maintainers
/icons/ @publiclab/is-ui-maintainers
/test/ui-2/test/* @publiclab/is-ui-maintainers
/test/ui/spec/* @publiclab/is-ui-maintainers
# <-- /SPECIFIC MAINTAINERS -->

View File

@@ -1,3 +1,10 @@
---
name: Bug report 🐞
about: Help us identify and fix a bug!
title: ''
labels: bug
---
### Please describe the problem (or idea)
> What happened just before the problem occurred? Or what problem could this idea solve?
@@ -10,13 +17,13 @@
### Please show us where to look
https://beta.sequencer.publiclab.org
Paste in a full URL, starting with:
> https://beta.sequencer.publiclab.org/
### What's your PublicLab.org username?
> This can help us diagnose the issue:
If you can share a screenshot or a GIF that is EXTRA helpful! 💖
If you can see a version number in the upper right, please note that!
### Browser, version, and operating system

View File

@@ -0,0 +1,32 @@
---
name: New release checklist ✅
about: Coordinate steps to publish a new release
title: 'Checklist and coordination for v0.0.0 major/minor/patch release'
labels: release
assignees: '@publiclab/is-maintainers'
---
This template guides us through the steps of creating a new release, based on [conversation and testing in https://github.com/publiclab/image-sequencer/issues/1692.
Discuss with @publiclab/is-maintainers if anything is ambiguous!
* [x] open an issue using the "release" template with this checklist with title `Checklist and coordination for v0.0.0 major/minor/patch release` (see [semantic versioning](https://docs.npmjs.com/about-semantic-versioning/))
* [ ] compile release notes below from corresponding [release milestone](https://github.com/publiclab/image-sequencer/milestones)
* [ ] update version number in `examples/sw.js` (ex #1734) and `package.json` (ex #1695)
* [ ] finalize and merge to `main` branch (freeze merges to `main` branch until next step)
* [ ] merge, build and publish `/dist/` files to `stable` (merges to `main` branch can resume for next release)
* [ ] create a release on GitHub and use features description + release notes from below
* [ ] tag version number branch (i.e. `v0.0.0`)
* [ ] publish tagged branch to `npm`
* [ ] publish to live `github-pages` demo (with [bash script](https://github.com/publiclab/image-sequencer/pull/1703) from `/scripts/update_demo`) (from within GitPod works well)
* [ ] move anything necessary to next release project, i.e. https://github.com/publiclab/image-sequencer/projects/4
* [ ] close this issue!
Noting we're now in this process in https://github.com/publiclab/image-sequencer/pull/1695 for `v3.6.0`.
****
### Release notes
Compile and edit release notes below, to be copied into the release description.

17
.github/config.yml vendored
View File

@@ -4,22 +4,27 @@
# Comment to be posted to on first time issues
newIssueWelcomeComment: |
Thanks for opening your first issue here! Please follow the issue template to help us help you 👍🎉😄
If you have screenshots to share demonstrating the issue, that's really helpful! 📸 You can [make a gif](https://www.cockos.com/licecap/) too!
Thanks for opening your first issue here! This space is [protected by our Code of Conduct](https://publiclab.org/conduct) - and we're here to help.
Please follow the issue template to help us help you 👍🎉😄
If you have screenshots to share demonstrating the issue, that's really helpful! 📸 You can [make a gif](https://www.cockos.com/licecap/) too!
Don't forget to join our [PublicLab Gitter channel](https://gitter.im/publiclab/publiclab) and our [ImageSequencer Gitter Channel](https://gitter.im/publiclab/image-sequencer) for some brainstorming discussions.
# Configuration for new-pr-welcome - https://github.com/behaviorbot/new-pr-welcome
# Comment to be posted to on PRs from first time contributors in your repository
newPRWelcomeComment: |
Thanks for opening this pull request!
Thanks for opening this pull request! This space is [protected by our Code of Conduct](https://publiclab.org/conduct).
There may be some errors, **but don't worry!** We're here to help! 👍🎉😄
Also please refer (https://github.com/publiclab/image-sequencer/blob/main/README.md) for installation help.
# Configuration for first-pr-merge - https://github.com/behaviorbot/first-pr-merge
# Comment to be posted to on pull requests merged by a first time user
firstPRMergeComment: |
Congrats on merging your first pull request! 🙌🎉⚡️
Your code will be published to https://beta.sequencer.publiclab.org in a day or two.
In the meantime, can you tell us your Twitter handle so we can thank you properly?
Now that you've completed this, you can help someone else take their first step!
Your code will be published to https://beta.sequencer.publiclab.org in a day or two. Please test out your work on this testing server and report back with a comment that all has gone well!
In the meantime, can you tell us your Twitter handle so we can thank you properly also do join our weekly check-in to share your this week goal and the awesome work you did 😃.
Please find the link **pinned in the issue section**
Now that you've completed this, you can help someone else take their first step! Try looking at this list of `first-timers-only` issues, and see if someone else is waiting for feedback, or even stuck! 😕
People often get stuck at the same steps, so you might be able to help someone get unstuck, or help lead them to some documentation that'd help. Reach out and be encouraging and friendly! 😄 🎉
See: [Public Lab's coding community!](https://code.publiclab.org)
# It is recommended to include as many gifs and emojis as possible

7
.gitpod.dockerfile Normal file
View File

@@ -0,0 +1,7 @@
FROM gitpod/workspace-full
USER root
RUN sudo apt-get update && apt-get install -y apt-transport-https \
&& sudo apt-get install -y \
xserver-xorg-dev libxext-dev libxi-dev build-essential libxi-dev libglu1-mesa-dev libglew-dev pkg-config libglu1-mesa-dev freeglut3-dev mesa-common-dev \
&& apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/*

View File

@@ -1,3 +1,5 @@
image:
file: .gitpod.dockerfile
tasks:
- init: npm run setup
command: npm start

View File

@@ -1,8 +1,8 @@
sudo: required
language: node_js
node_js:
- '8'
- '10'
- '12'
env:
- CXX=g++-4.8
before_script:
@@ -10,15 +10,22 @@ before_script:
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
- chmod +x ./cc-test-reporter
- ./cc-test-reporter before-build
script:
- npm test
- npm run benchmark
- npm run gif-test
- grunt tests
- npm run core-tests
- npm run test-ui
- npm run test-ui-2
- grunt build
jobs:
include:
- name: "Base istanbul/tape node tests"
script: npm test
- name: "Benchmark tests"
script: npm run benchmark
- name: "Gif tests"
script: npm run gif-test
- name: "Browserify core tests and run"
script: grunt tests && npm run core-tests
- name: "Jasmine UI tests (mocked browser env)"
script: npm run test-ui
- name: "jest-puppeteer UI tests (full browser env)"
script: npm run test-ui-2
- name: "Grunt build test of dev environment"
script: grunt build
after_success:
- bash <(curl -s https://codecov.io/bash)
after_script:

View File

@@ -17,6 +17,7 @@ Most contribution (we imagine) would be in the form of API-compatible modules, w
* [Ideas](#Contribution-ideas)
* [Grunt Tasks](#grunt-tasks)
* [UI Helper Methods](#ui-helper-methods)
* [Scripts](#scripts)
****
@@ -374,7 +375,7 @@ module.exports =
We are now using `eslint` and `husky` to help lint and format our code each time we commit. Eslint defines coding standards and helps in cleaning up the code. To run eslint for checking errors globally or within a specific file run:
```
npx eslint .
npx eslint .
npx eslint <file path>
```
@@ -412,15 +413,15 @@ The following command is used for running the tasks: `grunt [task-name]`. Here `
The method returns a scoped `jQuery` object which only searches for elements inside a given scope (a DOM element).
To use the method,
To use the method,
* import the `scopeSelector` and `scopeSelectorAll` methods from `lib/scopeQuery.js`
* call the methods with scope as a parameter
```js
var scopeQuery = require('./scopeQuery');
var $step = scopeQuery.scopeSelector(scope),
$stepAll = scopeQuery.scopeSelectorAll(scope);
$stepAll = scopeQuery.scopeSelectorAll(scope);
```
This will return an object with a constructor which returns a `jQuery` object (from inside the scope) but with new `elem` and `elemAll` methods.
@@ -433,7 +434,7 @@ This will return an object with a constructor which returns a `jQuery` object (f
#### Example
```js
//The scope is a div element with id=“container“ and there are three divs in it
//The scope is a div element with id=“container“ and there are three divs in it
//with ids „1“, „2“, and „3“, and all of them have a „child“ class attribute
var $step = require('./scopeQuery').scopeSelector(document.getElementById('container'));
@@ -458,3 +459,23 @@ The following code can be used
$step('query').show().hide();
$stepAll('q2').show().hide();
```
## Scripts
The following shell scripts are present in the `scripts/` directory.
- `update-gh-pages`: This script can be used to update the `gh-pages` branch of this repo or a fork.
This script is not meant to be used directly as it runs in the current working directory.
If you run it on your primary local clone, it can **delete** the local changes. This script is made to be used in a github action
or in a temporary directory via another script, such as `update-demo`.
Arguments:
1. Repo(to use as upstream) url in the form username/repo (default: publiclab/image-sequencer) NOTE: Github only
2. Branch to pull from eg: main or stable (default: stable)
3. CNAME URL (default: none)
4. Set the fourth argument to anything to bypass the warning. You will have to set this argument if you want to run this script in another script without needing
user interaction, such as in a github action.
- `update-demo`: A safe, interactive script that can be used to update the `gh-pages` branch of any image-sequencer fork.
This script is safe to use directly because it separately clones the repo in a temporary directory.
Arguments: None since it is a an *interactive* script, ie it asks the user for input.

View File

@@ -44,7 +44,14 @@ module.exports = function(grunt) {
dest: 'dist/image-sequencer-ui.brow.js'
},
tests: {
src: ['test/core/sequencer/meta-modules.js', 'test/core/sequencer/image-sequencer.js', 'test/core/sequencer/chain.js', 'test/core/sequencer/replace.js', 'test/core/sequencer/import-export.js', 'test/core/sequencer/run.js', 'test/core/sequencer/dynamic-imports.js', 'test/core/util/*.js'],
src: ['test/core/sequencer/meta-modules.js',
'test/core/sequencer/image-sequencer.js',
'test/core/sequencer/chain.js',
'test/core/sequencer/replace.js',
'test/core/sequencer/import-export.js',
'test/core/sequencer/run.js',
'test/core/sequencer/dynamic-imports.js',
'test/core/util/*.js'],
dest: './output/core-tests.js'
}
},

View File

@@ -2,13 +2,18 @@ Image Sequencer
====
[![Code of Conduct](https://img.shields.io/badge/code-of%20conduct-green.svg)](https://publiclab.org/conduct)
[![npm version](https://badge.fury.io/js/image-sequencer.svg)](https://badge.fury.io/js/image-sequencer)
[![Build Status](https://travis-ci.org/publiclab/image-sequencer.svg?branch=master)](https://travis-ci.org/publiclab/image-sequencer) [![Maintainability](https://api.codeclimate.com/v1/badges/5906996dd2e90aca6398/maintainability)](https://codeclimate.com/github/publiclab/image-sequencer/maintainability) [![Codecov](https://img.shields.io/codecov/c/github/publiclab/image-sequencer.svg?logo=codecov)](https://codecov.io/gh/publiclab/image-sequencer)
[![Gitpod Ready-to-Code](https://img.shields.io/badge/Gitpod-ready--to--code-blue?logo=gitpod)](https://gitpod.io/from-referrer/)
[![Gitpod Ready-to-Code](https://img.shields.io/badge/Gitpod-ready--to--code-blue?logo=gitpod)](https://gitpod.io/#https://github.com/publiclab/image-sequencer/)
- **Latest Stable Demo**: https://sequencer.publiclab.org
- **Latest Beta Demo**: https://beta.sequencer.publiclab.org
- **Stable Branch**: https://github.com/publiclab/image-sequencer/tree/stable/
Begin running (and contributing to) this codebase immediately with [GitPod](https://gitpod.io) (this also opens the latest `main` branch code):
[![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/#https://github.com/publiclab/image-sequencer)
## Why
Image Sequencer is different from other image processing systems because it's _non-destructive_: instead of modifying the original image, it **creates a new image at each step in a sequence**. This is because it:
@@ -615,8 +620,7 @@ The final frames are then converted back to a GIF but in the process, the time d
Modules that do not work:
1. ColorBar (Will get fixed upon fixing overlay as this is a meta module which uses overlay)
2. FisheyeGL
4. Overlay
5. Text Overlay (Almost fixed)
6. Blend
7. Histogram
8. WebGL Distort
3. Overlay
4. Blend
5. Histogram
6. WebGL Distort

View File

@@ -1,12 +1,8 @@
/* https://github.com/theleagueof/league-spartan */
@font-face {
font-family: 'League Spartan';
src: url('https://raw.githubusercontent.com/theleagueof/league-spartan/master/_webfonts/leaguespartan-bold.eot');
src: url('https://raw.githubusercontent.com/theleagueof/league-spartan/master/_webfonts/leaguespartan-bold.eot?#iefix') format('embedded-opentype'),
url('https://raw.githubusercontent.com/theleagueof/league-spartan/master/_webfonts/leaguespartan-bold.woff2') format('woff2'),
url('https://raw.githubusercontent.com/theleagueof/league-spartan/master/_webfonts/leaguespartan-bold.woff') format('woff'),
url('https://raw.githubusercontent.com/theleagueof/league-spartan/master/_webfonts/leaguespartan-bold.ttf') format('truetype'),
url('https://raw.githubusercontent.com/theleagueof/league-spartan/master/_webfonts/leaguespartan-bold.svg#league_spartanbold') format('svg');
src: url('https://cdn.jsdelivr.net/npm/fontsource-league-spartan@3/files/league-spartan-latin-600-normal.woff2') format('woff2'),
url('https://cdn.jsdelivr.net/npm/fontsource-league-spartan@3/files/league-spartan-latin-600-normal.woff') format('woff');
font-weight: bold;
font-style: normal;
}
@@ -44,7 +40,6 @@ body > .container-fluid {
.panel {
margin-left: 20px;
margin-right: 20px;
min-width:400px;
}
.mouse {
@@ -66,7 +61,6 @@ body > .container-fluid {
border-radius: 8px;
text-align: center;
color: #444;
min-width:300px;
}
.dropzone input {
@@ -156,6 +150,13 @@ body > .container-fluid {
margin: 0px 0px 0px 10px;
width: 250px;
}
@media(max-width: 768px) {
#dropzone {
margin: 0 0% 30px;
}
}
#dwnld {
max-width: 500px;
margin: 20px auto;
@@ -324,7 +325,7 @@ a.name-header{
position: fixed;
right: 2%;
top: 5%;
color: lightgray;
color: gray;
}
/* Non float rightward alignment*/
.right {

View File

@@ -340,6 +340,7 @@ window.onload = function () {
else
step.imgElement.src = url;
insertPreview.updatePreviews(url, document.querySelector('#addStep'));
DefaultHtmlStepUi(sequencer).updateDimensions(step);
}
});

View File

@@ -60,7 +60,7 @@
<div class="container-fluid">
<header class="text-center" style="min-width: 450px">
<header class="text-center">
<h1><a href="/" target='_blank' class="name-header">Image Sequencer</a></h1>
<p>
A pure JavaScript sequential image processing system, inspired by storyboards. Instead of modifying the original
@@ -218,7 +218,7 @@
<h2>Need Help?</h2>
<p>
<a class="btn btn-default" href="https://github.com/publiclab/image-sequencer/issues">Ask a question</a>
<a class="btn btn-default" href="https://publiclab.org/chat">Ask in our chatroom</a>
<a class="btn btn-default" href="https://gitter.im/publiclab/image-sequencer" target="_blank">Ask in our chatroom </a>
</p>
</div>
<div class="col-md-6">

View File

@@ -28,7 +28,7 @@ function DefaultHtmlSequencerUi(_sequencer, options) {
function selectNewStepUi() {
var m = $(addStepSel + ' select').val();
if(!m) m = arguments[0];
$(addStepSel + ' .info').html(_sequencer.modulesInfo(m).description);
else $(addStepSel + ' .info').html(_sequencer.modulesInfo(m).description);
$(addStepSel + ' #add-step-btn').prop('disabled', false);
}

View File

@@ -1,4 +1,4 @@
const staticCacheName = 'image-sequencer-static-v3.5.1';
const staticCacheName = 'image-sequencer-static-v3.6.0';
self.addEventListener('install', event => {
console.log('Attempting to install service worker');
});

5642
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -1,14 +1,14 @@
{
"name": "image-sequencer",
"version": "3.5.1",
"version": "3.6.0",
"description": "A modular JavaScript image manipulation library modeled on a storyboard.",
"main": "src/ImageSequencer.js",
"scripts": {
"debug": "TEST=true node ./index.js -i ./examples/images/monarch.png -s invert",
"test": "TEST=true istanbul cover tape test/core/*.js test/core/ui/user-interface.js test/core/modules/*.js | tap-spec;",
"benchmark" : "node test/core/sequencer/benchmark.js | tap-spec;",
"gif-test" : "node test/core/gifs/gif-test.js | tap-spec;",
"core-tests" : "cat ./output/core-tests.js | tape-run --render=\"tap-spec\"",
"benchmark": "node test/core/sequencer/benchmark.js | tap-spec;",
"gif-test": "node test/core/gifs/gif-test.js | tap-spec;",
"core-tests": "cat ./output/core-tests.js | tape-run --render=\"tap-spec\"",
"test-all": "npm run test && npm run benchmark && npm run gif-test && grunt tests && npm run core-tests",
"test-ui": "node node_modules/jasmine/bin/jasmine test/ui/spec/*.js",
"test-ui-2": "node ./node_modules/.bin/jest",
@@ -55,14 +55,14 @@
"image-sequencer-invert": "^1.0.0",
"imagejs": "0.0.9",
"imagemin": "^7.0.1",
"imagemin-jpegtran": "^6.0.0",
"imagemin-pngquant": "^8.0.0",
"imagemin-jpegtran": "^7.0.0",
"imagemin-pngquant": "^9.0.1",
"imgareaselect": "git://github.com/jywarren/imgareaselect.git#v1.0.0-rc.2",
"istanbul": "^0.4.5",
"jasmine": "^3.4.0",
"jpegtran-bin": "^4.0.0",
"jpegtran-bin": "^5.0.2",
"jquery": "^3.3.1",
"jsdom": "^15.0.0",
"jsdom": "^16.3.0",
"jspdf": "^1.5.3",
"jsqr": "^1.1.1",
"lodash": "^4.17.11",
@@ -100,14 +100,14 @@
"jasmine-core": "^3.3.0",
"jasmine-jquery": "^2.1.1",
"jasmine-spec-reporter": "^4.2.1",
"jest": "^25.1.0",
"jest": "^26.1.0",
"jest-puppeteer": "^4.3.0",
"lint-staged": "^10.0.3",
"looks-same": "^7.0.0",
"matchdep": "^2.0.0",
"tap-spec": "^5.0.0",
"tape": "^4.9.2",
"tape-run": "^7.0.0",
"tape-run": "^8.0.0",
"uglify-es": "^3.3.7"
},
"husky": {
@@ -119,4 +119,4 @@
"bin": {
"sequencer": "./index.js"
}
}
}

26
scripts/update-demo Executable file
View File

@@ -0,0 +1,26 @@
#!/bin/bash
scriptsDir=$(realpath $(dirname $0))
echo -ne "Enter the repo to push to in the form username/repo (required): "
read -e pushRepo
echo -ne "Enter repo URL to pull from (upstream) in the form username/repo (default: publiclab/image-sequencer): "
read -e repoInput
echo -ne "Enter branch name (default: stable): "
read -e branchInput
echo -ne "Enter CNAME URL(default: none): "
read -e cnameUrlInput
tempDir=$(mktemp -d)
pushd $tempDir > /dev/null
git clone https://github.com/$pushRepo
pushd image-sequencer > /dev/null
$scriptsDir/update-gh-pages "$repoInput" "$branchInput" "$cnameUrlInput" "no warn"
popd > /dev/null
popd > /dev/null

117
scripts/update-gh-pages Executable file
View File

@@ -0,0 +1,117 @@
#!/bin/bash
set -e # So that nothing wrong is published
warn() {
echo -e "\033[1;31m
------IMPORTANT------
THIS SCRIPT IS NOT MEANT TO BE USED DIRECTLY, PLEASE NEWLY CLONE THE REPO IN A SEPARATE DIRECTORY AND USE THE SCRIPT THERE.
USING THIS SCRIPT IN YOUR MAIN CLONE MAY DELETE YOUR LOCAL CHANGES.
This script is made to be reusable: If you want to manually update the demo, \
use the interactive script \`update-demo\`. This script can also be used in a github action.
You can set the 4th argument to anything to bypass this warning. \
Setting the 4th argument means that the first 3 arguments are also set which means that you know what you are doing (I assume).
------IMPORTANT------
\033[0m"
echo -ne "Do you still want to continue? [Y/n]: "
read -e yN
case $yN in
[yY][eE][sS] | [yY])
;;
*)
exit 0
;;
esac
}
# --- Constants ---
deps="jquery bootstrap imgareaselect gifshot downloadjs selectize font-awesome bootstrap-colorpicker jspdf opencv.js/opencv.js" # A list of node_module dependencies to force commit
# --- Constants ---
# --- Arguments ---
# $1: Repo(to use as upstream) url in the form username/repo (default: publiclab/image-sequencer) NOTE: Github only
# $2: Branch to pull from eg: main or stable (default: stable)
# $3: CNAME URL (default: none)
# $4: Set the fourth argument to anything to bypass the warning.
if [[ "$1" != "" ]];
then
repo=$1
else
repo="publiclab/image-sequencer"
fi
if [[ "$2" != "" ]];
then
branch=$2
else
branch="stable"
fi
if [[ "$3" != "" ]];
then
CNAMEURL=$3
else
CNAMEURL=""
fi
# --- Arguments ---
# --- Main Script ---
if [[ "$4" == "" ]]; # Set a 4th argument to anything to bypass this warning.
then
warn
fi
git checkout gh-pages
git remote add upstream https://github.com/$repo
git fetch upstream
git reset --hard upstream/$branch
echo -e "Running setup script."
npm run setup
echo -e "Building dist files."
grunt production
if [ ! -f CNAME ];
then
echo -e "Creating CNAME"
touch CNAME
fi
echo $CNAMEURL > CNAME
echo -e "Removing unnecessary files."
rm -R docs/
rm -R test/
rm CONTRIBUTING.md
rm index.js
echo -e "Copying important files from src/"
cp src/ui/prepareDynamic.js prepareDynamic.js
echo "Removing src/"
rm -R src/
mkdir -p src/ui/
mv prepareDynamic.js src/ui/prepareDynamic.js
echo -e "git add dist and node_modules dependencies."
git add .
for dep in $deps; # Force add node_modules dependencies
do
git add -f node_modules/$dep
done
git add -f dist/image-sequencer.js
git add -f dist/image-sequencer-ui.js
echo -e "committing and pusing."
git commit --no-verify -m "update"
git push -f
exit 0
# --- Main Script ---

View File

@@ -6,7 +6,7 @@ module.exports = require('../../util/createMetaModule.js')(
{ 'name': 'gradient', 'options': {} },
{ 'name': 'colormap', 'options': { colormap: options.colormap || defaults.colormap } },
{ 'name': 'crop', 'options': { 'y': 0, 'w': '100%', 'h': options.h || defaults.h } },
{ 'name': 'overlay', 'options': { 'x': options.x || defaults.h, 'y': options.y || defaults.y, 'offset': -4 } }
{ 'name': 'overlay', 'options': { 'x': options.x || defaults.x, 'y': options.y || defaults.y, 'offset': -4 } }
];
}, {
infoJson: require('./info.json')

View File

@@ -29,11 +29,13 @@ module.exports = function CropModule(options, UI) {
options.step.input = input.src;
// We should do this via event/listener:
if (ui && ui.hide) ui.hide();
function extraManipulation(pixels) {
const newPixels = require('./Crop')(pixels, options, function() {
// We should do this via event/listener:
if (ui && ui.hide) ui.hide();
// Start custom UI setup (draggable UI)
// Only once we have an input image
if (setupComplete === false && options.step.inBrowser && !options.noUI) {

View File

@@ -14,11 +14,9 @@ const kernelx = [
[ 1, 2, 1]
];
let pixelsToBeSupressed = [];
module.exports = function(pixels, highThresholdRatio, lowThresholdRatio, useHysteresis) {
let angles = [], grads = [], strongEdgePixels = [], weakEdgePixels = [];
let angles = [], grads = [], strongEdgePixels = [], weakEdgePixels = [], pixelsToBeSupressed = [];
for (var x = 0; x < pixels.shape[0]; x++) {
grads.push([]);
angles.push([]);
@@ -34,8 +32,8 @@ module.exports = function(pixels, highThresholdRatio, lowThresholdRatio, useHyst
angles.slice(-1)[0].push(result.angle);
}
}
nonMaxSupress(pixels, grads, angles); // Non Maximum Suppression: Filter fine edges.
doubleThreshold(pixels, highThresholdRatio, lowThresholdRatio, grads, strongEdgePixels, weakEdgePixels); // Double Threshold: Categorizes edges into strong and weak edges based on two thresholds.
nonMaxSupress(pixels, grads, angles, pixelsToBeSupressed); // Non Maximum Suppression: Filter fine edges.
doubleThreshold(pixels, highThresholdRatio, lowThresholdRatio, grads, strongEdgePixels, weakEdgePixels, pixelsToBeSupressed); // Double Threshold: Categorizes edges into strong and weak edges based on two thresholds.
if(useHysteresis.toLowerCase() == 'true') hysteresis(strongEdgePixels, weakEdgePixels); // Optional Hysteresis (very slow) to minimize edges generated due to noise.
strongEdgePixels.forEach(pixel => preserve(pixels, pixel)); // Makes the strong edges White.
@@ -112,10 +110,13 @@ function sobelFilter(pixels, x, y) {
* @returns {Number} Category number of the given angle
*/
function categorizeAngle(angle){
if ((angle >= -22.5 && angle <= 22.5) || (angle < -157.5 && angle >= -180)) return 1;
else if ((angle >= 22.5 && angle <= 67.5) || (angle < -112.5 && angle >= -157.5)) return 2;
else if ((angle >= 67.5 && angle <= 112.5) || (angle < -67.5 && angle >= -112.5)) return 3;
else if ((angle >= 112.5 && angle <= 157.5) || (angle < -22.5 && angle >= -67.5)) return 4;
const pi = Math.PI;
angle = angle > 0 ? angle : pi - Math.abs(angle); // Diagonally flip the angle if it is negative (since edge remains the same)
if (angle <= pi / 8 || angle > 7 * pi / 8) return 1;
else if (angle > pi / 8 && angle <= 3 * pi / 8) return 2;
else if (angle > 3 * pi / 8 && angle <= 5 * pi / 8) return 3;
else if (angle > 5 * pi / 8 && angle <= 7 * pi / 8) return 4;
/* Category Map
* 1 => E-W
@@ -144,9 +145,7 @@ const removeElem = (arr = [], elem) => { // Removes the specified element from t
};
// Non Maximum Supression without interpolation.
function nonMaxSupress(pixels, grads, angles) {
angles = angles.map((arr) => arr.map(convertToDegrees));
function nonMaxSupress(pixels, grads, angles, pixelsToBeSupressed) {
for (let x = 0; x < pixels.shape[0]; x++) {
for (let y = 0; y < pixels.shape[1]; y++) {
@@ -159,7 +158,7 @@ function nonMaxSupress(pixels, grads, angles) {
pixelsToBeSupressed.push([x, y]);
}
break;
case 2:
if (!((grads[x][y] >= grads[x + 1][y + 1]) && (grads[x][y] >= grads[x - 1][y - 1]))){
pixelsToBeSupressed.push([x, y]);
@@ -183,20 +182,11 @@ function nonMaxSupress(pixels, grads, angles) {
}
}
/**
* @method convertToDegrees
* @description Converts the given angle(in radians) to degrees.
* @param {Number} radians Angle in radians
* @returns {Number} Angle in degrees
*/
var convertToDegrees = radians => (radians * 180) / Math.PI;
// Finds the max value in a 2d array like grads.
var findMaxInMatrix = arr => Math.max(...arr.map(el => el.map(val => val ? val : 0)).map(el => Math.max(...el)));
// Applies the double threshold to the image.
function doubleThreshold(pixels, highThresholdRatio, lowThresholdRatio, grads, strongEdgePixels, weakEdgePixels) {
function doubleThreshold(pixels, highThresholdRatio, lowThresholdRatio, grads, strongEdgePixels, weakEdgePixels, pixelsToBeSupressed) {
const highThreshold = findMaxInMatrix(grads) * highThresholdRatio, // High Threshold relative to the strongest edge
lowThreshold = highThreshold * lowThresholdRatio; // Low threshold relative to high threshold

View File

@@ -16,7 +16,6 @@ module.exports = function edgeDetect(options, UI) {
// The function which is called on every draw.
function draw(input, callback, progressObj) {
progressObj.stop(true);
progressObj.overrideFlag = true;

View File

@@ -1,6 +1,3 @@
const imagejs = require('imagejs'),
pixelSetter = require('../../util/pixelSetter'),
ndarray = require('ndarray');
/*
* Resize the image by given percentage value
*/
@@ -19,44 +16,7 @@ module.exports = function Resize(options, UI) {
const step = this;
function extraManipulation(pixels) {
// Value above 100% scales up, and below 100% scales down
const resize_value = parseInt(options.resize.slice(0, -1));
if (resize_value == 100) return pixels;
const new_width = Math.round(pixels.shape[0] * (resize_value / 100)),
new_height = Math.round(pixels.shape[1] * (resize_value / 100));
const bitmap = new imagejs.Bitmap({ width: pixels.shape[0], height: pixels.shape[1] });
for (let x = 0; x < pixels.shape[0]; x++) {
for (let y = 0; y < pixels.shape[1]; y++) {
let r = pixels.get(x, y, 0),
g = pixels.get(x, y, 1),
b = pixels.get(x, y, 2),
a = pixels.get(x, y, 3);
bitmap.setPixel(x, y, r, g, b, a);
}
}
const resized = bitmap.resize({
width: new_width,
height: new_height,
algorithm: 'bicubicInterpolation'
});
const newPix = new ndarray([], [new_width, new_height, 4]);
for (let x = 0; x < new_width; x++) {
for (let y = 0; y < new_height; y++) {
const {r, g, b, a} = resized.getPixel(x, y);
pixelSetter(x, y, [r, g, b, a], newPix);
}
}
return newPix;
return require('./Resize')(pixels, options);
}
function output(image, datauri, mimetype, wasmSuccess) {

View File

@@ -0,0 +1,44 @@
const imagejs = require('imagejs'),
pixelSetter = require('../../util/pixelSetter'),
ndarray = require('ndarray');
module.exports = function Resize(pixels, options) {
const resize_value = parseInt(options.resize.slice(0, -1));
if (resize_value == 100) return pixels;
const new_width = Math.round(pixels.shape[0] * (resize_value / 100)),
new_height = Math.round(pixels.shape[1] * (resize_value / 100));
const bitmap = new imagejs.Bitmap({
width: pixels.shape[0],
height: pixels.shape[1]
});
for (let x = 0; x < pixels.shape[0]; x++) {
for (let y = 0; y < pixels.shape[1]; y++) {
let r = pixels.get(x, y, 0),
g = pixels.get(x, y, 1),
b = pixels.get(x, y, 2),
a = pixels.get(x, y, 3);
bitmap.setPixel(x, y, r, g, b, a);
}
}
const resized = bitmap.resize({
width: new_width,
height: new_height,
algorithm: 'bicubicInterpolation'
});
const newPix = new ndarray([], [new_width, new_height, 4]);
for (let x = 0; x < new_width; x++) {
for (let y = 0; y < new_height; y++) {
const { r, g, b, a } = resized.getPixel(x, y);
pixelSetter(x, y, [r, g, b, a], newPix);
}
}
return newPix;
};

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,35 @@
const timeout = process.env.SLOWMO ? 30000 : 10000;
const fs = require('fs');
beforeAll(async () => {
path = fs.realpathSync('file://../examples/index.html');
await page.goto('file://' + path, {waitUntil: 'domcontentloaded'});
});
describe('Apply Button Works', () => {
test('Apply Button is clicked', async () => {
await page.waitForSelector('.step');
await page.click('[data-value=\'resize\']');
const Length1 = await page.evaluate(() => document.querySelectorAll('.step').length);
//Lets change the default value
expect(Length1).toBe(2);
// Let's check the source of the image output by the default values
const src1 = await page.evaluate(() => document.querySelectorAll('.step img')[1].src);
//Lets change the default value
await page.evaluate(() => document.querySelector('div[name="resize"] input').value = '');
await page.type('div[name="resize"] input', '50%');
//Wait for the apply button to get enabled then click
await page.waitForFunction('document.querySelector(".btn-save").disabled == false');
await page.$eval('.btn-save', elem => elem.click());
//Wait for the image to process with the new value
await page.waitForSelector('.load', {visible: false});
//Let's check the source of the image output by the new values
const src2 = await page.evaluate(() => document.querySelectorAll('.step img')[1].src);
//Expect default and new image to be changed
expect(src1).not.toEqual(src2);
}, timeout);
});

2882
yarn.lock

File diff suppressed because it is too large Load Diff