All Projects → alvarotrigo → Angular Fullpage

alvarotrigo / Angular Fullpage

Licence: gpl-3.0
Official Angular wrapper for fullPage.js https://alvarotrigo.com/angular-fullpage/

Programming Languages

typescript
32286 projects

Projects that are alternatives of or similar to Angular Fullpage

React Fullpage
Official React.js wrapper for fullPage.js https://alvarotrigo.com/react-fullpage/
Stars: ✭ 707 (+439.69%)
Mutual labels:  slideshow, fullscreen, scrolling, snap
Fullpage.js
fullPage plugin by Alvaro Trigo. Create full screen pages fast and simple
Stars: ✭ 32,974 (+25070.99%)
Mutual labels:  slideshow, fullscreen, scrolling, snap
Vue Fullpage.js
Official Vue.js wrapper for fullPage.js http://alvarotrigo.com/vue-fullpage/
Stars: ✭ 1,626 (+1141.22%)
Mutual labels:  slideshow, fullscreen, scrolling, snap
Multiscroll.js
multiscroll plugin by Alvaro Trigo. Create scrolling split websites. http://alvarotrigo.com/multiScroll/
Stars: ✭ 1,537 (+1073.28%)
Mutual labels:  slideshow, scrolling, snap
Scroll Snap
↯ Snap page when user stops scrolling, with a customizable configuration and a consistent cross browser behaviour
Stars: ✭ 187 (+42.75%)
Mutual labels:  scrolling, snap
Pageable
Create full page scrolling web pages. No jQuery.
Stars: ✭ 199 (+51.91%)
Mutual labels:  slideshow, scrolling
awesome-angular
💖 A list of awesome Angular (2️⃣➕) resources
Stars: ✭ 61 (-53.44%)
Mutual labels:  angular-cli, angular-component
Pagepiling.js
pagePiling plugin by Alvaro Trigo. Create a scrolling pile of sections. http://alvarotrigo.com/pagePiling/
Stars: ✭ 3,993 (+2948.09%)
Mutual labels:  scrolling, snap
ng2-go-top-button
A simple customizable go-top-button component for Angular projects.
Stars: ✭ 18 (-86.26%)
Mutual labels:  scrolling, angular-component
cachu-slider
🌈 🔆 Create animated full screen and content-fit sliders efficiently.
Stars: ✭ 30 (-77.1%)
Mutual labels:  slideshow, scrolling
Angular Interview Questions
A list of helpful Angular interview questions you can use to interview potential candidates, test yourself or completely ignore.
Stars: ✭ 967 (+638.17%)
Mutual labels:  angular-component, angular-cli
Zhpopupcontroller
Help you pop up custom views easily. and support pop-up animation, layout position, mask effect and gesture interaction etc.
Stars: ✭ 1,481 (+1030.53%)
Mutual labels:  fullscreen
Snap.svg.zpd
A zoom/pan/drag/rotate plugin for Snap.svg (useful for view only)
Stars: ✭ 119 (-9.16%)
Mutual labels:  snap
Angular Firebase App
The code for the Angular and Firebase - Build a Web App Course
Stars: ✭ 124 (-5.34%)
Mutual labels:  angular-cli
Embla Carousel
A lightweight carousel library with fluid motion and great swipe precision.
Stars: ✭ 1,874 (+1330.53%)
Mutual labels:  slideshow
Ng Simple Slideshow
A simple, responsive slideshow for Angular 4+.
Stars: ✭ 119 (-9.16%)
Mutual labels:  slideshow
Jquery Scrolllock
Locks mouse wheel scroll inside container, preventing it from propagating to parent element
Stars: ✭ 109 (-16.79%)
Mutual labels:  scrolling
Angular Redux
Angular 4 and Redux simplified + Live Demo
Stars: ✭ 109 (-16.79%)
Mutual labels:  angular-cli
Ngx Content Loading
Angular component to create SVG loading placeholders
Stars: ✭ 124 (-5.34%)
Mutual labels:  angular-component
Angular Electron Seed
An Angular (4+) seed with Electron, Live-reload, AngularCLI, etc.
Stars: ✭ 118 (-9.92%)
Mutual labels:  angular-cli

Angular fullpage

preview

Official Angular wrapper for the fullpage.js library.

angular-fullpage version

Table of Contents

Installation

npm install @fullpage/angular-fullpage

This will install the Angular wrapper as well as fullpage.js library.

License

Non open source license

If you want to use angular-fullpage to develop non open sourced sites, themes, projects, and applications, the Commercial license is the appropriate license. With this option, your source code is kept proprietary. Which means, you won't have to change your whole application source code to an open source license. Purchase a Fullpage Commercial License.

Open source license

If you are creating an open source application under a license compatible with the GNU GPL license v3, you may use fullPage under the terms of the GPLv3.

The credit comments in the JavaScript and CSS files should be kept intact (even after combination or minification)

Read more about fullPage's license.

Usage

// app.module.ts
import { AngularFullpageModule } from '@fullpage/angular-fullpage';

@NgModule({
  imports: [
    BrowserModule,
    AppRoutingModule,
    AngularFullpageModule //*** added
  ]
})

You should import the fullpage.js stylesheet on your style.scss or component.scss:

/* styles.scss or app.component.scss */
@import url(~fullpage.js/dist/fullpage.min.css);
/* standard css */
@import '~fullpage.js/dist/fullpage.min.css';

Then use the directive on your component:

// app.component.ts
export class AppComponent {
  config: any;
  fullpage_api: any;

  constructor() {

    // for more details on config options please visit fullPage.js docs
    this.config = {

      // fullpage options
      licenseKey: 'YOUR LICENSE KEY HERE',
      anchors: ['firstPage', 'secondPage', 'thirdPage', 'fourthPage', 'lastPage'],
      menu: '#menu',

      // fullpage callbacks
      afterResize: () => {
        console.log("After resize");
      },
      afterLoad: (origin, destination, direction) => {
        console.log(origin.index);
      }
    };
  }

  getRef(fullPageRef) {
    this.fullpage_api = fullPageRef;
  }

}

You can optionally import types by

import { options, fullpage_api } from 'fullpage.js/dist/fullpage.extensions.min';
config: options;
fullpage_api: fullpage_api;

Example of HTML:

<!-- app.component.html -->
<div fullpage id="fullpage" [options]="config" (ref)="getRef($event)">
  <div class="section">Some section1</div>
	<div class="section" (click)="fullpage_api.moveSectionDown()">Some section2</div>
	<div class="section">
		<div class="slide">Slide 2.1</div>
		<div class="slide">Slide 2.2</div>
		<div class="slide">Slide 2.3</div>
	</div>
	<div class="section" (click)="fullpage_api.moveTo('secondPage', 2)">Some section4</div>
</div>

Use extensions

In order to make use of fullpage.js extension you'll have to add the extension file to angular.json.

For example, if we want to use the scrollHorizontally extension we will have to add the path to our fullpage.scrollHorizontally.min.js file on the scripts array:

"assets": [
  "src/favicon.ico",
  "src/assets"
],

"styles": [
  "src/styles.css"
],

"scripts": [
  "src/assets/fullpage.scrollHorizontally.min.js"
],

Then pass the required options to fullPage.js. In this case scrollHorizontally:true.

Use of scrollOverflow

Same procedure than the use of extensions detailed above.

"assets": [
  "src/favicon.ico",
  "src/assets"
],

"styles": [
  "src/styles.css"
],

"scripts": [
  "node_modules/fullpage.js/vendors/scrolloverflow.min.js"
],

Dynamic Changes

If you want to update fullPage.js with new changes in the DOM call the build() method after making those changes.

An example can be seen on the dynamic-changes example:

this.renderer.appendChild(this.fp_directive.nativeElement, section);
this.fullpage_api.build(); // <-- here

An example for *ngFor can be seen on the dynamic-changes-with-ngFor example:

<div fullpage id="fullpage" [options]="config" (ref)="getRef($event)">
    <div *ngFor="let section of sections" class="section">
		  <h1>Section {{section}}</h1>
	</div>
</div>

Examples

You can check some examples on the demo folder.

Contributing

Found an issue? Have an idea? Check out the Contributing guide and open a PR

Resources

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].