import 'package:flutter/material.dart'; class HtmlTemplate { static const String nameClassToolTip = 'tmail-tooltip'; static const String tooltipLinkCss = ''' .$nameClassToolTip .tooltiptext { visibility: hidden; max-width: 400px; background-color: black; color: #fff; text-align: center; border-radius: 6px; padding: 5px 8px 5px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; position: absolute; z-index: 1; } .$nameClassToolTip:hover .tooltiptext { visibility: visible; } '''; static const String printDocumentCssStyle = ''' '''; static const String fontFaceStyle = ''' @font-face { font-family: 'Inter'; src: url("/assets/fonts/Inter/Inter-Regular.ttf") format("truetype"); font-weight: 400; font-style: normal; } @font-face { font-family: 'Inter'; src: url("/assets/fonts/Inter/Inter-Medium.ttf") format("truetype"); font-weight: 500; font-style: medium; } @font-face { font-family: 'Inter'; src: url("/assets/fonts/Inter/Inter-SemiBold.ttf") format("truetype"); font-weight: 600; font-style: semi-bold; } @font-face { font-family: 'Inter'; src: url("/assets/fonts/Inter/Inter-Bold.ttf") format("truetype"); font-weight: 700; font-style: bold; } body { font-family: 'Inter', sans-serif; } '''; static const String defaultFontStyle = ''' div, p, span, th, td, tr, ul, ol, li, a, button { font-weight: 400; font-size: 16px; line-height: 24px; letter-spacing: -0.01em; /* -1% */ } p { margin: 0px; } '''; static const String defaultEditorFontStyle = ''' #editor, .note-editable, .note-frame { font-size: 16px; color: #222222; } p { margin: 0px; } '''; static const String previewEMLFileCssStyle = ''' '''; static const String markDownAndASCIIArtStyleCSS = 'display: block; font-family: monospace; white-space: pre; margin: 1em 0px;'; static String webCustomInternalStyleCSS({ bool useDefaultFontStyle = false, bool customScrollbar = false, }) => ''' '''; static String mobileCustomInternalStyleCSS({ bool useDefaultFontStyle = false, TextDirection direction = TextDirection.ltr, }) => ''' ${HtmlTemplate.fontFaceStyle} ${useDefaultFontStyle ? HtmlTemplate.defaultEditorFontStyle : ''} #editor { direction: ${direction.name}; } #editor .tmail-signature { text-align: ${direction == TextDirection.rtl ? 'right' : 'left'}; } '''; static const String disableScrollingStyleCSS = ''' html, body { overflow: hidden; overscroll-behavior: none; scrollbar-width: none; /* Firefox */ -ms-overflow-style: none; /* IE/Edge */ } ::-webkit-scrollbar { display: none; } '''; }