0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-03 01:52:42 +00:00

Converted the monster block to use border iamges

This commit is contained in:
Scott Tolksdorf
2016-05-10 23:51:45 -04:00
parent 6f6f5649d4
commit 634c1a617c
8 changed files with 24 additions and 32 deletions

View File

@@ -39,8 +39,6 @@
padding : 10px;
cursor : pointer;
font-size : 13px;
//font-weight: 800;
//text-transform: uppercase;
i{
margin-right: 8px;
}

View File

@@ -24,13 +24,13 @@ module.exports = function(classname){
"",
"#### Proficiencies",
"___",
"- **Armor:** " + (_.sample(["Light armor", "Medium armor", "Heavy armor", "Shields"], _.random(0,3)).join(', ') || "None"),
"- **Weapons:** " + (_.sample(["Squeegee", "Rubber Chicken", "Simple weapons", "Martial weapons"], _.random(0,2)).join(', ') || "None"),
"- **Tools:** " + (_.sample(["Artian's tools", "one musical instrument", "Thieve's tools"], _.random(0,2)).join(', ') || "None"),
"- **Armor:** " + (_.sampleSize(["Light armor", "Medium armor", "Heavy armor", "Shields"], _.random(0,3)).join(', ') || "None"),
"- **Weapons:** " + (_.sampleSize(["Squeegee", "Rubber Chicken", "Simple weapons", "Martial weapons"], _.random(0,2)).join(', ') || "None"),
"- **Tools:** " + (_.sampleSize(["Artian's tools", "one musical instrument", "Thieve's tools"], _.random(0,2)).join(', ') || "None"),
"",
"___",
"- **Saving Throws:** " + (_.sample(abilityList, 2).join(', ')),
"- **Skills:** Choose two from " + (_.sample(skillList, _.random(4, 6)).join(', ')),
"- **Saving Throws:** " + (_.sampleSize(abilityList, 2).join(', ')),
"- **Skills:** Choose two from " + (_.sampleSize(skillList, _.random(4, 6)).join(', ')),
"",
"#### Equipment",
"You start with the following equipment, in addition to the equipment granted by your background:",

View File

@@ -1,7 +1,7 @@
var _ = require('lodash');
var genList = function(list, max){
return _.sample(list, _.random(0,max)).join(', ') || "None";
return _.sampleSize(list, _.random(0,max)).join(', ') || "None";
}
var getMonsterName = function(){

View File

@@ -4,7 +4,7 @@ var cx = require('classnames');
var CreateRouter = require('pico-router').createRouter;
var HomePage = require('./pages/homePage/homePage.jsx');
var MainPage = require('./pages/mainPage/mainPage.jsx');
var EditPage = require('./pages/editPage/editPage.jsx');
var SharePage = require('./pages/sharePage/sharePage.jsx');
var NewPage = require('./pages/newPage/newPage.jsx');
@@ -41,7 +41,7 @@ var Homebrew = React.createClass({
'/homebrew/new' : (args) => {
return <NewPage />
},
'/homebrew*' : <HomePage welcomeText={this.props.welcomeText} />,
'/homebrew*' : <MainPage welcomeText={this.props.welcomeText} />,
});
},
render : function(){

Binary file not shown.

After

Width:  |  Height:  |  Size: 327 B

File diff suppressed because one or more lines are too long

View File

@@ -186,8 +186,11 @@
hr+blockquote{
position : relative;
background-color : @monsterStatBackground;
border : none;
//border : none;
padding-top: 15px;
border-image : @monsterBorderImage 10;
border-width : 10px;
h2{
margin-top: -8px;
margin-bottom : 0px;
@@ -231,27 +234,15 @@
}
//Triangle dividers
hr{
@height : 3px;
position : relative;
visibility : visible;
margin : 8px 0px;
border-color : transparent;
&:after, &:before{
content : "";
position : absolute;
left : 0px;
height : @height;
width : 100%;
}
&:before{
top : -@height;
background : linear-gradient(to right top, @horizontalRule 40%, transparent 50%)
}
&:after{
top : 0px;
background : linear-gradient(to right bottom, @horizontalRule 40%, transparent 50%)
}
visibility: visible;
border: none;
height: 6px;
margin: 4px 0px;
background-image: @redTriangleImage;
background-size: 100% 100%;
}
/*
//Top and Bottom Borders
&:after, &:before{
content : "";
@@ -270,6 +261,7 @@
bottom : 0px;
left : -3px;
}
*/
}
//Full Width
hr+hr+blockquote{

Binary file not shown.

After

Width:  |  Height:  |  Size: 864 B