Milestone
Description
I want to add a helper function for integrated UIs, similar to createContentScriptUi and createContentScriptIframe, but I'm recognizing that adding a third function would be confusing and that the API reference is hard to follow because of how I've constructed the options type.
So I think I'm going to simplify all that into a single function with a basic type for the options. Something like this:
export function createContentScriptUi(
options: {
mode?: "integrated" | "shadow-root" | "iframe",
position?: "inline" | "overlay" | "modal",
zIndex?: number;
anchor?: string | Element;
alignment?: "top-left" | "top-right" | "bottom-right" | "bottom-left";
page?: string;
css?: string;
name?: string;
mount?(container: Element): TApp;
onRemove?(app: TApp): void;
},
): ContentScriptUi;Originally posted by @aklinker1 in #267 (comment)
Reacted by mefengl
Reacted by Cihad Turhan
Metadata
Metadata
Assignees
Labels
No labels
Activity
aklinker1 commentedon Jan 11, 2024
See #333 (comment).
I've decided to keep the functions as separate, but I've renamed them to better represent how the functions create the UIs.
createContentScriptUi→createIntegratedUicreateContentScriptIframe→createShadowRootUicreateIframeUi(new)