Skip to content

Scheduling infrastructure for absolutely everyone.

Embed: Remove ugly windows scrollbar even on unscrollable content (#7171)

Hariom Balharaa5e5d103a0fd
diff --git a/packages/embeds/embed-core/src/embed.ts b/packages/embeds/embed-core/src/embed.ts
index 9a2c47a4bdc..856324a5aa7 100644
--- a/packages/embeds/embed-core/src/embed.ts
+++ b/packages/embeds/embed-core/src/embed.ts
@@ -270,8 +270,9 @@ export class Cal {
if (!element) {
throw new Error("Element not found");
}
+ element.classList.add("cal-inline-container");
const template = document.createElement("template");
- template.innerHTML = `<cal-inline style="max-height:inherit;height:inherit;min-height:inherit;display:flex;position:relative;flex-wrap:wrap;width:100%"></cal-inline>`;
+ template.innerHTML = `<cal-inline style="max-height:inherit;height:inherit;min-height:inherit;display:flex;position:relative;flex-wrap:wrap;width:100%"></cal-inline><style>.cal-inline-container::-webkit-scrollbar{display:none}.cal-inline-container{scrollbar-width:none}</style>`;
this.inlineEl = template.content.children[0];
(this.inlineEl as unknown as any).__CalAutoScroll = config.__autoScroll;
this.inlineEl.appendChild(iframe);