Skip to content

Commit

Permalink
Automated linting update and features.json sync
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Oct 17, 2023
1 parent fcf2ec6 commit 95b2793
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
7 changes: 5 additions & 2 deletions packages/studio-ui/src/hooks/useInjectUserStyles.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,11 @@ function clearStylingFromIframe(iframeDocument: Document) {
});
}

async function injectStyleIntoIframe(iframeDocument: Document, filepath: string) {
await loadStyletagIfMissing(filepath)
async function injectStyleIntoIframe(
iframeDocument: Document,
filepath: string
) {
await loadStyletagIfMissing(filepath);
const originalStyletag = document.querySelector(
`[studio-style-filepath='${filepath}']`
);
Expand Down
6 changes: 3 additions & 3 deletions packages/studio-ui/src/utils/loadUserAssets.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,14 @@ export function loadStyling() {
Object.values(UUIDToFileMetadata).forEach((fileMetadata) => {
if (fileMetadata.kind === FileMetadataKind.Component) {
fileMetadata.cssImports.forEach(async (filepath) => {
await loadStyletagIfMissing(filepath)
await loadStyletagIfMissing(filepath);
});
}
});

Object.values(pages).forEach((page) => {
page.cssImports.forEach(async (filepath) => {
await loadStyletagIfMissing(filepath)
await loadStyletagIfMissing(filepath);
});
});
}
Expand All @@ -61,4 +61,4 @@ export async function loadStyletagIfMissing(filepath: string) {
document.head.appendChild(styleEl);
styleEl.disabled = true;
});
}
}

0 comments on commit 95b2793

Please sign in to comment.