0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-13 04:22:40 +00:00

Pseudo borders are now working

This commit is contained in:
Scott Tolksdorf
2017-03-19 13:50:45 -04:00
parent 30d3fcf168
commit a3251dfa19
2 changed files with 42 additions and 41 deletions

View File

@@ -7,14 +7,11 @@
"quick": "node scripts/quick.js", "quick": "node scripts/quick.js",
"build": "node scripts/build.js", "build": "node scripts/build.js",
"populate": "node scripts/populate.js", "populate": "node scripts/populate.js",
"prod": "set NODE_ENV=production&& npm run build", "prod": "set NODE_ENV=production&& npm run build",
"postinstall": "npm run build", "postinstall": "npm run build",
"start": "node server.js", "start": "node server.js",
"snippet": "nodemon scripts/snippet.test.js",
"snippet" : "nodemon scripts/snippet.test.js", "todo": "./node_modules/.bin/fixme -i node_modules/** -i build/**",
"todo" : "node_modules/.bin/notes -h true -x node_modules/ -x build/",
"test": "mocha tests", "test": "mocha tests",
"test:dev": "nodemon -x mocha tests || exit 0", "test:dev": "nodemon -x mocha tests || exit 0",
"test:markdown": "nodemon -x mocha tests/markdown.test.js || exit 0" "test:markdown": "nodemon -x mocha tests/markdown.test.js || exit 0"
@@ -50,6 +47,7 @@
"chai": "^3.5.0", "chai": "^3.5.0",
"chai-as-promised": "^6.0.0", "chai-as-promised": "^6.0.0",
"chai-subset": "^1.4.0", "chai-subset": "^1.4.0",
"fixme": "^0.4.3",
"mocha": "^3.2.0", "mocha": "^3.2.0",
"supertest": "^2.0.1", "supertest": "^2.0.1",
"supertest-as-promised": "^4.0.2" "supertest-as-promised": "^4.0.2"

View File

@@ -6,18 +6,15 @@
.pseudoBorder(){ .pseudoBorder(){
position : relative; position : relative;
&:before{ &:before{
content : ''; content : '';
position : absolute; position : absolute;
box-sizing : border-box; z-index : -1;
width : 100%; box-sizing : border-box;
border-style : solid; border-style : solid;
z-index : -1; border-image-repeat : round;
} }
} }
/////////////////// ///////////////////
.spell{ .spell{
ul:first-of-type{ ul:first-of-type{
margin-top : -0.5em; margin-top : -0.5em;
@@ -31,36 +28,43 @@
} }
} }
.monster{ .monster{
-webkit-column-break-inside : avoid; .breakAvoid();
column-break-inside : avoid; .pseudoBorder();
&>.internal{ padding : 10px 5px;
table{
color : @headerText;
}
ul:nth-of-type(1),ul:nth-of-type(2){
background-color : red;
}
&:before{
top : 10px;
right : 0px;
bottom : 10px;
left : 0px;
//background-color : @monsterStatBackground; //background-color : @monsterStatBackground;
background-image : @monsterBG; //border-image-outset : 25px 17px;
border-style : solid; border-image-slice : 10;
border-width : 10px; border-image-source : @monsterBorder;
border-image : @monsterBorder 10; border-image-width : 47px;
table{
color : @headerText;
}
ul:nth-of-type(1),ul:nth-of-type(2){
background-color : red;
}
} }
} }
.note{ .note{
.useSansSerif(); .useSansSerif();
.breakAvoid(); .breakAvoid();
.pseudoBorder(); .pseudoBorder();
margin : 9px 0px; margin : 9px 0px;
padding : 12px 0px; padding : 12px 5px;
&:before{ &:before{
top : 9px; top : 9px;
right : 0px;
bottom : 9px; bottom : 9px;
left : 0px; left : 0px;
background-color : @green; background-color : @green;
border-width : 11px; border-width : 11px;
border-image : @noteBorder 11;
border-image-outset : 9px 0px; border-image-outset : 9px 0px;
border-image-slice : 11;
border-image-source : @noteBorder;
} }
h2,h3,h4{ h2,h3,h4{
.useSansSerif(); .useSansSerif();
@@ -70,28 +74,27 @@
font-size : 0.352cm; font-size : 0.352cm;
line-height : 1.1em; line-height : 1.1em;
} }
&.alt{ &.alt{
&:before{ &:before{
border-style : solid; border-style : solid;
border-width : 7px; border-width : 7px;
border-image : @descriptiveBorder 12 round;
border-image-outset : 4px; border-image-outset : 4px;
border-image-slice : 12;
border-image-source : @descriptiveBorder;
} }
} }
} }
.frame{ .frame{
margin-top : 26px; .breakAvoid();
margin-right : 17px; .pseudoBorder();
margin-bottom : 37px; padding : 25px 17px;
margin-left : 17px; &:before{
&>.internal{ top : 25px;
box-sizing : border-box; right : 17px;
bottom : 25px;
left : 17px;
background-color : white; background-color : white;
border : initial;
border-style : solid;
border-image-outset : 25px 17px; border-image-outset : 25px 17px;
border-image-repeat : round;
border-image-slice : 150 200 150 200; border-image-slice : 150 200 150 200;
border-image-source : @frameBorder; border-image-source : @frameBorder;
border-image-width : 47px; border-image-width : 47px;