@trimbleinc/modus-bootstrap

Modus Bootstrap is a responsive framework developed as a common platform for all Trimble web applications. It is built upon and extends the Bootstrap 4 framework.

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
@trimbleinc/modus-bootstrap
1.5.4a month ago2 years agoMinified + gzip package size for @trimbleinc/modus-bootstrap in KB

Readme

Modus Bootstrap
The Modus Bootstrap Framework was developed as a common platform for all of Trimble MAPS web applications, with the additional goal of sharing with other groups within Trimble. It leverages the Trimble brand as well as some of the work done by other groups, specifically Project Origin by the SketchUp team.

Background

The Modus Bootstrap Framework is built upon and extends the Bootstrap 4 code framework. It is a responsive framework for web and mobile uses. You can use the CSS files as is, or integrate the SASS files into your own application if you wish to modify it further.

CDN

The Modus Bootstrap Framework can be used as is from our public CDN: ```html ``` If you want to also use the Modus Bootstrap Framework layout (top nav, left nav, and content area) you will need to add these additional references in the head BEFORE Modus Bootstrap: ```html ``` You do not (and should not) include additional references to Bootstrap CSS other than their JavaScript links for component functions.  If you are using Angular, React, or other framework you should use an appropriate Bootstrap library. ```html ```

Install with npm

Install Modus Bootstrap Framework in your Node.js powered apps with our npm package:
$ npm install --save-dev @trimbleinc/modus-bootstrap
The compiled CSS files will be found in the ./node_modules/@trimbleinc/modus-bootstrap/dist directory.

Customize using SASS

The SASS files will be found in the /scss directory.

Development

Build CSS, run dev server, and watch for changes ```bash npm run dev ``` Sample page found at http://localhost:3030/

Build Package

Builds the CSS files to /dist ```bash npm run build ```

File structure

Whenever possible, avoid modifying Modus Bootstrap or Bootstrap core files. For Sass, that means creating your own stylesheet that imports Modus Bootstrap and Bootstrap so you can modify and extend it. Assuming you’re using a package manager like npm, you’ll have a file structure that looks like this: ```plaintext your-project/ ├── scss │ └── custom.scss └── nodemodules/
├── bootstrap
│   ├── js
│   └── scss
└── @trimblemaps
└──modus-framework
└── scss
```

Importing

In your custom.scss, you’ll import Modus Bootstrap and Bootstrap’s source Sass files. With that setup in place, you can begin to modify any of the Sass variables and maps in your custom.scss. You can also start to add parts of Bootstrap under the // Optional section as needed. We suggest using the full import stack from our bootstrap.scss file as your starting point. The main file to focus on is the _theme.scss file (and/or _theme-dark.scss if you want a dark look). You should copy this file from /node_modules/@trimbleinc/modus-bootstrap/scss/components to your own SASS directory and import your copy instead of the Modus Bootstrap Framework version in your main SASS file. This example shows you how you should structure your main file. The order in which files are imported matters. ```scss // Bootstrap functions @import "../node
modules/bootstrap/scss/functions"; // Modus Bootstrap functions @import "../nodemodules/@trimbleinc/modus-bootstrap/scss/components/functions"; // YOUR CUSTOM THEME GOES HERE @import "yourcustomsassdirectory/yourcopyofmodusthemefile"; // Modus Bootstrap variables @import "../nodemodules/@trimbleinc/modus-bootstrap/scss/components/variables"; // OPTIONAL - use your own variables: // @import "yourcustomsassdirectory/copyofmodusvariablesfile"; // Bootstrap variables @import "../nodemodules/bootstrap/scss/variables"; @import "../nodemodules/bootstrap/scss/mixins"; // Modus Bootstrap mixins @import "../nodemodules/@trimbleinc/modus-bootstrap/scss/components/mixins"; // Bootstrap components (you can leave some of these out if you don't need them) @import "../nodemodules/bootstrap/scss/reboot"; @import "../nodemodules/bootstrap/scss/type"; @import "../nodemodules/bootstrap/scss/images"; @import "../nodemodules/bootstrap/scss/code"; @import "../nodemodules/bootstrap/scss/grid"; @import "../nodemodules/bootstrap/scss/tables"; @import "../nodemodules/bootstrap/scss/forms"; @import "../nodemodules/bootstrap/scss/buttons"; @import "../nodemodules/bootstrap/scss/transitions"; @import "../nodemodules/bootstrap/scss/dropdown"; @import "../nodemodules/bootstrap/scss/button-group"; @import "../nodemodules/bootstrap/scss/input-group"; @import "../nodemodules/bootstrap/scss/custom-forms"; @import "../nodemodules/bootstrap/scss/nav"; @import "../nodemodules/bootstrap/scss/navbar"; @import "../nodemodules/bootstrap/scss/card"; @import "../nodemodules/bootstrap/scss/breadcrumb"; @import "../nodemodules/bootstrap/scss/pagination"; @import "../nodemodules/bootstrap/scss/badge"; @import "../nodemodules/bootstrap/scss/jumbotron"; @import "../nodemodules/bootstrap/scss/alert"; @import "../nodemodules/bootstrap/scss/progress"; @import "../nodemodules/bootstrap/scss/media"; @import "../nodemodules/bootstrap/scss/list-group"; @import "../nodemodules/bootstrap/scss/close"; @import "../nodemodules/bootstrap/scss/toasts"; @import "../nodemodules/bootstrap/scss/modal"; @import "../nodemodules/bootstrap/scss/tooltip"; @import "../nodemodules/bootstrap/scss/popover"; @import "../nodemodules/bootstrap/scss/carousel"; @import "../nodemodules/bootstrap/scss/spinners"; @import "../nodemodules/bootstrap/scss/utilities"; @import "../nodemodules/bootstrap/scss/print"; // Modus Bootstrap components @import "../nodemodules/@trimbleinc/modus-bootstrap/scss/components/controls"; @import "../nodemodules/@trimbleinc/modus-bootstrap/scss/components/base"; @import "../nodemodules/@trimbleinc/modus-bootstrap/scss/components/file-drop-zone"; // YOUR SITE SPECIFIC SASS GOES HERE @import "yourcustomsassdirectory/yourprojectspecificsassfiles"; ```