Skip to content

Commit 83468a0

Browse files
refactor!: remove no longer used addGlobalThemeStyles helper (#10673) (#10676)
Co-authored-by: Serhii Kulykov <iamkulykov@gmail.com>
1 parent eda3bb4 commit 83468a0

File tree

2 files changed

+0
-20
lines changed

2 files changed

+0
-20
lines changed
Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
1-
import type { CSSResultGroup } from 'lit';
2-
31
/**
42
* @license
53
* Copyright (c) 2017 - 2025 Vaadin Ltd.
64
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
75
*/
86
export { registerStyles, css, unsafeCSS } from './vaadin-themable-mixin.js';
9-
export const addGlobalThemeStyles: (id: string, ...styles: CSSResultGroup[]) => void;

packages/vaadin-themable-mixin/register-styles.js

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,3 @@
44
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
55
*/
66
export { registerStyles, css, unsafeCSS } from './vaadin-themable-mixin.js';
7-
8-
/**
9-
* This is for use internally by Lumo and Material styles.
10-
*
11-
* @param {string} id the id to set on the created element, only for informational purposes
12-
* @param {CSSResultGroup[]} styles the styles to add
13-
*/
14-
export const addGlobalThemeStyles = (id, ...styles) => {
15-
const styleTag = document.createElement('style');
16-
styleTag.id = id;
17-
styleTag.textContent = styles
18-
.map((style) => style.toString())
19-
.join('\n')
20-
.replace(':host', 'html');
21-
22-
document.head.insertAdjacentElement('afterbegin', styleTag);
23-
};

0 commit comments

Comments
 (0)