Giter Site home page Giter Site logo

officedev / office-365-appchrome-control Goto Github PK

View Code? Open in Web Editor NEW
5.0 44.0 4.0 309 KB

[ARCHIVED] This repo covers a feature is no longer supported. We are archiving the repo and it will no longer be maintained.

License: Other

CSS 23.54% HTML 21.38% JavaScript 45.61% C# 8.51% ASP 0.20% TypeScript 0.76%

office-365-appchrome-control's Introduction

products languages extensions
office-365
javascript
createdDate
6/9/2015 12:03:26 AM

[ARCHIVED] Office 365 AppChrome Control

========================

Note: This repo is archived and no longer actively maintained. Security vulnerabilities may exist in the project, or its dependencies. If you plan to reuse or run any code from this repo, be sure to perform appropriate security checks on the code or dependencies first. Do not use this project as the starting point of a production Office Add-in. Always start your production code by using the Office/SharePoint development workload in Visual Studio, or the Yeoman generator for Office Add-ins, and follow security best practices as you develop the add-in.

The Office 365 AppChrome Control provides a simple but extensible way to add Office 365-style navigation bar with your own functions. This enables users to sign in and out of their Office 365 account and navigate to sites and pages that you'd like to feature. We develop the control in JavaScript to provide universal compatibility without the additional overhead of other frameworks. We build the controls with two parts, Web UI and Data Provider, so that developers could customize the control easily based on the interface we defined.

You could find more description from - Office 365 JavaScript controls

Web UI

The standard Office 365 web experience comes from Office UI Fabric, you could also visit their GitHub repository - OfficeDev/Office-UI-Fabric

Data Provider

We provide a sample data provider which retrieves data from Office 365, you could get more detail about how to access Office 365 data from - Office 365 API reference. If you want to use the sample provider, please remember to type in your Office 365 client ID before initialize the provider.

Here are the key steps

  • Create your own Office 365 client ID
  • Set permissions for the API you plan to use
  • Set "Redirect URI" for your web app
  • Configure "Implicit Grant" for OAuth flow

For more detail guidance, you could check from - Create an app with Office 365 APIs

Permissions

You need to configure permissions for your Office 365 app based on the API and scope you want to access.

Here are the permissions sample data provider requires

Feature Application Name Delegated Permission
Login Azure Active Directory Sign in and read user profile
User's info Azure Active Directory Sign in and read user profile

License

  • All files on the Office 365 AppChrome Control repository are subject to the MIT license. Please read the License file at the root of the project.
  • All the Web UI are based on OfficeDev/Office-UI-Fabric
  • Usage of the fonts referenced on Office UI Fabric files is subject to the terms listed here

How to store access token

We provide a sample implicit grant login provider which is based on ADAL.js. The ADAL.js stores the access token in browser's localStorage. The use of localStorage has security implications, given that other apps in the same domain will have access to it, and it is prone to the same attacks that localStorage have to deal with. So before using access token to do some user credential related operation, it must be sent to a backend service for parsing and validating.

We provide server side sample project LoginControlForSPASolutionabout to validate access token. More ways about how to validate access token, please reference here: https://github.com/AzureADSamples.

Sample Site

We provide a sample site in the "demo" folder. In this site, you could find

  • Demo for the control
  • Test page

Here are the key steps for running your own sample site

install nodejs

To install development packages - From the root of your local git repository

  • npm install gulp -g
  • npm install
  • npm install dev

To build minified files

  • gulp Then you could deploy to your web service

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

office-365-appchrome-control's People

Contributors

brendayang avatar cathycc2015 avatar davidchesnut avatar lindalu-msft avatar o365devx avatar whazmy avatar zholi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

office-365-appchrome-control's Issues

Use AppChrome-Control in an existing MVC App

Hi,

I would like to know how can I make use of the AppChrome-Control in my existing MVC app which already have authentication/authorization in placed.

I am using IdentityServer4 as my STS (hybrid flow configured to authenticate using Microsoft account). Below is a simple illustration of my mvc app authentication flow.

(MVC App) <--> (IdentityServer4) <--> (Microsoft v2 endpoint)

Appreciate your inputs to put me in the right direction.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.