Let the theme be forced onto mail that styles itself
Appearance gained "Apply the theme to messages too" some time ago, and it themes an HTML message only when the message brings no colours of its own. That predicate is the right default and it almost never passes: one `color:#FFFFFF` on one button label opts a whole message out, so in real mail — receipts, shipping notices, anything from a template — the switch did nothing at all and the reader kept a bright white card on a dark UI. A second switch, off by default and only meaningful with the first on, forces the palette over the sender's colours. It cannot be done perfectly, which is why it is a separate, explicit choice: the same bargain a dark-reader extension makes. What it does is tell two kinds of colour apart. A *sheet* the design sits on — the white 600px wrapper — is neutralised, and a *painted surface* — a call to action, a footer banner — is kept whole so its label stays legible on it. Relative luminance decides, at 0.5: white wrappers sit at 1.0, a blue button near 0.09. Only the painted ones are marked, with data-ihm-keep, and one rule in EMAIL_BASE_CSS neutralises everything else. Nothing the sender wrote is removed, so the switch is reversible, colours arriving from a <style> block are covered as well as inline ones, and print still pins the tokens to ink on white. The mock grew the message this is about: an outer wrapper on bgcolor="#ffffff", a <style> block, a coloured button, a grey footer. Without one, neither the bug nor the fix could be seen. Verified in a browser against the mock: with only the first switch on the card is still white; with both, the wrapper computes to transparent, body text follows the theme, and the button keeps white-on-blue. Two surfaces marked, which are the two the message paints. Closes #290
This commit is contained in:
@@ -518,6 +518,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "Labels in der Seitenleiste anzeigen",
|
||||
"Collapse sidebar to icons": "Seitenleiste auf Symbole verkleinern",
|
||||
"Apply the theme to messages too": "Design auch auf Nachrichten anwenden",
|
||||
"Apply it even to mail that styles itself": "Auch auf Mails anwenden, die sich selbst gestalten",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "Fast jede Werbe- oder Beleg-Mail setzt irgendwo eine Farbe, deshalb lässt die Einstellung darüber nahezu alle davon auf einer weißen Karte. Mit dieser Option wird das Design über die Farben des Absenders gelegt: Hintergründe, auf denen die Nachricht liegt, entfallen, während Schaltflächen und farbige Banner erhalten bleiben, damit ihr Text lesbar bleibt. Manche Mail übersteht das nicht unbeschadet – deshalb ist es eine eigene Einstellung.",
|
||||
"Swiping": "Wischgesten",
|
||||
"Swipe left": "Nach links wischen",
|
||||
"Swipe right": "Nach rechts wischen",
|
||||
|
||||
@@ -518,6 +518,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "Mostrar las etiquetas en la barra lateral",
|
||||
"Collapse sidebar to icons": "Reducir la barra lateral a iconos",
|
||||
"Apply the theme to messages too": "Aplicar el tema también a los mensajes",
|
||||
"Apply it even to mail that styles itself": "Aplicarlo incluso al correo que se da estilo propio",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "Casi todo el correo publicitario y de recibos define algún color, así que el ajuste anterior deja casi todo sobre una tarjeta blanca. Con esto activado, el tema se impone sobre los colores del remitente: se descartan los fondos sobre los que apoyó el mensaje, mientras que los botones y los banners de color se conservan para que su texto siga siendo legible. Algunos mensajes no sobrevivirán intactos, y por eso es un ajuste aparte.",
|
||||
"Swiping": "Deslizamiento",
|
||||
"Swipe left": "Deslizar a la izquierda",
|
||||
"Swipe right": "Deslizar a la derecha",
|
||||
|
||||
@@ -524,6 +524,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "Afficher les libellés dans la barre latérale",
|
||||
"Collapse sidebar to icons": "Réduire la barre latérale en icônes",
|
||||
"Apply the theme to messages too": "Appliquer le thème aux messages",
|
||||
"Apply it even to mail that styles itself": "L'appliquer même aux messages qui se mettent en forme",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "Presque tous les courriers publicitaires et les reçus définissent une couleur quelque part, si bien que le réglage ci-dessus en laisse la quasi-totalité sur une carte blanche. Avec cette option, le thème est imposé par-dessus les couleurs de l'expéditeur : les fonds sur lesquels le message repose sont supprimés, tandis que les boutons et les bandeaux colorés sont conservés pour que leur texte reste lisible. Certains messages n'y survivront pas intacts, d'où un réglage distinct.",
|
||||
"Swiping": "Balayage",
|
||||
"Swipe left": "Balayer vers la gauche",
|
||||
"Swipe right": "Balayer vers la droite",
|
||||
|
||||
@@ -518,6 +518,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "サイドバーにラベルを表示する",
|
||||
"Collapse sidebar to icons": "サイドバーをアイコンだけにする",
|
||||
"Apply the theme to messages too": "メールにもテーマを適用する",
|
||||
"Apply it even to mail that styles itself": "自分で配色を持つメールにも適用する",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "宣伝メールや領収メールはほとんどがどこかで色を指定しているため、上の設定では大半が白いカードのままになります。これを有効にすると、送信者の配色の上からテーマを適用します。メッセージが載っている背景は取り除き、ボタンや色付きのバナーは文字が読めるようにそのまま残します。一部のメールは元の見た目を保てないため、別の設定として分けています。",
|
||||
"Swiping": "スワイプ操作",
|
||||
"Swipe left": "左へスワイプ",
|
||||
"Swipe right": "右へスワイプ",
|
||||
|
||||
@@ -515,6 +515,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "Labels in de zijbalk tonen",
|
||||
"Collapse sidebar to icons": "Zijbalk inklappen tot pictogrammen",
|
||||
"Apply the theme to messages too": "Thema ook op berichten toepassen",
|
||||
"Apply it even to mail that styles itself": "Pas dit ook toe op e-mail met eigen vormgeving",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "Bijna alle reclame- en bonmail zet ergens een kleur, waardoor de instelling hierboven vrijwel alles op een witte kaart laat staan. Met deze optie wordt het thema over de kleuren van de afzender heen gelegd: achtergronden waarop het bericht is geplaatst vervallen, terwijl knoppen en gekleurde banners blijven staan zodat hun tekst leesbaar blijft. Sommige berichten overleven dat niet ongeschonden, en daarom is dit een aparte instelling.",
|
||||
"Swiping": "Vegen",
|
||||
"Swipe left": "Naar links vegen",
|
||||
"Swipe right": "Naar rechts vegen",
|
||||
|
||||
@@ -521,6 +521,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "Mostrar os marcadores na barra lateral",
|
||||
"Collapse sidebar to icons": "Recolher a barra lateral em ícones",
|
||||
"Apply the theme to messages too": "Aplicar o tema também às mensagens",
|
||||
"Apply it even to mail that styles itself": "Aplicar mesmo em mensagens com estilo próprio",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "Quase toda mensagem de marketing ou de recibo define alguma cor, então a opção acima deixa quase todas em um cartão branco. Com isto ativado, o tema é imposto sobre as cores do remetente: os fundos sobre os quais a mensagem foi montada são descartados, enquanto botões e faixas coloridas são preservados para que o texto continue legível. Algumas mensagens não sobrevivem intactas, e por isso esta é uma opção separada.",
|
||||
"Swiping": "Gestos de deslizar",
|
||||
"Swipe left": "Deslizar para a esquerda",
|
||||
"Swipe right": "Deslizar para a direita",
|
||||
|
||||
@@ -521,6 +521,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "Показывать ярлыки на боковой панели",
|
||||
"Collapse sidebar to icons": "Свернуть боковую панель до значков",
|
||||
"Apply the theme to messages too": "Применять тему и к письмам",
|
||||
"Apply it even to mail that styles itself": "Применять даже к письмам с собственным оформлением",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "Почти в каждом рекламном письме и чеке где-нибудь задан цвет, поэтому настройка выше оставляет почти все такие письма на белой карточке. С этой настройкой тема накладывается поверх цветов отправителя: фон, на котором свёрстано письмо, убирается, а кнопки и цветные плашки сохраняются, чтобы текст на них оставался читаемым. Некоторые письма это не переживут без потерь — поэтому настройка отдельная.",
|
||||
"Swiping": "Жесты смахивания",
|
||||
"Swipe left": "Смахнуть влево",
|
||||
"Swipe right": "Смахнуть вправо",
|
||||
|
||||
@@ -515,6 +515,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "Показувати мітки на бічній панелі",
|
||||
"Collapse sidebar to icons": "Згорнути бічну панель до значків",
|
||||
"Apply the theme to messages too": "Застосовувати тему й до листів",
|
||||
"Apply it even to mail that styles itself": "Застосовувати навіть до листів із власним оформленням",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "Майже в кожному рекламному листі та чеку десь задано колір, тому налаштування вище залишає майже всі такі листи на білій картці. Із цим налаштуванням тема накладається поверх кольорів відправника: тло, на якому зверстано лист, прибирається, а кнопки та кольорові плашки зберігаються, щоб текст на них залишався читабельним. Деякі листи цього не переживуть без втрат — тому це окреме налаштування.",
|
||||
"Swiping": "Жести проведення",
|
||||
"Swipe left": "Провести ліворуч",
|
||||
"Swipe right": "Провести праворуч",
|
||||
|
||||
@@ -517,6 +517,8 @@ export const catalog: Catalog = {
|
||||
"Show labels in the sidebar": "在侧边栏中显示标签",
|
||||
"Collapse sidebar to icons": "将侧边栏收起为图标",
|
||||
"Apply the theme to messages too": "邮件也应用主题",
|
||||
"Apply it even to mail that styles itself": "即使邮件自带配色也套用",
|
||||
"Most marketing and receipt mail sets a colour somewhere, so the setting above leaves nearly all of it on a white card. With this on, the theme is forced over the sender's own colours: backgrounds they laid the message on are dropped, while buttons and coloured banners are kept so their text stays readable. Some mail will not survive it intact, which is why it is separate.": "几乎所有营销邮件和收据邮件都会在某处设置颜色,因此上面的设置会让它们几乎全部停留在白色卡片上。启用此项后,主题会覆盖发件人的配色:邮件所依托的背景会被去掉,而按钮和彩色横幅会保留下来,使其文字仍然清晰可读。有些邮件无法完好呈现,因此这是一项单独的设置。",
|
||||
"Swiping": "滑动手势",
|
||||
"Swipe left": "向左滑动",
|
||||
"Swipe right": "向右滑动",
|
||||
|
||||
Reference in New Issue
Block a user