1.0.4 • Published 6 years ago
ng-fweb-sidebar v1.0.4
#ngFwebSidebar
What is this repo?
This repo has the Angular.JS Fracweb sidebar. This allows us to update the sidebar in one repo, then import in those changes into all the other Fracweb repos.
How do I use it?
- In the
package.json
you want to import it in using an absolute version such as"ng-fweb-sidebar": "1.0.1",
. - Run
npm i
- Delete the sidebar files. If you don't know where they are, do a file search (command + P) for "sidebar".
- Make sure you have
grunt watch
running. It will yell at you about errors and it will guide you through the process. Fix one error, then the next error will come up until you are done. - Once you have it working, the product color will be a maroon.
- To update the product color, go to the product controller, find the
this.config
and at the bottom of the config add, theproductColor
. Here is an example:this.config = { listOfViews, logoTitle: 'FIS', user: this.user, logout: this.logoutLink, logoLink: 'index', productColor: '#d9534f' }
- Now you should see the correct product color!
Solutions to common errors
- Replace
@import '../../../assets/universal/components/sidebar/sidebar.sass'
with@import 'node_modules/ng-fweb-sidebar/dist/ngFwebSidebar'
- Replace
import '../../../../assets/universal/components/universal.components.module'
withimport 'ng-fweb-sidebar/dist/ngFwebSidebar.js'
- In the Angular Module for the product, replace
'universalComponents',
with'ngFwebSidebar',
- An error saying
$gray
is not defined. In the place where all the color variables are declared add in$gray: #dedede