diff --git a/markitect/clean_document_manager.py b/markitect/clean_document_manager.py index cc493c01..0c2f7910 100644 --- a/markitect/clean_document_manager.py +++ b/markitect/clean_document_manager.py @@ -134,8 +134,8 @@ class CleanDocumentManager: else: # Legacy single theme or fallback if not template or template not in TEMPLATE_STYLES: - # Use default layered themes - theme_list = parse_theme_string('basic') + # Use default layered themes or the specified theme + theme_list = parse_theme_string(template or 'basic') combined_props = combine_theme_properties(theme_list) return self._generate_layered_css(combined_props) else: @@ -267,9 +267,28 @@ class CleanDocumentManager: font-weight: 600; }}""" - # Branding accents (if specified) + # Link styling + link_css = "" + if props.get('link_color'): + link_css = f""" + a {{ + color: {props['link_color']}; + text-decoration: underline; + }}""" + if props.get('link_hover_color'): + link_css += f""" + a:hover {{ + color: {props['link_hover_color']}; + }}""" + else: + link_css += """ + a:hover { + opacity: 0.8; + }""" + + # Branding accents (if specified and no link_color already set) accent_css = "" - if props.get('accent_color'): + if props.get('accent_color') and not props.get('link_color'): accent_css = f""" a {{ color: {props['accent_color']}; @@ -278,7 +297,7 @@ class CleanDocumentManager: opacity: 0.8; }}""" - return f"" + return f"" def _get_legacy_template_css(self, template: str) -> str: """Legacy CSS generation - kept for backward compatibility."""