Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@wealthsimple/fabric
Advanced tools
Fabric is the CSS toolkit that powers Wealthsimple's front-end design. It's purposefully limited to common components to provide our developers with the most flexibility. It's built with SCSS and available via Bower, so it's easy to include all or part of
Fabric is the CSS toolkit that powers Wealthsimple's front-end design. It's purposefully limited to common components to provide our developers with the most flexibility. It's built with SCSS and available via Bower, so it's easy to include all or part of it within your own project.
Read the Fabric documentation to learn more.
There are three options for installing Fabric on your own project.
If you are using a import
- or require
- aware javascript bundler like webpack, we recommend installing using npm
or yarn
:
npm install --save @wealthsimple/fabric
or
yarn add @wealthsimple/fabric
If your project setup isn't capable of processing npm-based modules, we also publish to bower.
First, create a bower.json
in your project root directory if you dont have one yet:
{
"name": "your-project-name",
"private": true
}
Optionally specify a .bowerrc
config file to control the directory where the assets get pulled into:
{
"directory": "vendor/assets/bower_components"
}
Then, to install the latest version of Fabric, run:
$ bower install --save https://github.com/wealthsimple/fabric.git
To update the package once installed:
$ bower update wealthsimple-fabric
The concatenated and minified CSS is available in https://github.com/wealthsimple/fabric/blob/master/css/fabric.css
Note: this is not recommended, as you won't have access to any of the SCSS variables or mixins.
Once installed with bower, simply @import
either the master SCSS file, or the individual files as you need them.
// Example: All of Fabric
@import "wealthsimple-fabric/scss/fabric";
// Example: Individual files
@import "wealthsimple-fabric/scss/variables";
@import "wealthsimple-fabric/scss/mixins";
@import "wealthsimple-fabric/scss/base";
Since font installation may vary based on the asset compilation framework you're using (e.g. Sprockets for Rails, Grunt for Ghost.org), Fabric does not include @font-face
definitions. You must include these yourself.
Example below. Note: for Sprockets-based compilation, you'll want to replace url
with font-url
.
// Regular
@font-face {
font-family: "FuturaPT";
src: url("/fonts/FuturaPT-Book.eot");
src: url("/fonts/FuturaPT-Book.eot?#iefix") format("embedded-opentype"), url("/fonts/FuturaPT-Book.woff2")
format("woff2"), url("/fonts/FuturaPT-Book.woff") format("woff"), url("/fonts/FuturaPT-Book.ttf")
format("truetype");
}
// Bold
@font-face {
font-family: "FuturaPT";
src: url("/fonts/FuturaPT-Heavy.eot");
src: url("/fonts/FuturaPT-Heavy.eot?#iefix") format("embedded-opentype"), url("/fonts/FuturaPT-Heavy.woff2")
format("woff2"), url("/fonts/FuturaPT-Heavy.woff") format("woff"), url("/fonts/FuturaPT-Heavy.ttf")
format("truetype");
font-weight: 700;
}
To get this setup working locally, you must first have Node.JS and Ruby installed.
Next, install dependencies with the following commands:
bundle install
npm install
npm install -g grunt-cli
Then, you may have to open a new Terminal window or run source ~/.bash_profile
to have access to the new grunt
and jekyll
binaries.
grunt watch
to have the CSS recompiled when any file in scss
is changedbundle exec jekyll server
The public documentation is hosted on GitHub pages. To push new changes, first compile the CSS:
$ grunt
Prepare a PR with a new version number that follows semantic versioning - this is really important!
Build the latest website by running (it will create _site
directory):
$ bundle exec jekyll server
Commit all changes, then push the changes to gh-pages
branch with:
$ grunt publish
Changes should be live in around 30 seconds.
For npm you need to manually publish. Go to your terminal, rebase latest master, and run:
$ npm login
$ npm publish
You will need to be added to our organization to publish the package.
Boilerplate for this repository was heavily reused from GitHub's CSS toolkit.
FAQs
Fabric is the CSS toolkit that powers Wealthsimple's front-end design. It's purposefully limited to common components to provide our developers with the most flexibility. It's built with SCSS and available via Bower, so it's easy to include all or part of
We found that @wealthsimple/fabric demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 11 open source maintainers collaborating on the project.
Did you know?
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.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.