mirror of https://github.com/OpenVidu/openvidu.git
Compare commits
No commits in common. "master" and "v2.6.0" have entirely different histories.
|
@ -1,55 +0,0 @@
|
||||||
---
|
|
||||||
name: Bug report
|
|
||||||
about: Create a report to help us improve
|
|
||||||
title: ''
|
|
||||||
labels: bug
|
|
||||||
assignees: ''
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
<!--
|
|
||||||
IMPORTANT!!! IMPORTANT!!! IMPORTANT!!! IMPORTANT!!!
|
|
||||||
YOU SHOULD NEVER DELETE THE CONTENT OF THIS TEMPLATE WHEN OPENING AN ISSUE. IF YOUR QUESTION DOES NOT FIT THE TEMPLATE THEN IT MOST PROBABLY BELONGS TO OPENVIDU FORUM (https://openvidu.discourse.group/)
|
|
||||||
|
|
||||||
Hi! First of all, welcome to OpenVidu issue tracker. Please, carefully read the two points below before opening a new issue:
|
|
||||||
|
|
||||||
1. Is your question really a bug? In other words: did you actually get an unexpected behavior from OpenVidu platform? If you are not sure about the answer or you just want support for a particular use case, you can post a new question in our official Discourse Forum (https://openvidu.discourse.group/). OpenVidu community or a team's member will reply ASAP.
|
|
||||||
|
|
||||||
2. If your question is undoubtedly a bug, check that there's no other issue (opened or closed) talking about it. Your question may have already been answered! If you cannot find anything useful, please fill the report below.
|
|
||||||
-->
|
|
||||||
|
|
||||||
**Describe the bug**
|
|
||||||
A few words describing what the bug is.
|
|
||||||
|
|
||||||
**Expected behavior**
|
|
||||||
A clear and concise description of what you expected to happen.
|
|
||||||
|
|
||||||
**Wrong current behavior**
|
|
||||||
A clear and concise description of what is actually happening instead of the expected behavior.
|
|
||||||
|
|
||||||
**OpenVidu tutorial where to replicate the error**
|
|
||||||
This is an EXTREMELY IMPORTANT STEP. If we are able to replicate the error in any of the official [OpenVidu Tutorials](https://github.com/OpenVidu/openvidu-tutorials) or [OpenVidu Demos](https://github.com/OpenVidu), then we will be able to quickly fix it. If you are getting the error in your own application, please try to add the necessary changes to the most similar tutorial so it fails with the same error (try to keep those changes as contained as possible, so that the original tutorial maintains its integrity). Once you have an application to replicate the error, explain in detail the steps to get it like this:
|
|
||||||
1. Clone repository [...]
|
|
||||||
2. Compile the application like this [...]
|
|
||||||
3. Run OpenVidu Server like this [...]
|
|
||||||
4. Run the application like this [...]
|
|
||||||
5. Join 1 user... Publish a video stream [...]
|
|
||||||
6. See error
|
|
||||||
|
|
||||||
**OpenVidu deployment info**
|
|
||||||
How is your OpenVidu Server instance deployed when you get the bug. A couple of possible examples are listed below:
|
|
||||||
- Docker container as explained in OpenVidu tutorials, run with command `docker run ...` on macOS Catalina 10.15.1
|
|
||||||
- AWS deployment as explained in OpenVidu Docs (https://docs.openvidu.io/en/stable/deployment/deploying-aws/)
|
|
||||||
|
|
||||||
> **IMPORTANT NOTE**: please, if you think the bug might be related to OpenVidu Server side, specify here if you are also getting the error by using OpenVidu Server Demos instance. This instance is publicly available (use it only for this test, because it is not secure!!!): **URL**: `https://demos.openvidu.io:4443`, **SECRET**: `MY_SECRET`
|
|
||||||
|
|
||||||
**Client device info (if applicable)**
|
|
||||||
Describe the client device(s) or platform(s) where you are able to replicate the error. For example:
|
|
||||||
- Chrome 78.0.3904.97 (Official Build) (64-bit) on Windows 10 (1903).
|
|
||||||
- Firefox Mobile 68.2.0 running on OnePlus 6 with Android 9.
|
|
||||||
|
|
||||||
**Screenshots**
|
|
||||||
If applicable, add screenshots to help explain your problem.
|
|
||||||
|
|
||||||
**Additional context**
|
|
||||||
Add any other context about the problem here. For example, attach any useful logs related to the issue.
|
|
|
@ -1,5 +0,0 @@
|
||||||
blank_issues_enabled: false
|
|
||||||
contact_links:
|
|
||||||
- name: OpenVidu Discourse forum
|
|
||||||
url: https://openvidu.discourse.group/
|
|
||||||
about: If your question is about a certain feature or getting support for a specific use case, please use OpenVidu Discourse Group forum
|
|
|
@ -1,445 +0,0 @@
|
||||||
name: openvidu-components-angular Tests
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
paths:
|
|
||||||
- 'openvidu-components-angular/**'
|
|
||||||
- '.github/workflows/openvidu-components-angular-tests.yml'
|
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
workflow_dispatch:
|
|
||||||
inputs:
|
|
||||||
commit_sha:
|
|
||||||
description: 'Commit SHA'
|
|
||||||
required: false
|
|
||||||
default: ''
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
test_setup:
|
|
||||||
name: Test setup
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Set up Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Commit URL
|
|
||||||
run: echo https://github.com/OpenVidu/openvidu/commit/${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Send Dispatch Event
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.OPENVIDU_DISPATCH_EVENT_GA }}
|
|
||||||
COMMIT_MESSAGE: ${{ github.event.head_commit.message || 'Manually' }}
|
|
||||||
COMMIT_URL: ${{ github.event.commits[0].url || 'Manually' }}
|
|
||||||
BRANCH_NAME: ${{ github.ref_name }}
|
|
||||||
run: |
|
|
||||||
curl -X POST \
|
|
||||||
-H "Accept: application/vnd.github+json" \
|
|
||||||
-H "Authorization: Bearer ${GITHUB_TOKEN}" \
|
|
||||||
https://api.github.com/repos/OpenVidu/openvidu-call/dispatches \
|
|
||||||
-d '{"event_type":"openvidu-components-angular","client_payload":{"commit-message":"'"$COMMIT_MESSAGE"'","commit-ref":"'"$COMMIT_URL"'", "branch-name":"'"$BRANCH_NAME"'"}}'
|
|
||||||
|
|
||||||
nested_events:
|
|
||||||
needs: test_setup
|
|
||||||
name: Nested events
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Install dependencies
|
|
||||||
run: |
|
|
||||||
cd openvidu-components-angular
|
|
||||||
npm install
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run nested components E2E event tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:nested-events --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
nested_structural_directives:
|
|
||||||
needs: test_setup
|
|
||||||
name: Nested Structural Directives
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run nested structural directives tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:nested-structural-directives --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
nested_attribute_directives:
|
|
||||||
needs: test_setup
|
|
||||||
name: Nested Attribute Directives
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run nested attribute directives tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:nested-attribute-directives --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
e2e_directives:
|
|
||||||
needs: test_setup
|
|
||||||
name: API Directives Tests
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-directives --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
e2e_internal_directives:
|
|
||||||
needs: test_setup
|
|
||||||
name: Internal Directives Tests
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-internal-directives --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
e2e_chat:
|
|
||||||
needs: test_setup
|
|
||||||
name: Chat E2E
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-chat --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
e2e_events:
|
|
||||||
needs: test_setup
|
|
||||||
name: Events E2E
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-events --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
e2e_media_devices:
|
|
||||||
needs: test_setup
|
|
||||||
name: Media devices E2E
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-media-devices --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
e2e_panels:
|
|
||||||
needs: test_setup
|
|
||||||
name: Panels E2E
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-panels --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
e2e_screen_sharing:
|
|
||||||
needs: test_setup
|
|
||||||
name: Screen sharing E2E
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-screensharing --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
e2e_stream:
|
|
||||||
needs: test_setup
|
|
||||||
name: Stream E2E
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -v $(pwd)/openvidu-components-angular/e2e/assets:/e2e-assets selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-stream --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
||||||
e2e_toolbar:
|
|
||||||
needs: test_setup
|
|
||||||
name: Toolbar E2E
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
ref: ${{ inputs.commit_sha || github.sha }}
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '20'
|
|
||||||
- name: Install wait-on package
|
|
||||||
run: npm install -g wait-on
|
|
||||||
# - name: Run Browserless Chrome
|
|
||||||
# run: docker run -d -p 3000:3000 --network host browserless/chrome:1.57-chrome-stable
|
|
||||||
- name: Run Chrome
|
|
||||||
run: docker run --network=host -d -p 4444:4444 selenium/standalone-chrome:138.0
|
|
||||||
- name: Run openvidu-local-deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
- name: Start OpenVidu Call backend
|
|
||||||
uses: OpenVidu/actions/start-openvidu-call@main
|
|
||||||
- name: Build and Serve openvidu-components-angular Testapp
|
|
||||||
uses: OpenVidu/actions/start-openvidu-components-testapp@main
|
|
||||||
- name: Run Webcomponent E2E
|
|
||||||
env:
|
|
||||||
LAUNCH_MODE: CI
|
|
||||||
run: npm run e2e:lib-toolbar --prefix openvidu-components-angular
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
|
@ -1,56 +0,0 @@
|
||||||
name: OpenVidu integration tests
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
paths:
|
|
||||||
- "openvidu-test-integration/**"
|
|
||||||
- ".github/workflows/openvidu-integration-tests.yml"
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
integration-tests:
|
|
||||||
name: Integration tests
|
|
||||||
timeout-minutes: 30
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Configure OpenVidu Local Deployment
|
|
||||||
uses: OpenVidu/actions/start-openvidu-local-deployment@main
|
|
||||||
with:
|
|
||||||
ref-openvidu-local-deployment: development
|
|
||||||
pre_startup_commands: |
|
|
||||||
sed -i 's/interval: 10s/interval: 1s/' livekit.yaml
|
|
||||||
sed -i '/interval: 1s/a \ fixer_interval: 10s' livekit.yaml
|
|
||||||
- name: Install LiveKit CLI
|
|
||||||
run: |
|
|
||||||
curl -sSL https://get.livekit.io/cli | bash
|
|
||||||
|
|
||||||
- name: Checkout current repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
path: openvidu
|
|
||||||
|
|
||||||
- name: Setup Node
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: 22
|
|
||||||
|
|
||||||
- name: Install dependencies
|
|
||||||
working-directory: ./openvidu/openvidu-test-integration
|
|
||||||
run: npm ci
|
|
||||||
|
|
||||||
- name: Run tests
|
|
||||||
working-directory: ./openvidu/openvidu-test-integration
|
|
||||||
run: npm run test:ci
|
|
||||||
|
|
||||||
- name: Upload report
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
if: always()
|
|
||||||
with:
|
|
||||||
name: openvidu-integration-tests-report
|
|
||||||
path: ./openvidu/openvidu-test-integration/test-results.json
|
|
||||||
retention-days: 7
|
|
||||||
- name: Cleanup
|
|
||||||
if: always()
|
|
||||||
uses: OpenVidu/actions/cleanup@main
|
|
||||||
|
|
|
@ -4,10 +4,8 @@
|
||||||
|
|
||||||
/target
|
/target
|
||||||
.classpath
|
.classpath
|
||||||
.idea
|
|
||||||
.project
|
.project
|
||||||
.settings
|
.settings
|
||||||
*.iml
|
|
||||||
*orig
|
*orig
|
||||||
.springBeans
|
.springBeans
|
||||||
*tmp/
|
*tmp/
|
||||||
|
@ -19,11 +17,8 @@ nbactions.xml
|
||||||
.externalToolBuilders
|
.externalToolBuilders
|
||||||
*bin/
|
*bin/
|
||||||
*/.vscode/*
|
*/.vscode/*
|
||||||
.vscode/*
|
|
||||||
*/.sts4-cache/*
|
*/.sts4-cache/*
|
||||||
*/.project
|
*/.project
|
||||||
*/.classpath
|
*/.classpath
|
||||||
*/.settings/*
|
*/.settings/*
|
||||||
*/.tscache/*
|
*/.tscache/*
|
||||||
|
|
||||||
.factorypath
|
|
||||||
|
|
|
@ -1,3 +0,0 @@
|
||||||
[submodule "openvidu-livekit"]
|
|
||||||
path = openvidu-livekit
|
|
||||||
url = https://github.com/OpenVidu/openvidu-livekit.git
|
|
2
NOTICE
2
NOTICE
|
@ -1,4 +1,4 @@
|
||||||
(C) Copyright 2017-2022 OpenVidu (https://openvidu.io)
|
(C) Copyright 2017-2018 OpenVidu (https://openvidu.io)
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
you may not use this file except in compliance with the License.
|
you may not use this file except in compliance with the License.
|
||||||
|
|
26
README.md
26
README.md
|
@ -1,14 +1,7 @@
|
||||||
[](#backers) [](#sponsors)
|
[](#backers) [](#sponsors) [](http://www.apache.org/licenses/LICENSE-2.0)
|
||||||
[](http://www.apache.org/licenses/LICENSE-2.0)
|
[](https://openvidu.io/docs/home/)
|
||||||
[](https://github.com/OpenVidu/openvidu/actions/workflows/openvidu-ce-test.yml)
|
[](https://hub.docker.com/r/openvidu/)
|
||||||
[](https://npmjs.org/package/openvidu-browser)
|
[](https://groups.google.com/forum/#!forum/openvidu)
|
||||||
[](https://npmjs.org/package/openvidu-browser)
|
|
||||||
|
|
||||||
|
|
||||||
[](https://docs.openvidu.io/en/stable/?badge=stable)
|
|
||||||
[](https://hub.docker.com/r/openvidu/openvidu-server-kms)
|
|
||||||
[](https://openvidu.discourse.group/)
|
|
||||||
[](https://twitter.com/openvidu)
|
|
||||||
|
|
||||||
[![][OpenViduLogo]](https://openvidu.io)
|
[![][OpenViduLogo]](https://openvidu.io)
|
||||||
|
|
||||||
|
@ -17,16 +10,12 @@ openvidu
|
||||||
|
|
||||||
Visit [openvidu.io](https://openvidu.io)
|
Visit [openvidu.io](https://openvidu.io)
|
||||||
|
|
||||||
## Community Forum
|
|
||||||
|
|
||||||
Visit [OpenVidu Community Forum](https://openvidu.discourse.group/)
|
|
||||||
|
|
||||||
[OpenViduLogo]: https://secure.gravatar.com/avatar/5daba1d43042f2e4e85849733c8e5702?s=120
|
[OpenViduLogo]: https://secure.gravatar.com/avatar/5daba1d43042f2e4e85849733c8e5702?s=120
|
||||||
|
|
||||||
## Contributors
|
## Contributors
|
||||||
|
|
||||||
This project exists thanks to all the people who contribute.
|
This project exists thanks to all the people who contribute.
|
||||||
<a href="https://github.com/OpenVidu/openvidu/contributors"><img src="https://opencollective.com/openvidu/contributors.svg?width=890&button=false" /></a>
|
<a href="https://github.com/undefined/undefinedgraphs/contributors"><img src="https://opencollective.com/openvidu/contributors.svg?width=890&button=false" /></a>
|
||||||
|
|
||||||
|
|
||||||
## Backers
|
## Backers
|
||||||
|
@ -35,11 +24,6 @@ Thank you to all our backers! 🙏 [[Become a backer](https://opencollective.com
|
||||||
|
|
||||||
<a href="https://opencollective.com/openvidu#backers" target="_blank"><img src="https://opencollective.com/openvidu/backers.svg?width=890"></a>
|
<a href="https://opencollective.com/openvidu#backers" target="_blank"><img src="https://opencollective.com/openvidu/backers.svg?width=890"></a>
|
||||||
|
|
||||||
## Acknowledgments
|
|
||||||
|
|
||||||
OpenVidu has been supported under project "CPP2021-008720 NewGenVidu: An elastic, user-friendly and privacy-friendly videoconferencing platform", funded by MCIN/AEI/10.13039/501100011033 and by the European Union-NextGenerationEU/PRTR.
|
|
||||||
|
|
||||||
<img height="75px" src="https://docs.openvidu.io/en/stable/img/logos/support.jpg">
|
|
||||||
|
|
||||||
## Sponsors
|
## Sponsors
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,61 @@
|
||||||
|
# Logs
|
||||||
|
logs
|
||||||
|
*.log
|
||||||
|
npm-debug.log*
|
||||||
|
yarn-debug.log*
|
||||||
|
yarn-error.log*
|
||||||
|
|
||||||
|
# Runtime data
|
||||||
|
pids
|
||||||
|
*.pid
|
||||||
|
*.seed
|
||||||
|
*.pid.lock
|
||||||
|
|
||||||
|
# Directory for instrumented libs generated by jscoverage/JSCover
|
||||||
|
lib-cov
|
||||||
|
|
||||||
|
# Coverage directory used by tools like istanbul
|
||||||
|
coverage
|
||||||
|
|
||||||
|
# nyc test coverage
|
||||||
|
.nyc_output
|
||||||
|
|
||||||
|
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
|
||||||
|
.grunt
|
||||||
|
|
||||||
|
# Bower dependency directory (https://bower.io/)
|
||||||
|
bower_components
|
||||||
|
|
||||||
|
# node-waf configuration
|
||||||
|
.lock-wscript
|
||||||
|
|
||||||
|
# Compiled binary addons (http://nodejs.org/api/addons.html)
|
||||||
|
build/Release
|
||||||
|
|
||||||
|
# Dependency directories
|
||||||
|
node_modules/
|
||||||
|
jspm_packages/
|
||||||
|
|
||||||
|
# Typescript v1 declaration files
|
||||||
|
typings/
|
||||||
|
|
||||||
|
# Optional npm cache directory
|
||||||
|
.npm
|
||||||
|
|
||||||
|
# Optional eslint cache
|
||||||
|
.eslintcache
|
||||||
|
|
||||||
|
# Optional REPL history
|
||||||
|
.node_repl_history
|
||||||
|
|
||||||
|
# Output of 'npm pack'
|
||||||
|
*.tgz
|
||||||
|
|
||||||
|
# Yarn Integrity file
|
||||||
|
.yarn-integrity
|
||||||
|
|
||||||
|
# dotenv environment variables file
|
||||||
|
.env
|
||||||
|
|
||||||
|
docs/
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
docs/
|
|
@ -0,0 +1,150 @@
|
||||||
|
{
|
||||||
|
"extends": "tslint:recommended",
|
||||||
|
"rules": {
|
||||||
|
"array-type": [
|
||||||
|
true,
|
||||||
|
"array"
|
||||||
|
],
|
||||||
|
"ban-types": {
|
||||||
|
"options": [
|
||||||
|
[
|
||||||
|
"Function",
|
||||||
|
"Avoid using the `Function` type. Prefer a specific function type, like `() => void`, or use `ts.AnyFunction`."
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"Boolean",
|
||||||
|
"Avoid using the `Boolean` type. Did you mean `boolean`?"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"Number",
|
||||||
|
"Avoid using the `Number` type. Did you mean `number`?"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
"String",
|
||||||
|
"Avoid using the `String` type. Did you mean `string`?"
|
||||||
|
]
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"class-name": true,
|
||||||
|
"comment-format": [
|
||||||
|
true,
|
||||||
|
"check-space"
|
||||||
|
],
|
||||||
|
"curly": [
|
||||||
|
true,
|
||||||
|
"ignore-same-line"
|
||||||
|
],
|
||||||
|
"indent": [
|
||||||
|
true,
|
||||||
|
"spaces",
|
||||||
|
4
|
||||||
|
],
|
||||||
|
"interface-name": [
|
||||||
|
true,
|
||||||
|
"never-prefix"
|
||||||
|
],
|
||||||
|
"interface-over-type-literal": true,
|
||||||
|
"jsdoc-format": true,
|
||||||
|
"no-inferrable-types": true,
|
||||||
|
"no-internal-module": true,
|
||||||
|
"no-null-keyword": false,
|
||||||
|
"no-switch-case-fall-through": true,
|
||||||
|
"no-trailing-whitespace": [
|
||||||
|
true,
|
||||||
|
"ignore-template-strings"
|
||||||
|
],
|
||||||
|
"no-var-keyword": true,
|
||||||
|
"object-literal-shorthand": true,
|
||||||
|
"one-line": [
|
||||||
|
true,
|
||||||
|
"check-open-brace",
|
||||||
|
"check-whitespace"
|
||||||
|
],
|
||||||
|
"prefer-const": true,
|
||||||
|
"quotemark": [
|
||||||
|
true,
|
||||||
|
"single",
|
||||||
|
"avoid-escape",
|
||||||
|
"avoid-template"
|
||||||
|
],
|
||||||
|
"semicolon": [
|
||||||
|
true,
|
||||||
|
"always",
|
||||||
|
"ignore-bound-class-methods"
|
||||||
|
],
|
||||||
|
"space-within-parens": true,
|
||||||
|
"triple-equals": true,
|
||||||
|
"typedef-whitespace": [
|
||||||
|
true,
|
||||||
|
{
|
||||||
|
"call-signature": "nospace",
|
||||||
|
"index-signature": "nospace",
|
||||||
|
"parameter": "nospace",
|
||||||
|
"property-declaration": "nospace",
|
||||||
|
"variable-declaration": "nospace"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"call-signature": "onespace",
|
||||||
|
"index-signature": "onespace",
|
||||||
|
"parameter": "onespace",
|
||||||
|
"property-declaration": "onespace",
|
||||||
|
"variable-declaration": "onespace"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"whitespace": [
|
||||||
|
true,
|
||||||
|
"check-branch",
|
||||||
|
"check-decl",
|
||||||
|
"check-operator",
|
||||||
|
"check-module",
|
||||||
|
"check-separator",
|
||||||
|
"check-type"
|
||||||
|
],
|
||||||
|
"no-implicit-dependencies": [
|
||||||
|
true,
|
||||||
|
"dev"
|
||||||
|
],
|
||||||
|
"object-literal-key-quotes": [
|
||||||
|
true,
|
||||||
|
"consistent-as-needed"
|
||||||
|
],
|
||||||
|
"variable-name": [
|
||||||
|
true,
|
||||||
|
"ban-keywords",
|
||||||
|
"check-format",
|
||||||
|
"allow-leading-underscore"
|
||||||
|
],
|
||||||
|
"arrow-parens": false,
|
||||||
|
"arrow-return-shorthand": false,
|
||||||
|
"forin": false,
|
||||||
|
"member-access": false,
|
||||||
|
"no-conditional-assignment": false,
|
||||||
|
"no-console": false,
|
||||||
|
"no-debugger": false,
|
||||||
|
"no-empty-interface": false,
|
||||||
|
"no-eval": false,
|
||||||
|
"no-object-literal-type-assertion": false,
|
||||||
|
"no-shadowed-variable": false,
|
||||||
|
"no-submodule-imports": false,
|
||||||
|
"no-var-requires": false,
|
||||||
|
"ordered-imports": false,
|
||||||
|
"prefer-conditional-expression": false,
|
||||||
|
"radix": false,
|
||||||
|
"trailing-comma": false,
|
||||||
|
"align": false,
|
||||||
|
"eofline": false,
|
||||||
|
"max-line-length": false,
|
||||||
|
"no-consecutive-blank-lines": false,
|
||||||
|
"space-before-function-paren": false,
|
||||||
|
"ban-comma-operator": false,
|
||||||
|
"max-classes-per-file": false,
|
||||||
|
"member-ordering": false,
|
||||||
|
"no-angle-bracket-type-assertion": false,
|
||||||
|
"no-bitwise": false,
|
||||||
|
"no-namespace": false,
|
||||||
|
"no-reference": false,
|
||||||
|
"object-literal-sort-keys": false,
|
||||||
|
"one-variable-per-declaration": false,
|
||||||
|
"unified-signatures": false
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,39 @@
|
||||||
|
// Fonts
|
||||||
|
//
|
||||||
|
$FONT_FAMILY: 'Segoe UI', sans-serif
|
||||||
|
$FONT_FAMILY_MONO: Menlo, Monaco, Consolas, 'Courier New', monospace
|
||||||
|
|
||||||
|
$FONT_SIZE: 16px
|
||||||
|
$FONT_SIZE_MONO: 14px
|
||||||
|
|
||||||
|
$LINE_HEIGHT: 1.333em
|
||||||
|
|
||||||
|
|
||||||
|
// Colors
|
||||||
|
//
|
||||||
|
$COLOR_BACKGROUND: #fdfdfd
|
||||||
|
$COLOR_TEXT: #222
|
||||||
|
$COLOR_TEXT_ASIDE: #808080
|
||||||
|
$COLOR_LINK: #4da6ff
|
||||||
|
|
||||||
|
$COLOR_MENU_DIVIDER: #eee
|
||||||
|
$COLOR_MENU_DIVIDER_FOCUS: #000
|
||||||
|
$COLOR_MENU_LABEL: #808080
|
||||||
|
|
||||||
|
$COLOR_PANEL: #fff
|
||||||
|
$COLOR_PANEL_DIVIDER: #eee
|
||||||
|
|
||||||
|
$COLOR_COMMENT_TAG: #808080
|
||||||
|
$COLOR_COMMENT_TAG_TEXT: #fff
|
||||||
|
|
||||||
|
$COLOR_CODE_BACKGROUND: rgba(#000, 0.04)
|
||||||
|
|
||||||
|
$COLOR_TS: #9600ff
|
||||||
|
$COLOR_TS_INTERFACE: #7da01f
|
||||||
|
$COLOR_TS_ENUM: #cc9900
|
||||||
|
$COLOR_TS_CLASS: #4da6ff
|
||||||
|
$COLOR_TS_PRIVATE: #808080
|
||||||
|
|
||||||
|
$TOOLBAR_COLOR: #fff
|
||||||
|
$TOOLBAR_TEXT_COLOR: #333
|
||||||
|
$TOOLBAR_HEIGHT: 40px
|
|
@ -0,0 +1,53 @@
|
||||||
|
// Displays all regular comment tags
|
||||||
|
//
|
||||||
|
// <dl class="tsd-comment-tags">
|
||||||
|
// <dt>see</dt>
|
||||||
|
// <dd><p><a href="#">Dispatcher.EVENT_BEGIN</a></p></dd>
|
||||||
|
// <dt>see</dt>
|
||||||
|
// <dd><p><a href="#">Dispatcher.EVENT_BEGIN_RESOLVE</a></p></dd>
|
||||||
|
// <dt>see</dt>
|
||||||
|
// <dd><p><a href="#">Dispatcher.EVENT_END_RESOLVE</a></p></dd>
|
||||||
|
// </dl>
|
||||||
|
//
|
||||||
|
dl.tsd-comment-tags
|
||||||
|
overflow: hidden
|
||||||
|
|
||||||
|
dt
|
||||||
|
float: left
|
||||||
|
padding: 1px 5px
|
||||||
|
margin: 0 10px 0 0
|
||||||
|
border-radius: 4px
|
||||||
|
border: 1px solid $COLOR_COMMENT_TAG
|
||||||
|
color: $COLOR_COMMENT_TAG
|
||||||
|
font-size: 0.8em
|
||||||
|
font-weight: normal
|
||||||
|
|
||||||
|
dd
|
||||||
|
margin: 0 0 10px 0
|
||||||
|
|
||||||
|
&:before, &:after
|
||||||
|
display: table
|
||||||
|
content: " "
|
||||||
|
pre, &:after
|
||||||
|
clear: both
|
||||||
|
|
||||||
|
p
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
|
||||||
|
// Special formatting for the main reflection on each page.
|
||||||
|
//
|
||||||
|
// <section class="tsd-panel tsd-comment">
|
||||||
|
// <div class="tsd-comment tsd-typography">
|
||||||
|
// <div class="lead"><p>The default TypeDoc main application class.</p></div>
|
||||||
|
// <p>This class holds the two main components of TypeDoc, the Dispatcher and the Renderer.</p>
|
||||||
|
// </div>
|
||||||
|
// </section>
|
||||||
|
//
|
||||||
|
.tsd-panel.tsd-comment .lead
|
||||||
|
font-size: 1.1em
|
||||||
|
line-height: $LINE_HEIGHT
|
||||||
|
margin-bottom: 2em
|
||||||
|
|
||||||
|
&:last-child
|
||||||
|
margin-bottom: 0
|
|
@ -0,0 +1,65 @@
|
||||||
|
// Classes set on the body to control the visible state of the filtered elements
|
||||||
|
//
|
||||||
|
.toggle-protected .tsd-is-private
|
||||||
|
display: none
|
||||||
|
|
||||||
|
.toggle-public .tsd-is-private,
|
||||||
|
.toggle-public .tsd-is-protected,
|
||||||
|
.toggle-public .tsd-is-private-protected
|
||||||
|
display: none
|
||||||
|
|
||||||
|
.toggle-inherited .tsd-is-inherited
|
||||||
|
display: none
|
||||||
|
|
||||||
|
.toggle-only-exported .tsd-is-not-exported
|
||||||
|
display: none
|
||||||
|
|
||||||
|
.toggle-externals .tsd-is-external
|
||||||
|
display: none
|
||||||
|
|
||||||
|
|
||||||
|
// Filter Buttons in the toolbar
|
||||||
|
//
|
||||||
|
#tsd-filter
|
||||||
|
position: relative
|
||||||
|
display: inline-block
|
||||||
|
height: $TOOLBAR_HEIGHT
|
||||||
|
vertical-align: bottom
|
||||||
|
|
||||||
|
.no-filter &
|
||||||
|
display: none
|
||||||
|
|
||||||
|
.tsd-filter-group
|
||||||
|
display: inline-block
|
||||||
|
height: $TOOLBAR_HEIGHT
|
||||||
|
vertical-align: bottom
|
||||||
|
white-space: nowrap
|
||||||
|
|
||||||
|
input
|
||||||
|
display: none
|
||||||
|
|
||||||
|
+size-xs-sm
|
||||||
|
.tsd-filter-group
|
||||||
|
display: block
|
||||||
|
position: absolute
|
||||||
|
top: $TOOLBAR_HEIGHT
|
||||||
|
right: 20px
|
||||||
|
height: auto
|
||||||
|
background-color: $COLOR_PANEL
|
||||||
|
visibility: hidden
|
||||||
|
transform: translate(50%,0)
|
||||||
|
box-shadow: 0 0 4px rgba(#000, 0.25)
|
||||||
|
|
||||||
|
.has-options &
|
||||||
|
visibility: visible
|
||||||
|
|
||||||
|
.to-has-options &
|
||||||
|
animation: fade-in 0.2s
|
||||||
|
|
||||||
|
.from-has-options &
|
||||||
|
animation: fade-out 0.2s
|
||||||
|
|
||||||
|
label,
|
||||||
|
.tsd-select
|
||||||
|
display: block
|
||||||
|
padding-right: 20px
|
|
@ -0,0 +1,21 @@
|
||||||
|
footer
|
||||||
|
border-top: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
background-color: $COLOR_PANEL
|
||||||
|
|
||||||
|
&.with-border-bottom
|
||||||
|
border-bottom: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
.tsd-legend-group
|
||||||
|
font-size: 0
|
||||||
|
|
||||||
|
.tsd-legend
|
||||||
|
display: inline-block
|
||||||
|
width: 25%
|
||||||
|
padding: 0
|
||||||
|
font-size: $FONT_SIZE
|
||||||
|
list-style: none
|
||||||
|
line-height: $LINE_HEIGHT
|
||||||
|
vertical-align: top
|
||||||
|
|
||||||
|
+size-xs-sm
|
||||||
|
width: 50%
|
|
@ -0,0 +1,24 @@
|
||||||
|
// Displays the type hierarchy
|
||||||
|
//
|
||||||
|
// <ul class="tsd-hierarchy">
|
||||||
|
// <li>
|
||||||
|
// <a href="#" class="tsd-signature-type">Event</a>
|
||||||
|
// <ul class="tsd-hierarchy">
|
||||||
|
// <li>
|
||||||
|
// <span class="target">DispatcherEvent</span>
|
||||||
|
// <ul class="tsd-hierarchy">
|
||||||
|
// <li><a href="#" class="tsd-signature-type">BaseState</a></li>
|
||||||
|
// <li><a href="#" class="tsd-signature-type">ReflectionEvent</a></li>
|
||||||
|
// </ul>
|
||||||
|
// </li>
|
||||||
|
// </ul>
|
||||||
|
// </li>
|
||||||
|
// </ul>
|
||||||
|
//
|
||||||
|
.tsd-hierarchy
|
||||||
|
list-style: square
|
||||||
|
padding: 0 0 0 20px
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
.target
|
||||||
|
font-weight: bold
|
|
@ -0,0 +1,3 @@
|
||||||
|
// fixes issue with images in readme
|
||||||
|
img
|
||||||
|
max-width: 100%
|
|
@ -0,0 +1,80 @@
|
||||||
|
// Displays an index of grouped links.
|
||||||
|
//
|
||||||
|
// <section class="tsd-panel tsd-index-panel">
|
||||||
|
// <div class="tsd-index-content">
|
||||||
|
// <div class="tsd-index-section">
|
||||||
|
// <h3>Constructor methods</h3>
|
||||||
|
// <ul class="tsd-member-index">
|
||||||
|
// <li class="tsd-kind-constructor-method tsd-parent-kind-class"><a href="#" class="tsd-kind-icon">constructor</a></li>
|
||||||
|
// </ul>
|
||||||
|
// </div>
|
||||||
|
// <div class="tsd-index-section">
|
||||||
|
// <h3>Properties</h3>
|
||||||
|
// <ul class="tsd-member-index">
|
||||||
|
// <li class="tsd-kind-property tsd-parent-kind-class"><a href="#" class="tsd-kind-icon">EVENT_<wbr>BEGIN</a></li>
|
||||||
|
// <li class="tsd-kind-property tsd-parent-kind-class"><a href="#" class="tsd-kind-icon">EVENT_<wbr>BEGIN_<wbr>DECLARATION</a></li>
|
||||||
|
// <li class="tsd-kind-property tsd-parent-kind-class"><a href="#" class="tsd-kind-icon">EVENT_<wbr>BEGIN_<wbr>DOCUMENT</a></li>
|
||||||
|
// <li class="tsd-kind-property tsd-parent-kind-class"><a href="#" class="tsd-kind-icon">EVENT_<wbr>BEGIN_<wbr>RESOLVE</a></li>
|
||||||
|
// </ul>
|
||||||
|
// </div>
|
||||||
|
// </div>
|
||||||
|
// </section>
|
||||||
|
//
|
||||||
|
.tsd-index-panel
|
||||||
|
.tsd-index-content
|
||||||
|
margin-bottom: -30px !important
|
||||||
|
|
||||||
|
.tsd-index-section
|
||||||
|
margin-bottom: 30px !important
|
||||||
|
|
||||||
|
h3
|
||||||
|
@extend h4
|
||||||
|
margin: 0 -20px 10px -20px
|
||||||
|
padding: 0 20px 10px 20px
|
||||||
|
border-bottom: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
ul.tsd-index-list
|
||||||
|
+vendors(column-count, 3)
|
||||||
|
+vendors(column-gap, 20px)
|
||||||
|
padding: 0
|
||||||
|
list-style: none
|
||||||
|
line-height: $LINE_HEIGHT
|
||||||
|
|
||||||
|
+size-xs-sm
|
||||||
|
+vendors(column-count, 1)
|
||||||
|
|
||||||
|
+size-md
|
||||||
|
+vendors(column-count, 2)
|
||||||
|
|
||||||
|
li
|
||||||
|
+vendors(column-break-inside, avoid)
|
||||||
|
+vendors(page-break-inside, avoid)
|
||||||
|
|
||||||
|
a,
|
||||||
|
.tsd-parent-kind-module a
|
||||||
|
color: $COLOR_TS
|
||||||
|
|
||||||
|
.tsd-parent-kind-interface a
|
||||||
|
color: $COLOR_TS_INTERFACE
|
||||||
|
|
||||||
|
.tsd-parent-kind-enum a
|
||||||
|
color: $COLOR_TS_ENUM
|
||||||
|
|
||||||
|
.tsd-parent-kind-class a
|
||||||
|
color: $COLOR_TS_CLASS
|
||||||
|
|
||||||
|
|
||||||
|
.tsd-kind-module a
|
||||||
|
color: $COLOR_TS
|
||||||
|
|
||||||
|
.tsd-kind-interface a
|
||||||
|
color: $COLOR_TS_INTERFACE
|
||||||
|
|
||||||
|
.tsd-kind-enum a
|
||||||
|
color: $COLOR_TS_ENUM
|
||||||
|
|
||||||
|
.tsd-kind-class a
|
||||||
|
color: $COLOR_TS_CLASS
|
||||||
|
|
||||||
|
.tsd-is-private a
|
||||||
|
color: $COLOR_TS_PRIVATE
|
|
@ -0,0 +1,21 @@
|
||||||
|
.tsd-flag
|
||||||
|
display: inline-block
|
||||||
|
padding: 1px 5px
|
||||||
|
border-radius: 4px
|
||||||
|
color: $COLOR_COMMENT_TAG_TEXT
|
||||||
|
background-color: $COLOR_COMMENT_TAG
|
||||||
|
text-indent: 0
|
||||||
|
font-size: $FONT_SIZE_MONO
|
||||||
|
font-weight: normal
|
||||||
|
|
||||||
|
.tsd-anchor
|
||||||
|
position: absolute
|
||||||
|
top: -100px
|
||||||
|
|
||||||
|
.tsd-member
|
||||||
|
position: relative
|
||||||
|
|
||||||
|
.tsd-anchor + h3
|
||||||
|
margin-top: 0
|
||||||
|
margin-bottom: 0
|
||||||
|
border-bottom: none
|
|
@ -0,0 +1,162 @@
|
||||||
|
// Base format for the navigation parts.
|
||||||
|
//
|
||||||
|
=INDENT($DEPTH, $BASE, $STEP, $PROGRESS:$DEPTH)
|
||||||
|
@if $PROGRESS > 0
|
||||||
|
& li
|
||||||
|
+INDENT($DEPTH, $BASE, $STEP, $PROGRESS - 1)
|
||||||
|
@else
|
||||||
|
& a
|
||||||
|
padding-left: #{($BASE + $STEP * ($DEPTH - 1))}px
|
||||||
|
|
||||||
|
=INDENTS($COUNT, $BASE, $STEP)
|
||||||
|
@for $DEPTH from 1 through $COUNT
|
||||||
|
+INDENT($DEPTH, $BASE, $STEP)
|
||||||
|
|
||||||
|
.tsd-navigation
|
||||||
|
padding: 0 0 0 40px
|
||||||
|
|
||||||
|
a
|
||||||
|
display: block
|
||||||
|
padding-top: 2px
|
||||||
|
padding-bottom: 2px
|
||||||
|
border-left: 2px solid transparent
|
||||||
|
color: $COLOR_TEXT
|
||||||
|
text-decoration: none
|
||||||
|
transition: border-left-color 0.1s
|
||||||
|
|
||||||
|
&:hover
|
||||||
|
text-decoration: underline
|
||||||
|
|
||||||
|
ul
|
||||||
|
margin: 0
|
||||||
|
padding: 0
|
||||||
|
list-style: none
|
||||||
|
|
||||||
|
li
|
||||||
|
padding: 0
|
||||||
|
|
||||||
|
|
||||||
|
// Primary part of the navigation containing the available modules.
|
||||||
|
//
|
||||||
|
// <nav class="tsd-navigation primary">
|
||||||
|
// <ul>
|
||||||
|
// <li class="globals"><a href="#"><em>Globals</em></a></li>
|
||||||
|
// <li class="current tsd-kind-container">
|
||||||
|
// <a href="#">TypeDoc</a>
|
||||||
|
// <ul>
|
||||||
|
// <li class="tsd-kind-container tsd-parent-kind-container"><a href="#">Factories</a></li>
|
||||||
|
// <li class="tsd-kind-container tsd-parent-kind-container"><a href="#">Models</a></li>
|
||||||
|
// <li class="current tsd-kind-container tsd-parent-kind-container"><a href="#">Output</a></li>
|
||||||
|
// </ul>
|
||||||
|
// </li>
|
||||||
|
// </ul>
|
||||||
|
// </nav>
|
||||||
|
//
|
||||||
|
.tsd-navigation.primary
|
||||||
|
padding-bottom: 40px
|
||||||
|
|
||||||
|
a
|
||||||
|
display: block
|
||||||
|
padding-top: 6px
|
||||||
|
padding-bottom: 6px
|
||||||
|
|
||||||
|
ul
|
||||||
|
+INDENTS(6, 5, 20)
|
||||||
|
|
||||||
|
> ul
|
||||||
|
border-bottom: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
li
|
||||||
|
border-top: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
&.current > a
|
||||||
|
font-weight: bold
|
||||||
|
|
||||||
|
&.label span
|
||||||
|
display: block
|
||||||
|
padding: 20px 0 6px 5px
|
||||||
|
color: $COLOR_MENU_LABEL
|
||||||
|
|
||||||
|
&.globals + li > span,
|
||||||
|
&.globals + li > a
|
||||||
|
padding-top: 20px
|
||||||
|
|
||||||
|
|
||||||
|
// Secondary part of the navigation containing the table of contents
|
||||||
|
// of the current module.
|
||||||
|
// Can be made sticky by `typedoc.MenuSticky` and will highlight current sticky with `typedoc.MenuHighlight`.
|
||||||
|
//
|
||||||
|
// <nav class="tsd-navigation secondary">
|
||||||
|
// <ul class="before-current">
|
||||||
|
// <li class="tsd-kind-class tsd-parent-kind-container"><a href="#" class="tsd-kind-icon">AssetsPlugin</a></li>
|
||||||
|
// <li class="tsd-kind-class tsd-parent-kind-container"><a href="#" class="tsd-kind-icon">BasePlugin</a></li>
|
||||||
|
// <li class="tsd-kind-class tsd-parent-kind-container"><a href="#" class="tsd-kind-icon">BaseTheme</a></li>
|
||||||
|
// </ul>
|
||||||
|
// <ul class="current">
|
||||||
|
// <li class="current tsd-kind-class tsd-parent-kind-container">
|
||||||
|
// <a href="#" class="tsd-kind-icon">OutputEvent</a>
|
||||||
|
// <ul>
|
||||||
|
// <li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><a href="#" class="tsd-kind-icon">isDefaultPrevented</a></li>
|
||||||
|
// <li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><a href="#" class="tsd-kind-icon">isPropagationStopped</a></li>
|
||||||
|
// <li class="tsd-kind-property tsd-parent-kind-class"><a href="#" class="tsd-kind-icon">outputDirectory</a></li>
|
||||||
|
// <li class="tsd-kind-property tsd-parent-kind-class"><a href="#" class="tsd-kind-icon">project</a></li>
|
||||||
|
// </ul>
|
||||||
|
// </li>
|
||||||
|
// </ul>
|
||||||
|
// <ul class="after-current">
|
||||||
|
// <li class="tsd-kind-class tsd-parent-kind-container"><a href="#" class="tsd-kind-icon">OutputPageEvent</a></li>
|
||||||
|
// <li class="tsd-kind-class tsd-parent-kind-container"><a href="#" class="tsd-kind-icon">PartialsPlugin</a></li>
|
||||||
|
// </ul>
|
||||||
|
// </nav>
|
||||||
|
//
|
||||||
|
.tsd-navigation.secondary
|
||||||
|
ul
|
||||||
|
+INDENTS(6, 25, 20)
|
||||||
|
transition: opacity 0.2s
|
||||||
|
|
||||||
|
&.current a
|
||||||
|
border-left-color: $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
li.focus > a,
|
||||||
|
ul.current li.focus > a
|
||||||
|
border-left-color: $COLOR_MENU_DIVIDER_FOCUS
|
||||||
|
|
||||||
|
li.current
|
||||||
|
margin-top: 20px
|
||||||
|
margin-bottom: 20px
|
||||||
|
border-left-color: $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
> a
|
||||||
|
font-weight: bold
|
||||||
|
|
||||||
|
|
||||||
|
// Sticky menu setup
|
||||||
|
//
|
||||||
|
.menu-sticky-wrap
|
||||||
|
+size-md-lg
|
||||||
|
position: static
|
||||||
|
|
||||||
|
.no-csspositionsticky &
|
||||||
|
&.sticky
|
||||||
|
position: fixed
|
||||||
|
|
||||||
|
&.sticky-current
|
||||||
|
position: fixed
|
||||||
|
|
||||||
|
ul.before-current,
|
||||||
|
ul.after-current
|
||||||
|
opacity: 0
|
||||||
|
|
||||||
|
&.sticky-bottom
|
||||||
|
position: absolute
|
||||||
|
top: auto !important
|
||||||
|
left: auto !important
|
||||||
|
bottom: 0
|
||||||
|
right: 0
|
||||||
|
|
||||||
|
.csspositionsticky &
|
||||||
|
&.sticky
|
||||||
|
position: sticky
|
||||||
|
|
||||||
|
&.sticky-current
|
||||||
|
position: sticky
|
|
@ -0,0 +1,70 @@
|
||||||
|
// Displays a panel, an organisation unit in TypeDoc used to group single entities
|
||||||
|
// like a method or a variable.
|
||||||
|
//
|
||||||
|
// <div class="tsd-panel">
|
||||||
|
// <h3>Eirmod tempor invidunt</h3>
|
||||||
|
// <p>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat.</p>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
.tsd-panel
|
||||||
|
@extend %prevent-children-margin
|
||||||
|
margin: 20px 0
|
||||||
|
padding: 20px
|
||||||
|
background-color: $COLOR_PANEL
|
||||||
|
box-shadow: 0 0 4px rgba(#000, 0.25)
|
||||||
|
|
||||||
|
&:empty
|
||||||
|
display: none
|
||||||
|
|
||||||
|
> h1, > h2, > h3
|
||||||
|
margin: 1.5em -20px 10px -20px
|
||||||
|
padding: 0 20px 10px 20px
|
||||||
|
border-bottom: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
&.tsd-before-signature
|
||||||
|
margin-bottom: 0
|
||||||
|
border-bottom: 0
|
||||||
|
|
||||||
|
table
|
||||||
|
display: block
|
||||||
|
width: 100%
|
||||||
|
overflow: auto
|
||||||
|
margin-top: 10px
|
||||||
|
word-break: normal
|
||||||
|
word-break: keep-all
|
||||||
|
|
||||||
|
th
|
||||||
|
font-weight: bold
|
||||||
|
|
||||||
|
th, td
|
||||||
|
padding: 6px 13px
|
||||||
|
border: 1px solid #ddd
|
||||||
|
|
||||||
|
tr
|
||||||
|
background-color: #fff
|
||||||
|
border-top: 1px solid #ccc
|
||||||
|
|
||||||
|
&:nth-child(2n)
|
||||||
|
background-color: #f8f8f8
|
||||||
|
|
||||||
|
|
||||||
|
// Holds a series of panels with an optional heading.
|
||||||
|
//
|
||||||
|
// <div class="tsd-panel-group">
|
||||||
|
// <h2>Consetetur sadipscing elitr</h2>
|
||||||
|
// <div class="tsd-panel">
|
||||||
|
// <h3>Eirmod tempor invidunt</h3>
|
||||||
|
// <p>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat.</p>
|
||||||
|
// </div>
|
||||||
|
// <div class="tsd-panel">
|
||||||
|
// <h3>Eirmod tempor invidunt</h3>
|
||||||
|
// <p>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat.</p>
|
||||||
|
// </div>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
.tsd-panel-group
|
||||||
|
margin: 60px 0
|
||||||
|
|
||||||
|
> h1, > h2, > h3
|
||||||
|
padding-left: 20px
|
||||||
|
padding-right: 20px
|
|
@ -0,0 +1,89 @@
|
||||||
|
#tsd-search
|
||||||
|
transition: background-color 0.2s
|
||||||
|
|
||||||
|
.title
|
||||||
|
position: relative
|
||||||
|
z-index: 2
|
||||||
|
|
||||||
|
.field
|
||||||
|
position: absolute
|
||||||
|
left: 0
|
||||||
|
top: 0
|
||||||
|
right: 40px
|
||||||
|
height: 40px
|
||||||
|
|
||||||
|
input
|
||||||
|
box-sizing: border-box
|
||||||
|
position: relative
|
||||||
|
top: -50px
|
||||||
|
z-index: 1
|
||||||
|
width: 100%
|
||||||
|
padding: 0 10px
|
||||||
|
opacity: 0
|
||||||
|
outline: 0
|
||||||
|
border: 0
|
||||||
|
background: transparent
|
||||||
|
color: $COLOR_TEXT
|
||||||
|
|
||||||
|
label
|
||||||
|
position: absolute
|
||||||
|
overflow: hidden
|
||||||
|
right: -40px
|
||||||
|
|
||||||
|
.field input,
|
||||||
|
.title
|
||||||
|
transition: opacity 0.2s
|
||||||
|
|
||||||
|
.results
|
||||||
|
position: absolute
|
||||||
|
visibility: hidden
|
||||||
|
top: 40px
|
||||||
|
width: 100%
|
||||||
|
margin: 0
|
||||||
|
padding: 0
|
||||||
|
list-style: none
|
||||||
|
box-shadow: 0 0 4px rgba(#000, 0.25)
|
||||||
|
|
||||||
|
li
|
||||||
|
padding: 0 10px
|
||||||
|
background-color: $COLOR_BACKGROUND
|
||||||
|
|
||||||
|
li:nth-child(even)
|
||||||
|
background-color: $COLOR_PANEL
|
||||||
|
|
||||||
|
li.state
|
||||||
|
display: none
|
||||||
|
|
||||||
|
li.current,
|
||||||
|
li:hover
|
||||||
|
background-color: $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
a
|
||||||
|
display: block
|
||||||
|
|
||||||
|
&:before
|
||||||
|
top: 10px
|
||||||
|
|
||||||
|
span.parent
|
||||||
|
color: $COLOR_TEXT_ASIDE
|
||||||
|
font-weight: normal
|
||||||
|
|
||||||
|
&.has-focus
|
||||||
|
background-color: $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
.field input
|
||||||
|
top: 0
|
||||||
|
opacity: 1
|
||||||
|
|
||||||
|
.title
|
||||||
|
z-index: 0
|
||||||
|
opacity: 0
|
||||||
|
|
||||||
|
.results
|
||||||
|
visibility: visible
|
||||||
|
|
||||||
|
&.loading .results li.state.loading
|
||||||
|
display: block
|
||||||
|
|
||||||
|
&.failure .results li.state.failure
|
||||||
|
display: block
|
|
@ -0,0 +1,152 @@
|
||||||
|
// Wraps a function signature.
|
||||||
|
// Changes its appearance when directly placed inside a `tsd-panel`.
|
||||||
|
// Can be combined with class `tsd-kind-icon` to display an icon in front of the signature.
|
||||||
|
//
|
||||||
|
// <div class="tsd-kind-method">
|
||||||
|
// <div class="tsd-signature tsd-kind-icon">
|
||||||
|
// get<wbr>Child<wbr>ByName<span class="tsd-signature-symbol">(</span>
|
||||||
|
// name<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span>
|
||||||
|
// <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span>
|
||||||
|
// <a href="# class="tsd-signature-type">DeclarationReflection</a>
|
||||||
|
// </div>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
.tsd-signature
|
||||||
|
margin: 0 0 1em 0
|
||||||
|
padding: 10px
|
||||||
|
border: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
font-family: $FONT_FAMILY_MONO
|
||||||
|
font-size: $FONT_SIZE_MONO
|
||||||
|
|
||||||
|
&.tsd-kind-icon
|
||||||
|
padding-left: 30px
|
||||||
|
|
||||||
|
&:before
|
||||||
|
top: 10px
|
||||||
|
left: 10px
|
||||||
|
|
||||||
|
.tsd-panel > &
|
||||||
|
margin-left: -20px
|
||||||
|
margin-right: -20px
|
||||||
|
border-width: 1px 0
|
||||||
|
|
||||||
|
&.tsd-kind-icon
|
||||||
|
padding-left: 40px
|
||||||
|
|
||||||
|
&:before
|
||||||
|
left: 20px
|
||||||
|
|
||||||
|
.tsd-signature-symbol
|
||||||
|
color: $COLOR_TEXT_ASIDE
|
||||||
|
font-weight: normal
|
||||||
|
|
||||||
|
.tsd-signature-type
|
||||||
|
font-style: italic
|
||||||
|
font-weight: normal
|
||||||
|
|
||||||
|
|
||||||
|
// Displays a list of signatures.
|
||||||
|
// Changes its appearance when directly placed inside a `tsd-panel`.
|
||||||
|
// Made interactive by JavaScript at `typedoc.Signature`.
|
||||||
|
//
|
||||||
|
// <ul class="tsd-signatures tsd-kind-method">
|
||||||
|
// <li class="tsd-signature tsd-kind-icon current">getChildByName(name: string): DeclarationReflection</li>
|
||||||
|
// <li class="tsd-signature tsd-kind-icon">getChildByName(names: Array<string>): DeclarationReflection</li>
|
||||||
|
// </ul>
|
||||||
|
//
|
||||||
|
.tsd-signatures
|
||||||
|
padding: 0
|
||||||
|
margin: 0 0 1em 0
|
||||||
|
border: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
.tsd-signature
|
||||||
|
margin: 0
|
||||||
|
border-width: 1px 0 0 0
|
||||||
|
transition: background-color 0.1s
|
||||||
|
|
||||||
|
&:first-child
|
||||||
|
border-top-width: 0
|
||||||
|
|
||||||
|
&.current
|
||||||
|
background-color: $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
&.active > .tsd-signature
|
||||||
|
cursor: pointer
|
||||||
|
|
||||||
|
.tsd-panel > &
|
||||||
|
margin-left: -20px
|
||||||
|
margin-right: -20px
|
||||||
|
border-width: 1px 0
|
||||||
|
|
||||||
|
.tsd-signature.tsd-kind-icon
|
||||||
|
padding-left: 40px
|
||||||
|
|
||||||
|
&:before
|
||||||
|
left: 20px
|
||||||
|
|
||||||
|
.tsd-panel > a.anchor + &
|
||||||
|
border-top-width: 0
|
||||||
|
margin-top: -20px
|
||||||
|
|
||||||
|
|
||||||
|
// Holds the descriptions related to a list of signatures.
|
||||||
|
// Made interactive by JavaScript at `typedoc.Signature`.
|
||||||
|
//
|
||||||
|
// <ul class="tsd-descriptions active">
|
||||||
|
// <li class="tsd-description current">
|
||||||
|
// <p>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat.</p>
|
||||||
|
// </li>
|
||||||
|
// <li class="tsd-description">
|
||||||
|
// <p>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat.</p>
|
||||||
|
// </li>
|
||||||
|
// </ul>
|
||||||
|
//
|
||||||
|
ul.tsd-descriptions
|
||||||
|
position: relative
|
||||||
|
overflow: hidden
|
||||||
|
transition: height 0.3s
|
||||||
|
padding: 0
|
||||||
|
list-style: none
|
||||||
|
|
||||||
|
> li
|
||||||
|
@extend %prevent-children-margin
|
||||||
|
|
||||||
|
&.active > .tsd-description
|
||||||
|
display: none
|
||||||
|
|
||||||
|
&.current
|
||||||
|
display: block
|
||||||
|
|
||||||
|
&.fade-in
|
||||||
|
animation: fade-in-delayed 0.3s
|
||||||
|
|
||||||
|
&.fade-out
|
||||||
|
animation: fade-out-delayed 0.3s
|
||||||
|
position: absolute
|
||||||
|
display: block
|
||||||
|
top: 0
|
||||||
|
left: 0
|
||||||
|
right: 0
|
||||||
|
opacity: 0
|
||||||
|
visibility: hidden
|
||||||
|
|
||||||
|
h4
|
||||||
|
font-size: $FONT_SIZE
|
||||||
|
margin: 1em 0 0.5em 0
|
||||||
|
|
||||||
|
ul.tsd-parameters,
|
||||||
|
ul.tsd-type-parameters
|
||||||
|
list-style: square
|
||||||
|
margin: 0
|
||||||
|
padding-left: 20px
|
||||||
|
|
||||||
|
> li.tsd-parameter-siganture
|
||||||
|
list-style: none
|
||||||
|
margin-left: -20px
|
||||||
|
|
||||||
|
h5
|
||||||
|
font-size: $FONT_SIZE
|
||||||
|
margin: 1em 0 0.5em 0
|
||||||
|
|
||||||
|
.tsd-comment
|
||||||
|
margin-top: -0.5em
|
|
@ -0,0 +1,24 @@
|
||||||
|
// Displays the source and inheritance information
|
||||||
|
//
|
||||||
|
// <aside class="tsd-sources">
|
||||||
|
// <p>Overrides <a href="#">BaseHandler</a>.<a href="#">constructor</a></p>
|
||||||
|
// <ul>
|
||||||
|
// <li>Defined in src/typedoc/factories/handlers/DynamicModuleHandler.ts:37</li>
|
||||||
|
// </ul>
|
||||||
|
// </aside>
|
||||||
|
//
|
||||||
|
.tsd-sources
|
||||||
|
font-size: $FONT_SIZE_MONO
|
||||||
|
color: $COLOR_TEXT_ASIDE
|
||||||
|
margin: 0 0 1em 0
|
||||||
|
|
||||||
|
a
|
||||||
|
color: $COLOR_TEXT_ASIDE
|
||||||
|
text-decoration: underline
|
||||||
|
|
||||||
|
ul, p
|
||||||
|
margin: 0 !important
|
||||||
|
|
||||||
|
ul
|
||||||
|
list-style: none
|
||||||
|
padding: 0
|
|
@ -0,0 +1,171 @@
|
||||||
|
// Displays the toolbar at the top of the page.
|
||||||
|
//
|
||||||
|
// <div class="tsd-page-toolbar">
|
||||||
|
// <div class="container">
|
||||||
|
// <div class="table-wrap">
|
||||||
|
// <div class="table-cell">
|
||||||
|
// <a href="../index.html" class="title">TypeDoc Documentation</a>
|
||||||
|
// </div>
|
||||||
|
// </div>
|
||||||
|
// </div>
|
||||||
|
// </div>
|
||||||
|
//
|
||||||
|
.tsd-page-toolbar
|
||||||
|
position: absolute
|
||||||
|
z-index: 1
|
||||||
|
top: 0
|
||||||
|
left: 0
|
||||||
|
width: 100%
|
||||||
|
height: $TOOLBAR_HEIGHT
|
||||||
|
color: $TOOLBAR_TEXT_COLOR
|
||||||
|
background: $TOOLBAR_COLOR
|
||||||
|
border-bottom: 1px solid $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
a
|
||||||
|
color: $TOOLBAR_TEXT_COLOR
|
||||||
|
text-decoration: none
|
||||||
|
|
||||||
|
&.title
|
||||||
|
font-weight: bold
|
||||||
|
|
||||||
|
&.title:hover
|
||||||
|
text-decoration: underline
|
||||||
|
|
||||||
|
.table-wrap
|
||||||
|
display: table
|
||||||
|
width: 100%
|
||||||
|
height: $TOOLBAR_HEIGHT
|
||||||
|
|
||||||
|
.table-cell
|
||||||
|
display: table-cell
|
||||||
|
position: relative
|
||||||
|
white-space: nowrap
|
||||||
|
line-height: $TOOLBAR_HEIGHT
|
||||||
|
|
||||||
|
&:first-child
|
||||||
|
width: 100%
|
||||||
|
|
||||||
|
%TSD_WIDGET_ICON
|
||||||
|
&:before
|
||||||
|
content: ''
|
||||||
|
display: inline-block
|
||||||
|
width: 40px
|
||||||
|
height: 40px
|
||||||
|
margin: 0 -8px 0 0
|
||||||
|
background-image: url(../images/widgets.png)
|
||||||
|
background-repeat: no-repeat
|
||||||
|
text-indent: -1024px
|
||||||
|
vertical-align: bottom
|
||||||
|
|
||||||
|
+retina
|
||||||
|
background-image: url(../images/widgets@2x.png)
|
||||||
|
background-size: 320px 40px
|
||||||
|
|
||||||
|
.tsd-widget
|
||||||
|
@extend %TSD_WIDGET_ICON
|
||||||
|
display: inline-block
|
||||||
|
overflow: hidden
|
||||||
|
opacity: 0.6
|
||||||
|
height: $TOOLBAR_HEIGHT
|
||||||
|
transition: opacity 0.1s, background-color 0.2s
|
||||||
|
vertical-align: bottom
|
||||||
|
cursor: pointer
|
||||||
|
|
||||||
|
&:hover
|
||||||
|
opacity: 0.8
|
||||||
|
|
||||||
|
&.active
|
||||||
|
opacity: 1
|
||||||
|
background-color: $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
&.no-caption
|
||||||
|
width: 40px
|
||||||
|
|
||||||
|
&:before
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
&.search:before
|
||||||
|
background-position: 0 0
|
||||||
|
|
||||||
|
&.menu:before
|
||||||
|
background-position: -40px 0
|
||||||
|
|
||||||
|
&.options:before
|
||||||
|
background-position: -80px 0
|
||||||
|
|
||||||
|
&.options,
|
||||||
|
&.menu
|
||||||
|
display: none
|
||||||
|
|
||||||
|
+size-xs-sm
|
||||||
|
display: inline-block
|
||||||
|
|
||||||
|
input[type=checkbox] + &:before
|
||||||
|
background-position: -120px 0
|
||||||
|
|
||||||
|
input[type=checkbox]:checked + &:before
|
||||||
|
background-position: -160px 0
|
||||||
|
|
||||||
|
.tsd-select
|
||||||
|
position: relative
|
||||||
|
display: inline-block
|
||||||
|
height: $TOOLBAR_HEIGHT
|
||||||
|
transition: opacity 0.1s, background-color 0.2s
|
||||||
|
vertical-align: bottom
|
||||||
|
cursor: pointer
|
||||||
|
|
||||||
|
.tsd-select-label
|
||||||
|
@extend %TSD_WIDGET_ICON
|
||||||
|
opacity: 0.6
|
||||||
|
transition: opacity 0.2s
|
||||||
|
|
||||||
|
&:before
|
||||||
|
background-position: -240px 0
|
||||||
|
|
||||||
|
&.active
|
||||||
|
.tsd-select-label
|
||||||
|
opacity: 0.8
|
||||||
|
|
||||||
|
.tsd-select-list
|
||||||
|
visibility: visible
|
||||||
|
opacity: 1
|
||||||
|
transition-delay: 0s
|
||||||
|
|
||||||
|
.tsd-select-list
|
||||||
|
position: absolute
|
||||||
|
visibility: hidden
|
||||||
|
top: $TOOLBAR_HEIGHT
|
||||||
|
left: 0
|
||||||
|
margin: 0
|
||||||
|
padding: 0
|
||||||
|
opacity: 0
|
||||||
|
list-style: none
|
||||||
|
box-shadow: 0 0 4px rgba(#000, 0.25)
|
||||||
|
transition: visibility 0s 0.2s, opacity 0.2s
|
||||||
|
|
||||||
|
li
|
||||||
|
@extend %TSD_WIDGET_ICON
|
||||||
|
padding: 0 20px 0 0
|
||||||
|
background-color: $COLOR_BACKGROUND
|
||||||
|
|
||||||
|
&:before
|
||||||
|
background-position: 40px 0
|
||||||
|
|
||||||
|
&:nth-child(even)
|
||||||
|
background-color: $COLOR_PANEL
|
||||||
|
|
||||||
|
&:hover
|
||||||
|
background-color: $COLOR_PANEL_DIVIDER
|
||||||
|
|
||||||
|
&.selected:before
|
||||||
|
background-position: -200px 0
|
||||||
|
|
||||||
|
+size-xs-sm
|
||||||
|
.tsd-select-list
|
||||||
|
top: 0
|
||||||
|
left: auto
|
||||||
|
right: 100%
|
||||||
|
margin-right: -5px
|
||||||
|
|
||||||
|
.tsd-select-label:before
|
||||||
|
background-position: -280px 0
|
|
@ -0,0 +1,114 @@
|
||||||
|
html.default
|
||||||
|
+size-md
|
||||||
|
.col-content
|
||||||
|
width: 72%
|
||||||
|
|
||||||
|
.col-menu
|
||||||
|
width: 28%
|
||||||
|
|
||||||
|
.tsd-navigation
|
||||||
|
padding-left: 10px
|
||||||
|
|
||||||
|
+size-xs-sm
|
||||||
|
.col-content
|
||||||
|
float: none
|
||||||
|
width: 100%
|
||||||
|
|
||||||
|
.col-menu
|
||||||
|
position: fixed !important
|
||||||
|
overflow: auto
|
||||||
|
-webkit-overflow-scrolling: touch
|
||||||
|
overflow-scrolling: touch
|
||||||
|
z-index: 1024
|
||||||
|
top: 0 !important
|
||||||
|
bottom: 0 !important
|
||||||
|
left: auto !important
|
||||||
|
right: 0 !important
|
||||||
|
width: 100%
|
||||||
|
padding: 20px 20px 0 0
|
||||||
|
max-width: 450px
|
||||||
|
visibility: hidden
|
||||||
|
background-color: $COLOR_PANEL
|
||||||
|
transform: translate(100%,0)
|
||||||
|
|
||||||
|
> *:last-child
|
||||||
|
padding-bottom: 20px
|
||||||
|
|
||||||
|
.overlay
|
||||||
|
content: ''
|
||||||
|
display: block
|
||||||
|
position: fixed
|
||||||
|
z-index: 1023
|
||||||
|
top: 0
|
||||||
|
left: 0
|
||||||
|
right: 0
|
||||||
|
bottom: 0
|
||||||
|
background-color: rgba(#000, 0.75)
|
||||||
|
visibility: hidden
|
||||||
|
|
||||||
|
&.to-has-menu
|
||||||
|
.overlay
|
||||||
|
animation: fade-in 0.4s
|
||||||
|
|
||||||
|
header,
|
||||||
|
footer,
|
||||||
|
.col-content
|
||||||
|
animation: shift-to-left 0.4s
|
||||||
|
|
||||||
|
.col-menu
|
||||||
|
animation: pop-in-from-right 0.4s
|
||||||
|
|
||||||
|
&.from-has-menu
|
||||||
|
.overlay
|
||||||
|
animation: fade-out 0.4s
|
||||||
|
|
||||||
|
header,
|
||||||
|
footer,
|
||||||
|
.col-content
|
||||||
|
animation: unshift-to-left 0.4s
|
||||||
|
|
||||||
|
.col-menu
|
||||||
|
animation: pop-out-to-right 0.4s
|
||||||
|
|
||||||
|
&.has-menu
|
||||||
|
body
|
||||||
|
overflow: hidden
|
||||||
|
|
||||||
|
.overlay
|
||||||
|
visibility: visible
|
||||||
|
|
||||||
|
header,
|
||||||
|
footer,
|
||||||
|
.col-content
|
||||||
|
transform: translate(-25%, 0)
|
||||||
|
|
||||||
|
.col-menu
|
||||||
|
visibility: visible
|
||||||
|
transform: translate(0,0)
|
||||||
|
|
||||||
|
.tsd-page-title
|
||||||
|
padding: 70px 0 20px 0
|
||||||
|
margin: 0 0 40px 0
|
||||||
|
background: $COLOR_PANEL
|
||||||
|
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15)
|
||||||
|
|
||||||
|
h1
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
.tsd-breadcrumb
|
||||||
|
margin: 0
|
||||||
|
padding: 0
|
||||||
|
color: $COLOR_TEXT_ASIDE
|
||||||
|
|
||||||
|
a
|
||||||
|
color: $COLOR_TEXT_ASIDE
|
||||||
|
text-decoration: none
|
||||||
|
|
||||||
|
&:hover
|
||||||
|
text-decoration: underline
|
||||||
|
|
||||||
|
li
|
||||||
|
display: inline
|
||||||
|
|
||||||
|
&:after
|
||||||
|
content: ' / '
|
|
@ -0,0 +1,50 @@
|
||||||
|
html.minimal
|
||||||
|
.container
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
.container-main
|
||||||
|
padding-top: 50px
|
||||||
|
padding-bottom: 0
|
||||||
|
|
||||||
|
.content-wrap
|
||||||
|
padding-left: 300px
|
||||||
|
|
||||||
|
.tsd-navigation
|
||||||
|
position: fixed !important
|
||||||
|
overflow: auto
|
||||||
|
-webkit-overflow-scrolling: touch
|
||||||
|
overflow-scrolling: touch
|
||||||
|
box-sizing: border-box
|
||||||
|
z-index: 1
|
||||||
|
left: 0
|
||||||
|
top: 40px
|
||||||
|
bottom: 0
|
||||||
|
width: 300px
|
||||||
|
padding: 20px
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
.tsd-member .tsd-member
|
||||||
|
margin-left: 0
|
||||||
|
|
||||||
|
.tsd-page-toolbar
|
||||||
|
position: fixed
|
||||||
|
z-index: 2
|
||||||
|
|
||||||
|
#tsd-filter .tsd-filter-group
|
||||||
|
right: 0
|
||||||
|
transform: none
|
||||||
|
|
||||||
|
footer
|
||||||
|
background-color: transparent
|
||||||
|
|
||||||
|
.container
|
||||||
|
padding: 0
|
||||||
|
|
||||||
|
.tsd-generator
|
||||||
|
padding: 0
|
||||||
|
|
||||||
|
+size-xs-sm
|
||||||
|
.tsd-navigation
|
||||||
|
display: none
|
||||||
|
.content-wrap
|
||||||
|
padding-left: 0
|
|
@ -0,0 +1,27 @@
|
||||||
|
@import constants
|
||||||
|
|
||||||
|
@import vendors/normalize
|
||||||
|
@import vendors/highlight.js
|
||||||
|
|
||||||
|
@import setup/mixins
|
||||||
|
@import setup/grid
|
||||||
|
@import setup/icons
|
||||||
|
@import setup/animations
|
||||||
|
@import setup/typography
|
||||||
|
|
||||||
|
@import layouts/default
|
||||||
|
@import layouts/minimal
|
||||||
|
|
||||||
|
@import elements/comment
|
||||||
|
@import elements/filter
|
||||||
|
@import elements/footer
|
||||||
|
@import elements/hierarchy
|
||||||
|
@import elements/index
|
||||||
|
@import elements/member
|
||||||
|
@import elements/navigation
|
||||||
|
@import elements/panel
|
||||||
|
@import elements/search
|
||||||
|
@import elements/signatures
|
||||||
|
@import elements/sources
|
||||||
|
@import elements/toolbar
|
||||||
|
@import elements/images
|
|
@ -0,0 +1,57 @@
|
||||||
|
.no-transition
|
||||||
|
transition: none !important
|
||||||
|
|
||||||
|
@keyframes fade-in
|
||||||
|
from
|
||||||
|
opacity: 0
|
||||||
|
to
|
||||||
|
opacity: 1
|
||||||
|
|
||||||
|
@keyframes fade-out
|
||||||
|
from
|
||||||
|
opacity: 1
|
||||||
|
visibility: visible
|
||||||
|
to
|
||||||
|
opacity: 0
|
||||||
|
|
||||||
|
@keyframes fade-in-delayed
|
||||||
|
0%
|
||||||
|
opacity: 0
|
||||||
|
33%
|
||||||
|
opacity: 0
|
||||||
|
100%
|
||||||
|
opacity: 1
|
||||||
|
|
||||||
|
@keyframes fade-out-delayed
|
||||||
|
0%
|
||||||
|
opacity: 1
|
||||||
|
visibility: visible
|
||||||
|
66%
|
||||||
|
opacity: 0
|
||||||
|
100%
|
||||||
|
opacity: 0
|
||||||
|
|
||||||
|
@keyframes shift-to-left
|
||||||
|
from
|
||||||
|
transform: translate(0,0)
|
||||||
|
to
|
||||||
|
transform: translate(-25%,0)
|
||||||
|
|
||||||
|
@keyframes unshift-to-left
|
||||||
|
from
|
||||||
|
transform: translate(-25%,0)
|
||||||
|
to
|
||||||
|
transform: translate(0,0)
|
||||||
|
|
||||||
|
@keyframes pop-in-from-right
|
||||||
|
from
|
||||||
|
transform: translate(100%,0)
|
||||||
|
to
|
||||||
|
transform: translate(0,0)
|
||||||
|
|
||||||
|
@keyframes pop-out-to-right
|
||||||
|
from
|
||||||
|
transform: translate(0,0)
|
||||||
|
visibility: visible
|
||||||
|
to
|
||||||
|
transform: translate(100%,0)
|
|
@ -0,0 +1,59 @@
|
||||||
|
=size-xs
|
||||||
|
@media (max-width: 640px)
|
||||||
|
&
|
||||||
|
@content
|
||||||
|
|
||||||
|
=size-sm
|
||||||
|
@media (min-width: 641px) and (max-width: 900px)
|
||||||
|
&
|
||||||
|
@content
|
||||||
|
|
||||||
|
=size-md
|
||||||
|
@media (min-width: 901px) and (max-width: 1024px)
|
||||||
|
&
|
||||||
|
@content
|
||||||
|
|
||||||
|
=size-lg
|
||||||
|
@media (min-width: 1025px)
|
||||||
|
&
|
||||||
|
@content
|
||||||
|
|
||||||
|
=size-xs-sm
|
||||||
|
@media (max-width: 900px)
|
||||||
|
&
|
||||||
|
@content
|
||||||
|
|
||||||
|
=size-md-lg
|
||||||
|
@media (min-width: 901px)
|
||||||
|
&
|
||||||
|
@content
|
||||||
|
|
||||||
|
.container
|
||||||
|
max-width: 1200px
|
||||||
|
margin: 0 auto
|
||||||
|
padding: 0 40px
|
||||||
|
|
||||||
|
+size-xs
|
||||||
|
padding: 0 20px
|
||||||
|
|
||||||
|
.container-main
|
||||||
|
padding-bottom: 200px
|
||||||
|
|
||||||
|
.row
|
||||||
|
+clearfix
|
||||||
|
position: relative
|
||||||
|
margin: 0 -10px
|
||||||
|
|
||||||
|
.col
|
||||||
|
@extend %prevent-children-margin
|
||||||
|
box-sizing: border-box
|
||||||
|
float: left
|
||||||
|
padding: 0 10px
|
||||||
|
|
||||||
|
@for $width from 1 to 12
|
||||||
|
.col-#{$width}
|
||||||
|
@extend .col
|
||||||
|
width: $width / 12 * 100%
|
||||||
|
|
||||||
|
.offset-#{$width}
|
||||||
|
margin-left: $width / 12 * 100%
|
|
@ -0,0 +1,166 @@
|
||||||
|
$type-icons:
|
||||||
|
(object-literal),
|
||||||
|
(class),
|
||||||
|
('class.tsd-has-type-parameter'),
|
||||||
|
(interface),
|
||||||
|
('interface.tsd-has-type-parameter'),
|
||||||
|
(module, external-module),
|
||||||
|
(enum),
|
||||||
|
(enum-member),
|
||||||
|
(signature),
|
||||||
|
(type-alias),
|
||||||
|
('type-alias.tsd-has-type-parameter');
|
||||||
|
|
||||||
|
$member-icons:
|
||||||
|
(variable, property),
|
||||||
|
(get-signature),
|
||||||
|
(set-signature),
|
||||||
|
(accessor),
|
||||||
|
(function, method, call-signature),
|
||||||
|
('function.tsd-has-type-parameter', 'method.tsd-has-type-parameter'),
|
||||||
|
(constructor, constructor-signature),
|
||||||
|
(index-signature),
|
||||||
|
(event),
|
||||||
|
(property),
|
||||||
|
(function, method, call-signature),
|
||||||
|
(event);
|
||||||
|
|
||||||
|
// parameter
|
||||||
|
// type-literal
|
||||||
|
// type-parameter
|
||||||
|
|
||||||
|
.tsd-kind-icon {
|
||||||
|
display: block;
|
||||||
|
position: relative;
|
||||||
|
padding-left: 20px;
|
||||||
|
text-indent: -20px;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
content: '';
|
||||||
|
display: inline-block;
|
||||||
|
vertical-align: middle;
|
||||||
|
width: 17px;
|
||||||
|
height: 17px;
|
||||||
|
margin: 0 3px 2px 0;
|
||||||
|
background-image: url(../images/icons.png);
|
||||||
|
|
||||||
|
@include retina {
|
||||||
|
background-image: url(../images/icons@2x.png);
|
||||||
|
background-size: 238px 204px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.tsd-signature.tsd-kind-icon:before {
|
||||||
|
background-position: 0 -153px;
|
||||||
|
}
|
||||||
|
|
||||||
|
$icon-size: 17px;
|
||||||
|
$type: -0 * $icon-size;
|
||||||
|
$type-protected: -1 * $icon-size;
|
||||||
|
$type-private: -2 * $icon-size;
|
||||||
|
$member-class-public: -3 * $icon-size;
|
||||||
|
$member-class-public-inherited: -4 * $icon-size;
|
||||||
|
$member-class-protected: -5 * $icon-size;
|
||||||
|
$member-class-protected-inherited: -6 * $icon-size;
|
||||||
|
$member-private: -7 * $icon-size;
|
||||||
|
$member: -8 * $icon-size;
|
||||||
|
$member-protected: -9 * $icon-size;
|
||||||
|
$member-enum: -10 * $icon-size;
|
||||||
|
$member-enum-protected: -11 * $icon-size;
|
||||||
|
$member-interface: -12 * $icon-size;
|
||||||
|
$member-interface-inherited: -13 * $icon-size;
|
||||||
|
|
||||||
|
|
||||||
|
@for $index from 1 through length($type-icons) {
|
||||||
|
@each $kind in nth($type-icons, $index) {
|
||||||
|
$selector: '.tsd-kind-' + $kind;
|
||||||
|
$offset: -#{17 * ($index)}px;
|
||||||
|
|
||||||
|
#{$selector} {
|
||||||
|
> .tsd-kind-icon:before {
|
||||||
|
background-position: $type $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-protected > .tsd-kind-icon:before {
|
||||||
|
background-position: $type-protected $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-private > .tsd-kind-icon:before {
|
||||||
|
background-position: $type-private $offset;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@for $index from 1 through length($member-icons) {
|
||||||
|
@each $kind in nth($member-icons, $index) {
|
||||||
|
$offset: -#{17 * ($index - 1)}px;
|
||||||
|
$selector: '.tsd-kind-' + $kind;
|
||||||
|
@if $index == 10 {
|
||||||
|
$selector: '.tsd-is-static';
|
||||||
|
} @else if $index > 10 {
|
||||||
|
$selector: '.tsd-is-static.tsd-kind-' + $kind;
|
||||||
|
}
|
||||||
|
|
||||||
|
#{$selector} {
|
||||||
|
> .tsd-kind-icon:before {
|
||||||
|
background-position: $member $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-protected > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-protected $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-private > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-private $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-parent-kind-class {
|
||||||
|
> .tsd-kind-icon:before {
|
||||||
|
background-position: $member-class-public $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-inherited > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-class-public-inherited $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-protected > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-class-protected $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-class-protected-inherited $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-private > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-private $offset;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-parent-kind-enum {
|
||||||
|
> .tsd-kind-icon:before {
|
||||||
|
background-position: $member-enum $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-protected > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-enum-protected $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-private > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-private $offset;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-parent-kind-interface {
|
||||||
|
> .tsd-kind-icon:before {
|
||||||
|
background-position: $member-interface $offset;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.tsd-is-inherited > .tsd-kind-icon:before {
|
||||||
|
background-position: $member-interface-inherited $offset;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,30 @@
|
||||||
|
@mixin vendors($property, $value...)
|
||||||
|
-webkit-#{$property}: $value
|
||||||
|
-moz-#{$property}: $value
|
||||||
|
-ms-#{$property}: $value
|
||||||
|
-o-#{$property}: $value
|
||||||
|
#{$property}: $value
|
||||||
|
|
||||||
|
@mixin clearfix
|
||||||
|
&:after
|
||||||
|
visibility: hidden
|
||||||
|
display: block
|
||||||
|
content: ""
|
||||||
|
clear: both
|
||||||
|
height: 0
|
||||||
|
|
||||||
|
@mixin retina
|
||||||
|
@media (-webkit-min-device-pixel-ratio: 1.5), (min-device-pixel-ratio: 1.5), (min-resolution: 144dpi)
|
||||||
|
&
|
||||||
|
@content
|
||||||
|
|
||||||
|
%prevent-children-margin
|
||||||
|
> :first-child,
|
||||||
|
> :first-child > :first-child,
|
||||||
|
> :first-child > :first-child > :first-child
|
||||||
|
margin-top: 0
|
||||||
|
|
||||||
|
> :last-child,
|
||||||
|
> :last-child > :last-child,
|
||||||
|
> :last-child > :last-child > :last-child
|
||||||
|
margin-bottom: 0
|
|
@ -0,0 +1,45 @@
|
||||||
|
body
|
||||||
|
background: $COLOR_BACKGROUND
|
||||||
|
font-family: $FONT_FAMILY
|
||||||
|
font-size: $FONT_SIZE
|
||||||
|
color: $COLOR_TEXT
|
||||||
|
|
||||||
|
a
|
||||||
|
color: $COLOR_LINK
|
||||||
|
text-decoration: none
|
||||||
|
|
||||||
|
&:hover
|
||||||
|
text-decoration: underline
|
||||||
|
|
||||||
|
code, pre
|
||||||
|
font-family: $FONT_FAMILY_MONO
|
||||||
|
padding: 0.2em
|
||||||
|
margin: 0
|
||||||
|
font-size: $FONT_SIZE_MONO
|
||||||
|
background-color: $COLOR_CODE_BACKGROUND
|
||||||
|
|
||||||
|
pre
|
||||||
|
padding: 10px
|
||||||
|
|
||||||
|
code
|
||||||
|
padding: 0
|
||||||
|
font-size: 100%
|
||||||
|
background-color: transparent
|
||||||
|
|
||||||
|
.tsd-typography
|
||||||
|
line-height: $LINE_HEIGHT
|
||||||
|
|
||||||
|
ul
|
||||||
|
list-style: square
|
||||||
|
padding: 0 0 0 20px
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
h4, h5, h6
|
||||||
|
font-size: 1em
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
h5, h6
|
||||||
|
font-weight: normal
|
||||||
|
|
||||||
|
p, ul, ol
|
||||||
|
margin: 1em 0
|
50
openvidu-browser/config/typedoc/custom-theme/assets/css/vendors/_highlight.js.sass
vendored
Normal file
50
openvidu-browser/config/typedoc/custom-theme/assets/css/vendors/_highlight.js.sass
vendored
Normal file
|
@ -0,0 +1,50 @@
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
*Visual Studio-like style based on original C# coloring by Jason Diamond <jason@diamond.name>
|
||||||
|
|
||||||
|
.hljs
|
||||||
|
display: inline-block
|
||||||
|
padding: 0.5em
|
||||||
|
background: white
|
||||||
|
color: black
|
||||||
|
|
||||||
|
.hljs-comment, .hljs-annotation, .hljs-template_comment, .diff .hljs-header, .hljs-chunk, .apache .hljs-cbracket
|
||||||
|
color: #008000
|
||||||
|
|
||||||
|
.hljs-keyword, .hljs-id, .hljs-built_in, .css .smalltalk .hljs-class, .hljs-winutils, .bash .hljs-variable, .tex .hljs-command, .hljs-request, .hljs-status, .nginx .hljs-title
|
||||||
|
color: #00f
|
||||||
|
|
||||||
|
.xml .hljs-tag
|
||||||
|
color: #00f
|
||||||
|
.hljs-value
|
||||||
|
color: #00f
|
||||||
|
|
||||||
|
.hljs-string, .hljs-title, .hljs-parent, .hljs-tag .hljs-value, .hljs-rules .hljs-value
|
||||||
|
color: #a31515
|
||||||
|
|
||||||
|
.ruby .hljs-symbol
|
||||||
|
color: #a31515
|
||||||
|
.hljs-string
|
||||||
|
color: #a31515
|
||||||
|
|
||||||
|
.hljs-template_tag, .django .hljs-variable, .hljs-addition, .hljs-flow, .hljs-stream, .apache .hljs-tag, .hljs-date, .tex .hljs-formula, .coffeescript .hljs-attribute
|
||||||
|
color: #a31515
|
||||||
|
|
||||||
|
.ruby .hljs-string, .hljs-decorator, .hljs-filter .hljs-argument, .hljs-localvars, .hljs-array, .hljs-attr_selector, .hljs-pseudo, .hljs-pi, .hljs-doctype, .hljs-deletion, .hljs-envvar, .hljs-shebang, .hljs-preprocessor, .hljs-pragma, .userType, .apache .hljs-sqbracket, .nginx .hljs-built_in, .tex .hljs-special, .hljs-prompt
|
||||||
|
color: #2b91af
|
||||||
|
|
||||||
|
.hljs-phpdoc, .hljs-javadoc, .hljs-xmlDocTag
|
||||||
|
color: #808080
|
||||||
|
|
||||||
|
.vhdl
|
||||||
|
.hljs-typename
|
||||||
|
font-weight: bold
|
||||||
|
.hljs-string
|
||||||
|
color: #666666
|
||||||
|
.hljs-literal
|
||||||
|
color: #a31515
|
||||||
|
.hljs-attribute
|
||||||
|
color: #00b0e8
|
||||||
|
|
||||||
|
.xml .hljs-attribute
|
||||||
|
color: #f00
|
424
openvidu-browser/config/typedoc/custom-theme/assets/css/vendors/_normalize.sass
vendored
Normal file
424
openvidu-browser/config/typedoc/custom-theme/assets/css/vendors/_normalize.sass
vendored
Normal file
|
@ -0,0 +1,424 @@
|
||||||
|
/*! normalize.css v1.1.3 | MIT License | git.io/normalize
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* HTML5 display definitions
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Correct `block` display not defined in IE 6/7/8/9 and Firefox 3.
|
||||||
|
|
||||||
|
article, aside, details, figcaption, figure, footer, header, hgroup, main, nav, section, summary
|
||||||
|
display: block
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Correct `inline-block` display not defined in IE 6/7/8/9 and Firefox 3.
|
||||||
|
|
||||||
|
audio, canvas, video
|
||||||
|
display: inline-block
|
||||||
|
*display: inline
|
||||||
|
*zoom: 1
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Prevent modern browsers from displaying `audio` without controls.
|
||||||
|
* Remove excess height in iOS 5 devices.
|
||||||
|
|
||||||
|
audio:not([controls])
|
||||||
|
display: none
|
||||||
|
height: 0
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address styling not present in IE 7/8/9, Firefox 3, and Safari 4.
|
||||||
|
* Known issue: no IE 6 support.
|
||||||
|
|
||||||
|
[hidden]
|
||||||
|
display: none
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* Base
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 1. Correct text resizing oddly in IE 6/7 when body `font-size` is set using
|
||||||
|
* `em` units.
|
||||||
|
* 2. Prevent iOS text size adjust after orientation change, without disabling
|
||||||
|
* user zoom.
|
||||||
|
|
||||||
|
html
|
||||||
|
font-size: 100%
|
||||||
|
/* 1
|
||||||
|
-ms-text-size-adjust: 100%
|
||||||
|
/* 2
|
||||||
|
-webkit-text-size-adjust: 100%
|
||||||
|
/* 2
|
||||||
|
font-family: sans-serif
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address `font-family` inconsistency between `textarea` and other form
|
||||||
|
* elements.
|
||||||
|
|
||||||
|
button, input, select, textarea
|
||||||
|
font-family: sans-serif
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address margins handled incorrectly in IE 6/7.
|
||||||
|
|
||||||
|
body
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* Links
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address `outline` inconsistency between Chrome and other browsers.
|
||||||
|
|
||||||
|
a
|
||||||
|
&:focus
|
||||||
|
outline: thin dotted
|
||||||
|
&:active, &:hover
|
||||||
|
outline: 0
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Improve readability when focused and also mouse hovered in all browsers.
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* Typography
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address font sizes and margins set differently in IE 6/7.
|
||||||
|
* Address font sizes within `section` and `article` in Firefox 4+, Safari 5,
|
||||||
|
* and Chrome.
|
||||||
|
|
||||||
|
h1
|
||||||
|
font-size: 2em
|
||||||
|
margin: 0.67em 0
|
||||||
|
|
||||||
|
h2
|
||||||
|
font-size: 1.5em
|
||||||
|
margin: 0.83em 0
|
||||||
|
|
||||||
|
h3
|
||||||
|
font-size: 1.17em
|
||||||
|
margin: 1em 0
|
||||||
|
|
||||||
|
h4
|
||||||
|
font-size: 1em
|
||||||
|
margin: 1.33em 0
|
||||||
|
|
||||||
|
h5
|
||||||
|
font-size: 0.83em
|
||||||
|
margin: 1.67em 0
|
||||||
|
|
||||||
|
h6
|
||||||
|
font-size: 0.67em
|
||||||
|
margin: 2.33em 0
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address styling not present in IE 7/8/9, Safari 5, and Chrome.
|
||||||
|
|
||||||
|
abbr[title]
|
||||||
|
border-bottom: 1px dotted
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address style set to `bolder` in Firefox 3+, Safari 4/5, and Chrome.
|
||||||
|
|
||||||
|
b, strong
|
||||||
|
font-weight: bold
|
||||||
|
|
||||||
|
blockquote
|
||||||
|
margin: 1em 40px
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address styling not present in Safari 5 and Chrome.
|
||||||
|
|
||||||
|
dfn
|
||||||
|
font-style: italic
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address differences between Firefox and other browsers.
|
||||||
|
* Known issue: no IE 6/7 normalization.
|
||||||
|
|
||||||
|
hr
|
||||||
|
-moz-box-sizing: content-box
|
||||||
|
box-sizing: content-box
|
||||||
|
height: 0
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address styling not present in IE 6/7/8/9.
|
||||||
|
|
||||||
|
mark
|
||||||
|
background: #ff0
|
||||||
|
color: #000
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address margins set differently in IE 6/7.
|
||||||
|
|
||||||
|
p, pre
|
||||||
|
margin: 1em 0
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Correct font family set oddly in IE 6, Safari 4/5, and Chrome.
|
||||||
|
|
||||||
|
code, kbd, pre, samp
|
||||||
|
font-family: monospace, serif
|
||||||
|
_font-family: 'courier new', monospace
|
||||||
|
font-size: 1em
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Improve readability of pre-formatted text in all browsers.
|
||||||
|
|
||||||
|
pre
|
||||||
|
white-space: pre
|
||||||
|
white-space: pre-wrap
|
||||||
|
word-wrap: break-word
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address CSS quotes not supported in IE 6/7.
|
||||||
|
|
||||||
|
q
|
||||||
|
quotes: none
|
||||||
|
&:before, &:after
|
||||||
|
content: ''
|
||||||
|
content: none
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address `quotes` property not supported in Safari 4.
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address inconsistent and variable font size in all browsers.
|
||||||
|
|
||||||
|
small
|
||||||
|
font-size: 80%
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Prevent `sub` and `sup` affecting `line-height` in all browsers.
|
||||||
|
|
||||||
|
sub
|
||||||
|
font-size: 75%
|
||||||
|
line-height: 0
|
||||||
|
position: relative
|
||||||
|
vertical-align: baseline
|
||||||
|
|
||||||
|
sup
|
||||||
|
font-size: 75%
|
||||||
|
line-height: 0
|
||||||
|
position: relative
|
||||||
|
vertical-align: baseline
|
||||||
|
top: -0.5em
|
||||||
|
|
||||||
|
sub
|
||||||
|
bottom: -0.25em
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* Lists
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address margins set differently in IE 6/7.
|
||||||
|
|
||||||
|
dl, menu, ol, ul
|
||||||
|
margin: 1em 0
|
||||||
|
|
||||||
|
dd
|
||||||
|
margin: 0 0 0 40px
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address paddings set differently in IE 6/7.
|
||||||
|
|
||||||
|
menu, ol, ul
|
||||||
|
padding: 0 0 0 40px
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Correct list images handled incorrectly in IE 7.
|
||||||
|
|
||||||
|
nav
|
||||||
|
ul, ol
|
||||||
|
list-style: none
|
||||||
|
list-style-image: none
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* Embedded content
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 1. Remove border when inside `a` element in IE 6/7/8/9 and Firefox 3.
|
||||||
|
* 2. Improve image quality when scaled in IE 7.
|
||||||
|
|
||||||
|
img
|
||||||
|
border: 0
|
||||||
|
/* 1
|
||||||
|
-ms-interpolation-mode: bicubic
|
||||||
|
/* 2
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Correct overflow displayed oddly in IE 9.
|
||||||
|
|
||||||
|
svg:not(:root)
|
||||||
|
overflow: hidden
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* Figures
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address margin not present in IE 6/7/8/9, Safari 5, and Opera 11.
|
||||||
|
|
||||||
|
figure, form
|
||||||
|
margin: 0
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* Forms
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Correct margin displayed oddly in IE 6/7.
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Define consistent border, margin, and padding.
|
||||||
|
|
||||||
|
fieldset
|
||||||
|
border: 1px solid #c0c0c0
|
||||||
|
margin: 0 2px
|
||||||
|
padding: 0.35em 0.625em 0.75em
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 1. Correct color not being inherited in IE 6/7/8/9.
|
||||||
|
* 2. Correct text not wrapping in Firefox 3.
|
||||||
|
* 3. Correct alignment displayed oddly in IE 6/7.
|
||||||
|
|
||||||
|
legend
|
||||||
|
border: 0
|
||||||
|
/* 1
|
||||||
|
padding: 0
|
||||||
|
white-space: normal
|
||||||
|
/* 2
|
||||||
|
*margin-left: -7px
|
||||||
|
/* 3
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 1. Correct font size not being inherited in all browsers.
|
||||||
|
* 2. Address margins set differently in IE 6/7, Firefox 3+, Safari 5,
|
||||||
|
* and Chrome.
|
||||||
|
* 3. Improve appearance and consistency in all browsers.
|
||||||
|
|
||||||
|
button, input, select, textarea
|
||||||
|
font-size: 100%
|
||||||
|
/* 1
|
||||||
|
margin: 0
|
||||||
|
/* 2
|
||||||
|
vertical-align: baseline
|
||||||
|
/* 3
|
||||||
|
*vertical-align: middle
|
||||||
|
/* 3
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address Firefox 3+ setting `line-height` on `input` using `!important` in
|
||||||
|
* the UA stylesheet.
|
||||||
|
|
||||||
|
button, input
|
||||||
|
line-height: normal
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Address inconsistent `text-transform` inheritance for `button` and `select`.
|
||||||
|
* All other form control elements do not inherit `text-transform` values.
|
||||||
|
* Correct `button` style inheritance in Chrome, Safari 5+, and IE 6+.
|
||||||
|
* Correct `select` style inheritance in Firefox 4+ and Opera.
|
||||||
|
|
||||||
|
button, select
|
||||||
|
text-transform: none
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
|
||||||
|
* and `video` controls.
|
||||||
|
* 2. Correct inability to style clickable `input` types in iOS.
|
||||||
|
* 3. Improve usability and consistency of cursor style between image-type
|
||||||
|
* `input` and others.
|
||||||
|
* 4. Remove inner spacing in IE 7 without affecting normal text inputs.
|
||||||
|
* Known issue: inner spacing remains in IE 6.
|
||||||
|
|
||||||
|
button, html input[type="button"]
|
||||||
|
-webkit-appearance: button
|
||||||
|
/* 2
|
||||||
|
cursor: pointer
|
||||||
|
/* 3
|
||||||
|
*overflow: visible
|
||||||
|
/* 4
|
||||||
|
|
||||||
|
input
|
||||||
|
&[type="reset"], &[type="submit"]
|
||||||
|
-webkit-appearance: button
|
||||||
|
/* 2
|
||||||
|
cursor: pointer
|
||||||
|
/* 3
|
||||||
|
*overflow: visible
|
||||||
|
/* 4
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Re-set default cursor for disabled elements.
|
||||||
|
|
||||||
|
button[disabled], html input[disabled]
|
||||||
|
cursor: default
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 1. Address box sizing set to content-box in IE 8/9.
|
||||||
|
* 2. Remove excess padding in IE 8/9.
|
||||||
|
* 3. Remove excess padding in IE 7.
|
||||||
|
* Known issue: excess padding remains in IE 6.
|
||||||
|
|
||||||
|
input
|
||||||
|
&[type="checkbox"], &[type="radio"]
|
||||||
|
box-sizing: border-box
|
||||||
|
/* 1
|
||||||
|
padding: 0
|
||||||
|
/* 2
|
||||||
|
*height: 13px
|
||||||
|
/* 3
|
||||||
|
*width: 13px
|
||||||
|
/* 3
|
||||||
|
&[type="search"]
|
||||||
|
-webkit-appearance: textfield
|
||||||
|
/* 1
|
||||||
|
-moz-box-sizing: content-box
|
||||||
|
-webkit-box-sizing: content-box
|
||||||
|
/* 2
|
||||||
|
box-sizing: content-box
|
||||||
|
&::-webkit-search-cancel-button, &::-webkit-search-decoration
|
||||||
|
-webkit-appearance: none
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 1. Address `appearance` set to `searchfield` in Safari 5 and Chrome.
|
||||||
|
* 2. Address `box-sizing` set to `border-box` in Safari 5 and Chrome
|
||||||
|
* (include `-moz` to future-proof).
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Remove inner padding and search cancel button in Safari 5 and Chrome
|
||||||
|
* on OS X.
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Remove inner padding and border in Firefox 3+.
|
||||||
|
|
||||||
|
button::-moz-focus-inner, input::-moz-focus-inner
|
||||||
|
border: 0
|
||||||
|
padding: 0
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 1. Remove default vertical scrollbar in IE 6/7/8/9.
|
||||||
|
* 2. Improve readability and alignment in all browsers.
|
||||||
|
|
||||||
|
textarea
|
||||||
|
overflow: auto
|
||||||
|
/* 1
|
||||||
|
vertical-align: top
|
||||||
|
/* 2
|
||||||
|
|
||||||
|
/* ==========================================================================
|
||||||
|
* Tables
|
||||||
|
* ==========================================================================
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Remove most spacing between table cells.
|
||||||
|
|
||||||
|
table
|
||||||
|
border-collapse: collapse
|
||||||
|
border-spacing: 0
|
Binary file not shown.
After Width: | Height: | Size: 9.4 KiB |
Binary file not shown.
Binary file not shown.
After Width: | Height: | Size: 28 KiB |
Binary file not shown.
After Width: | Height: | Size: 480 B |
Binary file not shown.
Binary file not shown.
After Width: | Height: | Size: 855 B |
2
openvidu-browser/config/typedoc/custom-theme/assets/js/lib/backbone-1.1.2.min.js
vendored
Normal file
2
openvidu-browser/config/typedoc/custom-theme/assets/js/lib/backbone-1.1.2.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
4
openvidu-browser/config/typedoc/custom-theme/assets/js/lib/jquery-2.1.1.min.js
vendored
Normal file
4
openvidu-browser/config/typedoc/custom-theme/assets/js/lib/jquery-2.1.1.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
6
openvidu-browser/config/typedoc/custom-theme/assets/js/lib/underscore-1.6.0.min.js
vendored
Normal file
6
openvidu-browser/config/typedoc/custom-theme/assets/js/lib/underscore-1.6.0.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,825 @@
|
||||||
|
var __extends = (this && this.__extends) || (function () {
|
||||||
|
var extendStatics = function (d, b) {
|
||||||
|
extendStatics = Object.setPrototypeOf ||
|
||||||
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
||||||
|
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
||||||
|
return extendStatics(d, b);
|
||||||
|
}
|
||||||
|
return function (d, b) {
|
||||||
|
extendStatics(d, b);
|
||||||
|
function __() { this.constructor = d; }
|
||||||
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
||||||
|
};
|
||||||
|
})();
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
typedoc.$html = $('html');
|
||||||
|
var services = [];
|
||||||
|
var components = [];
|
||||||
|
typedoc.$document = $(document);
|
||||||
|
typedoc.$window = $(window);
|
||||||
|
typedoc.$body = $('body');
|
||||||
|
function registerService(constructor, name, priority) {
|
||||||
|
if (priority === void 0) { priority = 0; }
|
||||||
|
services.push({
|
||||||
|
constructor: constructor,
|
||||||
|
name: name,
|
||||||
|
priority: priority,
|
||||||
|
instance: null
|
||||||
|
});
|
||||||
|
services.sort(function (a, b) { return a.priority - b.priority; });
|
||||||
|
}
|
||||||
|
typedoc.registerService = registerService;
|
||||||
|
function registerComponent(constructor, selector, priority, namespace) {
|
||||||
|
if (priority === void 0) { priority = 0; }
|
||||||
|
if (namespace === void 0) { namespace = '*'; }
|
||||||
|
components.push({
|
||||||
|
selector: selector,
|
||||||
|
constructor: constructor,
|
||||||
|
priority: priority,
|
||||||
|
namespace: namespace
|
||||||
|
});
|
||||||
|
components.sort(function (a, b) { return a.priority - b.priority; });
|
||||||
|
}
|
||||||
|
typedoc.registerComponent = registerComponent;
|
||||||
|
if (typeof Backbone != 'undefined') {
|
||||||
|
typedoc['Events'] = (function () {
|
||||||
|
var res = function () { };
|
||||||
|
_.extend(res.prototype, Backbone.Events);
|
||||||
|
return res;
|
||||||
|
})();
|
||||||
|
}
|
||||||
|
var Application = (function (_super) {
|
||||||
|
__extends(Application, _super);
|
||||||
|
function Application() {
|
||||||
|
var _this = _super.call(this) || this;
|
||||||
|
_this.createServices();
|
||||||
|
_this.createComponents(typedoc.$body);
|
||||||
|
return _this;
|
||||||
|
}
|
||||||
|
Application.prototype.createServices = function () {
|
||||||
|
_(services).forEach(function (c) {
|
||||||
|
c.instance = new c.constructor();
|
||||||
|
typedoc[c.name] = c.instance;
|
||||||
|
});
|
||||||
|
};
|
||||||
|
Application.prototype.createComponents = function ($context, namespace) {
|
||||||
|
if (namespace === void 0) { namespace = 'default'; }
|
||||||
|
var result = [];
|
||||||
|
_(components).forEach(function (c) {
|
||||||
|
if (c.namespace != namespace && c.namespace != '*') {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
$context.find(c.selector).each(function (m, el) {
|
||||||
|
var $el = $(el), instance;
|
||||||
|
if (instance = $el.data('component')) {
|
||||||
|
if (_(result).indexOf(instance) == -1) {
|
||||||
|
result.push(instance);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
instance = new c.constructor({ el: el });
|
||||||
|
$el.data('component', instance);
|
||||||
|
result.push(instance);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
return result;
|
||||||
|
};
|
||||||
|
return Application;
|
||||||
|
}(typedoc.Events));
|
||||||
|
typedoc.Application = Application;
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
var FilterItem = (function () {
|
||||||
|
function FilterItem(key, value) {
|
||||||
|
this.key = key;
|
||||||
|
this.value = value;
|
||||||
|
this.defaultValue = value;
|
||||||
|
this.initialize();
|
||||||
|
if (window.localStorage[this.key]) {
|
||||||
|
this.setValue(this.fromLocalStorage(window.localStorage[this.key]));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
FilterItem.prototype.initialize = function () { };
|
||||||
|
FilterItem.prototype.handleValueChange = function (oldValue, newValue) { };
|
||||||
|
FilterItem.prototype.fromLocalStorage = function (value) {
|
||||||
|
return value;
|
||||||
|
};
|
||||||
|
FilterItem.prototype.toLocalStorage = function (value) {
|
||||||
|
return value;
|
||||||
|
};
|
||||||
|
FilterItem.prototype.setValue = function (value) {
|
||||||
|
if (this.value == value)
|
||||||
|
return;
|
||||||
|
var oldValue = this.value;
|
||||||
|
this.value = value;
|
||||||
|
window.localStorage[this.key] = this.toLocalStorage(value);
|
||||||
|
this.handleValueChange(oldValue, value);
|
||||||
|
};
|
||||||
|
return FilterItem;
|
||||||
|
}());
|
||||||
|
var FilterItemCheckbox = (function (_super) {
|
||||||
|
__extends(FilterItemCheckbox, _super);
|
||||||
|
function FilterItemCheckbox() {
|
||||||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||||||
|
}
|
||||||
|
FilterItemCheckbox.prototype.initialize = function () {
|
||||||
|
var _this = this;
|
||||||
|
this.$checkbox = $('#tsd-filter-' + this.key);
|
||||||
|
this.$checkbox.on('change', function () {
|
||||||
|
_this.setValue(_this.$checkbox.prop('checked'));
|
||||||
|
});
|
||||||
|
};
|
||||||
|
FilterItemCheckbox.prototype.handleValueChange = function (oldValue, newValue) {
|
||||||
|
this.$checkbox.prop('checked', this.value);
|
||||||
|
typedoc.$html.toggleClass('toggle-' + this.key, this.value != this.defaultValue);
|
||||||
|
};
|
||||||
|
FilterItemCheckbox.prototype.fromLocalStorage = function (value) {
|
||||||
|
return value == 'true';
|
||||||
|
};
|
||||||
|
FilterItemCheckbox.prototype.toLocalStorage = function (value) {
|
||||||
|
return value ? 'true' : 'false';
|
||||||
|
};
|
||||||
|
return FilterItemCheckbox;
|
||||||
|
}(FilterItem));
|
||||||
|
var FilterItemSelect = (function (_super) {
|
||||||
|
__extends(FilterItemSelect, _super);
|
||||||
|
function FilterItemSelect() {
|
||||||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||||||
|
}
|
||||||
|
FilterItemSelect.prototype.initialize = function () {
|
||||||
|
var _this = this;
|
||||||
|
typedoc.$html.addClass('toggle-' + this.key + this.value);
|
||||||
|
this.$select = $('#tsd-filter-' + this.key);
|
||||||
|
this.$select.on(typedoc.pointerDown + ' mouseover', function () {
|
||||||
|
_this.$select.addClass('active');
|
||||||
|
}).on('mouseleave', function () {
|
||||||
|
_this.$select.removeClass('active');
|
||||||
|
}).on(typedoc.pointerUp, 'li', function (e) {
|
||||||
|
_this.$select.removeClass('active');
|
||||||
|
_this.setValue($(e.target).attr('data-value'));
|
||||||
|
});
|
||||||
|
typedoc.$document.on(typedoc.pointerDown, function (e) {
|
||||||
|
var $path = $(e.target).parents().addBack();
|
||||||
|
if ($path.is(_this.$select))
|
||||||
|
return;
|
||||||
|
_this.$select.removeClass('active');
|
||||||
|
});
|
||||||
|
};
|
||||||
|
FilterItemSelect.prototype.handleValueChange = function (oldValue, newValue) {
|
||||||
|
this.$select.find('li.selected').removeClass('selected');
|
||||||
|
this.$select.find('.tsd-select-label').text(this.$select.find('li[data-value="' + newValue + '"]').addClass('selected').text());
|
||||||
|
typedoc.$html.removeClass('toggle-' + oldValue);
|
||||||
|
typedoc.$html.addClass('toggle-' + newValue);
|
||||||
|
};
|
||||||
|
return FilterItemSelect;
|
||||||
|
}(FilterItem));
|
||||||
|
var Filter = (function (_super) {
|
||||||
|
__extends(Filter, _super);
|
||||||
|
function Filter(options) {
|
||||||
|
var _this = _super.call(this, options) || this;
|
||||||
|
_this.optionVisibility = new FilterItemSelect('visibility', 'private');
|
||||||
|
_this.optionInherited = new FilterItemCheckbox('inherited', true);
|
||||||
|
_this.optionExternals = new FilterItemCheckbox('externals', true);
|
||||||
|
_this.optionOnlyExported = new FilterItemCheckbox('only-exported', false);
|
||||||
|
return _this;
|
||||||
|
}
|
||||||
|
Filter.isSupported = function () {
|
||||||
|
try {
|
||||||
|
return typeof window.localStorage != 'undefined';
|
||||||
|
}
|
||||||
|
catch (e) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return Filter;
|
||||||
|
}(Backbone.View));
|
||||||
|
if (Filter.isSupported()) {
|
||||||
|
typedoc.registerComponent(Filter, '#tsd-filter');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
typedoc.$html.addClass('no-filter');
|
||||||
|
}
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
var MenuHighlight = (function (_super) {
|
||||||
|
__extends(MenuHighlight, _super);
|
||||||
|
function MenuHighlight(options) {
|
||||||
|
var _this = _super.call(this, options) || this;
|
||||||
|
_this.index = 0;
|
||||||
|
_this.listenTo(typedoc.viewport, 'resize', _this.onResize);
|
||||||
|
_this.listenTo(typedoc.viewport, 'scroll', _this.onScroll);
|
||||||
|
_this.createAnchors();
|
||||||
|
return _this;
|
||||||
|
}
|
||||||
|
MenuHighlight.prototype.createAnchors = function () {
|
||||||
|
var _this = this;
|
||||||
|
this.index = 0;
|
||||||
|
this.anchors = [{
|
||||||
|
position: 0
|
||||||
|
}];
|
||||||
|
var base = window.location.href;
|
||||||
|
if (base.indexOf('#') != -1) {
|
||||||
|
base = base.substr(0, base.indexOf('#'));
|
||||||
|
}
|
||||||
|
this.$el.find('a').each(function (index, el) {
|
||||||
|
var href = el.href;
|
||||||
|
if (href.indexOf('#') == -1)
|
||||||
|
return;
|
||||||
|
if (href.substr(0, base.length) != base)
|
||||||
|
return;
|
||||||
|
var hash = href.substr(href.indexOf('#') + 1);
|
||||||
|
var $anchor = $('a.tsd-anchor[name=' + hash + ']');
|
||||||
|
if ($anchor.length == 0)
|
||||||
|
return;
|
||||||
|
_this.anchors.push({
|
||||||
|
$link: $(el.parentNode),
|
||||||
|
$anchor: $anchor,
|
||||||
|
position: 0
|
||||||
|
});
|
||||||
|
});
|
||||||
|
this.onResize();
|
||||||
|
};
|
||||||
|
MenuHighlight.prototype.onResize = function () {
|
||||||
|
var anchor;
|
||||||
|
for (var index = 1, count = this.anchors.length; index < count; index++) {
|
||||||
|
anchor = this.anchors[index];
|
||||||
|
anchor.position = anchor.$anchor.offset().top;
|
||||||
|
}
|
||||||
|
this.anchors.sort(function (a, b) {
|
||||||
|
return a.position - b.position;
|
||||||
|
});
|
||||||
|
this.onScroll(typedoc.viewport.scrollTop);
|
||||||
|
};
|
||||||
|
MenuHighlight.prototype.onScroll = function (scrollTop) {
|
||||||
|
var anchors = this.anchors;
|
||||||
|
var index = this.index;
|
||||||
|
var count = anchors.length - 1;
|
||||||
|
scrollTop += 5;
|
||||||
|
while (index > 0 && anchors[index].position > scrollTop) {
|
||||||
|
index -= 1;
|
||||||
|
}
|
||||||
|
while (index < count && anchors[index + 1].position < scrollTop) {
|
||||||
|
index += 1;
|
||||||
|
}
|
||||||
|
if (this.index != index) {
|
||||||
|
if (this.index > 0)
|
||||||
|
this.anchors[this.index].$link.removeClass('focus');
|
||||||
|
this.index = index;
|
||||||
|
if (this.index > 0)
|
||||||
|
this.anchors[this.index].$link.addClass('focus');
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return MenuHighlight;
|
||||||
|
}(Backbone.View));
|
||||||
|
typedoc.MenuHighlight = MenuHighlight;
|
||||||
|
typedoc.registerComponent(MenuHighlight, '.menu-highlight');
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
var hasPositionSticky = typedoc.$html.hasClass('csspositionsticky');
|
||||||
|
var StickyMode;
|
||||||
|
(function (StickyMode) {
|
||||||
|
StickyMode[StickyMode["None"] = 0] = "None";
|
||||||
|
StickyMode[StickyMode["Secondary"] = 1] = "Secondary";
|
||||||
|
StickyMode[StickyMode["Current"] = 2] = "Current";
|
||||||
|
})(StickyMode || (StickyMode = {}));
|
||||||
|
var MenuSticky = (function (_super) {
|
||||||
|
__extends(MenuSticky, _super);
|
||||||
|
function MenuSticky(options) {
|
||||||
|
var _this = _super.call(this, options) || this;
|
||||||
|
_this.state = '';
|
||||||
|
_this.stickyMode = StickyMode.None;
|
||||||
|
_this.$current = _this.$el.find('> ul.current');
|
||||||
|
_this.$navigation = _this.$el.parents('.menu-sticky-wrap');
|
||||||
|
_this.$container = _this.$el.parents('.row');
|
||||||
|
_this.listenTo(typedoc.viewport, 'resize', _this.onResize);
|
||||||
|
if (!hasPositionSticky) {
|
||||||
|
_this.listenTo(typedoc.viewport, 'scroll', _this.onScroll);
|
||||||
|
}
|
||||||
|
_this.onResize(typedoc.viewport.width, typedoc.viewport.height);
|
||||||
|
return _this;
|
||||||
|
}
|
||||||
|
MenuSticky.prototype.setState = function (state) {
|
||||||
|
if (this.state == state)
|
||||||
|
return;
|
||||||
|
if (this.state != '')
|
||||||
|
this.$navigation.removeClass(this.state);
|
||||||
|
this.state = state;
|
||||||
|
if (this.state != '')
|
||||||
|
this.$navigation.addClass(this.state);
|
||||||
|
};
|
||||||
|
MenuSticky.prototype.onResize = function (width, height) {
|
||||||
|
this.stickyMode = StickyMode.None;
|
||||||
|
this.setState('');
|
||||||
|
var containerTop = this.$container.offset().top;
|
||||||
|
var containerHeight = this.$container.height();
|
||||||
|
var bottom = containerTop + containerHeight;
|
||||||
|
if (this.$navigation.height() < containerHeight) {
|
||||||
|
var elHeight = this.$el.height();
|
||||||
|
var elTop = this.$el.offset().top;
|
||||||
|
if (this.$current.length) {
|
||||||
|
var currentHeight = this.$current.height();
|
||||||
|
var currentTop = this.$current.offset().top;
|
||||||
|
this.$navigation.css('top', containerTop - currentTop + 20);
|
||||||
|
if (currentHeight < height) {
|
||||||
|
this.stickyMode = StickyMode.Current;
|
||||||
|
this.stickyTop = currentTop;
|
||||||
|
this.stickyBottom = bottom - elHeight + (currentTop - elTop) - 20;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (elHeight < height) {
|
||||||
|
this.$navigation.css('top', containerTop - elTop + 20);
|
||||||
|
this.stickyMode = StickyMode.Secondary;
|
||||||
|
this.stickyTop = elTop;
|
||||||
|
this.stickyBottom = bottom - elHeight - 20;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!hasPositionSticky) {
|
||||||
|
this.$navigation.css('left', this.$navigation.offset().left);
|
||||||
|
this.onScroll(typedoc.viewport.scrollTop);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
if (this.stickyMode == StickyMode.Current) {
|
||||||
|
this.setState('sticky-current');
|
||||||
|
}
|
||||||
|
else if (this.stickyMode == StickyMode.Secondary) {
|
||||||
|
this.setState('sticky');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
this.setState('');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
MenuSticky.prototype.onScroll = function (scrollTop) {
|
||||||
|
if (this.stickyMode == StickyMode.Current) {
|
||||||
|
if (scrollTop > this.stickyBottom) {
|
||||||
|
this.setState('sticky-bottom');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
this.setState(scrollTop + 20 > this.stickyTop ? 'sticky-current' : '');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (this.stickyMode == StickyMode.Secondary) {
|
||||||
|
if (scrollTop > this.stickyBottom) {
|
||||||
|
this.setState('sticky-bottom');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
this.setState(scrollTop + 20 > this.stickyTop ? 'sticky' : '');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return MenuSticky;
|
||||||
|
}(Backbone.View));
|
||||||
|
typedoc.MenuSticky = MenuSticky;
|
||||||
|
typedoc.registerComponent(MenuSticky, '.menu-sticky');
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
var search;
|
||||||
|
(function (search) {
|
||||||
|
var SearchLoadingState;
|
||||||
|
(function (SearchLoadingState) {
|
||||||
|
SearchLoadingState[SearchLoadingState["Idle"] = 0] = "Idle";
|
||||||
|
SearchLoadingState[SearchLoadingState["Loading"] = 1] = "Loading";
|
||||||
|
SearchLoadingState[SearchLoadingState["Ready"] = 2] = "Ready";
|
||||||
|
SearchLoadingState[SearchLoadingState["Failure"] = 3] = "Failure";
|
||||||
|
})(SearchLoadingState || (SearchLoadingState = {}));
|
||||||
|
var $el = $('#tsd-search');
|
||||||
|
var $field = $('#tsd-search-field');
|
||||||
|
var $results = $('.results');
|
||||||
|
var base = $el.attr('data-base') + '/';
|
||||||
|
var query = '';
|
||||||
|
var loadingState = SearchLoadingState.Idle;
|
||||||
|
var hasFocus = false;
|
||||||
|
var preventPress = false;
|
||||||
|
var index;
|
||||||
|
function createIndex() {
|
||||||
|
index = new lunr.Index();
|
||||||
|
index.pipeline.add(lunr.trimmer);
|
||||||
|
index.field('name', { boost: 10 });
|
||||||
|
index.field('parent');
|
||||||
|
index.ref('id');
|
||||||
|
var rows = search.data.rows;
|
||||||
|
var pos = 0;
|
||||||
|
var length = rows.length;
|
||||||
|
function batch() {
|
||||||
|
var cycles = 0;
|
||||||
|
while (cycles++ < 100) {
|
||||||
|
index.add(rows[pos]);
|
||||||
|
if (++pos == length) {
|
||||||
|
return setLoadingState(SearchLoadingState.Ready);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
setTimeout(batch, 10);
|
||||||
|
}
|
||||||
|
batch();
|
||||||
|
}
|
||||||
|
function loadIndex() {
|
||||||
|
if (loadingState != SearchLoadingState.Idle)
|
||||||
|
return;
|
||||||
|
setTimeout(function () {
|
||||||
|
if (loadingState == SearchLoadingState.Idle) {
|
||||||
|
setLoadingState(SearchLoadingState.Loading);
|
||||||
|
}
|
||||||
|
}, 500);
|
||||||
|
if (typeof search.data != 'undefined') {
|
||||||
|
createIndex();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$.get($el.attr('data-index'))
|
||||||
|
.done(function (source) {
|
||||||
|
eval(source);
|
||||||
|
createIndex();
|
||||||
|
}).fail(function () {
|
||||||
|
setLoadingState(SearchLoadingState.Failure);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function updateResults() {
|
||||||
|
if (loadingState != SearchLoadingState.Ready)
|
||||||
|
return;
|
||||||
|
$results.empty();
|
||||||
|
var res = index.search(query);
|
||||||
|
for (var i = 0, c = Math.min(10, res.length); i < c; i++) {
|
||||||
|
var row = search.data.rows[res[i].ref];
|
||||||
|
var name = row.name;
|
||||||
|
if (row.parent)
|
||||||
|
name = '<span class="parent">' + row.parent + '.</span>' + name;
|
||||||
|
$results.append('<li class="' + row.classes + '"><a href="' + base + row.url + '" class="tsd-kind-icon">' + name + '</li>');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function setLoadingState(value) {
|
||||||
|
if (loadingState == value)
|
||||||
|
return;
|
||||||
|
$el.removeClass(SearchLoadingState[loadingState].toLowerCase());
|
||||||
|
loadingState = value;
|
||||||
|
$el.addClass(SearchLoadingState[loadingState].toLowerCase());
|
||||||
|
if (value == SearchLoadingState.Ready) {
|
||||||
|
updateResults();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function setHasFocus(value) {
|
||||||
|
if (hasFocus == value)
|
||||||
|
return;
|
||||||
|
hasFocus = value;
|
||||||
|
$el.toggleClass('has-focus');
|
||||||
|
if (!value) {
|
||||||
|
$field.val(query);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
setQuery('');
|
||||||
|
$field.val('');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function setQuery(value) {
|
||||||
|
query = $.trim(value);
|
||||||
|
updateResults();
|
||||||
|
}
|
||||||
|
function setCurrentResult(dir) {
|
||||||
|
var $current = $results.find('.current');
|
||||||
|
if ($current.length == 0) {
|
||||||
|
$results.find(dir == 1 ? 'li:first-child' : 'li:last-child').addClass('current');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
var $rel = dir == 1 ? $current.next('li') : $current.prev('li');
|
||||||
|
if ($rel.length > 0) {
|
||||||
|
$current.removeClass('current');
|
||||||
|
$rel.addClass('current');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function gotoCurrentResult() {
|
||||||
|
var $current = $results.find('.current');
|
||||||
|
if ($current.length == 0) {
|
||||||
|
$current = $results.find('li:first-child');
|
||||||
|
}
|
||||||
|
if ($current.length > 0) {
|
||||||
|
window.location.href = $current.find('a').prop('href');
|
||||||
|
$field.blur();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$field.on('focusin', function () {
|
||||||
|
setHasFocus(true);
|
||||||
|
loadIndex();
|
||||||
|
}).on('focusout', function () {
|
||||||
|
setTimeout(function () { return setHasFocus(false); }, 100);
|
||||||
|
}).on('input', function () {
|
||||||
|
setQuery($.trim($field.val()));
|
||||||
|
}).on('keydown', function (e) {
|
||||||
|
if (e.keyCode == 13 || e.keyCode == 27 || e.keyCode == 38 || e.keyCode == 40) {
|
||||||
|
preventPress = true;
|
||||||
|
e.preventDefault();
|
||||||
|
if (e.keyCode == 13) {
|
||||||
|
gotoCurrentResult();
|
||||||
|
}
|
||||||
|
else if (e.keyCode == 27) {
|
||||||
|
$field.blur();
|
||||||
|
}
|
||||||
|
else if (e.keyCode == 38) {
|
||||||
|
setCurrentResult(-1);
|
||||||
|
}
|
||||||
|
else if (e.keyCode == 40) {
|
||||||
|
setCurrentResult(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
preventPress = false;
|
||||||
|
}
|
||||||
|
}).on('keypress', function (e) {
|
||||||
|
if (preventPress)
|
||||||
|
e.preventDefault();
|
||||||
|
});
|
||||||
|
$('body').on('keydown', function (e) {
|
||||||
|
if (e.altKey || e.ctrlKey || e.metaKey)
|
||||||
|
return;
|
||||||
|
if (!hasFocus && e.keyCode > 47 && e.keyCode < 112) {
|
||||||
|
$field.focus();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})(search = typedoc.search || (typedoc.search = {}));
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
var SignatureGroup = (function () {
|
||||||
|
function SignatureGroup($signature, $description) {
|
||||||
|
this.$signature = $signature;
|
||||||
|
this.$description = $description;
|
||||||
|
}
|
||||||
|
SignatureGroup.prototype.addClass = function (className) {
|
||||||
|
this.$signature.addClass(className);
|
||||||
|
this.$description.addClass(className);
|
||||||
|
return this;
|
||||||
|
};
|
||||||
|
SignatureGroup.prototype.removeClass = function (className) {
|
||||||
|
this.$signature.removeClass(className);
|
||||||
|
this.$description.removeClass(className);
|
||||||
|
return this;
|
||||||
|
};
|
||||||
|
return SignatureGroup;
|
||||||
|
}());
|
||||||
|
var Signature = (function (_super) {
|
||||||
|
__extends(Signature, _super);
|
||||||
|
function Signature(options) {
|
||||||
|
var _this = _super.call(this, options) || this;
|
||||||
|
_this.index = -1;
|
||||||
|
_this.createGroups();
|
||||||
|
if (_this.groups) {
|
||||||
|
_this.$el.addClass('active')
|
||||||
|
.on('touchstart', '.tsd-signature', function (event) { return _this.onClick(event); })
|
||||||
|
.on('click', '.tsd-signature', function (event) { return _this.onClick(event); });
|
||||||
|
_this.$container.addClass('active');
|
||||||
|
_this.setIndex(0);
|
||||||
|
}
|
||||||
|
return _this;
|
||||||
|
}
|
||||||
|
Signature.prototype.setIndex = function (index) {
|
||||||
|
if (index < 0)
|
||||||
|
index = 0;
|
||||||
|
if (index > this.groups.length - 1)
|
||||||
|
index = this.groups.length - 1;
|
||||||
|
if (this.index == index)
|
||||||
|
return;
|
||||||
|
var to = this.groups[index];
|
||||||
|
if (this.index > -1) {
|
||||||
|
var from = this.groups[this.index];
|
||||||
|
typedoc.animateHeight(this.$container, function () {
|
||||||
|
from.removeClass('current').addClass('fade-out');
|
||||||
|
to.addClass('current fade-in');
|
||||||
|
typedoc.viewport.triggerResize();
|
||||||
|
});
|
||||||
|
setTimeout(function () {
|
||||||
|
from.removeClass('fade-out');
|
||||||
|
to.removeClass('fade-in');
|
||||||
|
}, 300);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
to.addClass('current');
|
||||||
|
typedoc.viewport.triggerResize();
|
||||||
|
}
|
||||||
|
this.index = index;
|
||||||
|
};
|
||||||
|
Signature.prototype.createGroups = function () {
|
||||||
|
var _this = this;
|
||||||
|
var $signatures = this.$el.find('> .tsd-signature');
|
||||||
|
if ($signatures.length < 2)
|
||||||
|
return;
|
||||||
|
this.$container = this.$el.siblings('.tsd-descriptions');
|
||||||
|
var $descriptions = this.$container.find('> .tsd-description');
|
||||||
|
this.groups = [];
|
||||||
|
$signatures.each(function (index, el) {
|
||||||
|
_this.groups.push(new SignatureGroup($(el), $descriptions.eq(index)));
|
||||||
|
});
|
||||||
|
};
|
||||||
|
Signature.prototype.onClick = function (e) {
|
||||||
|
var _this = this;
|
||||||
|
e.preventDefault();
|
||||||
|
_(this.groups).forEach(function (group, index) {
|
||||||
|
if (group.$signature.is(e.currentTarget)) {
|
||||||
|
_this.setIndex(index);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
return Signature;
|
||||||
|
}(Backbone.View));
|
||||||
|
typedoc.registerComponent(Signature, '.tsd-signatures');
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
var Toggle = (function (_super) {
|
||||||
|
__extends(Toggle, _super);
|
||||||
|
function Toggle(options) {
|
||||||
|
var _this = _super.call(this, options) || this;
|
||||||
|
_this.className = _this.$el.attr('data-toggle');
|
||||||
|
_this.$el.on(typedoc.pointerUp, function (e) { return _this.onPointerUp(e); });
|
||||||
|
_this.$el.on('click', function (e) { return e.preventDefault(); });
|
||||||
|
typedoc.$document.on(typedoc.pointerDown, function (e) { return _this.onDocumentPointerDown(e); });
|
||||||
|
typedoc.$document.on(typedoc.pointerUp, function (e) { return _this.onDocumentPointerUp(e); });
|
||||||
|
return _this;
|
||||||
|
}
|
||||||
|
Toggle.prototype.setActive = function (value) {
|
||||||
|
if (this.active == value)
|
||||||
|
return;
|
||||||
|
this.active = value;
|
||||||
|
typedoc.$html.toggleClass('has-' + this.className, value);
|
||||||
|
this.$el.toggleClass('active', value);
|
||||||
|
var transition = (this.active ? 'to-has-' : 'from-has-') + this.className;
|
||||||
|
typedoc.$html.addClass(transition);
|
||||||
|
setTimeout(function () { return typedoc.$html.removeClass(transition); }, 500);
|
||||||
|
};
|
||||||
|
Toggle.prototype.onPointerUp = function (event) {
|
||||||
|
if (typedoc.hasPointerMoved)
|
||||||
|
return;
|
||||||
|
this.setActive(true);
|
||||||
|
event.preventDefault();
|
||||||
|
};
|
||||||
|
Toggle.prototype.onDocumentPointerDown = function (e) {
|
||||||
|
if (this.active) {
|
||||||
|
var $path = $(e.target).parents().addBack();
|
||||||
|
if ($path.hasClass('col-menu')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if ($path.hasClass('tsd-filter-group')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.setActive(false);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
Toggle.prototype.onDocumentPointerUp = function (e) {
|
||||||
|
var _this = this;
|
||||||
|
if (typedoc.hasPointerMoved)
|
||||||
|
return;
|
||||||
|
if (this.active) {
|
||||||
|
var $path = $(e.target).parents().addBack();
|
||||||
|
if ($path.hasClass('col-menu')) {
|
||||||
|
var $link = $path.filter('a');
|
||||||
|
if ($link.length) {
|
||||||
|
var href = window.location.href;
|
||||||
|
if (href.indexOf('#') != -1) {
|
||||||
|
href = href.substr(0, href.indexOf('#'));
|
||||||
|
}
|
||||||
|
if ($link.prop('href').substr(0, href.length) == href) {
|
||||||
|
setTimeout(function () { return _this.setActive(false); }, 250);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return Toggle;
|
||||||
|
}(Backbone.View));
|
||||||
|
typedoc.registerComponent(Toggle, 'a[data-toggle]');
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
var Viewport = (function (_super) {
|
||||||
|
__extends(Viewport, _super);
|
||||||
|
function Viewport() {
|
||||||
|
var _this = _super.call(this) || this;
|
||||||
|
_this.scrollTop = 0;
|
||||||
|
_this.width = 0;
|
||||||
|
_this.height = 0;
|
||||||
|
typedoc.$window.on('scroll', _(function () { return _this.onScroll(); }).throttle(10));
|
||||||
|
typedoc.$window.on('resize', _(function () { return _this.onResize(); }).throttle(10));
|
||||||
|
_this.onResize();
|
||||||
|
_this.onScroll();
|
||||||
|
return _this;
|
||||||
|
}
|
||||||
|
Viewport.prototype.triggerResize = function () {
|
||||||
|
this.trigger('resize', this.width, this.height);
|
||||||
|
};
|
||||||
|
Viewport.prototype.onResize = function () {
|
||||||
|
this.width = typedoc.$window.width();
|
||||||
|
this.height = typedoc.$window.height();
|
||||||
|
this.trigger('resize', this.width, this.height);
|
||||||
|
};
|
||||||
|
Viewport.prototype.onScroll = function () {
|
||||||
|
this.scrollTop = typedoc.$window.scrollTop();
|
||||||
|
this.trigger('scroll', this.scrollTop);
|
||||||
|
};
|
||||||
|
return Viewport;
|
||||||
|
}(typedoc.Events));
|
||||||
|
typedoc.Viewport = Viewport;
|
||||||
|
typedoc.registerService(Viewport, 'viewport');
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
typedoc.pointerDown = 'mousedown';
|
||||||
|
typedoc.pointerMove = 'mousemove';
|
||||||
|
typedoc.pointerUp = 'mouseup';
|
||||||
|
typedoc.pointerDownPosition = { x: 0, y: 0 };
|
||||||
|
typedoc.preventNextClick = false;
|
||||||
|
typedoc.isPointerDown = false;
|
||||||
|
typedoc.isPointerTouch = false;
|
||||||
|
typedoc.hasPointerMoved = false;
|
||||||
|
typedoc.isMobile = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
|
||||||
|
typedoc.$html.addClass(typedoc.isMobile ? 'is-mobile' : 'not-mobile');
|
||||||
|
if (typedoc.isMobile && 'ontouchstart' in document.documentElement) {
|
||||||
|
typedoc.isPointerTouch = true;
|
||||||
|
typedoc.pointerDown = 'touchstart';
|
||||||
|
typedoc.pointerMove = 'touchmove';
|
||||||
|
typedoc.pointerUp = 'touchend';
|
||||||
|
}
|
||||||
|
typedoc.$document.on(typedoc.pointerDown, function (e) {
|
||||||
|
typedoc.isPointerDown = true;
|
||||||
|
typedoc.hasPointerMoved = false;
|
||||||
|
var t = (typedoc.pointerDown == 'touchstart' ? e.originalEvent['targetTouches'][0] : e);
|
||||||
|
typedoc.pointerDownPosition.x = t.pageX;
|
||||||
|
typedoc.pointerDownPosition.y = t.pageY;
|
||||||
|
}).on(typedoc.pointerMove, function (e) {
|
||||||
|
if (!typedoc.isPointerDown)
|
||||||
|
return;
|
||||||
|
if (!typedoc.hasPointerMoved) {
|
||||||
|
var t = (typedoc.pointerDown == 'touchstart' ? e.originalEvent['targetTouches'][0] : e);
|
||||||
|
var x = typedoc.pointerDownPosition.x - t.pageX;
|
||||||
|
var y = typedoc.pointerDownPosition.y - t.pageY;
|
||||||
|
typedoc.hasPointerMoved = (Math.sqrt(x * x + y * y) > 10);
|
||||||
|
}
|
||||||
|
}).on(typedoc.pointerUp, function (e) {
|
||||||
|
typedoc.isPointerDown = false;
|
||||||
|
}).on('click', function (e) {
|
||||||
|
if (typedoc.preventNextClick) {
|
||||||
|
e.preventDefault();
|
||||||
|
e.stopImmediatePropagation();
|
||||||
|
typedoc.preventNextClick = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
function getVendorInfo(tuples) {
|
||||||
|
for (var name in tuples) {
|
||||||
|
if (!tuples.hasOwnProperty(name))
|
||||||
|
continue;
|
||||||
|
if (typeof (document.body.style[name]) !== 'undefined') {
|
||||||
|
return { name: name, endEvent: tuples[name] };
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
typedoc.transition = getVendorInfo({
|
||||||
|
'transition': 'transitionend',
|
||||||
|
'OTransition': 'oTransitionEnd',
|
||||||
|
'msTransition': 'msTransitionEnd',
|
||||||
|
'MozTransition': 'transitionend',
|
||||||
|
'WebkitTransition': 'webkitTransitionEnd'
|
||||||
|
});
|
||||||
|
function noTransition($el, callback) {
|
||||||
|
$el.addClass('no-transition');
|
||||||
|
callback();
|
||||||
|
$el.offset();
|
||||||
|
$el.removeClass('no-transition');
|
||||||
|
}
|
||||||
|
typedoc.noTransition = noTransition;
|
||||||
|
function animateHeight($el, callback, success) {
|
||||||
|
var from = $el.height(), to;
|
||||||
|
noTransition($el, function () {
|
||||||
|
callback();
|
||||||
|
$el.css('height', '');
|
||||||
|
to = $el.height();
|
||||||
|
if (from != to && typedoc.transition)
|
||||||
|
$el.css('height', from);
|
||||||
|
});
|
||||||
|
if (from != to && typedoc.transition) {
|
||||||
|
$el.css('height', to);
|
||||||
|
$el.on(typedoc.transition.endEvent, function () {
|
||||||
|
noTransition($el, function () {
|
||||||
|
$el.off(typedoc.transition.endEvent).css('height', '');
|
||||||
|
if (success)
|
||||||
|
success();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
if (success)
|
||||||
|
success();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
typedoc.animateHeight = animateHeight;
|
||||||
|
})(typedoc || (typedoc = {}));
|
||||||
|
var typedoc;
|
||||||
|
(function (typedoc) {
|
||||||
|
typedoc.app = new typedoc.Application();
|
||||||
|
})(typedoc || (typedoc = {}));
|
387
openvidu-browser/config/typedoc/custom-theme/assets/js/src/lib/backbone/backbone.d.ts
vendored
Normal file
387
openvidu-browser/config/typedoc/custom-theme/assets/js/src/lib/backbone/backbone.d.ts
vendored
Normal file
|
@ -0,0 +1,387 @@
|
||||||
|
// Type definitions for Backbone 1.0.0
|
||||||
|
// Project: http://backbonejs.org/
|
||||||
|
// Definitions by: Boris Yankov <https://github.com/borisyankov/>, Natan Vivo <https://github.com/nvivo/>
|
||||||
|
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||||
|
|
||||||
|
/// <reference path="../jquery/jquery.d.ts" />
|
||||||
|
/// <reference path="../underscore/underscore.d.ts" />
|
||||||
|
|
||||||
|
declare module Backbone {
|
||||||
|
|
||||||
|
interface AddOptions extends Silenceable {
|
||||||
|
at?: number;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface HistoryOptions extends Silenceable {
|
||||||
|
pushState?: boolean;
|
||||||
|
root?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface NavigateOptions {
|
||||||
|
trigger?: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface RouterOptions {
|
||||||
|
routes: any;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface Silenceable {
|
||||||
|
silent?: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface Validable {
|
||||||
|
validate?: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface Waitable {
|
||||||
|
wait?: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface Parseable {
|
||||||
|
parse?: any;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface PersistenceOptions {
|
||||||
|
url?: string;
|
||||||
|
beforeSend?: (jqxhr: JQueryXHR) => void;
|
||||||
|
success?: (modelOrCollection?: any, response?: any, options?: any) => void;
|
||||||
|
error?: (modelOrCollection?: any, jqxhr?: JQueryXHR, options?: any) => void;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface ModelSetOptions extends Silenceable, Validable {
|
||||||
|
}
|
||||||
|
|
||||||
|
interface ModelFetchOptions extends PersistenceOptions, ModelSetOptions, Parseable {
|
||||||
|
}
|
||||||
|
|
||||||
|
interface ModelSaveOptions extends Silenceable, Waitable, Validable, Parseable, PersistenceOptions {
|
||||||
|
patch?: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface ModelDestroyOptions extends Waitable, PersistenceOptions {
|
||||||
|
}
|
||||||
|
|
||||||
|
interface CollectionFetchOptions extends PersistenceOptions, Parseable {
|
||||||
|
reset?: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
class Events {
|
||||||
|
on(eventName: string, callback?: Function, context?: any): any;
|
||||||
|
off(eventName?: string, callback?: Function, context?: any): any;
|
||||||
|
trigger(eventName: string, ...args: any[]): any;
|
||||||
|
bind(eventName: string, callback: Function, context?: any): any;
|
||||||
|
unbind(eventName?: string, callback?: Function, context?: any): any;
|
||||||
|
|
||||||
|
once(events: string, callback: Function, context?: any): any;
|
||||||
|
listenTo(object: any, events: string, callback: Function): any;
|
||||||
|
listenToOnce(object: any, events: string, callback: Function): any;
|
||||||
|
stopListening(object?: any, events?: string, callback?: Function): any;
|
||||||
|
}
|
||||||
|
|
||||||
|
class ModelBase extends Events {
|
||||||
|
url: any;
|
||||||
|
parse(response: any, options?: any): any;
|
||||||
|
toJSON(options?: any): any;
|
||||||
|
sync(...arg: any[]): JQueryXHR;
|
||||||
|
}
|
||||||
|
|
||||||
|
class Model extends ModelBase {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Do not use, prefer TypeScript's extend functionality.
|
||||||
|
**/
|
||||||
|
private static extend(properties: any, classProperties?: any): any;
|
||||||
|
|
||||||
|
attributes: any;
|
||||||
|
changed: any[];
|
||||||
|
cid: string;
|
||||||
|
collection: Collection<any>;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Default attributes for the model. It can be an object hash or a method returning an object hash.
|
||||||
|
* For assigning an object hash, do it like this: this.defaults = <any>{ attribute: value, ... };
|
||||||
|
* That works only if you set it in the constructor or the initialize method.
|
||||||
|
**/
|
||||||
|
defaults(): any;
|
||||||
|
id: any;
|
||||||
|
idAttribute: string;
|
||||||
|
validationError: any;
|
||||||
|
urlRoot: any;
|
||||||
|
|
||||||
|
constructor(attributes?: any, options?: any);
|
||||||
|
initialize(attributes?: any): void;
|
||||||
|
|
||||||
|
fetch(options?: ModelFetchOptions): JQueryXHR;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* For strongly-typed access to attributes, use the `get` method only privately in public getter properties.
|
||||||
|
* @example
|
||||||
|
* get name(): string {
|
||||||
|
* return super.get("name");
|
||||||
|
* }
|
||||||
|
**/
|
||||||
|
/*private*/ get(attributeName: string): any;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* For strongly-typed assignment of attributes, use the `set` method only privately in public setter properties.
|
||||||
|
* @example
|
||||||
|
* set name(value: string) {
|
||||||
|
* super.set("name", value);
|
||||||
|
* }
|
||||||
|
**/
|
||||||
|
/*private*/ set(attributeName: string, value: any, options?: ModelSetOptions): Model;
|
||||||
|
set(obj: any, options?: ModelSetOptions): Model;
|
||||||
|
|
||||||
|
change(): any;
|
||||||
|
changedAttributes(attributes?: any): any[];
|
||||||
|
clear(options?: Silenceable): any;
|
||||||
|
clone(): Model;
|
||||||
|
destroy(options?: ModelDestroyOptions): any;
|
||||||
|
escape(attribute: string): string;
|
||||||
|
has(attribute: string): boolean;
|
||||||
|
hasChanged(attribute?: string): boolean;
|
||||||
|
isNew(): boolean;
|
||||||
|
isValid(options?:any): boolean;
|
||||||
|
previous(attribute: string): any;
|
||||||
|
previousAttributes(): any[];
|
||||||
|
save(attributes?: any, options?: ModelSaveOptions): any;
|
||||||
|
unset(attribute: string, options?: Silenceable): Model;
|
||||||
|
validate(attributes: any, options?: any): any;
|
||||||
|
|
||||||
|
private _validate(attrs: any, options: any): boolean;
|
||||||
|
|
||||||
|
// mixins from underscore
|
||||||
|
|
||||||
|
keys(): string[];
|
||||||
|
values(): any[];
|
||||||
|
pairs(): any[];
|
||||||
|
invert(): any;
|
||||||
|
pick(keys: string[]): any;
|
||||||
|
pick(...keys: string[]): any;
|
||||||
|
omit(keys: string[]): any;
|
||||||
|
omit(...keys: string[]): any;
|
||||||
|
}
|
||||||
|
|
||||||
|
class Collection<TModel extends Model> extends ModelBase {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Do not use, prefer TypeScript's extend functionality.
|
||||||
|
**/
|
||||||
|
private static extend(properties: any, classProperties?: any): any;
|
||||||
|
|
||||||
|
// TODO: this really has to be typeof TModel
|
||||||
|
//model: typeof TModel;
|
||||||
|
model: { new(): TModel; }; // workaround
|
||||||
|
models: TModel[];
|
||||||
|
length: number;
|
||||||
|
|
||||||
|
constructor(models?: TModel[], options?: any);
|
||||||
|
|
||||||
|
fetch(options?: CollectionFetchOptions): JQueryXHR;
|
||||||
|
|
||||||
|
comparator(element: TModel): number;
|
||||||
|
comparator(compare: TModel, to?: TModel): number;
|
||||||
|
|
||||||
|
add(model: TModel, options?: AddOptions): Collection<TModel>;
|
||||||
|
add(models: TModel[], options?: AddOptions): Collection<TModel>;
|
||||||
|
at(index: number): TModel;
|
||||||
|
/**
|
||||||
|
* Get a model from a collection, specified by an id, a cid, or by passing in a model.
|
||||||
|
**/
|
||||||
|
get(id: number): TModel;
|
||||||
|
get(id: string): TModel;
|
||||||
|
get(id: Model): TModel;
|
||||||
|
create(attributes: any, options?: ModelSaveOptions): TModel;
|
||||||
|
pluck(attribute: string): any[];
|
||||||
|
push(model: TModel, options?: AddOptions): TModel;
|
||||||
|
pop(options?: Silenceable): TModel;
|
||||||
|
remove(model: TModel, options?: Silenceable): TModel;
|
||||||
|
remove(models: TModel[], options?: Silenceable): TModel[];
|
||||||
|
reset(models?: TModel[], options?: Silenceable): TModel[];
|
||||||
|
set(models?: TModel[], options?: Silenceable): TModel[];
|
||||||
|
shift(options?: Silenceable): TModel;
|
||||||
|
sort(options?: Silenceable): Collection<TModel>;
|
||||||
|
unshift(model: TModel, options?: AddOptions): TModel;
|
||||||
|
where(properies: any): TModel[];
|
||||||
|
findWhere(properties: any): TModel;
|
||||||
|
|
||||||
|
private _prepareModel(attrs?: any, options?: any): any;
|
||||||
|
private _removeReference(model: TModel): void;
|
||||||
|
private _onModelEvent(event: string, model: TModel, collection: Collection<TModel>, options: any): void;
|
||||||
|
|
||||||
|
// mixins from underscore
|
||||||
|
|
||||||
|
all(iterator: (element: TModel, index: number) => boolean, context?: any): boolean;
|
||||||
|
any(iterator: (element: TModel, index: number) => boolean, context?: any): boolean;
|
||||||
|
collect(iterator: (element: TModel, index: number, context?: any) => any[], context?: any): any[];
|
||||||
|
chain(): any;
|
||||||
|
compact(): TModel[];
|
||||||
|
contains(value: any): boolean;
|
||||||
|
countBy(iterator: (element: TModel, index: number) => any): _.Dictionary<number>;
|
||||||
|
countBy(attribute: string): _.Dictionary<number>;
|
||||||
|
detect(iterator: (item: any) => boolean, context?: any): any; // ???
|
||||||
|
difference(...model: TModel[]): TModel[];
|
||||||
|
drop(): TModel;
|
||||||
|
drop(n: number): TModel[];
|
||||||
|
each(iterator: (element: TModel, index: number, list?: any) => void, context?: any): any;
|
||||||
|
every(iterator: (element: TModel, index: number) => boolean, context?: any): boolean;
|
||||||
|
filter(iterator: (element: TModel, index: number) => boolean, context?: any): TModel[];
|
||||||
|
find(iterator: (element: TModel, index: number) => boolean, context?: any): TModel;
|
||||||
|
first(): TModel;
|
||||||
|
first(n: number): TModel[];
|
||||||
|
flatten(shallow?: boolean): TModel[];
|
||||||
|
foldl(iterator: (memo: any, element: TModel, index: number) => any, initialMemo: any, context?: any): any;
|
||||||
|
forEach(iterator: (element: TModel, index: number, list?: any) => void, context?: any): any;
|
||||||
|
groupBy(iterator: (element: TModel, index: number) => string, context?: any): _.Dictionary<TModel[]>;
|
||||||
|
groupBy(attribute: string, context?: any): _.Dictionary<TModel[]>;
|
||||||
|
include(value: any): boolean;
|
||||||
|
indexOf(element: TModel, isSorted?: boolean): number;
|
||||||
|
initial(): TModel;
|
||||||
|
initial(n: number): TModel[];
|
||||||
|
inject(iterator: (memo: any, element: TModel, index: number) => any, initialMemo: any, context?: any): any;
|
||||||
|
intersection(...model: TModel[]): TModel[];
|
||||||
|
isEmpty(object: any): boolean;
|
||||||
|
invoke(methodName: string, args?: any[]): any;
|
||||||
|
last(): TModel;
|
||||||
|
last(n: number): TModel[];
|
||||||
|
lastIndexOf(element: TModel, fromIndex?: number): number;
|
||||||
|
map(iterator: (element: TModel, index: number, context?: any) => any[], context?: any): any[];
|
||||||
|
max(iterator?: (element: TModel, index: number) => any, context?: any): TModel;
|
||||||
|
min(iterator?: (element: TModel, index: number) => any, context?: any): TModel;
|
||||||
|
object(...values: any[]): any[];
|
||||||
|
reduce(iterator: (memo: any, element: TModel, index: number) => any, initialMemo: any, context?: any): any;
|
||||||
|
select(iterator: any, context?: any): any[];
|
||||||
|
size(): number;
|
||||||
|
shuffle(): any[];
|
||||||
|
some(iterator: (element: TModel, index: number) => boolean, context?: any): boolean;
|
||||||
|
sortBy(iterator: (element: TModel, index: number) => number, context?: any): TModel[];
|
||||||
|
sortBy(attribute: string, context?: any): TModel[];
|
||||||
|
sortedIndex(element: TModel, iterator?: (element: TModel, index: number) => number): number;
|
||||||
|
range(stop: number, step?: number): any;
|
||||||
|
range(start: number, stop: number, step?: number): any;
|
||||||
|
reduceRight(iterator: (memo: any, element: TModel, index: number) => any, initialMemo: any, context?: any): any[];
|
||||||
|
reject(iterator: (element: TModel, index: number) => boolean, context?: any): TModel[];
|
||||||
|
rest(): TModel;
|
||||||
|
rest(n: number): TModel[];
|
||||||
|
tail(): TModel;
|
||||||
|
tail(n: number): TModel[];
|
||||||
|
toArray(): any[];
|
||||||
|
union(...model: TModel[]): TModel[];
|
||||||
|
uniq(isSorted?: boolean, iterator?: (element: TModel, index: number) => boolean): TModel[];
|
||||||
|
without(...values: any[]): TModel[];
|
||||||
|
zip(...model: TModel[]): TModel[];
|
||||||
|
}
|
||||||
|
|
||||||
|
class Router extends Events {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Do not use, prefer TypeScript's extend functionality.
|
||||||
|
**/
|
||||||
|
private static extend(properties: any, classProperties?: any): any;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Routes hash or a method returning the routes hash that maps URLs with parameters to methods on your Router.
|
||||||
|
* For assigning routes as object hash, do it like this: this.routes = <any>{ "route": callback, ... };
|
||||||
|
* That works only if you set it in the constructor or the initialize method.
|
||||||
|
**/
|
||||||
|
routes(): any;
|
||||||
|
|
||||||
|
constructor(options?: RouterOptions);
|
||||||
|
initialize(options?: RouterOptions): void;
|
||||||
|
route(route: string, name: string, callback?: Function): Router;
|
||||||
|
navigate(fragment: string, options?: NavigateOptions): Router;
|
||||||
|
navigate(fragment: string, trigger?: boolean): Router;
|
||||||
|
|
||||||
|
private _bindRoutes(): void;
|
||||||
|
private _routeToRegExp(route: string): RegExp;
|
||||||
|
private _extractParameters(route: RegExp, fragment: string): string[];
|
||||||
|
}
|
||||||
|
|
||||||
|
var history: History;
|
||||||
|
|
||||||
|
class History extends Events {
|
||||||
|
|
||||||
|
handlers: any[];
|
||||||
|
interval: number;
|
||||||
|
|
||||||
|
start(options?: HistoryOptions): boolean;
|
||||||
|
|
||||||
|
getHash(window?: Window): string;
|
||||||
|
getFragment(fragment?: string, forcePushState?: boolean): string;
|
||||||
|
stop(): void;
|
||||||
|
route(route: string, callback: Function): number;
|
||||||
|
checkUrl(e?: any): void;
|
||||||
|
loadUrl(fragmentOverride: string): boolean;
|
||||||
|
navigate(fragment: string, options?: any): boolean;
|
||||||
|
started: boolean;
|
||||||
|
options: any;
|
||||||
|
|
||||||
|
private _updateHash(location: Location, fragment: string, replace: boolean): void;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface ViewOptions<TModel extends Model> {
|
||||||
|
model?: TModel;
|
||||||
|
collection?: Backbone.Collection<TModel>;
|
||||||
|
el?: any;
|
||||||
|
id?: string;
|
||||||
|
className?: string;
|
||||||
|
tagName?: string;
|
||||||
|
attributes?: any[];
|
||||||
|
}
|
||||||
|
|
||||||
|
class View<TModel extends Model> extends Events {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Do not use, prefer TypeScript's extend functionality.
|
||||||
|
**/
|
||||||
|
private static extend(properties: any, classProperties?: any): any;
|
||||||
|
|
||||||
|
constructor(options?: ViewOptions<TModel>);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Events hash or a method returning the events hash that maps events/selectors to methods on your View.
|
||||||
|
* For assigning events as object hash, do it like this: this.events = <any>{ "event:selector": callback, ... };
|
||||||
|
* That works only if you set it in the constructor or the initialize method.
|
||||||
|
**/
|
||||||
|
events(): any;
|
||||||
|
|
||||||
|
$(selector: string): JQuery;
|
||||||
|
model: TModel;
|
||||||
|
collection: Collection<TModel>;
|
||||||
|
//template: (json, options?) => string;
|
||||||
|
make(tagName: string, attrs?: any, opts?: any): View<TModel>;
|
||||||
|
setElement(element: HTMLElement, delegate?: boolean): View<TModel>;
|
||||||
|
setElement(element: JQuery, delegate?: boolean): View<TModel>;
|
||||||
|
id: string;
|
||||||
|
cid: string;
|
||||||
|
className: string;
|
||||||
|
tagName: string;
|
||||||
|
|
||||||
|
el: any;
|
||||||
|
$el: JQuery;
|
||||||
|
setElement(element: any): View<TModel>;
|
||||||
|
attributes: any;
|
||||||
|
$(selector: any): JQuery;
|
||||||
|
render(): View<TModel>;
|
||||||
|
remove(): View<TModel>;
|
||||||
|
make(tagName: any, attributes?: any, content?: any): any;
|
||||||
|
delegateEvents(events?: any): any;
|
||||||
|
undelegateEvents(): any;
|
||||||
|
|
||||||
|
_ensureElement(): void;
|
||||||
|
}
|
||||||
|
|
||||||
|
// SYNC
|
||||||
|
function sync(method: string, model: Model, options?: JQueryAjaxSettings): any;
|
||||||
|
function ajax(options?: JQueryAjaxSettings): JQueryXHR;
|
||||||
|
var emulateHTTP: boolean;
|
||||||
|
var emulateJSON: boolean;
|
||||||
|
|
||||||
|
// Utility
|
||||||
|
function noConflict(): typeof Backbone;
|
||||||
|
var $: JQueryStatic;
|
||||||
|
}
|
||||||
|
|
||||||
|
declare module "backbone" {
|
||||||
|
export = Backbone;
|
||||||
|
}
|
3929
openvidu-browser/config/typedoc/custom-theme/assets/js/src/lib/jquery/jquery.d.ts
vendored
Normal file
3929
openvidu-browser/config/typedoc/custom-theme/assets/js/src/lib/jquery/jquery.d.ts
vendored
Normal file
File diff suppressed because it is too large
Load Diff
839
openvidu-browser/config/typedoc/custom-theme/assets/js/src/lib/lunr/lunr.d.ts
vendored
Normal file
839
openvidu-browser/config/typedoc/custom-theme/assets/js/src/lib/lunr/lunr.d.ts
vendored
Normal file
|
@ -0,0 +1,839 @@
|
||||||
|
// Type definitions for lunr.js 0.5.4
|
||||||
|
// Project: https://github.com/olivernn/lunr.js
|
||||||
|
// Definitions by: Sebastian Lenz <https://github.com/sebastian-lenz>
|
||||||
|
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr - http://lunrjs.com - A bit like Solr, but much smaller and not as bright - 0.5.4
|
||||||
|
* Copyright (C) 2014 Oliver Nightingale
|
||||||
|
* MIT Licensed
|
||||||
|
* @license
|
||||||
|
*/
|
||||||
|
declare module lunr
|
||||||
|
{
|
||||||
|
var version:string;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* A function for splitting a string into tokens ready to be inserted into the search index.
|
||||||
|
*
|
||||||
|
* @param token The token to pass through the filter
|
||||||
|
*/
|
||||||
|
function tokenizer(token:string):string;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.stemmer is an english language stemmer, this is a JavaScript implementation of
|
||||||
|
* the PorterStemmer taken from http://tartaurs.org/~martin
|
||||||
|
*
|
||||||
|
* @param token The string to stem
|
||||||
|
*/
|
||||||
|
function stemmer(token:string):string;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.stopWordFilter is an English language stop word list filter, any words contained
|
||||||
|
* in the list will not be passed through the filter.
|
||||||
|
*
|
||||||
|
* This is intended to be used in the Pipeline. If the token does not pass the filter then
|
||||||
|
* undefined will be returned.
|
||||||
|
*
|
||||||
|
* @param token The token to pass through the filter
|
||||||
|
*/
|
||||||
|
function stopWordFilter(token:string):string;
|
||||||
|
|
||||||
|
module stopWordFilter {
|
||||||
|
var stopWords:SortedSet<string>;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.trimmer is a pipeline function for trimming non word characters from the beginning
|
||||||
|
* and end of tokens before they enter the index.
|
||||||
|
*
|
||||||
|
* This implementation may not work correctly for non latin characters and should either
|
||||||
|
* be removed or adapted for use with languages with non-latin characters.
|
||||||
|
* @param token The token to pass through the filter
|
||||||
|
*/
|
||||||
|
function trimmer(token:string):string;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.EventEmitter is an event emitter for lunr. It manages adding and removing event handlers
|
||||||
|
* and triggering events and their handlers.
|
||||||
|
*/
|
||||||
|
class EventEmitter
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Can bind a single function to many different events in one call.
|
||||||
|
*
|
||||||
|
* @param eventName The name(s) of events to bind this function to.
|
||||||
|
* @param handler The function to call when an event is fired. Binds a handler
|
||||||
|
* function to a specific event(s).
|
||||||
|
*/
|
||||||
|
addListener(eventName:string, handler:Function):void;
|
||||||
|
addListener(eventName:string, eventName2:string, handler:Function):void;
|
||||||
|
addListener(eventName:string, eventName2:string, eventName3:string, handler:Function):void;
|
||||||
|
addListener(eventName:string, eventName2:string, eventName3:string, eventName4:string, handler:Function):void;
|
||||||
|
addListener(eventName:string, eventName2:string, eventName3:string, eventName4:string, eventName5:string, handler:Function):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Removes a handler function from a specific event.
|
||||||
|
*
|
||||||
|
* @param eventName The name of the event to remove this function from.
|
||||||
|
* @param handler The function to remove from an event.
|
||||||
|
*/
|
||||||
|
removeListener(eventName:string, handler:Function):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Calls all functions bound to the given event.
|
||||||
|
*
|
||||||
|
* Additional data can be passed to the event handler as arguments to emit after the event name.
|
||||||
|
*
|
||||||
|
* @param eventName The name of the event to emit.
|
||||||
|
* @param args
|
||||||
|
*/
|
||||||
|
emit(eventName:string, ...args:any[]):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Checks whether a handler has ever been stored against an event.
|
||||||
|
*
|
||||||
|
* @param eventName The name of the event to check.
|
||||||
|
*/
|
||||||
|
hasHandler(eventName:string):boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
interface IPipelineFunction {
|
||||||
|
(token:string):string;
|
||||||
|
(token:string, tokenIndex:number):string;
|
||||||
|
(token:string, tokenIndex:number, tokens:string[]):string;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.Pipelines maintain an ordered list of functions to be applied to all tokens in documents
|
||||||
|
* entering the search index and queries being ran against the index.
|
||||||
|
*
|
||||||
|
* An instance of lunr.Index created with the lunr shortcut will contain a pipeline with a stop
|
||||||
|
* word filter and an English language stemmer. Extra functions can be added before or after either
|
||||||
|
* of these functions or these default functions can be removed.
|
||||||
|
*
|
||||||
|
* When run the pipeline will call each function in turn, passing a token, the index of that token
|
||||||
|
* in the original list of all tokens and finally a list of all the original tokens.
|
||||||
|
*
|
||||||
|
* The output of functions in the pipeline will be passed to the next function in the pipeline.
|
||||||
|
* To exclude a token from entering the index the function should return undefined, the rest of
|
||||||
|
* the pipeline will not be called with this token.
|
||||||
|
*
|
||||||
|
* For serialisation of pipelines to work, all functions used in an instance of a pipeline should
|
||||||
|
* be registered with lunr.Pipeline. Registered functions can then be loaded. If trying to load a
|
||||||
|
* serialised pipeline that uses functions that are not registered an error will be thrown.
|
||||||
|
*
|
||||||
|
* If not planning on serialising the pipeline then registering pipeline functions is not necessary.
|
||||||
|
*/
|
||||||
|
class Pipeline
|
||||||
|
{
|
||||||
|
registeredFunctions:{[label:string]:Function};
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register a function with the pipeline.
|
||||||
|
*
|
||||||
|
* Functions that are used in the pipeline should be registered if the pipeline needs to be
|
||||||
|
* serialised, or a serialised pipeline needs to be loaded.
|
||||||
|
*
|
||||||
|
* Registering a function does not add it to a pipeline, functions must still be added to instances
|
||||||
|
* of the pipeline for them to be used when running a pipeline.
|
||||||
|
*
|
||||||
|
* @param fn The function to check for.
|
||||||
|
* @param label The label to register this function with
|
||||||
|
*/
|
||||||
|
registerFunction(fn:IPipelineFunction, label:string):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Warns if the function is not registered as a Pipeline function.
|
||||||
|
*
|
||||||
|
* @param fn The function to check for.
|
||||||
|
*/
|
||||||
|
warnIfFunctionNotRegistered(fn:IPipelineFunction):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Adds new functions to the end of the pipeline.
|
||||||
|
*
|
||||||
|
* Logs a warning if the function has not been registered.
|
||||||
|
*
|
||||||
|
* @param functions Any number of functions to add to the pipeline.
|
||||||
|
*/
|
||||||
|
add(...functions:IPipelineFunction[]):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Adds a single function after a function that already exists in the pipeline.
|
||||||
|
*
|
||||||
|
* Logs a warning if the function has not been registered.
|
||||||
|
*
|
||||||
|
* @param existingFn A function that already exists in the pipeline.
|
||||||
|
* @param newFn The new function to add to the pipeline.
|
||||||
|
*/
|
||||||
|
after(existingFn:IPipelineFunction, newFn:IPipelineFunction):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Adds a single function before a function that already exists in the pipeline.
|
||||||
|
*
|
||||||
|
* Logs a warning if the function has not been registered.
|
||||||
|
*
|
||||||
|
* @param existingFn A function that already exists in the pipeline.
|
||||||
|
* @param newFn The new function to add to the pipeline.
|
||||||
|
*/
|
||||||
|
before(existingFn:IPipelineFunction, newFn:IPipelineFunction):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Removes a function from the pipeline.
|
||||||
|
*
|
||||||
|
* @param fn The function to remove from the pipeline.
|
||||||
|
*/
|
||||||
|
remove(fn:IPipelineFunction):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Runs the current list of functions that make up the pipeline against
|
||||||
|
* the passed tokens.
|
||||||
|
*
|
||||||
|
* @param tokens The tokens to run through the pipeline.
|
||||||
|
*/
|
||||||
|
run(tokens:string[]):string[];
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Resets the pipeline by removing any existing processors.
|
||||||
|
*/
|
||||||
|
reset():void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a representation of the pipeline ready for serialisation.
|
||||||
|
*/
|
||||||
|
toJSON():any;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads a previously serialised pipeline.
|
||||||
|
*
|
||||||
|
* All functions to be loaded must already be registered with lunr.Pipeline. If any function from
|
||||||
|
* the serialised data has not been registered then an error will be thrown.
|
||||||
|
*
|
||||||
|
* @param serialised The serialised pipeline to load.
|
||||||
|
*/
|
||||||
|
static load(serialised:any):Pipeline;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.Vectors implement vector related operations for a series of elements.
|
||||||
|
*/
|
||||||
|
class Vector
|
||||||
|
{
|
||||||
|
list:Node;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Calculates the magnitude of this vector.
|
||||||
|
*/
|
||||||
|
magnitude():number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Calculates the dot product of this vector and another vector.
|
||||||
|
* @param otherVector The vector to compute the dot product with.
|
||||||
|
*/
|
||||||
|
dot(otherVector:Vector):number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Calculates the cosine similarity between this vector and another vector.
|
||||||
|
*
|
||||||
|
* @param otherVector The other vector to calculate the
|
||||||
|
*/
|
||||||
|
similarity(otherVector:Vector):number;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.Vector.Node is a simple struct for each node in a lunr.Vector.
|
||||||
|
*/
|
||||||
|
class Node
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* The index of the node in the vector.
|
||||||
|
*/
|
||||||
|
idx:number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The data at this node in the vector.
|
||||||
|
*/
|
||||||
|
val:number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The node directly after this node in the vector.
|
||||||
|
*/
|
||||||
|
next:Node;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param idx The index of the node in the vector.
|
||||||
|
* @param val The data at this node in the vector.
|
||||||
|
* @param next The node directly after this node in the vector.
|
||||||
|
*/
|
||||||
|
constructor(idx:number, val:number, next:Node);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.SortedSets are used to maintain an array of unique values in a sorted order.
|
||||||
|
*/
|
||||||
|
class SortedSet<T>
|
||||||
|
{
|
||||||
|
elements:T[];
|
||||||
|
|
||||||
|
length:number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Inserts new items into the set in the correct position to maintain the order.
|
||||||
|
*
|
||||||
|
* @param values The objects to add to this set.
|
||||||
|
*/
|
||||||
|
add(...values:T[]):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Converts this sorted set into an array.
|
||||||
|
*/
|
||||||
|
toArray():T[];
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates a new array with the results of calling a provided function on
|
||||||
|
* every element in this sorted set.
|
||||||
|
*
|
||||||
|
* Delegates to Array.prototype.map and has the same signature.
|
||||||
|
*
|
||||||
|
* @param fn The function that is called on each element of the
|
||||||
|
* @param ctx An optional object that can be used as the context
|
||||||
|
*/
|
||||||
|
map(fn:Function, ctx:any):T[];
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Executes a provided function once per sorted set element.
|
||||||
|
*
|
||||||
|
* Delegates to Array.prototype.forEach and has the same signature.
|
||||||
|
*
|
||||||
|
* @param fn The function that is called on each element of the
|
||||||
|
* @param ctx An optional object that can be used as the context
|
||||||
|
*/
|
||||||
|
forEach(fn:Function, ctx:any):any;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the index at which a given element can be found in the sorted
|
||||||
|
* set, or -1 if it is not present.
|
||||||
|
*
|
||||||
|
* @param elem The object to locate in the sorted set.
|
||||||
|
* @param start An optional index at which to start searching from
|
||||||
|
* @param end An optional index at which to stop search from within
|
||||||
|
*/
|
||||||
|
indexOf(elem:T, start?:number, end?:number):number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the position within the sorted set that an element should be
|
||||||
|
* inserted at to maintain the current order of the set.
|
||||||
|
*
|
||||||
|
* This function assumes that the element to search for does not already exist
|
||||||
|
* in the sorted set.
|
||||||
|
*
|
||||||
|
* @param elem - The elem to find the position for in the set
|
||||||
|
* @param start - An optional index at which to start searching from
|
||||||
|
* @param end - An optional index at which to stop search from within
|
||||||
|
*/
|
||||||
|
locationFor(elem:T, start?:number, end?:number):number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates a new lunr.SortedSet that contains the elements in the
|
||||||
|
* intersection of this set and the passed set.
|
||||||
|
*
|
||||||
|
* @param otherSet The set to intersect with this set.
|
||||||
|
*/
|
||||||
|
intersect(otherSet:SortedSet<T>):SortedSet<T>;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates a new lunr.SortedSet that contains the elements in the union of this
|
||||||
|
* set and the passed set.
|
||||||
|
*
|
||||||
|
* @param otherSet The set to union with this set.
|
||||||
|
*/
|
||||||
|
union(otherSet:SortedSet<T>):SortedSet<T>;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Makes a copy of this set
|
||||||
|
*/
|
||||||
|
clone():SortedSet<T>;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a representation of the sorted set ready for serialisation.
|
||||||
|
*/
|
||||||
|
toJSON():any;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads a previously serialised sorted set.
|
||||||
|
*
|
||||||
|
* @param serialisedData The serialised set to load.
|
||||||
|
*/
|
||||||
|
static load<T>(serialisedData:T[]):SortedSet<T>;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
interface IIndexField
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* The name of the field within the document that
|
||||||
|
*/
|
||||||
|
name:string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* An optional boost that can be applied to terms in this field.
|
||||||
|
*/
|
||||||
|
boost:number;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
interface IIndexSearchResult
|
||||||
|
{
|
||||||
|
ref:any;
|
||||||
|
|
||||||
|
score:number;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.Index is object that manages a search index. It contains the indexes and stores
|
||||||
|
* all the tokens and document lookups. It also provides the main user facing API for
|
||||||
|
* the library.
|
||||||
|
*/
|
||||||
|
class Index
|
||||||
|
{
|
||||||
|
eventEmitter:EventEmitter;
|
||||||
|
|
||||||
|
documentStore:Store<string>;
|
||||||
|
|
||||||
|
tokenStore:TokenStore;
|
||||||
|
|
||||||
|
corpusTokens:SortedSet<string>;
|
||||||
|
|
||||||
|
pipeline:Pipeline;
|
||||||
|
|
||||||
|
_fields:IIndexField[];
|
||||||
|
|
||||||
|
_ref:string;
|
||||||
|
|
||||||
|
_idfCache:{[key:string]:string};
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Bind a handler to events being emitted by the index.
|
||||||
|
*
|
||||||
|
* The handler can be bound to many events at the same time.
|
||||||
|
*
|
||||||
|
* @param eventName The name(s) of events to bind the function to.
|
||||||
|
* @param handler The function to call when an event is fired. Binds a handler
|
||||||
|
* function to a specific event(s).
|
||||||
|
*/
|
||||||
|
on(eventName:string, handler:Function):void;
|
||||||
|
on(eventName:string, eventName2:string, handler:Function):void;
|
||||||
|
on(eventName:string, eventName2:string, eventName3:string, handler:Function):void;
|
||||||
|
on(eventName:string, eventName2:string, eventName3:string, eventName4:string, handler:Function):void;
|
||||||
|
on(eventName:string, eventName2:string, eventName3:string, eventName4:string, eventName5:string, handler:Function):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Removes a handler from an event being emitted by the index.
|
||||||
|
*
|
||||||
|
* @param eventName The name of events to remove the function from.
|
||||||
|
* @param handler The serialised set to load.
|
||||||
|
*/
|
||||||
|
off(eventName:string, handler:Function):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Adds a field to the list of fields that will be searchable within documents in the index.
|
||||||
|
*
|
||||||
|
* An optional boost param can be passed to affect how much tokens in this field rank in
|
||||||
|
* search results, by default the boost value is 1.
|
||||||
|
*
|
||||||
|
* Fields should be added before any documents are added to the index, fields that are added
|
||||||
|
* after documents are added to the index will only apply to new documents added to the index.
|
||||||
|
*
|
||||||
|
* @param fieldName The name of the field within the document that
|
||||||
|
* @param options An optional boost that can be applied to terms in this field.
|
||||||
|
*/
|
||||||
|
field(fieldName:string, options?:{boost?:number}):Index;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the property used to uniquely identify documents added to the index, by default this
|
||||||
|
* property is 'id'.
|
||||||
|
*
|
||||||
|
* This should only be changed before adding documents to the index, changing the ref property
|
||||||
|
* without resetting the index can lead to unexpected results.
|
||||||
|
*
|
||||||
|
* @refName The property to use to uniquely identify the
|
||||||
|
*/
|
||||||
|
ref(refName:string):Index;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Add a document to the index.
|
||||||
|
*
|
||||||
|
* This is the way new documents enter the index, this function will run the fields from the
|
||||||
|
* document through the index's pipeline and then add it to the index, it will then show up
|
||||||
|
* in search results.
|
||||||
|
*
|
||||||
|
* An 'add' event is emitted with the document that has been added and the index the document
|
||||||
|
* has been added to. This event can be silenced by passing false as the second argument to add.
|
||||||
|
*
|
||||||
|
* @param doc The document to add to the index.
|
||||||
|
* @param emitEvent Whether or not to emit events, default true.
|
||||||
|
*/
|
||||||
|
add(doc:any, emitEvent?:boolean):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Removes a document from the index.
|
||||||
|
*
|
||||||
|
* To make sure documents no longer show up in search results they can be removed from the
|
||||||
|
* index using this method.
|
||||||
|
*
|
||||||
|
* The document passed only needs to have the same ref property value as the document that was
|
||||||
|
* added to the index, they could be completely different objects.
|
||||||
|
*
|
||||||
|
* A 'remove' event is emitted with the document that has been removed and the index the
|
||||||
|
* document has been removed from. This event can be silenced by passing false as the second
|
||||||
|
* argument to remove.
|
||||||
|
*
|
||||||
|
* @param doc The document to remove from the index.
|
||||||
|
* @param emitEvent Whether to emit remove events, defaults to true
|
||||||
|
*/
|
||||||
|
remove(doc:any, emitEvent?:boolean):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Updates a document in the index.
|
||||||
|
*
|
||||||
|
* When a document contained within the index gets updated, fields changed, added or removed,
|
||||||
|
* to make sure it correctly matched against search queries, it should be updated in the index.
|
||||||
|
*
|
||||||
|
* This method is just a wrapper around [[remove]] and [[add]].
|
||||||
|
*
|
||||||
|
* An 'update' event is emitted with the document that has been updated and the index.
|
||||||
|
* This event can be silenced by passing false as the second argument to update. Only an
|
||||||
|
* update event will be fired, the 'add' and 'remove' events of the underlying calls are
|
||||||
|
* silenced.
|
||||||
|
*
|
||||||
|
* @param doc The document to update in the index.
|
||||||
|
* @param emitEvent Whether to emit update events, defaults to true
|
||||||
|
*/
|
||||||
|
update(doc:any, emitEvent?:boolean):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Calculates the inverse document frequency for a token within the index.
|
||||||
|
*
|
||||||
|
* @param token The token to calculate the idf of.
|
||||||
|
*/
|
||||||
|
idf(token:string):string;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Searches the index using the passed query.
|
||||||
|
*
|
||||||
|
* Queries should be a string, multiple words are allowed and will lead to an AND based
|
||||||
|
* query, e.g. idx.search('foo bar') will run a search for documents containing both
|
||||||
|
* 'foo' and 'bar'.
|
||||||
|
*
|
||||||
|
* All query tokens are passed through the same pipeline that document tokens are passed
|
||||||
|
* through, so any language processing involved will be run on every query term.
|
||||||
|
*
|
||||||
|
* Each query term is expanded, so that the term 'he' might be expanded to 'hello'
|
||||||
|
* and 'help' if those terms were already included in the index.
|
||||||
|
*
|
||||||
|
* Matching documents are returned as an array of objects, each object contains the
|
||||||
|
* matching document ref, as set for this index, and the similarity score for this
|
||||||
|
* document against the query.
|
||||||
|
*
|
||||||
|
* @param query The query to search the index with.
|
||||||
|
*/
|
||||||
|
search(query:string):IIndexSearchResult[];
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Generates a vector containing all the tokens in the document matching the
|
||||||
|
* passed documentRef.
|
||||||
|
*
|
||||||
|
* The vector contains the tf-idf score for each token contained in the document with
|
||||||
|
* the passed documentRef. The vector will contain an element for every token in the
|
||||||
|
* indexes corpus, if the document does not contain that token the element will be 0.
|
||||||
|
*
|
||||||
|
* @param documentRef The ref to find the document with.
|
||||||
|
*/
|
||||||
|
documentVector(documentRef:string):Vector;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a representation of the index ready for serialisation.
|
||||||
|
*/
|
||||||
|
toJSON():any;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Applies a plugin to the current index.
|
||||||
|
*
|
||||||
|
* A plugin is a function that is called with the index as its context. Plugins can be
|
||||||
|
* used to customise or extend the behaviour the index in some way. A plugin is just a
|
||||||
|
* function, that encapsulated the custom behaviour that should be applied to the index.
|
||||||
|
*
|
||||||
|
* The plugin function will be called with the index as its argument, additional arguments
|
||||||
|
* can also be passed when calling use. The function will be called with the index as
|
||||||
|
* its context.
|
||||||
|
*
|
||||||
|
* Example:
|
||||||
|
*
|
||||||
|
* ```javascript
|
||||||
|
* var myPlugin = function(idx, arg1, arg2) {
|
||||||
|
* // `this` is the index to be extended
|
||||||
|
* // apply any extensions etc here.
|
||||||
|
* };
|
||||||
|
*
|
||||||
|
* var idx = lunr(function() {
|
||||||
|
* this.use(myPlugin, 'arg1', 'arg2');
|
||||||
|
* });
|
||||||
|
* ```
|
||||||
|
*
|
||||||
|
* @param plugin The plugin to apply.
|
||||||
|
* @param args
|
||||||
|
*/
|
||||||
|
use(plugin:Function, ...args:any[]):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads a previously serialised index.
|
||||||
|
*
|
||||||
|
* Issues a warning if the index being imported was serialised by a different version
|
||||||
|
* of lunr.
|
||||||
|
*
|
||||||
|
* @param serialisedData The serialised set to load.
|
||||||
|
*/
|
||||||
|
static load(serialisedData:any):Index;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.Store is a simple key-value store used for storing sets of tokens for documents
|
||||||
|
* stored in index.
|
||||||
|
*/
|
||||||
|
class Store<T>
|
||||||
|
{
|
||||||
|
store:{[id:string]:SortedSet<T>};
|
||||||
|
|
||||||
|
length:number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Stores the given tokens in the store against the given id.
|
||||||
|
*
|
||||||
|
* @param id The key used to store the tokens against.
|
||||||
|
* @param tokens The tokens to store against the key.
|
||||||
|
*/
|
||||||
|
set(id:string, tokens:SortedSet<T>):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Retrieves the tokens from the store for a given key.
|
||||||
|
*
|
||||||
|
* @param id The key to lookup and retrieve from the store.
|
||||||
|
*/
|
||||||
|
get(id:string):SortedSet<T>;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Checks whether the store contains a key.
|
||||||
|
*
|
||||||
|
* @param id The id to look up in the store.
|
||||||
|
*/
|
||||||
|
has(id:string):boolean;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Removes the value for a key in the store.
|
||||||
|
*
|
||||||
|
* @param id The id to remove from the store.
|
||||||
|
*/
|
||||||
|
remove(id:string):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a representation of the store ready for serialisation.
|
||||||
|
*/
|
||||||
|
toJSON():any;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads a previously serialised store.
|
||||||
|
*
|
||||||
|
* @param serialisedData The serialised store to load.
|
||||||
|
*/
|
||||||
|
static load<T>(serialisedData:any):Store<T>;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
interface ITokenDocument
|
||||||
|
{
|
||||||
|
ref:number;
|
||||||
|
|
||||||
|
tf:number;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* lunr.TokenStore is used for efficient storing and lookup of the reverse index of token
|
||||||
|
* to document ref.
|
||||||
|
*/
|
||||||
|
class TokenStore
|
||||||
|
{
|
||||||
|
root:{[token:string]:TokenStore};
|
||||||
|
|
||||||
|
docs:{[ref:string]:ITokenDocument};
|
||||||
|
|
||||||
|
length:number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Adds a new token doc pair to the store.
|
||||||
|
*
|
||||||
|
* By default this function starts at the root of the current store, however it can
|
||||||
|
* start at any node of any token store if required.
|
||||||
|
*
|
||||||
|
* @param token The token to store the doc under
|
||||||
|
* @param doc The doc to store against the token
|
||||||
|
* @param root An optional node at which to start looking for the
|
||||||
|
*/
|
||||||
|
add(token:string, doc:ITokenDocument, root?:TokenStore):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Checks whether this key is contained within this lunr.TokenStore.
|
||||||
|
*
|
||||||
|
* @param token The token to check for
|
||||||
|
*/
|
||||||
|
has(token:string):boolean;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Retrieve a node from the token store for a given token.
|
||||||
|
*
|
||||||
|
* @param token The token to get the node for.
|
||||||
|
*/
|
||||||
|
getNode(token:string):TokenStore;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Retrieve the documents for a node for the given token.
|
||||||
|
*
|
||||||
|
* By default this function starts at the root of the current store, however it can
|
||||||
|
* start at any node of any token store if required.
|
||||||
|
*
|
||||||
|
* @param token The token to get the documents for.
|
||||||
|
* @param root An optional node at which to start.
|
||||||
|
*/
|
||||||
|
get(token:string, root:TokenStore):{[ref:string]:ITokenDocument};
|
||||||
|
|
||||||
|
|
||||||
|
count(token:string, root:TokenStore):number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Remove the document identified by ref from the token in the store.
|
||||||
|
*
|
||||||
|
* @param token The token to get the documents for.
|
||||||
|
* @param ref The ref of the document to remove from this token.
|
||||||
|
*/
|
||||||
|
remove(token:string, ref:string):void;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Find all the possible suffixes of the passed token using tokens currently in
|
||||||
|
* the store.
|
||||||
|
*
|
||||||
|
* @param token The token to expand.
|
||||||
|
* @param memo
|
||||||
|
*/
|
||||||
|
expand(token:string, memo?:string[]):string[];
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a representation of the token store ready for serialisation.
|
||||||
|
*/
|
||||||
|
toJSON():any;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Loads a previously serialised token store.
|
||||||
|
*
|
||||||
|
* @param serialisedData The serialised token store to load.
|
||||||
|
*/
|
||||||
|
static load(serialisedData:any):TokenStore;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Convenience function for instantiating a new lunr index and configuring it with the default
|
||||||
|
* pipeline functions and the passed config function.
|
||||||
|
*
|
||||||
|
* When using this convenience function a new index will be created with the following functions
|
||||||
|
* already in the pipeline:
|
||||||
|
*
|
||||||
|
* * lunr.StopWordFilter - filters out any stop words before they enter the index
|
||||||
|
*
|
||||||
|
* * lunr.stemmer - stems the tokens before entering the index.
|
||||||
|
*
|
||||||
|
* Example:
|
||||||
|
*
|
||||||
|
* ```javascript
|
||||||
|
* var idx = lunr(function () {
|
||||||
|
* this.field('title', 10);
|
||||||
|
* this.field('tags', 100);
|
||||||
|
* this.field('body');
|
||||||
|
*
|
||||||
|
* this.ref('cid');
|
||||||
|
*
|
||||||
|
* this.pipeline.add(function () {
|
||||||
|
* // some custom pipeline function
|
||||||
|
* });
|
||||||
|
* });
|
||||||
|
* ```
|
||||||
|
*/
|
||||||
|
declare function lunr(config:Function):lunr.Index;
|
|
@ -0,0 +1,4 @@
|
||||||
|
/// <reference path="jquery/jquery.d.ts" />
|
||||||
|
/// <reference path="underscore/underscore.d.ts" />
|
||||||
|
/// <reference path="backbone/backbone.d.ts" />
|
||||||
|
/// <reference path="lunr/lunr.d.ts" />
|
|
@ -0,0 +1,21 @@
|
||||||
|
{
|
||||||
|
"version": "v4",
|
||||||
|
"repo": "borisyankov/DefinitelyTyped",
|
||||||
|
"ref": "master",
|
||||||
|
"path": "./",
|
||||||
|
"bundle": "./tsd.d.ts",
|
||||||
|
"installed": {
|
||||||
|
"jquery/jquery.d.ts": {
|
||||||
|
"commit": "d4b55bafc0c9c4a2338cb427a4eeaf6023f12a24"
|
||||||
|
},
|
||||||
|
"lunr/lunr.d.ts": {
|
||||||
|
"commit": "f64ae50d573dae7500236a3deaee402f3376a871"
|
||||||
|
},
|
||||||
|
"backbone/backbone.d.ts": {
|
||||||
|
"commit": "d4b55bafc0c9c4a2338cb427a4eeaf6023f12a24"
|
||||||
|
},
|
||||||
|
"underscore/underscore.d.ts": {
|
||||||
|
"commit": "d4b55bafc0c9c4a2338cb427a4eeaf6023f12a24"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
3168
openvidu-browser/config/typedoc/custom-theme/assets/js/src/lib/underscore/underscore.d.ts
vendored
Normal file
3168
openvidu-browser/config/typedoc/custom-theme/assets/js/src/lib/underscore/underscore.d.ts
vendored
Normal file
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,158 @@
|
||||||
|
declare module typedoc
|
||||||
|
{
|
||||||
|
class Events extends Backbone.Events { }
|
||||||
|
}
|
||||||
|
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
export var $html = $('html');
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Service definition.
|
||||||
|
*/
|
||||||
|
export interface IService
|
||||||
|
{
|
||||||
|
constructor:any;
|
||||||
|
name:string;
|
||||||
|
instance:any;
|
||||||
|
priority:number;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Component definition.
|
||||||
|
*/
|
||||||
|
export interface IComponent
|
||||||
|
{
|
||||||
|
constructor:any;
|
||||||
|
selector:string;
|
||||||
|
priority:number;
|
||||||
|
namespace:string;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* List of all known services.
|
||||||
|
*/
|
||||||
|
var services:IService[] = [];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* List of all known components.
|
||||||
|
*/
|
||||||
|
var components:IComponent[] = [];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* jQuery instance of the document.
|
||||||
|
*/
|
||||||
|
export var $document = $(document);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* jQuery instance of the window.
|
||||||
|
*/
|
||||||
|
export var $window = $(window);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* jQuery instance of the window.
|
||||||
|
*/
|
||||||
|
export var $body = $('body');
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register a new component.
|
||||||
|
*/
|
||||||
|
export function registerService(constructor:any, name:string, priority:number = 0) {
|
||||||
|
services.push({
|
||||||
|
constructor: constructor,
|
||||||
|
name: name,
|
||||||
|
priority: priority,
|
||||||
|
instance: null
|
||||||
|
});
|
||||||
|
|
||||||
|
services.sort((a:IService, b:IService) => a.priority - b.priority);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register a new component.
|
||||||
|
*/
|
||||||
|
export function registerComponent(constructor:any, selector:string, priority:number = 0, namespace:string = '*')
|
||||||
|
{
|
||||||
|
components.push({
|
||||||
|
selector: selector,
|
||||||
|
constructor: constructor,
|
||||||
|
priority: priority,
|
||||||
|
namespace: namespace
|
||||||
|
});
|
||||||
|
|
||||||
|
components.sort((a:IComponent, b:IComponent) => a.priority - b.priority);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Copy Backbone.Events to TypeScript class.
|
||||||
|
*/
|
||||||
|
if (typeof Backbone != 'undefined') {
|
||||||
|
typedoc['Events'] = <any>(function() {
|
||||||
|
var res = function() {};
|
||||||
|
_.extend(res.prototype, Backbone.Events);
|
||||||
|
return res;
|
||||||
|
})();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* TypeDoc application class.
|
||||||
|
*/
|
||||||
|
export class Application extends Events
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Create a new Application instance.
|
||||||
|
*/
|
||||||
|
constructor() {
|
||||||
|
super();
|
||||||
|
|
||||||
|
this.createServices();
|
||||||
|
this.createComponents($body);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create all services.
|
||||||
|
*/
|
||||||
|
private createServices() {
|
||||||
|
_(services).forEach((c) => {
|
||||||
|
c.instance = new c.constructor();
|
||||||
|
typedoc[c.name] = c.instance;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create all components beneath the given jQuery element.
|
||||||
|
*/
|
||||||
|
public createComponents($context:JQuery, namespace:string = 'default'):Backbone.View<any>[] {
|
||||||
|
var result = [];
|
||||||
|
_(components).forEach((c) => {
|
||||||
|
if (c.namespace != namespace && c.namespace != '*') {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
$context.find(c.selector).each((m:number, el:HTMLElement) => {
|
||||||
|
var $el = $(el), instance;
|
||||||
|
if (instance = $el.data('component')) {
|
||||||
|
if (_(result).indexOf(instance) == -1) {
|
||||||
|
result.push(instance);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
instance = new c.constructor({el:el});
|
||||||
|
$el.data('component', instance);
|
||||||
|
result.push(instance);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,157 @@
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
class FilterItem<T>
|
||||||
|
{
|
||||||
|
protected key:string;
|
||||||
|
|
||||||
|
protected value:T;
|
||||||
|
|
||||||
|
protected defaultValue:T;
|
||||||
|
|
||||||
|
|
||||||
|
constructor(key:string, value:T) {
|
||||||
|
this.key = key;
|
||||||
|
this.value = value;
|
||||||
|
this.defaultValue = value;
|
||||||
|
|
||||||
|
this.initialize();
|
||||||
|
|
||||||
|
if (window.localStorage[this.key]) {
|
||||||
|
this.setValue(this.fromLocalStorage(window.localStorage[this.key]));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected initialize() {}
|
||||||
|
|
||||||
|
|
||||||
|
protected handleValueChange(oldValue:T, newValue:T) {}
|
||||||
|
|
||||||
|
|
||||||
|
protected fromLocalStorage(value:string):T {
|
||||||
|
return <any>value;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected toLocalStorage(value:T):string {
|
||||||
|
return <any>value;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected setValue(value:T) {
|
||||||
|
if (this.value == value) return;
|
||||||
|
|
||||||
|
var oldValue = this.value;
|
||||||
|
this.value = value;
|
||||||
|
window.localStorage[this.key] = this.toLocalStorage(value);
|
||||||
|
|
||||||
|
this.handleValueChange(oldValue, value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
class FilterItemCheckbox extends FilterItem<boolean>
|
||||||
|
{
|
||||||
|
private $checkbox:JQuery;
|
||||||
|
|
||||||
|
|
||||||
|
protected initialize() {
|
||||||
|
this.$checkbox = $('#tsd-filter-' + this.key);
|
||||||
|
this.$checkbox.on('change', () => {
|
||||||
|
this.setValue(this.$checkbox.prop('checked'));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected handleValueChange(oldValue:boolean, newValue:boolean) {
|
||||||
|
this.$checkbox.prop('checked', this.value);
|
||||||
|
$html.toggleClass('toggle-' + this.key, this.value != this.defaultValue);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected fromLocalStorage(value:string):boolean {
|
||||||
|
return value == 'true';
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected toLocalStorage(value:boolean):string {
|
||||||
|
return value ? 'true' : 'false';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
class FilterItemSelect extends FilterItem<string>
|
||||||
|
{
|
||||||
|
private $select:JQuery;
|
||||||
|
|
||||||
|
|
||||||
|
protected initialize() {
|
||||||
|
$html.addClass('toggle-' + this.key + this.value);
|
||||||
|
|
||||||
|
this.$select = $('#tsd-filter-' + this.key);
|
||||||
|
this.$select.on(pointerDown + ' mouseover', () => {
|
||||||
|
this.$select.addClass('active');
|
||||||
|
}).on('mouseleave', () => {
|
||||||
|
this.$select.removeClass('active');
|
||||||
|
}).on(pointerUp, 'li', (e:JQueryMouseEventObject) => {
|
||||||
|
this.$select.removeClass('active');
|
||||||
|
this.setValue($(e.target).attr('data-value'));
|
||||||
|
});
|
||||||
|
|
||||||
|
$document.on(pointerDown, (e:JQueryMouseEventObject) => {
|
||||||
|
var $path = $(e.target).parents().addBack();
|
||||||
|
if ($path.is(this.$select)) return;
|
||||||
|
|
||||||
|
this.$select.removeClass('active');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
protected handleValueChange(oldValue:string, newValue:string) {
|
||||||
|
this.$select.find('li.selected').removeClass('selected');
|
||||||
|
this.$select.find('.tsd-select-label').text(
|
||||||
|
this.$select.find('li[data-value="' + newValue + '"]').addClass('selected').text());
|
||||||
|
|
||||||
|
$html.removeClass('toggle-' + oldValue);
|
||||||
|
$html.addClass('toggle-' + newValue);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
class Filter extends Backbone.View<any>
|
||||||
|
{
|
||||||
|
private optionVisibility:FilterItemSelect;
|
||||||
|
|
||||||
|
private optionInherited:FilterItemCheckbox;
|
||||||
|
|
||||||
|
private optionOnlyExported:FilterItemCheckbox;
|
||||||
|
|
||||||
|
private optionExternals:FilterItemCheckbox;
|
||||||
|
|
||||||
|
|
||||||
|
constructor(options?:Backbone.ViewOptions<any>) {
|
||||||
|
super(options);
|
||||||
|
|
||||||
|
this.optionVisibility = new FilterItemSelect('visibility', 'private');
|
||||||
|
this.optionInherited = new FilterItemCheckbox('inherited', true);
|
||||||
|
this.optionExternals = new FilterItemCheckbox('externals', true);
|
||||||
|
this.optionOnlyExported = new FilterItemCheckbox('only-exported', false);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static isSupported():boolean {
|
||||||
|
try {
|
||||||
|
return typeof window.localStorage != 'undefined';
|
||||||
|
} catch (e) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (Filter.isSupported()) {
|
||||||
|
registerComponent(Filter, '#tsd-filter');
|
||||||
|
} else {
|
||||||
|
$html.addClass('no-filter');
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,141 @@
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Stored element and position data of a single anchor.
|
||||||
|
*/
|
||||||
|
interface IAnchorInfo
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* jQuery instance of the anchor tag.
|
||||||
|
*/
|
||||||
|
$anchor?:JQuery;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* jQuery instance of the link in the navigation representing this anchor.
|
||||||
|
*/
|
||||||
|
$link?:JQuery;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The vertical offset of the anchor on the page.
|
||||||
|
*/
|
||||||
|
position:number;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Manages the sticky state of the navigation and moves the highlight
|
||||||
|
* to the current navigation item.
|
||||||
|
*/
|
||||||
|
export class MenuHighlight extends Backbone.View<any>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* List of all discovered anchors.
|
||||||
|
*/
|
||||||
|
private anchors:IAnchorInfo[];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Index of the currently highlighted anchor.
|
||||||
|
*/
|
||||||
|
private index:number = 0;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create a new MenuHighlight instance.
|
||||||
|
*
|
||||||
|
* @param options Backbone view constructor options.
|
||||||
|
*/
|
||||||
|
constructor(options:Backbone.ViewOptions<any>) {
|
||||||
|
super(options);
|
||||||
|
|
||||||
|
this.listenTo(viewport, 'resize', this.onResize);
|
||||||
|
this.listenTo(viewport, 'scroll', this.onScroll);
|
||||||
|
|
||||||
|
this.createAnchors();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Find all anchors on the current page.
|
||||||
|
*/
|
||||||
|
private createAnchors() {
|
||||||
|
this.index = 0;
|
||||||
|
this.anchors = [{
|
||||||
|
position: 0
|
||||||
|
}];
|
||||||
|
|
||||||
|
var base = window.location.href;
|
||||||
|
if (base.indexOf('#') != -1) {
|
||||||
|
base = base.substr(0, base.indexOf('#'));
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$el.find('a').each((index, el:HTMLAnchorElement) => {
|
||||||
|
var href = el.href;
|
||||||
|
if (href.indexOf('#') == -1) return;
|
||||||
|
if (href.substr(0, base.length) != base) return;
|
||||||
|
|
||||||
|
var hash = href.substr(href.indexOf('#') + 1);
|
||||||
|
var $anchor = $('a.tsd-anchor[name=' + hash + ']');
|
||||||
|
if ($anchor.length == 0) return;
|
||||||
|
|
||||||
|
this.anchors.push({
|
||||||
|
$link: $(el.parentNode),
|
||||||
|
$anchor: $anchor,
|
||||||
|
position: 0
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
this.onResize();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Triggered after the viewport was resized.
|
||||||
|
*/
|
||||||
|
private onResize() {
|
||||||
|
var anchor;
|
||||||
|
for (var index = 1, count = this.anchors.length; index < count; index++) {
|
||||||
|
anchor = this.anchors[index];
|
||||||
|
anchor.position = anchor.$anchor.offset().top;
|
||||||
|
}
|
||||||
|
|
||||||
|
this.anchors.sort((a, b) => {
|
||||||
|
return a.position - b.position;
|
||||||
|
});
|
||||||
|
|
||||||
|
this.onScroll(viewport.scrollTop);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Triggered after the viewport was scrolled.
|
||||||
|
*
|
||||||
|
* @param scrollTop The current vertical scroll position.
|
||||||
|
*/
|
||||||
|
private onScroll(scrollTop:number) {
|
||||||
|
var anchors = this.anchors;
|
||||||
|
var index = this.index;
|
||||||
|
var count = anchors.length - 1;
|
||||||
|
|
||||||
|
scrollTop += 5;
|
||||||
|
while (index > 0 && anchors[index].position > scrollTop) {
|
||||||
|
index -= 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
while (index < count && anchors[index + 1].position < scrollTop) {
|
||||||
|
index += 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.index != index) {
|
||||||
|
if (this.index > 0) this.anchors[this.index].$link.removeClass('focus');
|
||||||
|
this.index = index;
|
||||||
|
if (this.index > 0) this.anchors[this.index].$link.addClass('focus');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register this component.
|
||||||
|
*/
|
||||||
|
registerComponent(MenuHighlight, '.menu-highlight');
|
||||||
|
}
|
|
@ -0,0 +1,182 @@
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
var hasPositionSticky = $html.hasClass('csspositionsticky');
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Defines the known ways to make the navigation sticky.
|
||||||
|
*/
|
||||||
|
enum StickyMode
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* The navigation is not sticky at all.
|
||||||
|
*/
|
||||||
|
None,
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The entire secondary navigation will stick to the top.
|
||||||
|
*/
|
||||||
|
Secondary,
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Only the current root navigation item will stick to the top.
|
||||||
|
*/
|
||||||
|
Current
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Controls the sticky behaviour of the secondary menu.
|
||||||
|
*/
|
||||||
|
export class MenuSticky extends Backbone.View<any>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* jQuery instance of the current navigation item.
|
||||||
|
*/
|
||||||
|
private $current:JQuery;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* jQuery instance of the parent representing the entire navigation.
|
||||||
|
*/
|
||||||
|
private $navigation:JQuery;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* jQuery instance of the parent representing entire sticky container.
|
||||||
|
*/
|
||||||
|
private $container:JQuery;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The current state of the menu.
|
||||||
|
*/
|
||||||
|
private state:string = '';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The current mode for determining the sticky position.
|
||||||
|
*/
|
||||||
|
private stickyMode:StickyMode = StickyMode.None;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The threshold at which the menu is attached to the top.
|
||||||
|
*/
|
||||||
|
private stickyTop:number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The threshold at which the menu is attached to the bottom.
|
||||||
|
*/
|
||||||
|
private stickyBottom:number;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create a new MenuSticky instance.
|
||||||
|
*
|
||||||
|
* @param options Backbone view constructor options.
|
||||||
|
*/
|
||||||
|
constructor(options:Backbone.ViewOptions<any>) {
|
||||||
|
super(options);
|
||||||
|
|
||||||
|
this.$current = this.$el.find('> ul.current');
|
||||||
|
this.$navigation = this.$el.parents('.menu-sticky-wrap');
|
||||||
|
this.$container = this.$el.parents('.row');
|
||||||
|
|
||||||
|
this.listenTo(viewport, 'resize', this.onResize);
|
||||||
|
if (!hasPositionSticky) {
|
||||||
|
this.listenTo(viewport, 'scroll', this.onScroll);
|
||||||
|
}
|
||||||
|
|
||||||
|
this.onResize(viewport.width, viewport.height);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set the current sticky state.
|
||||||
|
*
|
||||||
|
* @param state The new sticky state.
|
||||||
|
*/
|
||||||
|
private setState(state:string) {
|
||||||
|
if (this.state == state) return;
|
||||||
|
|
||||||
|
if (this.state != '') this.$navigation.removeClass(this.state);
|
||||||
|
this.state = state;
|
||||||
|
if (this.state != '') this.$navigation.addClass(this.state);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Triggered after the viewport was resized.
|
||||||
|
*
|
||||||
|
* @param width The width of the viewport.
|
||||||
|
* @param height The height of the viewport.
|
||||||
|
*/
|
||||||
|
private onResize(width:number, height:number) {
|
||||||
|
this.stickyMode = StickyMode.None;
|
||||||
|
this.setState('');
|
||||||
|
|
||||||
|
var containerTop = this.$container.offset().top;
|
||||||
|
var containerHeight = this.$container.height();
|
||||||
|
var bottom = containerTop + containerHeight;
|
||||||
|
if (this.$navigation.height() < containerHeight) {
|
||||||
|
var elHeight = this.$el.height();
|
||||||
|
var elTop = this.$el.offset().top;
|
||||||
|
|
||||||
|
if (this.$current.length) {
|
||||||
|
var currentHeight = this.$current.height();
|
||||||
|
var currentTop = this.$current.offset().top;
|
||||||
|
|
||||||
|
this.$navigation.css('top', containerTop - currentTop + 20);
|
||||||
|
if (currentHeight < height) {
|
||||||
|
this.stickyMode = StickyMode.Current;
|
||||||
|
this.stickyTop = currentTop;
|
||||||
|
this.stickyBottom = bottom - elHeight + (currentTop - elTop) - 20;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (elHeight < height) {
|
||||||
|
this.$navigation.css('top', containerTop - elTop + 20);
|
||||||
|
this.stickyMode = StickyMode.Secondary;
|
||||||
|
this.stickyTop = elTop;
|
||||||
|
this.stickyBottom = bottom - elHeight - 20;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!hasPositionSticky) {
|
||||||
|
this.$navigation.css('left', this.$navigation.offset().left);
|
||||||
|
this.onScroll(viewport.scrollTop);
|
||||||
|
} else {
|
||||||
|
if (this.stickyMode == StickyMode.Current) {
|
||||||
|
this.setState('sticky-current');
|
||||||
|
} else if (this.stickyMode == StickyMode.Secondary) {
|
||||||
|
this.setState('sticky');
|
||||||
|
} else {
|
||||||
|
this.setState('');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Triggered after the viewport was scrolled.
|
||||||
|
*
|
||||||
|
* @param scrollTop The current vertical scroll position.
|
||||||
|
*/
|
||||||
|
private onScroll(scrollTop:number) {
|
||||||
|
if (this.stickyMode == StickyMode.Current) {
|
||||||
|
if (scrollTop > this.stickyBottom) {
|
||||||
|
this.setState('sticky-bottom');
|
||||||
|
} else {
|
||||||
|
this.setState(scrollTop + 20 > this.stickyTop ? 'sticky-current' : '');
|
||||||
|
}
|
||||||
|
} else if (this.stickyMode == StickyMode.Secondary) {
|
||||||
|
if (scrollTop > this.stickyBottom) {
|
||||||
|
this.setState('sticky-bottom');
|
||||||
|
} else {
|
||||||
|
this.setState(scrollTop + 20 > this.stickyTop ? 'sticky' : '');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register this component.
|
||||||
|
*/
|
||||||
|
registerComponent(MenuSticky, '.menu-sticky');
|
||||||
|
}
|
|
@ -0,0 +1,268 @@
|
||||||
|
declare module typedoc.search
|
||||||
|
{
|
||||||
|
interface IDocument {
|
||||||
|
id:number;
|
||||||
|
kind:number;
|
||||||
|
name:string;
|
||||||
|
url:string;
|
||||||
|
classes:string;
|
||||||
|
parent?:string;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface IData {
|
||||||
|
kinds:{[kind:number]:string};
|
||||||
|
rows:IDocument[];
|
||||||
|
}
|
||||||
|
|
||||||
|
var data:IData;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
module typedoc.search
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Loading state definitions.
|
||||||
|
*/
|
||||||
|
enum SearchLoadingState
|
||||||
|
{
|
||||||
|
Idle, Loading, Ready, Failure
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The element holding the search widget and results.
|
||||||
|
*/
|
||||||
|
var $el:JQuery = $('#tsd-search');
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The input field of the search widget.
|
||||||
|
*/
|
||||||
|
var $field:JQuery = $('#tsd-search-field');
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The result list wrapper.
|
||||||
|
*/
|
||||||
|
var $results:JQuery = $('.results');
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The base url that must be prepended to the indexed urls.
|
||||||
|
*/
|
||||||
|
var base:string = $el.attr('data-base') + '/';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The current query string.
|
||||||
|
*/
|
||||||
|
var query:string = '';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The state the search is currently in.
|
||||||
|
*/
|
||||||
|
var loadingState:SearchLoadingState = SearchLoadingState.Idle;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is the input field focused?
|
||||||
|
*/
|
||||||
|
var hasFocus:boolean = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Should the next key press be prevents?
|
||||||
|
*/
|
||||||
|
var preventPress:boolean = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The lunr index used to search the documentation.
|
||||||
|
*/
|
||||||
|
var index:lunr.Index;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instantiate the lunr index.
|
||||||
|
*/
|
||||||
|
function createIndex() {
|
||||||
|
index = new lunr.Index();
|
||||||
|
index.pipeline.add(
|
||||||
|
lunr.trimmer
|
||||||
|
);
|
||||||
|
|
||||||
|
index.field('name', {boost:10});
|
||||||
|
index.field('parent');
|
||||||
|
index.ref('id');
|
||||||
|
|
||||||
|
var rows = data.rows;
|
||||||
|
var pos = 0;
|
||||||
|
var length = rows.length;
|
||||||
|
function batch() {
|
||||||
|
var cycles = 0;
|
||||||
|
while (cycles++ < 100) {
|
||||||
|
index.add(rows[pos]);
|
||||||
|
if (++pos == length) {
|
||||||
|
return setLoadingState(SearchLoadingState.Ready);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
setTimeout(batch, 10);
|
||||||
|
}
|
||||||
|
|
||||||
|
batch();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Lazy load the search index and parse it.
|
||||||
|
*/
|
||||||
|
function loadIndex() {
|
||||||
|
if (loadingState != SearchLoadingState.Idle) return;
|
||||||
|
setTimeout(() => {
|
||||||
|
if (loadingState == SearchLoadingState.Idle) {
|
||||||
|
setLoadingState(SearchLoadingState.Loading);
|
||||||
|
}
|
||||||
|
}, 500);
|
||||||
|
|
||||||
|
if (typeof data != 'undefined') {
|
||||||
|
createIndex();
|
||||||
|
} else {
|
||||||
|
$.get($el.attr('data-index'))
|
||||||
|
.done((source:string) => {
|
||||||
|
eval(source);
|
||||||
|
createIndex();
|
||||||
|
}).fail(() => {
|
||||||
|
setLoadingState(SearchLoadingState.Failure);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update the visible state of the search control.
|
||||||
|
*/
|
||||||
|
function updateResults() {
|
||||||
|
if (loadingState != SearchLoadingState.Ready) return;
|
||||||
|
$results.empty();
|
||||||
|
|
||||||
|
var res = index.search(query);
|
||||||
|
for (var i = 0, c = Math.min(10, res.length); i < c; i++) {
|
||||||
|
var row = data.rows[res[i].ref];
|
||||||
|
var name = row.name;
|
||||||
|
if (row.parent) name = '<span class="parent">' + row.parent + '.</span>' + name;
|
||||||
|
$results.append('<li class="' + row.classes + '"><a href="' + base + row.url + '" class="tsd-kind-icon">' + name + '</li>');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set the loading state and update the visual state accordingly.
|
||||||
|
*/
|
||||||
|
function setLoadingState(value:SearchLoadingState) {
|
||||||
|
if (loadingState == value) return;
|
||||||
|
|
||||||
|
$el.removeClass(SearchLoadingState[loadingState].toLowerCase());
|
||||||
|
loadingState = value;
|
||||||
|
$el.addClass(SearchLoadingState[loadingState].toLowerCase());
|
||||||
|
|
||||||
|
if (value == SearchLoadingState.Ready) {
|
||||||
|
updateResults();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set the focus state and update the visual state accordingly.
|
||||||
|
*/
|
||||||
|
function setHasFocus(value:boolean) {
|
||||||
|
if (hasFocus == value) return;
|
||||||
|
hasFocus = value;
|
||||||
|
$el.toggleClass('has-focus');
|
||||||
|
|
||||||
|
if (!value) {
|
||||||
|
$field.val(query);
|
||||||
|
} else {
|
||||||
|
setQuery('');
|
||||||
|
$field.val('');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set the query string and update the results.
|
||||||
|
*/
|
||||||
|
function setQuery(value:string) {
|
||||||
|
query = $.trim(value);
|
||||||
|
updateResults();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Move the highlight within the result set.
|
||||||
|
*/
|
||||||
|
function setCurrentResult(dir:number) {
|
||||||
|
var $current = $results.find('.current');
|
||||||
|
if ($current.length == 0) {
|
||||||
|
$results.find(dir == 1 ? 'li:first-child' : 'li:last-child').addClass('current');
|
||||||
|
} else {
|
||||||
|
var $rel = dir == 1 ? $current.next('li') : $current.prev('li');
|
||||||
|
if ($rel.length > 0) {
|
||||||
|
$current.removeClass('current');
|
||||||
|
$rel.addClass('current');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Navigate to the highlighted result.
|
||||||
|
*/
|
||||||
|
function gotoCurrentResult() {
|
||||||
|
var $current = $results.find('.current');
|
||||||
|
|
||||||
|
if ($current.length == 0) {
|
||||||
|
$current = $results.find('li:first-child');
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($current.length > 0) {
|
||||||
|
window.location.href = $current.find('a').prop('href');
|
||||||
|
$field.blur();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Bind all required events on the input field.
|
||||||
|
*/
|
||||||
|
$field.on('focusin', () => {
|
||||||
|
setHasFocus(true);
|
||||||
|
loadIndex();
|
||||||
|
}).on('focusout', () => {
|
||||||
|
setTimeout(() => setHasFocus(false), 100);
|
||||||
|
}).on('input', () => {
|
||||||
|
setQuery($.trim($field.val()));
|
||||||
|
}).on('keydown', (e:JQueryKeyEventObject) => {
|
||||||
|
if (e.keyCode == 13 || e.keyCode == 27 || e.keyCode == 38 || e.keyCode == 40) {
|
||||||
|
preventPress = true;
|
||||||
|
e.preventDefault();
|
||||||
|
|
||||||
|
if (e.keyCode == 13) {
|
||||||
|
gotoCurrentResult();
|
||||||
|
} else if (e.keyCode == 27) {
|
||||||
|
$field.blur();
|
||||||
|
} else if (e.keyCode == 38) {
|
||||||
|
setCurrentResult(-1);
|
||||||
|
} else if (e.keyCode == 40) {
|
||||||
|
setCurrentResult(1);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
preventPress = false;
|
||||||
|
}
|
||||||
|
}).on('keypress', (e) => {
|
||||||
|
if (preventPress) e.preventDefault();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Start searching by pressing a key on the body.
|
||||||
|
*/
|
||||||
|
$('body').on('keydown', (e:JQueryKeyEventObject) => {
|
||||||
|
if (e.altKey || e.ctrlKey || e.metaKey) return;
|
||||||
|
if (!hasFocus && e.keyCode > 47 && e.keyCode < 112) {
|
||||||
|
$field.focus();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
|
@ -0,0 +1,167 @@
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Holds a signature and its description.
|
||||||
|
*/
|
||||||
|
class SignatureGroup
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* The target signature.
|
||||||
|
*/
|
||||||
|
$signature:JQuery;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The description for the signature.
|
||||||
|
*/
|
||||||
|
$description:JQuery;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create a new SignatureGroup instance.
|
||||||
|
*
|
||||||
|
* @param $signature The target signature.
|
||||||
|
* @param $description The description for the signature.
|
||||||
|
*/
|
||||||
|
constructor($signature, $description) {
|
||||||
|
this.$signature = $signature;
|
||||||
|
this.$description = $description;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Add the given class to all elements of the group.
|
||||||
|
*
|
||||||
|
* @param className The class name to add.
|
||||||
|
*/
|
||||||
|
addClass(className:string):SignatureGroup {
|
||||||
|
this.$signature.addClass(className);
|
||||||
|
this.$description.addClass(className);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Remove the given class from all elements of the group.
|
||||||
|
*
|
||||||
|
* @param className The class name to remove.
|
||||||
|
*/
|
||||||
|
removeClass(className:string):SignatureGroup {
|
||||||
|
this.$signature.removeClass(className);
|
||||||
|
this.$description.removeClass(className);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Controls the tab like behaviour of methods and functions with multiple signatures.
|
||||||
|
*/
|
||||||
|
class Signature extends Backbone.View<any>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* List of found signature groups.
|
||||||
|
*/
|
||||||
|
private groups:SignatureGroup[];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The container holding all the descriptions.
|
||||||
|
*/
|
||||||
|
private $container:JQuery;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The index of the currently displayed signature.
|
||||||
|
*/
|
||||||
|
private index:number = -1;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create a new Signature instance.
|
||||||
|
*
|
||||||
|
* @param options Backbone view constructor options.
|
||||||
|
*/
|
||||||
|
constructor(options:Backbone.ViewOptions<any>) {
|
||||||
|
super(options);
|
||||||
|
|
||||||
|
this.createGroups();
|
||||||
|
|
||||||
|
if (this.groups) {
|
||||||
|
this.$el.addClass('active')
|
||||||
|
.on('touchstart', '.tsd-signature', (event) => this.onClick(event))
|
||||||
|
.on('click', '.tsd-signature', (event) => this.onClick(event));
|
||||||
|
this.$container.addClass('active');
|
||||||
|
this.setIndex(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Set the index of the active signature.
|
||||||
|
*
|
||||||
|
* @param index The index of the signature to activate.
|
||||||
|
*/
|
||||||
|
private setIndex(index:number) {
|
||||||
|
if (index < 0) index = 0;
|
||||||
|
if (index > this.groups.length - 1) index = this.groups.length - 1;
|
||||||
|
if (this.index == index) return;
|
||||||
|
|
||||||
|
var to = this.groups[index];
|
||||||
|
if (this.index > -1) {
|
||||||
|
var from = this.groups[this.index];
|
||||||
|
|
||||||
|
animateHeight(this.$container, () => {
|
||||||
|
from.removeClass('current').addClass('fade-out');
|
||||||
|
to.addClass('current fade-in');
|
||||||
|
viewport.triggerResize();
|
||||||
|
});
|
||||||
|
|
||||||
|
setTimeout(() => {
|
||||||
|
from.removeClass('fade-out');
|
||||||
|
to.removeClass('fade-in');
|
||||||
|
}, 300);
|
||||||
|
} else {
|
||||||
|
to.addClass('current');
|
||||||
|
viewport.triggerResize();
|
||||||
|
}
|
||||||
|
|
||||||
|
this.index = index;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Find all signature/description groups.
|
||||||
|
*/
|
||||||
|
private createGroups() {
|
||||||
|
var $signatures = this.$el.find('> .tsd-signature');
|
||||||
|
if ($signatures.length < 2) return;
|
||||||
|
|
||||||
|
this.$container = this.$el.siblings('.tsd-descriptions');
|
||||||
|
var $descriptions = this.$container.find('> .tsd-description');
|
||||||
|
|
||||||
|
this.groups = [];
|
||||||
|
$signatures.each((index, el) => {
|
||||||
|
this.groups.push(new SignatureGroup($(el), $descriptions.eq(index)));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Triggered when the user clicks onto a signature header.
|
||||||
|
*
|
||||||
|
* @param e The related jQuery event object.
|
||||||
|
*/
|
||||||
|
private onClick(e:JQueryMouseEventObject) {
|
||||||
|
e.preventDefault();
|
||||||
|
_(this.groups).forEach((group, index) => {
|
||||||
|
if (group.$signature.is(e.currentTarget)) {
|
||||||
|
this.setIndex(index);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register this component.
|
||||||
|
*/
|
||||||
|
registerComponent(Signature, '.tsd-signatures');
|
||||||
|
}
|
|
@ -0,0 +1,84 @@
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Enabled simple toggle buttons.
|
||||||
|
*/
|
||||||
|
class Toggle extends Backbone.View<any>
|
||||||
|
{
|
||||||
|
active:boolean;
|
||||||
|
|
||||||
|
className:string;
|
||||||
|
|
||||||
|
|
||||||
|
constructor(options:Backbone.ViewOptions<any>) {
|
||||||
|
super(options);
|
||||||
|
|
||||||
|
this.className = this.$el.attr('data-toggle');
|
||||||
|
this.$el.on(pointerUp, (e) => this.onPointerUp(e));
|
||||||
|
this.$el.on('click', (e) => e.preventDefault());
|
||||||
|
$document.on(pointerDown, (e) => this.onDocumentPointerDown(e));
|
||||||
|
$document.on(pointerUp, (e) => this.onDocumentPointerUp(e));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
setActive(value:boolean) {
|
||||||
|
if (this.active == value) return;
|
||||||
|
this.active = value;
|
||||||
|
|
||||||
|
$html.toggleClass('has-' + this.className, value);
|
||||||
|
this.$el.toggleClass('active', value);
|
||||||
|
|
||||||
|
var transition = (this.active ? 'to-has-' : 'from-has-') + this.className;
|
||||||
|
$html.addClass(transition);
|
||||||
|
setTimeout(() => $html.removeClass(transition), 500);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
onPointerUp(event:JQueryMouseEventObject) {
|
||||||
|
if (hasPointerMoved) return;
|
||||||
|
this.setActive(true);
|
||||||
|
event.preventDefault();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
onDocumentPointerDown(e:JQueryMouseEventObject) {
|
||||||
|
if (this.active) {
|
||||||
|
var $path = $(e.target).parents().addBack();
|
||||||
|
if ($path.hasClass('col-menu')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($path.hasClass('tsd-filter-group')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
this.setActive(false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
onDocumentPointerUp(e:JQueryMouseEventObject) {
|
||||||
|
if (hasPointerMoved) return;
|
||||||
|
if (this.active) {
|
||||||
|
var $path = $(e.target).parents().addBack();
|
||||||
|
if ($path.hasClass('col-menu')) {
|
||||||
|
var $link = $path.filter('a');
|
||||||
|
if ($link.length) {
|
||||||
|
var href = window.location.href;
|
||||||
|
if (href.indexOf('#') != -1) {
|
||||||
|
href = href.substr(0, href.indexOf('#'));
|
||||||
|
}
|
||||||
|
if ($link.prop('href').substr(0, href.length) == href) {
|
||||||
|
setTimeout(() => this.setActive(false), 250);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register this component.
|
||||||
|
*/
|
||||||
|
registerComponent(Toggle, 'a[data-toggle]');
|
||||||
|
}
|
|
@ -0,0 +1,70 @@
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* A global service that monitors the window size and scroll position.
|
||||||
|
*/
|
||||||
|
export class Viewport extends Events
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* The current scroll position.
|
||||||
|
*/
|
||||||
|
scrollTop:number = 0;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The width of the window.
|
||||||
|
*/
|
||||||
|
width:number = 0;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The height of the window.
|
||||||
|
*/
|
||||||
|
height:number = 0;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create new Viewport instance.
|
||||||
|
*/
|
||||||
|
constructor() {
|
||||||
|
super();
|
||||||
|
$window.on('scroll', <any>_(() => this.onScroll()).throttle(10));
|
||||||
|
$window.on('resize', <any>_(() => this.onResize()).throttle(10));
|
||||||
|
|
||||||
|
this.onResize();
|
||||||
|
this.onScroll();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Trigger a resize event.
|
||||||
|
*/
|
||||||
|
triggerResize() {
|
||||||
|
this.trigger('resize', this.width, this.height);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Triggered when the size of the window has changed.
|
||||||
|
*/
|
||||||
|
onResize() {
|
||||||
|
this.width = $window.width();
|
||||||
|
this.height = $window.height();
|
||||||
|
this.trigger('resize', this.width, this.height);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Triggered when the user scrolled the viewport.
|
||||||
|
*/
|
||||||
|
onScroll() {
|
||||||
|
this.scrollTop = $window.scrollTop();
|
||||||
|
this.trigger('scroll', this.scrollTop);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register service.
|
||||||
|
*/
|
||||||
|
export var viewport:Viewport;
|
||||||
|
registerService(Viewport, 'viewport');
|
||||||
|
}
|
|
@ -0,0 +1,88 @@
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Simple point interface.
|
||||||
|
*/
|
||||||
|
export interface Point {
|
||||||
|
x:number;
|
||||||
|
y:number;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Event name of the pointer down event.
|
||||||
|
*/
|
||||||
|
export var pointerDown:string = 'mousedown';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Event name of the pointer move event.
|
||||||
|
*/
|
||||||
|
export var pointerMove:string = 'mousemove';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Event name of the pointer up event.
|
||||||
|
*/
|
||||||
|
export var pointerUp:string = 'mouseup';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Position the pointer was pressed at.
|
||||||
|
*/
|
||||||
|
export var pointerDownPosition:Point = {x:0, y:0};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Should the next click on the document be supressed?
|
||||||
|
*/
|
||||||
|
export var preventNextClick:boolean = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is the pointer down?
|
||||||
|
*/
|
||||||
|
export var isPointerDown:boolean = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is the pointer a touch point?
|
||||||
|
*/
|
||||||
|
export var isPointerTouch:boolean = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Did the pointer move since the last down event?
|
||||||
|
*/
|
||||||
|
export var hasPointerMoved:boolean = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is the user agent a mobile agent?
|
||||||
|
*/
|
||||||
|
export var isMobile:boolean = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
|
||||||
|
$html.addClass(isMobile ? 'is-mobile' : 'not-mobile');
|
||||||
|
|
||||||
|
|
||||||
|
if (isMobile && 'ontouchstart' in document.documentElement) {
|
||||||
|
isPointerTouch = true;
|
||||||
|
pointerDown = 'touchstart';
|
||||||
|
pointerMove = 'touchmove';
|
||||||
|
pointerUp = 'touchend';
|
||||||
|
}
|
||||||
|
|
||||||
|
$document.on(pointerDown, (e:JQueryMouseEventObject) => {
|
||||||
|
isPointerDown = true;
|
||||||
|
hasPointerMoved = false;
|
||||||
|
var t = (pointerDown == 'touchstart' ? e.originalEvent['targetTouches'][0] : e);
|
||||||
|
pointerDownPosition.x = t.pageX;
|
||||||
|
pointerDownPosition.y = t.pageY;
|
||||||
|
}).on(pointerMove, (e:JQueryMouseEventObject) => {
|
||||||
|
if (!isPointerDown) return;
|
||||||
|
if (!hasPointerMoved) {
|
||||||
|
var t = (pointerDown == 'touchstart' ? e.originalEvent['targetTouches'][0] : e);
|
||||||
|
var x = pointerDownPosition.x - t.pageX;
|
||||||
|
var y = pointerDownPosition.y - t.pageY;
|
||||||
|
hasPointerMoved = (Math.sqrt(x*x + y*y) > 10);
|
||||||
|
}
|
||||||
|
}).on(pointerUp, (e:JQueryMouseEventObject) => {
|
||||||
|
isPointerDown = false;
|
||||||
|
}).on('click', (e:JQueryMouseEventObject) => {
|
||||||
|
if (preventNextClick) {
|
||||||
|
e.preventDefault();
|
||||||
|
e.stopImmediatePropagation();
|
||||||
|
preventNextClick = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
|
@ -0,0 +1,53 @@
|
||||||
|
module typedoc {
|
||||||
|
function getVendorInfo(tuples) {
|
||||||
|
for (var name in tuples) {
|
||||||
|
if (!tuples.hasOwnProperty(name))
|
||||||
|
continue;
|
||||||
|
if (typeof (document.body.style[name]) !== 'undefined') {
|
||||||
|
return { name: name, endEvent: tuples[name] };
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
export var transition = getVendorInfo({
|
||||||
|
'transition': 'transitionend',
|
||||||
|
'OTransition': 'oTransitionEnd',
|
||||||
|
'msTransition': 'msTransitionEnd',
|
||||||
|
'MozTransition': 'transitionend',
|
||||||
|
'WebkitTransition': 'webkitTransitionEnd'
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
export function noTransition($el, callback) {
|
||||||
|
$el.addClass('no-transition');
|
||||||
|
callback();
|
||||||
|
$el.offset();
|
||||||
|
$el.removeClass('no-transition');
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
export function animateHeight($el:JQuery, callback:Function, success?:Function) {
|
||||||
|
var from = $el.height(), to;
|
||||||
|
noTransition($el, function () {
|
||||||
|
callback();
|
||||||
|
|
||||||
|
$el.css('height', '');
|
||||||
|
to = $el.height();
|
||||||
|
if (from != to && transition) $el.css('height', from);
|
||||||
|
});
|
||||||
|
|
||||||
|
if (from != to && transition) {
|
||||||
|
$el.css('height', to);
|
||||||
|
$el.on(transition.endEvent, function () {
|
||||||
|
noTransition($el, function () {
|
||||||
|
$el.off(transition.endEvent).css('height', '');
|
||||||
|
if (success) success();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
if (success) success();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,6 @@
|
||||||
|
/// <reference path="./typedoc/Application.ts" />
|
||||||
|
|
||||||
|
module typedoc
|
||||||
|
{
|
||||||
|
export var app:Application = new Application();
|
||||||
|
}
|
|
@ -0,0 +1,139 @@
|
||||||
|
module.exports = function(grunt)
|
||||||
|
{
|
||||||
|
grunt.file.setBase('../../../');
|
||||||
|
grunt.initConfig({
|
||||||
|
pkg: grunt.file.readJSON('package.json'),
|
||||||
|
ts: {
|
||||||
|
themeCustom: {
|
||||||
|
options: {
|
||||||
|
sourceMap: false,
|
||||||
|
module: 'amd',
|
||||||
|
basePath: 'themes',
|
||||||
|
declaration: false
|
||||||
|
},
|
||||||
|
src: [
|
||||||
|
'config/typedoc/custom-theme/assets/js/src/lib/**/*.ts',
|
||||||
|
'config/typedoc/custom-theme/assets/js/src/typedoc/Application.ts',
|
||||||
|
'config/typedoc/custom-theme/assets/js/src/typedoc/components/**/*.ts',
|
||||||
|
'config/typedoc/custom-theme/assets/js/src/typedoc/services/**/*.ts',
|
||||||
|
'config/typedoc/custom-theme/assets/js/src/typedoc/utils/**/*.ts',
|
||||||
|
'config/typedoc/custom-theme/assets/js/src/~bootstrap.ts'
|
||||||
|
],
|
||||||
|
out: 'config/typedoc/custom-theme/assets/js/main.js'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
uglify: {
|
||||||
|
themeCustom: {
|
||||||
|
options: {
|
||||||
|
mangle: false
|
||||||
|
},
|
||||||
|
files: {
|
||||||
|
'config/typedoc/custom-theme/bin/default/assets/js/main.js': [
|
||||||
|
'config/typedoc/custom-theme/assets/js/lib/jquery-2.1.1.min.js',
|
||||||
|
'config/typedoc/custom-theme/assets/js/lib/underscore-1.6.0.min.js',
|
||||||
|
'config/typedoc/custom-theme/assets/js/lib/backbone-1.1.2.min.js',
|
||||||
|
'config/typedoc/custom-theme/assets/js/lib/lunr.min.js',
|
||||||
|
'config/typedoc/custom-theme/assets/js/main.js'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
'string-replace': {
|
||||||
|
themeMinimal: {
|
||||||
|
files: {
|
||||||
|
'config/typedoc/custom-theme/bin/minimal/layouts/default.hbs': ['src/minimal/layouts/default.hbs']
|
||||||
|
},
|
||||||
|
options: {
|
||||||
|
replacements: [{
|
||||||
|
pattern: /{{ CSS }}/g,
|
||||||
|
replacement: function() {
|
||||||
|
var css = grunt.file.read('bin/default/assets/css/main.css');
|
||||||
|
return css.replace(/url\(([^\)]*)\)/g, function(match, file) {
|
||||||
|
if (match.indexOf(':') != -1) return match;
|
||||||
|
var path = require('path'), fs = require('fs');
|
||||||
|
var file = path.resolve('bin/default/assets/css', file);
|
||||||
|
var data = fs.readFileSync(file, 'base64');
|
||||||
|
return 'url(data:image/png;base64,' + data + ')';
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
pattern: /{{ JS }}/g,
|
||||||
|
replacement: function() {
|
||||||
|
return grunt.file.read('bin/default/assets/js/main.js').replace('{{', '{/**/{');
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
sass: {
|
||||||
|
options: {
|
||||||
|
style: 'compact',
|
||||||
|
unixNewlines: true
|
||||||
|
},
|
||||||
|
themeCustom: {
|
||||||
|
files: [{
|
||||||
|
expand: true,
|
||||||
|
cwd: 'config/typedoc/custom-theme/assets/css',
|
||||||
|
src: 'config/typedoc/custom-theme/**/*.sass',
|
||||||
|
dest: 'config/typedoc/custom-theme/bin/assets/css',
|
||||||
|
ext: '.css'
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
autoprefixer: {
|
||||||
|
options: {
|
||||||
|
cascade: false
|
||||||
|
},
|
||||||
|
themeCustom: {
|
||||||
|
expand: true,
|
||||||
|
src: 'config/typedoc/custom-theme/bin/**/*.css',
|
||||||
|
dest: './'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
copy: {
|
||||||
|
plugin: {
|
||||||
|
files: [{
|
||||||
|
expand: true,
|
||||||
|
cwd: 'src',
|
||||||
|
src: ['*.js'],
|
||||||
|
dest: 'config/typedoc/custom-theme/bin'
|
||||||
|
}]
|
||||||
|
},
|
||||||
|
themeCustom: {
|
||||||
|
files: [{
|
||||||
|
expand: true,
|
||||||
|
cwd: 'config/typedoc/custom-theme',
|
||||||
|
src: ['**/*.hbs', '**/*.png'],
|
||||||
|
dest: 'config/typedoc/custom-theme/bin'
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
js: {
|
||||||
|
files: ['config/typedoc/custom-theme/assets/js/src/**/*.ts'],
|
||||||
|
tasks: ['js']
|
||||||
|
},
|
||||||
|
css: {
|
||||||
|
files: ['config/typedoc/custom-theme/assets/css/**/*'],
|
||||||
|
tasks: ['css']
|
||||||
|
},
|
||||||
|
custom: {
|
||||||
|
files: ['config/typedoc/custom-theme/**/*.hbs'],
|
||||||
|
tasks: ['copy', 'string-replace']
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
grunt.loadNpmTasks('grunt-contrib-watch');
|
||||||
|
grunt.loadNpmTasks('grunt-contrib-sass');
|
||||||
|
grunt.loadNpmTasks('grunt-contrib-uglify');
|
||||||
|
grunt.loadNpmTasks('grunt-contrib-copy');
|
||||||
|
grunt.loadNpmTasks('grunt-string-replace');
|
||||||
|
grunt.loadNpmTasks('grunt-autoprefixer');
|
||||||
|
grunt.loadNpmTasks('grunt-ts');
|
||||||
|
|
||||||
|
grunt.registerTask('css', ['sass', 'autoprefixer']);
|
||||||
|
grunt.registerTask('js', ['ts:themeCustom', 'uglify']);
|
||||||
|
grunt.registerTask('default', ['copy', 'css', 'js', 'string-replace']);
|
||||||
|
};
|
|
@ -0,0 +1,51 @@
|
||||||
|
<!doctype html>
|
||||||
|
<html class="default no-js">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||||
|
<title>{{#ifCond model.name '==' project.name}}{{project.name}}{{else}}{{model.name}} | {{project.name}}{{/ifCond}}</title>
|
||||||
|
<meta name="description" content="">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="{{relativeURL "assets/css/main.css"}}">
|
||||||
|
<link rel="shortcut icon" href="/img/favicon.ico" type="image/x-icon">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
{{> header}}
|
||||||
|
|
||||||
|
<div class="container container-main">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-8 col-content">
|
||||||
|
{{{contents}}}
|
||||||
|
</div>
|
||||||
|
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
|
||||||
|
<nav class="tsd-navigation primary">
|
||||||
|
<ul>
|
||||||
|
{{#each navigation.children}}
|
||||||
|
{{> navigation}}
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
<nav class="tsd-navigation secondary menu-sticky">
|
||||||
|
<ul class="before-current">
|
||||||
|
{{#each toc.children}}
|
||||||
|
{{> toc.root}}
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
</nav>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{> footer}}
|
||||||
|
|
||||||
|
<div class="overlay"></div>
|
||||||
|
<script src="{{relativeURL "assets/js/main.js"}}"></script>
|
||||||
|
<script>if (location.protocol == 'file:') document.write('<script src="{{relativeURL "assets/js/search.js"}}"><' + '/script>');</script>
|
||||||
|
|
||||||
|
{{> analytics}}
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
|
@ -0,0 +1,11 @@
|
||||||
|
{{#if settings.gaID}}
|
||||||
|
<script>
|
||||||
|
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||||
|
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||||
|
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||||
|
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||||
|
|
||||||
|
ga('create', '{{settings.gaID}}', '{{settings.gaSite}}');
|
||||||
|
ga('send', 'pageview');
|
||||||
|
</script>
|
||||||
|
{{/if}}
|
|
@ -0,0 +1,16 @@
|
||||||
|
{{#if parent}}
|
||||||
|
{{#with parent}}{{> breadcrumb}}{{/with}}
|
||||||
|
<li>
|
||||||
|
{{#if url}}
|
||||||
|
<a href="{{relativeURL url}}">{{name}}</a>
|
||||||
|
{{else}}
|
||||||
|
<span>{{name}}</span>
|
||||||
|
{{/if}}
|
||||||
|
</li>
|
||||||
|
{{else}}
|
||||||
|
{{#if url}}
|
||||||
|
<li>
|
||||||
|
<a href="{{relativeURL url}}">Globals</a>
|
||||||
|
</li>
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
|
@ -0,0 +1,22 @@
|
||||||
|
{{#with comment}}
|
||||||
|
{{#if hasVisibleComponent}}
|
||||||
|
<div class="tsd-comment tsd-typography">
|
||||||
|
{{#if shortText}}
|
||||||
|
<div class="lead">
|
||||||
|
{{#markdown}}{{{shortText}}}{{/markdown}}
|
||||||
|
</div>
|
||||||
|
{{/if}}
|
||||||
|
{{#if text}}
|
||||||
|
{{#markdown}}{{{text}}}{{/markdown}}
|
||||||
|
{{/if}}
|
||||||
|
{{#if tags}}
|
||||||
|
<dl class="tsd-comment-tags">
|
||||||
|
{{#each tags}}
|
||||||
|
<dt>{{tagName}}</dt>
|
||||||
|
<dd>{{#markdown}}{{{text}}}{{/markdown}}</dd>
|
||||||
|
{{/each}}
|
||||||
|
</dl>
|
||||||
|
{{/if}}
|
||||||
|
</div>
|
||||||
|
{{/if}}
|
||||||
|
{{/with}}
|
|
@ -0,0 +1,68 @@
|
||||||
|
|
||||||
|
<footer{{#unless settings.hideGenerator}} class="with-border-bottom"{{/unless}}>
|
||||||
|
<div class="container">
|
||||||
|
<h2>Legend</h2>
|
||||||
|
<div class="tsd-legend-group">
|
||||||
|
<ul class="tsd-legend">
|
||||||
|
<li class="tsd-kind-module"><span class="tsd-kind-icon">Module</span></li>
|
||||||
|
<li class="tsd-kind-object-literal"><span class="tsd-kind-icon">Object literal</span></li>
|
||||||
|
<li class="tsd-kind-variable"><span class="tsd-kind-icon">Variable</span></li>
|
||||||
|
<li class="tsd-kind-function"><span class="tsd-kind-icon">Function</span></li>
|
||||||
|
<li class="tsd-kind-function tsd-has-type-parameter"><span class="tsd-kind-icon">Function with type parameter</span></li>
|
||||||
|
<li class="tsd-kind-index-signature"><span class="tsd-kind-icon">Index signature</span></li>
|
||||||
|
<li class="tsd-kind-type-alias"><span class="tsd-kind-icon">Type alias</span></li>
|
||||||
|
<li class="tsd-kind-type-alias tsd-has-type-parameter"><span class="tsd-kind-icon">Type alias with type parameter</span></li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
<ul class="tsd-legend">
|
||||||
|
<li class="tsd-kind-enum"><span class="tsd-kind-icon">Enumeration</span></li>
|
||||||
|
<li class="tsd-kind-enum-member"><span class="tsd-kind-icon">Enumeration member</span></li>
|
||||||
|
<li class="tsd-kind-property tsd-parent-kind-enum"><span class="tsd-kind-icon">Property</span></li>
|
||||||
|
<li class="tsd-kind-method tsd-parent-kind-enum"><span class="tsd-kind-icon">Method</span></li>
|
||||||
|
</ul>
|
||||||
|
<ul class="tsd-legend">
|
||||||
|
<li class="tsd-kind-interface"><span class="tsd-kind-icon">Interface</span></li>
|
||||||
|
<li class="tsd-kind-interface tsd-has-type-parameter"><span class="tsd-kind-icon">Interface with type parameter</span></li>
|
||||||
|
<li class="tsd-kind-constructor tsd-parent-kind-interface"><span class="tsd-kind-icon">Constructor</span></li>
|
||||||
|
<li class="tsd-kind-property tsd-parent-kind-interface"><span class="tsd-kind-icon">Property</span></li>
|
||||||
|
<li class="tsd-kind-method tsd-parent-kind-interface"><span class="tsd-kind-icon">Method</span></li>
|
||||||
|
<li class="tsd-kind-index-signature tsd-parent-kind-interface"><span class="tsd-kind-icon">Index signature</span></li>
|
||||||
|
</ul>
|
||||||
|
<ul class="tsd-legend">
|
||||||
|
<li class="tsd-kind-class"><span class="tsd-kind-icon">Class</span></li>
|
||||||
|
<li class="tsd-kind-class tsd-has-type-parameter"><span class="tsd-kind-icon">Class with type parameter</span></li>
|
||||||
|
<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
|
||||||
|
<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
|
||||||
|
<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
|
||||||
|
<li class="tsd-kind-accessor tsd-parent-kind-class"><span class="tsd-kind-icon">Accessor</span></li>
|
||||||
|
<li class="tsd-kind-index-signature tsd-parent-kind-class"><span class="tsd-kind-icon">Index signature</span></li>
|
||||||
|
</ul>
|
||||||
|
<ul class="tsd-legend">
|
||||||
|
<li class="tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited constructor</span></li>
|
||||||
|
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited property</span></li>
|
||||||
|
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li>
|
||||||
|
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited accessor</span></li>
|
||||||
|
</ul>
|
||||||
|
<ul class="tsd-legend">
|
||||||
|
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li>
|
||||||
|
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected method</span></li>
|
||||||
|
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected accessor</span></li>
|
||||||
|
</ul>
|
||||||
|
<ul class="tsd-legend">
|
||||||
|
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li>
|
||||||
|
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private method</span></li>
|
||||||
|
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private accessor</span></li>
|
||||||
|
</ul>
|
||||||
|
<ul class="tsd-legend">
|
||||||
|
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static property</span></li>
|
||||||
|
<li class="tsd-kind-call-signature tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static method</span></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</footer>
|
||||||
|
|
||||||
|
{{#unless settings.hideGenerator}}
|
||||||
|
<div class="container tsd-generator">
|
||||||
|
<p>Generated using <a href="http://typedoc.org/" target="_blank">TypeDoc</a></p>
|
||||||
|
</div>
|
||||||
|
{{/unless}}
|
|
@ -0,0 +1,73 @@
|
||||||
|
<header>
|
||||||
|
<div class="tsd-page-toolbar">
|
||||||
|
<div class="container">
|
||||||
|
<div class="table-wrap">
|
||||||
|
<div class="table-cell" id="tsd-search" data-index="{{relativeURL "assets/js/search.js"}}" data-base="{{relativeURL "./"}}">
|
||||||
|
<div class="field">
|
||||||
|
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
|
||||||
|
<input id="tsd-search-field" type="text" />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<ul class="results">
|
||||||
|
<li class="state loading">Preparing search index...</li>
|
||||||
|
<li class="state failure">The search index is not available</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<a style="position: absolute" href="/docs/reference-docs/openvidu-browser/" class="title">
|
||||||
|
<img class="logo-small" style="height: 26px; margin-top: 7px" src="/img/logos/openvidu_vert_grey_bg_transp_cropped.png">
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="table-cell" id="tsd-widgets">
|
||||||
|
<div id="tsd-filter">
|
||||||
|
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
|
||||||
|
<div class="tsd-filter-group">
|
||||||
|
<div class="tsd-select" id="tsd-filter-visibility">
|
||||||
|
<span class="tsd-select-label">All</span>
|
||||||
|
<ul class="tsd-select-list">
|
||||||
|
<li data-value="public">Public</li>
|
||||||
|
<li data-value="protected">Public/Protected</li>
|
||||||
|
<li data-value="private" class="selected">All</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<input type="checkbox" id="tsd-filter-inherited" checked />
|
||||||
|
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
|
||||||
|
|
||||||
|
{{#unless settings.excludeExternals}}
|
||||||
|
<input type="checkbox" id="tsd-filter-externals" checked />
|
||||||
|
<label class="tsd-widget" for="tsd-filter-externals">Externals</label>
|
||||||
|
{{/unless}}
|
||||||
|
|
||||||
|
{{#unless settings.excludeNotExported}}
|
||||||
|
<input type="checkbox" id="tsd-filter-only-exported" />
|
||||||
|
<label class="tsd-widget" for="tsd-filter-only-exported">Only exported</label>
|
||||||
|
{{/unless}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="tsd-page-title">
|
||||||
|
<div class="container">
|
||||||
|
<ul class="tsd-breadcrumb">
|
||||||
|
{{#with model}}{{> breadcrumb}}{{/with}}
|
||||||
|
</ul>
|
||||||
|
<h1>{{#compact}}
|
||||||
|
{{model.kindString}}
|
||||||
|
{{model.name}}
|
||||||
|
{{#if model.typeParameters}}
|
||||||
|
<
|
||||||
|
{{#each model.typeParameters}}
|
||||||
|
{{#if @index}}, {{/if}}
|
||||||
|
{{name}}
|
||||||
|
{{/each}}
|
||||||
|
>
|
||||||
|
{{/if}}
|
||||||
|
{{/compact}}</h1>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</header>
|
|
@ -0,0 +1,17 @@
|
||||||
|
<ul class="tsd-hierarchy">
|
||||||
|
{{#each types}}
|
||||||
|
<li>
|
||||||
|
{{#if ../isTarget}}
|
||||||
|
<span class="target">{{this}}</span>
|
||||||
|
{{else}}
|
||||||
|
{{> type}}
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if @last}}
|
||||||
|
{{#with ../next}}
|
||||||
|
{{> hierarchy}}
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
|
@ -0,0 +1,19 @@
|
||||||
|
{{#if groups}}
|
||||||
|
<section class="tsd-panel-group tsd-index-group">
|
||||||
|
<h2>Index</h2>
|
||||||
|
<section class="tsd-panel tsd-index-panel">
|
||||||
|
<div class="tsd-index-content">
|
||||||
|
{{#each groups}}
|
||||||
|
<section class="tsd-index-section {{cssClasses}}">
|
||||||
|
<h3>{{title}}</h3>
|
||||||
|
<ul class="tsd-index-list">
|
||||||
|
{{#each children}}
|
||||||
|
<li class="{{cssClasses}}"><a href="{{relativeURL url}}" class="tsd-kind-icon">{{#if name}}{{{wbr name}}}{{else}}<em>{{{wbr kindString}}}</em>{{/if}}</a></li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
</section>
|
||||||
|
{{/each}}
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
</section>
|
||||||
|
{{/if}}
|
|
@ -0,0 +1,36 @@
|
||||||
|
<div class="tsd-signature tsd-kind-icon">{{#compact}}
|
||||||
|
{{{wbr name}}}
|
||||||
|
{{#if typeParameters}}
|
||||||
|
<
|
||||||
|
{{#each typeParameters}}
|
||||||
|
{{#if @index}}, {{/if}}
|
||||||
|
{{name}}
|
||||||
|
{{/each}}
|
||||||
|
>
|
||||||
|
{{/if}}
|
||||||
|
<span class="tsd-signature-symbol">{{#if isOptional}}?{{/if}}:</span> {{#with type}}{{>type}}{{/with}}
|
||||||
|
{{#if defaultValue}}
|
||||||
|
<span class="tsd-signature-symbol">
|
||||||
|
=
|
||||||
|
{{defaultValue}}
|
||||||
|
</span>
|
||||||
|
{{/if}}
|
||||||
|
{{/compact}}</div>
|
||||||
|
|
||||||
|
{{> member.sources}}
|
||||||
|
|
||||||
|
{{> comment}}
|
||||||
|
|
||||||
|
{{#if typeParameters}}
|
||||||
|
<h4 class="tsd-type-parameters-title">Type parameters</h4>
|
||||||
|
{{> typeParameters}}
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if type.declaration}}
|
||||||
|
<div class="tsd-type-declaration">
|
||||||
|
<h4>Type declaration</h4>
|
||||||
|
{{#with type.declaration}}
|
||||||
|
{{> parameter}}
|
||||||
|
{{/with}}
|
||||||
|
</div>
|
||||||
|
{{/if}}
|
|
@ -0,0 +1,37 @@
|
||||||
|
<ul class="tsd-signatures {{cssClasses}}">
|
||||||
|
{{#if getSignature}}
|
||||||
|
{{#with getSignature}}
|
||||||
|
<li class="tsd-signature tsd-kind-icon">{{#compact}}
|
||||||
|
<span class="tsd-signature-symbol">get</span>
|
||||||
|
{{../name}}
|
||||||
|
{{> member.signature.title hideName=true }}
|
||||||
|
{{/compact}}</li>
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
{{#if setSignature}}
|
||||||
|
{{#with setSignature}}
|
||||||
|
<li class="tsd-signature tsd-kind-icon">{{#compact}}
|
||||||
|
<span class="tsd-signature-symbol">set</span>
|
||||||
|
{{../name}}
|
||||||
|
{{> member.signature.title hideName=true }}
|
||||||
|
{{/compact}}</li>
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<ul class="tsd-descriptions">
|
||||||
|
{{#if getSignature}}
|
||||||
|
{{#with getSignature}}
|
||||||
|
<li class="tsd-description">
|
||||||
|
{{> member.signature.body }}
|
||||||
|
</li>
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
{{#if setSignature}}
|
||||||
|
{{#with setSignature}}
|
||||||
|
<li class="tsd-description">
|
||||||
|
{{> member.signature.body }}
|
||||||
|
</li>
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
</ul>
|
|
@ -0,0 +1,22 @@
|
||||||
|
<section class="tsd-panel tsd-member {{cssClasses}}">
|
||||||
|
<a name="{{anchor}}" class="tsd-anchor"></a>
|
||||||
|
{{#if name}}
|
||||||
|
<h3>{{#each flags}}<span class="tsd-flag ts-flag{{this}}">{{this}}</span> {{/each}}{{{wbr name}}}</h3>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if signatures}}
|
||||||
|
{{> member.signatures}}
|
||||||
|
{{else}}{{#if hasGetterOrSetter}}
|
||||||
|
{{> member.getterSetter}}
|
||||||
|
{{else}}
|
||||||
|
{{> member.declaration}}
|
||||||
|
{{/if}}{{/if}}
|
||||||
|
|
||||||
|
{{#each groups}}
|
||||||
|
{{#each children}}
|
||||||
|
{{#unless hasOwnDocument}}
|
||||||
|
{{> member}}
|
||||||
|
{{/unless}}
|
||||||
|
{{/each}}
|
||||||
|
{{/each}}
|
||||||
|
</section>
|
|
@ -0,0 +1,56 @@
|
||||||
|
{{#unless hideSources}}
|
||||||
|
{{> member.sources}}
|
||||||
|
{{/unless}}
|
||||||
|
|
||||||
|
{{> comment}}
|
||||||
|
|
||||||
|
{{#if typeParameters}}
|
||||||
|
<h4 class="tsd-type-parameters-title">Type parameters</h4>
|
||||||
|
{{> typeParameters}}
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if parameters}}
|
||||||
|
<h4 class="tsd-parameters-title">Parameters</h4>
|
||||||
|
<ul class="tsd-parameters">
|
||||||
|
{{#each parameters}}
|
||||||
|
<li>
|
||||||
|
<h5>{{#compact}}
|
||||||
|
{{#each flags}}
|
||||||
|
<span class="tsd-flag ts-flag{{this}}">{{this}}</span>
|
||||||
|
{{/each}}
|
||||||
|
{{#if flags.isRest}}<span class="tsd-signature-symbol">...</span>{{/if}}
|
||||||
|
{{name}}:
|
||||||
|
{{#with type}}{{>type}}{{/with}}
|
||||||
|
{{#if defaultValue}}
|
||||||
|
<span class="tsd-signature-symbol">
|
||||||
|
=
|
||||||
|
{{defaultValue}}
|
||||||
|
</span>
|
||||||
|
{{/if}}
|
||||||
|
{{/compact}}</h5>
|
||||||
|
|
||||||
|
{{> comment}}
|
||||||
|
|
||||||
|
{{#if type.declaration}}
|
||||||
|
{{#with type.declaration}}
|
||||||
|
{{> parameter}}
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if type}}
|
||||||
|
<h4 class="tsd-returns-title">Returns {{#with type}}{{>type}}{{/with}}</h4>
|
||||||
|
|
||||||
|
{{#if comment.returns}}
|
||||||
|
{{#markdown}}{{{comment.returns}}}{{/markdown}}
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if type.declaration}}
|
||||||
|
{{#with type.declaration}}
|
||||||
|
{{> parameter}}
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
|
@ -0,0 +1,28 @@
|
||||||
|
{{#compact}}
|
||||||
|
{{#unless hideName}}{{{wbr name}}}{{/unless}}
|
||||||
|
{{#if typeParameters}}
|
||||||
|
<
|
||||||
|
{{#each typeParameters}}
|
||||||
|
{{#if @index}}, {{/if}}
|
||||||
|
{{name}}
|
||||||
|
{{/each}}
|
||||||
|
>
|
||||||
|
{{/if}}
|
||||||
|
<span class="tsd-signature-symbol">(</span>
|
||||||
|
{{#each parameters}}
|
||||||
|
{{#if @index}}, {{/if}}
|
||||||
|
{{#if flags.isRest}}<span class="tsd-signature-symbol">...</span>{{/if}}
|
||||||
|
{{name}}
|
||||||
|
<span class="tsd-signature-symbol">
|
||||||
|
{{#if flags.isOptional}}?{{/if}}
|
||||||
|
{{#if defaultValue}}?{{/if}}
|
||||||
|
:
|
||||||
|
</span>
|
||||||
|
{{#with type}}{{>type}}{{/with}}
|
||||||
|
{{/each}}
|
||||||
|
<span class="tsd-signature-symbol">)</span>
|
||||||
|
{{#if type}}
|
||||||
|
<span class="tsd-signature-symbol">: </span>
|
||||||
|
{{#with type}}{{>type}}{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
{{/compact}}
|
|
@ -0,0 +1,13 @@
|
||||||
|
<ul class="tsd-signatures {{cssClasses}}">
|
||||||
|
{{#each signatures}}
|
||||||
|
<li class="tsd-signature tsd-kind-icon">{{> member.signature.title }}</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<ul class="tsd-descriptions">
|
||||||
|
{{#each signatures}}
|
||||||
|
<li class="tsd-description">
|
||||||
|
{{> member.signature.body }}
|
||||||
|
</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
|
@ -0,0 +1,22 @@
|
||||||
|
<aside class="tsd-sources">
|
||||||
|
{{#if implementationOf}}
|
||||||
|
<p>Implementation of {{#with implementationOf}}{{> typeAndParent}}{{/with}}</p>
|
||||||
|
{{/if}}
|
||||||
|
{{#if inheritedFrom}}
|
||||||
|
<p>Inherited from {{#with inheritedFrom}}{{> typeAndParent}}{{/with}}</p>
|
||||||
|
{{/if}}
|
||||||
|
{{#if overwrites}}
|
||||||
|
<p>Overrides {{#with overwrites}}{{> typeAndParent}}{{/with}}</p>
|
||||||
|
{{/if}}
|
||||||
|
{{#if sources}}
|
||||||
|
<ul>
|
||||||
|
{{#each sources}}
|
||||||
|
{{#if url}}
|
||||||
|
<li>Defined in <a href="{{url}}">{{fileName}}:{{line}}</a></li>
|
||||||
|
{{else}}
|
||||||
|
<li>Defined in {{fileName}}:{{line}}</li>
|
||||||
|
{{/if}}
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
{{/if}}
|
||||||
|
</aside>
|
|
@ -0,0 +1,8 @@
|
||||||
|
<section class="tsd-panel-group tsd-member-group {{cssClasses}}">
|
||||||
|
<h2>{{title}}</h2>
|
||||||
|
{{#each children}}
|
||||||
|
{{#unless hasOwnDocument}}
|
||||||
|
{{> member}}
|
||||||
|
{{/unless}}
|
||||||
|
{{/each}}
|
||||||
|
</section>
|
|
@ -0,0 +1,5 @@
|
||||||
|
{{#each groups}}
|
||||||
|
{{#unless allChildrenHaveOwnDocument}}
|
||||||
|
{{> members.group}}
|
||||||
|
{{/unless}}
|
||||||
|
{{/each}}
|
|
@ -0,0 +1,26 @@
|
||||||
|
{{#if isVisible}}
|
||||||
|
{{#if isLabel}}
|
||||||
|
<li class="label {{cssClasses}}">
|
||||||
|
<span>{{{wbr title}}}</span>
|
||||||
|
</li>
|
||||||
|
{{else}}
|
||||||
|
{{#if isGlobals}}
|
||||||
|
<li class="globals {{#if isInPath}}current{{/if}} {{cssClasses}}">
|
||||||
|
<a href="{{relativeURL url}}"><em>{{{wbr title}}}</em></a>
|
||||||
|
</li>
|
||||||
|
{{else}}
|
||||||
|
<li class="{{#if isInPath}}current{{/if}} {{cssClasses}}">
|
||||||
|
<a href="{{relativeURL url}}">{{{wbr title}}}</a>
|
||||||
|
{{#if isInPath}}
|
||||||
|
{{#if children}}
|
||||||
|
<ul>
|
||||||
|
{{#each children}}
|
||||||
|
{{> navigation}}
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
</li>
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
|
@ -0,0 +1,81 @@
|
||||||
|
<ul class="tsd-parameters">
|
||||||
|
{{#if signatures}}
|
||||||
|
<li class="tsd-parameter-siganture">
|
||||||
|
<ul class="tsd-signatures {{cssClasses}}">
|
||||||
|
{{#each signatures}}
|
||||||
|
<li class="tsd-signature tsd-kind-icon">{{> member.signature.title hideName=true }}</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<ul class="tsd-descriptions">
|
||||||
|
{{#each signatures}}
|
||||||
|
<li class="tsd-description">{{> member.signature.body hideSources=true }}</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
</li>
|
||||||
|
{{/if}}
|
||||||
|
{{#if indexSignature}}
|
||||||
|
<li class="tsd-parameter-index-signature">
|
||||||
|
<h5>{{#compact}}
|
||||||
|
<span class="tsd-signature-symbol">[</span>
|
||||||
|
{{#each indexSignature.parameters}}
|
||||||
|
{{#if flags.isRest}}<span class="tsd-signature-symbol">...</span>{{/if}}{{name}}: {{#with type}}{{>type}}{{/with}}
|
||||||
|
{{/each}}
|
||||||
|
<span class="tsd-signature-symbol">]: </span>
|
||||||
|
{{#with indexSignature.type}}{{>type}}{{/with}}
|
||||||
|
{{/compact}}</h5>
|
||||||
|
|
||||||
|
{{#with indexSignature}}
|
||||||
|
{{> comment}}
|
||||||
|
{{/with}}
|
||||||
|
|
||||||
|
{{#if indexSignature.type.declaration}}
|
||||||
|
{{#with indexSignature.type.declaration}}
|
||||||
|
{{> parameter}}
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
</li>
|
||||||
|
{{/if}}
|
||||||
|
{{#each children}}
|
||||||
|
<li class="tsd-parameter">
|
||||||
|
{{#if signatures}}
|
||||||
|
<h5>{{#compact}}
|
||||||
|
{{#if flags.isRest}}<span class="tsd-signature-symbol">...</span>{{/if}}
|
||||||
|
{{{wbr name}}}
|
||||||
|
<span class="tsd-signature-symbol">
|
||||||
|
{{#if isOptional}}?{{/if}}
|
||||||
|
:
|
||||||
|
</span>
|
||||||
|
function
|
||||||
|
{{/compact}}</h5>
|
||||||
|
|
||||||
|
{{> member.signatures}}
|
||||||
|
{{else}}
|
||||||
|
<h5>{{#compact}}
|
||||||
|
{{#each flags}}
|
||||||
|
<span class="tsd-flag ts-flag{{this}}">{{this}}</span>
|
||||||
|
{{/each}}
|
||||||
|
{{#if flags.isRest}}<span class="tsd-signature-symbol">...</span>{{/if}}
|
||||||
|
{{{wbr name}}}
|
||||||
|
<span class="tsd-signature-symbol">
|
||||||
|
{{#if flags.isOptional}}?{{/if}}
|
||||||
|
:
|
||||||
|
</span>
|
||||||
|
{{#with type}}{{>type}}{{/with}}
|
||||||
|
{{/compact}}</h5>
|
||||||
|
|
||||||
|
{{> comment}}
|
||||||
|
|
||||||
|
{{#if children}}
|
||||||
|
{{> parameter}}
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if type.declaration}}
|
||||||
|
{{#with type.declaration}}
|
||||||
|
{{> parameter}}
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
|
@ -0,0 +1,10 @@
|
||||||
|
<li class="{{#if isInPath}}current{{/if}} {{cssClasses}}">
|
||||||
|
<a href="{{relativeURL url}}" class="tsd-kind-icon">{{{wbr title}}}</a>
|
||||||
|
{{#if children}}
|
||||||
|
<ul>
|
||||||
|
{{#each children}}
|
||||||
|
{{> toc}}
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
{{/if}}
|
||||||
|
</li>
|
|
@ -0,0 +1,18 @@
|
||||||
|
{{#if isInPath}}
|
||||||
|
</ul>
|
||||||
|
<ul class="current">
|
||||||
|
{{/if}}
|
||||||
|
<li class="{{#if isInPath}}current{{/if}} {{cssClasses}}">
|
||||||
|
<a href="{{relativeURL url}}" class="tsd-kind-icon">{{{wbr title}}}</a>
|
||||||
|
{{#if children}}
|
||||||
|
<ul>
|
||||||
|
{{#each children}}
|
||||||
|
{{> toc}}
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
{{/if}}
|
||||||
|
</li>
|
||||||
|
{{#if isInPath}}
|
||||||
|
</ul>
|
||||||
|
<ul class="after-current">
|
||||||
|
{{/if}}
|
|
@ -0,0 +1,83 @@
|
||||||
|
{{#if this}}
|
||||||
|
{{#if reflection}}
|
||||||
|
{{#compact}}
|
||||||
|
<a href="{{relativeURL reflection.url}}" class="tsd-signature-type">
|
||||||
|
{{reflection.name}}
|
||||||
|
</a>
|
||||||
|
{{#if typeArguments}}
|
||||||
|
<span class="tsd-signature-symbol"><</span>
|
||||||
|
|
||||||
|
{{#each typeArguments}}
|
||||||
|
{{#if @index}}
|
||||||
|
<span class="tsd-signature-symbol">, </span>
|
||||||
|
{{/if}}{{> type}}
|
||||||
|
{{/each}}
|
||||||
|
|
||||||
|
<span class="tsd-signature-symbol">></span>
|
||||||
|
{{/if}}
|
||||||
|
{{/compact}}
|
||||||
|
{{else}}
|
||||||
|
{{#if elementType}}
|
||||||
|
{{#with elementType}}
|
||||||
|
{{#compact}}
|
||||||
|
{{#if types}}
|
||||||
|
<span class="tsd-signature-symbol">(</span>
|
||||||
|
{{/if}}
|
||||||
|
{{> type}}
|
||||||
|
{{#if types}}
|
||||||
|
<span class="tsd-signature-symbol">)</span>
|
||||||
|
{{/if}}<span class="tsd-signature-symbol">[]</span>
|
||||||
|
{{/compact}}
|
||||||
|
{{/with}}
|
||||||
|
{{else}}
|
||||||
|
{{#if types}}
|
||||||
|
{{#each types}}
|
||||||
|
{{#if @index}}
|
||||||
|
<span class="tsd-signature-symbol"> {{#ifCond ../type '==' 'intersection'}}&{{else}}|{{/ifCond}} </span>
|
||||||
|
{{/if}}{{> type}}
|
||||||
|
{{/each}}
|
||||||
|
{{else}}
|
||||||
|
{{#if elements}}
|
||||||
|
{{#compact}}
|
||||||
|
<span class="tsd-signature-symbol">[</span>
|
||||||
|
|
||||||
|
{{#each elements}}
|
||||||
|
{{#if @index}}
|
||||||
|
<span class="tsd-signature-symbol">, </span>
|
||||||
|
{{/if}}{{> type}}
|
||||||
|
{{/each}}
|
||||||
|
|
||||||
|
<span class="tsd-signature-symbol">]</span>
|
||||||
|
{{/compact}}
|
||||||
|
{{else}}
|
||||||
|
{{#compact}}
|
||||||
|
<span class="tsd-signature-type">
|
||||||
|
{{#if name}}
|
||||||
|
{{name}}
|
||||||
|
{{else}}
|
||||||
|
{{#if value}}
|
||||||
|
"{{value}}"
|
||||||
|
{{else}}
|
||||||
|
{{this}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
</span>
|
||||||
|
{{#if typeArguments}}
|
||||||
|
<span class="tsd-signature-symbol"><</span>
|
||||||
|
|
||||||
|
{{#each typeArguments}}
|
||||||
|
{{#if @index}}
|
||||||
|
<span class="tsd-signature-symbol">, </span>
|
||||||
|
{{/if}}{{> type}}
|
||||||
|
{{/each}}
|
||||||
|
|
||||||
|
<span class="tsd-signature-symbol">></span>
|
||||||
|
{{/if}}
|
||||||
|
{{/compact}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{else}}
|
||||||
|
<span class="tsd-signature-type">void</span>
|
||||||
|
{{/if}}
|
|
@ -0,0 +1,42 @@
|
||||||
|
{{#compact}}
|
||||||
|
{{#if this}}
|
||||||
|
{{#if elementType}}
|
||||||
|
{{#with elementType}}
|
||||||
|
{{> typeAndParent}}
|
||||||
|
{{/with}}
|
||||||
|
[]
|
||||||
|
{{else}}
|
||||||
|
{{#if reflection}}
|
||||||
|
{{#ifSignature reflection}}
|
||||||
|
{{#if reflection.parent.parent.url}}
|
||||||
|
<a href="{{relativeURL reflection.parent.parent.url}}">{{reflection.parent.parent.name}}</a>
|
||||||
|
{{else}}
|
||||||
|
{{reflection.parent.parent.name}}
|
||||||
|
{{/if}}
|
||||||
|
.
|
||||||
|
{{#if reflection.parent.url}}
|
||||||
|
<a href="{{relativeURL reflection.parent.url}}">{{reflection.parent.name}}</a>
|
||||||
|
{{else}}
|
||||||
|
{{reflection.parent.name}}
|
||||||
|
{{/if}}
|
||||||
|
{{else}}
|
||||||
|
{{#if reflection.parent.url}}
|
||||||
|
<a href="{{relativeURL reflection.parent.url}}">{{reflection.parent.name}}</a>
|
||||||
|
{{else}}
|
||||||
|
{{reflection.parent.name}}
|
||||||
|
{{/if}}
|
||||||
|
.
|
||||||
|
{{#if reflection.url}}
|
||||||
|
<a href="{{relativeURL reflection.url}}">{{reflection.name}}</a>
|
||||||
|
{{else}}
|
||||||
|
{{reflection.name}}
|
||||||
|
{{/if}}
|
||||||
|
{{/ifSignature}}
|
||||||
|
{{else}}
|
||||||
|
{{this}}
|
||||||
|
{{/if}}
|
||||||
|
{{/if}}
|
||||||
|
{{else}}
|
||||||
|
void
|
||||||
|
{{/if}}
|
||||||
|
{{/compact}}
|
|
@ -0,0 +1,14 @@
|
||||||
|
<ul class="tsd-type-parameters">
|
||||||
|
{{#each typeParameters}}
|
||||||
|
<li>
|
||||||
|
<h4>{{#compact}}
|
||||||
|
{{name}}
|
||||||
|
{{#if type}}
|
||||||
|
<span class="tsd-signature-symbol">: </span>
|
||||||
|
{{#with type}}{{> type}}{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
{{/compact}}</h4>
|
||||||
|
{{> comment}}
|
||||||
|
</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
|
@ -0,0 +1,3 @@
|
||||||
|
<div class="tsd-panel tsd-typography">
|
||||||
|
{{#markdown}}{{{model.readme}}}{{/markdown}}
|
||||||
|
</div>
|
|
@ -0,0 +1,79 @@
|
||||||
|
{{#with model}}
|
||||||
|
{{#if hasComment}}
|
||||||
|
<section class="tsd-panel tsd-comment">
|
||||||
|
{{> comment}}
|
||||||
|
</section>
|
||||||
|
{{/if}}
|
||||||
|
{{/with}}
|
||||||
|
|
||||||
|
{{#if model.typeParameters}}
|
||||||
|
<section class="tsd-panel tsd-type-parameters">
|
||||||
|
<h3>Type parameters</h3>
|
||||||
|
{{#with model}}{{> typeParameters}}{{/with}}
|
||||||
|
</section>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if model.typeHierarchy}}
|
||||||
|
<section class="tsd-panel tsd-hierarchy">
|
||||||
|
<h3>Hierarchy</h3>
|
||||||
|
{{#with model.typeHierarchy}}{{> hierarchy}}{{/with}}
|
||||||
|
</section>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if model.implementedTypes}}
|
||||||
|
<section class="tsd-panel">
|
||||||
|
<h3>Implements</h3>
|
||||||
|
<ul class="tsd-hierarchy">
|
||||||
|
{{#each model.implementedTypes}}
|
||||||
|
<li>{{> type}}</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
</section>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if model.implementedBy}}
|
||||||
|
<section class="tsd-panel">
|
||||||
|
<h3>Implemented by</h3>
|
||||||
|
<ul class="tsd-hierarchy">
|
||||||
|
{{#each model.implementedBy}}
|
||||||
|
<li>{{> type}}</li>
|
||||||
|
{{/each}}
|
||||||
|
</ul>
|
||||||
|
</section>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if model.signatures}}
|
||||||
|
<section class="tsd-panel">
|
||||||
|
<h3 class="tsd-before-signature">Callable</h3>
|
||||||
|
{{#with model}}{{> member.signatures}}{{/with}}
|
||||||
|
</section>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if model.indexSignature}}
|
||||||
|
<section class="tsd-panel {{model.cssClasses}}">
|
||||||
|
<h3 class="tsd-before-signature">Indexable</h3>
|
||||||
|
<div class="tsd-signature tsd-kind-icon">{{#compact}}
|
||||||
|
<span class="tsd-signature-symbol">[</span>
|
||||||
|
{{#each model.indexSignature.parameters}}
|
||||||
|
{{name}}: {{#with type}}{{>type}}{{/with}}
|
||||||
|
{{/each}}
|
||||||
|
<span class="tsd-signature-symbol">]: </span>
|
||||||
|
{{#with model.indexSignature.type}}{{>type}}{{/with}}
|
||||||
|
{{/compact}}</div>
|
||||||
|
|
||||||
|
{{#with model.indexSignature}}
|
||||||
|
{{> comment}}
|
||||||
|
{{/with}}
|
||||||
|
|
||||||
|
{{#if model.indexSignature.type.declaration}}
|
||||||
|
{{#with model.indexSignature.type.declaration}}
|
||||||
|
{{> parameter}}
|
||||||
|
{{/with}}
|
||||||
|
{{/if}}
|
||||||
|
</section>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
|
{{#with model}}
|
||||||
|
{{> index}}
|
||||||
|
{{> members}}
|
||||||
|
{{/with}}
|
|
@ -0,0 +1,22 @@
|
||||||
|
module.exports = {
|
||||||
|
lib: [
|
||||||
|
"lib.dom.d.ts",
|
||||||
|
"lib.es5.d.ts",
|
||||||
|
"lib.es2015.promise.d.ts",
|
||||||
|
"lib.scripthost.d.ts"
|
||||||
|
],
|
||||||
|
mode: "file",
|
||||||
|
module: "commonjs",
|
||||||
|
name: "OpenVidu Browser",
|
||||||
|
target: "es5",
|
||||||
|
externalPattern: "node_modules",
|
||||||
|
exclude: [
|
||||||
|
"**/OpenViduInternal/Interfaces/Private/**",
|
||||||
|
"**/OpenViduInternal/WebRtcStats/WebRtcStats.ts",
|
||||||
|
"**/OpenViduInternal/WebRtcPeer/WebRtcPeer.ts"
|
||||||
|
],
|
||||||
|
excludeExternals: true,
|
||||||
|
excludePrivate: true,
|
||||||
|
theme: "./config/typedoc/custom-theme/bin",
|
||||||
|
readme: "none"
|
||||||
|
}
|
|
@ -0,0 +1,60 @@
|
||||||
|
import { Session } from './Session';
|
||||||
|
import { Stream } from './Stream';
|
||||||
|
import { ConnectionOptions } from '../OpenViduInternal/Interfaces/Private/ConnectionOptions';
|
||||||
|
import { StreamOptionsServer } from '../OpenViduInternal/Interfaces/Private/StreamOptionsServer';
|
||||||
|
/**
|
||||||
|
* Represents each one of the user's connection to the session (the local one and other user's connections).
|
||||||
|
* Therefore each [[Session]] and [[Stream]] object has an attribute of type Connection
|
||||||
|
*/
|
||||||
|
export declare class Connection {
|
||||||
|
private session;
|
||||||
|
/**
|
||||||
|
* Unique identifier of the connection
|
||||||
|
*/
|
||||||
|
connectionId: string;
|
||||||
|
/**
|
||||||
|
* Time when this connection was created (UTC milliseconds)
|
||||||
|
*/
|
||||||
|
creationTime: number;
|
||||||
|
/**
|
||||||
|
* Data associated to this connection (and therefore to certain user). This is an important field:
|
||||||
|
* it allows you to broadcast all the information you want for each user (a username, for example)
|
||||||
|
*/
|
||||||
|
data: string;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
stream: Stream;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
options: ConnectionOptions | undefined;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
disposed: boolean;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
constructor(session: Session, opts?: ConnectionOptions);
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
sendIceCandidate(candidate: RTCIceCandidate): void;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
initRemoteStreams(options: StreamOptionsServer[]): void;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
addStream(stream: Stream): void;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
removeStream(streamId: string): void;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
dispose(): void;
|
||||||
|
}
|
|
@ -0,0 +1,123 @@
|
||||||
|
"use strict";
|
||||||
|
/*
|
||||||
|
* (C) Copyright 2017-2018 OpenVidu (https://openvidu.io/)
|
||||||
|
*
|
||||||
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
* you may not use this file except in compliance with the License.
|
||||||
|
* You may obtain a copy of the License at
|
||||||
|
*
|
||||||
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
*
|
||||||
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
* See the License for the specific language governing permissions and
|
||||||
|
* limitations under the License.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
exports.__esModule = true;
|
||||||
|
var Stream_1 = require("./Stream");
|
||||||
|
/**
|
||||||
|
* Represents each one of the user's connection to the session (the local one and other user's connections).
|
||||||
|
* Therefore each [[Session]] and [[Stream]] object has an attribute of type Connection
|
||||||
|
*/
|
||||||
|
var Connection = /** @class */ (function () {
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
function Connection(session, opts) {
|
||||||
|
this.session = session;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
this.disposed = false;
|
||||||
|
var msg = "'Connection' created ";
|
||||||
|
if (!!opts) {
|
||||||
|
msg += "(remote) with 'connectionId' [" + opts.id + ']';
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
msg += '(local)';
|
||||||
|
}
|
||||||
|
console.info(msg);
|
||||||
|
this.options = opts;
|
||||||
|
if (!!opts) {
|
||||||
|
// Connection is remote
|
||||||
|
this.connectionId = opts.id;
|
||||||
|
if (opts.metadata) {
|
||||||
|
this.data = opts.metadata;
|
||||||
|
}
|
||||||
|
if (opts.streams) {
|
||||||
|
this.initRemoteStreams(opts.streams);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
this.creationTime = new Date().getTime();
|
||||||
|
}
|
||||||
|
/* Hidden methods */
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
Connection.prototype.sendIceCandidate = function (candidate) {
|
||||||
|
console.debug((!!this.stream.outboundStreamOpts ? 'Local' : 'Remote'), 'candidate for', this.connectionId, JSON.stringify(candidate));
|
||||||
|
this.session.openvidu.sendRequest('onIceCandidate', {
|
||||||
|
endpointName: this.connectionId,
|
||||||
|
candidate: candidate.candidate,
|
||||||
|
sdpMid: candidate.sdpMid,
|
||||||
|
sdpMLineIndex: candidate.sdpMLineIndex
|
||||||
|
}, function (error, response) {
|
||||||
|
if (error) {
|
||||||
|
console.error('Error sending ICE candidate: '
|
||||||
|
+ JSON.stringify(error));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
Connection.prototype.initRemoteStreams = function (options) {
|
||||||
|
var _this = this;
|
||||||
|
// This is ready for supporting multiple streams per Connection object. Right now the loop will always run just once
|
||||||
|
// this.stream should also be replaced by a collection of streams to support multiple streams per Connection
|
||||||
|
options.forEach(function (opts) {
|
||||||
|
var streamOptions = {
|
||||||
|
id: opts.id,
|
||||||
|
connection: _this,
|
||||||
|
hasAudio: opts.hasAudio,
|
||||||
|
hasVideo: opts.hasVideo,
|
||||||
|
audioActive: opts.audioActive,
|
||||||
|
videoActive: opts.videoActive,
|
||||||
|
typeOfVideo: opts.typeOfVideo,
|
||||||
|
frameRate: opts.frameRate,
|
||||||
|
videoDimensions: !!opts.videoDimensions ? JSON.parse(opts.videoDimensions) : undefined,
|
||||||
|
filter: !!opts.filter ? opts.filter : undefined
|
||||||
|
};
|
||||||
|
var stream = new Stream_1.Stream(_this.session, streamOptions);
|
||||||
|
_this.addStream(stream);
|
||||||
|
});
|
||||||
|
console.info("Remote 'Connection' with 'connectionId' [" + this.connectionId + '] is now configured for receiving Streams with options: ', this.stream.inboundStreamOpts);
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
Connection.prototype.addStream = function (stream) {
|
||||||
|
stream.connection = this;
|
||||||
|
this.stream = stream;
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
Connection.prototype.removeStream = function (streamId) {
|
||||||
|
delete this.stream;
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
Connection.prototype.dispose = function () {
|
||||||
|
if (!!this.stream) {
|
||||||
|
delete this.stream;
|
||||||
|
}
|
||||||
|
this.disposed = true;
|
||||||
|
};
|
||||||
|
return Connection;
|
||||||
|
}());
|
||||||
|
exports.Connection = Connection;
|
||||||
|
//# sourceMappingURL=Connection.js.map
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"Connection.js","sourceRoot":"","sources":["../../src/OpenVidu/Connection.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG;;AAGH,mCAAkC;AAMlC;;;GAGG;AACH;IAiCI;;OAEG;IACH,oBAAoB,OAAgB,EAAE,IAAwB;QAA1C,YAAO,GAAP,OAAO,CAAS;QARpC;;WAEG;QACH,aAAQ,GAAG,KAAK,CAAC;QAOb,IAAI,GAAG,GAAG,uBAAuB,CAAC;QAClC,IAAI,CAAC,CAAC,IAAI,EAAE;YACR,GAAG,IAAI,gCAAgC,GAAG,IAAI,CAAC,EAAE,GAAG,GAAG,CAAC;SAC3D;aAAM;YACH,GAAG,IAAI,SAAS,CAAC;SACpB;QACD,OAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAElB,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;QAEpB,IAAI,CAAC,CAAC,IAAI,EAAE;YACR,uBAAuB;YACvB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,EAAE,CAAC;YAC5B,IAAI,IAAI,CAAC,QAAQ,EAAE;gBACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,QAAQ,CAAC;aAC7B;YACD,IAAI,IAAI,CAAC,OAAO,EAAE;gBACd,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;aACxC;SACJ;QAED,IAAI,CAAC,YAAY,GAAG,IAAI,IAAI,EAAE,CAAC,OAAO,EAAE,CAAC;IAC7C,CAAC;IAGD,oBAAoB;IAEpB;;OAEG;IACH,qCAAgB,GAAhB,UAAiB,SAA0B;QAEvC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,kBAAkB,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,eAAe,EAClF,IAAI,CAAC,YAAY,EAAE,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,CAAC;QAElD,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAC,gBAAgB,EAAE;YAChD,YAAY,EAAE,IAAI,CAAC,YAAY;YAC/B,SAAS,EAAE,SAAS,CAAC,SAAS;YAC9B,MAAM,EAAE,SAAS,CAAC,MAAM;YACxB,aAAa,EAAE,SAAS,CAAC,aAAa;SACzC,EAAE,UAAC,KAAK,EAAE,QAAQ;YACf,IAAI,KAAK,EAAE;gBACP,OAAO,CAAC,KAAK,CAAC,+BAA+B;sBACvC,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC;aAChC;QACL,CAAC,CAAC,CAAC;IACP,CAAC;IAED;;OAEG;IACH,sCAAiB,GAAjB,UAAkB,OAA8B;QAAhD,iBAuBC;QArBG,oHAAoH;QACpH,4GAA4G;QAC5G,OAAO,CAAC,OAAO,CAAC,UAAA,IAAI;YAChB,IAAM,aAAa,GAAyB;gBACxC,EAAE,EAAE,IAAI,CAAC,EAAE;gBACX,UAAU,EAAE,KAAI;gBAChB,QAAQ,EAAE,IAAI,CAAC,QAAQ;gBACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ;gBACvB,WAAW,EAAE,IAAI,CAAC,WAAW;gBAC7B,WAAW,EAAE,IAAI,CAAC,WAAW;gBAC7B,WAAW,EAAE,IAAI,CAAC,WAAW;gBAC7B,SAAS,EAAE,IAAI,CAAC,SAAS;gBACzB,eAAe,EAAE,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,SAAS;gBACtF,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS;aAClD,CAAC;YACF,IAAM,MAAM,GAAG,IAAI,eAAM,CAAC,KAAI,CAAC,OAAO,EAAE,aAAa,CAAC,CAAC;YAEvD,KAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;QAC3B,CAAC,CAAC,CAAC;QAEH,OAAO,CAAC,IAAI,CAAC,2CAA2C,GAAG,IAAI,CAAC,YAAY,GAAG,0DAA0D,EAAE,IAAI,CAAC,MAAM,CAAC,iBAAiB,CAAC,CAAC;IAC9K,CAAC;IAED;;OAEG;IACH,8BAAS,GAAT,UAAU,MAAc;QACpB,MAAM,CAAC,UAAU,GAAG,IAAI,CAAC;QACzB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACzB,CAAC;IAED;;OAEG;IACH,iCAAY,GAAZ,UAAa,QAAgB;QACzB,OAAO,IAAI,CAAC,MAAM,CAAC;IACvB,CAAC;IAED;;OAEG;IACH,4BAAO,GAAP;QACI,IAAI,CAAC,CAAC,IAAI,CAAC,MAAM,EAAE;YACf,OAAO,IAAI,CAAC,MAAM,CAAC;SACtB;QACD,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC;IACzB,CAAC;IAEL,iBAAC;AAAD,CAAC,AA3ID,IA2IC;AA3IY,gCAAU"}
|
|
@ -0,0 +1,73 @@
|
||||||
|
import { Stream } from './Stream';
|
||||||
|
import { FilterEvent } from '../OpenViduInternal/Events/FilterEvent';
|
||||||
|
import { ObjMap } from '../OpenViduInternal/Interfaces/Private/ObjMap';
|
||||||
|
/**
|
||||||
|
* **WARNING**: experimental option. This interface may change in the near future
|
||||||
|
*
|
||||||
|
* Video/audio filter applied to a Stream. See [[Stream.applyFilter]]
|
||||||
|
*/
|
||||||
|
export declare class Filter {
|
||||||
|
/**
|
||||||
|
* Type of filter applied. This is the name of the remote class identifying the filter to apply in Kurento Media Server.
|
||||||
|
* For example: `"FaceOverlayFilter"`, `"GStreamerFilter"`.
|
||||||
|
*
|
||||||
|
* You can get this property in `*.kmd.json` files defining the Kurento filters. For example, for GStreamerFilter that's
|
||||||
|
* [here](https://github.com/Kurento/kms-filters/blob/53a452fac71d61795952e3d2202156c6b00f6d65/src/server/interface/filters.GStreamerFilter.kmd.json#L4)
|
||||||
|
*/
|
||||||
|
type: string;
|
||||||
|
/**
|
||||||
|
* Parameters used to initialize the filter.
|
||||||
|
* These correspond to the constructor parameters used in the filter in Kurento Media Server (except for `mediaPipeline` parameter, which is never needed).
|
||||||
|
*
|
||||||
|
* For example: for `filter.type = "GStreamerFilter"` could be `filter.options = {"command": "videobalance saturation=0.0"}`
|
||||||
|
*
|
||||||
|
* You can get this property in `*.kmd.json` files defining the Kurento filters. For example, for GStreamerFilter that's
|
||||||
|
* [here](https://github.com/Kurento/kms-filters/blob/53a452fac71d61795952e3d2202156c6b00f6d65/src/server/interface/filters.GStreamerFilter.kmd.json#L13-L31)
|
||||||
|
*/
|
||||||
|
options: Object;
|
||||||
|
/**
|
||||||
|
* Value passed the last time [[Filter.execMethod]] was called. If `undefined` this method has not been called yet.
|
||||||
|
*
|
||||||
|
* You can use this value to know the current status of any applied filter
|
||||||
|
*/
|
||||||
|
lastExecMethod?: {
|
||||||
|
method: string;
|
||||||
|
params: Object;
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
handlers: ObjMap<(event: FilterEvent) => void>;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
stream: Stream;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
constructor(type: string, options: Object);
|
||||||
|
/**
|
||||||
|
* Executes a filter method. Available methods are specific for each filter
|
||||||
|
*
|
||||||
|
* @param method Name of the method
|
||||||
|
* @param params Parameters of the method
|
||||||
|
*/
|
||||||
|
execMethod(method: string, params: Object): Promise<any>;
|
||||||
|
/**
|
||||||
|
* Subscribe to certain filter event. Available events are specific for each filter
|
||||||
|
*
|
||||||
|
* @param eventType Event to which subscribe to.
|
||||||
|
* @param handler Function to execute upon event dispatched. It receives as parameter a [[FilterEvent]] object
|
||||||
|
*
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the event listener was successfully attached to the filter and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
addEventListener(eventType: string, handler: (event: FilterEvent) => void): Promise<any>;
|
||||||
|
/**
|
||||||
|
* Removes certain filter event listener previously set.
|
||||||
|
*
|
||||||
|
* @param eventType Event to unsubscribe from.
|
||||||
|
*
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the event listener was successfully removed from the filter and rejected with an Error object in other case
|
||||||
|
*/
|
||||||
|
removeEventListener(eventType: string): Promise<any>;
|
||||||
|
}
|
|
@ -0,0 +1,145 @@
|
||||||
|
"use strict";
|
||||||
|
/*
|
||||||
|
* (C) Copyright 2017-2018 OpenVidu (https://openvidu.io/)
|
||||||
|
*
|
||||||
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
* you may not use this file except in compliance with the License.
|
||||||
|
* You may obtain a copy of the License at
|
||||||
|
*
|
||||||
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
*
|
||||||
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
* See the License for the specific language governing permissions and
|
||||||
|
* limitations under the License.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
exports.__esModule = true;
|
||||||
|
var StreamPropertyChangedEvent_1 = require("../OpenViduInternal/Events/StreamPropertyChangedEvent");
|
||||||
|
var OpenViduError_1 = require("../OpenViduInternal/Enums/OpenViduError");
|
||||||
|
/**
|
||||||
|
* **WARNING**: experimental option. This interface may change in the near future
|
||||||
|
*
|
||||||
|
* Video/audio filter applied to a Stream. See [[Stream.applyFilter]]
|
||||||
|
*/
|
||||||
|
var Filter = /** @class */ (function () {
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
function Filter(type, options) {
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
this.handlers = {};
|
||||||
|
this.type = type;
|
||||||
|
this.options = options;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Executes a filter method. Available methods are specific for each filter
|
||||||
|
*
|
||||||
|
* @param method Name of the method
|
||||||
|
* @param params Parameters of the method
|
||||||
|
*/
|
||||||
|
Filter.prototype.execMethod = function (method, params) {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
console.info('Executing filter method to stream ' + _this.stream.streamId);
|
||||||
|
var stringParams;
|
||||||
|
if (typeof params !== 'string') {
|
||||||
|
try {
|
||||||
|
stringParams = JSON.stringify(params);
|
||||||
|
}
|
||||||
|
catch (error) {
|
||||||
|
var errorMsg = "'params' property must be a JSON formatted object";
|
||||||
|
console.error(errorMsg);
|
||||||
|
reject(errorMsg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
stringParams = params;
|
||||||
|
}
|
||||||
|
_this.stream.session.openvidu.sendRequest('execFilterMethod', { streamId: _this.stream.streamId, method: method, params: stringParams }, function (error, response) {
|
||||||
|
if (error) {
|
||||||
|
console.error('Error executing filter method for Stream ' + _this.stream.streamId, error);
|
||||||
|
if (error.code === 401) {
|
||||||
|
reject(new OpenViduError_1.OpenViduError(OpenViduError_1.OpenViduErrorName.OPENVIDU_PERMISSION_DENIED, "You don't have permissions to execute a filter method"));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
reject(error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
console.info('Filter method successfully executed on Stream ' + _this.stream.streamId);
|
||||||
|
var oldValue = Object.assign({}, _this.stream.filter);
|
||||||
|
_this.stream.filter.lastExecMethod = { method: method, params: JSON.parse(stringParams) };
|
||||||
|
_this.stream.session.emitEvent('streamPropertyChanged', [new StreamPropertyChangedEvent_1.StreamPropertyChangedEvent(_this.stream.session, _this.stream, 'filter', _this.stream.filter, oldValue, 'execFilterMethod')]);
|
||||||
|
_this.stream.streamManager.emitEvent('streamPropertyChanged', [new StreamPropertyChangedEvent_1.StreamPropertyChangedEvent(_this.stream.streamManager, _this.stream, 'filter', _this.stream.filter, oldValue, 'execFilterMethod')]);
|
||||||
|
resolve();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Subscribe to certain filter event. Available events are specific for each filter
|
||||||
|
*
|
||||||
|
* @param eventType Event to which subscribe to.
|
||||||
|
* @param handler Function to execute upon event dispatched. It receives as parameter a [[FilterEvent]] object
|
||||||
|
*
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the event listener was successfully attached to the filter and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
Filter.prototype.addEventListener = function (eventType, handler) {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
console.info('Adding filter event listener to event ' + eventType + ' to stream ' + _this.stream.streamId);
|
||||||
|
_this.stream.session.openvidu.sendRequest('addFilterEventListener', { streamId: _this.stream.streamId, eventType: eventType }, function (error, response) {
|
||||||
|
if (error) {
|
||||||
|
console.error('Error adding filter event listener to event ' + eventType + 'for Stream ' + _this.stream.streamId, error);
|
||||||
|
if (error.code === 401) {
|
||||||
|
reject(new OpenViduError_1.OpenViduError(OpenViduError_1.OpenViduErrorName.OPENVIDU_PERMISSION_DENIED, "You don't have permissions to add a filter event listener"));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
reject(error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
_this.handlers[eventType] = handler;
|
||||||
|
console.info('Filter event listener to event ' + eventType + ' successfully applied on Stream ' + _this.stream.streamId);
|
||||||
|
resolve();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Removes certain filter event listener previously set.
|
||||||
|
*
|
||||||
|
* @param eventType Event to unsubscribe from.
|
||||||
|
*
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the event listener was successfully removed from the filter and rejected with an Error object in other case
|
||||||
|
*/
|
||||||
|
Filter.prototype.removeEventListener = function (eventType) {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
console.info('Removing filter event listener to event ' + eventType + ' to stream ' + _this.stream.streamId);
|
||||||
|
_this.stream.session.openvidu.sendRequest('removeFilterEventListener', { streamId: _this.stream.streamId, eventType: eventType }, function (error, response) {
|
||||||
|
if (error) {
|
||||||
|
console.error('Error removing filter event listener to event ' + eventType + 'for Stream ' + _this.stream.streamId, error);
|
||||||
|
if (error.code === 401) {
|
||||||
|
reject(new OpenViduError_1.OpenViduError(OpenViduError_1.OpenViduErrorName.OPENVIDU_PERMISSION_DENIED, "You don't have permissions to add a filter event listener"));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
reject(error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
delete _this.handlers[eventType];
|
||||||
|
console.info('Filter event listener to event ' + eventType + ' successfully removed on Stream ' + _this.stream.streamId);
|
||||||
|
resolve();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
};
|
||||||
|
return Filter;
|
||||||
|
}());
|
||||||
|
exports.Filter = Filter;
|
||||||
|
//# sourceMappingURL=Filter.js.map
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"Filter.js","sourceRoot":"","sources":["../../src/OpenVidu/Filter.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG;;AAIH,oGAAmG;AACnG,yEAA2F;AAI3F;;;;GAIG;AACH;IA0CI;;OAEG;IACH,gBAAY,IAAY,EAAE,OAAe;QAdzC;;WAEG;QACH,aAAQ,GAAyC,EAAE,CAAC;QAYhD,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IAC3B,CAAC;IAGD;;;;;OAKG;IACH,2BAAU,GAAV,UAAW,MAAc,EAAE,MAAc;QAAzC,iBAqCC;QApCG,OAAO,IAAI,OAAO,CAAC,UAAC,OAAO,EAAE,MAAM;YAC/B,OAAO,CAAC,IAAI,CAAC,oCAAoC,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAC1E,IAAI,YAAY,CAAC;YACjB,IAAI,OAAO,MAAM,KAAK,QAAQ,EAAE;gBAC5B,IAAI;oBACA,YAAY,GAAG,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;iBACzC;gBAAC,OAAO,KAAK,EAAE;oBACZ,IAAM,QAAQ,GAAG,mDAAmD,CAAC;oBACrE,OAAO,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;oBACxB,MAAM,CAAC,QAAQ,CAAC,CAAC;iBACpB;aACJ;iBAAM;gBACH,YAAY,GAAW,MAAM,CAAC;aACjC;YACD,KAAI,CAAC,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC,WAAW,CACpC,kBAAkB,EAClB,EAAE,QAAQ,EAAE,KAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,MAAM,QAAA,EAAE,MAAM,EAAE,YAAY,EAAE,EAChE,UAAC,KAAK,EAAE,QAAQ;gBACZ,IAAI,KAAK,EAAE;oBACP,OAAO,CAAC,KAAK,CAAC,2CAA2C,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC;oBACzF,IAAI,KAAK,CAAC,IAAI,KAAK,GAAG,EAAE;wBACpB,MAAM,CAAC,IAAI,6BAAa,CAAC,iCAAiB,CAAC,0BAA0B,EAAE,uDAAuD,CAAC,CAAC,CAAC;qBACpI;yBAAM;wBACH,MAAM,CAAC,KAAK,CAAC,CAAC;qBACjB;iBACJ;qBAAM;oBACH,OAAO,CAAC,IAAI,CAAC,gDAAgD,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;oBACtF,IAAM,QAAQ,GAAS,MAAO,CAAC,MAAM,CAAC,EAAE,EAAE,KAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;oBAC9D,KAAI,CAAC,MAAM,CAAC,MAAM,CAAC,cAAc,GAAG,EAAE,MAAM,QAAA,EAAE,MAAM,EAAE,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,EAAE,CAAC;oBACjF,KAAI,CAAC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,uBAAuB,EAAE,CAAC,IAAI,uDAA0B,CAAC,KAAI,CAAC,MAAM,CAAC,OAAO,EAAE,KAAI,CAAC,MAAM,EAAE,QAAQ,EAAE,KAAI,CAAC,MAAM,CAAC,MAAM,EAAE,QAAQ,EAAE,kBAAkB,CAAC,CAAC,CAAC,CAAC;oBACvL,KAAI,CAAC,MAAM,CAAC,aAAa,CAAC,SAAS,CAAC,uBAAuB,EAAE,CAAC,IAAI,uDAA0B,CAAC,KAAI,CAAC,MAAM,CAAC,aAAa,EAAE,KAAI,CAAC,MAAM,EAAE,QAAQ,EAAE,KAAI,CAAC,MAAM,CAAC,MAAM,EAAE,QAAQ,EAAE,kBAAkB,CAAC,CAAC,CAAC,CAAC;oBACnM,OAAO,EAAE,CAAC;iBACb;YACL,CAAC,CACJ,CAAC;QACN,CAAC,CAAC,CAAC;IACP,CAAC;IAGD;;;;;;;OAOG;IACH,iCAAgB,GAAhB,UAAiB,SAAiB,EAAE,OAAqC;QAAzE,iBAsBC;QArBG,OAAO,IAAI,OAAO,CAAC,UAAC,OAAO,EAAE,MAAM;YAC/B,OAAO,CAAC,IAAI,CAAC,wCAAwC,GAAG,SAAS,GAAG,aAAa,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAC1G,KAAI,CAAC,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC,WAAW,CACpC,wBAAwB,EACxB,EAAE,QAAQ,EAAE,KAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,SAAS,WAAA,EAAE,EAC7C,UAAC,KAAK,EAAE,QAAQ;gBACZ,IAAI,KAAK,EAAE;oBACP,OAAO,CAAC,KAAK,CAAC,8CAA8C,GAAG,SAAS,GAAG,aAAa,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC;oBACxH,IAAI,KAAK,CAAC,IAAI,KAAK,GAAG,EAAE;wBACpB,MAAM,CAAC,IAAI,6BAAa,CAAC,iCAAiB,CAAC,0BAA0B,EAAE,2DAA2D,CAAC,CAAC,CAAC;qBACxI;yBAAM;wBACH,MAAM,CAAC,KAAK,CAAC,CAAC;qBACjB;iBACJ;qBAAM;oBACH,KAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,GAAG,OAAO,CAAC;oBACnC,OAAO,CAAC,IAAI,CAAC,iCAAiC,GAAG,SAAS,GAAG,kCAAkC,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;oBACxH,OAAO,EAAE,CAAC;iBACb;YACL,CAAC,CACJ,CAAC;QACN,CAAC,CAAC,CAAC;IACP,CAAC;IAGD;;;;;;OAMG;IACH,oCAAmB,GAAnB,UAAoB,SAAiB;QAArC,iBAsBC;QArBG,OAAO,IAAI,OAAO,CAAC,UAAC,OAAO,EAAE,MAAM;YAC/B,OAAO,CAAC,IAAI,CAAC,0CAA0C,GAAG,SAAS,GAAG,aAAa,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAC5G,KAAI,CAAC,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC,WAAW,CACpC,2BAA2B,EAC3B,EAAE,QAAQ,EAAE,KAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,SAAS,WAAA,EAAE,EAC7C,UAAC,KAAK,EAAE,QAAQ;gBACZ,IAAI,KAAK,EAAE;oBACP,OAAO,CAAC,KAAK,CAAC,gDAAgD,GAAG,SAAS,GAAG,aAAa,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC;oBAC1H,IAAI,KAAK,CAAC,IAAI,KAAK,GAAG,EAAE;wBACpB,MAAM,CAAC,IAAI,6BAAa,CAAC,iCAAiB,CAAC,0BAA0B,EAAE,2DAA2D,CAAC,CAAC,CAAC;qBACxI;yBAAM;wBACH,MAAM,CAAC,KAAK,CAAC,CAAC;qBACjB;iBACJ;qBAAM;oBACH,OAAO,KAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;oBAChC,OAAO,CAAC,IAAI,CAAC,iCAAiC,GAAG,SAAS,GAAG,kCAAkC,GAAG,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;oBACxH,OAAO,EAAE,CAAC;iBACb;YACL,CAAC,CACJ,CAAC;QACN,CAAC,CAAC,CAAC;IACP,CAAC;IAEL,aAAC;AAAD,CAAC,AAjKD,IAiKC;AAjKY,wBAAM"}
|
|
@ -0,0 +1,83 @@
|
||||||
|
import { Stream } from './Stream';
|
||||||
|
import { LocalRecorderState } from '../OpenViduInternal/Enums/LocalRecorderState';
|
||||||
|
/**
|
||||||
|
* Easy recording of [[Stream]] objects straightaway from the browser. Initialized with [[OpenVidu.initLocalRecorder]] method
|
||||||
|
*
|
||||||
|
* > WARNING: Performing browser local recording of **remote streams** may cause some troubles. A long waiting time may be required after calling _LocalRecorder.stop()_ in this case
|
||||||
|
*/
|
||||||
|
export declare class LocalRecorder {
|
||||||
|
private stream;
|
||||||
|
state: LocalRecorderState;
|
||||||
|
private connectionId;
|
||||||
|
private mediaRecorder;
|
||||||
|
private chunks;
|
||||||
|
private blob;
|
||||||
|
private count;
|
||||||
|
private id;
|
||||||
|
private videoPreviewSrc;
|
||||||
|
private htmlParentElementId;
|
||||||
|
private videoPreview;
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
constructor(stream: Stream);
|
||||||
|
/**
|
||||||
|
* Starts the recording of the Stream. [[state]] property must be `READY`. After method succeeds is set to `RECORDING`
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the recording successfully started and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
record(): Promise<any>;
|
||||||
|
/**
|
||||||
|
* Ends the recording of the Stream. [[state]] property must be `RECORDING` or `PAUSED`. After method succeeds is set to `FINISHED`
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the recording successfully stopped and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
stop(): Promise<any>;
|
||||||
|
/**
|
||||||
|
* Pauses the recording of the Stream. [[state]] property must be `RECORDING`. After method succeeds is set to `PAUSED`
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the recording was successfully paused and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
pause(): Promise<any>;
|
||||||
|
/**
|
||||||
|
* Resumes the recording of the Stream. [[state]] property must be `PAUSED`. After method succeeds is set to `RECORDING`
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the recording was successfully resumed and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
resume(): Promise<any>;
|
||||||
|
/**
|
||||||
|
* Previews the recording, appending a new HTMLVideoElement to element with id `parentId`. [[state]] property must be `FINISHED`
|
||||||
|
*/
|
||||||
|
preview(parentElement: any): HTMLVideoElement;
|
||||||
|
/**
|
||||||
|
* Gracefully stops and cleans the current recording (WARNING: it is completely dismissed). Sets [[state]] to `READY` so the recording can start again
|
||||||
|
*/
|
||||||
|
clean(): void;
|
||||||
|
/**
|
||||||
|
* Downloads the recorded video through the browser. [[state]] property must be `FINISHED`
|
||||||
|
*/
|
||||||
|
download(): void;
|
||||||
|
/**
|
||||||
|
* Gets the raw Blob file. Methods preview, download, uploadAsBinary and uploadAsMultipartfile use this same file to perform their specific actions. [[state]] property must be `FINISHED`
|
||||||
|
*/
|
||||||
|
getBlob(): Blob;
|
||||||
|
/**
|
||||||
|
* Uploads the recorded video as a binary file performing an HTTP/POST operation to URL `endpoint`. [[state]] property must be `FINISHED`. Optional HTTP headers can be passed as second parameter. For example:
|
||||||
|
* ```
|
||||||
|
* var headers = {
|
||||||
|
* "Cookie": "$Version=1; Skin=new;",
|
||||||
|
* "Authorization":"Basic QWxhZGpbjpuIHNlctZQ=="
|
||||||
|
* }
|
||||||
|
* ```
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved with the `http.responseText` from server if the operation was successful and rejected with the failed `http.status` if not
|
||||||
|
*/
|
||||||
|
uploadAsBinary(endpoint: string, headers?: any): Promise<any>;
|
||||||
|
/**
|
||||||
|
* Uploads the recorded video as a multipart file performing an HTTP/POST operation to URL `endpoint`. [[state]] property must be `FINISHED`. Optional HTTP headers can be passed as second parameter. For example:
|
||||||
|
* ```
|
||||||
|
* var headers = {
|
||||||
|
* "Cookie": "$Version=1; Skin=new;",
|
||||||
|
* "Authorization":"Basic QWxhZGpbjpuIHNlctZQ=="
|
||||||
|
* }
|
||||||
|
* ```
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved with the `http.responseText` from server if the operation was successful and rejected with the failed `http.status` if not:
|
||||||
|
*/
|
||||||
|
uploadAsMultipartfile(endpoint: string, headers?: any): Promise<any>;
|
||||||
|
private onStopDefault;
|
||||||
|
}
|
|
@ -0,0 +1,327 @@
|
||||||
|
"use strict";
|
||||||
|
/*
|
||||||
|
* (C) Copyright 2017-2018 OpenVidu (https://openvidu.io/)
|
||||||
|
*
|
||||||
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
* you may not use this file except in compliance with the License.
|
||||||
|
* You may obtain a copy of the License at
|
||||||
|
*
|
||||||
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
*
|
||||||
|
* Unless required by applicable law or agreed to in writing, software
|
||||||
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
* See the License for the specific language governing permissions and
|
||||||
|
* limitations under the License.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
exports.__esModule = true;
|
||||||
|
var LocalRecorderState_1 = require("../OpenViduInternal/Enums/LocalRecorderState");
|
||||||
|
/**
|
||||||
|
* Easy recording of [[Stream]] objects straightaway from the browser. Initialized with [[OpenVidu.initLocalRecorder]] method
|
||||||
|
*
|
||||||
|
* > WARNING: Performing browser local recording of **remote streams** may cause some troubles. A long waiting time may be required after calling _LocalRecorder.stop()_ in this case
|
||||||
|
*/
|
||||||
|
var LocalRecorder = /** @class */ (function () {
|
||||||
|
/**
|
||||||
|
* @hidden
|
||||||
|
*/
|
||||||
|
function LocalRecorder(stream) {
|
||||||
|
this.stream = stream;
|
||||||
|
this.chunks = [];
|
||||||
|
this.count = 0;
|
||||||
|
this.connectionId = (!!this.stream.connection) ? this.stream.connection.connectionId : 'default-connection';
|
||||||
|
this.id = this.stream.streamId + '_' + this.connectionId + '_localrecord';
|
||||||
|
this.state = LocalRecorderState_1.LocalRecorderState.READY;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Starts the recording of the Stream. [[state]] property must be `READY`. After method succeeds is set to `RECORDING`
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the recording successfully started and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.record = function () {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
try {
|
||||||
|
if (typeof MediaRecorder === 'undefined') {
|
||||||
|
console.error('MediaRecorder not supported on your browser. See compatibility in https://caniuse.com/#search=MediaRecorder');
|
||||||
|
throw (Error('MediaRecorder not supported on your browser. See compatibility in https://caniuse.com/#search=MediaRecorder'));
|
||||||
|
}
|
||||||
|
if (_this.state !== LocalRecorderState_1.LocalRecorderState.READY) {
|
||||||
|
throw (Error('\'LocalRecord.record()\' needs \'LocalRecord.state\' to be \'READY\' (current value: \'' + _this.state + '\'). Call \'LocalRecorder.clean()\' or init a new LocalRecorder before'));
|
||||||
|
}
|
||||||
|
console.log("Starting local recording of stream '" + _this.stream.streamId + "' of connection '" + _this.connectionId + "'");
|
||||||
|
if (typeof MediaRecorder.isTypeSupported === 'function') {
|
||||||
|
var options = void 0;
|
||||||
|
if (MediaRecorder.isTypeSupported('video/webm;codecs=vp9')) {
|
||||||
|
options = { mimeType: 'video/webm;codecs=vp9' };
|
||||||
|
}
|
||||||
|
else if (MediaRecorder.isTypeSupported('video/webm;codecs=h264')) {
|
||||||
|
options = { mimeType: 'video/webm;codecs=h264' };
|
||||||
|
}
|
||||||
|
else if (MediaRecorder.isTypeSupported('video/webm;codecs=vp8')) {
|
||||||
|
options = { mimeType: 'video/webm;codecs=vp8' };
|
||||||
|
}
|
||||||
|
console.log('Using mimeType ' + options.mimeType);
|
||||||
|
_this.mediaRecorder = new MediaRecorder(_this.stream.getMediaStream(), options);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
console.warn('isTypeSupported is not supported, using default codecs for browser');
|
||||||
|
_this.mediaRecorder = new MediaRecorder(_this.stream.getMediaStream());
|
||||||
|
}
|
||||||
|
_this.mediaRecorder.start(10);
|
||||||
|
}
|
||||||
|
catch (err) {
|
||||||
|
reject(err);
|
||||||
|
}
|
||||||
|
_this.mediaRecorder.ondataavailable = function (e) {
|
||||||
|
_this.chunks.push(e.data);
|
||||||
|
};
|
||||||
|
_this.mediaRecorder.onerror = function (e) {
|
||||||
|
console.error('MediaRecorder error: ', e);
|
||||||
|
};
|
||||||
|
_this.mediaRecorder.onstart = function () {
|
||||||
|
console.log('MediaRecorder started (state=' + _this.mediaRecorder.state + ')');
|
||||||
|
};
|
||||||
|
_this.mediaRecorder.onstop = function () {
|
||||||
|
_this.onStopDefault();
|
||||||
|
};
|
||||||
|
_this.mediaRecorder.onpause = function () {
|
||||||
|
console.log('MediaRecorder paused (state=' + _this.mediaRecorder.state + ')');
|
||||||
|
};
|
||||||
|
_this.mediaRecorder.onresume = function () {
|
||||||
|
console.log('MediaRecorder resumed (state=' + _this.mediaRecorder.state + ')');
|
||||||
|
};
|
||||||
|
_this.mediaRecorder.onwarning = function (e) {
|
||||||
|
console.log('MediaRecorder warning: ' + e);
|
||||||
|
};
|
||||||
|
_this.state = LocalRecorderState_1.LocalRecorderState.RECORDING;
|
||||||
|
resolve();
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Ends the recording of the Stream. [[state]] property must be `RECORDING` or `PAUSED`. After method succeeds is set to `FINISHED`
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the recording successfully stopped and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.stop = function () {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
try {
|
||||||
|
if (_this.state === LocalRecorderState_1.LocalRecorderState.READY || _this.state === LocalRecorderState_1.LocalRecorderState.FINISHED) {
|
||||||
|
throw (Error('\'LocalRecord.stop()\' needs \'LocalRecord.state\' to be \'RECORDING\' or \'PAUSED\' (current value: \'' + _this.state + '\'). Call \'LocalRecorder.start()\' before'));
|
||||||
|
}
|
||||||
|
_this.mediaRecorder.onstop = function () {
|
||||||
|
_this.onStopDefault();
|
||||||
|
resolve();
|
||||||
|
};
|
||||||
|
_this.mediaRecorder.stop();
|
||||||
|
}
|
||||||
|
catch (e) {
|
||||||
|
reject(e);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Pauses the recording of the Stream. [[state]] property must be `RECORDING`. After method succeeds is set to `PAUSED`
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the recording was successfully paused and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.pause = function () {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
try {
|
||||||
|
if (_this.state !== LocalRecorderState_1.LocalRecorderState.RECORDING) {
|
||||||
|
reject(Error('\'LocalRecord.pause()\' needs \'LocalRecord.state\' to be \'RECORDING\' (current value: \'' + _this.state + '\'). Call \'LocalRecorder.start()\' or \'LocalRecorder.resume()\' before'));
|
||||||
|
}
|
||||||
|
_this.mediaRecorder.pause();
|
||||||
|
_this.state = LocalRecorderState_1.LocalRecorderState.PAUSED;
|
||||||
|
}
|
||||||
|
catch (error) {
|
||||||
|
reject(error);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Resumes the recording of the Stream. [[state]] property must be `PAUSED`. After method succeeds is set to `RECORDING`
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved if the recording was successfully resumed and rejected with an Error object if not
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.resume = function () {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
try {
|
||||||
|
if (_this.state !== LocalRecorderState_1.LocalRecorderState.PAUSED) {
|
||||||
|
throw (Error('\'LocalRecord.resume()\' needs \'LocalRecord.state\' to be \'PAUSED\' (current value: \'' + _this.state + '\'). Call \'LocalRecorder.pause()\' before'));
|
||||||
|
}
|
||||||
|
_this.mediaRecorder.resume();
|
||||||
|
_this.state = LocalRecorderState_1.LocalRecorderState.RECORDING;
|
||||||
|
}
|
||||||
|
catch (error) {
|
||||||
|
reject(error);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Previews the recording, appending a new HTMLVideoElement to element with id `parentId`. [[state]] property must be `FINISHED`
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.preview = function (parentElement) {
|
||||||
|
if (this.state !== LocalRecorderState_1.LocalRecorderState.FINISHED) {
|
||||||
|
throw (Error('\'LocalRecord.preview()\' needs \'LocalRecord.state\' to be \'FINISHED\' (current value: \'' + this.state + '\'). Call \'LocalRecorder.stop()\' before'));
|
||||||
|
}
|
||||||
|
this.videoPreview = document.createElement('video');
|
||||||
|
this.videoPreview.id = this.id;
|
||||||
|
this.videoPreview.autoplay = true;
|
||||||
|
if (typeof parentElement === 'string') {
|
||||||
|
this.htmlParentElementId = parentElement;
|
||||||
|
var parentElementDom = document.getElementById(parentElement);
|
||||||
|
if (parentElementDom) {
|
||||||
|
this.videoPreview = parentElementDom.appendChild(this.videoPreview);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
this.htmlParentElementId = parentElement.id;
|
||||||
|
this.videoPreview = parentElement.appendChild(this.videoPreview);
|
||||||
|
}
|
||||||
|
this.videoPreview.src = this.videoPreviewSrc;
|
||||||
|
return this.videoPreview;
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Gracefully stops and cleans the current recording (WARNING: it is completely dismissed). Sets [[state]] to `READY` so the recording can start again
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.clean = function () {
|
||||||
|
var _this = this;
|
||||||
|
var f = function () {
|
||||||
|
delete _this.blob;
|
||||||
|
_this.chunks = [];
|
||||||
|
_this.count = 0;
|
||||||
|
delete _this.mediaRecorder;
|
||||||
|
_this.state = LocalRecorderState_1.LocalRecorderState.READY;
|
||||||
|
};
|
||||||
|
if (this.state === LocalRecorderState_1.LocalRecorderState.RECORDING || this.state === LocalRecorderState_1.LocalRecorderState.PAUSED) {
|
||||||
|
this.stop().then(function () { return f(); })["catch"](function () { return f(); });
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
f();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Downloads the recorded video through the browser. [[state]] property must be `FINISHED`
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.download = function () {
|
||||||
|
if (this.state !== LocalRecorderState_1.LocalRecorderState.FINISHED) {
|
||||||
|
throw (Error('\'LocalRecord.download()\' needs \'LocalRecord.state\' to be \'FINISHED\' (current value: \'' + this.state + '\'). Call \'LocalRecorder.stop()\' before'));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
var a = document.createElement('a');
|
||||||
|
a.style.display = 'none';
|
||||||
|
document.body.appendChild(a);
|
||||||
|
var url = window.URL.createObjectURL(this.blob);
|
||||||
|
a.href = url;
|
||||||
|
a.download = this.id + '.webm';
|
||||||
|
a.click();
|
||||||
|
window.URL.revokeObjectURL(url);
|
||||||
|
document.body.removeChild(a);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Gets the raw Blob file. Methods preview, download, uploadAsBinary and uploadAsMultipartfile use this same file to perform their specific actions. [[state]] property must be `FINISHED`
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.getBlob = function () {
|
||||||
|
if (this.state !== LocalRecorderState_1.LocalRecorderState.FINISHED) {
|
||||||
|
throw (Error('Call \'LocalRecord.stop()\' before getting Blob file'));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return this.blob;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Uploads the recorded video as a binary file performing an HTTP/POST operation to URL `endpoint`. [[state]] property must be `FINISHED`. Optional HTTP headers can be passed as second parameter. For example:
|
||||||
|
* ```
|
||||||
|
* var headers = {
|
||||||
|
* "Cookie": "$Version=1; Skin=new;",
|
||||||
|
* "Authorization":"Basic QWxhZGpbjpuIHNlctZQ=="
|
||||||
|
* }
|
||||||
|
* ```
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved with the `http.responseText` from server if the operation was successful and rejected with the failed `http.status` if not
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.uploadAsBinary = function (endpoint, headers) {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
if (_this.state !== LocalRecorderState_1.LocalRecorderState.FINISHED) {
|
||||||
|
reject(Error('\'LocalRecord.uploadAsBinary()\' needs \'LocalRecord.state\' to be \'FINISHED\' (current value: \'' + _this.state + '\'). Call \'LocalRecorder.stop()\' before'));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
var http_1 = new XMLHttpRequest();
|
||||||
|
http_1.open('POST', endpoint, true);
|
||||||
|
if (typeof headers === 'object') {
|
||||||
|
for (var _i = 0, _a = Object.keys(headers); _i < _a.length; _i++) {
|
||||||
|
var key = _a[_i];
|
||||||
|
http_1.setRequestHeader(key, headers[key]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
http_1.onreadystatechange = function () {
|
||||||
|
if (http_1.readyState === 4) {
|
||||||
|
if (http_1.status.toString().charAt(0) === '2') {
|
||||||
|
// Success response from server (HTTP status standard: 2XX is success)
|
||||||
|
resolve(http_1.responseText);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
reject(http_1.status);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
http_1.send(_this.blob);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/**
|
||||||
|
* Uploads the recorded video as a multipart file performing an HTTP/POST operation to URL `endpoint`. [[state]] property must be `FINISHED`. Optional HTTP headers can be passed as second parameter. For example:
|
||||||
|
* ```
|
||||||
|
* var headers = {
|
||||||
|
* "Cookie": "$Version=1; Skin=new;",
|
||||||
|
* "Authorization":"Basic QWxhZGpbjpuIHNlctZQ=="
|
||||||
|
* }
|
||||||
|
* ```
|
||||||
|
* @returns A Promise (to which you can optionally subscribe to) that is resolved with the `http.responseText` from server if the operation was successful and rejected with the failed `http.status` if not:
|
||||||
|
*/
|
||||||
|
LocalRecorder.prototype.uploadAsMultipartfile = function (endpoint, headers) {
|
||||||
|
var _this = this;
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
if (_this.state !== LocalRecorderState_1.LocalRecorderState.FINISHED) {
|
||||||
|
reject(Error('\'LocalRecord.uploadAsMultipartfile()\' needs \'LocalRecord.state\' to be \'FINISHED\' (current value: \'' + _this.state + '\'). Call \'LocalRecorder.stop()\' before'));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
var http_2 = new XMLHttpRequest();
|
||||||
|
http_2.open('POST', endpoint, true);
|
||||||
|
if (typeof headers === 'object') {
|
||||||
|
for (var _i = 0, _a = Object.keys(headers); _i < _a.length; _i++) {
|
||||||
|
var key = _a[_i];
|
||||||
|
http_2.setRequestHeader(key, headers[key]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
var sendable = new FormData();
|
||||||
|
sendable.append('file', _this.blob, _this.id + '.webm');
|
||||||
|
http_2.onreadystatechange = function () {
|
||||||
|
if (http_2.readyState === 4) {
|
||||||
|
if (http_2.status.toString().charAt(0) === '2') {
|
||||||
|
// Success response from server (HTTP status standard: 2XX is success)
|
||||||
|
resolve(http_2.responseText);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
reject(http_2.status);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
http_2.send(sendable);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
/* Private methods */
|
||||||
|
LocalRecorder.prototype.onStopDefault = function () {
|
||||||
|
console.log('MediaRecorder stopped (state=' + this.mediaRecorder.state + ')');
|
||||||
|
this.blob = new Blob(this.chunks, { type: 'video/webm' });
|
||||||
|
this.chunks = [];
|
||||||
|
this.videoPreviewSrc = window.URL.createObjectURL(this.blob);
|
||||||
|
this.state = LocalRecorderState_1.LocalRecorderState.FINISHED;
|
||||||
|
};
|
||||||
|
return LocalRecorder;
|
||||||
|
}());
|
||||||
|
exports.LocalRecorder = LocalRecorder;
|
||||||
|
//# sourceMappingURL=LocalRecorder.js.map
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue