🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis →
Socket
Book a DemoInstallSign in
Socket

3dwayfinder-angular

Package Overview
Dependencies
Maintainers
2
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

3dwayfinder-angular

Angular service for 3D Wayfinder

latest
Source
npmnpm
Version
0.2.2
Version published
Maintainers
2
Created
Source

3DWayfinderAngular

Angular Service for 3D Wayfinder (now supports 2D maps also)

Getting started

Install

bower install --save 3dwayfinder-angular

Please include the following JavaScript files into Your HTML file and inject wfangular into Your Angular app:

<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.min.js"></script>
<!-- FOR 3D Map add the line below -->
<script type="text/javascript" src="http://static.3dwayfinder.com/projects/shared/js/minified/frak-stable.min.js"></script>
<script type="text/javascript" src="http://static.3dwayfinder.com/projects/shared/js/minified/Wayfinder3D.min.js"></script>
<!-- FOR 2D Map add the line below -->
<script type="text/javascript" src="http://static.3dwayfinder.com/projects/shared/js/minified/Wayfinder2D.min.js"></script>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/angularjs/1.4.6/angular.min.js"></script>
<script type="text/javascript" src="index.js"></script>

<script>
    var app = angular.module('basictest', ['wfangular']);
    app.config(['wfangularConfig', function(wayfinderConfig){
    	wayfinderConfig.mapType = '2d';
    }])
    app.run(['wfangular', function(wayfinder) {
      wayfinder.open();
    }]);
</script>

Broadcasted events

  • wf.data.loaded - broadcasted when all data is loaded
  • wf.poi.click - broadcasted when user clicks on map. Arguments: POI
  • wf.language.change - broadcasted when language is changed. Arguments: language code {string} (eg en, de etc)
  • wf.floor.change - broadcasted when floor is changed. Arguments: Floor
  • wf.zoom.change - broadcasted when zoom is changed. Arguments: zoom {float}
  • wf.path.floor.change - broadcasted when path animation changes floor: Arguments: Object {current: Floor, next: Floor, destination: Floor}

Directives

  • wf-banner - displays a banner, ex. id="advertisements" template="default"
  • wf-floor-buttons - displays floor buttons, on-click function to react, can give additional parameters for the button group via group-class and for the buttons via button-class, see example below
<wf-floors-buttons group-class="btn-group floors-buttons" active-class="btn btn-positive floor"></wf-floors-buttons>

##Options Constant wfangularConfig takes the following arguments for changing the behavior:

  • assetsLocation: 'http://static.3dwayfinder.com/shared/',
  • apiLocation: 'http://api.3dwayfinder.com'
  • mapType: '3d'//2d

Keywords

3d

FAQs

Package last updated on 03 Jun 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts