Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class CssStyleDecorator(CssStyle):
- def __init__(self, style):
- self.style = style
- def render(self):
- return self.style.render()
- class ColoredDivStyle(CssStyleDecorator):
- def render(self):
- return "div.styled-div { margin: 10px; border: 1px solid #000; }\n"
- class ColoredLabelStyle(CssStyleDecorator):
- def render(self):
- return "label.styled-label { font-size: 14px; color: #FF5733; }\n"
- class ColoredInputStyle(CssStyleDecorator):
- def render(self):
- return "input.styled-input[type='text'] { padding: 5px; border: 2px solid #4CAF50; }\n"
- class ColoredSelectStyle(CssStyleDecorator):
- def render(self):
- return "select.styled-select { width: 100px; border: 1px solid #333; }\n"
- class ColoredSubmitStyle(CssStyleDecorator):
- def render(self):
- return "input.styled-submit[type='submit'] { background-color: #4CAF50; color: white; padding: 10px; }\n"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement