feat: add iframe widget (#291)
* feat: add nestjs replacement, remove nestjs * feat: add iframe widget * fix: format issue * fix: format issue * fix: format issue * fix: lockfile frozen
This commit is contained in:
1 parent
82e9887f36
commit
8f4897186c
8 files changed
+142
-5
No files matched your search
@@ -0,0 +1,24 @@
|
||||
import { IconBrowser } from "@homarr/ui";
|
||||
|
||||
import { createWidgetDefinition } from "../definition";
|
||||
import { optionsBuilder } from "../options";
|
||||
|
||||
export const { definition, componentLoader } = createWidgetDefinition(
|
||||
"iframe",
|
||||
{
|
||||
icon: IconBrowser,
|
||||
options: optionsBuilder.from((factory) => ({
|
||||
embedUrl: factory.text(),
|
||||
allowFullScreen: factory.switch(),
|
||||
allowScrolling: factory.switch({
|
||||
defaultValue: true,
|
||||
}),
|
||||
allowTransparency: factory.switch(),
|
||||
allowPayment: factory.switch(),
|
||||
allowAutoPlay: factory.switch(),
|
||||
allowMicrophone: factory.switch(),
|
||||
allowCamera: factory.switch(),
|
||||
allowGeolocation: factory.switch(),
|
||||
})),
|
||||
},
|
||||
).withDynamicImport(() => import("./component"));
|
||||
Reference in new issue
Block a user