dsh-im-ops/plugin-src/client/channels/wecom/styles.js
oliver d53daf7d26 Rebrand as dsh-im-ops fork of xmanrui/dsh-im@4.9.1.
Keep all IM channels; rename package/cordis id for local profile install without colliding with the community plugin. Document fork intent in FORK.md.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-05 15:02:54 +08:00

19 lines
814 B
JavaScript

export const WECOM_STYLE_ID = 'xmanrui-dsh-im-wecom-settings';
const CSS = String.raw`
.dwecom-page { --ddt-accent: #3370ff; --ddt-accent-deep: #245bdb; --ddt-accent-wash: #eef4ff; }
.dwecom-avatar, .dwecom-brand { color: #3370ff; background: #fff; border: 1px solid var(--dsw-alias-border-l2, #e5e6eb); }
.dwecom-avatar svg, .dwecom-brand svg { display: block; }
`;
export function installWecomStyles() {
if (typeof document === 'undefined') return () => {};
const existing = document.querySelector(`style[data-plugin-css="${WECOM_STYLE_ID}"]`);
if (existing) return () => {};
const style = document.createElement('style');
style.dataset.plugin = 'dsh-im-ops';
style.dataset.pluginCss = WECOM_STYLE_ID;
style.textContent = CSS;
document.head.appendChild(style);
return () => style.remove();
}