@@ -2,6 +2,7 @@ import { ReactElement } from 'react';
22import {
33 TbAlignLeft ,
44 TbBike ,
5+ TbBrowserPlus ,
56 TbBus ,
67 TbCalendarEvent ,
78 TbCloudStorm ,
@@ -79,7 +80,8 @@ export type WidgetName =
7980 | 'bike'
8081 | 'weathercam'
8182 | 'map'
82- | 'cmschEvents' ;
83+ | 'cmschEvents'
84+ | 'iframe' ;
8385
8486export const WidgetDisplay : Record < WidgetName , { name : string ; icon : ReactElement } > = {
8587 weather : { name : 'Időjárás' , icon : TbSun ( { size : 50 } ) } ,
@@ -92,6 +94,7 @@ export const WidgetDisplay: Record<WidgetName, { name: string; icon: ReactElemen
9294 weathercam : { name : 'Időjárás kamera' , icon : TbCloudStorm ( { size : 50 } ) } ,
9395 map : { name : 'Térkép' , icon : TbMap ( { size : 50 } ) } ,
9496 cmschEvents : { name : 'CMSch események' , icon : TbCalendarEvent ( { size : 50 } ) } ,
97+ iframe : { name : 'Iframe' , icon : TbBrowserPlus ( { size : 50 } ) } ,
9598} ;
9699
97100type WidgetConfigField = {
@@ -120,6 +123,7 @@ export const WidgetConfigFields: Record<WidgetName, WidgetConfigField[]> = {
120123 { name : 'radius' , type : 'number' , label : 'Hatósugár' } ,
121124 ] ,
122125 cmschEvents : [ { name : 'baseUrl' , type : 'text' , label : 'Szerver Hoszt' } ] ,
126+ iframe : [ { name : 'url' , type : 'text' , label : 'Iframe URL címe' } ] ,
123127} ;
124128
125129export type WidgetConfigBase = {
@@ -177,6 +181,11 @@ export interface CMSchEventsConfig extends WidgetConfigBase {
177181 baseUrl : string ;
178182}
179183
184+ export interface IframeConfig extends WidgetConfigBase {
185+ name : 'iframe' ;
186+ url : string ;
187+ }
188+
180189export type GridSettings = {
181190 column : Axis ;
182191 row : Axis ;
@@ -199,4 +208,5 @@ export type WidgetConfig =
199208 | BikeConfig
200209 | WeatherCamConfig
201210 | MapConfig
202- | CMSchEventsConfig ;
211+ | CMSchEventsConfig
212+ | IframeConfig ;
0 commit comments