mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2026-01-14 21:32:41 +00:00
Starting on the brew card
This commit is contained in:
30
shared/homebrewery/brewCard/brewCard.jsx
Normal file
30
shared/homebrewery/brewCard/brewCard.jsx
Normal file
@@ -0,0 +1,30 @@
|
||||
|
||||
const React = require('react');
|
||||
const _ = require('lodash');
|
||||
const cx = require('classnames');
|
||||
|
||||
const BrewCard = React.createClass({
|
||||
getDefaultProps: function() {
|
||||
return {
|
||||
brew : {
|
||||
shareId : '',
|
||||
title : '',
|
||||
description : '',
|
||||
|
||||
views : 0,
|
||||
|
||||
editId : false
|
||||
}
|
||||
};
|
||||
},
|
||||
render: function(){
|
||||
const brew = this.props.brew;
|
||||
return <div className='brewCard'>
|
||||
<h3>{brew.title}</h3>
|
||||
<p>{brew.description}</p>
|
||||
|
||||
</div>
|
||||
}
|
||||
});
|
||||
|
||||
module.exports = BrewCard;
|
||||
10
shared/homebrewery/brewCard/brewCard.less
Normal file
10
shared/homebrewery/brewCard/brewCard.less
Normal file
@@ -0,0 +1,10 @@
|
||||
.brewCard{
|
||||
width : 300px;
|
||||
height : 100px;
|
||||
|
||||
//border : 1px solid black;
|
||||
background-image : url('/assets/homebrewery/brewCard/monster_bg.jpg');
|
||||
|
||||
position : relative;
|
||||
|
||||
}
|
||||
BIN
shared/homebrewery/brewCard/monster_bg.jpg
Normal file
BIN
shared/homebrewery/brewCard/monster_bg.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 339 KiB |
BIN
shared/homebrewery/brewCard/note_border.png
Normal file
BIN
shared/homebrewery/brewCard/note_border.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 530 B |
BIN
shared/homebrewery/brewCard/note_border_shadow.png
Normal file
BIN
shared/homebrewery/brewCard/note_border_shadow.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
@@ -6,7 +6,10 @@ module.exports = _.merge(
|
||||
require('./class.snippet.js'),
|
||||
require('./note.snippet.js'),
|
||||
require('./monster.snippet.js'),
|
||||
require('./toc.snippet.js')
|
||||
require('./toc.snippet.js'),
|
||||
|
||||
require('./random.brew.js')
|
||||
|
||||
|
||||
|
||||
//wide
|
||||
|
||||
11
shared/homebrewery/snippets/brew/random.brew.js
Normal file
11
shared/homebrewery/snippets/brew/random.brew.js
Normal file
@@ -0,0 +1,11 @@
|
||||
const _ = require('lodash');
|
||||
const Data = require('./random.data.js');
|
||||
|
||||
|
||||
module.exports = {
|
||||
brew : ()=>{
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user