Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class HtmlElementDecorator(HtmlElement):
- def __init__(self, element):
- self.element = element
- def render(self):
- return self.element.render()
- class StyledDiv(HtmlElementDecorator):
- def render(self):
- return "<div class='styled-div'>" + self.element.render() + "</div>\n"
- class StyledLabel(HtmlElementDecorator):
- def render(self):
- return "<label class='styled-label'>" + self.element.render() + "</label>\n"
- class StyledInput(HtmlElementDecorator):
- def render(self):
- return "<input class='styled-input' type='text'/>\n"
- class StyledSelect(HtmlElementDecorator):
- def render(self):
- return "<select class='styled-select'><option>Option</option></select>\n"
- class StyledSubmit(HtmlElementDecorator):
- def render(self):
- return "<input class='styled-submit' type='submit'/>\n"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement