You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
+[Alphabetization of Bidder Adapters](#alphabetization-of-bidder-adaptors)
9
+
+[Building Assets](#building-assets)
10
10
+[The Downloads Page](#the-downloads-page)
11
11
+[Thanks](#thanks)
12
12
@@ -33,20 +33,17 @@ All docs are under the license shown in the `LICENSE` file in this directory.
33
33
34
34
## Prerequisites
35
35
36
-
The site uses [Jekyll](http://jekyllrb.com/), which is written in the [Ruby](http://www.ruby-lang.org/en/) language.
36
+
The site uses [Jekyll](https://jekyllrb.com/), which is written in the [Ruby](https://www.ruby-lang.org/en/) language.
37
37
38
-
To follow the instructions in the next section, you will need to install the [Bundler](http://bundler.io/) Ruby gem.
38
+
1. follow the instructions at https://jekyllrb.com/docs/installation/ for your OS
39
+
1. gem install github-pages
40
+
1. start Jekyll as described below
39
41
40
-
Try the following command:
42
+
For CSS, the site uses Laravel Mix to build CSS from Sass (scss-flavored) source files. Under the hood Laravel Mix uses Webpack.
41
43
42
-
```
43
-
$ gem install bundler
44
-
```
45
-
46
-
If you are on a Mac and the above command fails with a permissions error (e.g., `"ERROR: While executing gem ... You don't have write permissions for the /Library/Ruby/Gems/... directory."`), try the following steps:
47
-
48
-
1. Build your own `ruby` binary using [Homebrew](https://brew.sh/): `brew install ruby`. The Homebrew-built Ruby should include its own version of the `gem` command which avoids modifying system libraries.
49
-
2. Try `gem install bundler` again. If it still fails, try `sudo gem install bundler`. After that, you should be able to avoid any further use of `sudo` by running `bundler` with the arguments shown in the next section.
44
+
1. follow the instructions at https://nodejs.dev to install Node.js for your OS
45
+
1.`npm install` to install packages for building assets
46
+
1. build assets as described below
50
47
51
48
<aname="running-jekyll-locally" />
52
49
@@ -56,10 +53,7 @@ Before submitting a pull request, you should run the site locally to make sure y
56
53
57
54
To get started editing the site and seeing your changes, clone this repo and enter the following commands in your terminal:
58
55
59
-
-`cd /path/to/prebid.github.io`
60
-
61
-
-`bundle install --path vendor/bundle`
62
-
56
+
-`cd path/to/prebid.github.io`
63
57
-`bundle exec jekyll serve`
64
58
65
59
You should see output that looks something like this:
Open the `Server address` URL in your browser, and you should see a locally running copy of the site.
83
77
84
-
<aname="alphabetization-of-bidder-adaptors"/>
78
+
<aname="building-assets"/>
85
79
86
-
## Alphabetization of Bidder Adaptors
87
-
88
-
Please don't alphabetize the lists of adapters in your PR, either on the home page or the downloads page.
89
-
90
-
The adapters are not listed in alphabetical order, they're listed in the order in which they were added to the Prebid.js repo, using (approximately) this command in `src/adapters`:
91
-
92
-
```
93
-
for file in `ls | grep -f <(git ls-files)`; do
94
-
HASH=`git rev-list HEAD $file | tail -n 1`;
95
-
DATE=`git show -s --format="%ci" $HASH --`;
96
-
printf "%-35s %-35s %s\n" $file "$DATE" $HASH;
97
-
done | sort -d -k 2
98
-
```
80
+
## Building Assets
99
81
100
-
<aname="the-downloads-page" />
82
+
-`npm run dev` to build unminified CSS for development
83
+
-`npm run prod` to build minified CSS for production
84
+
-`npm run watch` to use [Browsersync](https://browsersync.io) to rebuild CSS on demand and reload the browser
@warn"Cannot convert `#{unit($value)}` to `#{$unit}`.";
11
+
}
12
+
13
+
/// Test if `$value` is an angle
14
+
///@param{*}$value - Value to test
15
+
///@return{Bool}
16
+
@function is-direction($value) {
17
+
$is-direction: index((to top, to topright, to righttop, to right, to bottomright, to rightbottom, to bottom, to bottomleft, to leftbottom, to left, to lefttop, to topleft), $value);
18
+
$is-angle: type-of($value) == 'number' and index('deg''grad''turn''rad', unit($value));
19
+
20
+
@return$is-direction or $is-angle;
21
+
}
22
+
23
+
/// Convert a direction to legacy syntax
24
+
///@param{Keyword | Angle}$value - Value to convert
25
+
///@require{function}is-direction
26
+
///@require{function}convert-angle
27
+
@functionlegacy-direction($value) {
28
+
@ifis-direction($value) == false {
29
+
@warn"Cannot convert `#{$value}` to legacy syntax because it doesn't seem to be an angle or a direction";
0 commit comments