├── .gitignore ├── docs ├── 0.7.0 │ ├── fonts │ │ ├── OpenSans-Bold-webfont.eot │ │ ├── OpenSans-Bold-webfont.woff │ │ ├── OpenSans-Italic-webfont.eot │ │ ├── OpenSans-Light-webfont.eot │ │ ├── OpenSans-Light-webfont.woff │ │ ├── OpenSans-Italic-webfont.woff │ │ ├── OpenSans-Regular-webfont.eot │ │ ├── OpenSans-Regular-webfont.woff │ │ ├── OpenSans-Semibold-webfont.eot │ │ ├── OpenSans-Semibold-webfont.ttf │ │ ├── OpenSans-Semibold-webfont.woff │ │ ├── OpenSans-BoldItalic-webfont.eot │ │ ├── OpenSans-BoldItalic-webfont.woff │ │ ├── OpenSans-LightItalic-webfont.eot │ │ ├── OpenSans-LightItalic-webfont.woff │ │ ├── OpenSans-SemiboldItalic-webfont.eot │ │ ├── OpenSans-SemiboldItalic-webfont.ttf │ │ └── OpenSans-SemiboldItalic-webfont.woff │ ├── icons │ │ ├── home.svg │ │ └── search.svg │ ├── styles │ │ ├── collapse.css │ │ ├── prettify-jsdoc.css │ │ ├── prettify-tomorrow.css │ │ └── jsdoc-default.css │ ├── scripts │ │ ├── linenumber.js │ │ └── pagelocation.js │ ├── Autodesk.Viewing.html │ ├── index.html │ └── Utilities.js ├── 0.8.0 │ ├── fonts │ │ ├── OpenSans-Bold-webfont.eot │ │ ├── OpenSans-Bold-webfont.woff │ │ ├── OpenSans-Italic-webfont.eot │ │ ├── OpenSans-Light-webfont.eot │ │ ├── OpenSans-Light-webfont.woff │ │ ├── OpenSans-Italic-webfont.woff │ │ ├── OpenSans-Regular-webfont.eot │ │ ├── OpenSans-Regular-webfont.woff │ │ ├── OpenSans-Semibold-webfont.eot │ │ ├── OpenSans-Semibold-webfont.ttf │ │ ├── OpenSans-Semibold-webfont.woff │ │ ├── OpenSans-BoldItalic-webfont.eot │ │ ├── OpenSans-BoldItalic-webfont.woff │ │ ├── OpenSans-LightItalic-webfont.eot │ │ ├── OpenSans-LightItalic-webfont.woff │ │ ├── OpenSans-SemiboldItalic-webfont.eot │ │ ├── OpenSans-SemiboldItalic-webfont.ttf │ │ └── OpenSans-SemiboldItalic-webfont.woff │ ├── icons │ │ ├── home.svg │ │ └── search.svg │ ├── styles │ │ ├── collapse.css │ │ ├── prettify-jsdoc.css │ │ ├── prettify-tomorrow.css │ │ └── jsdoc-default.css │ ├── scripts │ │ ├── linenumber.js │ │ └── pagelocation.js │ ├── Autodesk.Viewing.html │ └── index.html └── master │ ├── fonts │ ├── OpenSans-Bold-webfont.eot │ ├── OpenSans-Bold-webfont.woff │ ├── OpenSans-Light-webfont.eot │ ├── OpenSans-Italic-webfont.eot │ ├── OpenSans-Italic-webfont.woff │ ├── OpenSans-Light-webfont.woff │ ├── OpenSans-Regular-webfont.eot │ ├── OpenSans-Regular-webfont.woff │ ├── OpenSans-Semibold-webfont.eot │ ├── OpenSans-Semibold-webfont.ttf │ ├── OpenSans-BoldItalic-webfont.eot │ ├── OpenSans-Semibold-webfont.woff │ ├── OpenSans-BoldItalic-webfont.woff │ ├── OpenSans-LightItalic-webfont.eot │ ├── OpenSans-LightItalic-webfont.woff │ ├── OpenSans-SemiboldItalic-webfont.eot │ ├── OpenSans-SemiboldItalic-webfont.ttf │ └── OpenSans-SemiboldItalic-webfont.woff │ ├── icons │ ├── home.svg │ └── search.svg │ ├── styles │ ├── collapse.css │ ├── prettify-jsdoc.css │ ├── prettify-tomorrow.css │ └── jsdoc-default.css │ ├── scripts │ ├── linenumber.js │ └── pagelocation.js │ ├── Autodesk.Viewing.html │ └── index.html ├── package.json ├── .jsdoc.json ├── examples ├── basic.html ├── server.js ├── fragments.html ├── list.html ├── enumerate.html ├── raycast.html └── transforms.html └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | .vscode/ 2 | node_modules/ 3 | *.log 4 | .DS_Store 5 | Thumbs.db -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Bold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Bold-webfont.eot -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Bold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Bold-webfont.eot -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Bold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Bold-webfont.woff -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Italic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Italic-webfont.eot -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Light-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Light-webfont.eot -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Light-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Light-webfont.woff -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Bold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Bold-webfont.woff -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Italic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Italic-webfont.eot -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Light-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Light-webfont.eot -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Light-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Light-webfont.woff -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Bold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Bold-webfont.eot -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Bold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Bold-webfont.woff -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Light-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Light-webfont.eot -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Italic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Italic-webfont.woff -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Regular-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Regular-webfont.eot -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Regular-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Regular-webfont.woff -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Semibold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Semibold-webfont.eot -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Semibold-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Semibold-webfont.ttf -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-Semibold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-Semibold-webfont.woff -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Italic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Italic-webfont.woff -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Regular-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Regular-webfont.eot -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Regular-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Regular-webfont.woff -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Semibold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Semibold-webfont.eot -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Semibold-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Semibold-webfont.ttf -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-Semibold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-Semibold-webfont.woff -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Italic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Italic-webfont.eot -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Italic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Italic-webfont.woff -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Light-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Light-webfont.woff -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Regular-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Regular-webfont.eot -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Regular-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Regular-webfont.woff -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Semibold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Semibold-webfont.eot -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Semibold-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Semibold-webfont.ttf -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-BoldItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-BoldItalic-webfont.eot -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-BoldItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-BoldItalic-webfont.woff -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-LightItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-LightItalic-webfont.eot -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-BoldItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-BoldItalic-webfont.eot -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-BoldItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-BoldItalic-webfont.woff -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-LightItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-LightItalic-webfont.eot -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-BoldItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-BoldItalic-webfont.eot -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-Semibold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-Semibold-webfont.woff -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-LightItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-LightItalic-webfont.woff -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-SemiboldItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-SemiboldItalic-webfont.eot -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-SemiboldItalic-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-SemiboldItalic-webfont.ttf -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-LightItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-LightItalic-webfont.woff -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-SemiboldItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-SemiboldItalic-webfont.eot -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-SemiboldItalic-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-SemiboldItalic-webfont.ttf -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-BoldItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-BoldItalic-webfont.woff -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-LightItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-LightItalic-webfont.eot -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-LightItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-LightItalic-webfont.woff -------------------------------------------------------------------------------- /docs/0.7.0/fonts/OpenSans-SemiboldItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.7.0/fonts/OpenSans-SemiboldItalic-webfont.woff -------------------------------------------------------------------------------- /docs/0.8.0/fonts/OpenSans-SemiboldItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/0.8.0/fonts/OpenSans-SemiboldItalic-webfont.woff -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-SemiboldItalic-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-SemiboldItalic-webfont.eot -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-SemiboldItalic-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-SemiboldItalic-webfont.ttf -------------------------------------------------------------------------------- /docs/master/fonts/OpenSans-SemiboldItalic-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Autodesk-Forge/forge-viewer-utils/HEAD/docs/master/fonts/OpenSans-SemiboldItalic-webfont.woff -------------------------------------------------------------------------------- /docs/0.7.0/icons/home.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /docs/0.8.0/icons/home.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /docs/master/icons/home.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /docs/0.7.0/icons/search.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /docs/0.8.0/icons/search.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /docs/master/icons/search.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /docs/0.7.0/styles/collapse.css: -------------------------------------------------------------------------------- 1 | @media only screen and (min-width: 681px) { 2 | nav > ul > li:hover .methods, 3 | .active .methods { 4 | display: block; 5 | } 6 | 7 | .methods { 8 | display: none; 9 | } 10 | 11 | nav > ul > li { 12 | padding: 20px 0; 13 | } 14 | 15 | nav > ul > li > a { 16 | padding: 0; 17 | } 18 | 19 | nav > ul > li.active a { 20 | margin-bottom: 10px; 21 | } 22 | 23 | nav > ul > li:hover > a, 24 | nav > ul > li.active > a { 25 | margin-bottom: 15px; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /docs/0.8.0/styles/collapse.css: -------------------------------------------------------------------------------- 1 | @media only screen and (min-width: 681px) { 2 | nav > ul > li:hover .methods, 3 | .active .methods { 4 | display: block; 5 | } 6 | 7 | .methods { 8 | display: none; 9 | } 10 | 11 | nav > ul > li { 12 | padding: 20px 0; 13 | } 14 | 15 | nav > ul > li > a { 16 | padding: 0; 17 | } 18 | 19 | nav > ul > li.active a { 20 | margin-bottom: 10px; 21 | } 22 | 23 | nav > ul > li:hover > a, 24 | nav > ul > li.active > a { 25 | margin-bottom: 15px; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /docs/master/styles/collapse.css: -------------------------------------------------------------------------------- 1 | @media only screen and (min-width: 681px) { 2 | nav > ul > li:hover .methods, 3 | .active .methods { 4 | display: block; 5 | } 6 | 7 | .methods { 8 | display: none; 9 | } 10 | 11 | nav > ul > li { 12 | padding: 20px 0; 13 | } 14 | 15 | nav > ul > li > a { 16 | padding: 0; 17 | } 18 | 19 | nav > ul > li.active a { 20 | margin-bottom: 10px; 21 | } 22 | 23 | nav > ul > li:hover > a, 24 | nav > ul > li.active > a { 25 | margin-bottom: 15px; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /docs/0.7.0/scripts/linenumber.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* global document */ 4 | (function () { 5 | var lineId, lines, totalLines, anchorHash; 6 | var source = document.getElementsByClassName('prettyprint source linenums'); 7 | var i = 0; 8 | var lineNumber = 0; 9 | 10 | if (source && source[0]) { 11 | anchorHash = document.location.hash.substring(1); 12 | lines = source[0].getElementsByTagName('li'); 13 | totalLines = lines.length; 14 | 15 | for (; i < totalLines; i++) { 16 | lineNumber++; 17 | lineId = 'line' + lineNumber; 18 | lines[i].id = lineId; 19 | if (lineId === anchorHash) { 20 | lines[i].className += ' selected'; 21 | } 22 | } 23 | } 24 | })(); 25 | -------------------------------------------------------------------------------- /docs/0.8.0/scripts/linenumber.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* global document */ 4 | (function () { 5 | var lineId, lines, totalLines, anchorHash; 6 | var source = document.getElementsByClassName('prettyprint source linenums'); 7 | var i = 0; 8 | var lineNumber = 0; 9 | 10 | if (source && source[0]) { 11 | anchorHash = document.location.hash.substring(1); 12 | lines = source[0].getElementsByTagName('li'); 13 | totalLines = lines.length; 14 | 15 | for (; i < totalLines; i++) { 16 | lineNumber++; 17 | lineId = 'line' + lineNumber; 18 | lines[i].id = lineId; 19 | if (lineId === anchorHash) { 20 | lines[i].className += ' selected'; 21 | } 22 | } 23 | } 24 | })(); 25 | -------------------------------------------------------------------------------- /docs/master/scripts/linenumber.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* global document */ 4 | (function () { 5 | var lineId, lines, totalLines, anchorHash; 6 | var source = document.getElementsByClassName('prettyprint source linenums'); 7 | var i = 0; 8 | var lineNumber = 0; 9 | 10 | if (source && source[0]) { 11 | anchorHash = document.location.hash.substring(1); 12 | lines = source[0].getElementsByTagName('li'); 13 | totalLines = lines.length; 14 | 15 | for (; i < totalLines; i++) { 16 | lineNumber++; 17 | lineId = 'line' + lineNumber; 18 | lines[i].id = lineId; 19 | if (lineId === anchorHash) { 20 | lines[i].className += ' selected'; 21 | } 22 | } 23 | } 24 | })(); 25 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "forge-viewer-utils", 3 | "version": "0.8.0", 4 | "description": "Wrapper library for Autodesk Forge Viewer providing additional utility functions and documentation.", 5 | "main": "src/Utilities.js", 6 | "scripts": { 7 | "build:docs": "rm -rf docs/$npm_package_version; jsdoc --configure .jsdoc.json --verbose; mv docs/forge-viewer-utils/$npm_package_version docs/; rm -rf docs/master docs/forge-viewer-utils; cp src/Utilities.js docs/$npm_package_version; cp -R docs/$npm_package_version docs/master" 8 | }, 9 | "keywords": [ 10 | "autodesk", 11 | "forge", 12 | "viewer", 13 | "utilities" 14 | ], 15 | "author": "Petr Broz ", 16 | "license": "MIT", 17 | "directories": { 18 | "example": "examples" 19 | }, 20 | "devDependencies": { 21 | "express": "^4.16.4", 22 | "jsdoc": "^3.6.6", 23 | "jsdoc-template": "git+https://github.com/braintree/jsdoc-template.git" 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /.jsdoc.json: -------------------------------------------------------------------------------- 1 | { 2 | "tags": { 3 | "allowUnknownTags": true, 4 | "dictionaries": ["jsdoc"] 5 | }, 6 | "source": { 7 | "include": ["src", "package.json", "README.md"], 8 | "includePattern": ".js$", 9 | "excludePattern": "(node_modules|docs)" 10 | }, 11 | "plugins": [ 12 | "plugins/markdown" 13 | ], 14 | "templates": { 15 | "referenceTitle": "Autodesk Forge Viewer Utilities", 16 | "disableSort": false, 17 | "collapse": true, 18 | "resources": { 19 | "Autodesk Forge": "https://forge.autodesk.com" 20 | }, 21 | "search": { 22 | "apiKey": "50f26ddfc7f2f8b57f05b7e306a852a1", 23 | "indexName": "petrbroz_forge-power-viewer", 24 | "hitsPerPage": 10 25 | } 26 | }, 27 | "opts": { 28 | "destination": "./docs/", 29 | "encoding": "utf8", 30 | "private": true, 31 | "recurse": true, 32 | "template": "./node_modules/jsdoc-template" 33 | } 34 | } -------------------------------------------------------------------------------- /examples/basic.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Autodesk Forge Viewer Utilities: Basic Example 8 | 9 | 10 | 11 | 15 | 16 | 17 |
18 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /examples/server.js: -------------------------------------------------------------------------------- 1 | const express = require('express'); 2 | const path = require('path'); 3 | const https = require('https'); 4 | const querystring = require('querystring'); 5 | 6 | const { FORGE_CLIENT_ID, FORGE_CLIENT_SECRET } = process.env; 7 | if (!FORGE_CLIENT_ID || !FORGE_CLIENT_SECRET) { 8 | console.warn('Provide FORGE_CLIENT_ID and FORGE_CLIENT_SECRET env. variables to run this application.'); 9 | return; 10 | } 11 | 12 | const app = express(); 13 | 14 | app.use(express.static(__dirname)); 15 | app.use(express.static(path.resolve(__dirname, '../src'))); 16 | app.get('/api/auth', function(req, res) { 17 | const options = { 18 | hostname: 'developer.api.autodesk.com', port: 443, 19 | path: '/authentication/v1/authenticate', method: 'POST', 20 | headers: { 'Content-Type': 'application/x-www-form-urlencoded' } 21 | }; 22 | const request = https.request(options, (response) => { 23 | let buffer = ''; 24 | response.on('data', function(data) { buffer += data; }); 25 | response.on('error', function(err) { res.status(500).send(err); }); 26 | response.on('end', function() { res.json(JSON.parse(buffer)); }); 27 | }); 28 | request.on('error', function(err) { res.status(500).send(err); }); 29 | request.write(querystring.stringify({ 30 | 'client_id': FORGE_CLIENT_ID, 31 | 'client_secret': FORGE_CLIENT_SECRET, 32 | 'grant_type': 'client_credentials', 33 | 'scope': 'viewables:read' 34 | })); 35 | request.end(); 36 | }); 37 | 38 | const port = process.env.PORT || 3000; 39 | app.listen(port, () => { console.log(`Server listening on port ${port}`); }); 40 | -------------------------------------------------------------------------------- /examples/fragments.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Autodesk Forge Viewer Utilities: Basic Example 8 | 9 | 10 | 11 | 15 | 16 | 17 |
18 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /examples/list.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Autodesk Forge Viewer Utilities: Basic Example 8 | 9 | 10 | 11 | 15 | 16 | 17 |
18 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /examples/enumerate.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Autodesk Forge Viewer Utilities: Basic Example 8 | 9 | 10 | 11 | 15 | 16 | 17 |
18 | 48 | 49 | 50 | -------------------------------------------------------------------------------- /docs/0.7.0/styles/prettify-jsdoc.css: -------------------------------------------------------------------------------- 1 | /* JSDoc prettify.js theme */ 2 | 3 | /* plain text */ 4 | .pln { 5 | color: #000000; 6 | font-weight: normal; 7 | font-style: normal; 8 | } 9 | 10 | /* string content */ 11 | .str { 12 | color: hsl(104, 100%, 24%); 13 | font-weight: normal; 14 | font-style: normal; 15 | } 16 | 17 | /* a keyword */ 18 | .kwd { 19 | color: #000000; 20 | font-weight: bold; 21 | font-style: normal; 22 | } 23 | 24 | /* a comment */ 25 | .com { 26 | font-weight: normal; 27 | font-style: italic; 28 | } 29 | 30 | /* a type name */ 31 | .typ { 32 | color: #000000; 33 | font-weight: normal; 34 | font-style: normal; 35 | } 36 | 37 | /* a literal value */ 38 | .lit { 39 | color: #006400; 40 | font-weight: normal; 41 | font-style: normal; 42 | } 43 | 44 | /* punctuation */ 45 | .pun { 46 | color: #000000; 47 | font-weight: bold; 48 | font-style: normal; 49 | } 50 | 51 | /* lisp open bracket */ 52 | .opn { 53 | color: #000000; 54 | font-weight: bold; 55 | font-style: normal; 56 | } 57 | 58 | /* lisp close bracket */ 59 | .clo { 60 | color: #000000; 61 | font-weight: bold; 62 | font-style: normal; 63 | } 64 | 65 | /* a markup tag name */ 66 | .tag { 67 | color: #006400; 68 | font-weight: normal; 69 | font-style: normal; 70 | } 71 | 72 | /* a markup attribute name */ 73 | .atn { 74 | color: #006400; 75 | font-weight: normal; 76 | font-style: normal; 77 | } 78 | 79 | /* a markup attribute value */ 80 | .atv { 81 | color: #006400; 82 | font-weight: normal; 83 | font-style: normal; 84 | } 85 | 86 | /* a declaration */ 87 | .dec { 88 | color: #000000; 89 | font-weight: bold; 90 | font-style: normal; 91 | } 92 | 93 | /* a variable name */ 94 | .var { 95 | color: #000000; 96 | font-weight: normal; 97 | font-style: normal; 98 | } 99 | 100 | /* a function name */ 101 | .fun { 102 | color: #000000; 103 | font-weight: bold; 104 | font-style: normal; 105 | } 106 | 107 | /* Specify class=linenums on a pre to get line numbering */ 108 | ol.linenums { 109 | margin-top: 0; 110 | margin-bottom: 0; 111 | } 112 | -------------------------------------------------------------------------------- /docs/0.8.0/styles/prettify-jsdoc.css: -------------------------------------------------------------------------------- 1 | /* JSDoc prettify.js theme */ 2 | 3 | /* plain text */ 4 | .pln { 5 | color: #000000; 6 | font-weight: normal; 7 | font-style: normal; 8 | } 9 | 10 | /* string content */ 11 | .str { 12 | color: hsl(104, 100%, 24%); 13 | font-weight: normal; 14 | font-style: normal; 15 | } 16 | 17 | /* a keyword */ 18 | .kwd { 19 | color: #000000; 20 | font-weight: bold; 21 | font-style: normal; 22 | } 23 | 24 | /* a comment */ 25 | .com { 26 | font-weight: normal; 27 | font-style: italic; 28 | } 29 | 30 | /* a type name */ 31 | .typ { 32 | color: #000000; 33 | font-weight: normal; 34 | font-style: normal; 35 | } 36 | 37 | /* a literal value */ 38 | .lit { 39 | color: #006400; 40 | font-weight: normal; 41 | font-style: normal; 42 | } 43 | 44 | /* punctuation */ 45 | .pun { 46 | color: #000000; 47 | font-weight: bold; 48 | font-style: normal; 49 | } 50 | 51 | /* lisp open bracket */ 52 | .opn { 53 | color: #000000; 54 | font-weight: bold; 55 | font-style: normal; 56 | } 57 | 58 | /* lisp close bracket */ 59 | .clo { 60 | color: #000000; 61 | font-weight: bold; 62 | font-style: normal; 63 | } 64 | 65 | /* a markup tag name */ 66 | .tag { 67 | color: #006400; 68 | font-weight: normal; 69 | font-style: normal; 70 | } 71 | 72 | /* a markup attribute name */ 73 | .atn { 74 | color: #006400; 75 | font-weight: normal; 76 | font-style: normal; 77 | } 78 | 79 | /* a markup attribute value */ 80 | .atv { 81 | color: #006400; 82 | font-weight: normal; 83 | font-style: normal; 84 | } 85 | 86 | /* a declaration */ 87 | .dec { 88 | color: #000000; 89 | font-weight: bold; 90 | font-style: normal; 91 | } 92 | 93 | /* a variable name */ 94 | .var { 95 | color: #000000; 96 | font-weight: normal; 97 | font-style: normal; 98 | } 99 | 100 | /* a function name */ 101 | .fun { 102 | color: #000000; 103 | font-weight: bold; 104 | font-style: normal; 105 | } 106 | 107 | /* Specify class=linenums on a pre to get line numbering */ 108 | ol.linenums { 109 | margin-top: 0; 110 | margin-bottom: 0; 111 | } 112 | -------------------------------------------------------------------------------- /docs/master/styles/prettify-jsdoc.css: -------------------------------------------------------------------------------- 1 | /* JSDoc prettify.js theme */ 2 | 3 | /* plain text */ 4 | .pln { 5 | color: #000000; 6 | font-weight: normal; 7 | font-style: normal; 8 | } 9 | 10 | /* string content */ 11 | .str { 12 | color: hsl(104, 100%, 24%); 13 | font-weight: normal; 14 | font-style: normal; 15 | } 16 | 17 | /* a keyword */ 18 | .kwd { 19 | color: #000000; 20 | font-weight: bold; 21 | font-style: normal; 22 | } 23 | 24 | /* a comment */ 25 | .com { 26 | font-weight: normal; 27 | font-style: italic; 28 | } 29 | 30 | /* a type name */ 31 | .typ { 32 | color: #000000; 33 | font-weight: normal; 34 | font-style: normal; 35 | } 36 | 37 | /* a literal value */ 38 | .lit { 39 | color: #006400; 40 | font-weight: normal; 41 | font-style: normal; 42 | } 43 | 44 | /* punctuation */ 45 | .pun { 46 | color: #000000; 47 | font-weight: bold; 48 | font-style: normal; 49 | } 50 | 51 | /* lisp open bracket */ 52 | .opn { 53 | color: #000000; 54 | font-weight: bold; 55 | font-style: normal; 56 | } 57 | 58 | /* lisp close bracket */ 59 | .clo { 60 | color: #000000; 61 | font-weight: bold; 62 | font-style: normal; 63 | } 64 | 65 | /* a markup tag name */ 66 | .tag { 67 | color: #006400; 68 | font-weight: normal; 69 | font-style: normal; 70 | } 71 | 72 | /* a markup attribute name */ 73 | .atn { 74 | color: #006400; 75 | font-weight: normal; 76 | font-style: normal; 77 | } 78 | 79 | /* a markup attribute value */ 80 | .atv { 81 | color: #006400; 82 | font-weight: normal; 83 | font-style: normal; 84 | } 85 | 86 | /* a declaration */ 87 | .dec { 88 | color: #000000; 89 | font-weight: bold; 90 | font-style: normal; 91 | } 92 | 93 | /* a variable name */ 94 | .var { 95 | color: #000000; 96 | font-weight: normal; 97 | font-style: normal; 98 | } 99 | 100 | /* a function name */ 101 | .fun { 102 | color: #000000; 103 | font-weight: bold; 104 | font-style: normal; 105 | } 106 | 107 | /* Specify class=linenums on a pre to get line numbering */ 108 | ol.linenums { 109 | margin-top: 0; 110 | margin-bottom: 0; 111 | } 112 | -------------------------------------------------------------------------------- /examples/raycast.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Autodesk Forge Viewer Utilities: Basic Example 8 | 9 | 10 | 11 | 15 | 16 | 17 |
18 | 52 | 53 | 54 | -------------------------------------------------------------------------------- /examples/transforms.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Autodesk Forge Viewer Utilities: Basic Example 8 | 9 | 10 | 11 | 15 | 16 | 17 |
18 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /docs/0.7.0/scripts/pagelocation.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | $(document).ready(function () { 4 | var currentSectionNav, target; 5 | 6 | // If an anchor hash is in the URL highlight the menu item 7 | highlightActiveHash(); 8 | // If a specific page section is in the URL highlight the menu item 9 | highlightActiveSection(); 10 | 11 | // If a specific page section is in the URL scroll that section up to the top 12 | currentSectionNav = $('#' + getCurrentSectionName() + '-nav'); 13 | 14 | if (currentSectionNav.position()) { 15 | $('nav').scrollTop(currentSectionNav.position().top); 16 | } 17 | 18 | // function to scroll to anchor when clicking an anchor linl 19 | $('a[href*="#"]:not([href="#"])').click(function () { 20 | /* eslint-disable no-invalid-this */ 21 | if (location.pathname.replace(/^\//, '') === this.pathname.replace(/^\//, '') && location.hostname === this.hostname) { 22 | target = $(this.hash); 23 | target = target.length ? target : $('[name=' + this.hash.slice(1) + ']'); 24 | if (target.length) { 25 | $('html, body').animate({ 26 | scrollTop: target.offset().top 27 | }, 1000); 28 | } 29 | } 30 | /* eslint-enable no-invalid-this */ 31 | }); 32 | }); 33 | 34 | // If a new anchor section is selected, change the hightlighted menu item 35 | $(window).bind('hashchange', function (event) { 36 | highlightActiveHash(event); 37 | }); 38 | 39 | function highlightActiveHash(event) { 40 | var oldUrl, oldSubSectionElement; 41 | 42 | // check for and remove old hash active state 43 | if (event && event.originalEvent.oldURL) { 44 | oldUrl = event.originalEvent.oldURL; 45 | 46 | if (oldUrl.indexOf('#') > -1) { 47 | oldSubSectionElement = $('#' + getCurrentSectionName() + '-' + oldUrl.substring(oldUrl.indexOf('#') + 1) + '-nav'); 48 | 49 | if (oldSubSectionElement) { 50 | oldSubSectionElement.removeClass('active'); 51 | } 52 | } 53 | } 54 | 55 | if (getCurrentHashName()) { 56 | $('#' + getCurrentSectionName() + '-' + getCurrentHashName() + '-nav').addClass('active'); 57 | } 58 | } 59 | 60 | function highlightActiveSection() { 61 | var pageId = getCurrentSectionName(); 62 | 63 | $('#' + pageId + '-nav').addClass('active'); 64 | } 65 | 66 | function getCurrentSectionName() { 67 | var path = window.location.pathname; 68 | var pageUrl = path.split('/').pop(); 69 | 70 | var sectionName = pageUrl.substring(0, pageUrl.indexOf('.')); 71 | 72 | // remove the wodr module- if its in the url 73 | sectionName = sectionName.replace('module-', ''); 74 | 75 | return sectionName; 76 | } 77 | 78 | function getCurrentHashName() { 79 | var pageSubSectionId; 80 | var pageSubSectionHash = window.location.hash; 81 | 82 | if (pageSubSectionHash) { 83 | pageSubSectionId = pageSubSectionHash.substring(1).replace('.', ''); 84 | 85 | return pageSubSectionId; 86 | } 87 | 88 | return false; 89 | } 90 | -------------------------------------------------------------------------------- /docs/0.8.0/scripts/pagelocation.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | $(document).ready(function () { 4 | var currentSectionNav, target; 5 | 6 | // If an anchor hash is in the URL highlight the menu item 7 | highlightActiveHash(); 8 | // If a specific page section is in the URL highlight the menu item 9 | highlightActiveSection(); 10 | 11 | // If a specific page section is in the URL scroll that section up to the top 12 | currentSectionNav = $('#' + getCurrentSectionName() + '-nav'); 13 | 14 | if (currentSectionNav.position()) { 15 | $('nav').scrollTop(currentSectionNav.position().top); 16 | } 17 | 18 | // function to scroll to anchor when clicking an anchor linl 19 | $('a[href*="#"]:not([href="#"])').click(function () { 20 | /* eslint-disable no-invalid-this */ 21 | if (location.pathname.replace(/^\//, '') === this.pathname.replace(/^\//, '') && location.hostname === this.hostname) { 22 | target = $(this.hash); 23 | target = target.length ? target : $('[name=' + this.hash.slice(1) + ']'); 24 | if (target.length) { 25 | $('html, body').animate({ 26 | scrollTop: target.offset().top 27 | }, 1000); 28 | } 29 | } 30 | /* eslint-enable no-invalid-this */ 31 | }); 32 | }); 33 | 34 | // If a new anchor section is selected, change the hightlighted menu item 35 | $(window).bind('hashchange', function (event) { 36 | highlightActiveHash(event); 37 | }); 38 | 39 | function highlightActiveHash(event) { 40 | var oldUrl, oldSubSectionElement; 41 | 42 | // check for and remove old hash active state 43 | if (event && event.originalEvent.oldURL) { 44 | oldUrl = event.originalEvent.oldURL; 45 | 46 | if (oldUrl.indexOf('#') > -1) { 47 | oldSubSectionElement = $('#' + getCurrentSectionName() + '-' + oldUrl.substring(oldUrl.indexOf('#') + 1) + '-nav'); 48 | 49 | if (oldSubSectionElement) { 50 | oldSubSectionElement.removeClass('active'); 51 | } 52 | } 53 | } 54 | 55 | if (getCurrentHashName()) { 56 | $('#' + getCurrentSectionName() + '-' + getCurrentHashName() + '-nav').addClass('active'); 57 | } 58 | } 59 | 60 | function highlightActiveSection() { 61 | var pageId = getCurrentSectionName(); 62 | 63 | $('#' + pageId + '-nav').addClass('active'); 64 | } 65 | 66 | function getCurrentSectionName() { 67 | var path = window.location.pathname; 68 | var pageUrl = path.split('/').pop(); 69 | 70 | var sectionName = pageUrl.substring(0, pageUrl.indexOf('.')); 71 | 72 | // remove the wodr module- if its in the url 73 | sectionName = sectionName.replace('module-', ''); 74 | 75 | return sectionName; 76 | } 77 | 78 | function getCurrentHashName() { 79 | var pageSubSectionId; 80 | var pageSubSectionHash = window.location.hash; 81 | 82 | if (pageSubSectionHash) { 83 | pageSubSectionId = pageSubSectionHash.substring(1).replace('.', ''); 84 | 85 | return pageSubSectionId; 86 | } 87 | 88 | return false; 89 | } 90 | -------------------------------------------------------------------------------- /docs/master/scripts/pagelocation.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | $(document).ready(function () { 4 | var currentSectionNav, target; 5 | 6 | // If an anchor hash is in the URL highlight the menu item 7 | highlightActiveHash(); 8 | // If a specific page section is in the URL highlight the menu item 9 | highlightActiveSection(); 10 | 11 | // If a specific page section is in the URL scroll that section up to the top 12 | currentSectionNav = $('#' + getCurrentSectionName() + '-nav'); 13 | 14 | if (currentSectionNav.position()) { 15 | $('nav').scrollTop(currentSectionNav.position().top); 16 | } 17 | 18 | // function to scroll to anchor when clicking an anchor linl 19 | $('a[href*="#"]:not([href="#"])').click(function () { 20 | /* eslint-disable no-invalid-this */ 21 | if (location.pathname.replace(/^\//, '') === this.pathname.replace(/^\//, '') && location.hostname === this.hostname) { 22 | target = $(this.hash); 23 | target = target.length ? target : $('[name=' + this.hash.slice(1) + ']'); 24 | if (target.length) { 25 | $('html, body').animate({ 26 | scrollTop: target.offset().top 27 | }, 1000); 28 | } 29 | } 30 | /* eslint-enable no-invalid-this */ 31 | }); 32 | }); 33 | 34 | // If a new anchor section is selected, change the hightlighted menu item 35 | $(window).bind('hashchange', function (event) { 36 | highlightActiveHash(event); 37 | }); 38 | 39 | function highlightActiveHash(event) { 40 | var oldUrl, oldSubSectionElement; 41 | 42 | // check for and remove old hash active state 43 | if (event && event.originalEvent.oldURL) { 44 | oldUrl = event.originalEvent.oldURL; 45 | 46 | if (oldUrl.indexOf('#') > -1) { 47 | oldSubSectionElement = $('#' + getCurrentSectionName() + '-' + oldUrl.substring(oldUrl.indexOf('#') + 1) + '-nav'); 48 | 49 | if (oldSubSectionElement) { 50 | oldSubSectionElement.removeClass('active'); 51 | } 52 | } 53 | } 54 | 55 | if (getCurrentHashName()) { 56 | $('#' + getCurrentSectionName() + '-' + getCurrentHashName() + '-nav').addClass('active'); 57 | } 58 | } 59 | 60 | function highlightActiveSection() { 61 | var pageId = getCurrentSectionName(); 62 | 63 | $('#' + pageId + '-nav').addClass('active'); 64 | } 65 | 66 | function getCurrentSectionName() { 67 | var path = window.location.pathname; 68 | var pageUrl = path.split('/').pop(); 69 | 70 | var sectionName = pageUrl.substring(0, pageUrl.indexOf('.')); 71 | 72 | // remove the wodr module- if its in the url 73 | sectionName = sectionName.replace('module-', ''); 74 | 75 | return sectionName; 76 | } 77 | 78 | function getCurrentHashName() { 79 | var pageSubSectionId; 80 | var pageSubSectionHash = window.location.hash; 81 | 82 | if (pageSubSectionHash) { 83 | pageSubSectionId = pageSubSectionHash.substring(1).replace('.', ''); 84 | 85 | return pageSubSectionId; 86 | } 87 | 88 | return false; 89 | } 90 | -------------------------------------------------------------------------------- /docs/0.7.0/styles/prettify-tomorrow.css: -------------------------------------------------------------------------------- 1 | /* Tomorrow Theme */ 2 | /* Original theme - https://github.com/chriskempson/tomorrow-theme */ 3 | /* Pretty printing styles. Used with prettify.js. */ 4 | /* SPAN elements with the classes below are added by prettyprint. */ 5 | /* plain text */ 6 | .pln { 7 | color: #4d4d4c; } 8 | 9 | @media screen { 10 | /* string content */ 11 | .str { 12 | color: hsl(104, 100%, 24%); } 13 | 14 | /* a keyword */ 15 | .kwd { 16 | color: hsl(240, 100%, 50%); } 17 | 18 | /* a comment */ 19 | .com { 20 | color: hsl(0, 0%, 60%); } 21 | 22 | /* a type name */ 23 | .typ { 24 | color: hsl(240, 100%, 32%); } 25 | 26 | /* a literal value */ 27 | .lit { 28 | color: hsl(240, 100%, 40%); } 29 | 30 | /* punctuation */ 31 | .pun { 32 | color: #000000; } 33 | 34 | /* lisp open bracket */ 35 | .opn { 36 | color: #000000; } 37 | 38 | /* lisp close bracket */ 39 | .clo { 40 | color: #000000; } 41 | 42 | /* a markup tag name */ 43 | .tag { 44 | color: #c82829; } 45 | 46 | /* a markup attribute name */ 47 | .atn { 48 | color: #f5871f; } 49 | 50 | /* a markup attribute value */ 51 | .atv { 52 | color: #3e999f; } 53 | 54 | /* a declaration */ 55 | .dec { 56 | color: #f5871f; } 57 | 58 | /* a variable name */ 59 | .var { 60 | color: #c82829; } 61 | 62 | /* a function name */ 63 | .fun { 64 | color: #4271ae; } } 65 | /* Use higher contrast and text-weight for printable form. */ 66 | @media print, projection { 67 | .str { 68 | color: #060; } 69 | 70 | .kwd { 71 | color: #006; 72 | font-weight: bold; } 73 | 74 | .com { 75 | color: #600; 76 | font-style: italic; } 77 | 78 | .typ { 79 | color: #404; 80 | font-weight: bold; } 81 | 82 | .lit { 83 | color: #044; } 84 | 85 | .pun, .opn, .clo { 86 | color: #440; } 87 | 88 | .tag { 89 | color: #006; 90 | font-weight: bold; } 91 | 92 | .atn { 93 | color: #404; } 94 | 95 | .atv { 96 | color: #060; } } 97 | /* Style */ 98 | /* 99 | pre.prettyprint { 100 | background: white; 101 | font-family: Consolas, Monaco, 'Andale Mono', monospace; 102 | font-size: 12px; 103 | line-height: 1.5; 104 | border: 1px solid #ccc; 105 | padding: 10px; } 106 | */ 107 | 108 | /* Get LI elements to show when they are in the main article */ 109 | article ul li { 110 | list-style-type: circle; 111 | margin-left: 25px; 112 | } 113 | 114 | /* Specify class=linenums on a pre to get line numbering */ 115 | ol.linenums { 116 | margin-top: 0; 117 | margin-bottom: 0; } 118 | 119 | /* IE indents via margin-left */ 120 | li.L0, 121 | li.L1, 122 | li.L2, 123 | li.L3, 124 | li.L4, 125 | li.L5, 126 | li.L6, 127 | li.L7, 128 | li.L8, 129 | li.L9 { 130 | /* */ } 131 | 132 | /* Alternate shading for lines */ 133 | li.L1, 134 | li.L3, 135 | li.L5, 136 | li.L7, 137 | li.L9 { 138 | /* */ } 139 | -------------------------------------------------------------------------------- /docs/0.8.0/styles/prettify-tomorrow.css: -------------------------------------------------------------------------------- 1 | /* Tomorrow Theme */ 2 | /* Original theme - https://github.com/chriskempson/tomorrow-theme */ 3 | /* Pretty printing styles. Used with prettify.js. */ 4 | /* SPAN elements with the classes below are added by prettyprint. */ 5 | /* plain text */ 6 | .pln { 7 | color: #4d4d4c; } 8 | 9 | @media screen { 10 | /* string content */ 11 | .str { 12 | color: hsl(104, 100%, 24%); } 13 | 14 | /* a keyword */ 15 | .kwd { 16 | color: hsl(240, 100%, 50%); } 17 | 18 | /* a comment */ 19 | .com { 20 | color: hsl(0, 0%, 60%); } 21 | 22 | /* a type name */ 23 | .typ { 24 | color: hsl(240, 100%, 32%); } 25 | 26 | /* a literal value */ 27 | .lit { 28 | color: hsl(240, 100%, 40%); } 29 | 30 | /* punctuation */ 31 | .pun { 32 | color: #000000; } 33 | 34 | /* lisp open bracket */ 35 | .opn { 36 | color: #000000; } 37 | 38 | /* lisp close bracket */ 39 | .clo { 40 | color: #000000; } 41 | 42 | /* a markup tag name */ 43 | .tag { 44 | color: #c82829; } 45 | 46 | /* a markup attribute name */ 47 | .atn { 48 | color: #f5871f; } 49 | 50 | /* a markup attribute value */ 51 | .atv { 52 | color: #3e999f; } 53 | 54 | /* a declaration */ 55 | .dec { 56 | color: #f5871f; } 57 | 58 | /* a variable name */ 59 | .var { 60 | color: #c82829; } 61 | 62 | /* a function name */ 63 | .fun { 64 | color: #4271ae; } } 65 | /* Use higher contrast and text-weight for printable form. */ 66 | @media print, projection { 67 | .str { 68 | color: #060; } 69 | 70 | .kwd { 71 | color: #006; 72 | font-weight: bold; } 73 | 74 | .com { 75 | color: #600; 76 | font-style: italic; } 77 | 78 | .typ { 79 | color: #404; 80 | font-weight: bold; } 81 | 82 | .lit { 83 | color: #044; } 84 | 85 | .pun, .opn, .clo { 86 | color: #440; } 87 | 88 | .tag { 89 | color: #006; 90 | font-weight: bold; } 91 | 92 | .atn { 93 | color: #404; } 94 | 95 | .atv { 96 | color: #060; } } 97 | /* Style */ 98 | /* 99 | pre.prettyprint { 100 | background: white; 101 | font-family: Consolas, Monaco, 'Andale Mono', monospace; 102 | font-size: 12px; 103 | line-height: 1.5; 104 | border: 1px solid #ccc; 105 | padding: 10px; } 106 | */ 107 | 108 | /* Get LI elements to show when they are in the main article */ 109 | article ul li { 110 | list-style-type: circle; 111 | margin-left: 25px; 112 | } 113 | 114 | /* Specify class=linenums on a pre to get line numbering */ 115 | ol.linenums { 116 | margin-top: 0; 117 | margin-bottom: 0; } 118 | 119 | /* IE indents via margin-left */ 120 | li.L0, 121 | li.L1, 122 | li.L2, 123 | li.L3, 124 | li.L4, 125 | li.L5, 126 | li.L6, 127 | li.L7, 128 | li.L8, 129 | li.L9 { 130 | /* */ } 131 | 132 | /* Alternate shading for lines */ 133 | li.L1, 134 | li.L3, 135 | li.L5, 136 | li.L7, 137 | li.L9 { 138 | /* */ } 139 | -------------------------------------------------------------------------------- /docs/master/styles/prettify-tomorrow.css: -------------------------------------------------------------------------------- 1 | /* Tomorrow Theme */ 2 | /* Original theme - https://github.com/chriskempson/tomorrow-theme */ 3 | /* Pretty printing styles. Used with prettify.js. */ 4 | /* SPAN elements with the classes below are added by prettyprint. */ 5 | /* plain text */ 6 | .pln { 7 | color: #4d4d4c; } 8 | 9 | @media screen { 10 | /* string content */ 11 | .str { 12 | color: hsl(104, 100%, 24%); } 13 | 14 | /* a keyword */ 15 | .kwd { 16 | color: hsl(240, 100%, 50%); } 17 | 18 | /* a comment */ 19 | .com { 20 | color: hsl(0, 0%, 60%); } 21 | 22 | /* a type name */ 23 | .typ { 24 | color: hsl(240, 100%, 32%); } 25 | 26 | /* a literal value */ 27 | .lit { 28 | color: hsl(240, 100%, 40%); } 29 | 30 | /* punctuation */ 31 | .pun { 32 | color: #000000; } 33 | 34 | /* lisp open bracket */ 35 | .opn { 36 | color: #000000; } 37 | 38 | /* lisp close bracket */ 39 | .clo { 40 | color: #000000; } 41 | 42 | /* a markup tag name */ 43 | .tag { 44 | color: #c82829; } 45 | 46 | /* a markup attribute name */ 47 | .atn { 48 | color: #f5871f; } 49 | 50 | /* a markup attribute value */ 51 | .atv { 52 | color: #3e999f; } 53 | 54 | /* a declaration */ 55 | .dec { 56 | color: #f5871f; } 57 | 58 | /* a variable name */ 59 | .var { 60 | color: #c82829; } 61 | 62 | /* a function name */ 63 | .fun { 64 | color: #4271ae; } } 65 | /* Use higher contrast and text-weight for printable form. */ 66 | @media print, projection { 67 | .str { 68 | color: #060; } 69 | 70 | .kwd { 71 | color: #006; 72 | font-weight: bold; } 73 | 74 | .com { 75 | color: #600; 76 | font-style: italic; } 77 | 78 | .typ { 79 | color: #404; 80 | font-weight: bold; } 81 | 82 | .lit { 83 | color: #044; } 84 | 85 | .pun, .opn, .clo { 86 | color: #440; } 87 | 88 | .tag { 89 | color: #006; 90 | font-weight: bold; } 91 | 92 | .atn { 93 | color: #404; } 94 | 95 | .atv { 96 | color: #060; } } 97 | /* Style */ 98 | /* 99 | pre.prettyprint { 100 | background: white; 101 | font-family: Consolas, Monaco, 'Andale Mono', monospace; 102 | font-size: 12px; 103 | line-height: 1.5; 104 | border: 1px solid #ccc; 105 | padding: 10px; } 106 | */ 107 | 108 | /* Get LI elements to show when they are in the main article */ 109 | article ul li { 110 | list-style-type: circle; 111 | margin-left: 25px; 112 | } 113 | 114 | /* Specify class=linenums on a pre to get line numbering */ 115 | ol.linenums { 116 | margin-top: 0; 117 | margin-bottom: 0; } 118 | 119 | /* IE indents via margin-left */ 120 | li.L0, 121 | li.L1, 122 | li.L2, 123 | li.L3, 124 | li.L4, 125 | li.L5, 126 | li.L6, 127 | li.L7, 128 | li.L8, 129 | li.L9 { 130 | /* */ } 131 | 132 | /* Alternate shading for lines */ 133 | li.L1, 134 | li.L3, 135 | li.L5, 136 | li.L7, 137 | li.L9 { 138 | /* */ } 139 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Forge Viewer Utils 2 | 3 | Collection of helpful tools for [Autodesk Forge Viewer](https://forge.autodesk.com/en/docs/viewer) 4 | that are not (yet) part of its official [API](https://forge.autodesk.com/en/docs/viewer/v6/reference/javascript/viewer3d). 5 | 6 | ## Why? 7 | 8 | During [Forge Accelerator](http://autodeskcloudaccelerator.com) events, there are often recurring themes 9 | of features that the attendees want to build, for example, finding a scene object under the mouse cursor, 10 | or being able to change the transform of an object. Unfortunately, many of these features cannot be built 11 | using the official [APIs](https://forge.autodesk.com/en/docs/viewer/v6/reference/javascript/viewer3d), 12 | sending developers into the dreaded, undocumented area of internal APIs, also known as `viewer.impl`. 13 | 14 | The goal of this wrapper library is to: 15 | - provide best practice examples of using the official APIs 16 | - show how commonly requested features can be implemented, for now, using `viewer.impl` 17 | - provide more documentation to both the official and the `viewer.impl` APIs 18 | - collect feedback for the [Forge Viewer](https://forge.autodesk.com/en/docs/viewer) dev team 19 | 20 | ## Usage 21 | 22 | Drop the library in your webpage. You can either use the latest `master` version: 23 | 24 | ```html 25 | 26 | ``` 27 | 28 | Or a specific tagged version, for example `v0.7.0`: 29 | 30 | ```html 31 | 32 | ``` 33 | 34 | > Similarly, the documentation is available both for the latest [master](https://petrbroz.github.io/forge-viewer-utils/master/index.html) 35 | > version and for all tagged versions, for example, [0.7.0](https://petrbroz.github.io/forge-viewer-utils/0.7.0/index.html). 36 | 37 | Start using the `Autodesk.Viewing.Utilities` class, either by wrapping an existing instance 38 | of [Viewer3D](https://forge.autodesk.com/en/docs/viewer/v6/reference/javascript/viewer3d): 39 | 40 | ```js 41 | const utils = new Autodesk.Viewing.Utilities(viewer3d); 42 | utils.load("your-urn"); 43 | ``` 44 | 45 | Or by initializing everything using the static method `Autodesk.Viewing.Utilities.Initialize`: 46 | 47 | ```html 48 |
49 | 66 | ``` 67 | 68 | ## Development 69 | 70 | - install dependencies: `npm install` 71 | - build code documentation: `npm run build:docs` 72 | - running the examples 73 | - you need two things: Forge app _credentials_, and an _urn_ of a model to view 74 | - you can create a free Forge app at https://forge.autodesk.com 75 | - to upload and translate a model for viewing, see the official [tutorial](https://forge.autodesk.com/en/docs/model-derivative/v2/tutorials/prepare-file-for-viewer) 76 | - run the example server with your Forge credentials: 77 | `FORGE_CLIENT_ID= FORGE_CLIENT_SECRET= node examples/server.js` 78 | - open one of the example html files with an urn of your model as a url query, 79 | for example: http://localhost:3000/basic.html?dXyabcdefgh 80 | -------------------------------------------------------------------------------- /docs/0.7.0/Autodesk.Viewing.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Viewing - Documentation 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 52 | 53 | 54 | 55 |
56 | 83 |
84 | 85 | 101 | 102 |
103 | 104 |

105 | Viewing 106 |

107 | 108 | 109 | 110 | 111 |
112 |
113 | 114 |

115 | 116 | Viewing 117 | 118 |

119 | 120 | 121 | 122 |
123 | 124 |
125 |
126 | 127 | 128 |
129 |

Wrapper for Viewer3D 130 | with a collection of helpful methods that are not (yet) part of the official API.

131 |
132 | 133 | 134 | 135 | 136 |
137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 |
Source:
164 |
165 | 170 |
171 | 172 | 173 | 174 | 175 | 176 | 177 | 178 |
179 | 180 | 181 | 182 | 183 |
184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | 201 | 202 |
203 |
204 | 205 | 206 | 207 | 208 |
209 | 210 |
211 | 212 | 215 | 216 | 217 | 218 | 219 | 220 | 233 | 234 | 235 | 236 | -------------------------------------------------------------------------------- /docs/0.8.0/Autodesk.Viewing.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Viewing - Documentation 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 52 | 53 | 54 | 55 |
56 | 83 |
84 | 85 | 101 | 102 |
103 | 104 |

105 | Viewing 106 |

107 | 108 | 109 | 110 | 111 |
112 |
113 | 114 |

115 | 116 | Viewing 117 | 118 |

119 | 120 | 121 | 122 |
123 | 124 |
125 |
126 | 127 | 128 |
129 |

Wrapper for Viewer3D 130 | with a collection of helpful methods that are not (yet) part of the official API.

131 |
132 | 133 | 134 | 135 | 136 |
137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 |
Source:
164 |
165 | 170 |
171 | 172 | 173 | 174 | 175 | 176 | 177 | 178 |
179 | 180 | 181 | 182 | 183 |
184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | 201 | 202 |
203 |
204 | 205 | 206 | 207 | 208 |
209 | 210 |
211 | 212 | 215 | 216 | 217 | 218 | 219 | 220 | 233 | 234 | 235 | 236 | -------------------------------------------------------------------------------- /docs/master/Autodesk.Viewing.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Viewing - Documentation 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 52 | 53 | 54 | 55 |
56 | 83 |
84 | 85 | 101 | 102 |
103 | 104 |

105 | Viewing 106 |

107 | 108 | 109 | 110 | 111 |
112 |
113 | 114 |

115 | 116 | Viewing 117 | 118 |

119 | 120 | 121 | 122 |
123 | 124 |
125 |
126 | 127 | 128 |
129 |

Wrapper for Viewer3D 130 | with a collection of helpful methods that are not (yet) part of the official API.

131 |
132 | 133 | 134 | 135 | 136 |
137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 |
Source:
164 |
165 | 170 |
171 | 172 | 173 | 174 | 175 | 176 | 177 | 178 |
179 | 180 | 181 | 182 | 183 |
184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | 201 | 202 |
203 |
204 | 205 | 206 | 207 | 208 |
209 | 210 |
211 | 212 | 215 | 216 | 217 | 218 | 219 | 220 | 233 | 234 | 235 | 236 | -------------------------------------------------------------------------------- /docs/0.7.0/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Home - Documentation 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 52 | 53 | 54 | 55 |
56 | 83 |
84 | 85 | 101 | 102 |
103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 |
116 |
117 |

Forge Viewer Utils

Collection of helpful tools for Autodesk Forge Viewer 118 | that are not (yet) part of its official API.

119 |

Why?

During Forge Accelerator events, there are often recurring themes 120 | of features that the attendees want to build, for example, finding a scene object under the mouse cursor, 121 | or being able to change the transform of an object. Unfortunately, many of these features cannot be built 122 | using the official APIs, 123 | sending developers into the dreaded, undocumented area of internal APIs, also known as viewer.impl.

124 |

The goal of this wrapper library is to:

125 |
    126 |
  • provide best practice examples of using the official APIs
  • 127 |
  • show how commonly requested features can be implemented, for now, using viewer.impl
  • 128 |
  • provide more documentation to both the official and the viewer.impl APIs
  • 129 |
  • collect feedback for the Forge Viewer dev team
  • 130 |
131 |

Usage

Drop the library in your webpage. You can either use the latest master version:

132 |
<script src="https://petrbroz.github.io/forge-viewer-utils/master/Utilities.js"></script>

Or a specific tagged version, for example v0.7.0:

133 |
<script src="https://petrbroz.github.io/forge-viewer-utils/0.7.0/Utilities.js"></script>
134 |

Similarly, the documentation is available both for the latest master 135 | version and for all tagged versions, for example, 0.7.0.

136 |
137 |

Start using the Autodesk.Viewing.Utilities class, either by wrapping an existing instance 138 | of Viewer3D:

139 |
const utils = new Autodesk.Viewing.Utilities(viewer3d);
140 | utils.load("your-urn");

Or by initializing everything using the static method Autodesk.Viewing.Utilities.Initialize:

141 |
<div id="viewer"></div>
142 | <script>
143 |   async function getAccessToken(callback) {
144 |       const resp = await fetch('/api/auth');
145 |       const json = await resp.json();
146 |       callback(json.access_token, json.expires_in);
147 |   }
148 |   async function run() {
149 |       try {
150 |           const utils = await Autodesk.Viewing.Utilities.Initialize(document.getElementById('viewer'), getAccessToken);
151 |           const viewable = await utils.load("your-urn");
152 |           console.log('Viewable loaded successfully', viewable);
153 |       } catch(err) {
154 |           console.error(err);
155 |       }
156 |   }
157 |   run();
158 | </script>

Development

    159 |
  • install dependencies: npm install
  • 160 |
  • build code documentation: npm run build:docs
  • 161 |
  • running the examples
      162 |
    • you need two things: Forge app credentials, and an urn of a model to view
        163 |
      • you can create a free Forge app at https://forge.autodesk.com
      • 164 |
      • to upload and translate a model for viewing, see the official tutorial
      • 165 |
      166 |
    • 167 |
    • run the example server with your Forge credentials: 168 | FORGE_CLIENT_ID=<client_id> FORGE_CLIENT_SECRET=<client_secret> node examples/server.js
    • 169 |
    • open one of the example html files with an urn of your model as a url query, 170 | for example: http://localhost:3000/basic.html?dXyabcdefgh
    • 171 |
    172 |
  • 173 |
174 |
175 |
176 | 177 | 178 | 179 | 180 | 181 |
182 | 183 |
184 | 185 | 188 | 189 | 190 | 191 | 192 | 193 | 206 | 207 | 208 | 209 | -------------------------------------------------------------------------------- /docs/0.8.0/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Home - Documentation 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 52 | 53 | 54 | 55 |
56 | 83 |
84 | 85 | 101 | 102 |
103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 |
116 |
117 |

Forge Viewer Utils

118 |

Collection of helpful tools for Autodesk Forge Viewer 119 | that are not (yet) part of its official API.

120 |

Why?

121 |

During Forge Accelerator events, there are often recurring themes 122 | of features that the attendees want to build, for example, finding a scene object under the mouse cursor, 123 | or being able to change the transform of an object. Unfortunately, many of these features cannot be built 124 | using the official APIs, 125 | sending developers into the dreaded, undocumented area of internal APIs, also known as viewer.impl.

126 |

The goal of this wrapper library is to:

127 |
    128 |
  • provide best practice examples of using the official APIs
  • 129 |
  • show how commonly requested features can be implemented, for now, using viewer.impl
  • 130 |
  • provide more documentation to both the official and the viewer.impl APIs
  • 131 |
  • collect feedback for the Forge Viewer dev team
  • 132 |
133 |

Usage

134 |

Drop the library in your webpage. You can either use the latest master version:

135 |
<script src="https://petrbroz.github.io/forge-viewer-utils/master/Utilities.js"></script>
136 | 
137 |

Or a specific tagged version, for example v0.7.0:

138 |
<script src="https://petrbroz.github.io/forge-viewer-utils/0.7.0/Utilities.js"></script>
139 | 
140 |
141 |

Similarly, the documentation is available both for the latest master 142 | version and for all tagged versions, for example, 0.7.0.

143 |
144 |

Start using the Autodesk.Viewing.Utilities class, either by wrapping an existing instance 145 | of Viewer3D:

146 |
const utils = new Autodesk.Viewing.Utilities(viewer3d);
147 | utils.load("your-urn");
148 | 
149 |

Or by initializing everything using the static method Autodesk.Viewing.Utilities.Initialize:

150 |
<div id="viewer"></div>
151 | <script>
152 |   async function getAccessToken(callback) {
153 |       const resp = await fetch('/api/auth');
154 |       const json = await resp.json();
155 |       callback(json.access_token, json.expires_in);
156 |   }
157 |   async function run() {
158 |       try {
159 |           const utils = await Autodesk.Viewing.Utilities.Initialize(document.getElementById('viewer'), getAccessToken);
160 |           const viewable = await utils.load("your-urn");
161 |           console.log('Viewable loaded successfully', viewable);
162 |       } catch(err) {
163 |           console.error(err);
164 |       }
165 |   }
166 |   run();
167 | </script>
168 | 
169 |

Development

170 |
    171 |
  • install dependencies: npm install
  • 172 |
  • build code documentation: npm run build:docs
  • 173 |
  • running the examples 174 |
      175 |
    • you need two things: Forge app credentials, and an urn of a model to view 176 |
        177 |
      • you can create a free Forge app at https://forge.autodesk.com
      • 178 |
      • to upload and translate a model for viewing, see the official tutorial
      • 179 |
      180 |
    • 181 |
    • run the example server with your Forge credentials: 182 | FORGE_CLIENT_ID=<client_id> FORGE_CLIENT_SECRET=<client_secret> node examples/server.js
    • 183 |
    • open one of the example html files with an urn of your model as a url query, 184 | for example: http://localhost:3000/basic.html?dXyabcdefgh
    • 185 |
    186 |
  • 187 |
188 |
189 |
190 | 191 | 192 | 193 | 194 | 195 |
196 | 197 |
198 | 199 | 202 | 203 | 204 | 205 | 206 | 207 | 220 | 221 | 222 | 223 | -------------------------------------------------------------------------------- /docs/master/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Home - Documentation 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 52 | 53 | 54 | 55 |
56 | 83 |
84 | 85 | 101 | 102 |
103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 |
116 |
117 |

Forge Viewer Utils

118 |

Collection of helpful tools for Autodesk Forge Viewer 119 | that are not (yet) part of its official API.

120 |

Why?

121 |

During Forge Accelerator events, there are often recurring themes 122 | of features that the attendees want to build, for example, finding a scene object under the mouse cursor, 123 | or being able to change the transform of an object. Unfortunately, many of these features cannot be built 124 | using the official APIs, 125 | sending developers into the dreaded, undocumented area of internal APIs, also known as viewer.impl.

126 |

The goal of this wrapper library is to:

127 |
    128 |
  • provide best practice examples of using the official APIs
  • 129 |
  • show how commonly requested features can be implemented, for now, using viewer.impl
  • 130 |
  • provide more documentation to both the official and the viewer.impl APIs
  • 131 |
  • collect feedback for the Forge Viewer dev team
  • 132 |
133 |

Usage

134 |

Drop the library in your webpage. You can either use the latest master version:

135 |
<script src="https://petrbroz.github.io/forge-viewer-utils/master/Utilities.js"></script>
136 | 
137 |

Or a specific tagged version, for example v0.7.0:

138 |
<script src="https://petrbroz.github.io/forge-viewer-utils/0.7.0/Utilities.js"></script>
139 | 
140 |
141 |

Similarly, the documentation is available both for the latest master 142 | version and for all tagged versions, for example, 0.7.0.

143 |
144 |

Start using the Autodesk.Viewing.Utilities class, either by wrapping an existing instance 145 | of Viewer3D:

146 |
const utils = new Autodesk.Viewing.Utilities(viewer3d);
147 | utils.load("your-urn");
148 | 
149 |

Or by initializing everything using the static method Autodesk.Viewing.Utilities.Initialize:

150 |
<div id="viewer"></div>
151 | <script>
152 |   async function getAccessToken(callback) {
153 |       const resp = await fetch('/api/auth');
154 |       const json = await resp.json();
155 |       callback(json.access_token, json.expires_in);
156 |   }
157 |   async function run() {
158 |       try {
159 |           const utils = await Autodesk.Viewing.Utilities.Initialize(document.getElementById('viewer'), getAccessToken);
160 |           const viewable = await utils.load("your-urn");
161 |           console.log('Viewable loaded successfully', viewable);
162 |       } catch(err) {
163 |           console.error(err);
164 |       }
165 |   }
166 |   run();
167 | </script>
168 | 
169 |

Development

170 |
    171 |
  • install dependencies: npm install
  • 172 |
  • build code documentation: npm run build:docs
  • 173 |
  • running the examples 174 |
      175 |
    • you need two things: Forge app credentials, and an urn of a model to view 176 |
        177 |
      • you can create a free Forge app at https://forge.autodesk.com
      • 178 |
      • to upload and translate a model for viewing, see the official tutorial
      • 179 |
      180 |
    • 181 |
    • run the example server with your Forge credentials: 182 | FORGE_CLIENT_ID=<client_id> FORGE_CLIENT_SECRET=<client_secret> node examples/server.js
    • 183 |
    • open one of the example html files with an urn of your model as a url query, 184 | for example: http://localhost:3000/basic.html?dXyabcdefgh
    • 185 |
    186 |
  • 187 |
188 |
189 |
190 | 191 | 192 | 193 | 194 | 195 |
196 | 197 |
198 | 199 | 202 | 203 | 204 | 205 | 206 | 207 | 220 | 221 | 222 | 223 | -------------------------------------------------------------------------------- /docs/0.7.0/Utilities.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Wrapper for {@link https://forge.autodesk.com/en/docs/viewer/v6/reference/javascript/viewer3d|Viewer3D} 3 | * with a collection of helpful methods that are not (yet) part of the official API. 4 | * @namespace Autodesk.Viewing 5 | */ 6 | class Utilities { 7 | 8 | /** 9 | * Callback function used to report access token to the viewer. 10 | * @callback AccessTokenCallback 11 | * @param {string} token Access token. 12 | * @param {int} expires Number of seconds after which the token expires. 13 | */ 14 | 15 | /** 16 | * Callback function used by the viewer to request new access token. 17 | * @callback AccessTokenRequest 18 | * @param {AccessTokenCallback} callback Access token callback. 19 | */ 20 | 21 | /** 22 | * Initializes new instance of {@link Utilities}, including the initialization 23 | * of the underlying {@link https://forge.autodesk.com/en/docs/viewer/v6/reference/javascript/viewer3d|Viewer3D}. 24 | * @param {HTMLElement} container Target container for the viewer canvas. 25 | * @param {AccessTokenRequest} getAccessToken Function that will be called by the viewer 26 | * whenever a new access token is required. 27 | * @returns {Promise} Promise that will be either resolved with {@link Utilities} instance, 28 | * or rejected with an error message. 29 | * 30 | * @example Using Promises 31 | * function getAccessToken(callback) { 32 | * fetch('/api/forge/auth/token') 33 | * .then(resp => resp.json()) 34 | * .then(json => callback(json.access_token, json.expires_in)); 35 | * } 36 | * Autodesk.Viewing.Utilities.Initialize(document.getElementById('viewer'), getAccessToken) 37 | * .then(utils => console.log(utils)); 38 | * 39 | * @example Using Async/Await 40 | * async function getAccessToken(callback) { 41 | * const resp = await fetch('/api/forge/auth/token'); 42 | * const json = await resp.json(); 43 | * callback(json.access_token, json.expires_in); 44 | * } 45 | * async function init() { 46 | * const utils = await Autodesk.Viewing.Utilities.Initialize(document.getElementById('viewer'), getAccessToken); 47 | * console.log(utils); 48 | * } 49 | * init(); 50 | */ 51 | static Initialize(container, getAccessToken) { 52 | return new Promise(function(resolve, reject) { 53 | const options = { 54 | getAccessToken 55 | }; 56 | Autodesk.Viewing.Initializer(options, function() { 57 | const viewer = new Autodesk.Viewing.Private.GuiViewer3D(container); 58 | viewer.start(); 59 | resolve(new Autodesk.Viewing.Utilities(viewer)); 60 | }); 61 | }); 62 | } 63 | 64 | /** 65 | * Initializes {@link Utilities} with existing instance 66 | * of {@link https://forge.autodesk.com/en/docs/viewer/v6/reference/javascript/viewer3d|Viewer3D}. 67 | * @param {Viewer3D} viewer Forge viewer. 68 | */ 69 | constructor(viewer) { 70 | this.viewer = viewer; 71 | this.impl = viewer.impl; 72 | } 73 | 74 | /** 75 | * Viewable, also referred to as "bubble node", is a singular viewable 76 | * item from a document that has been generated by {@link https://forge.autodesk.com/en/docs/model-derivative/v2|Model Derivative API}. 77 | * For example, submitting a Revit file into the service will generate 78 | * a single document identified by its unique, base-64 encoded *urn*, 79 | * and the document will include a hierarchy of various *viewables* such 80 | * as thumbnails, 3D scenes for individual camera views, or 2D scenes 81 | * for individual Revit sheets. 82 | * @typedef {object} Viewable 83 | * @property {Viewable} parent Parent of the viewable in the document hierarchy. 84 | * @property {Viewable[]} children Children of the viewable in the document hierarchy. 85 | * @property {number} id Internal viewable ID. 86 | * @property {boolean} isLeaf Indicates that the viewable has no children. 87 | * @property {object} data Additional viewable properties such as *guid* (unique, string identifier), 88 | * *name*, *role*, *type*, etc. 89 | */ 90 | 91 | /** 92 | * Loads {@link Viewable} into the viewer. 93 | * @param {string} documentUrn Base64-encoded identifier of the document. 94 | * @param {string|number} [viewableId=0] Optional GUID (string) or index (number) of the viewable within the document. 95 | * @returns {Promise} Promise that will be either resolved with {@link Viewable} structure, 96 | * or rejected with an error message. 97 | * 98 | * @example 99 | * async function loadDocument(urn) { 100 | * const viewable = await utils.load(urn); 101 | * console.log('Loaded viewable', viewable.data.id); 102 | * } 103 | */ 104 | load(documentUrn, viewableId = 0) { 105 | const viewer = this.viewer; 106 | return new Promise(function(resolve, reject) { 107 | function onDocumentLoadSuccess(doc) { 108 | if (typeof viewableId === 'string') { 109 | const viewable = doc.getRoot().findByGuid(viewableId); 110 | if (viewable) { 111 | viewer.loadDocumentNode(doc, viewable); 112 | resolve(viewable); 113 | } else { 114 | reject(`Viewable ${viewableId} not found.`); 115 | } 116 | } else { 117 | const viewables = doc.getRoot().search({ type: 'geometry' }); 118 | if (viewableId < viewables.length) { 119 | const viewable = viewables[viewableId]; 120 | viewer.loadDocumentNode(doc, viewable); 121 | resolve(viewable); 122 | } else { 123 | reject(`Viewable ${viewableId} not found.`); 124 | } 125 | } 126 | } 127 | function onDocumentLoadError(errorCode, errorMsg) { 128 | reject(`Document loading error: ${errorMsg} (${errorCode})`); 129 | } 130 | Autodesk.Viewing.Document.load('urn:' + documentUrn, onDocumentLoadSuccess, onDocumentLoadError); 131 | }); 132 | } 133 | 134 | /** 135 | * Object returned by ray casting methods for each scene object under the given canvas coordinates. 136 | * @typedef {object} Intersection 137 | * @property {number} dbId Internal ID of the scene object. 138 | * @property {number} distance Distance of the intersection point from camera. All intersections 139 | * returned by the ray casting method are sorted from the smallest distance to the largest. 140 | * @property {THREE.Face3} face {@link https://threejs.org/docs/#api/en/core/Face3|Face3} object 141 | * representing the triangular mesh face that has been intersected. 142 | * @property {number} faceIndex Index of the intersected face, if available. 143 | * @property {number} fragId ID of Forge Viewer *fragment* that was intersected. 144 | * @property {THREE.Vector3} intersectPoint {@link https://threejs.org/docs/#api/en/core/Vector3|Vector3} point of intersection. 145 | * @property {THREE.Vector3} point Same as *intersectPoint*. 146 | * @property {Model} model Forge Viewer {@link https://forge.autodesk.com/en/docs/viewer/v6/reference/javascript/model|Model} that was intersected. 147 | */ 148 | 149 | /** 150 | * Finds all scene objects on specific X,Y position on the canvas. 151 | * @param {number} x X-coordinate, i.e., horizontal distance (in pixels) from the left border of the canvas. 152 | * @param {number} y Y-coordinate, i.e., vertical distance (in pixels) from the top border of the canvas. 153 | * @returns {Intersection[]} List of intersections. 154 | * 155 | * @example 156 | * document.getElementById('viewer').addEventListener('click', function(ev) { 157 | * const bounds = ev.target.getBoundingClientRect(); 158 | * const intersections = utils.rayCast(ev.clientX - bounds.left, ev.clientY - bounds.top); 159 | * if (intersections.length > 0) { 160 | * console.log('hit', intersections[0]); 161 | * } else { 162 | * console.log('miss'); 163 | * } 164 | * }); 165 | */ 166 | rayCast(x, y) { 167 | let intersections = []; 168 | this.impl.castRayViewport(this.impl.clientToViewport(x, y), false, null, null, intersections); 169 | return intersections; 170 | } 171 | 172 | /** 173 | * Inserts custom {@link https://threejs.org/docs/#api/en/objects/Mesh|Mesh} into 174 | * *overlay* scene of given name. An overlay scene is always rendered *after* 175 | * the main scene with the Forge Viewer model. 176 | * @param {THREE.Mesh} mesh Custom {@link https://threejs.org/docs/#api/en/objects/Mesh|Mesh}. 177 | * @param {string} [overlay='UtilitiesOverlay'] Name of the overlay scene. 178 | * 179 | * @example 180 | * const geometry = new THREE.SphereGeometry(10, 8, 8); 181 | * const material = new THREE.MeshBasicMaterial({ color: 0x336699 }); 182 | * const mesh = new THREE.Mesh(geometry, material); 183 | * mesh.position.x = 1.0; mesh.position.y = 2.0; mesh.position.z = 3.0; 184 | * utils.addCustomMesh(mesh, 'myOverlay'); 185 | */ 186 | addCustomMesh(mesh, overlay = 'UtilitiesOverlay') { 187 | if (!this.impl.overlayScenes[overlay]) { 188 | this.impl.createOverlayScene(overlay); 189 | } 190 | this.impl.addOverlay(overlay, mesh); 191 | } 192 | 193 | /** 194 | * Removes custom {@link https://threejs.org/docs/#api/en/objects/Mesh|Mesh} from 195 | * *overlay* scene of given name. An overlay scene is always rendered *after* 196 | * the main scene with the Forge Viewer model. 197 | * @param {THREE.Mesh} mesh {@link https://threejs.org/docs/#api/en/objects/Mesh|Mesh} to be removed. 198 | * @param {string} [overlay='UtilitiesOverlay'] Name of the overlay scene. 199 | * 200 | * @example 201 | * // after adding a mesh using addCustomMesh 202 | * utils.removeCustomMesh(mesh, 'myOverlay'); 203 | */ 204 | removeCustomMesh(mesh, overlay = 'UtilitiesOverlay') { 205 | if (!this.impl.overlayScenes[overlay]) { 206 | this.impl.createOverlayScene(overlay); 207 | } 208 | this.impl.removeOverlay(overlay, mesh); 209 | } 210 | 211 | /** 212 | * Callback function used when enumerating scene nodes. 213 | * @callback NodeCallback 214 | * @param {number} id Node ID. 215 | */ 216 | 217 | /** 218 | * Enumerates all nodes in the viewer scene. 219 | * Can only be called after the object tree has been loaded. 220 | * @param {NodeCallback} callback Function called for each node. 221 | * @param {number?} [parent = undefined] ID of the parent node whose children 222 | * should be enumerated. If undefined, the enumeration includes all scene nodes. 223 | * @throws Exception when the object tree is not yet available. 224 | * 225 | * @example 226 | * viewer.addEventListener(Autodesk.Viewing.OBJECT_TREE_CREATED_EVENT, function() { 227 | * try { 228 | * utils.enumerateNodes(function(id) { 229 | * console.log('Found node', id); 230 | * }); 231 | * } catch(err) { 232 | * console.error('Could not enumerate nodes', err); 233 | * } 234 | * }); 235 | */ 236 | enumerateNodes(callback, parent = undefined) { 237 | function onSuccess(tree) { 238 | if (typeof parent === 'undefined') { 239 | parent = tree.getRootId(); 240 | } 241 | tree.enumNodeChildren(parent, callback, true); 242 | } 243 | function onError(err) { throw new Error(err); } 244 | this.viewer.getObjectTree(onSuccess, onError); 245 | } 246 | 247 | /** 248 | * Enumerates leaf nodes in the viewer scene. 249 | * Can only be called after the object tree has been loaded. 250 | * @param {NodeCallback} callback Function called for each node. 251 | * @param {number?} [parent = undefined] ID of the parent node whose children 252 | * should be enumerated. If undefined, the enumeration includes all scene nodes. 253 | * @throws Exception when the object tree is not yet available. 254 | * 255 | * @example 256 | * viewer.addEventListener(Autodesk.Viewing.OBJECT_TREE_CREATED_EVENT, function() { 257 | * try { 258 | * utils.enumerateLeafNodes(function(id) { 259 | * console.log('Found leaf node', id); 260 | * }); 261 | * } catch(err) { 262 | * console.error('Could not enumerate nodes', err); 263 | * } 264 | * }); 265 | */ 266 | enumerateLeafNodes(callback, parent = undefined) { 267 | let tree = null; 268 | function onNode(id) { if (tree.getChildCount(id) === 0) callback(id); } 269 | function onSuccess(_tree) { 270 | tree = _tree; 271 | if (typeof parent === 'undefined') { 272 | parent = tree.getRootId(); 273 | } 274 | tree.enumNodeChildren(parent, onNode, true); 275 | } 276 | function onError(err) { throw new Error(err); } 277 | this.viewer.getObjectTree(onSuccess, onError); 278 | } 279 | 280 | /** 281 | * Callback function used when enumerating scene fragments. 282 | * @callback FragmentCallback 283 | * @param {number} id Fragment ID. 284 | */ 285 | 286 | /** 287 | * Enumerates fragments of specific node or entire scene. 288 | * Can only be called after the object tree has been loaded. 289 | * @param {FragmentCallback} callback Function called for each fragment. 290 | * @param {number?} [parent = undefined] ID of the parent node whose fragments 291 | * should be enumerated. If undefined, the enumeration includes all scene fragments. 292 | * @throws Exception when the object tree is not yet available. 293 | * 294 | * @example 295 | * viewer.addEventListener(Autodesk.Viewing.OBJECT_TREE_CREATED_EVENT, function() { 296 | * try { 297 | * utils.enumerateFragments(function(id) { 298 | * console.log('Found fragment', id); 299 | * }); 300 | * } catch(err) { 301 | * console.error('Could not enumerate fragments', err); 302 | * } 303 | * }); 304 | */ 305 | enumerateFragments(callback, parent = undefined) { 306 | function onSuccess(tree) { 307 | if (typeof parent === 'undefined') { 308 | parent = tree.getRootId(); 309 | } 310 | tree.enumNodeFragments(parent, callback, true); 311 | } 312 | function onError(err) { throw new Error(err); } 313 | this.viewer.getObjectTree(onSuccess, onError); 314 | } 315 | 316 | /** 317 | * Gets transformation matrix of scene fragment. 318 | * @param {number} fragId Fragment ID. 319 | * @returns {THREE.Matrix4} Transformation {@link https://threejs.org/docs/#api/en/math/Matrix4|Matrix4}. 320 | * @throws Exception when the fragments are not yet available. 321 | * 322 | * @example 323 | * viewer.addEventListener(Autodesk.Viewing.GEOMETRY_LOADED_EVENT, function() { 324 | * try { 325 | * const transform = utils.getFragmentTransform(1); 326 | * console.log('Fragment transform', transform); 327 | * } catch(err) { 328 | * console.error('Could not retrieve fragment transform', err); 329 | * } 330 | * }); 331 | */ 332 | getFragmentTransform(fragId) { 333 | if (!this.viewer.model) { 334 | throw new Error('Fragments not yet available. Wait for Autodesk.Viewing.FRAGMENTS_LOADED_EVENT event.'); 335 | } 336 | const frags = this.viewer.model.getFragmentList(); 337 | let transform = new THREE.Matrix4(); 338 | frags.getWorldMatrix(fragId, transform); 339 | return transform; 340 | } 341 | 342 | /** 343 | * Gets world bounding box of scene fragment. 344 | * @param {number} fragId Fragment ID. 345 | * @returns {THREE.Box3} Transformation {@link https://threejs.org/docs/#api/en/math/Box3|Box3}. 346 | * @throws Exception when the fragments are not yet available. 347 | * 348 | * @example 349 | * viewer.addEventListener(Autodesk.Viewing.GEOMETRY_LOADED_EVENT, function() { 350 | * try { 351 | * const bounds = utils.getFragmentBounds(1); 352 | * console.log('Fragment bounds', bounds); 353 | * } catch(err) { 354 | * console.error('Could not retrieve fragment bounds', err); 355 | * } 356 | * }); 357 | */ 358 | getFragmentBounds(fragId) { 359 | if (!this.viewer.model) { 360 | throw new Error('Fragments not yet available. Wait for Autodesk.Viewing.FRAGMENTS_LOADED_EVENT event.'); 361 | } 362 | const frags = this.viewer.model.getFragmentList(); 363 | let bounds = new THREE.Box3(); 364 | frags.getWorldBounds(fragId, bounds); 365 | return bounds; 366 | } 367 | } 368 | 369 | Autodesk = Autodesk || {}; 370 | Autodesk.Viewing = Autodesk.Viewing || {}; 371 | Autodesk.Viewing.Utilities = Utilities; 372 | -------------------------------------------------------------------------------- /docs/0.7.0/styles/jsdoc-default.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: "Avenir Next W01"; 3 | font-style: normal; 4 | font-weight: 600; 5 | src: url("https://fast.fonts.net/dv2/14/14c73713-e4df-4dba-933b-057feeac8dd1.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 6 | } 7 | 8 | @font-face { 9 | font-family: "Avenir Next W01"; 10 | font-style: normal; 11 | font-weight: 500; 12 | src: url("https://fast.fonts.net/dv2/14/627fbb5a-3bae-4cd9-b617-2f923e29d55e.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 13 | } 14 | 15 | @font-face { 16 | font-family: "Avenir Next W01"; 17 | font-style: normal; 18 | font-weight: 400; 19 | src: url("https://fast.fonts.net/dv2/14/2cd55546-ec00-4af9-aeca-4a3cd186da53.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 20 | } 21 | 22 | @font-face { 23 | font-family: 'bt_mono'; 24 | font-style: normal; 25 | font-weight: 400; 26 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.eot'); 27 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.svg#bt_mono_reqular-webfont') format('svg'); 28 | } 29 | 30 | @font-face { 31 | font-family: 'bt_mono'; 32 | font-style: normal; 33 | font-weight: 500; 34 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.eot'); 35 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.svg#bt_mono_medium-webfont') format('svg'); 36 | } 37 | 38 | @font-face { 39 | font-family: 'bt_mono'; 40 | font-style: normal; 41 | font-weight: 600; 42 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.eot'); 43 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.svg#bt_mono_bold-webfont') format('svg'); 44 | } 45 | 46 | @font-face { 47 | font-family: 'bt_mono'; 48 | font-style: normal; 49 | font-weight: 900; 50 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.eot'); 51 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.svg#bt_mono_heavy-webfont') format('svg'); 52 | } 53 | 54 | * { 55 | box-sizing: border-box 56 | } 57 | 58 | html, body { 59 | height: 100%; 60 | width: 100%; 61 | -webkit-font-smoothing: antialiased; 62 | -moz-osx-font-smoothing: grayscale; 63 | color: #3e3c42; 64 | text-rendering: optimizeLegibility; 65 | margin: 0; 66 | } 67 | 68 | body { 69 | color: #3e3c42; 70 | background-color: #f3f3f3; 71 | width: 100%; 72 | font: 16px/1.875 "Avenir Next W01", "Avenir Next", "Helvetica Neue", Helvetica, sans-serif; 73 | font-size: 16px; 74 | line-height: 160%; 75 | } 76 | 77 | a, a:active { 78 | color: #0095dd; 79 | text-decoration: none; 80 | } 81 | 82 | a:hover { 83 | text-decoration: underline 84 | } 85 | 86 | p, ul, ol, blockquote { 87 | margin-bottom: 1em; 88 | } 89 | 90 | p { 91 | max-width: 800px; 92 | } 93 | 94 | h1, h2, h3, h4, h5, h6 { 95 | color: #706d77; 96 | font-weight: 500; 97 | margin: 0; 98 | line-height: 1; 99 | } 100 | 101 | h1 { 102 | color: #4b484f; 103 | font-weight: 500; 104 | font-size: 40px; 105 | display: block; 106 | } 107 | 108 | h1 span { 109 | color: #999; 110 | font-size: 32px; 111 | display: block; 112 | line-height: 1.5; 113 | } 114 | 115 | h1.page-title { 116 | border-bottom: 1px dashed #ccc; 117 | margin-bottom: 20px; 118 | padding-bottom: 30px; 119 | } 120 | 121 | h2 { 122 | font-size: 30px; 123 | margin: 1.5em 0 0; 124 | } 125 | 126 | h3 { 127 | font-size: 20px; 128 | margin: 1.5em 0 0; 129 | text-transform: uppercase; 130 | } 131 | 132 | h3.reference-title { 133 | display: block; 134 | font-weight: 400; 135 | margin-top: 2em; 136 | max-width: 200px; 137 | } 138 | 139 | h3.reference-title small { 140 | display: inline-block; 141 | color: #0095dd; 142 | margin-left: 5px; 143 | font-weight: 500; 144 | } 145 | 146 | h3.subsection-title { 147 | border-bottom: 1px solid #ececec; 148 | padding-bottom: 20px; 149 | margin-top: 3em; 150 | margin-bottom: 1em; 151 | } 152 | 153 | h4 { 154 | font-size: 16px; 155 | margin: 1em 0 0; 156 | font-weight: bold; 157 | } 158 | 159 | h4.name { 160 | font-size: 20px; 161 | margin-top: 0; 162 | font-weight: 500; 163 | } 164 | 165 | h5 { 166 | margin: 2em 0 0.5em 0; 167 | font-size: 14px; 168 | font-weight: 500; 169 | text-transform: uppercase; 170 | } 171 | 172 | .container-overview .subsection-title { 173 | font-size: 14px; 174 | text-transform: uppercase; 175 | margin: 8px 0 15px 0; 176 | font-weight: bold; 177 | color: #4D4E53; 178 | padding-top: 10px; 179 | } 180 | 181 | h6 { 182 | font-size: 100%; 183 | letter-spacing: -0.01em; 184 | margin: 6px 0 3px 0; 185 | font-style: italic; 186 | text-transform: uppercase; 187 | font-weight: 500; 188 | } 189 | 190 | tt, code, kbd, samp { 191 | font-family: "Source Code Pro", monospace; 192 | background: #f4f4f4; 193 | padding: 1px 5px; 194 | border-radius: 5px; 195 | } 196 | 197 | .class-description { 198 | margin-bottom: 1em; 199 | margin-top: 1em; 200 | padding: 10px 20px; 201 | background-color: rgba(26, 159, 224, 0.1); 202 | } 203 | 204 | .class-description:empty { 205 | margin: 0 206 | } 207 | 208 | #main { 209 | background-color: white; 210 | float: right; 211 | min-width: 360px; 212 | width: calc(100% - 300px); 213 | padding: 30px; 214 | z-index: 100; 215 | } 216 | 217 | header { 218 | display: block; 219 | max-width: 1400px; 220 | } 221 | 222 | section { 223 | display: block; 224 | max-width: 1400px; 225 | background-color: #fff; 226 | } 227 | 228 | .variation { 229 | display: none 230 | } 231 | 232 | .signature-attributes { 233 | font-size: 60%; 234 | color: #aaa; 235 | font-style: italic; 236 | font-weight: lighter; 237 | } 238 | 239 | .rule { 240 | width: 100%; 241 | margin-top: 20px; 242 | display: block; 243 | border-top: 1px solid #ccc; 244 | } 245 | 246 | ul { 247 | list-style-type: none; 248 | padding-left: 0; 249 | } 250 | 251 | ul li a { 252 | font-weight: 500; 253 | } 254 | 255 | ul ul { 256 | padding-top: 5px; 257 | } 258 | 259 | ul li ul { 260 | padding-left: 20px; 261 | } 262 | 263 | ul li ul li a { 264 | font-weight: normal; 265 | } 266 | 267 | nav { 268 | float: left; 269 | display: block; 270 | width: 300px; 271 | background: #f7f7f7; 272 | overflow-x: visible; 273 | overflow-y: auto; 274 | height: 100%; 275 | padding: 0px 30px 100px 30px; 276 | height: 100%; 277 | position: fixed; 278 | transition: left 0.2s; 279 | z-index: 998; 280 | margin-top: 0px; 281 | top: 43px; 282 | } 283 | 284 | .navicon-button { 285 | display: inline-block; 286 | position: fixed; 287 | bottom: 1.5em; 288 | right: 1.5em; 289 | z-index: 2; 290 | } 291 | 292 | nav h3 { 293 | font-size: 13px; 294 | text-transform: uppercase; 295 | letter-spacing: 1px; 296 | font-weight: bold; 297 | line-height: 24px; 298 | margin: 40px 0 10px 0; 299 | padding: 0; 300 | } 301 | 302 | nav ul { 303 | font-size: 100%; 304 | line-height: 17px; 305 | padding: 0; 306 | margin: 0; 307 | list-style-type: none; 308 | border: none; 309 | padding-left: 0; 310 | } 311 | 312 | nav ul a { 313 | font-size: 16px; 314 | } 315 | 316 | nav ul a, nav ul a:active { 317 | display: block; 318 | } 319 | 320 | nav ul a:hover, nav ul a:active { 321 | color: hsl(200, 100%, 43%); 322 | text-decoration: none; 323 | } 324 | 325 | nav>ul { 326 | padding: 0 10px; 327 | } 328 | 329 | nav>ul li:first-child { 330 | padding-top: 0; 331 | } 332 | 333 | nav ul li ul { 334 | padding-left: 0; 335 | } 336 | 337 | nav>ul>li { 338 | border-bottom: 1px solid #e2e2e2; 339 | padding: 10px 0 20px 0; 340 | } 341 | 342 | nav>ul>li.active ul { 343 | border-left: 3px solid #0095dd; 344 | padding-left: 15px; 345 | } 346 | 347 | nav>ul>li.active ul li.active a { 348 | font-weight: bold; 349 | } 350 | 351 | nav>ul>li.active a { 352 | color: #0095dd; 353 | } 354 | 355 | nav>ul>li>a { 356 | color: #706d77; 357 | padding: 20px 0; 358 | font-size: 18px; 359 | } 360 | 361 | nav ul ul { 362 | margin-bottom: 10px; 363 | padding-left: 0; 364 | } 365 | 366 | nav ul ul a { 367 | color: #5f5c63; 368 | } 369 | 370 | nav ul ul a, nav ul ul a:active { 371 | font-family: 'bt_mono', monospace; 372 | font-size: 14px; 373 | padding-left: 20px; 374 | padding-top: 3px; 375 | padding-bottom: 9px; 376 | } 377 | 378 | nav h2 { 379 | font-size: 12px; 380 | margin: 0; 381 | padding: 0; 382 | } 383 | 384 | nav>h2>a { 385 | color: hsl(202, 71%, 50%); 386 | border-bottom: 1px solid hsl(202, 71%, 50%); 387 | padding-bottom: 5px; 388 | } 389 | 390 | nav>h2>a:hover { 391 | font-weight: 500; 392 | text-decoration: none; 393 | } 394 | 395 | footer { 396 | background-color: #fff; 397 | color: hsl(0, 0%, 28%); 398 | margin-left: 300px; 399 | display: block; 400 | font-style: italic; 401 | font-size: 12px; 402 | padding: 30px; 403 | text-align: center; 404 | } 405 | 406 | .ancestors { 407 | color: #999; 408 | } 409 | 410 | .ancestors a { 411 | color: #999 !important; 412 | text-decoration: none; 413 | } 414 | 415 | .clear { 416 | clear: both; 417 | } 418 | 419 | .important { 420 | font-weight: bold; 421 | color: #950B02; 422 | } 423 | 424 | .yes-def { 425 | text-indent: -1000px; 426 | } 427 | 428 | .type-signature { 429 | color: #aaa; 430 | } 431 | 432 | .name, .signature { 433 | font-family: 'bt_mono', monospace; 434 | word-wrap: break-word; 435 | } 436 | 437 | .details { 438 | margin-top: 14px; 439 | font-size: 13px; 440 | text-align: right; 441 | background: #ffffff; 442 | /* Old browsers */ 443 | background: -moz-linear-gradient(left, #ffffff 0%, #fafafa 100%); 444 | /* FF3.6-15 */ 445 | background: -webkit-linear-gradient(left, #ffffff 0%, #fafafa 100%); 446 | /* Chrome10-25,Safari5.1-6 */ 447 | background: linear-gradient(to right, #ffffff 0%, #fafafa 100%); 448 | /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */ 449 | filter: progid: DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#fafafa', GradientType=1); 450 | padding-right: 5px; 451 | } 452 | 453 | .details dt { 454 | display: inline-block; 455 | } 456 | 457 | .details dd { 458 | display: inline-block; 459 | margin: 0; 460 | } 461 | 462 | .details dd a { 463 | font-style: italic; 464 | font-weight: normal; 465 | line-height: 1; 466 | } 467 | 468 | .details ul { 469 | list-style-type: none; 470 | margin: 0; 471 | } 472 | 473 | .details pre.prettyprint { 474 | margin: 0 475 | } 476 | 477 | .details .object-value { 478 | padding-top: 0 479 | } 480 | 481 | .description { 482 | margin-bottom: 1em; 483 | margin-top: 1em; 484 | } 485 | 486 | .code-caption { 487 | font-style: italic; 488 | margin: 0; 489 | font-size: 16px; 490 | color: #545454; 491 | } 492 | 493 | .prettyprint { 494 | font-size: 13px; 495 | border: 1px solid #ddd; 496 | border-radius: 3px; 497 | overflow: auto; 498 | background-color: #fbfbfb; 499 | } 500 | 501 | .prettyprint.source { 502 | width: inherit; 503 | } 504 | 505 | .prettyprint code { 506 | font-size: 100%; 507 | line-height: 18px; 508 | display: block; 509 | margin: 0 30px; 510 | background-color: #fbfbfb; 511 | color: #4D4E53; 512 | } 513 | 514 | .prettyprint>code { 515 | padding: 30px 15px; 516 | } 517 | 518 | .prettyprint .linenums code { 519 | padding: 0 15px; 520 | } 521 | 522 | .prettyprint .linenums li:first-of-type code { 523 | padding-top: 15px; 524 | } 525 | 526 | .prettyprint code span.line { 527 | display: inline-block; 528 | } 529 | 530 | .prettyprint.linenums { 531 | -webkit-user-select: none; 532 | -moz-user-select: none; 533 | -ms-user-select: none; 534 | user-select: none; 535 | } 536 | 537 | .prettyprint.linenums ol { 538 | padding-left: 0 539 | } 540 | 541 | .prettyprint.linenums li { 542 | border-left: 3px #ddd solid 543 | } 544 | 545 | .prettyprint.linenums li.selected, .prettyprint.linenums li.selected * { 546 | background-color: lightyellow 547 | } 548 | 549 | .prettyprint.linenums li * { 550 | -webkit-user-select: text; 551 | -moz-user-select: text; 552 | -ms-user-select: text; 553 | user-select: text; 554 | } 555 | 556 | .readme .prettyprint { 557 | max-width: 800px; 558 | } 559 | 560 | .params, .props { 561 | border-spacing: 0; 562 | border: 1px solid #ddd; 563 | border-radius: 3px; 564 | width: 100%; 565 | font-size: 14px; 566 | } 567 | 568 | .params .name, .props .name, .name code { 569 | color: #4D4E53; 570 | font-family: 'bt_mono', monospace; 571 | font-size: 100%; 572 | } 573 | 574 | .params td, .params th, .props td, .props th { 575 | margin: 0px; 576 | text-align: left; 577 | vertical-align: top; 578 | padding: 10px; 579 | display: table-cell; 580 | } 581 | 582 | .params td { 583 | border-top: 1px solid #eee; 584 | } 585 | 586 | .params thead tr, .props thead tr { 587 | background-color: #fff; 588 | font-weight: bold; 589 | } 590 | 591 | .params .params thead tr, .props .props thead tr { 592 | background-color: #fff; 593 | font-weight: bold; 594 | } 595 | 596 | .params td.description>p:first-child, .props td.description>p:first-child { 597 | margin-top: 0; 598 | padding-top: 0; 599 | } 600 | 601 | .params td.description>p:last-child, .props td.description>p:last-child { 602 | margin-bottom: 0; 603 | padding-bottom: 0; 604 | } 605 | 606 | dl.param-type { 607 | margin-top: 5px; 608 | } 609 | 610 | .param-type dt, .param-type dd { 611 | display: inline-block 612 | } 613 | 614 | .param-type dd { 615 | font-family: Consolas, Monaco, 'Andale Mono', monospace 616 | } 617 | 618 | .disabled { 619 | color: #454545 620 | } 621 | 622 | 623 | /* tag source style */ 624 | 625 | .tag-deprecated { 626 | padding-right: 5px; 627 | } 628 | 629 | .tag-source { 630 | border-bottom: 1px solid rgba(28, 160, 224, 0.35); 631 | } 632 | 633 | .tag-source:first-child { 634 | border-bottom: 1px solid rgba(28, 160, 224, 1); 635 | } 636 | 637 | 638 | /* navicon button */ 639 | 640 | .navicon-button { 641 | position: relative; 642 | transition: 0.25s; 643 | cursor: pointer; 644 | user-select: none; 645 | opacity: .8; 646 | background-color: white; 647 | border-radius: 100%; 648 | width: 50px; 649 | height: 50px; 650 | -webkit-box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 651 | -moz-box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 652 | box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 653 | } 654 | 655 | .navicon-button .navicon:before, .navicon-button .navicon:after { 656 | transition: 0.25s; 657 | } 658 | 659 | .navicon-button:hover { 660 | transition: 0.5s; 661 | opacity: 1; 662 | } 663 | 664 | .navicon-button:hover .navicon:before, .navicon-button:hover .navicon:after { 665 | transition: 0.25s; 666 | } 667 | 668 | .navicon-button:hover .navicon:before { 669 | top: .425rem; 670 | } 671 | 672 | .navicon-button:hover .navicon:after { 673 | top: -.425rem; 674 | } 675 | 676 | 677 | /* navicon */ 678 | 679 | .navicon { 680 | position: relative; 681 | width: 1.5em; 682 | height: .195rem; 683 | background: #000; 684 | top: calc(50% - .09rem); 685 | left: calc(50% - .75rem); 686 | transition: 0.3s; 687 | border-radius: 5px; 688 | } 689 | 690 | .navicon:before, .navicon:after { 691 | display: block; 692 | content: ""; 693 | height: .195rem; 694 | width: 1.5rem; 695 | background: #000; 696 | position: absolute; 697 | z-index: -1; 698 | transition: 0.3s 0.25s; 699 | } 700 | 701 | .navicon:before { 702 | top: 0.425rem; 703 | height: .195rem; 704 | border-radius: 5px; 705 | } 706 | 707 | .navicon:after { 708 | top: -0.425rem; 709 | border-radius: 5px; 710 | } 711 | 712 | 713 | /* open */ 714 | 715 | .nav-trigger:checked+label:not(.steps) .navicon:before, .nav-trigger:checked+label:not(.steps) .navicon:after { 716 | top: 0 !important; 717 | } 718 | 719 | .nav-trigger:checked+label .navicon:before, .nav-trigger:checked+label .navicon:after { 720 | transition: 0.5s; 721 | } 722 | 723 | 724 | /* Minus */ 725 | 726 | .nav-trigger:checked+label { 727 | transform: scale(0.75); 728 | } 729 | 730 | 731 | /* × and + */ 732 | 733 | .nav-trigger:checked+label.plus .navicon, .nav-trigger:checked+label.x .navicon { 734 | background: transparent; 735 | } 736 | 737 | .nav-trigger:checked+label.plus .navicon:before, .nav-trigger:checked+label.x .navicon:before { 738 | transform: rotate(-45deg); 739 | background: #000; 740 | } 741 | 742 | .nav-trigger:checked+label.plus .navicon:after, .nav-trigger:checked+label.x .navicon:after { 743 | transform: rotate(45deg); 744 | background: #000; 745 | } 746 | 747 | .nav-trigger:checked+label.plus { 748 | transform: scale(0.75) rotate(45deg); 749 | } 750 | 751 | .nav-trigger:checked~nav { 752 | left: 0 !important; 753 | } 754 | 755 | .nav-trigger:checked~.overlay { 756 | display: block; 757 | } 758 | 759 | .nav-trigger { 760 | position: fixed; 761 | top: 0; 762 | clip: rect(0, 0, 0, 0); 763 | } 764 | 765 | .overlay { 766 | display: none; 767 | position: fixed; 768 | top: 0; 769 | bottom: 0; 770 | left: 0; 771 | right: 0; 772 | width: 100%; 773 | height: 100%; 774 | background: hsla(0, 0%, 0%, 0.5); 775 | z-index: 1; 776 | } 777 | 778 | table { 779 | border-collapse: separate; 780 | ; 781 | display: block; 782 | overflow-x: auto; 783 | /*table-layout:fixed;*/ 784 | } 785 | 786 | table tbody td { 787 | border-top: 1px solid hsl(207, 10%, 86%); 788 | border-right: 1px solid #eee; 789 | padding: 5px; 790 | /*word-wrap: break-word;*/ 791 | } 792 | 793 | td table.params, td table.props { 794 | border: 0; 795 | } 796 | 797 | @media only screen and (min-width: 320px) and (max-width: 680px) { 798 | body { 799 | overflow-x: hidden; 800 | } 801 | #main { 802 | padding: 30px 30px; 803 | width: 100%; 804 | min-width: 360px; 805 | } 806 | nav { 807 | background: #FFF; 808 | width: 300px; 809 | height: 100%; 810 | position: fixed; 811 | top: 0; 812 | right: 0; 813 | bottom: 0; 814 | left: -300px; 815 | z-index: 3; 816 | padding: 0 10px; 817 | transition: left 0.2s; 818 | margin-top: 0; 819 | } 820 | .navicon-button { 821 | display: inline-block; 822 | position: fixed; 823 | bottom: 1.5em; 824 | right: 20px; 825 | z-index: 1000; 826 | } 827 | .top-nav-wrapper { 828 | display: none; 829 | } 830 | #main h1.page-title { 831 | margin: 0.5em 0; 832 | } 833 | footer { 834 | margin-left: 0; 835 | margin-bottom: 30px; 836 | } 837 | } 838 | 839 | .top-nav-wrapper { 840 | background-color: #ececec; 841 | position: fixed; 842 | top: 0px; 843 | left: 0px; 844 | padding: 10px 10px 0 10px; 845 | z-index: 999; 846 | width: 300px; 847 | } 848 | 849 | .top-nav-wrapper ul { 850 | margin: 0; 851 | } 852 | 853 | .top-nav-wrapper ul li { 854 | display: inline-block; 855 | padding: 0 10px; 856 | vertical-align: top; 857 | } 858 | 859 | .top-nav-wrapper ul li.active { 860 | border-bottom: 2px solid rgba(28, 160, 224, 1); 861 | } 862 | 863 | .search-wrapper { 864 | display: inline-block; 865 | position: relative; 866 | } 867 | 868 | .search-wrapper svg { 869 | position: absolute; 870 | left: 0px; 871 | } 872 | 873 | input.search-input { 874 | background: transparent; 875 | box-shadow: 0; 876 | border: 0; 877 | border-bottom: 1px solid #c7c7c7; 878 | padding: 7px 15px 12px 35px; 879 | margin: 0 auto; 880 | } 881 | 882 | 883 | /* Smooth outline with box-shadow: */ 884 | 885 | input.search-input:focus { 886 | border-bottom: 2px solid rgba(28, 160, 224, 1); 887 | outline: none; 888 | } 889 | 890 | 891 | /* Hightlight JS Paradiso Light Theme */ 892 | 893 | .hljs-comment, .hljs-quote { 894 | color: #776e71 895 | } 896 | 897 | .hljs-variable, .hljs-template-variable, .hljs-tag, .hljs-name, .hljs-selector-id, .hljs-selector-class, .hljs-regexp, .hljs-link, .hljs-meta { 898 | color: #ef6155 899 | } 900 | 901 | .hljs-number, .hljs-built_in, .hljs-builtin-name, .hljs-literal, .hljs-type, .hljs-params, .hljs-deletion { 902 | color: #f99b15 903 | } 904 | 905 | .hljs-title, .hljs-section, .hljs-attribute { 906 | color: #fec418 907 | } 908 | 909 | .hljs-string, .hljs-symbol, .hljs-bullet, .hljs-addition { 910 | color: #48b685 911 | } 912 | 913 | .hljs-keyword, .hljs-selector-tag { 914 | color: #815ba4 915 | } 916 | 917 | .hljs { 918 | display: block; 919 | overflow-x: auto; 920 | background: #e7e9db; 921 | color: #4f424c; 922 | padding: 0.5em 923 | } 924 | 925 | .hljs-emphasis { 926 | font-style: italic 927 | } 928 | 929 | .hljs-strong { 930 | font-weight: bold 931 | } 932 | 933 | .link-icon { 934 | opacity: 0; 935 | position: absolute; 936 | margin-left: -25px; 937 | padding-right: 5px; 938 | padding-top: 2px; 939 | } 940 | 941 | .example-container .link-icon { 942 | margin-top: -6px; 943 | } 944 | 945 | .example-container:hover .link-icon, 946 | .name-container:hover .link-icon { 947 | opacity: .5; 948 | } 949 | 950 | .name-container { 951 | display: flex; 952 | padding-top: 1em; 953 | } 954 | -------------------------------------------------------------------------------- /docs/0.8.0/styles/jsdoc-default.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: "Avenir Next W01"; 3 | font-style: normal; 4 | font-weight: 600; 5 | src: url("https://fast.fonts.net/dv2/14/14c73713-e4df-4dba-933b-057feeac8dd1.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 6 | } 7 | 8 | @font-face { 9 | font-family: "Avenir Next W01"; 10 | font-style: normal; 11 | font-weight: 500; 12 | src: url("https://fast.fonts.net/dv2/14/627fbb5a-3bae-4cd9-b617-2f923e29d55e.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 13 | } 14 | 15 | @font-face { 16 | font-family: "Avenir Next W01"; 17 | font-style: normal; 18 | font-weight: 400; 19 | src: url("https://fast.fonts.net/dv2/14/2cd55546-ec00-4af9-aeca-4a3cd186da53.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 20 | } 21 | 22 | @font-face { 23 | font-family: 'bt_mono'; 24 | font-style: normal; 25 | font-weight: 400; 26 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.eot'); 27 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.svg#bt_mono_reqular-webfont') format('svg'); 28 | } 29 | 30 | @font-face { 31 | font-family: 'bt_mono'; 32 | font-style: normal; 33 | font-weight: 500; 34 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.eot'); 35 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.svg#bt_mono_medium-webfont') format('svg'); 36 | } 37 | 38 | @font-face { 39 | font-family: 'bt_mono'; 40 | font-style: normal; 41 | font-weight: 600; 42 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.eot'); 43 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.svg#bt_mono_bold-webfont') format('svg'); 44 | } 45 | 46 | @font-face { 47 | font-family: 'bt_mono'; 48 | font-style: normal; 49 | font-weight: 900; 50 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.eot'); 51 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.svg#bt_mono_heavy-webfont') format('svg'); 52 | } 53 | 54 | * { 55 | box-sizing: border-box 56 | } 57 | 58 | html, body { 59 | height: 100%; 60 | width: 100%; 61 | -webkit-font-smoothing: antialiased; 62 | -moz-osx-font-smoothing: grayscale; 63 | color: #3e3c42; 64 | text-rendering: optimizeLegibility; 65 | margin: 0; 66 | } 67 | 68 | body { 69 | color: #3e3c42; 70 | background-color: #f3f3f3; 71 | width: 100%; 72 | font: 16px/1.875 "Avenir Next W01", "Avenir Next", "Helvetica Neue", Helvetica, sans-serif; 73 | font-size: 16px; 74 | line-height: 160%; 75 | } 76 | 77 | a, a:active { 78 | color: #0095dd; 79 | text-decoration: none; 80 | } 81 | 82 | a:hover { 83 | text-decoration: underline 84 | } 85 | 86 | p, ul, ol, blockquote { 87 | margin-bottom: 1em; 88 | } 89 | 90 | p { 91 | max-width: 800px; 92 | } 93 | 94 | h1, h2, h3, h4, h5, h6 { 95 | color: #706d77; 96 | font-weight: 500; 97 | margin: 0; 98 | line-height: 1; 99 | } 100 | 101 | h1 { 102 | color: #4b484f; 103 | font-weight: 500; 104 | font-size: 40px; 105 | display: block; 106 | } 107 | 108 | h1 span { 109 | color: #999; 110 | font-size: 32px; 111 | display: block; 112 | line-height: 1.5; 113 | } 114 | 115 | h1.page-title { 116 | border-bottom: 1px dashed #ccc; 117 | margin-bottom: 20px; 118 | padding-bottom: 30px; 119 | } 120 | 121 | h2 { 122 | font-size: 30px; 123 | margin: 1.5em 0 0; 124 | } 125 | 126 | h3 { 127 | font-size: 20px; 128 | margin: 1.5em 0 0; 129 | text-transform: uppercase; 130 | } 131 | 132 | h3.reference-title { 133 | display: block; 134 | font-weight: 400; 135 | margin-top: 2em; 136 | max-width: 200px; 137 | } 138 | 139 | h3.reference-title small { 140 | display: inline-block; 141 | color: #0095dd; 142 | margin-left: 5px; 143 | font-weight: 500; 144 | } 145 | 146 | h3.subsection-title { 147 | border-bottom: 1px solid #ececec; 148 | padding-bottom: 20px; 149 | margin-top: 3em; 150 | margin-bottom: 1em; 151 | } 152 | 153 | h4 { 154 | font-size: 16px; 155 | margin: 1em 0 0; 156 | font-weight: bold; 157 | } 158 | 159 | h4.name { 160 | font-size: 20px; 161 | margin-top: 0; 162 | font-weight: 500; 163 | } 164 | 165 | h5 { 166 | margin: 2em 0 0.5em 0; 167 | font-size: 14px; 168 | font-weight: 500; 169 | text-transform: uppercase; 170 | } 171 | 172 | .container-overview .subsection-title { 173 | font-size: 14px; 174 | text-transform: uppercase; 175 | margin: 8px 0 15px 0; 176 | font-weight: bold; 177 | color: #4D4E53; 178 | padding-top: 10px; 179 | } 180 | 181 | h6 { 182 | font-size: 100%; 183 | letter-spacing: -0.01em; 184 | margin: 6px 0 3px 0; 185 | font-style: italic; 186 | text-transform: uppercase; 187 | font-weight: 500; 188 | } 189 | 190 | tt, code, kbd, samp { 191 | font-family: "Source Code Pro", monospace; 192 | background: #f4f4f4; 193 | padding: 1px 5px; 194 | border-radius: 5px; 195 | } 196 | 197 | .class-description { 198 | margin-bottom: 1em; 199 | margin-top: 1em; 200 | padding: 10px 20px; 201 | background-color: rgba(26, 159, 224, 0.1); 202 | } 203 | 204 | .class-description:empty { 205 | margin: 0 206 | } 207 | 208 | #main { 209 | background-color: white; 210 | float: right; 211 | min-width: 360px; 212 | width: calc(100% - 300px); 213 | padding: 30px; 214 | z-index: 100; 215 | } 216 | 217 | header { 218 | display: block; 219 | max-width: 1400px; 220 | } 221 | 222 | section { 223 | display: block; 224 | max-width: 1400px; 225 | background-color: #fff; 226 | } 227 | 228 | .variation { 229 | display: none 230 | } 231 | 232 | .signature-attributes { 233 | font-size: 60%; 234 | color: #aaa; 235 | font-style: italic; 236 | font-weight: lighter; 237 | } 238 | 239 | .rule { 240 | width: 100%; 241 | margin-top: 20px; 242 | display: block; 243 | border-top: 1px solid #ccc; 244 | } 245 | 246 | ul { 247 | list-style-type: none; 248 | padding-left: 0; 249 | } 250 | 251 | ul li a { 252 | font-weight: 500; 253 | } 254 | 255 | ul ul { 256 | padding-top: 5px; 257 | } 258 | 259 | ul li ul { 260 | padding-left: 20px; 261 | } 262 | 263 | ul li ul li a { 264 | font-weight: normal; 265 | } 266 | 267 | nav { 268 | float: left; 269 | display: block; 270 | width: 300px; 271 | background: #f7f7f7; 272 | overflow-x: visible; 273 | overflow-y: auto; 274 | height: 100%; 275 | padding: 0px 30px 100px 30px; 276 | height: 100%; 277 | position: fixed; 278 | transition: left 0.2s; 279 | z-index: 998; 280 | margin-top: 0px; 281 | top: 43px; 282 | } 283 | 284 | .navicon-button { 285 | display: inline-block; 286 | position: fixed; 287 | bottom: 1.5em; 288 | right: 1.5em; 289 | z-index: 2; 290 | } 291 | 292 | nav h3 { 293 | font-size: 13px; 294 | text-transform: uppercase; 295 | letter-spacing: 1px; 296 | font-weight: bold; 297 | line-height: 24px; 298 | margin: 40px 0 10px 0; 299 | padding: 0; 300 | } 301 | 302 | nav ul { 303 | font-size: 100%; 304 | line-height: 17px; 305 | padding: 0; 306 | margin: 0; 307 | list-style-type: none; 308 | border: none; 309 | padding-left: 0; 310 | } 311 | 312 | nav ul a { 313 | font-size: 16px; 314 | } 315 | 316 | nav ul a, nav ul a:active { 317 | display: block; 318 | } 319 | 320 | nav ul a:hover, nav ul a:active { 321 | color: hsl(200, 100%, 43%); 322 | text-decoration: none; 323 | } 324 | 325 | nav>ul { 326 | padding: 0 10px; 327 | } 328 | 329 | nav>ul li:first-child { 330 | padding-top: 0; 331 | } 332 | 333 | nav ul li ul { 334 | padding-left: 0; 335 | } 336 | 337 | nav>ul>li { 338 | border-bottom: 1px solid #e2e2e2; 339 | padding: 10px 0 20px 0; 340 | } 341 | 342 | nav>ul>li.active ul { 343 | border-left: 3px solid #0095dd; 344 | padding-left: 15px; 345 | } 346 | 347 | nav>ul>li.active ul li.active a { 348 | font-weight: bold; 349 | } 350 | 351 | nav>ul>li.active a { 352 | color: #0095dd; 353 | } 354 | 355 | nav>ul>li>a { 356 | color: #706d77; 357 | padding: 20px 0; 358 | font-size: 18px; 359 | } 360 | 361 | nav ul ul { 362 | margin-bottom: 10px; 363 | padding-left: 0; 364 | } 365 | 366 | nav ul ul a { 367 | color: #5f5c63; 368 | } 369 | 370 | nav ul ul a, nav ul ul a:active { 371 | font-family: 'bt_mono', monospace; 372 | font-size: 14px; 373 | padding-left: 20px; 374 | padding-top: 3px; 375 | padding-bottom: 9px; 376 | } 377 | 378 | nav h2 { 379 | font-size: 12px; 380 | margin: 0; 381 | padding: 0; 382 | } 383 | 384 | nav>h2>a { 385 | color: hsl(202, 71%, 50%); 386 | border-bottom: 1px solid hsl(202, 71%, 50%); 387 | padding-bottom: 5px; 388 | } 389 | 390 | nav>h2>a:hover { 391 | font-weight: 500; 392 | text-decoration: none; 393 | } 394 | 395 | footer { 396 | background-color: #fff; 397 | color: hsl(0, 0%, 28%); 398 | margin-left: 300px; 399 | display: block; 400 | font-style: italic; 401 | font-size: 12px; 402 | padding: 30px; 403 | text-align: center; 404 | } 405 | 406 | .ancestors { 407 | color: #999; 408 | } 409 | 410 | .ancestors a { 411 | color: #999 !important; 412 | text-decoration: none; 413 | } 414 | 415 | .clear { 416 | clear: both; 417 | } 418 | 419 | .important { 420 | font-weight: bold; 421 | color: #950B02; 422 | } 423 | 424 | .yes-def { 425 | text-indent: -1000px; 426 | } 427 | 428 | .type-signature { 429 | color: #aaa; 430 | } 431 | 432 | .name, .signature { 433 | font-family: 'bt_mono', monospace; 434 | word-wrap: break-word; 435 | } 436 | 437 | .details { 438 | margin-top: 14px; 439 | font-size: 13px; 440 | text-align: right; 441 | background: #ffffff; 442 | /* Old browsers */ 443 | background: -moz-linear-gradient(left, #ffffff 0%, #fafafa 100%); 444 | /* FF3.6-15 */ 445 | background: -webkit-linear-gradient(left, #ffffff 0%, #fafafa 100%); 446 | /* Chrome10-25,Safari5.1-6 */ 447 | background: linear-gradient(to right, #ffffff 0%, #fafafa 100%); 448 | /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */ 449 | filter: progid: DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#fafafa', GradientType=1); 450 | padding-right: 5px; 451 | } 452 | 453 | .details dt { 454 | display: inline-block; 455 | } 456 | 457 | .details dd { 458 | display: inline-block; 459 | margin: 0; 460 | } 461 | 462 | .details dd a { 463 | font-style: italic; 464 | font-weight: normal; 465 | line-height: 1; 466 | } 467 | 468 | .details ul { 469 | list-style-type: none; 470 | margin: 0; 471 | } 472 | 473 | .details pre.prettyprint { 474 | margin: 0 475 | } 476 | 477 | .details .object-value { 478 | padding-top: 0 479 | } 480 | 481 | .description { 482 | margin-bottom: 1em; 483 | margin-top: 1em; 484 | } 485 | 486 | .code-caption { 487 | font-style: italic; 488 | margin: 0; 489 | font-size: 16px; 490 | color: #545454; 491 | } 492 | 493 | .prettyprint { 494 | font-size: 13px; 495 | border: 1px solid #ddd; 496 | border-radius: 3px; 497 | overflow: auto; 498 | background-color: #fbfbfb; 499 | } 500 | 501 | .prettyprint.source { 502 | width: inherit; 503 | } 504 | 505 | .prettyprint code { 506 | font-size: 100%; 507 | line-height: 18px; 508 | display: block; 509 | margin: 0 30px; 510 | background-color: #fbfbfb; 511 | color: #4D4E53; 512 | } 513 | 514 | .prettyprint>code { 515 | padding: 30px 15px; 516 | } 517 | 518 | .prettyprint .linenums code { 519 | padding: 0 15px; 520 | } 521 | 522 | .prettyprint .linenums li:first-of-type code { 523 | padding-top: 15px; 524 | } 525 | 526 | .prettyprint code span.line { 527 | display: inline-block; 528 | } 529 | 530 | .prettyprint.linenums { 531 | -webkit-user-select: none; 532 | -moz-user-select: none; 533 | -ms-user-select: none; 534 | user-select: none; 535 | } 536 | 537 | .prettyprint.linenums ol { 538 | padding-left: 0 539 | } 540 | 541 | .prettyprint.linenums li { 542 | border-left: 3px #ddd solid 543 | } 544 | 545 | .prettyprint.linenums li.selected, .prettyprint.linenums li.selected * { 546 | background-color: lightyellow 547 | } 548 | 549 | .prettyprint.linenums li * { 550 | -webkit-user-select: text; 551 | -moz-user-select: text; 552 | -ms-user-select: text; 553 | user-select: text; 554 | } 555 | 556 | .readme .prettyprint { 557 | max-width: 800px; 558 | } 559 | 560 | .params, .props { 561 | border-spacing: 0; 562 | border: 1px solid #ddd; 563 | border-radius: 3px; 564 | width: 100%; 565 | font-size: 14px; 566 | } 567 | 568 | .params .name, .props .name, .name code { 569 | color: #4D4E53; 570 | font-family: 'bt_mono', monospace; 571 | font-size: 100%; 572 | } 573 | 574 | .params td, .params th, .props td, .props th { 575 | margin: 0px; 576 | text-align: left; 577 | vertical-align: top; 578 | padding: 10px; 579 | display: table-cell; 580 | } 581 | 582 | .params td { 583 | border-top: 1px solid #eee; 584 | } 585 | 586 | .params thead tr, .props thead tr { 587 | background-color: #fff; 588 | font-weight: bold; 589 | } 590 | 591 | .params .params thead tr, .props .props thead tr { 592 | background-color: #fff; 593 | font-weight: bold; 594 | } 595 | 596 | .params td.description>p:first-child, .props td.description>p:first-child { 597 | margin-top: 0; 598 | padding-top: 0; 599 | } 600 | 601 | .params td.description>p:last-child, .props td.description>p:last-child { 602 | margin-bottom: 0; 603 | padding-bottom: 0; 604 | } 605 | 606 | dl.param-type { 607 | margin-top: 5px; 608 | } 609 | 610 | .param-type dt, .param-type dd { 611 | display: inline-block 612 | } 613 | 614 | .param-type dd { 615 | font-family: Consolas, Monaco, 'Andale Mono', monospace 616 | } 617 | 618 | .disabled { 619 | color: #454545 620 | } 621 | 622 | 623 | /* tag source style */ 624 | 625 | .tag-deprecated { 626 | padding-right: 5px; 627 | } 628 | 629 | .tag-source { 630 | border-bottom: 1px solid rgba(28, 160, 224, 0.35); 631 | } 632 | 633 | .tag-source:first-child { 634 | border-bottom: 1px solid rgba(28, 160, 224, 1); 635 | } 636 | 637 | 638 | /* navicon button */ 639 | 640 | .navicon-button { 641 | position: relative; 642 | transition: 0.25s; 643 | cursor: pointer; 644 | user-select: none; 645 | opacity: .8; 646 | background-color: white; 647 | border-radius: 100%; 648 | width: 50px; 649 | height: 50px; 650 | -webkit-box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 651 | -moz-box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 652 | box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 653 | } 654 | 655 | .navicon-button .navicon:before, .navicon-button .navicon:after { 656 | transition: 0.25s; 657 | } 658 | 659 | .navicon-button:hover { 660 | transition: 0.5s; 661 | opacity: 1; 662 | } 663 | 664 | .navicon-button:hover .navicon:before, .navicon-button:hover .navicon:after { 665 | transition: 0.25s; 666 | } 667 | 668 | .navicon-button:hover .navicon:before { 669 | top: .425rem; 670 | } 671 | 672 | .navicon-button:hover .navicon:after { 673 | top: -.425rem; 674 | } 675 | 676 | 677 | /* navicon */ 678 | 679 | .navicon { 680 | position: relative; 681 | width: 1.5em; 682 | height: .195rem; 683 | background: #000; 684 | top: calc(50% - .09rem); 685 | left: calc(50% - .75rem); 686 | transition: 0.3s; 687 | border-radius: 5px; 688 | } 689 | 690 | .navicon:before, .navicon:after { 691 | display: block; 692 | content: ""; 693 | height: .195rem; 694 | width: 1.5rem; 695 | background: #000; 696 | position: absolute; 697 | z-index: -1; 698 | transition: 0.3s 0.25s; 699 | } 700 | 701 | .navicon:before { 702 | top: 0.425rem; 703 | height: .195rem; 704 | border-radius: 5px; 705 | } 706 | 707 | .navicon:after { 708 | top: -0.425rem; 709 | border-radius: 5px; 710 | } 711 | 712 | 713 | /* open */ 714 | 715 | .nav-trigger:checked+label:not(.steps) .navicon:before, .nav-trigger:checked+label:not(.steps) .navicon:after { 716 | top: 0 !important; 717 | } 718 | 719 | .nav-trigger:checked+label .navicon:before, .nav-trigger:checked+label .navicon:after { 720 | transition: 0.5s; 721 | } 722 | 723 | 724 | /* Minus */ 725 | 726 | .nav-trigger:checked+label { 727 | transform: scale(0.75); 728 | } 729 | 730 | 731 | /* × and + */ 732 | 733 | .nav-trigger:checked+label.plus .navicon, .nav-trigger:checked+label.x .navicon { 734 | background: transparent; 735 | } 736 | 737 | .nav-trigger:checked+label.plus .navicon:before, .nav-trigger:checked+label.x .navicon:before { 738 | transform: rotate(-45deg); 739 | background: #000; 740 | } 741 | 742 | .nav-trigger:checked+label.plus .navicon:after, .nav-trigger:checked+label.x .navicon:after { 743 | transform: rotate(45deg); 744 | background: #000; 745 | } 746 | 747 | .nav-trigger:checked+label.plus { 748 | transform: scale(0.75) rotate(45deg); 749 | } 750 | 751 | .nav-trigger:checked~nav { 752 | left: 0 !important; 753 | } 754 | 755 | .nav-trigger:checked~.overlay { 756 | display: block; 757 | } 758 | 759 | .nav-trigger { 760 | position: fixed; 761 | top: 0; 762 | clip: rect(0, 0, 0, 0); 763 | } 764 | 765 | .overlay { 766 | display: none; 767 | position: fixed; 768 | top: 0; 769 | bottom: 0; 770 | left: 0; 771 | right: 0; 772 | width: 100%; 773 | height: 100%; 774 | background: hsla(0, 0%, 0%, 0.5); 775 | z-index: 1; 776 | } 777 | 778 | table { 779 | border-collapse: separate; 780 | ; 781 | display: block; 782 | overflow-x: auto; 783 | /*table-layout:fixed;*/ 784 | } 785 | 786 | table tbody td { 787 | border-top: 1px solid hsl(207, 10%, 86%); 788 | border-right: 1px solid #eee; 789 | padding: 5px; 790 | /*word-wrap: break-word;*/ 791 | } 792 | 793 | td table.params, td table.props { 794 | border: 0; 795 | } 796 | 797 | @media only screen and (min-width: 320px) and (max-width: 680px) { 798 | body { 799 | overflow-x: hidden; 800 | } 801 | #main { 802 | padding: 30px 30px; 803 | width: 100%; 804 | min-width: 360px; 805 | } 806 | nav { 807 | background: #FFF; 808 | width: 300px; 809 | height: 100%; 810 | position: fixed; 811 | top: 0; 812 | right: 0; 813 | bottom: 0; 814 | left: -300px; 815 | z-index: 3; 816 | padding: 0 10px; 817 | transition: left 0.2s; 818 | margin-top: 0; 819 | } 820 | .navicon-button { 821 | display: inline-block; 822 | position: fixed; 823 | bottom: 1.5em; 824 | right: 20px; 825 | z-index: 1000; 826 | } 827 | .top-nav-wrapper { 828 | display: none; 829 | } 830 | #main h1.page-title { 831 | margin: 0.5em 0; 832 | } 833 | footer { 834 | margin-left: 0; 835 | margin-bottom: 30px; 836 | } 837 | } 838 | 839 | .top-nav-wrapper { 840 | background-color: #ececec; 841 | position: fixed; 842 | top: 0px; 843 | left: 0px; 844 | padding: 10px 10px 0 10px; 845 | z-index: 999; 846 | width: 300px; 847 | } 848 | 849 | .top-nav-wrapper ul { 850 | margin: 0; 851 | } 852 | 853 | .top-nav-wrapper ul li { 854 | display: inline-block; 855 | padding: 0 10px; 856 | vertical-align: top; 857 | } 858 | 859 | .top-nav-wrapper ul li.active { 860 | border-bottom: 2px solid rgba(28, 160, 224, 1); 861 | } 862 | 863 | .search-wrapper { 864 | display: inline-block; 865 | position: relative; 866 | } 867 | 868 | .search-wrapper svg { 869 | position: absolute; 870 | left: 0px; 871 | } 872 | 873 | input.search-input { 874 | background: transparent; 875 | box-shadow: 0; 876 | border: 0; 877 | border-bottom: 1px solid #c7c7c7; 878 | padding: 7px 15px 12px 35px; 879 | margin: 0 auto; 880 | } 881 | 882 | 883 | /* Smooth outline with box-shadow: */ 884 | 885 | input.search-input:focus { 886 | border-bottom: 2px solid rgba(28, 160, 224, 1); 887 | outline: none; 888 | } 889 | 890 | 891 | /* Hightlight JS Paradiso Light Theme */ 892 | 893 | .hljs-comment, .hljs-quote { 894 | color: #776e71 895 | } 896 | 897 | .hljs-variable, .hljs-template-variable, .hljs-tag, .hljs-name, .hljs-selector-id, .hljs-selector-class, .hljs-regexp, .hljs-link, .hljs-meta { 898 | color: #ef6155 899 | } 900 | 901 | .hljs-number, .hljs-built_in, .hljs-builtin-name, .hljs-literal, .hljs-type, .hljs-params, .hljs-deletion { 902 | color: #f99b15 903 | } 904 | 905 | .hljs-title, .hljs-section, .hljs-attribute { 906 | color: #fec418 907 | } 908 | 909 | .hljs-string, .hljs-symbol, .hljs-bullet, .hljs-addition { 910 | color: #48b685 911 | } 912 | 913 | .hljs-keyword, .hljs-selector-tag { 914 | color: #815ba4 915 | } 916 | 917 | .hljs { 918 | display: block; 919 | overflow-x: auto; 920 | background: #e7e9db; 921 | color: #4f424c; 922 | padding: 0.5em 923 | } 924 | 925 | .hljs-emphasis { 926 | font-style: italic 927 | } 928 | 929 | .hljs-strong { 930 | font-weight: bold 931 | } 932 | 933 | .link-icon { 934 | opacity: 0; 935 | position: absolute; 936 | margin-left: -25px; 937 | padding-right: 5px; 938 | padding-top: 2px; 939 | } 940 | 941 | .example-container .link-icon { 942 | margin-top: -6px; 943 | } 944 | 945 | .example-container:hover .link-icon, 946 | .name-container:hover .link-icon { 947 | opacity: .5; 948 | } 949 | 950 | .name-container { 951 | display: flex; 952 | padding-top: 1em; 953 | } 954 | -------------------------------------------------------------------------------- /docs/master/styles/jsdoc-default.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: "Avenir Next W01"; 3 | font-style: normal; 4 | font-weight: 600; 5 | src: url("https://fast.fonts.net/dv2/14/14c73713-e4df-4dba-933b-057feeac8dd1.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 6 | } 7 | 8 | @font-face { 9 | font-family: "Avenir Next W01"; 10 | font-style: normal; 11 | font-weight: 500; 12 | src: url("https://fast.fonts.net/dv2/14/627fbb5a-3bae-4cd9-b617-2f923e29d55e.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 13 | } 14 | 15 | @font-face { 16 | font-family: "Avenir Next W01"; 17 | font-style: normal; 18 | font-weight: 400; 19 | src: url("https://fast.fonts.net/dv2/14/2cd55546-ec00-4af9-aeca-4a3cd186da53.woff2?d44f19a684109620e484167ba790e8180fd9e29df91d80ce3d096f014db863074e1ea706cf5ed4e1c042492e76df291ce1d24ec684d3d9da9684f55406b9f22bce02f0f30f556681593dafea074d7bd44e28a680d083ccfd44ed4f8a3087a20c56147c11f917ed1dbd85c4a18cf38da25e6ac78f008f472262304d50e7e0cb7541ef1642c676db6e4bde4924846f5daf486fbde9335e98f6a20f6664bc4525253d1d4fca42cf1c490483c8daf0237f6a0fd292563417ad80ca3e69321417747bdc6f0969f34b2a0401b5e2b9a4dfd5b06d9710850900c66b34870aef&projectId=f750d5c7-baa2-4767-afd7-45484f47fe17") format('woff2'); 20 | } 21 | 22 | @font-face { 23 | font-family: 'bt_mono'; 24 | font-style: normal; 25 | font-weight: 400; 26 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.eot'); 27 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_regular-webfont.svg#bt_mono_reqular-webfont') format('svg'); 28 | } 29 | 30 | @font-face { 31 | font-family: 'bt_mono'; 32 | font-style: normal; 33 | font-weight: 500; 34 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.eot'); 35 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_medium-webfont.svg#bt_mono_medium-webfont') format('svg'); 36 | } 37 | 38 | @font-face { 39 | font-family: 'bt_mono'; 40 | font-style: normal; 41 | font-weight: 600; 42 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.eot'); 43 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_bold-webfont.svg#bt_mono_bold-webfont') format('svg'); 44 | } 45 | 46 | @font-face { 47 | font-family: 'bt_mono'; 48 | font-style: normal; 49 | font-weight: 900; 50 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.eot'); 51 | src: url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.woff2') format('woff2'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.woff') format('woff'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.ttf') format('truetype'), url('https://assets.braintreegateway.com/fonts/bt_mono_heavy-webfont.svg#bt_mono_heavy-webfont') format('svg'); 52 | } 53 | 54 | * { 55 | box-sizing: border-box 56 | } 57 | 58 | html, body { 59 | height: 100%; 60 | width: 100%; 61 | -webkit-font-smoothing: antialiased; 62 | -moz-osx-font-smoothing: grayscale; 63 | color: #3e3c42; 64 | text-rendering: optimizeLegibility; 65 | margin: 0; 66 | } 67 | 68 | body { 69 | color: #3e3c42; 70 | background-color: #f3f3f3; 71 | width: 100%; 72 | font: 16px/1.875 "Avenir Next W01", "Avenir Next", "Helvetica Neue", Helvetica, sans-serif; 73 | font-size: 16px; 74 | line-height: 160%; 75 | } 76 | 77 | a, a:active { 78 | color: #0095dd; 79 | text-decoration: none; 80 | } 81 | 82 | a:hover { 83 | text-decoration: underline 84 | } 85 | 86 | p, ul, ol, blockquote { 87 | margin-bottom: 1em; 88 | } 89 | 90 | p { 91 | max-width: 800px; 92 | } 93 | 94 | h1, h2, h3, h4, h5, h6 { 95 | color: #706d77; 96 | font-weight: 500; 97 | margin: 0; 98 | line-height: 1; 99 | } 100 | 101 | h1 { 102 | color: #4b484f; 103 | font-weight: 500; 104 | font-size: 40px; 105 | display: block; 106 | } 107 | 108 | h1 span { 109 | color: #999; 110 | font-size: 32px; 111 | display: block; 112 | line-height: 1.5; 113 | } 114 | 115 | h1.page-title { 116 | border-bottom: 1px dashed #ccc; 117 | margin-bottom: 20px; 118 | padding-bottom: 30px; 119 | } 120 | 121 | h2 { 122 | font-size: 30px; 123 | margin: 1.5em 0 0; 124 | } 125 | 126 | h3 { 127 | font-size: 20px; 128 | margin: 1.5em 0 0; 129 | text-transform: uppercase; 130 | } 131 | 132 | h3.reference-title { 133 | display: block; 134 | font-weight: 400; 135 | margin-top: 2em; 136 | max-width: 200px; 137 | } 138 | 139 | h3.reference-title small { 140 | display: inline-block; 141 | color: #0095dd; 142 | margin-left: 5px; 143 | font-weight: 500; 144 | } 145 | 146 | h3.subsection-title { 147 | border-bottom: 1px solid #ececec; 148 | padding-bottom: 20px; 149 | margin-top: 3em; 150 | margin-bottom: 1em; 151 | } 152 | 153 | h4 { 154 | font-size: 16px; 155 | margin: 1em 0 0; 156 | font-weight: bold; 157 | } 158 | 159 | h4.name { 160 | font-size: 20px; 161 | margin-top: 0; 162 | font-weight: 500; 163 | } 164 | 165 | h5 { 166 | margin: 2em 0 0.5em 0; 167 | font-size: 14px; 168 | font-weight: 500; 169 | text-transform: uppercase; 170 | } 171 | 172 | .container-overview .subsection-title { 173 | font-size: 14px; 174 | text-transform: uppercase; 175 | margin: 8px 0 15px 0; 176 | font-weight: bold; 177 | color: #4D4E53; 178 | padding-top: 10px; 179 | } 180 | 181 | h6 { 182 | font-size: 100%; 183 | letter-spacing: -0.01em; 184 | margin: 6px 0 3px 0; 185 | font-style: italic; 186 | text-transform: uppercase; 187 | font-weight: 500; 188 | } 189 | 190 | tt, code, kbd, samp { 191 | font-family: "Source Code Pro", monospace; 192 | background: #f4f4f4; 193 | padding: 1px 5px; 194 | border-radius: 5px; 195 | } 196 | 197 | .class-description { 198 | margin-bottom: 1em; 199 | margin-top: 1em; 200 | padding: 10px 20px; 201 | background-color: rgba(26, 159, 224, 0.1); 202 | } 203 | 204 | .class-description:empty { 205 | margin: 0 206 | } 207 | 208 | #main { 209 | background-color: white; 210 | float: right; 211 | min-width: 360px; 212 | width: calc(100% - 300px); 213 | padding: 30px; 214 | z-index: 100; 215 | } 216 | 217 | header { 218 | display: block; 219 | max-width: 1400px; 220 | } 221 | 222 | section { 223 | display: block; 224 | max-width: 1400px; 225 | background-color: #fff; 226 | } 227 | 228 | .variation { 229 | display: none 230 | } 231 | 232 | .signature-attributes { 233 | font-size: 60%; 234 | color: #aaa; 235 | font-style: italic; 236 | font-weight: lighter; 237 | } 238 | 239 | .rule { 240 | width: 100%; 241 | margin-top: 20px; 242 | display: block; 243 | border-top: 1px solid #ccc; 244 | } 245 | 246 | ul { 247 | list-style-type: none; 248 | padding-left: 0; 249 | } 250 | 251 | ul li a { 252 | font-weight: 500; 253 | } 254 | 255 | ul ul { 256 | padding-top: 5px; 257 | } 258 | 259 | ul li ul { 260 | padding-left: 20px; 261 | } 262 | 263 | ul li ul li a { 264 | font-weight: normal; 265 | } 266 | 267 | nav { 268 | float: left; 269 | display: block; 270 | width: 300px; 271 | background: #f7f7f7; 272 | overflow-x: visible; 273 | overflow-y: auto; 274 | height: 100%; 275 | padding: 0px 30px 100px 30px; 276 | height: 100%; 277 | position: fixed; 278 | transition: left 0.2s; 279 | z-index: 998; 280 | margin-top: 0px; 281 | top: 43px; 282 | } 283 | 284 | .navicon-button { 285 | display: inline-block; 286 | position: fixed; 287 | bottom: 1.5em; 288 | right: 1.5em; 289 | z-index: 2; 290 | } 291 | 292 | nav h3 { 293 | font-size: 13px; 294 | text-transform: uppercase; 295 | letter-spacing: 1px; 296 | font-weight: bold; 297 | line-height: 24px; 298 | margin: 40px 0 10px 0; 299 | padding: 0; 300 | } 301 | 302 | nav ul { 303 | font-size: 100%; 304 | line-height: 17px; 305 | padding: 0; 306 | margin: 0; 307 | list-style-type: none; 308 | border: none; 309 | padding-left: 0; 310 | } 311 | 312 | nav ul a { 313 | font-size: 16px; 314 | } 315 | 316 | nav ul a, nav ul a:active { 317 | display: block; 318 | } 319 | 320 | nav ul a:hover, nav ul a:active { 321 | color: hsl(200, 100%, 43%); 322 | text-decoration: none; 323 | } 324 | 325 | nav>ul { 326 | padding: 0 10px; 327 | } 328 | 329 | nav>ul li:first-child { 330 | padding-top: 0; 331 | } 332 | 333 | nav ul li ul { 334 | padding-left: 0; 335 | } 336 | 337 | nav>ul>li { 338 | border-bottom: 1px solid #e2e2e2; 339 | padding: 10px 0 20px 0; 340 | } 341 | 342 | nav>ul>li.active ul { 343 | border-left: 3px solid #0095dd; 344 | padding-left: 15px; 345 | } 346 | 347 | nav>ul>li.active ul li.active a { 348 | font-weight: bold; 349 | } 350 | 351 | nav>ul>li.active a { 352 | color: #0095dd; 353 | } 354 | 355 | nav>ul>li>a { 356 | color: #706d77; 357 | padding: 20px 0; 358 | font-size: 18px; 359 | } 360 | 361 | nav ul ul { 362 | margin-bottom: 10px; 363 | padding-left: 0; 364 | } 365 | 366 | nav ul ul a { 367 | color: #5f5c63; 368 | } 369 | 370 | nav ul ul a, nav ul ul a:active { 371 | font-family: 'bt_mono', monospace; 372 | font-size: 14px; 373 | padding-left: 20px; 374 | padding-top: 3px; 375 | padding-bottom: 9px; 376 | } 377 | 378 | nav h2 { 379 | font-size: 12px; 380 | margin: 0; 381 | padding: 0; 382 | } 383 | 384 | nav>h2>a { 385 | color: hsl(202, 71%, 50%); 386 | border-bottom: 1px solid hsl(202, 71%, 50%); 387 | padding-bottom: 5px; 388 | } 389 | 390 | nav>h2>a:hover { 391 | font-weight: 500; 392 | text-decoration: none; 393 | } 394 | 395 | footer { 396 | background-color: #fff; 397 | color: hsl(0, 0%, 28%); 398 | margin-left: 300px; 399 | display: block; 400 | font-style: italic; 401 | font-size: 12px; 402 | padding: 30px; 403 | text-align: center; 404 | } 405 | 406 | .ancestors { 407 | color: #999; 408 | } 409 | 410 | .ancestors a { 411 | color: #999 !important; 412 | text-decoration: none; 413 | } 414 | 415 | .clear { 416 | clear: both; 417 | } 418 | 419 | .important { 420 | font-weight: bold; 421 | color: #950B02; 422 | } 423 | 424 | .yes-def { 425 | text-indent: -1000px; 426 | } 427 | 428 | .type-signature { 429 | color: #aaa; 430 | } 431 | 432 | .name, .signature { 433 | font-family: 'bt_mono', monospace; 434 | word-wrap: break-word; 435 | } 436 | 437 | .details { 438 | margin-top: 14px; 439 | font-size: 13px; 440 | text-align: right; 441 | background: #ffffff; 442 | /* Old browsers */ 443 | background: -moz-linear-gradient(left, #ffffff 0%, #fafafa 100%); 444 | /* FF3.6-15 */ 445 | background: -webkit-linear-gradient(left, #ffffff 0%, #fafafa 100%); 446 | /* Chrome10-25,Safari5.1-6 */ 447 | background: linear-gradient(to right, #ffffff 0%, #fafafa 100%); 448 | /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */ 449 | filter: progid: DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#fafafa', GradientType=1); 450 | padding-right: 5px; 451 | } 452 | 453 | .details dt { 454 | display: inline-block; 455 | } 456 | 457 | .details dd { 458 | display: inline-block; 459 | margin: 0; 460 | } 461 | 462 | .details dd a { 463 | font-style: italic; 464 | font-weight: normal; 465 | line-height: 1; 466 | } 467 | 468 | .details ul { 469 | list-style-type: none; 470 | margin: 0; 471 | } 472 | 473 | .details pre.prettyprint { 474 | margin: 0 475 | } 476 | 477 | .details .object-value { 478 | padding-top: 0 479 | } 480 | 481 | .description { 482 | margin-bottom: 1em; 483 | margin-top: 1em; 484 | } 485 | 486 | .code-caption { 487 | font-style: italic; 488 | margin: 0; 489 | font-size: 16px; 490 | color: #545454; 491 | } 492 | 493 | .prettyprint { 494 | font-size: 13px; 495 | border: 1px solid #ddd; 496 | border-radius: 3px; 497 | overflow: auto; 498 | background-color: #fbfbfb; 499 | } 500 | 501 | .prettyprint.source { 502 | width: inherit; 503 | } 504 | 505 | .prettyprint code { 506 | font-size: 100%; 507 | line-height: 18px; 508 | display: block; 509 | margin: 0 30px; 510 | background-color: #fbfbfb; 511 | color: #4D4E53; 512 | } 513 | 514 | .prettyprint>code { 515 | padding: 30px 15px; 516 | } 517 | 518 | .prettyprint .linenums code { 519 | padding: 0 15px; 520 | } 521 | 522 | .prettyprint .linenums li:first-of-type code { 523 | padding-top: 15px; 524 | } 525 | 526 | .prettyprint code span.line { 527 | display: inline-block; 528 | } 529 | 530 | .prettyprint.linenums { 531 | -webkit-user-select: none; 532 | -moz-user-select: none; 533 | -ms-user-select: none; 534 | user-select: none; 535 | } 536 | 537 | .prettyprint.linenums ol { 538 | padding-left: 0 539 | } 540 | 541 | .prettyprint.linenums li { 542 | border-left: 3px #ddd solid 543 | } 544 | 545 | .prettyprint.linenums li.selected, .prettyprint.linenums li.selected * { 546 | background-color: lightyellow 547 | } 548 | 549 | .prettyprint.linenums li * { 550 | -webkit-user-select: text; 551 | -moz-user-select: text; 552 | -ms-user-select: text; 553 | user-select: text; 554 | } 555 | 556 | .readme .prettyprint { 557 | max-width: 800px; 558 | } 559 | 560 | .params, .props { 561 | border-spacing: 0; 562 | border: 1px solid #ddd; 563 | border-radius: 3px; 564 | width: 100%; 565 | font-size: 14px; 566 | } 567 | 568 | .params .name, .props .name, .name code { 569 | color: #4D4E53; 570 | font-family: 'bt_mono', monospace; 571 | font-size: 100%; 572 | } 573 | 574 | .params td, .params th, .props td, .props th { 575 | margin: 0px; 576 | text-align: left; 577 | vertical-align: top; 578 | padding: 10px; 579 | display: table-cell; 580 | } 581 | 582 | .params td { 583 | border-top: 1px solid #eee; 584 | } 585 | 586 | .params thead tr, .props thead tr { 587 | background-color: #fff; 588 | font-weight: bold; 589 | } 590 | 591 | .params .params thead tr, .props .props thead tr { 592 | background-color: #fff; 593 | font-weight: bold; 594 | } 595 | 596 | .params td.description>p:first-child, .props td.description>p:first-child { 597 | margin-top: 0; 598 | padding-top: 0; 599 | } 600 | 601 | .params td.description>p:last-child, .props td.description>p:last-child { 602 | margin-bottom: 0; 603 | padding-bottom: 0; 604 | } 605 | 606 | dl.param-type { 607 | margin-top: 5px; 608 | } 609 | 610 | .param-type dt, .param-type dd { 611 | display: inline-block 612 | } 613 | 614 | .param-type dd { 615 | font-family: Consolas, Monaco, 'Andale Mono', monospace 616 | } 617 | 618 | .disabled { 619 | color: #454545 620 | } 621 | 622 | 623 | /* tag source style */ 624 | 625 | .tag-deprecated { 626 | padding-right: 5px; 627 | } 628 | 629 | .tag-source { 630 | border-bottom: 1px solid rgba(28, 160, 224, 0.35); 631 | } 632 | 633 | .tag-source:first-child { 634 | border-bottom: 1px solid rgba(28, 160, 224, 1); 635 | } 636 | 637 | 638 | /* navicon button */ 639 | 640 | .navicon-button { 641 | position: relative; 642 | transition: 0.25s; 643 | cursor: pointer; 644 | user-select: none; 645 | opacity: .8; 646 | background-color: white; 647 | border-radius: 100%; 648 | width: 50px; 649 | height: 50px; 650 | -webkit-box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 651 | -moz-box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 652 | box-shadow: 0px 2px 9px 0px rgba(0, 0, 0, 0.31); 653 | } 654 | 655 | .navicon-button .navicon:before, .navicon-button .navicon:after { 656 | transition: 0.25s; 657 | } 658 | 659 | .navicon-button:hover { 660 | transition: 0.5s; 661 | opacity: 1; 662 | } 663 | 664 | .navicon-button:hover .navicon:before, .navicon-button:hover .navicon:after { 665 | transition: 0.25s; 666 | } 667 | 668 | .navicon-button:hover .navicon:before { 669 | top: .425rem; 670 | } 671 | 672 | .navicon-button:hover .navicon:after { 673 | top: -.425rem; 674 | } 675 | 676 | 677 | /* navicon */ 678 | 679 | .navicon { 680 | position: relative; 681 | width: 1.5em; 682 | height: .195rem; 683 | background: #000; 684 | top: calc(50% - .09rem); 685 | left: calc(50% - .75rem); 686 | transition: 0.3s; 687 | border-radius: 5px; 688 | } 689 | 690 | .navicon:before, .navicon:after { 691 | display: block; 692 | content: ""; 693 | height: .195rem; 694 | width: 1.5rem; 695 | background: #000; 696 | position: absolute; 697 | z-index: -1; 698 | transition: 0.3s 0.25s; 699 | } 700 | 701 | .navicon:before { 702 | top: 0.425rem; 703 | height: .195rem; 704 | border-radius: 5px; 705 | } 706 | 707 | .navicon:after { 708 | top: -0.425rem; 709 | border-radius: 5px; 710 | } 711 | 712 | 713 | /* open */ 714 | 715 | .nav-trigger:checked+label:not(.steps) .navicon:before, .nav-trigger:checked+label:not(.steps) .navicon:after { 716 | top: 0 !important; 717 | } 718 | 719 | .nav-trigger:checked+label .navicon:before, .nav-trigger:checked+label .navicon:after { 720 | transition: 0.5s; 721 | } 722 | 723 | 724 | /* Minus */ 725 | 726 | .nav-trigger:checked+label { 727 | transform: scale(0.75); 728 | } 729 | 730 | 731 | /* × and + */ 732 | 733 | .nav-trigger:checked+label.plus .navicon, .nav-trigger:checked+label.x .navicon { 734 | background: transparent; 735 | } 736 | 737 | .nav-trigger:checked+label.plus .navicon:before, .nav-trigger:checked+label.x .navicon:before { 738 | transform: rotate(-45deg); 739 | background: #000; 740 | } 741 | 742 | .nav-trigger:checked+label.plus .navicon:after, .nav-trigger:checked+label.x .navicon:after { 743 | transform: rotate(45deg); 744 | background: #000; 745 | } 746 | 747 | .nav-trigger:checked+label.plus { 748 | transform: scale(0.75) rotate(45deg); 749 | } 750 | 751 | .nav-trigger:checked~nav { 752 | left: 0 !important; 753 | } 754 | 755 | .nav-trigger:checked~.overlay { 756 | display: block; 757 | } 758 | 759 | .nav-trigger { 760 | position: fixed; 761 | top: 0; 762 | clip: rect(0, 0, 0, 0); 763 | } 764 | 765 | .overlay { 766 | display: none; 767 | position: fixed; 768 | top: 0; 769 | bottom: 0; 770 | left: 0; 771 | right: 0; 772 | width: 100%; 773 | height: 100%; 774 | background: hsla(0, 0%, 0%, 0.5); 775 | z-index: 1; 776 | } 777 | 778 | table { 779 | border-collapse: separate; 780 | ; 781 | display: block; 782 | overflow-x: auto; 783 | /*table-layout:fixed;*/ 784 | } 785 | 786 | table tbody td { 787 | border-top: 1px solid hsl(207, 10%, 86%); 788 | border-right: 1px solid #eee; 789 | padding: 5px; 790 | /*word-wrap: break-word;*/ 791 | } 792 | 793 | td table.params, td table.props { 794 | border: 0; 795 | } 796 | 797 | @media only screen and (min-width: 320px) and (max-width: 680px) { 798 | body { 799 | overflow-x: hidden; 800 | } 801 | #main { 802 | padding: 30px 30px; 803 | width: 100%; 804 | min-width: 360px; 805 | } 806 | nav { 807 | background: #FFF; 808 | width: 300px; 809 | height: 100%; 810 | position: fixed; 811 | top: 0; 812 | right: 0; 813 | bottom: 0; 814 | left: -300px; 815 | z-index: 3; 816 | padding: 0 10px; 817 | transition: left 0.2s; 818 | margin-top: 0; 819 | } 820 | .navicon-button { 821 | display: inline-block; 822 | position: fixed; 823 | bottom: 1.5em; 824 | right: 20px; 825 | z-index: 1000; 826 | } 827 | .top-nav-wrapper { 828 | display: none; 829 | } 830 | #main h1.page-title { 831 | margin: 0.5em 0; 832 | } 833 | footer { 834 | margin-left: 0; 835 | margin-bottom: 30px; 836 | } 837 | } 838 | 839 | .top-nav-wrapper { 840 | background-color: #ececec; 841 | position: fixed; 842 | top: 0px; 843 | left: 0px; 844 | padding: 10px 10px 0 10px; 845 | z-index: 999; 846 | width: 300px; 847 | } 848 | 849 | .top-nav-wrapper ul { 850 | margin: 0; 851 | } 852 | 853 | .top-nav-wrapper ul li { 854 | display: inline-block; 855 | padding: 0 10px; 856 | vertical-align: top; 857 | } 858 | 859 | .top-nav-wrapper ul li.active { 860 | border-bottom: 2px solid rgba(28, 160, 224, 1); 861 | } 862 | 863 | .search-wrapper { 864 | display: inline-block; 865 | position: relative; 866 | } 867 | 868 | .search-wrapper svg { 869 | position: absolute; 870 | left: 0px; 871 | } 872 | 873 | input.search-input { 874 | background: transparent; 875 | box-shadow: 0; 876 | border: 0; 877 | border-bottom: 1px solid #c7c7c7; 878 | padding: 7px 15px 12px 35px; 879 | margin: 0 auto; 880 | } 881 | 882 | 883 | /* Smooth outline with box-shadow: */ 884 | 885 | input.search-input:focus { 886 | border-bottom: 2px solid rgba(28, 160, 224, 1); 887 | outline: none; 888 | } 889 | 890 | 891 | /* Hightlight JS Paradiso Light Theme */ 892 | 893 | .hljs-comment, .hljs-quote { 894 | color: #776e71 895 | } 896 | 897 | .hljs-variable, .hljs-template-variable, .hljs-tag, .hljs-name, .hljs-selector-id, .hljs-selector-class, .hljs-regexp, .hljs-link, .hljs-meta { 898 | color: #ef6155 899 | } 900 | 901 | .hljs-number, .hljs-built_in, .hljs-builtin-name, .hljs-literal, .hljs-type, .hljs-params, .hljs-deletion { 902 | color: #f99b15 903 | } 904 | 905 | .hljs-title, .hljs-section, .hljs-attribute { 906 | color: #fec418 907 | } 908 | 909 | .hljs-string, .hljs-symbol, .hljs-bullet, .hljs-addition { 910 | color: #48b685 911 | } 912 | 913 | .hljs-keyword, .hljs-selector-tag { 914 | color: #815ba4 915 | } 916 | 917 | .hljs { 918 | display: block; 919 | overflow-x: auto; 920 | background: #e7e9db; 921 | color: #4f424c; 922 | padding: 0.5em 923 | } 924 | 925 | .hljs-emphasis { 926 | font-style: italic 927 | } 928 | 929 | .hljs-strong { 930 | font-weight: bold 931 | } 932 | 933 | .link-icon { 934 | opacity: 0; 935 | position: absolute; 936 | margin-left: -25px; 937 | padding-right: 5px; 938 | padding-top: 2px; 939 | } 940 | 941 | .example-container .link-icon { 942 | margin-top: -6px; 943 | } 944 | 945 | .example-container:hover .link-icon, 946 | .name-container:hover .link-icon { 947 | opacity: .5; 948 | } 949 | 950 | .name-container { 951 | display: flex; 952 | padding-top: 1em; 953 | } 954 | --------------------------------------------------------------------------------